diff options
author | Eric Stanley <estanley@nagios.com> | 2011-12-16 10:18:41 -0600 |
---|---|---|
committer | Eric Stanley <estanley@nagios.com> | 2011-12-16 10:18:41 -0600 |
commit | 55fb4097cd416aecd778ccb82e731d25f3ee6fce (patch) | |
tree | 6ab83e079bbac68f0cc34f3dca92dbe468bc34bf /m4 | |
parent | 5532dbe48a485edb7f75c5058a2aac87090f66d3 (diff) | |
download | monitoring-plugins-55fb4097cd416aecd778ccb82e731d25f3ee6fce.tar.gz |
Fixed issue for compiling mysql plugin on Solaris
On Solaris, in the case where the mysql libraries were compiled using a
non-gcc compiler, but the plugins are being compiled with gcc, the configure
process would incorrectly determine the MYSQLCFLAGS. This has been corrected
in the m4/np_mysqlclient.m4 file.
Diffstat (limited to 'm4')
-rw-r--r-- | m4/np_mysqlclient.m4 | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/m4/np_mysqlclient.m4 b/m4/np_mysqlclient.m4 index 9bbe63c6..cd36c4f7 100644 --- a/m4/np_mysqlclient.m4 +++ b/m4/np_mysqlclient.m4 | |||
@@ -42,6 +42,12 @@ AC_DEFUN([np_mysqlclient], | |||
42 | fi | 42 | fi |
43 | np_mysql_libs="`$np_mysql_config --libs`" | 43 | np_mysql_libs="`$np_mysql_config --libs`" |
44 | np_mysql_cflags="`$np_mysql_config --cflags`" | 44 | np_mysql_cflags="`$np_mysql_config --cflags`" |
45 | # On Solaris, cflags may contain -xstrconst, which is not acceptable to the | ||
46 | # gcc compiler. In this case, use the include flags as the cflags | ||
47 | echo $np_mysql_cflags | grep -- -xstrconst > /dev/null 2> /dev/null | ||
48 | if test $? -eq 0 -a "$CC" = "gcc" ; then | ||
49 | np_mysql_cflags="`$np_mysql_config --include`" | ||
50 | fi | ||
45 | 51 | ||
46 | dnl Test a mysql_init. Some systems have mysql_config, but no headers | 52 | dnl Test a mysql_init. Some systems have mysql_config, but no headers |
47 | _savedcppflags="$CPPFLAGS" | 53 | _savedcppflags="$CPPFLAGS" |