ports/168046: textproc/chpp: Fix build on amd64

KATO Tsuguru tkato432 at yahoo.com
Thu May 17 18:10:13 UTC 2012


>Number:         168046
>Category:       ports
>Synopsis:       textproc/chpp: Fix build on amd64
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Thu May 17 18:10:09 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator:     KATO Tsuguru
>Release:        FreeBSD 7.4-RELEASE-p5 i386
>Organization:
>Environment:
>Description:
- Fix build on amd64
- Add LICENSE
- Add MAKE_JOBS_SAFE
- Support COPYTREE_SHARE

Remove file:
files/patch-ab

>How-To-Repeat:
>Fix:

diff -urN /usr/ports/textproc/chpp/Makefile textproc/chpp/Makefile
--- /usr/ports/textproc/chpp/Makefile	2007-07-02 19:18:19.000000000 +0900
+++ textproc/chpp/Makefile	2012-04-21 03:09:59.000000000 +0900
@@ -7,37 +7,57 @@
 
 PORTNAME=	chpp
 PORTVERSION=	0.3.5
+PORTREVISION=	1
 CATEGORIES=	textproc
-MASTER_SITES=	http://www.complang.tuwien.ac.at/~schani/chpp/files/ \
+MASTER_SITES=	http://www.complang.tuwien.ac.at/schani/chpp/files/ \
 		http://freebsd.nsu.ru/distfiles/
 
 MAINTAINER=	ports at FreeBSD.org
 COMMENT=	Non-intrusive full-featured text preprocessor
 
+LICENSE=	GPLv2
+
+LIB_DEPENDS=	gc.1:${PORTSDIR}/devel/boehm-gc
+
+USE_GMAKE=	yes
 GNU_CONFIGURE=	yes
 CONFIGURE_ARGS=	--libdir=${PREFIX}/share
+MAKE_JOBS_SAFE=	yes
+
+CPPFLAGS+=	-I${LOCALBASE}/include
+LDFLAGS+=	-L${LOCALBASE}/lib
 
 INFO=		chpp
 
 .include <bsd.port.pre.mk>
 
-.if ${ARCH} != "i386"
+.if ${ARCH} != "i386" && ${ARCH} != "amd64"
 BROKEN=		Does not compile
 .endif
 
+post-extract:
+	@${RM} -f ${WRKSRC}/gc/gc.h
+
+post-patch:
+	@${REINPLACE_CMD} -e \
+		'/LDADD/s|gc/gc.a|-lgc| ; \
+		 /LIBOBJS/s|gc/gc.a|| ; \
+		 s|gc/gc.h||' ${WRKSRC}/Makefile.in
+	@${REINPLACE_CMD} -e \
+		's|../gc/gc.h||' ${WRKSRC}/builtins/Makefile.in
+	@${REINPLACE_CMD} -e \
+		's|../../gc/gc.h||' ${WRKSRC}/builtins/database/Makefile.in
+
 post-install:
-.if !defined(NOPORTEXAMPLES)
-	@${MKDIR} ${EXAMPLESDIR}
-	${TAR} -C ${WRKSRC}/test -cf - . | \
-		${TAR} -C ${EXAMPLESDIR} --unlink -xf -
-	@${FIND} ${EXAMPLESDIR} | ${XARGS} ${CHOWN} ${SHAREOWN}:${SHAREGRP}
-	@${FIND} ${EXAMPLESDIR} -type f | ${XARGS} ${CHMOD} ${SHAREMODE}
-.endif
 .if !defined(NOPORTDOCS)
 	@${MKDIR} ${DOCSDIR}
 .for file in AUTHORS NEWS README
 	${INSTALL_DATA} ${WRKSRC}/${file} ${DOCSDIR}
 .endfor
 .endif
+.if !defined(NOPORTEXAMPLES)
+	@${MKDIR} ${EXAMPLESDIR}
+	@(cd ${WRKSRC}/test && ${COPYTREE_SHARE} . ${EXAMPLESDIR})
+.endif
 
 .include <bsd.port.post.mk>
diff -urN /usr/ports/textproc/chpp/files/patch-ab textproc/chpp/files/patch-ab
--- /usr/ports/textproc/chpp/files/patch-ab	2000-07-08 09:26:15.000000000 +0900
+++ textproc/chpp/files/patch-ab	1970-01-01 09:00:00.000000000 +0900
@@ -1,24 +0,0 @@
---- Makefile.in.orig	Tue Feb  9 23:02:50 1999
-+++ Makefile.in	Tue Jul  4 04:03:19 2000
-@@ -471,10 +471,10 @@
- 
- 
- gc/gc.a :
--	( cd gc ; make gc.a )
-+	( cd gc ; $(MAKE) gc.a )
- 
- dist-hook :
--	( cd gc ; make clean )
-+	( cd gc ; $(MAKE) clean )
- 	cp -dR gc $(distdir)
- 	rm -rf `find $(distdir)/gc -name CVS`
- 	mkdir $(distdir)/test
-@@ -484,7 +484,7 @@
- 	rm -rf `find $(distdir)/test -name CVS`
- 
- clean-gc :
--	( cd gc ; make clean )
-+	( cd gc ; $(MAKE) clean )
- 
- clean : clean-gc
- 
diff -urN /usr/ports/textproc/chpp/pkg-descr textproc/chpp/pkg-descr
--- /usr/ports/textproc/chpp/pkg-descr	2007-07-02 19:07:53.000000000 +0900
+++ textproc/chpp/pkg-descr	2012-04-20 23:43:12.000000000 +0900
@@ -17,4 +17,4 @@
      namely lists and hashes (associative arrays), which can be nested
      arbitrarily.
 
-WWW: http://www.complang.tuwien.ac.at/~schani/chpp/
+WWW: http://www.complang.tuwien.ac.at/schani/chpp/
>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list