summaryrefslogtreecommitdiff
blob: 94811747d2b416b493a4424b0ef57bfdd8acbb2d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
--- a/configure.ac
+++ b/configure.ac
@@ -25,6 +25,8 @@
 
 AC_MSG_CACHE_INIT()
 
+PKG_PROG_PKG_CONFIG
+
 #
 # save the configure arguments
 #
--- a/configure.d/config_os_libs2
+++ b/configure.d/config_os_libs2
@@ -516,6 +516,8 @@
 #   mysql
 ##
 if test "x$with_mysql" = "xyes" ; then
+  PKG_CHECK_MODULES([MYSQL],[mysqlclient],[MYSQL_INCLUDES="$MYSQL_CFLAGS"],)
+  if test -x "$MYSQL_LIBS"; then
   AC_PATH_PROGS(MYSQLCONFIG,mysql_config)
   test -x "$MYSQLCONFIG" \
 	|| AC_MSG_ERROR([Could not find mysql_config and was specifically asked to use MySQL support])
@@ -523,6 +525,7 @@
   MYSQL_INCLUDES=`$MYSQLCONFIG --include`
   _libs="${LIBS}"
   _cppflags="${CPPFLAGS}"
+  fi
   LIBS="${LIBS} ${MYSQL_LIBS}"
   CPPFLAGS="${CPPFLAGS} ${MYSQL_INCLUDES}"
   AC_CHECK_HEADER(mysql.h,,