On Saturday 30 May 2009 06:55, I wrote:
> Trying to compile openvas (specifically openvas-libraries-2.0.2) on a Mac
> (10.5.8) using Mac Ports to add necessary libraries. Mac Ports puts files
> into /opt/local/include and /opt/local/lib, so I should need something
> like:
>
> LDFLAGS=-L/opt/local/lib
> CPPFLAGS=-I/opt/local/include

I managed to get this past the ./compile stage (it helps to remember that -l 
and -I look identical in my mailreader). But the make is dying in an unusual 
way, and with only a rudimentary knowledge of C I don't know what to make of 
it.

The make output features a series of calls to gcc that look like the 
following:

gcc -pipe -I../ -DHAVE_CONFIG_H -I. -I/opt/local/src/openvas- 
libraries-2.0.2/include -I/usr/local/include -I/opt/local/include/ 
glib-2.0 -I/opt/local/lib/glib-2.0/include -I/opt/local/include - 
DHAVE_CONFIG_H -g -Wall -c openvas_ssh_login.c -o openvas_ssh_login.o  
 >/dev/null 2>&1

Then a bunch of stuff happens, and the next time gcc gets a similar call it 
looks like this:

gcc -pipe -DHAVE_CONFIG_H -I. -I/opt/local/src/openvas-libraries-2.0.2/ 
include -I/usr/local/include -Wall -I../libopenvas -c hg_utils.c  -fno- 
common -DPIC -o .libs/hg_utils.o

The includes are gone except for /usr/local/include, gcc can't find 
/opt/local/include/gnutls, and the compile stops.

Anyone have any ideas about what's going on here, and is this the kind of 
thing I should file a bug report for? The complete sequence:

gcc -pipe -I../ -DHAVE_CONFIG_H -I. -I/opt/local/src/openvas- 
libraries-2.0.2/include -I/usr/local/include -I/opt/local/include/ 
glib-2.0 -I/opt/local/lib/glib-2.0/include -I/opt/local/include - 
DHAVE_CONFIG_H -g -Wall -c openvas_ssh_login.c -o openvas_ssh_login.o  
 >/dev/null 2>&1
/bin/sh /opt/local/src/openvas-libraries-2.0.2/libtool gcc -pipe -L/ 
opt/local/lib -o libopenvas.la plugutils.lo system.lo network.lo  
resolve.lo arglists.lo ftp_funcs.lo scanners_utils.lo pcap.lo hlst.lo   
harglists.lo www_funcs.lo ids_send.lo rand.lo popen.lo bpf_share.lo  
services.lo services1.lo proctitle.lo store.lo kb.lo share_fd.lo  
hash_table_file.lo openvas_ssh_login.lo -lutil -lpcap -lgnutls - 
lresolv  -L/usr/local/lib -L/opt/local/lib -lglib-2.0 -lintl -liconv    
-rpath /usr/local/lib \
        -version-info 2:2:0
*** Warning: inferring the mode of operation is deprecated.
*** Future versions of Libtool will require --mode=MODE be specified.
gcc -dynamiclib ${wl}-flat_namespace ${wl}-undefined ${wl}suppress - 
o .libs/libopenvas.2.0.2.dylib  .libs/plugutils.o .libs/system.o .libs/ 
network.o .libs/resolve.o .libs/arglists.o .libs/ftp_funcs.o .libs/ 
scanners_utils.o .libs/pcap.o .libs/hlst.o .libs/harglists.o .libs/ 
www_funcs.o .libs/ids_send.o .libs/rand.o .libs/popen.o .libs/ 
bpf_share.o .libs/services.o .libs/services1.o .libs/proctitle.o .libs/ 
store.o .libs/kb.o .libs/share_fd.o .libs/hash_table_file.o .libs/ 
openvas_ssh_login.o  -L/opt/local/lib -lutil -lpcap /opt/local/lib/ 
libgnutls.dylib /opt/local/lib/libtasn1.dylib /opt/local/lib/ 
libz.dylib /opt/local/lib/libgcrypt.dylib /opt/local/lib/libgpg- 
error.dylib -lresolv -L/usr/local/lib /opt/local/lib/ 
libglib-2.0.dylib /opt/local/lib/libintl.dylib /opt/local/lib/ 
libiconv.dylib  -install_name  /usr/local/lib/libopenvas.2.dylib -Wl,- 
compatibility_version -Wl,3 -Wl,-current_version -Wl,3.2
ld: warning, duplicate dylib /opt/local/lib/libz.1.dylib
(cd .libs && rm -f libopenvas.2.dylib && ln -s libopenvas.2.0.2.dylib  
libopenvas.2.dylib)
(cd .libs && rm -f libopenvas.dylib && ln -s libopenvas.2.0.2.dylib  
libopenvas.dylib)
ar cru .libs/libopenvas.a  plugutils.o system.o network.o resolve.o  
arglists.o ftp_funcs.o scanners_utils.o pcap.o hlst.o harglists.o  
www_funcs.o ids_send.o rand.o popen.o bpf_share.o services.o  
services1.o proctitle.o store.o kb.o share_fd.o hash_table_file.o  
openvas_ssh_login.o
ranlib .libs/libopenvas.a
creating libopenvas.la
(cd .libs && rm -f libopenvas.la && ln -s ../libopenvas.la  
libopenvas.la)
cd libopenvas_hg && make
/bin/sh /opt/local/src/openvas-libraries-2.0.2/libtool --mode=compile   
gcc -pipe -DHAVE_CONFIG_H   -I. -I/opt/local/src/openvas- 
libraries-2.0.2/include -I/usr/local/include  -Wall -I../libopenvas -c  
hg_utils.c
mkdir .libs
gcc -pipe -DHAVE_CONFIG_H -I. -I/opt/local/src/openvas-libraries-2.0.2/ 
include -I/usr/local/include -Wall -I../libopenvas -c hg_utils.c  -fno- 
common -DPIC -o .libs/hg_utils.o
In file included from /opt/local/src/openvas-libraries-2.0.2/include/ 
libopenvas.h:48,
              from /opt/local/src/openvas-libraries-2.0.2/include/ 
includes.h:233,
              from hg_utils.c:19:
../libopenvas/network.h:30:27: error: gnutls/gnutls.h: No such file or  
directory
In file included from /opt/local/src/openvas-libraries-2.0.2/include/ 
libopenvas.h:48,
              from /opt/local/src/openvas-libraries-2.0.2/include/ 
includes.h:233,
              from hg_utils.c:19:
../libopenvas/network.h:91: error: syntax error before '*' token
../libopenvas/network.h:91: warning: type defaults to 'int' in  
declaration of 'ovas_get_tlssession_from_connection'
../libopenvas/network.h:91: warning: data definition has no type or  
storage class
make[1]: *** [hg_utils.o] Error 1
make: *** [all] Error 2

Thanks for any assistance.

-- 
Jeff Simmons                                   [email protected]
Simmons Consulting - Network Engineering, Administration, Security
"You guys, I don't hear any noise.  Are you sure you're doing it right?"
        --  My Life With The Thrill Kill Kult
_______________________________________________
Openvas-discuss mailing list
[email protected]
http://lists.wald.intevation.org/mailman/listinfo/openvas-discuss

Reply via email to