From 02a319f1a043a3296dae63c3a086f74df1cd91f5 Mon Sep 17 00:00:00 2001 From: tron Date: Mon, 10 Apr 2006 15:04:44 +0000 Subject: Teach Kerberos 5 to detect the MIT Kerberos 5 bundled with Mac OS X. This stops the "gnome-vfs2" package from pulling in the "heimdal" package. This fixes PR pkg/29946 by Juha-Matti Liukkonen. --- security/mit-krb5/builtin.mk | 70 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 security/mit-krb5/builtin.mk (limited to 'security/mit-krb5') diff --git a/security/mit-krb5/builtin.mk b/security/mit-krb5/builtin.mk new file mode 100644 index 00000000000..ce0d50e7ac1 --- /dev/null +++ b/security/mit-krb5/builtin.mk @@ -0,0 +1,70 @@ +# $NetBSD: builtin.mk,v 1.1 2006/04/10 15:04:44 tron Exp $ + +BUILTIN_PKG:= mit-krb5 + +BUILTIN_FIND_FILES_VAR:= KRB5_CONFIG +BUILTIN_FIND_FILES.KRB5_CONFIG= /usr/bin/krb5-config + +.include "../../mk/buildlink3/bsd.builtin.mk" + +### +### Figure out the version of MIT Kerberos V installed on the system. +### + +.if !defined(BUILTIN_VERSION.mit-krb5) && \ + empty(KRB5_CONFIG:M__nonexistent__) && \ + empty(KRB5_CONFIG:M${LOCALBASE}/*) +BUILTIN_VERSION.mit-krb5!= ${KRB5_CONFIG} --version | \ + ${SED} -e 's/.*release //' -e 's/-.*//' +.endif +MAKEVARS+= BUILTIN_VERSION.mit-krb5 + +### +### Determine if there is a built-in implementation of the package and +### set IS_BUILTIN. appropriately ("yes" or "no"). +### +.if !defined(IS_BUILTIN.mit-krb5) +IS_BUILTIN.mit-krb5= no +. if defined(BUILTIN_VERSION.mit-krb5) +IS_BUILTIN.mit-krb5= yes +. endif +.endif +MAKEVARS+= IS_BUILTIN.mit-krb5 + +### +### If there is a built-in implementation, then set BUILTIN_PKG. to +### a package name to represent the built-in package. +### +.if !defined(BUILTIN_PKG.mit-krb5) && \ + !empty(IS_BUILTIN.mit-krb5:M[yY][eE][sS]) && \ + defined(BUILTIN_VERSION.mit-krb5) +BUILTIN_PKG.mit-krb5= mit-krb5-${BUILTIN_VERSION.mit-krb5} +.endif +MAKEVARS+= BUILTIN_PKG.mit-krb5 + +### +### Determine whether we should use the built-in implementation if it +### exists, and set USE_BUILTIN. appropriate ("yes" or "no"). +### +.if !defined(USE_BUILTIN.mit-krb5) +. if ${PREFER.mit-krb5} == "pkgsrc" +USE_BUILTIN.mit-krb5= no +. else +USE_BUILTIN.mit-krb5= ${IS_BUILTIN.mit-krb5} +. if defined(BUILTIN_PKG.mit-krb5) && \ + !empty(IS_BUILTIN.mit-krb5:M[yY][eE][sS]) +USE_BUILTIN.mit-krb5= yes +. for _dep_ in ${BUILDLINK_API_DEPENDS.mit-krb5} +. if !empty(USE_BUILTIN.mit-krb5:M[yY][eE][sS]) +USE_BUILTIN.mit-krb5!= \ + if ${PKG_ADMIN} pmatch ${_dep_:Q} ${BUILTIN_PKG.mit-krb5:Q}; then \ + ${ECHO} "yes"; \ + else \ + ${ECHO} "no"; \ + fi +. endif +. endfor +. endif +. endif +.endif +MAKEVARS+= USE_BUILTIN.mit-krb5 -- cgit v1.2.3