summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--archivers/bzip2/buildlink3.mk31
-rw-r--r--converters/libiconv/buildlink3.mk34
-rw-r--r--databases/db/buildlink3.mk22
-rw-r--r--devel/binutils/buildlink3.mk29
-rw-r--r--devel/gettext-lib/buildlink3.mk37
-rw-r--r--devel/libgetopt/buildlink3.mk26
-rw-r--r--devel/ncurses/buildlink3.mk48
-rw-r--r--devel/zlib/buildlink3.mk36
-rw-r--r--graphics/MesaLib/buildlink3.mk39
-rw-r--r--graphics/freetype2/buildlink3.mk35
-rw-r--r--graphics/glu/buildlink3.mk35
-rw-r--r--graphics/xpm/buildlink3.mk35
-rw-r--r--net/libpcap/buildlink3.mk26
-rw-r--r--security/PAM/buildlink3.mk26
-rw-r--r--security/openssl/buildlink3.mk36
-rw-r--r--security/tcp_wrappers/buildlink3.mk26
-rw-r--r--x11/Xrender/buildlink3.mk36
17 files changed, 257 insertions, 300 deletions
diff --git a/archivers/bzip2/buildlink3.mk b/archivers/bzip2/buildlink3.mk
index 1faa397e43a..1a6ea30b985 100644
--- a/archivers/bzip2/buildlink3.mk
+++ b/archivers/bzip2/buildlink3.mk
@@ -1,11 +1,12 @@
-# $NetBSD: buildlink3.mk,v 1.2 2004/01/04 23:34:04 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.3 2004/01/05 09:31:31 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
BZIP2_BUILDLINK3_MK:= ${BZIP2_BUILDLINK3_MK}+
-.if !empty(BZIP2_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
+.include "../../mk/bsd.prefs.mk"
+.if !empty(BZIP2_BUILDLINK3_MK:M+)
+BUILDLINK_PACKAGES+= bzip2
BUILDLINK_DEPENDS.bzip2?= bzip2>=1.0.1
BUILDLINK_PKGSRCDIR.bzip2?= ../../archivers/bzip2
.endif # BZIP2_BUILDLINK3_MK
@@ -26,18 +27,18 @@ MAKEFLAGS+= BUILDLINK_IS_BUILTIN.bzip2=${BUILDLINK_IS_BUILTIN.bzip2}
.endif
.if defined(USE_BZIP2)
-_NEED_BZIP2= YES
+BUILDLINK_USE_BUILTIN.bzip2= NO
.endif
.if !empty(BUILDLINK_CHECK_BUILTIN.bzip2:M[yY][eE][sS])
-_NEED_BZIP2= NO
+BUILDLINK_USE_BUILTIN.bzip2= YES
.endif
-.if !defined(_NEED_BZIP2)
+.if !defined(BUILDLINK_USE_BUILTIN.bzip2)
. if !empty(BUILDLINK_IS_BUILTIN.bzip2:M[nN][oO])
-_NEED_BZIP2= YES
+BUILDLINK_USE_BUILTIN.bzip2= NO
. else
-_NEED_BZIP2= NO
+BUILDLINK_USE_BUILTIN.bzip2= YES
#
# Solaris 9 has bzip2 1.0.1, build it on older versions.
# Darwin only has static libbz2.a, which can't be buildlinked.
@@ -46,25 +47,17 @@ _INCOMPAT_BZIP2= SunOS-5.[678]-* Darwin-*
INCOMPAT_BZIP2?= # empty
. for _pattern_ in ${_INCOMPAT_BZIP2} ${INCOMPAT_BZIP2}
. if !empty(MACHINE_PLATFORM:M${_pattern_})
-_NEED_BZIP2= YES
+BUILDLINK_USE_BUILTIN.bzip2= NO
. endif
. endfor
. endif
-MAKEFLAGS+= _NEED_BZIP2="${_NEED_BZIP2}"
+MAKEFLAGS+= BUILDLINK_USE_BUILTIN.bzip2="${BUILDLINK_USE_BUILTIN.bzip2}"
.endif
-.if ${_NEED_BZIP2} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.bzip2:M[nN][oO])
. if !empty(BUILDLINK_DEPTH:M+)
BUILDLINK_DEPENDS+= bzip2
. endif
.endif
-.if !empty(BZIP2_BUILDLINK3_MK:M+)
-. if ${_NEED_BZIP2} == "YES"
-BUILDLINK_PACKAGES+= bzip2
-. else
-BUILDLINK_PREFIX.bzip2= /usr
-. endif
-.endif # BZIP2_BUILDLINK3_MK
-
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:C/\+$//}
diff --git a/converters/libiconv/buildlink3.mk b/converters/libiconv/buildlink3.mk
index 81991203b5c..e6a874b5ec8 100644
--- a/converters/libiconv/buildlink3.mk
+++ b/converters/libiconv/buildlink3.mk
@@ -1,11 +1,12 @@
-# $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}+
ICONV_BUILDLINK3_MK:= ${ICONV_BUILDLINK3_MK}+
-.if !empty(ICONV_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
+.include "../../mk/bsd.prefs.mk"
+.if !empty(ICONV_BUILDLINK3_MK:M+)
+BUILDLINK_PACKAGES+= iconv
BUILDLINK_DEPENDS.iconv?= libiconv>=1.9.1
BUILDLINK_PKGSRCDIR.iconv?= ../../converters/libiconv
.endif # ICONV_BUILDLINK3_MK
@@ -19,38 +20,38 @@ BUILDLINK_IS_BUILTIN.iconv= YES
. endif
.endif
+.if defined(USE_GNU_ICONV)
+BUILDLINK_USE_BUILTIN.iconv= NO
+.endif
+
.if !empty(BUILDLINK_CHECK_BUILTIN.iconv:M[yY][eE][sS])
-_NEED_GNU_ICONV= NO
+BUILDLINK_USE_BUILTIN.iconv= YES
.endif
-.if !defined(_NEED_GNU_ICONV)
+.if !defined(BUILDLINK_USE_BUILTIN.iconv)
. if !empty(BUILDLINK_IS_BUILTIN.iconv:M[nN][oO])
-_NEED_GNU_ICONV= YES
+BUILDLINK_USE_BUILTIN.iconv= NO
. else
-_NEED_GNU_ICONV= NO
+BUILDLINK_USE_BUILTIN.iconv= YES
_INCOMPAT_ICONV?= # should be set from defs.${OPSYS}.mk
INCOMPAT_ICONV?= # empty
. for _pattern_ in ${_INCOMPAT_ICONV} ${INCOMPAT_ICONV}
. if !empty(MACHINE_PLATFORM:M${_pattern_})
-_NEED_GNU_ICONV= YES
+BUILDLINK_USE_BUILTIN.iconv= NO
. endif
. endfor
. endif
-. if defined(USE_GNU_ICONV)
-_NEED_GNU_ICONV= YES
-. endif
-MAKEFLAGS+= _NEED_GNU_ICONV=${_NEED_GNU_ICONV}
+MAKEFLAGS+= BUILDLINK_USE_BUILTIN.iconv="${BUILDLINK_USE_BUILTIN.iconv}"
.endif
-.if ${_NEED_GNU_ICONV} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.iconv:M[nN][oO])
. if !empty(BUILDLINK_DEPTH:M+)
BUILDLINK_DEPENDS+= iconv
. endif
.endif
.if !empty(ICONV_BUILDLINK3_MK:M+)
-. if ${_NEED_GNU_ICONV} == "YES"
-BUILDLINK_PACKAGES+= iconv
+. if !empty(BUILDLINK_USE_BUILTIN.iconv:M[nN][oO])
_BLNK_LIBICONV= -liconv
. else
. if !defined(_BLNK_LIBICONV_FOUND)
@@ -69,11 +70,10 @@ _BLNK_LIBICONV= # empty
BUILDLINK_TRANSFORM+= S:-liconv:
. endif
BUILDLINK_LDADD.iconv?= ${_BLNK_LIBICONV}
-BUILDLINK_PREFIX.iconv= /usr
. endif
. if defined(GNU_CONFIGURE)
-. if ${_NEED_GNU_ICONV} == "YES"
+. if !empty(BUILDLINK_USE_BUILTIN.iconv:M[nN][oO])
CONFIGURE_ARGS+= --with-libiconv-prefix=${BUILDLINK_PREFIX.iconv}
. else
CONFIGURE_ARGS+= --without-libiconv-prefix
diff --git a/databases/db/buildlink3.mk b/databases/db/buildlink3.mk
index fbb6638add0..2136defaad3 100644
--- a/databases/db/buildlink3.mk
+++ b/databases/db/buildlink3.mk
@@ -1,4 +1,4 @@
-# $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}+
DB2_BUILDLINK3_MK:= ${DB2_BUILDLINK3_MK}+
@@ -9,30 +9,28 @@ BUILDLINK_DEPENDS.db?= db>=2.7.3
BUILDLINK_PKGSRCDIR.db?= ../../databases/db
.endif # DB2_BUILDLINK3_MK
-.if !defined(_NEED_DB2)
-_NEED_DB2= YES
+.if !defined(BUILDLINK_USE_BUILTIN.db)
+BUILDLINK_USE_BUILTIN.db= NO
. if defined(USE_DB185)
. if exists(/usr/include/db.h) # NetBSD, Darwin
-BUILDLINK_PREFIX.db= /usr
-_NEED_DB2= NO
+BUILDLINK_USE_BUILTIN.db= YES
. elif exists(/usr/include/db1/db.h) # Linux
-BUILDLINK_PREFIX.db= /usr
-BUILDLINK_INCDIRS.db= include/db1
-BUILDLINK_TRANSFORM+= l:db:db1
-_NEED_DB2= NO
+BUILDLINK_USE_BUILTIN.db= YES
+BUILDLINK_INCDIRS.db?= include/db1
+BUILDLINK_TRANSFORM+= l:db:db1
. endif
. endif
-MAKEFLAGS+= _NEED_DB2="${_NEED_DB2}"
+MAKEFLAGS+= BUILDLINK_USE_BUILTIN.db="${BUILDLINK_USE_BUILTIN.db}"
.endif
-.if ${_NEED_DB2} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.db:M[nN][oO])
. if !empty(BUILDLINK_DEPTH:M+)
BUILDLINK_DEPENDS+= db
. endif
.endif
.if !empty(DB2_BUILDLINK3_MK:M+)
-. if ${_NEED_DB2} == "YES"
+. if !empty(BUILDLINK_USE_BUILTIN.db:M[nN][oO])
BUILDLINK_INCDIRS.db= include/db2
BUILDLINK_TRANSFORM+= l:db:db2
. endif
diff --git a/devel/binutils/buildlink3.mk b/devel/binutils/buildlink3.mk
index b1c4bbb1ba6..c5dbab449e4 100644
--- a/devel/binutils/buildlink3.mk
+++ b/devel/binutils/buildlink3.mk
@@ -1,14 +1,12 @@
-# $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}+
BINUTILS_BUILDLINK3_MK:= ${BINUTILS_BUILDLINK3_MK}+
-.if !defined(BINUTILS_BUILDLINK3_MK)
-BINUTILS_BUILDLINK3_MK= # defined
+.include "../../mk/bsd.prefs.mk"
.if !empty(BINUTILS_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
-
+BUILDLINK_PACKAGES+= binutils
BUILDLINK_DEPENDS.binutils?= binutils>=2.14.0
BUILDLINK_PKGSRCDIR.binutils?= ../../devel/binutils
BUILDLINK_DEPMETHOD.binutils?= build
@@ -21,18 +19,18 @@ BUILDLINK_IS_BUILTIN.binutils= YES
.endif
.if defined(USE_BINUTILS)
-_NEED_BINUTILS= YES
+BUILDLINK_USE_BUILTIN.binutils= NO
.endif
.if !empty(BUILDLINK_CHECK_BUILTIN.binutils:M[yY][eE][sS])
-_NEED_BINUTILS= NO
+BUILDLINK_USE_BUILTIN.binutils= YES
.endif
-.if !defined(_NEED_BINUTILS)
+.if !defined(BUILDLINK_USE_BUILTIN.binutils)
. if !empty(BUILDLINK_IS_BUILTIN.binutils:M[nN][oO])
-_NEED_BINUTILS= YES
+BUILDLINK_USE_BUILTIN.binutils= NO
. else
-_NEED_BINUTILS= NO
+BUILDLINK_USE_BUILTIN.binutils= YES
#
# These versions of NetBSD didn't have a toolchain that was capable of
# replacing binutils.
@@ -46,23 +44,22 @@ _INCOMPAT_BINUTILS+= NetBSD-1.5.*-* NetBSD-1.5[A-X]-*
INCOMPAT_BINUTILS?= # empty
. for _pattern_ in ${_INCOMPAT_BINUTILS} ${INCOMPAT_BINUTILS}
. if !empty(MACHINE_PLATFORM:M${_pattern_})
-_NEED_BINUTILS= YES
+BUILDLINK_USE_BUILTIN.binutils= NO
. endif
. endfor
. endif
-MAKEFLAGS+= _NEED_BINUTILS="${_NEED_BINUTILS}"
+MAKEFLAGS+= \
+ BUILDLINK_USE_BUILTIN.binutils="${BUILDLINK_USE_BUILTIN.binutils}"
.endif
-.if ${_NEED_BINUTILS} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.binutils:M[nN][oO])
. if !empty(BUILDLINK_DEPTH:M+)
BUILDLINK_DEPENDS+= binutils
. endif
.endif
.if !empty(BINUTILS_BUILDLINK3_MK:M+)
-. if ${_NEED_BINUTILS} == "YES"
-BUILDLINK_PACKAGES+= binutils
-
+. if !empty(BUILDLINK_USE_BUILTIN.binutils:M[nN][oO])
AR= ${BUILDLINK_PREFIX.binutils}/bin/ar
AS= ${BUILDLINK_PREFIX.binutils}/bin/as
LD= ${BUILDLINK_PREFIX.binutils}/bin/ld
diff --git a/devel/gettext-lib/buildlink3.mk b/devel/gettext-lib/buildlink3.mk
index 1f6f13c0f25..875a1cbc947 100644
--- a/devel/gettext-lib/buildlink3.mk
+++ b/devel/gettext-lib/buildlink3.mk
@@ -1,11 +1,12 @@
-# $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}+
GETTEXT_BUILDLINK3_MK:= ${GETTEXT_BUILDLINK3_MK}+
-.if !empty(GETTEXT_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
+.include "../../mk/bsd.prefs.mk"
+.if !empty(GETTEXT_BUILDLINK3_MK:M+)
+BUILDLINK_PACKAGES+= gettext
BUILDLINK_DEPENDS.gettext?= gettext-lib>=0.10.35nb1
BUILDLINK_PKGSRCDIR.gettext?= ../../devel/gettext-lib
.endif # GETTEXT_BUILDLINK3_MK
@@ -19,24 +20,28 @@ BUILDLINK_IS_BUILTIN.gettext= YES
. endif
.endif
+.if defined(USE_GNU_GETTEXT)
+BUILDLINK_USE_BUILTIN.gettext= NO
+.endif
+
.if !empty(BUILDLINK_CHECK_BUILTIN.gettext:M[yY][eE][sS])
-_NEED_GNU_GETTEXT= NO
+BUILDLINK_USE_BUILTIN.gettext= YES
.endif
-.if !defined(_NEED_GNU_GETTEXT)
+.if !defined(BUILDLINK_USE_BUILTIN.gettext)
. if !empty(BUILDLINK_IS_BUILTIN.gettext:M[nN][oO])
-_NEED_GNU_GETTEXT= YES
+BUILDLINK_USE_BUILTIN.gettext= NO
. else
#
# Consider the base system libintl to be gettext-lib-0.10.35nb1.
#
_GETTEXT_PKG= gettext-lib-0.10.35nb1
_GETTEXT_DEPENDS= ${BUILDLINK_DEPENDS.gettext}
-_NEED_GNU_GETTEXT!= \
+BUILDLINK_USE_BUILTIN.gettext!= \
if ${PKG_ADMIN} pmatch '${_GETTEXT_DEPENDS}' ${_GETTEXT_PKG}; then \
- ${ECHO} "NO"; \
- else \
${ECHO} "YES"; \
+ else \
+ ${ECHO} "NO"; \
fi
#
# The listed platforms have a broken (for the purposes of pkgsrc) version
@@ -46,11 +51,12 @@ _INCOMPAT_GETTEXT= SunOS-*-*
INCOMPAT_GETTEXT?= # empty
. for _pattern_ in ${_INCOMPAT_GETTEXT} ${INCOMPAT_GETTEXT}
. if !empty(MACHINE_PLATFORM:M${_pattern_})
-_NEED_GNU_GETTEXT= YES
+BUILDLINK_USE_BUILTIN.gettext= NO
. endif
. endfor
. endif
-MAKEFLAGS+= _NEED_GNU_GETTEXT=${_NEED_GNU_GETTEXT}
+MAKEFLAGS+= \
+ BUILDLINK_USE_BUILTIN.gettext="${BUILDLINK_USE_BUILTIN.gettext}"
.endif
.if !defined(_BLNK_LIBINTL_FOUND)
@@ -63,15 +69,14 @@ _BLNK_LIBINTL_FOUND!= \
MAKEFLAGS+= _BLNK_LIBINTL_FOUND=${_BLNK_LIBINTL_FOUND}
.endif
-.if ${_NEED_GNU_GETTEXT} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.gettext:M[nN][oO])
. if !empty(BUILDLINK_DEPTH:M+)
BUILDLINK_DEPENDS+= gettext
. endif
.endif
.if !empty(GETTEXT_BUILDLINK3_MK:M+)
-. if ${_NEED_GNU_GETTEXT} == "YES"
-BUILDLINK_PACKAGES+= gettext
+. if !empty(BUILDLINK_USE_BUILTIN.gettext:M[nN][oO])
_BLNK_LIBINTL= -lintl
_GETTEXT_ICONV_DEPENDS= gettext-lib>=0.11.5nb1
. if !defined(_GETTEXT_NEEDS_ICONV)
@@ -113,12 +118,12 @@ BUILDLINK_LDADD.gettext?= ${_BLNK_LIBINTL}
. if defined(GNU_CONFIGURE)
LIBS+= ${BUILDLINK_LDADD.gettext}
CONFIGURE_ENV+= INTLLIBS="${BUILDLINK_LDADD.gettext}"
-. if ${_NEED_GNU_GETTEXT} == "NO"
+. if !empty(BUILDLINK_USE_BUILTIN.gettext:M[yY][eE][sS])
. if ${_BLNK_LIBINTL_FOUND} == "YES"
CONFIGURE_ENV+= gt_cv_func_gnugettext1_libintl="yes"
. endif
. endif
-. if ${_NEED_GNU_GETTEXT} == "YES"
+. if !empty(BUILDLINK_USE_BUILTIN.gettext:M[nN][oO])
CONFIGURE_ARGS+= --with-libintl-prefix=${BUILDLINK_PREFIX.gettext}
. else
CONFIGURE_ARGS+= --without-libintl-prefix
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/\+$//}
diff --git a/devel/ncurses/buildlink3.mk b/devel/ncurses/buildlink3.mk
index f65853605b6..181f32b7d3e 100644
--- a/devel/ncurses/buildlink3.mk
+++ b/devel/ncurses/buildlink3.mk
@@ -1,27 +1,18 @@
-# $NetBSD: buildlink3.mk,v 1.2 2004/01/04 23:34:05 jlam Exp $
-#
-# Optionally define:
-#
-# USE_NCURSES force use of ncurses
-# INCOMPAT_CURSES specify MACHINE_PLATFORM versions that are missing
-# some needed functions.
+# $NetBSD: buildlink3.mk,v 1.3 2004/01/05 09:31:31 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
NCURSES_BUILDLINK3_MK:= ${NCURSES_BUILDLINK3_MK}+
-.if !empty(NCURSES_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
+.include "../../mk/bsd.prefs.mk"
+.if !empty(NCURSES_BUILDLINK3_MK:M+)
+BUILDLINK_PACKAGES+= ncurses
BUILDLINK_DEPENDS.ncurses?= ncurses>=5.3nb1
BUILDLINK_PKGSRCDIR.ncurses?= ../../devel/ncurses
.endif # NCURSES_BUILDLINK3_MK
BUILDLINK_CHECK_BUILTIN.ncurses?= NO
-.if !defined(BUILDLINK_IS_BUILTIN.ncurses)
-BUILDLINK_IS_BUILTIN.ncurses= NO
-.endif
-
.if !defined(_BLNK_LIBNCURSES_FOUND)
_BLNK_LIBNCURSES_FOUND!= \
if [ "`${ECHO} /usr/lib/libncurses.*`" = "/usr/lib/libncurses.*" ]; then \
@@ -32,17 +23,24 @@ _BLNK_LIBNCURSES_FOUND!= \
MAKEFLAGS+= _BLNK_LIBNCURSES_FOUND=${_BLNK_LIBNCURSES_FOUND}
.endif
-.if ${_BLNK_LIBNCURSES_FOUND} == "YES"
+.if !defined(BUILDLINK_IS_BUILTIN.ncurses)
+BUILDLINK_IS_BUILTIN.ncurses= NO
+. if ${_BLNK_LIBNCURSES_FOUND} == "YES"
BUILDLINK_IS_BUILTIN.ncurses= YES
+. endif
+.endif
+
+.if defined(USE_NCURSES)
+BUILDLINK_USE_BUILTIN.ncurses= NO
.endif
.if !empty(BUILDLINK_CHECK_BUILTIN.ncurses:M[yY][eE][sS])
-_NEED_NCURSES= NO
+BUILDLINK_USE_BUILTIN.ncurses= YES
.endif
-.if !defined(_NEED_NCURSES)
+.if !defined(BUILDLINK_USE_BUILTIN.ncurses)
. if !empty(BUILDLINK_IS_BUILTIN.ncurses:M[nN][oO])
-_NEED_NCURSES= NO
+BUILDLINK_USE_BUILTIN.ncurses= YES
. else
#
# These versions of NetBSD didn't have a curses library that was capable of
@@ -61,24 +59,22 @@ _INCOMPAT_CURSES+= Darwin-*-*
INCOMPAT_CURSES?= # empty
. for _pattern_ in ${_INCOMPAT_CURSES} ${INCOMPAT_CURSES}
. if !empty(MACHINE_PLATFORM:M${_pattern_})
-_NEED_NCURSES= YES
+BUILDLINK_USE_BUILTIN.ncurses= NO
. endif
. endfor
. endif
-MAKEFLAGS+= _NEED_NCURSES="${_NEED_NCURSES}"
+MAKEFLAGS+= \
+ BUILDLINK_USE_BUILTIN.ncurses="${BUILDLINK_USE_BUILTIN.ncurses}"
.endif
-.if ${_NEED_NCURSES} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.ncurses:M[nN][oO])
. if !empty(BUILDLINK_DEPTH:M+)
BUILDLINK_DEPENDS+= ncurses
. endif
.endif
.if !empty(NCURSES_BUILDLINK3_MK:M+)
-. if ${_NEED_NCURSES} == "YES"
-BUILDLINK_PACKAGES+= ncurses
-. else
-BUILDLINK_PREFIX.ncurses= /usr
+. if !empty(BUILDLINK_USE_BUILTIN.ncurses:M[yY][eE][sS])
. if ${_BLNK_LIBNCURSES_FOUND} == "NO"
BUILDLINK_TRANSFORM.ncurses+= -e "s|/curses.h|/ncurses.h|g"
BUILDLINK_TRANSFORM+= l:ncurses:curses
@@ -94,9 +90,7 @@ BUILDLINK_TARGETS+= buildlink-ncurses-extra-includes
.PHONY: buildlink-ncurses-extra-includes
buildlink-ncurses-extra-includes:
${_PKG_SILENT}${_PKG_DEBUG} \
- extra_includes=" \
- include/term.h \
- "; \
+ extra_includes="include/term.h"; \
for f in $${extra_includes}; do \
if [ ! -f ${BUILDLINK_DIR}/$${f} ]; then \
${ECHO_BUILDLINK_MSG} "Touching extra ncurses header ($${f}) in ${BUILDLINK_DIR}."; \
diff --git a/devel/zlib/buildlink3.mk b/devel/zlib/buildlink3.mk
index 0db3114fbac..5017d389e26 100644
--- a/devel/zlib/buildlink3.mk
+++ b/devel/zlib/buildlink3.mk
@@ -1,11 +1,12 @@
-# $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}+
ZLIB_BUILDLINK3_MK:= ${ZLIB_BUILDLINK3_MK}+
-.if !empty(ZLIB_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
+.include "../../mk/bsd.prefs.mk"
+.if !empty(ZLIB_BUILDLINK3_MK:M+)
+BUILDLINK_PACKAGES+= zlib
BUILDLINK_DEPENDS.zlib?= zlib>=1.1.4nb1
BUILDLINK_PKGSRCDIR.zlib?= ../../devel/zlib
.endif # ZLIB_BUILDLINK3_MK
@@ -19,15 +20,19 @@ BUILDLINK_IS_BUILTIN.zlib= YES
. endif
.endif
+.if defined(USE_ZLIB)
+BUILDLINK_USE_BUILTIN.zlib= NO
+.endif
+
.if !empty(BUILDLINK_CHECK_BUILTIN.zlib:M[yY][eE][sS])
-_NEED_ZLIB= NO
+BUILDLINK_USE_BUILTIN.zlib= YES
.endif
-.if !defined(_NEED_ZLIB)
+.if !defined(BUILDLINK_USE_BUILTIN.zlib)
. if !empty(BUILDLINK_IS_BUILTIN.zlib:M[nN][oO])
-_NEED_ZLIB= YES
+BUILDLINK_USE_BUILTIN.zlib= NO
. else
-_NEED_ZLIB= NO
+BUILDLINK_USE_BUILTIN.zlib= YES
#
# The listed platforms have a broken (for the purposes of pkgsrc) version
# of this package.
@@ -45,28 +50,17 @@ _INCOMPAT_ZLIB+= NetBSD-1.3-* NetBSD-1.3.*-* NetBSD-1.3[A-H]-*
INCOMPAT_ZLIB?= # empty
. for _pattern_ in ${_INCOMPAT_ZLIB} ${INCOMPAT_ZLIB}
. if !empty(MACHINE_PLATFORM:M${_pattern_})
-_NEED_ZLIB= YES
+BUILDLINK_USE_BUILTIN.zlib= NO
. endif
. endfor
. endif
-. if defined(USE_ZLIB)
-_NEED_ZLIB= YES
-. endif
-MAKEFLAGS+= _NEED_ZLIB="${_NEED_ZLIB}"
+MAKEFLAGS+= BUILDLINK_USE_BUILTIN.zlib="${BUILDLINK_USE_BUILTIN.zlib}"
.endif
-.if ${_NEED_ZLIB} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.zlib:M[nN][oO])
. if !empty(BUILDLINK_DEPTH:M+)
BUILDLINK_DEPENDS+= zlib
. endif
.endif
-.if !empty(ZLIB_BUILDLINK3_MK:M+)
-. if ${_NEED_ZLIB} == "YES"
-BUILDLINK_PACKAGES+= zlib
-. else
-BUILDLINK_PREFIX.zlib= /usr
-. endif
-.endif # ZLIB_BUILDLINK3_MK
-
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:C/\+$//}
diff --git a/graphics/MesaLib/buildlink3.mk b/graphics/MesaLib/buildlink3.mk
index f8ab82733bb..37de2c2b6fe 100644
--- a/graphics/MesaLib/buildlink3.mk
+++ b/graphics/MesaLib/buildlink3.mk
@@ -1,13 +1,14 @@
-# $NetBSD: buildlink3.mk,v 1.9 2004/01/04 23:34:06 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.10 2004/01/05 09:31:31 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
MESALIB_BUILDLINK3_MK:= ${MESALIB_BUILDLINK3_MK}+
-.if !empty(MESALIB_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
+.include "../../mk/bsd.prefs.mk"
+.if !empty(MESALIB_BUILDLINK3_MK:M+)
MESA_REQD?= 3.4.2
+BUILDLINK_PACKAGES+= MesaLib
BUILDLINK_DEPENDS.MesaLib?= MesaLib>=${MESA_REQD}
BUILDLINK_PKGSRCDIR.MesaLib?= ../../graphics/MesaLib
.endif # MESALIB_BUILDLINK3_MK
@@ -22,21 +23,21 @@ BUILDLINK_IS_BUILTIN.MesaLib= NO
. if exists(${_GL_GLX_H}) && exists(${_X11_TMPL})
BUILDLINK_IS_BUILTIN.MesaLib!= \
if ${GREP} -q BuildGLXLibrary ${_X11_TMPL}; then \
- ${ECHO} YES; \
+ ${ECHO} "YES"; \
else \
- ${ECHO} NO; \
+ ${ECHO} "NO"; \
fi
. endif
-MAKEFLAGS+= BUILDLINK_IS_BUILTIN.MesaLib=${BUILDLINK_IS_BUILTIN.MesaLib}
+MAKEFLAGS+= BUILDLINK_IS_BUILTIN.MesaLib="${BUILDLINK_IS_BUILTIN.MesaLib}"
.endif
.if !empty(BUILDLINK_CHECK_BUILTIN.MesaLib:M[yY][eE][sS])
-_NEED_MESALIB= NO
+BUILDLINK_USE_BUILTIN.MesaLib= YES
.endif
-.if !defined(_NEED_MESALIB)
+.if !defined(BUILDLINK_USE_BUILTIN.MesaLib)
. if !empty(BUILDLINK_IS_BUILTIN.MesaLib:M[nN][oO])
-_NEED_MESALIB= YES
+BUILDLINK_USE_BUILTIN.MesaLib= NO
. else
#
# Create an appropriate package name for the built-in Mesa/GLX distributed
@@ -47,17 +48,18 @@ _NEED_MESALIB= YES
. include "../../graphics/Mesa/version.mk"
_MESALIB_PKG= MesaLib-${_MESA_VERSION}
_MESALIB_DEPENDS= ${BUILDLINK_DEPENDS.MesaLib}
-_NEED_MESALIB!= \
+BUILDLINK_USE_BUILTIN.MesaLib!= \
if ${PKG_ADMIN} pmatch '${_MESALIB_DEPENDS}' ${_MESALIB_PKG}; then \
- ${ECHO} "NO"; \
- else \
${ECHO} "YES"; \
+ else \
+ ${ECHO} "NO"; \
fi
. endif
-MAKEFLAGS+= _NEED_MESALIB="${_NEED_MESALIB}"
-.endif # _NEED_MESALIB
+MAKEFLAGS+= \
+ BUILDLINK_USE_BUILTIN.MesaLib="${BUILDLINK_USE_BUILTIN.MesaLib}"
+.endif # BUILDLINK_USE_BUILTIN.MesaLib
-.if ${_NEED_MESALIB} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.MesaLib:M[nN][oO])
#
# If we depend on the package, depend on the latest version with a library
# major number bump.
@@ -69,11 +71,10 @@ BUILDLINK_DEPENDS+= MesaLib
.endif
.if !empty(MESALIB_BUILDLINK3_MK:M+)
-. if ${_NEED_MESALIB} == "YES"
-BUILDLINK_PACKAGES+= MesaLib
-BUILDLINK_CPPFLAGS.MesaLib= -DGLX_GLXEXT_LEGACY
-. else
+. if !empty(BUILDLINK_USE_BUILTIN.MesaLib:M[yY][eE][sS])
BUILDLINK_PREFIX.MesaLib= ${X11BASE}
+. else
+BUILDLINK_CPPFLAGS.MesaLib= -DGLX_GLXEXT_LEGACY
. endif
.endif # MESALIB_BUILDLINK3_MK
diff --git a/graphics/freetype2/buildlink3.mk b/graphics/freetype2/buildlink3.mk
index d007badf629..4ecb9661a57 100644
--- a/graphics/freetype2/buildlink3.mk
+++ b/graphics/freetype2/buildlink3.mk
@@ -1,11 +1,12 @@
-# $NetBSD: buildlink3.mk,v 1.7 2004/01/04 23:34:06 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.8 2004/01/05 09:31:31 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
FREETYPE2_BUILDLINK3_MK:= ${FREETYPE2_BUILDLINK3_MK}+
-.if !empty(FREETYPE2_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
+.include "../../mk/bsd.prefs.mk"
+.if !empty(FREETYPE2_BUILDLINK3_MK:M+)
+BUILDLINK_PACKAGES+= freetype2
BUILDLINK_DEPENDS.freetype2?= freetype2>=2.0.1
BUILDLINK_PKGSRCDIR.freetype2?= ../../graphics/freetype2
.endif # FREETYPE2_BUILDLINK3_MK
@@ -20,21 +21,22 @@ BUILDLINK_IS_BUILTIN.freetype2= NO
. if exists(${_FREETYPE2_FREETYPE_H}) && exists(${_X11_TMPL})
BUILDLINK_IS_BUILTIN.freetype2!= \
if ${GREP} -q BuildFreetype2Library ${_X11_TMPL}; then \
- ${ECHO} YES; \
+ ${ECHO} "YES"; \
else \
- ${ECHO} NO; \
+ ${ECHO} "NO"; \
fi
. endif
-MAKEFLAGS+= BUILDLINK_IS_BUILTIN.freetype2=${BUILDLINK_IS_BUILTIN.freetype2}
+MAKEFLAGS+= \
+ BUILDLINK_IS_BUILTIN.freetype2="${BUILDLINK_IS_BUILTIN.freetype2}"
.endif
.if !empty(BUILDLINK_CHECK_BUILTIN.freetype2:M[yY][eE][sS])
-_NEED_FREETYPE2= NO
+BUILDLINK_USE_BUILTIN.freetype2= YES
.endif
-.if !defined(_NEED_FREETYPE2)
+.if !defined(BUILDLINK_USE_BUILTIN.freetype2)
. if !empty(BUILDLINK_IS_BUILTIN.freetype2:M[nN][oO])
-_NEED_FREETYPE2= YES
+BUILDLINK_USE_BUILTIN.freetype2= NO
. else
#
# Create an appropriate package name for the built-in freetype2 distributed
@@ -51,17 +53,18 @@ _FREETYPE2_PATCH!= \
_FREETYPE2_VERSION= ${_FREETYPE2_MAJOR}${_FREETYPE2_MINOR}${_FREETYPE2_PATCH}
_FREETYPE2_PKG= freetype2-${_FREETYPE2_VERSION}
_FREETYPE2_DEPENDS= ${BUILDLINK_DEPENDS.freetype2}
-_NEED_FREETYPE2!= \
+BUILDLINK_USE_BUILTIN.freetype2!= \
if ${PKG_ADMIN} pmatch '${_FREETYPE2_DEPENDS}' ${_FREETYPE2_PKG}; then \
- ${ECHO} "NO"; \
- else \
${ECHO} "YES"; \
+ else \
+ ${ECHO} "NO"; \
fi
. endif
-MAKEFLAGS+= _NEED_FREETYPE2="${_NEED_FREETYPE2}"
+MAKEFLAGS+= \
+ BUILDLINK_USE_BUILTIN.freetype2="${BUILDLINK_USE_BUILTIN.freetype2}"
.endif
-.if ${_NEED_FREETYPE2} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.freetype2:M[nN][oO])
#
# If we depend on the package, depend on the latest version with a library
# major number bump.
@@ -73,9 +76,7 @@ BUILDLINK_DEPENDS+= freetype2
.endif
.if !empty(FREETYPE2_BUILDLINK3_MK:M+)
-. if ${_NEED_FREETYPE2} == "YES"
-BUILDLINK_PACKAGES+= freetype2
-. else
+. if !empty(BUILDLINK_USE_BUILTIN.freetype2:M[yY][eE][sS])
BUILDLINK_PREFIX.freetype2= ${X11BASE}
. endif
diff --git a/graphics/glu/buildlink3.mk b/graphics/glu/buildlink3.mk
index b69b0fe22d8..54c40dfd1e3 100644
--- a/graphics/glu/buildlink3.mk
+++ b/graphics/glu/buildlink3.mk
@@ -1,13 +1,14 @@
-# $NetBSD: buildlink3.mk,v 1.7 2004/01/04 23:34:06 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.8 2004/01/05 09:31:31 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
GLU_BUILDLINK3_MK:= ${GLU_BUILDLINK3_MK}+
-.if !empty(GLU_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
+.include "../../mk/bsd.prefs.mk"
+.if !empty(GLU_BUILDLINK3_MK:M+)
MESA_REQD?= 3.4.2
+BUILDLINK_PACKAGES+= glu
BUILDLINK_DEPENDS.glu?= glu>=${MESA_REQD}
BUILDLINK_PKGSRCDIR.glu?= ../../graphics/glu
.endif # GLU_BUILDLINK3_MK
@@ -22,21 +23,21 @@ BUILDLINK_IS_BUILTIN.glu= NO
. if exists(${_GL_GLU_H}) && exists(${_X11_TMPL})
BUILDLINK_IS_BUILTIN.glu!= \
if ${GREP} -q BuildGLULibrary ${_X11_TMPL}; then \
- ${ECHO} YES; \
+ ${ECHO} "YES"; \
else \
- ${ECHO} NO; \
+ ${ECHO} "NO"; \
fi
. endif
-MAKEFLAGS+= BUILDLINK_IS_BUILTIN.glu=${BUILDLINK_IS_BUILTIN.glu}
+MAKEFLAGS+= BUILDLINK_IS_BUILTIN.glu="${BUILDLINK_IS_BUILTIN.glu}"
.endif
.if !empty(BUILDLINK_CHECK_BUILTIN.glu:M[yY][eE][sS])
-_NEED_GLU= NO
+BUILDLINK_USE_BUILTIN.glu= YES
.endif
-.if !defined(_NEED_GLU)
+.if !defined(BUILDLINK_USE_BUILTIN.glu)
. if !empty(BUILDLINK_IS_BUILTIN.glu:M[nN][oO])
-_NEED_GLU= YES
+BUILDLINK_USE_BUILTIN.glu= NO
. else
#
# Create an appropriate package name for the built-in Mesa/GLU distributed
@@ -47,17 +48,17 @@ _NEED_GLU= YES
. include "../../graphics/Mesa/version.mk"
_GLU_PKG= glu-${_MESA_VERSION}
_GLU_DEPENDS= ${BUILDLINK_DEPENDS.glu}
-_NEED_GLU!= \
+BUILDLINK_USE_BUILTIN.glu!= \
if ${PKG_ADMIN} pmatch '${_GLU_DEPENDS}' ${_GLU_PKG}; then \
- ${ECHO} "NO"; \
- else \
${ECHO} "YES"; \
+ else \
+ ${ECHO} "NO"; \
fi
. endif
-MAKEFLAGS+= _NEED_GLU="${_NEED_GLU}"
-.endif # _NEED_GLU
+MAKEFLAGS+= BUILDLINK_USE_BUILTIN.glu="${BUILDLINK_USE_BUILTIN.glu}"
+.endif # BUILDLINK_USE_BUILTIN.glu
-.if ${_NEED_GLU} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.glu:M[nN][oO])
#
# If we depend on the package, depend on the latest version with a library
# major number bump.
@@ -69,9 +70,7 @@ BUILDLINK_DEPENDS+= glu
.endif
.if !empty(GLU_BUILDLINK3_MK:M+)
-. if ${_NEED_GLU} == "YES"
-BUILDLINK_PACKAGES+= glu
-. else
+. if !empty(BUILDLINK_USE_BUILTIN.glu:M[yY][eE][sS])
BUILDLINK_PREFIX.glu= ${X11BASE}
. endif
.endif # GLU_BUILDLINK3_MK
diff --git a/graphics/xpm/buildlink3.mk b/graphics/xpm/buildlink3.mk
index 2a8dbed0f40..f983413ec58 100644
--- a/graphics/xpm/buildlink3.mk
+++ b/graphics/xpm/buildlink3.mk
@@ -1,4 +1,4 @@
-# $NetBSD: buildlink3.mk,v 1.8 2004/01/04 23:34:06 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.9 2004/01/05 09:31:31 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
XPM_BUILDLINK3_MK:= ${XPM_BUILDLINK3_MK}+
@@ -6,6 +6,7 @@ XPM_BUILDLINK3_MK:= ${XPM_BUILDLINK3_MK}+
.include "../../mk/bsd.prefs.mk"
.if !empty(XPM_BUILDLINK3_MK:M+)
+BUILDLINK_PACKAGES+= xpm
BUILDLINK_DEPENDS.xpm?= xpm>=3.4k
BUILDLINK_PKGSRCDIR.xpm?= ../../graphics/xpm
.endif # XPM_BUILDLINK3_MK
@@ -21,31 +22,31 @@ BUILDLINK_IS_BUILTIN.xpm= NO
. if !empty(X11BASE:M*openwin)
BUILDLINK_IS_BUILTIN.xpm!= \
if /usr/sbin/pkgchk -l SUNWxwinc | ${GREP} -q xpm.h; then \
- ${ECHO} YES; \
+ ${ECHO} "YES"; \
else \
- ${ECHO} NO; \
+ ${ECHO} "NO"; \
fi
. elif exists(${_X11_TMPL})
BUILDLINK_IS_BUILTIN.xpm!= \
if ${GREP} -q NormalLibXpm ${_X11_TMPL}; then \
- ${ECHO} YES; \
+ ${ECHO} "YES"; \
else \
- ${ECHO} NO; \
+ ${ECHO} "NO"; \
fi
. else
BUILDLINK_IS_BUILTIN.xpm= NO
. endif
. endif
-MAKEFLAGS+= BUILDLINK_IS_BUILTIN.xpm=${BUILDLINK_IS_BUILTIN.xpm}
+MAKEFLAGS+= BUILDLINK_IS_BUILTIN.xpm="${BUILDLINK_IS_BUILTIN.xpm}"
.endif
.if !empty(BUILDLINK_CHECK_BUILTIN.xpm:M[yY][eE][sS])
-_NEED_XPM= NO
+BUILDLINK_USE_BUILTIN.xpm= YES
.endif
-.if !defined(_NEED_XPM)
+.if !defined(BUILDLINK_USE_BUILTIN.xpm)
. if !empty(BUILDLINK_IS_BUILTIN.xpm:M[nN][oO])
-_NEED_XPM= YES
+BUILDLINK_USE_BUILTIN.xpm= NO
. else
#
# Create an appropriate package name for the built-in xpm distributed
@@ -62,26 +63,24 @@ _XPM_PATCH!= \
_XPM_VERSION= ${_XPM_MAJOR}${_XPM_MINOR}${_XPM_PATCH}
_XPM_PKG= xpm-${_XPM_VERSION}
_XPM_DEPENDS= ${BUILDLINK_DEPENDS.xpm}
-_NEED_XPM!= \
+BUILDLINK_USE_BUILTIN.xpm!= \
if ${PKG_ADMIN} pmatch '${_XPM_DEPENDS}' ${_XPM_PKG}; then \
- ${ECHO} "NO"; \
- else \
${ECHO} "YES"; \
+ else \
+ ${ECHO} "NO"; \
fi
. endif
-MAKEFLAGS+= _NEED_XPM="${_NEED_XPM}"
-.endif # _NEED_XPM
+MAKEFLAGS+= BUILDLINK_USE_BUILTIN.xpm="${BUILDLINK_USE_BUILTIN.xpm}"
+.endif # BUILDLINK_USE_BUILTIN.xpm
-.if ${_NEED_XPM} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.xpm:M[nN][oO])
. if !empty(BUILDLINK_DEPTH:M+)
BUILDLINK_DEPENDS+= xpm
. endif
.endif
.if !empty(XPM_BUILDLINK3_MK:M+)
-. if ${_NEED_XPM} == "YES"
-BUILDLINK_PACKAGES+= xpm
-. else
+. if !empty(BUILDLINK_USE_BUILTIN.xpm:M[yY][eE][sS])
BUILDLINK_PREFIX.xpm= ${X11BASE}
. endif
.endif # XPM_BUILDLINK3_MK
diff --git a/net/libpcap/buildlink3.mk b/net/libpcap/buildlink3.mk
index b7407355562..e7af7aad3e4 100644
--- a/net/libpcap/buildlink3.mk
+++ b/net/libpcap/buildlink3.mk
@@ -1,11 +1,12 @@
-# $NetBSD: buildlink3.mk,v 1.2 2004/01/04 23:34:07 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.3 2004/01/05 09:31:31 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
LIBPCAP_BUILDLINK3_MK:= ${LIBPCAP_BUILDLINK3_MK}+
-.if !empty(LIBPCAP_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
+.include "../../mk/bsd.prefs.mk"
+.if !empty(LIBPCAP_BUILDLINK3_MK:M+)
+BUILDLINK_PACKAGES+= libpcap
BUILDLINK_DEPENDS.libpcap?= libpcap>=0.7.2
BUILDLINK_PKGSRCDIR.libpcap?= ../../net/libpcap
.endif # LIBPCAP_BUILDLINK3_MK
@@ -20,30 +21,21 @@ BUILDLINK_IS_BUILTIN.libpcap= YES
.endif
.if !empty(BUILDLINK_CHECK_BUILTIN.libpcap:M[yY][eE][sS])
-_NEED_LIBPCAP= NO
+BUILDLINK_USE_BUILTIN.libpcap= YES
.endif
-.if !defined(_NEED_LIBPCAP)
+.if !defined(BUILDLINK_USE_BUILTIN.libpcap)
. if !empty(BUILDLINK_IS_BUILTIN.libpcap:M[nN][oO])
-_NEED_LIBPCAP= YES
+BUILDLINK_USE_BUILTIN.libpcap= NO
. else
-_NEED_LIBPCAP= NO
+BUILDLINK_USE_BUILTIN.libpcap= YES
. endif
-MAKEFLAGS+= _NEED_LIBPCAP="${_NEED_LIBPCAP}"
.endif
-.if ${_NEED_LIBPCAP} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.libpcap:M[nN][oO])
. if !empty(BUILDLINK_DEPTH:M+)
BUILDLINK_DEPENDS+= libpcap
. endif
.endif
-.if !empty(LIBPCAP_BUILDLINK3_MK:M+)
-. if ${_NEED_LIBPCAP} == "YES"
-BUILDLINK_PACKAGES+= libpcap
-. else
-BUILDLINK_PREFIX.libpcap= /usr
-. endif
-.endif # LIBPCAP_BUILDLINK3_MK
-
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:C/\+$//}
diff --git a/security/PAM/buildlink3.mk b/security/PAM/buildlink3.mk
index 1866c8f0be9..526312e7877 100644
--- a/security/PAM/buildlink3.mk
+++ b/security/PAM/buildlink3.mk
@@ -1,11 +1,12 @@
-# $NetBSD: buildlink3.mk,v 1.2 2004/01/04 23:34:07 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.3 2004/01/05 09:31:31 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
PAM_BUILDLINK3_MK:= ${PAM_BUILDLINK3_MK}+
-.if !empty(PAM_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
+.include "../../mk/bsd.prefs.mk"
+.if !empty(PAM_BUILDLINK3_MK:M+)
+BUILDLINK_PACKAGES+= pam
BUILDLINK_DEPENDS.pam?= PAM>=0.75
BUILDLINK_PKGSRCDIR.pam?= ../../security/PAM
.endif # PAM_BUILDLINK3_MK
@@ -20,30 +21,21 @@ BUILDLINK_IS_BUILTIN.pam= YES
.endif
.if !empty(BUILDLINK_CHECK_BUILTIN.pam:M[yY][eE][sS])
-_NEED_PAM= NO
+BUILDLINK_USE_BUILTIN.pam= YES
.endif
-.if !defined(_NEED_PAM)
+.if !defined(BUILDLINK_USE_BUILTIN.pam)
. if !empty(BUILDLINK_IS_BUILTIN.pam:M[nN][oO])
-_NEED_PAM= YES
+BUILDLINK_USE_BUILTIN.pam= NO
. else
-_NEED_PAM= NO
+BUILDLINK_USE_BUILTIN.pam= YES
. endif
-MAKEFLAGS+= _NEED_PAM="${_NEED_PAM}"
.endif
-.if ${_NEED_PAM} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.pam:M[nN][oO])
. if !empty(BUILDLINK_DEPTH:M+)
BUILDLINK_DEPENDS+= pam
. endif
.endif
-.if !empty(PAM_BUILDLINK3_MK:M+)
-. if ${_NEED_PAM} == "YES"
-BUILDLINK_PACKAGES+= pam
-. else
-BUILDLINK_PREFIX.pam= /usr
-. endif
-.endif # PAM_BUILDLINK3_MK
-
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:C/\+$//}
diff --git a/security/openssl/buildlink3.mk b/security/openssl/buildlink3.mk
index b8032279454..4d2ecc28210 100644
--- a/security/openssl/buildlink3.mk
+++ b/security/openssl/buildlink3.mk
@@ -1,11 +1,12 @@
-# $NetBSD: buildlink3.mk,v 1.2 2004/01/04 23:34:07 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.3 2004/01/05 09:31:31 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
OPENSSL_BUILDLINK3_MK:= ${OPENSSL_BUILDLINK3_MK}+
-.if !empty(OPENSSL_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
+.include "../../mk/bsd.prefs.mk"
+.if !empty(OPENSSL_BUILDLINK3_MK:M+)
+#
# This is the ${PKGNAME} of the version of the OpenSSL package installed
# by pkgsrc.
#
@@ -28,12 +29,12 @@ BUILDLINK_IS_BUILTIN.openssl= YES
.endif
.if !empty(BUILDLINK_CHECK_BUILTIN.openssl:M[yY][eE][sS])
-_NEED_OPENSSL= NO
+BUILDLINK_USE_BUILTIN.openssl= YES
.endif
-.if !defined(_NEED_OPENSSL)
+.if !defined(BUILDLINK_USE_BUILTIN.openssl)
. if !empty(BUILDLINK_IS_BUILTIN.openssl:M[nN][oO])
-_NEED_OPENSSL= YES
+BUILDLINK_USE_BUILTIN.openssl= NO
. else
#
# Create an appropriate name for the built-in package distributed
@@ -104,14 +105,15 @@ _OPENSSL_PKG= openssl-0.9.6l
. endif
_OPENSSL_DEPENDS= ${BUILDLINK_DEPENDS.openssl}
-_NEED_OPENSSL!= \
+BUILDLINK_USE_BUILTIN.openssl!= \
if ${PKG_ADMIN} pmatch '${_OPENSSL_DEPENDS}' ${_OPENSSL_PKG}; then \
- ${ECHO} "NO"; \
- else \
${ECHO} "YES"; \
+ else \
+ ${ECHO} "NO"; \
fi
. endif
-MAKEFLAGS+= _NEED_OPENSSL="${_NEED_OPENSSL}"
+MAKEFLAGS+= \
+ BUILDLINK_USE_BUILTIN.openssl="${BUILDLINK_USE_BUILTIN.openssl}"
.endif
.if !defined(_NEED_NEWER_OPENSSL)
@@ -124,20 +126,21 @@ _NEED_NEWER_OPENSSL!= \
MAKEFLAGS+= _NEED_NEWER_OPENSSL="${_NEED_NEWER_OPENSSL}"
.endif
-.if (${_NEED_OPENSSL} == "YES") && (${_NEED_NEWER_OPENSSL} == "YES")
+.if !empty(BUILDLINK_USE_BUILTIN.openssl:M[nN][oO]) && \
+ (${_NEED_NEWER_OPENSSL} == "YES")
PKG_SKIP_REASON= "Unable to satisfy dependency: ${BUILDLINK_DEPENDS.openssl}"
.endif
-.if ${_NEED_OPENSSL} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.openssl:M[nN][oO])
. if !empty(BUILDLINK_DEPTH:M+)
BUILDLINK_DEPENDS+= openssl
+. if defined(USE_RSAREF2) && !empty(USE_RSAREF2:M[yY][eE][sS])
+BUILDLINK_DEPENDS+= rsaref
+. endif
. endif
.endif
.if !empty(OPENSSL_BUILDLINK3_MK:M+)
-. if ${_NEED_OPENSSL} == "NO"
-BUILDLINK_PREFIX.openssl= /usr
-. endif
SSLBASE= ${BUILDLINK_PREFIX.openssl}
BUILD_DEFS+= SSLBASE
@@ -150,9 +153,8 @@ SSLCERTS= ${PKG_SYSCONFBASE}/openssl/certs
. endif
BUILD_DEFS+= SSLCERTS
-. if ${_NEED_OPENSSL} == "YES"
+. if !empty(BUILDLINK_USE_BUILTIN.openssl:M[nN][oO])
. if defined(USE_RSAREF2) && !empty(USE_RSAREF2:M[yY][eE][sS])
-BUILDLINK_DEPENDS+= rsaref
. include "../../security/rsaref/buildlink3.mk"
. endif
. endif
diff --git a/security/tcp_wrappers/buildlink3.mk b/security/tcp_wrappers/buildlink3.mk
index 9f8480e8573..3193d018909 100644
--- a/security/tcp_wrappers/buildlink3.mk
+++ b/security/tcp_wrappers/buildlink3.mk
@@ -1,11 +1,12 @@
-# $NetBSD: buildlink3.mk,v 1.2 2004/01/04 23:34:07 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.3 2004/01/05 09:31:31 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
TCP_WRAPPERS_BUILDLINK3_MK:= ${TCP_WRAPPERS_BUILDLINK3_MK}+
-.if !empty(TCP_WRAPPERS_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
+.include "../../mk/bsd.prefs.mk"
+.if !empty(TCP_WRAPPERS_BUILDLINK3_MK:M+)
+BUILDLINK_PACKAGES+= tcp_wrappers
BUILDLINK_DEPENDS.tcp_wrappers?= tcp_wrappers>=7.6.1nb1
BUILDLINK_PKGSRCDIR.tcp_wrappers?= ../../security/tcp_wrappers
.endif # TCP_WRAPPERS_BUILDLINK3_MK
@@ -20,30 +21,21 @@ BUILDLINK_IS_BUILTIN.tcp_wrappers= YES
.endif
.if !empty(BUILDLINK_CHECK_BUILTIN.tcp_wrappers:M[yY][eE][sS])
-_NEED_TCP_WRAPPERS= NO
+BUILDLINK_USE_BUILTIN.tcp_wrappers= YES
.endif
-.if !defined(_NEED_TCP_WRAPPERS)
+.if !defined(BUILDLINK_USE_BUILTIN.tcp_wrappers)
. if !empty(BUILDLINK_IS_BUILTIN.tcp_wrappers:M[nN][oO])
-_NEED_TCP_WRAPPERS= YES
+BUILDLINK_USE_BUILTIN.tcp_wrappers= NO
. else
-_NEED_TCP_WRAPPERS= NO
+BUILDLINK_USE_BUILTIN.tcp_wrappers= YES
. endif
-MAKEFLAGS+= _NEED_TCP_WRAPPERS="${_NEED_TCP_WRAPPERS}"
.endif
-.if ${_NEED_TCP_WRAPPERS} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.tcp_wrappers:M[nN][oO])
. if !empty(BUILDLINK_DEPTH:M+)
BUILDLINK_DEPENDS+= tcp_wrappers
. endif
.endif
-.if !empty(TCP_WRAPPERS_BUILDLINK3_MK:M+)
-. if ${_NEED_TCP_WRAPPERS} == "YES"
-BUILDLINK_PACKAGES+= tcp_wrappers
-. else
-BUILDLINK_PREFIX.tcp_wrappers= /usr
-. endif
-.endif # TCP_WRAPPERS_BUILDLINK3_MK
-
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:C/\+$//}
diff --git a/x11/Xrender/buildlink3.mk b/x11/Xrender/buildlink3.mk
index e7961f3de26..af421afb1c6 100644
--- a/x11/Xrender/buildlink3.mk
+++ b/x11/Xrender/buildlink3.mk
@@ -1,11 +1,12 @@
-# $NetBSD: buildlink3.mk,v 1.9 2004/01/04 23:34:07 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.10 2004/01/05 09:31:31 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
XRENDER_BUILDLINK3_MK:= ${XRENDER_BUILDLINK3_MK}+
-.if !empty(XRENDER_BUILDLINK3_MK:M+)
-. include "../../mk/bsd.prefs.mk"
+.include "../../mk/bsd.prefs.mk"
+.if !empty(XRENDER_BUILDLINK3_MK:M+)
+BUILDLINK_PACKAGES+= Xrender
BUILDLINK_DEPENDS.Xrender?= Xrender>=0.2
BUILDLINK_PKGSRCDIR.Xrender?= ../../x11/Xrender
.endif # XRENDER_BUILDLINK3_MK
@@ -20,21 +21,21 @@ BUILDLINK_IS_BUILTIN.Xrender= NO
. if exists(${_X11_EXTENSIONS_RENDER_H}) && exists(${_X11_TMPL})
BUILDLINK_IS_BUILTIN.Xrender!= \
if ${GREP} -q BuildRenderLibrary ${_X11_TMPL}; then \
- ${ECHO} YES; \
+ ${ECHO} "YES"; \
else \
- ${ECHO} NO; \
+ ${ECHO} "NO"; \
fi
. endif
-MAKEFLAGS+= BUILDLINK_IS_BUILTIN.Xrender=${BUILDLINK_IS_BUILTIN.Xrender}
+MAKEFLAGS+= BUILDLINK_IS_BUILTIN.Xrender="${BUILDLINK_IS_BUILTIN.Xrender}"
.endif
.if !empty(BUILDLINK_CHECK_BUILTIN.Xrender:M[yY][eE][sS])
-_NEED_XRENDER= NO
+BUILDLINK_USE_BUILTIN.Xrender= YES
.endif
-.if !defined(_NEED_XRENDER)
+.if !defined(BUILDLINK_USE_BUILTIN.Xrender)
. if !empty(BUILDLINK_IS_BUILTIN.Xrender:M[nN][oO])
-_NEED_XRENDER= YES
+BUILDLINK_USE_BUILTIN.Xrender= NO
. else
#
# Create an appropriate package name for the built-in Xrender distributed
@@ -49,17 +50,18 @@ _XRENDER_MINOR!= \
_XRENDER_VERSION= ${_XRENDER_MAJOR}${_XRENDER_MINOR}
_XRENDER_PKG= Xrender-${_XRENDER_VERSION}
_XRENDER_DEPENDS= ${BUILDLINK_DEPENDS.Xrender}
-_NEED_XRENDER!= \
+BUILDLINK_USE_BUILTIN.Xrender!= \
if ${PKG_ADMIN} pmatch '${_XRENDER_DEPENDS}' ${_XRENDER_PKG}; then \
- ${ECHO} "NO"; \
- else \
${ECHO} "YES"; \
+ else \
+ ${ECHO} "NO"; \
fi
. endif
-MAKEFLAGS+= _NEED_XRENDER="${_NEED_XRENDER}"
-.endif # _NEED_XRENDER
+MAKEFLAGS+= \
+ BUILDLINK_USE_BUILTIN.Xrender="${BUILDLINK_USE_BUILTIN.Xrender}"
+.endif # BUILDLINK_USE_BUILTIN.Xrender
-.if ${_NEED_XRENDER} == "YES"
+.if !empty(BUILDLINK_USE_BUILTIN.Xrender:M[nN][oO])
#
# If we depend on the package, depend on the latest version with a library
# minor number bump.
@@ -71,9 +73,7 @@ BUILDLINK_DEPENDS+= Xrender
.endif
.if !empty(XRENDER_BUILDLINK3_MK:M+)
-. if ${_NEED_XRENDER} == "YES"
-BUILDLINK_PACKAGES+= Xrender
-. else
+. if !empty(BUILDLINK_USE_BUILTIN.Xrender:M[yY][eE][sS])
BUILDLINK_PREFIX.Xrender= ${X11BASE}
. endif
.endif # XRENDER_BUILDLINK3_MK