help-cfengine
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 2.1.0p1 compile problem on Solaris8 (more info)


From: Frank Smith
Subject: Re: 2.1.0p1 compile problem on Solaris8 (more info)
Date: Tue, 11 Nov 2003 18:42:00 -0600

--On Wednesday, November 05, 2003 15:32:50 -0600 Frank Smith 
<fsmith@hoovers.com> wrote:

> When I try to build cfengine-2.1.0p1 on a Solaris 8 (sparc) box
> I get the following compile error:
> 
> gcc -DHAVE_CONFIG_H -I. -I. -I../src -I/usr/local/BerkeleyDB.4.0/include 
> -I/usr/local/ssl/include   -static -I/usr/local/BerkeleyDB.4.0/include -g -O2 
> -Wreturn-type -Wmissing-prototypes -Wuninitialized -static 
> -I/usr/local/BerkeleyDB.4.0/include -c
> `test -f 'full-write.c' || echo './'`full-write.c
> In file included from ../src/cf.defs.h:1855,
>                  from full-write.c:23:
> ../src/prototypes.h:756: conflicting types for `setnetgrent'
> /usr/include/netdb.h:283: previous declaration of `setnetgrent'
> ../src/prototypes.h:758: conflicting types for `endnetgrent'
> /usr/include/netdb.h:284: previous declaration of `endnetgrent'
> make[1]: *** [full-write.o] Error 1

Finally got some time to dig further into this.  The problem is
caused by configure thinking that the *netgrent functions don't
exist, which is incorrect.  The configure test script is being
compiled with the -static option, and the test program fails
with undefined sysmbols for _dlopen _dlclose and _dlsym since
there is no static (.a) version of libdl on Solaris, only the
shared (.o) version of the library.
   I got around this by just manually editing src/conf.h and changing
/* #undef HAVE_GETNETGRENT */
to:
#define HAVE_GETNETGRENT 1

However, from looking through config.log it looks like other
system functions also end up undefined for the same reason.

I've also had to remove the -static flag from the makefiles,
change YACC to be defined as yacc (configure had defined it as
'bison -y' which evidently isn't completely compatible), and
add -lnsl to the linker flags.
  Now I'm down to one error in linking cfagent, which is:
Undefined                       first referenced
 symbol                             in file
OPENSSL_add_all_algorithms_noconf   cfagent.o

A Google search seems to indicate that its picking up an
older (pre 0.9.7) openssl library, so I'll track that down
tomorrow.  With all the troubles I'm having, I'm somewhat
hesitant to actually install this when it does build.  However,
2.0.0 was previously built without problems on this same box.

Has anyone successfully built this on Solaris 8?  


> 
> 
> Any ideas on how to get around this (besides deleting system header
> files)?
> 
> Thanks,
> Frank



-- 
Frank Smith                                      fsmith@hoovers.com
Systems Administrator                           Voice: 512-374-4673
Hoover's Online                                   Fax: 512-374-4501





reply via email to

[Prev in Thread] Current Thread [Next in Thread]