summaryrefslogtreecommitdiff
path: root/mk/dlopen.builtin.mk
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2004-12-02 15:04:16 +0000
committerjlam <jlam@pkgsrc.org>2004-12-02 15:04:16 +0000
commit6c02e9e0aa86d3b1e738d4e84d85dbbe9ad2b193 (patch)
tree16fbc9e3fb70fdd69b2d3e6f920256940bb0fc6e /mk/dlopen.builtin.mk
parent0fec2dc7323d3a3d63a48fb7f724d6888d68679f (diff)
downloadpkgsrc-6c02e9e0aa86d3b1e738d4e84d85dbbe9ad2b193.tar.gz
If we're using the builtin dlopen(), and libdl.* doesn't exist, then
drop the "-ldl" option on the floor. This "fixes" packages that hardcode "-ldl" into the command line when linking software.
Diffstat (limited to 'mk/dlopen.builtin.mk')
-rw-r--r--mk/dlopen.builtin.mk4
1 files changed, 3 insertions, 1 deletions
diff --git a/mk/dlopen.builtin.mk b/mk/dlopen.builtin.mk
index 809e0d0fee1..a254e94f302 100644
--- a/mk/dlopen.builtin.mk
+++ b/mk/dlopen.builtin.mk
@@ -1,4 +1,4 @@
-# $NetBSD: dlopen.builtin.mk,v 1.6 2004/11/28 05:44:34 jlam Exp $
+# $NetBSD: dlopen.builtin.mk,v 1.7 2004/12/02 15:04:16 jlam Exp $
.for _lib_ in dl
. if !defined(_BLNK_LIB_FOUND.${_lib_})
@@ -71,6 +71,8 @@ BUILDLINK_PREFIX.dl= /usr
# scripts already check for -ldl themselves.
#
BUILDLINK_LDADD.dl= -ldl
+. else
+BUILDLINK_TRANSFORM+= rm:-ldl
. endif
. if !empty(_DLOPEN_REQUIRE_PTHREADS:M[yY][eE][sS])
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+