diff options
author | jlam <jlam@pkgsrc.org> | 2004-01-03 23:06:43 +0000 |
---|---|---|
committer | jlam <jlam@pkgsrc.org> | 2004-01-03 23:06:43 +0000 |
commit | 339cd13cb2e6dedfb07f792d4748aad67fe2788b (patch) | |
tree | 7815453a8a5d5cc91288c15c8c52893726b1e2bc /security | |
parent | 24f7929dc215b42dce86fc5cd36d848a3e54389c (diff) | |
download | pkgsrc-339cd13cb2e6dedfb07f792d4748aad67fe2788b.tar.gz |
Initial sprinkling of work-in-progress buildlink3.mk files for using the
buildlink3 framework.
Diffstat (limited to 'security')
-rw-r--r-- | security/PAM/buildlink3.mk | 49 | ||||
-rw-r--r-- | security/cyrus-sasl2/buildlink3.mk | 19 | ||||
-rw-r--r-- | security/libcrack/buildlink3.mk | 19 | ||||
-rw-r--r-- | security/openssl/buildlink3.mk | 161 | ||||
-rw-r--r-- | security/rsaref/buildlink3.mk | 19 | ||||
-rw-r--r-- | security/tcp_wrappers/buildlink3.mk | 49 |
6 files changed, 316 insertions, 0 deletions
diff --git a/security/PAM/buildlink3.mk b/security/PAM/buildlink3.mk new file mode 100644 index 00000000000..393cb0a66f9 --- /dev/null +++ b/security/PAM/buildlink3.mk @@ -0,0 +1,49 @@ +# $NetBSD: buildlink3.mk,v 1.1 2004/01/03 23:06:45 jlam Exp $ + +BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ +PAM_BUILDLINK3_MK:= ${PAM_BUILDLINK3_MK}+ + +.if !empty(PAM_BUILDLINK3_MK:M\+) +. include "../../mk/bsd.prefs.mk" + +BUILDLINK_DEPENDS.pam?= PAM>=0.75 +BUILDLINK_PKGSRCDIR.pam?= ../../security/PAM +.endif # PAM_BUILDLINK3_MK + +BUILDLINK_CHECK_BUILTIN.pam?= NO + +.if !defined(BUILDLINK_IS_BUILTIN.pam) +BUILDLINK_IS_BUILTIN.pam= NO +. if exists(/usr/include/security/pam_appl.h) +BUILDLINK_IS_BUILTIN.pam= YES +. endif +.endif + +.if !empty(BUILDLINK_CHECK_BUILTIN.pam:M[yY][eE][sS]) +_NEED_PAM= NO +.endif + +.if !defined(_NEED_PAM) +. if !empty(BUILDLINK_IS_BUILTIN.pam:M[nN][oO]) +_NEED_PAM= YES +. else +_NEED_PAM= NO +. endif +MAKEFLAGS+= _NEED_PAM="${_NEED_PAM}" +.endif + +.if ${_NEED_PAM} == "YES" +. 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/cyrus-sasl2/buildlink3.mk b/security/cyrus-sasl2/buildlink3.mk new file mode 100644 index 00000000000..b4db1364cff --- /dev/null +++ b/security/cyrus-sasl2/buildlink3.mk @@ -0,0 +1,19 @@ +# $NetBSD: buildlink3.mk,v 1.1 2004/01/03 23:06:45 jlam Exp $ + +BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ +CYRUS_SASL_BUILDLINK3_MK:= ${CYRUS_SASL_BUILDLINK3_MK}+ + +.if !empty(CYRUS_SASL_BUILDLINK3_MK:M\+) +BUILDLINK_DEPENDS.cyrus-sasl?= cyrus-sasl>=2.1.12 +BUILDLINK_PKGSRCDIR.cyrus-sasl?= ../../security/cyrus-sasl2 +.endif # CYRUS_SASL_BUILDLINK3_MK + +.if !empty(BUILDLINK_DEPTH:M\+) +BUILDLINK_DEPENDS+= cyrus-sasl +.endif + +.if !empty(CYRUS_SASL_BUILDLINK3_MK:M\+) +BUILDLINK_PACKAGES+= cyrus-sasl +.endif # CYRUS_SASL_BUILDLINK3_MK + +BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:C/\+$//} diff --git a/security/libcrack/buildlink3.mk b/security/libcrack/buildlink3.mk new file mode 100644 index 00000000000..c5f444d3736 --- /dev/null +++ b/security/libcrack/buildlink3.mk @@ -0,0 +1,19 @@ +# $NetBSD: buildlink3.mk,v 1.1 2004/01/03 23:06:45 jlam Exp $ + +BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ +LIBCRACK_BUILDLINK3_MK:= ${LIBCRACK_BUILDLINK3_MK}+ + +.if !empty(LIBCRACK_BUILDLINK3_MK:M\+) +BUILDLINK_DEPENDS.libcrack?= libcrack>=2.7 +BUILDLINK_PKGSRCDIR.libcrack?= ../../security/libcrack +.endif # LIBCRACK_BUILDLINK3_MK + +.if !empty(BUILDLINK_DEPTH:M\+) +BUILDLINK_DEPENDS+= libcrack +.endif + +.if !empty(LIBCRACK_BUILDLINK3_MK:M\+) +BUILDLINK_PACKAGES+= libcrack +.endif # LIBCRACK_BUILDLINK3_MK + +BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:C/\+$//} diff --git a/security/openssl/buildlink3.mk b/security/openssl/buildlink3.mk new file mode 100644 index 00000000000..9ae9ba3a0f3 --- /dev/null +++ b/security/openssl/buildlink3.mk @@ -0,0 +1,161 @@ +# $NetBSD: buildlink3.mk,v 1.1 2004/01/03 23:06:45 jlam Exp $ + +BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ +OPENSSL_BUILDLINK3_MK:= ${OPENSSL_BUILDLINK3_MK}+ + +.if !empty(OPENSSL_BUILDLINK3_MK:M\+) +. include "../../mk/bsd.prefs.mk" + +# This is the ${PKGNAME} of the version of the OpenSSL package installed +# by pkgsrc. +# +_OPENSSL_PKGSRC_PKGNAME= openssl-0.9.6l + +BUILDLINK_PACKAGES+= openssl +BUILDLINK_DEPENDS.openssl?= openssl>=0.9.6l +BUILDLINK_PKGSRCDIR.openssl?= ../../security/openssl +.endif # OPENSSL_BUILDLINK3_MK + +BUILDLINK_CHECK_BUILTIN.openssl?= NO + +_OPENSSL_OPENSSLV_H= /usr/include/openssl/opensslv.h + +.if !defined(BUILDLINK_IS_BUILTIN.openssl) +BUILDLINK_IS_BUILTIN.openssl= NO +. if exists(${_OPENSSL_OPENSSLV_H}) +BUILDLINK_IS_BUILTIN.openssl= YES +. endif +.endif + +.if !empty(BUILDLINK_CHECK_BUILTIN.openssl:M[yY][eE][sS]) +_NEED_OPENSSL= NO +.endif + +.if !defined(_NEED_OPENSSL) +. if !empty(BUILDLINK_IS_BUILTIN.openssl:M[nN][oO]) +_NEED_OPENSSL= YES +. else +# +# Create an appropriate name for the built-in package distributed +# with the system. This package name can be used to check against +# BUILDLINK_DEPENDS.<pkg> to see if we need to install the pkgsrc +# version or if the built-in one is sufficient. +# +_OPENSSL_MAJOR!= \ + ${AWK} 'BEGIN { hex="0123456789abcdef" } \ + /\#define[ ]*OPENSSL_VERSION_NUMBER/ { \ + i = index(hex, substr($$3, 3, 1)) - 1; \ + print i; \ + exit 0; \ + } \ + ' ${_OPENSSL_OPENSSLV_H} +_OPENSSL_MINOR!= \ + ${AWK} 'BEGIN { hex="0123456789abcdef" } \ + /\#define[ ]*OPENSSL_VERSION_NUMBER/ { \ + i = 16 * (index(hex, substr($$3, 4, 1)) - 1); \ + i += index(hex, substr($$3, 5, 1)) - 1; \ + print i; \ + exit 0; \ + } \ + ' ${_OPENSSL_OPENSSLV_H} +_OPENSSL_TEENY!= \ + ${AWK} 'BEGIN { hex="0123456789abcdef" } \ + /\#define[ ]*OPENSSL_VERSION_NUMBER/ { \ + i = 16 * (index(hex, substr($$3, 6, 1)) - 1); \ + i += index(hex, substr($$3, 7, 1)) - 1; \ + print i; \ + exit 0; \ + } \ + ' ${_OPENSSL_OPENSSLV_H} +_OPENSSL_PATCHLEVEL!= \ + ${AWK} 'BEGIN { hex="0123456789abcdef"; \ + split("abcdefghijklmnopqrstuvwxyz", alpha, ""); \ + } \ + /\#define[ ]*OPENSSL_VERSION_NUMBER/ { \ + i = 16 * (index(hex, substr($$3, 8, 1)) - 1); \ + i += index(hex, substr($$3, 9, 1)) - 1; \ + if (i == 0) { \ + print ""; \ + } else if (i > 26) { \ + print "a"; \ + } else { \ + print alpha[i]; \ + } \ + exit 0; \ + } \ + ' ${_OPENSSL_OPENSSLV_H} +_OPENSSL_VERSION= ${_OPENSSL_MAJOR}.${_OPENSSL_MINOR}.${_OPENSSL_TEENY}${_OPENSSL_PATCHLEVEL} +_OPENSSL_PKG= openssl-${_OPENSSL_VERSION} +# +# If the built-in OpenSSL software is 0.9.6g, then check whether it +# contains the security fixes pulled up to netbsd-1-6 on 2003-11-07. +# If it does, then treat it as the equivalent of openssl-0.9.6l. This +# is not strictly true, but is good enough since the main differences +# between 0.9.6g and 0.9.6l are security fixes that NetBSD has already +# patched into its built-in OpenSSL software. +# +_OPENSSL_HAS_FIX!= \ + ${AWK} 'BEGIN { ans = "NO" } \ + /OPENSSL_HAS_20031107_FIX/ { ans = "YES" } \ + END { print ans; exit 0 } \ + ' ${_OPENSSL_OPENSSLV_H} +. if !empty(_OPENSSL_VERSION:M0\.9\.6g) && (${_OPENSSL_HAS_FIX} == "YES") +_OPENSSL_PKG= openssl-0.9.6l +. endif + +_OPENSSL_DEPENDS= ${BUILDLINK_DEPENDS.openssl} +_NEED_OPENSSL!= \ + if ${PKG_ADMIN} pmatch '${_OPENSSL_DEPENDS}' ${_OPENSSL_PKG}; then \ + ${ECHO} "NO"; \ + else \ + ${ECHO} "YES"; \ + fi +. endif +MAKEFLAGS+= _NEED_OPENSSL="${_NEED_OPENSSL}" +.endif + +.if !defined(_NEED_NEWER_OPENSSL) +_NEED_NEWER_OPENSSL!= \ + if ${PKG_ADMIN} pmatch '${BUILDLINK_DEPENDS.openssl}' ${_OPENSSL_PKGSRC_PKGNAME}; then \ + ${ECHO} "NO"; \ + else \ + ${ECHO} "YES"; \ + fi +MAKEFLAGS+= _NEED_NEWER_OPENSSL="${_NEED_NEWER_OPENSSL}" +.endif + +.if (${_NEED_OPENSSL} == "YES") && (${_NEED_NEWER_OPENSSL} == "YES") +PKG_SKIP_REASON= "Unable to satisfy dependency: ${BUILDLINK_DEPENDS.openssl}" +.endif + +.if ${_NEED_OPENSSL} == "YES" +. if !empty(BUILDLINK_DEPTH:M\+) +BUILDLINK_DEPENDS+= openssl +. endif +.endif + +.if !empty(OPENSSL_BUILDLINK3_MK:M\+) +. if ${_NEED_OPENSSL} == "NO" +BUILDLINK_PREFIX.openssl= /usr +. endif +SSLBASE= ${BUILDLINK_PREFIX.openssl} +BUILD_DEFS+= SSLBASE + +. if defined(PKG_SYSCONFDIR.openssl) +SSLCERTS= ${PKG_SYSCONFDIR.openssl}/certs +. elif ${OPSYS} == "NetBSD" +SSLCERTS= /etc/openssl/certs +. else +SSLCERTS= ${PKG_SYSCONFBASE}/openssl/certs +. endif +BUILD_DEFS+= SSLCERTS + +. if ${_NEED_OPENSSL} == "YES" +. if defined(USE_RSAREF2) && !empty(USE_RSAREF2:M[yY][eE][sS]) +BUILDLINK_DEPENDS+= rsaref +. include "../../security/rsaref/buildlink3.mk" +. endif +. endif +.endif # OPENSSL_BUILDLINK3_MK + +BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:C/\+$//} diff --git a/security/rsaref/buildlink3.mk b/security/rsaref/buildlink3.mk new file mode 100644 index 00000000000..812464aee64 --- /dev/null +++ b/security/rsaref/buildlink3.mk @@ -0,0 +1,19 @@ +# $NetBSD: buildlink3.mk,v 1.1 2004/01/03 23:06:45 jlam Exp $ + +BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+ +RSAREF_BUILDLINK3_MK:= ${RSAREF_BUILDLINK3_MK}+ + +.if !empty(RSAREF_BUILDLINK3_MK:M\+) +BUILDLINK_DEPENDS.rsaref?= rsaref-2.0p3 +BUILDLINK_PKGSRCDIR.rsaref?= ../../security/rsaref +.endif # RSAREF_BUILDLINK3_MK + +.if !empty(BUILDLINK_DEPTH:M\+) +BUILDLINK_DEPENDS+= rsaref +.endif + +.if !empty(RSAREF_BUILDLINK3_MK:M\+) +BUILDLINK_PACKAGES+= rsaref +.endif # RSAREF_BUILDLINK3_MK + +BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:C/\+$//} diff --git a/security/tcp_wrappers/buildlink3.mk b/security/tcp_wrappers/buildlink3.mk new file mode 100644 index 00000000000..b4dd96870ee --- /dev/null +++ b/security/tcp_wrappers/buildlink3.mk @@ -0,0 +1,49 @@ +# $NetBSD: buildlink3.mk,v 1.1 2004/01/03 23:06:45 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" + +BUILDLINK_DEPENDS.tcp_wrappers?= tcp_wrappers>=7.6.1nb1 +BUILDLINK_PKGSRCDIR.tcp_wrappers?= ../../security/tcp_wrappers +.endif # TCP_WRAPPERS_BUILDLINK3_MK + +BUILDLINK_CHECK_BUILTIN.tcp_wrappers?= NO + +.if !defined(BUILDLINK_IS_BUILTIN.tcp_wrappers) +BUILDLINK_IS_BUILTIN.tcp_wrappers= NO +. if exists(/usr/include/tcpd.h) +BUILDLINK_IS_BUILTIN.tcp_wrappers= YES +. endif +.endif + +.if !empty(BUILDLINK_CHECK_BUILTIN.tcp_wrappers:M[yY][eE][sS]) +_NEED_TCP_WRAPPERS= NO +.endif + +.if !defined(_NEED_TCP_WRAPPERS) +. if !empty(BUILDLINK_IS_BUILTIN.tcp_wrappers:M[nN][oO]) +_NEED_TCP_WRAPPERS= YES +. else +_NEED_TCP_WRAPPERS= NO +. endif +MAKEFLAGS+= _NEED_TCP_WRAPPERS="${_NEED_TCP_WRAPPERS}" +.endif + +.if ${_NEED_TCP_WRAPPERS} == "YES" +. 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/\+$//} |