summaryrefslogtreecommitdiff
path: root/devel/libgetopt
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2004-01-05 09:31:31 +0000
committerjlam <jlam@pkgsrc.org>2004-01-05 09:31:31 +0000
commitc9ff27d2708681feb21548e2c9a385edb67a88bb (patch)
tree5e468c9c5f542e31226f7780d62182ff9f54b072 /devel/libgetopt
parent55945e26ef4106d1adfcde1f726943e6167e8fc2 (diff)
downloadpkgsrc-c9ff27d2708681feb21548e2c9a385edb67a88bb.tar.gz
Sow BUILDLINK_USE_BUILTIN.<pkg> and reap _NEED_<PKG> variables.
Diffstat (limited to 'devel/libgetopt')
-rw-r--r--devel/libgetopt/buildlink3.mk26
1 files changed, 12 insertions, 14 deletions
diff --git a/devel/libgetopt/buildlink3.mk b/devel/libgetopt/buildlink3.mk
index 392c92ebfbf..ce63a76dcee 100644
--- a/devel/libgetopt/buildlink3.mk
+++ b/devel/libgetopt/buildlink3.mk
@@ -1,9 +1,10 @@
-# $NetBSD: buildlink3.mk,v 1.2 2004/01/04 23:34:05 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.3 2004/01/05 09:31:31 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
GETOPT_BUILDLINK3_MK:= ${GETOPT_BUILDLINK3_MK}+
.if !empty(GETOPT_BUILDLINK3_MK:M+)
+BUILDLINK_PACKAGES+= getopt
BUILDLINK_DEPENDS.getopt?= libgetopt>=1.3
BUILDLINK_PKGSRCDIR.getopt?= ../../devel/libgetopt
.endif # GETOPT_BUILDLINK3_MK
@@ -18,37 +19,34 @@ BUILDLINK_IS_BUILTIN.getopt= YES
.endif
.if !empty(BUILDLINK_CHECK_BUILTIN.getopt:M[yY][eE][sS])
-_NEED_GETOPT= NO
+BUILDLINK_USE_BUILTIN.getopt= YES
.endif
-.if !defined(_NEED_GETOPT)
+.if !defined(BUILDLINK_USE_BUILTIN.getopt)
. if !empty(BUILDLINK_IS_BUILTIN.getopt:M[nN][oO])
-_NEED_GETOPT= YES
+BUILDLINK_USE_BUILTIN.getopt= NO
. else
-_NEED_GETOPT= NO
+BUILDLINK_USE_BUILTIN.getopt= YES
. endif
-MAKEFLAGS+= _NEED_GETOPT="${_NEED_GETOPT}"
.endif
-.if ${_NEED_GETOPT} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.getopt:M[nN][oO])
. if !empty(BUILDLINK_DEPTH:M+)
BUILDLINK_DEPENDS+= getopt
. endif
.endif
.if !empty(GETOPT_BUILDLINK3_MK:M+)
-. if ${_NEED_GETOPT} == "YES"
-BUILDLINK_PACKAGES+= getopt
-LIBGETOPT= -lgetopt
+. if !empty(BUILDLINK_USE_BUILTIN.getopt:M[nN][oO])
+LIBGETOPT= -lgetopt
. else
-BUILDLINK_PREFIX.getopt= /usr
-LIBGETOPT= # empty
+LIBGETOPT= # empty
. endif
BUILDLINK_LDADD.getopt?= ${LIBGETOPT}
-CONFIGURE_ENV+= LIBGETOPT="${LIBGETOPT}"
-MAKE_ENV+= LIBGETOPT="${LIBGETOPT}"
+CONFIGURE_ENV+= LIBGETOPT="${LIBGETOPT}"
+MAKE_ENV+= LIBGETOPT="${LIBGETOPT}"
.endif # GETOPT_BUILDLINK3_MK
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:C/\+$//}