[Nagiosplug-devel] Solaris 10: mysql plugin breaks 'make'

Ton Voon ton.voon at opsera.com
Tue May 19 10:18:26 CEST 2009


On 18 May 2009, at 15:15, Chris Pepper wrote:

>> If you are using GCC and your MySQL version was compiled using  
>> Sun's C compiler (or the other way round), then it is likely that  
>> the configure options will fail as configure will run mysql_config  
>> to get the appropriate CFLAGS.
>
> 	This assumes MySQL is installed. Our S10 boxen don't have MySQL, so  
> I'd amend as follows:
>
> If you are using GCC to build the plugins, but your MySQL version  
> was compiled using Sun's C compiler (or the other way round) -- or  
> if you don't have MySQL installed on Solaris at all -- then it is  
> likely that the default build procedure will fail, as configure  
> assumes it get appropriate CFLAGS by executing mysql_config.
>
> 	But really, configure shouldn't assume MySQL is present at all.

Hi Chris,

If mysql_config doesn't exist, then it assumes mysql does not exist  
and then doesn't try to compile check_mysql.

I think this is a reasonable course of action. The current logic is:
   * if you've been told to include mysql, then try to compile  
check_mysql
   * if you've been told not to include mysql, don't try to compile  
check_mysql
   * if you have not specified anything, then see if mysql_config is  
available and if it is the compile check_mysql

I think the last step could be enhanced to include trying to compile a  
very small mysql program and if that fails, then do not try  
check_mysql. Patches welcome.

(Copying to nagiosplug-devel list)

Ton





More information about the Devel mailing list