From d03cd9afc5c493cefcf8dc87de3689b53d79a54d Mon Sep 17 00:00:00 2001 From: Chris Rees Date: Sun, 18 Sep 2011 08:33:15 +0000 Subject: Handle built world without NIS more gracefully; detect missing ypcat and disable NIS module. PR: ports/115940 Submitted by: Alex Deiter Reviewed by: bf --- lang/python31/Makefile | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'lang/python31/Makefile') diff --git a/lang/python31/Makefile b/lang/python31/Makefile index 0650170d3525..9389dfa372fb 100644 --- a/lang/python31/Makefile +++ b/lang/python31/Makefile @@ -96,8 +96,10 @@ CONFIGURE_ARGS+= --without-pymalloc CFLAGS+= -DPYTHON_DEFAULT_RECURSION_LIMIT=900 .endif -.if !exists(/usr/bin/ypcat) # the world with NO_NIS +# See http://bugs.freebsd.org/115940 +.if !exists(/usr/bin/ypcat) || defined(WITHOUT_NIS) # the world with NO_NIS PLIST_SUB+= NO_NIS="@comment " +WITHOUT_NIS?= detected .else PLIST_SUB+= NO_NIS="" .endif @@ -143,6 +145,13 @@ pre-patch: ${ECHO} "fpectl fpectlmodule.c" >> ${WRKSRC}/Modules/Setup.dist .endif +post-patch: +.if defined(WITHOUT_NIS) + ${REINPLACE_CMD} -e \ + 's/disabled_module_list =[^]]*/&, "nis"/' \ + ${PATCH_WRKSRC}/setup.py +.endif + post-configure: ${TAR} -C ${WRKSRC} -cf - . | ${TAR} -C ${SHARED_WRKSRC} -xf - ${LN} -sf ${PYTHON_WRKSRC}/Lib ${WRKSRC}/Lib -- cgit v1.2.3