Hello dear developers,
I've run into some problems trying to proper package strongswan for
fedora/rhel, mainly with autoconf and the mysql plugin.
Since fedora stores the mysqlclient_r library in /usr/lib/mysql and not
in /usr/lib, the configure script as it is now won't find the library
when --enable-mysql is used.
However, --enable-mysql=/usr/lib/mysql will also not work as it's not
even recognized as enabled :) (it used test x$enableval = xtrue)
I've done a little patch to configure.in which enables configure to test
an argument to --enable-mysql as a library search path.
This way i can use --enable-mysql=%{_libdir}/mysql in my spec :)
Is this an acceptable way of doing this or are you generating
configure.in somewhere else or do you not agree to doing it this way at
all?
Thanks for your time,
Johannes

diff -Nur strongswan-4.3.4.orig/configure.in strongswan-4.3.4/configure.in
--- strongswan-4.3.4.orig/configure.in	2009-08-14 18:04:47.000000000 +0200
+++ strongswan-4.3.4/configure.in	2009-09-22 18:37:55.000000000 +0200
@@ -320,8 +320,8 @@
 AC_ARG_ENABLE(
 	[mysql],
 	AS_HELP_STRING([--enable-mysql],[enable MySQL database support (default is NO). Requires libmysqlclient_r.]),
-	[if test x$enableval = xyes; then
-		mysql=true
+	[if test x$enableval != x; then
+		mysql=$enableval
 	fi]
 )
 
@@ -1039,7 +1039,10 @@
 	AC_CHECK_HEADER([fcgiapp.h],,[AC_MSG_ERROR([FastCGI header file fcgiapp.h not found!])])
 fi
 
-if test x$mysql = xtrue; then
+if test x$mysql != x; then
+	if test x$mysql != xyes; then
+		LIBS="$LIBS -L$mysql"
+	fi
 	AC_HAVE_LIBRARY([mysqlclient_r],[LIBS="$LIBS"],[AC_MSG_ERROR([MySQL library mysqlclient_r not found])])
 	AC_CHECK_HEADER([mysql/mysql.h],,[AC_MSG_ERROR([MySQL header mysql/mysql.h not found!])])
 fi
_______________________________________________
Users mailing list
[email protected]
https://lists.strongswan.org/mailman/listinfo/users

Reply via email to