[hobbit] 4.1.2p1 Client Compile Problems on HP-UX 11.0

Adam Scheblein adam.scheblein at marquette.edu
Fri Nov 11 18:28:17 CET 2005


As a quick fix, (and a fix for an additional similar problem)  i changed 
the osdefs.h file to be the following (take note, i had to rename the 
snprintf and the socklen_t variables):

/*----------------------------------------------------------------------------*/
/* Hobbit monitor 
library.                                                    */
/* Compatibility definitions for various 
OS's                                 */
/*                                                                            
*/
/* Copyright (C) 2002-2005 Henrik Storner 
<henrik at storner.dk>                 */
/*                                                                            
*/
/* This program is released under the GNU General Public License 
(GPL),       */
/* version 2. See the file "COPYING" for 
details.                             */
/*                                                                            
*/
/*----------------------------------------------------------------------------*/

#ifndef __LIBBBGEN_OSDEFS_H__
#define __LIBBBGEN_OSDEFS_H__

#include "config.h"

#include <sys/types.h>
#include <stdarg.h>

#ifndef HAVE_SOCKLEN_T
typedef int hobbit_socklen_t;
#endif

#ifndef HAVE_SNPRINTF
extern int hobbit_snprintf(char *str, size_t size, const char *format, ...);
#endif

#ifndef HAVE_VSNPRINTF
extern int vsnprintf(char *str, size_t size, const char *format, va_list 
ap);
#endif

#endif


Adam Scheblein wrote:

> Greetings,
>
> When compiling the newest snapshot on HP-UX 11.0 with gcc, i get the 
> following error:
>
> CC="/usr/local/bin/gcc" CFLAGS="-g -O -D_REENTRANT -DHPUX -I. 
> -I`pwd`/include -DCLIENTONLY=1" OSDEF="-DHPUX" RPATHOPT="" 
> PCREINCDIR="" SSLFLAGS="" SSLINCDIR="" SSLLIBS="" NETLIBS="-lnsl" 
> BBTOPDIR="/home/hobbit" BBLOGDIR="" BBHOSTNAME="" 
> BBHOSTIP="134.48.22.240" BBHOSTOS="" LOCALCLIENT="no" 
> /usr/local/bin/gmake -C lib client
> gmake[1]: Entering directory `/home/hobbit/uploaded/snapshot/lib'
> /usr/local/bin/gcc -g -O -D_REENTRANT -DHPUX -I. 
> -I/home/hobbit/uploaded/snapshot/include -DCLIENTONLY=1 -I. 
> -I../include    -c -o osdefs.o osdefs.c
> In file included from osdefs.c:16:
> osdefs.h:25: error: conflicting types for `snprintf'
> /usr/local/lib/gcc-lib/hppa2.0n-hp-hpux11.00/3.3.2/include/stdio.h:493: 
> error: previous declaration of `snprintf'
> gmake[1]: *** [osdefs.o] Error 1
> gmake[1]: Leaving directory `/home/hobbit/uploaded/snapshot/lib'
> gmake: *** [lib-client] Error 2
>
>
> Any ideas?
>
> thanks,
> Adam
>
> To unsubscribe from the hobbit list, send an e-mail to
> hobbit-unsubscribe at hswn.dk
>
>




More information about the Xymon mailing list