hholzgra Wed Oct 23 12:03:53 2002 EDT
Modified files:
/php4/ext/yp config.m4
Log:
don't assume yp-functions are always in libc, try also libnsl
Index: php4/ext/yp/config.m4
diff -u php4/ext/yp/config.m4:1.8 php4/ext/yp/config.m4:1.9
--- php4/ext/yp/config.m4:1.8 Tue Mar 12 11:38:59 2002
+++ php4/ext/yp/config.m4 Wed Oct 23 12:03:52 2002
@@ -1,13 +1,36 @@
dnl
-dnl $Id: config.m4,v 1.8 2002/03/12 16:38:59 sas Exp $
+dnl $Id: config.m4,v 1.9 2002/10/23 16:03:52 hholzgra Exp $
dnl
PHP_ARG_ENABLE(yp,whether to include YP support,
[ --enable-yp Include YP support.])
if test "$PHP_YP" != "no"; then
+
+ AC_CHECK_LIB(nsl, yp_match, [
+ YP_LIBS=nsl
+ YP_CHECK_IN_LIB=nsl
+ ],
+ AC_CHECK_LIB(c, yp_match, [
+ YP_LIBS=
+ YP_CHECK_IN_LIB=c
+ ],[
+ AC_MSG_ERROR(Unable to find required yp/nis library)
+ ])
+ )
+
+
AC_DEFINE(HAVE_YP,1,[ ])
PHP_NEW_EXTENSION(yp, yp.c, $ext_shared)
+
+ PHP_SUBST(YP_SHARED_LIBADD)
+
+ if test -n "$YP_LIBS"; then
+ PHP_ADD_LIBRARY_WITH_PATH($YP_LIBS, $YP_LIBDIR, YP_SHARED_LIBADD)
+ fi
+
+
+
case $host_alias in
*solaris*)
AC_DEFINE(SOLARIS_YP,1,[ ]) ;;
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php