summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Biebl <biebl@debian.org>2009-02-06 21:30:22 +0100
committerRainer Gerhards <rgerhards@adiscon.com>2009-02-24 13:09:45 +0100
commit1b912a970cf08eed3bb3919e7e68f4b0eea313f4 (patch)
tree41e729d2e36cf2d5439fe549085fd7f0ae40b2d8
parent1ca5268698acfcf043d06782baaa92c26eb999f1 (diff)
downloadrsyslog-1b912a970cf08eed3bb3919e7e68f4b0eea313f4.tar.gz
rsyslog-1b912a970cf08eed3bb3919e7e68f4b0eea313f4.tar.xz
rsyslog-1b912a970cf08eed3bb3919e7e68f4b0eea313f4.zip
Improve mysql configure check (for unusual paths)
Remove AC_CHECK_HEADERS([mysql/mysql.h],...) as this was causing pain for users where the mysql headers are not installed in the system include directory. It was superfluous anyways, as we check for mysql_config and set the include path to the correct directory. Update ommysql.c to use #include <mysql.h>, as mysql_config will set the include path to /path/to/include/mysql/ so <mysql/mysql.h> would not work. Remove errmsg.h include as it is not used.
-rw-r--r--configure.ac4
-rw-r--r--plugins/ommysql/ommysql.c3
2 files changed, 1 insertions, 6 deletions
diff --git a/configure.ac b/configure.ac
index 2e9a654f..f29991be 100644
--- a/configure.ac
+++ b/configure.ac
@@ -386,10 +386,6 @@ AC_ARG_ENABLE(mysql,
[enable_mysql=no]
)
if test "x$enable_mysql" = "xyes"; then
- AC_CHECK_HEADERS(
- [mysql/mysql.h],,
- [AC_MSG_FAILURE([MySQL is missing])]
- )
AC_CHECK_PROG(
[HAVE_MYSQL_CONFIG],
[mysql_config],
diff --git a/plugins/ommysql/ommysql.c b/plugins/ommysql/ommysql.c
index 22abb1d2..ecf738a9 100644
--- a/plugins/ommysql/ommysql.c
+++ b/plugins/ommysql/ommysql.c
@@ -35,8 +35,7 @@
#include <signal.h>
#include <errno.h>
#include <time.h>
-#include <mysql/mysql.h>
-#include <mysql/errmsg.h>
+#include <mysql.h>
#include "dirty.h"
#include "syslogd-types.h"
#include "srUtils.h"