[GnomeMeeting-list] another patch



I needed this patch when building gnomemeeting on an arch with 
libdir==/usr/lib64.

-- 
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 Alexander Larsson                                            Red Hat, Inc 
                   alexl redhat com    alla lysator liu se 
He's an uncontrollable moralistic househusband in a wheelchair. She's an 
orphaned hypochondriac mechanic who dreams of becoming Elvis. They fight 
crime! 
Index: configure.in
===================================================================
RCS file: /cvs/gnome/gnomemeeting/configure.in,v
retrieving revision 1.106
diff -u -p -r1.106 configure.in
--- configure.in	8 Oct 2002 11:37:36 -0000	1.106
+++ configure.in	9 Oct 2002 16:13:18 -0000
@@ -295,32 +295,43 @@ dnl ####################################
 dnl LDAP Checks
 dnl ###########################################################################
 
-LDAP_INCLUDES=""
+AC_ARG_WITH(openldap-includes, [  --with-ldap-includes=PFX   Location of OpenLDAP includes.],
+        with_openldap_includes="$withval", with_openldap_includes="/usr/include")
+have_openldap_includes="no"
+if test "x${with_openldap_includes}" != "xno" ; then
+        CPPFLAGS_save="$CPPFLAGS"
 
-LDAP_LIBS="-lldap -llber -lresolv"
+        AC_MSG_CHECKING(for OpenLDAP includes)
+        AC_MSG_RESULT()
 
-AC_ARG_WITH(ldap, [  --with-ldap=PFX       Location of ldap.],
-	with_ldap="$withval", with_ldap="/usr")
-msg_ldap="no"
-if test "x${with_ldap}" != "xno" -a "x${have_ldap}" != "xno"; then
-	AC_CHECK_FILE(${with_ldap}/lib/libldap.so, ldap="yes", ldap="no")
-	if test "x${ldap}" != "xno"; then
-		ldap="yes"
-	        LDAP_DIR="${with_ldap}"
-		LDAP_LIBS="-L${LDAP_DIR}/lib ${LDAP_LIBS}"
-		if test "x${LDAP_DIR}" != "x/usr" -a "x${LDAP_DIR}" != "x/usr/local"; then 
-			LDAP_INCLUDES="-I${LDAP_DIR}/include ${LDAP_INCLUDES}"
-		else
-			LDAP_INCLUDES="${LDAP_INCLUDES}"
-		fi
-	
-	else
-		AC_MSG_ERROR([You need ldap to enjoy GnomeMeeting])
-	fi
+        CPPFLAGS="$CPPFLAGS -I${with_openldap_includes}"
+        AC_CHECK_HEADER(ldap.h, [ openldap_includes="yes" ])
+        CPPFLAGS="$CPPFLAGS_save"
+
+        if test "x${openldap_includes}" != "xno" -a "x${openldap_includes}" != "x"; then
+                have_openldap_includes="yes"
+                LDAP_INCLUDES="-I${with_openldap_includes}"
+        else
+                AC_MSG_ERROR([You need OpenLDAP's header files to build GnomeMeeting])
+        fi
 else
-	AC_MSG_ERROR([You need ldap to enjoy GnomeMeeting])
+        AC_MSG_ERROR([You need OpenLDAP's header files to build GnomeMeeting])
 fi
 
+AC_ARG_WITH(openldap-libs, [  --with-openldap-libs=PFX       Location of OpenLDAP libs.],
+        with_openldap_libs="$withval", with_openldap_libs="/usr/lib")
+msg_openldap="no"
+if test "x${with_openldap_libs}" != "xno" -a "x${have_openldap_includes}" != "xno"; then
+        AC_CHECK_FILE(${with_openldap_libs}/libldap.so, openldap_libs="yes", openldap_libs="no")
+        if test "x${openldap_libs}" != "xno"; then
+                msg_openldap="yes"
+		LDAP_LIBS="-L${with_openldap_libs} -lldap -llber -lresolv ${LDAP_LIBS}"
+        else
+                AC_MSG_ERROR([You need OpenLDAP to enjoy GnomeMeeting])
+        fi
+else
+        AC_MSG_ERROR([You need OpenLDAP to enjoy GnomeMeeting])
+fi
 
 
 GNOMEMEETING_INCLUDES="$GNOMEMEETING_CFLAGS $PTLIB_CFLAGS $LDAP_INCLUDES $OPENH323_CFLAGS $OPENSSL_CFLAGS $H323_CFLAGS $SDL_CFLAGS $ARTSC_CFLAGS"


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]