ham/tnt: Fix build on DragonFly Problem 1: $la and $lo would not expand with the intl/makefile I couldn't get SUBST_SED to manually replace them either. Use of MAKE_ENV also failed. Problem 2: DragonFly doesn't have base libintl. This package will not build without -lintl LDFLAG. Solution was to convert existing SUBST_SED into a patch and expand $la to "a" and $lo to "o" on the intl/Makefile.in file. Tested on both DragonFly and NetBSDdiff -r1.28 -r1.29 pkgsrc/ham/tnt/Makefile
(marino)
@@ -1,31 +1,26 @@ | @@ -1,31 +1,26 @@ | |||
1 | # $NetBSD: Makefile,v 1.28 2011/04/22 13:43:53 obache Exp $ | 1 | # $NetBSD: Makefile,v 1.29 2012/08/08 13:11:48 marino Exp $ | |
2 | # | 2 | # | |
3 | 3 | |||
4 | DISTNAME= tnt-1.9.2 | 4 | DISTNAME= tnt-1.9.2 | |
5 | PKGREVISION= 1 | 5 | PKGREVISION= 1 | |
6 | CATEGORIES= ham | 6 | CATEGORIES= ham | |
7 | MASTER_SITES= ftp://ftp.wspse.de/pub/packet_radio/tnt/ | 7 | MASTER_SITES= ftp://ftp.wspse.de/pub/packet_radio/tnt/ | |
8 | 8 | |||
9 | MAINTAINER= pkgsrc-users@NetBSD.org | 9 | MAINTAINER= pkgsrc-users@NetBSD.org | |
10 | HOMEPAGE= http://wspse.de/WSPse/Packet.php3 | 10 | HOMEPAGE= http://wspse.de/WSPse/Packet.php3 | |
11 | COMMENT= Amateur packet radio terminal program for TNC2, AEA PK232 and PK88 | 11 | COMMENT= Amateur packet radio terminal program for TNC2, AEA PK232 and PK88 | |
12 | 12 | |||
13 | DEPENDS+= dialog>=0.6z:../../misc/dialog | 13 | DEPENDS+= dialog>=0.6z:../../misc/dialog | |
14 | 14 | |||
15 | PKG_INSTALLATION_TYPES= overwrite pkgviews | 15 | PKG_INSTALLATION_TYPES= overwrite pkgviews | |
16 | PKG_DESTDIR_SUPPORT= user-destdir | 16 | PKG_DESTDIR_SUPPORT= user-destdir | |
17 | 17 | |||
18 | USE_TOOLS+= gmake | 18 | USE_TOOLS+= gmake | |
19 | USE_PKGLOCALEDIR= yes | 19 | USE_PKGLOCALEDIR= yes | |
20 | GNU_CONFIGURE= yes | 20 | GNU_CONFIGURE= yes | |
21 | INFO_FILES= yes | 21 | INFO_FILES= yes | |
22 | 22 | |||
23 | SUBST_CLASSES+= missing | 23 | LDFLAGS.DragonFly+= -lintl | |
24 | SUBST_MESSAGE.missing= Subst missing replacements with configure | |||
25 | SUBST_STAGE.missing= post-configure | |||
26 | SUBST_FILES.missing= intl/Makefile | |||
27 | SUBST_SED.missing= -e 's,@GT_YES@,\#,g' | |||
28 | SUBST_SED.missing+= -e 's,@GT_NO@,,g' | |||
29 | 24 | |||
30 | .include "../../devel/gettext-lib/buildlink3.mk" | 25 | .include "../../devel/gettext-lib/buildlink3.mk" | |
31 | .include "../../mk/bsd.pkg.mk" | 26 | .include "../../mk/bsd.pkg.mk" |
@@ -1,9 +1,10 @@ | @@ -1,9 +1,10 @@ | |||
1 | $NetBSD: distinfo,v 1.9 2009/02/16 19:20:16 joerg Exp $ | 1 | $NetBSD: distinfo,v 1.10 2012/08/08 13:11:48 marino Exp $ | |
2 | 2 | |||
3 | SHA1 (tnt-1.9.2.tar.gz) = 8826e7e730c3440113bf723e18bb136e91cef8f8 | 3 | SHA1 (tnt-1.9.2.tar.gz) = 8826e7e730c3440113bf723e18bb136e91cef8f8 | |
4 | RMD160 (tnt-1.9.2.tar.gz) = 10e5812715d564f25797ff3d83124ad2b86f2a62 | 4 | RMD160 (tnt-1.9.2.tar.gz) = 10e5812715d564f25797ff3d83124ad2b86f2a62 | |
5 | Size (tnt-1.9.2.tar.gz) = 920883 bytes | 5 | Size (tnt-1.9.2.tar.gz) = 920883 bytes | |
6 | SHA1 (patch-aa) = f2b6c9f22ffd4ef418f5aab6ca179d656e0a563c | 6 | SHA1 (patch-aa) = f2b6c9f22ffd4ef418f5aab6ca179d656e0a563c | |
7 | SHA1 (patch-ac) = 86865198639da69469c2766ec638898553eb7662 | 7 | SHA1 (patch-ac) = 86865198639da69469c2766ec638898553eb7662 | |
8 | SHA1 (patch-ad) = 1735028a7a52cc75f83a3f3c9fd29a06c9dd0153 | 8 | SHA1 (patch-ad) = 1735028a7a52cc75f83a3f3c9fd29a06c9dd0153 | |
9 | SHA1 (patch-ae) = 0f952e74159cd2eed714b7f3ab62bf54c9fbd177 | 9 | SHA1 (patch-ae) = 0f952e74159cd2eed714b7f3ab62bf54c9fbd177 | |
10 | SHA1 (patch-intl_Makefile.in) = 57e58f81217d382bcb71d227e9184ae827f9ddd7 |
$NetBSD: patch-intl_Makefile.in,v 1.1 2012/08/08 13:11:48 marino Exp $
--- intl/Makefile.in.orig 2000-01-06 01:16:49.000000000 +0000
+++ intl/Makefile.in
@@ -62,11 +62,11 @@ SOURCES = $(COMSRCS) intl-compat.c cat-c
COMSRCS = bindtextdom.c dcgettext.c dgettext.c gettext.c \
finddomain.c loadmsgcat.c localealias.c textdomain.c l10nflist.c \
explodename.c
-OBJECTS = @INTLOBJS@ bindtextdom.$lo dcgettext.$lo dgettext.$lo gettext.$lo \
-finddomain.$lo loadmsgcat.$lo localealias.$lo textdomain.$lo l10nflist.$lo \
-explodename.$lo
-CATOBJS = cat-compat.$lo ../po/cat-id-tbl.$lo
-GETTOBJS = intl-compat.$lo
+OBJECTS = @INTLOBJS@ bindtextdom.o dcgettext.o dgettext.o gettext.o \
+finddomain.o loadmsgcat.o localealias.o textdomain.o l10nflist.o \
+explodename.o
+CATOBJS = cat-compat.o ../po/cat-id-tbl.o
+GETTOBJS = intl-compat.o
DISTFILES.common = ChangeLog Makefile.in linux-msg.sed po2tbl.sed.in \
xopen-msg.sed $(HEADERS) $(SOURCES)
DISTFILES.normal = VERSION
@@ -83,7 +83,7 @@ INCLUDES = -I.. -I. -I$(top_srcdir)/intl
all: all-@USE_INCLUDED_LIBINTL@
-all-yes: libintl.$la intlh.inst
+all-yes: libintl.a intlh.inst
all-no:
libintl.a: $(OBJECTS)
@@ -95,8 +95,8 @@ libintl.la: $(OBJECTS)
$(LIBTOOL) --mode=link $(CC) $(LDFLAGS) -o $@ $(OBJECTS) \
-version-info 1:0 -rpath $(libdir)
-../po/cat-id-tbl.$lo: ../po/cat-id-tbl.c $(top_srcdir)/po/$(PACKAGE).pot
- cd ../po && $(MAKE) cat-id-tbl.$lo
+../po/cat-id-tbl.o: ../po/cat-id-tbl.c $(top_srcdir)/po/$(PACKAGE).pot
+ cd ../po && $(MAKE) cat-id-tbl.o
check: all
@@ -151,8 +151,8 @@ uninstall:
info dvi:
$(OBJECTS): ../config.h libgettext.h
-bindtextdom.$lo finddomain.$lo loadmsgcat.$lo: gettextP.h gettext.h loadinfo.h
-dcgettext.$lo: gettextP.h gettext.h hash-string.h loadinfo.h
+bindtextdom.o finddomain.o loadmsgcat.o: gettextP.h gettext.h loadinfo.h
+dcgettext.o: gettextP.h gettext.h hash-string.h loadinfo.h
tags: TAGS
@@ -202,12 +202,8 @@ Makefile: Makefile.in ../config.status
# The dependency for intlh.inst is different in gettext and all other
# packages. Because we cannot you GNU make features we have to solve
# the problem while rewriting Makefile.in.
-@GT_YES@intlh.inst: intlh.inst.in ../config.status
-@GT_YES@ cd .. \
-@GT_YES@ && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= \
-@GT_YES@ $(SHELL) ./config.status
-@GT_NO@.PHONY: intlh.inst
-@GT_NO@intlh.inst:
+.PHONY: intlh.inst
+intlh.inst:
# Tell versions [3.59,3.63) of GNU make not to export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.