<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 5.5.2656.60">
<TITLE>RE : [Nagios-users] Compiling MySQL NEB Module</TITLE>
</HEAD>
<BODY>
<P><FONT SIZE=2>Which version of mysql do you use ?</FONT>
</P>
<P><FONT SIZE=2>In my configuration (mysql 4.1.10a), inserter.c includes mysql.h, which includes mysql_com.h, where you find :</FONT>
</P>
<P><FONT SIZE=2>#define CLIENT_MULTI_STATEMENTS 65536</FONT>
</P>
<P><FONT SIZE=2>So, I confirm that you don't have to change the code. Instead, check your mysql client.</FONT>
</P>
<P><FONT SIZE=2>> -----Original Message-----</FONT>
<BR><FONT SIZE=2>> From: Mohr James [<A HREF="mailto:james.mohr@elaxy.com">mailto:james.mohr@elaxy.com</A>] </FONT>
<BR><FONT SIZE=2>> Sent: Wednesday, June 08, 2005 4:08 PM</FONT>
<BR><FONT SIZE=2>> To: Nagios-users@lists.sourceforge.net</FONT>
<BR><FONT SIZE=2>> Subject: [Nagios-users] Compiling MySQL NEB Module</FONT>
<BR><FONT SIZE=2>> </FONT>
<BR><FONT SIZE=2>> </FONT>
<BR><FONT SIZE=2>> Hi All!</FONT>
<BR><FONT SIZE=2>> </FONT>
<BR><FONT SIZE=2>> When running make on the MySQL NEB Module I get:</FONT>
<BR><FONT SIZE=2>> </FONT>
<BR><FONT SIZE=2>> inserter.c: In function `nebmodule_init':</FONT>
<BR><FONT SIZE=2>> inserter.c:130: error: `CLIENT_MULTI_STATEMENTS' undeclared </FONT>
<BR><FONT SIZE=2>> (first use in this function)</FONT>
<BR><FONT SIZE=2>> inserter.c:130: error: (Each undeclared identifier is </FONT>
<BR><FONT SIZE=2>> reported only once</FONT>
<BR><FONT SIZE=2>> inserter.c:130: error: for each function it appears in.)</FONT>
<BR><FONT SIZE=2>> make: *** [all] Error 1</FONT>
<BR><FONT SIZE=2>> </FONT>
<BR><FONT SIZE=2>> I changed the makefile to point to the correct nagios include </FONT>
<BR><FONT SIZE=2>> directory and the mysql include directory was correct from the start:</FONT>
<BR><FONT SIZE=2>> </FONT>
<BR><FONT SIZE=2>> all:</FONT>
<BR><FONT SIZE=2>> gcc -g -O2 -Wall -o inserter.o inserter.c -shared </FONT>
<BR><FONT SIZE=2>> -I/opt/INSTALL/nagios/nagios.src/nagios-2.0b3/include</FONT>
<BR><FONT SIZE=2>> -I/usr/include/mysql -lmysqlclient -fPIC</FONT>
<BR><FONT SIZE=2>> </FONT>
<BR><FONT SIZE=2>> </FONT>
<BR><FONT SIZE=2>> I don't want to change the code to explizitely define it </FONT>
<BR><FONT SIZE=2>> myself until I am sure that is what I need to do. Any help is </FONT>
<BR><FONT SIZE=2>> greatly appreaciated.</FONT>
<BR><FONT SIZE=2>> </FONT>
<BR><FONT SIZE=2>> Regards,</FONT>
<BR><FONT SIZE=2>> </FONT>
<BR><FONT SIZE=2>> Jim Mohr</FONT>
<BR><FONT SIZE=2>> </FONT>
<BR><FONT SIZE=2>> </FONT>
<BR><FONT SIZE=2>> -------------------------------------------------------</FONT>
<BR><FONT SIZE=2>> This SF.Net email is sponsored by: NEC IT Guy Games. How far </FONT>
<BR><FONT SIZE=2>> can you shotput a projector? How fast can you ride your desk </FONT>
<BR><FONT SIZE=2>> chair down the office luge track? If you want to score the </FONT>
<BR><FONT SIZE=2>> big prize, get to know the little guy. </FONT>
<BR><FONT SIZE=2>> Play to win an NEC 61" plasma display: <A HREF="http://www.necitguy.com/?r" TARGET="_blank">http://www.necitguy.com/?r</A> </FONT>
<BR><FONT SIZE=2>> _______________________________________________</FONT>
<BR><FONT SIZE=2>> Nagios-users mailing list</FONT>
<BR><FONT SIZE=2>> Nagios-users@lists.sourceforge.net</FONT>
<BR><FONT SIZE=2>> <A HREF="https://lists.sourceforge.net/lists/listinfo/nagios-users" TARGET="_blank">https://lists.sourceforge.net/lists/listinfo/nagios-users</A></FONT>
<BR><FONT SIZE=2>> ::: Please include Nagios version, plugin version (-v) and OS </FONT>
<BR><FONT SIZE=2>> when reporting any issue. </FONT>
<BR><FONT SIZE=2>> ::: Messages without supporting info will risk being sent to /dev/null</FONT>
<BR><FONT SIZE=2>> </FONT>
</P>
</BODY>
</HTML>