Ndoutil confiture script failed to set mysql include path

Patrick Proy nagios at proy.org
Wed May 9 20:34:17 CEST 2007


Hi,

I had a problem when compiling Ndoutil 1.4b3 on a RHEL4 with MySQL in a
special directory : 

I run the configure script : 

-------------------
./configure --prefix=<prefix> --with-mysql-lib=<path1>
--with-mysql-inc=<path2>
-------------------
MySQL detection by configure was OK (lib + include files).

Then : 

-------------------
# make
cd ./src/; make ; cd ..
make[1]: Entering directory `/usr/local/src/Nagios/ndoutils-1.4b3/src'
gcc -fPIC -O0 -g -DHAVE_CONFIG_H -c -o io.o io.c
In file included from io.c:10:
../include/config.h:250:25: mysql/mysql.h: No such file or directory
../include/config.h:251:26: mysql/errmsg.h: No such file or directory
make[1]: *** [io.o] Error 1
make[1]: Leaving directory `/usr/local/src/Nagios/ndoutils-1.4b3/src'
-------------------

I had to change manually the include/config.h file, lines 250 & 251 to :

    246 #define USE_MYSQL 1
    247 /* #undef HAVE_MYSQL */
    248 #ifdef USE_MYSQL
    249 #define HAVE_MYSQL 1
    250 #include "<path2>/mysql/mysql.h"
    251 #include "<path2>/mysql/errmsg.h"
    252 #endif

Then it would compile OK.

Maybe it's something I did wrong (found nothing on Google about it), but
probably the configure script should modify this path too.

An init script for ndo2db included in the tgz would be great (found one here
:
http://nagios-portal.de/forum/print.php?threadid=5261&page=1&sid=846621ddd01
ffbc5ee89bdf949e311d6, but I had to modify path & user)

Regards,

Patrick
http://nagios.manubulon.com


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/




More information about the Developers mailing list