summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2004-03-11 08:36:41 +0000
committerjlam <jlam@pkgsrc.org>2004-03-11 08:36:41 +0000
commit12d273cd9dd3389d06f33b22f2b2c598c305edb9 (patch)
treebd3de7eef574e188de6d962aa73fe57732375fca /mk
parent6307bde7a7258ed4e5753e449b7a171bbd37c29b (diff)
downloadpkgsrc-12d273cd9dd3389d06f33b22f2b2c598c305edb9.tar.gz
Check that a variable is defined before using it.
BUILDLINK_PKGSRCDIR.<pkg> may not be defined since <pkg> may refer to a dummy package, e.g. "db-native" as set by bdb.buildlink3.mk.
Diffstat (limited to 'mk')
-rw-r--r--mk/buildlink3/bsd.buildlink3.mk8
1 files changed, 5 insertions, 3 deletions
diff --git a/mk/buildlink3/bsd.buildlink3.mk b/mk/buildlink3/bsd.buildlink3.mk
index 0e3c300fdad..d261d067c28 100644
--- a/mk/buildlink3/bsd.buildlink3.mk
+++ b/mk/buildlink3/bsd.buildlink3.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.buildlink3.mk,v 1.111 2004/03/11 06:32:58 jlam Exp $
+# $NetBSD: bsd.buildlink3.mk,v 1.112 2004/03/11 08:36:41 jlam Exp $
#
# An example package buildlink3.mk file:
#
@@ -116,10 +116,12 @@ USE_BUILTIN.${_pkg_}?= no
# We can then check for this value to avoid build loops.
#
.for _pkg_ in ${BUILDLINK_PACKAGES}
-. if !defined(IGNORE_PKG.${_pkg_}) && \
- (${BUILDLINK_PKGSRCDIR.${_pkg_}:C|.*/([^/]*/[^/]*)$|\1|} == ${PKGPATH})
+. if defined(BUILDLINK_PKGSRCDIR.${_pkg_})
+. if !defined(IGNORE_PKG.${_pkg_}) && \
+ (${BUILDLINK_PKGSRCDIR.${_pkg_}:C|.*/([^/]*/[^/]*)$|\1|} == ${PKGPATH})
IGNORE_PKG.${_pkg_}= yes
MAKEFLAGS+= IGNORE_PKG.${_pkg_}=${IGNORE_PKG.${_pkg_}}
+. endif
. endif
.endfor