diff options
author | jlam <jlam@pkgsrc.org> | 2004-02-21 10:35:57 +0000 |
---|---|---|
committer | jlam <jlam@pkgsrc.org> | 2004-02-21 10:35:57 +0000 |
commit | 0af79f88faca078e7314fc3d872a1a6050828172 (patch) | |
tree | 6a059d62453dab5da35da8eef0568bc95ecf6eee /mk | |
parent | e021a3c19870013d9482d13ed7087716d0072231 (diff) | |
download | pkgsrc-0af79f88faca078e7314fc3d872a1a6050828172.tar.gz |
Pass LDFLAGS (minus any libraries) to the compiler when creating the
trivial libtool archive.
Diffstat (limited to 'mk')
-rw-r--r-- | mk/buildlink2/bsd.buildlink2.mk | 5 | ||||
-rw-r--r-- | mk/buildlink2/fake-la | 4 |
2 files changed, 5 insertions, 4 deletions
diff --git a/mk/buildlink2/bsd.buildlink2.mk b/mk/buildlink2/bsd.buildlink2.mk index 7c844e148fa..78c0b1c1681 100644 --- a/mk/buildlink2/bsd.buildlink2.mk +++ b/mk/buildlink2/bsd.buildlink2.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.buildlink2.mk,v 1.119 2004/02/18 14:23:43 jlam Exp $ +# $NetBSD: bsd.buildlink2.mk,v 1.120 2004/02/21 10:35:57 jlam Exp $ # # An example package buildlink2.mk file: # @@ -195,7 +195,7 @@ do-buildlink: buildlink-wrappers buildlink-${_BLNK_OPSYS}-wrappers # buildlink target. This ensures that the symlinks are created # before any configure scripts or build commands are called. # -.for _target_ in ${BUILDLINK_TARGETS} +.for _target_ in ${BUILDLINK_PRE_TARGETS} ${BUILDLINK_TARGETS} do-buildlink: ${_target_} .endfor @@ -859,6 +859,7 @@ ${_BLNK_FAKE_LA}: ${.CURDIR}/../../mk/buildlink2/fake-la -e "s|@AWK@|${AWK:Q}|g" \ -e "s|@BASENAME@|${BASENAME:Q}|g" \ -e "s|@CC@|${BUILDLINK_CC:Q}|g" \ + -e "s|@LDFLAGS@|${LDFLAGS:N-l*:Q}|g" \ -e "s|@CP@|${CP:Q}|g" \ -e "s|@DIRNAME@|${DIRNAME:Q}|g" \ -e "s|@ECHO@|${ECHO:Q}|g" \ diff --git a/mk/buildlink2/fake-la b/mk/buildlink2/fake-la index 52cbd9ff71d..78ddee08b1a 100644 --- a/mk/buildlink2/fake-la +++ b/mk/buildlink2/fake-la @@ -1,6 +1,6 @@ #!@BUILDLINK_SHELL@ # -# $NetBSD: fake-la,v 1.10 2004/02/05 09:57:53 jlam Exp $ +# $NetBSD: fake-la,v 1.11 2004/02/21 10:35:57 jlam Exp $ AR="@AR@" AWK="@AWK@" @@ -84,7 +84,7 @@ if ${TEST} ! -f $tmpdir/inst/$libbase.la; then cd $tmpdir ${ECHO} "static int i;" > nonempty.c # create a nonempty input file ${LIBTOOL} --mode=compile ${CC} -c nonempty.c - ${LIBTOOL} --mode=link ${CC} -o $libbase.la nonempty.lo -rpath $tmpdir/inst -version-info $version + ${LIBTOOL} --mode=link ${CC} @LDFLAGS@ -o $libbase.la nonempty.lo -rpath $tmpdir/inst -version-info $version ${LIBTOOL} --mode=install ${CP} $libbase.la $tmpdir/inst >/dev/null # Reset the ld.so cache as "libtool --mode=install" may have executed |