Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 1 Dec 2013 23:21:51 +0100 (CET)
From:      Gerald Pfeifer <gerald@pfeifer.com>
To:        Mathieu Arnold <mat@FreeBSD.org>,  Kozlov Sergey <kozlov.sergey.404@gmail.com>,  Greg Larkin <glarkin@FreeBSD.org>
Cc:        svn-ports-head@freebsd.org, svn-ports-all@freebsd.org, ports-committers@freebsd.org
Subject:   Re: svn commit: r335189 - in head/print/pdftk: . files
Message-ID:  <alpine.LNX.2.00.1312012257230.2185@tuna.site>
In-Reply-To: <201311291548.rATFm8g7098382@svn.freebsd.org>
References:  <201311291548.rATFm8g7098382@svn.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 29 Nov 2013, Mathieu Arnold wrote:
> Log:
>   Updated port to pdftk-2.02
:
>    - Added LIB_DEPENDS. Libraries provided by gcc required to run the binary,
>      but gcc is registered only as build dependency. Removing the gcc after
>      installation of pdftk is permitted but breaks pdftk

This looks quite dubious since USE_GCC already takes care of 
registering this run-time dependency.

USE_GCC also takes care of the BUILD_DEPENDency, so the pre-existing
entry there also is unnecessary.

>   maintainer timeout.

This reminds me, I had submitted another patch in August 2012 (per
mail, not PR).  The -Wl,-path magic is not necessary and manually
constructing the path to the GCC run-time libraries is A Bad Idea[TM].
This is what ${LDFLAGS} is there for, and what the second, and more
important hunk, in my patch below does.

Can you guys please give the patch below a spin and review?

(Greg, explicit approval is preferred.)

Thanks,
Gerald

Index: Makefile
===================================================================
--- Makefile	(revision 335437)
+++ Makefile	(working copy)
@@ -12,14 +12,6 @@
 
 LICENSE=	GPLv2
 
-LIB_DEPENDS=	libgcj.so:${PORTSDIR}/lang/gcc${CSUFF} \
-		libstdc++.so:${PORTSDIR}/lang/gcc${CSUFF} \
-		libgcc_s.so:${PORTSDIR}/lang/gcc${CSUFF}
-
-BUILD_DEPENDS=	gcj${CSUFF}:${PORTSDIR}/lang/gcc${CSUFF} \
-		gcjh${CSUFF}:${PORTSDIR}/lang/gcc${CSUFF} \
-		cpp${CSUFF}:${PORTSDIR}/lang/gcc${CSUFF}
-
 USE_ZIP=	yes
 
 # Get GCC version suffix without the dot in USE_GCC
@@ -44,8 +36,8 @@
 post-patch:
 	@${REINPLACE_CMD} -e "s|TOOLPATH=|TOOLPATH=${LOCALBASE}/bin/|g" ${WRKSRC}/${MAKEFILE}
 	@${REINPLACE_CMD} -e "s|VERSUFF=|VERSUFF=${CSUFF}|g" ${WRKSRC}/${MAKEFILE}
-	@${REINPLACE_CMD} -e "s|GCJFLAGS=|GCJFLAGS= -L${LOCALBASE}/lib -Wl,-rpath=${LOCALBASE}/lib/gcc${CSUFF} -w|g" ${WRKSRC}/${MAKEFILE}
-	@${REINPLACE_CMD} -e "s|LDLIBS= -lgcj|LDLIBS= -lgcj ${PTHREAD_CFLAGS} ${PTHREAD_LIBS} ${ICONV_LIB} -lz -L${LOCALBASE}/lib -Wl,-rpath=${LOCALBASE}/lib/gcc${CSUFF} -w|g" \
+	@${REINPLACE_CMD} -e "s|GCJFLAGS=|GCJFLAGS= -L${LOCALBASE}/lib ${LDFLAGS} -w|g" ${WRKSRC}/${MAKEFILE}
+	@${REINPLACE_CMD} -e "s|LDLIBS= -lgcj|LDLIBS= -lgcj ${PTHREAD_CFLAGS} ${PTHREAD_LIBS} ${ICONV_LIB} -lz -L${LOCALBASE}/lib ${LDFLAGS} -w|g" \
 			${WRKSRC}/${MAKEFILE}
 
 do-install:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?alpine.LNX.2.00.1312012257230.2185>