Nmap Development mailing list archives
Re: nmap 5.21 on Solaris with Sun Studio 12u1 fails
From: David Fifield <david () bamsoftware com>
Date: Mon, 22 Nov 2010 20:14:54 -0800
On Thu, Nov 11, 2010 at 02:32:31PM +1100, Mark Ashley wrote:
Note: The nmap-dev archive search function fails, it's probably my NoScript but I can't see which domain it requires. (I forbid googlesyndication etc) I'm getting failures to compile on all version of Solaris I'm trying using the Sun Studio 12 update 1 compiler. I'm trying on Solaris 10 x86 and Solaris 10 SPARC 64bit and OpenSolaris x86 simultaneously. Compiler: I've got the latest Sun Studio 12u1 compiler and patches installed. Image: sol_sparc_spro_12_1 Contents: 11 patches listed in app_patches directory 118683-03 119963-13 120753-06 128228-11 128231-01 128232-01 141854-01 141860-03 141861-06 142369-01 142371-01 Image: sol_i86pc_spro_12_1 Contents: 10 patches listed in app_patches directory 119961-07 119964-20 120754-08 128229-11 141852-01 141853-01 141855-01 141858-07 142363-06 142368-01 Libraries: I have pre-compiled versions of the libraries, except for libdnet # ls -1 | egrep '(openssl|lua|libpcap|pcre)' libpcap.1.1.1.SPARC.64bit.Solaris.10.pkg libpcap.1.1.1.i86pc.Solaris.10.pkg libpcap.1.1.1.i86pc.Solaris.11.pkg lua.5.1.4.SPARC.64bit.Solaris.10.pkg lua.5.1.4.i86pc.Solaris.10.pkg lua.5.1.4.i86pc.Solaris.11.pkg openssl.0.9.8o.SPARC.64bit.Solaris.10.pkg openssl.0.9.8o.i86pc.Solaris.10.pkg openssl.0.9.8o.i86pc.Solaris.11.pkg pcre.8.10.SPARC.64bit.Solaris.10.pkg pcre.8.10.i86pc.Solaris.10.pkg pcre.8.10.i86pc.Solaris.11.pkg Environment: CC=cc CXX=CC -features=extensions LDFLAGS=-I/usr/local/include -L/usr/local/lib CPPFLAGS=-I/usr/local/include -L/usr/local/lib and CC=cc -xtarget=ultra -m64 -xcode=pic32 CXX=CC -xtarget=ultra -m64 -xcode=pic32 -features=extensions LDFLAGS=-I/usr/local/include -L/usr/local/lib CPPFLAGS=-I/usr/local/include -L/usr/local/lib Commands: cd /var/tmp rm -rf /nmap nmap-5.21 unbgz /usr/local/src/net/nmap-5.21.tar.bz2 cd nmap-5.21 mkdir /nmap /bin/perl -pe 's#ac_cv_dnet_linux_pf_packet=yes#ac_cv_dnet_linux_pf_packet=no#' -i libdnet-stripped/configure /bin/perl -pe 's#ac_cv_dnet_linux_pf_packet=yes#ac_cv_dnet_linux_pf_packet=no#' -i libdnet-stripped/config/acinclude.m4 /bin/perl -pe 's#-MM##' -i Makefile.in /bin/perl -pe 's#-MM##' -i ncat/Makefile.in /bin/perl -pe 's#-MM##' -i liblua/Makefile.in /bin/perl -pe 's#-MM##' -i nsock/src/Makefile.in /bin/perl -pe 's#^makefile.dep#xyzzy#' -i Makefile.in /bin/perl -pe 's#^makefile.dep#xyzzy#' -i ncat/Makefile.in /bin/perl -pe 's#^makefile.dep#xyzzy#' -i nsock/src/Makefile.in /bin/perl -pe 's#^include makefile.dep##' -i Makefile.in /bin/perl -pe 's#^include makefile.dep##' -i ncat/Makefile.in /bin/perl -pe 's#^include makefile.dep##' -i nsock/src/Makefile.in autoconf; aclocal; automake --add-missing; autoconf ./configure --prefix=/nmap \ --with-pcre=/usr/local \ --with-liblua=/usr/local \ --with-libpcap=/usr/local \ --with-openssl=/usr/local \ --with-libdnet=included gmake Background: I had to skip all the makefile.dep stuff, it just will never work with this compiler apparently. Massive error output and every file failed. e.g.: "nbase/nbase.h", line 187: Error: uint8_t is not defined. "nbase/nbase.h", line 188: Error: int8_t is not defined. "nbase/nbase.h", line 189: Error: uint16_t is not defined. "nbase/nbase.h", line 190: Error: int16_t is not defined. "nbase/nbase.h", line 191: Error: uint32_t is not defined. "nbase/nbase.h", line 192: Error: int32_t is not defined. "nbase/nbase.h", line 193: Error: uint64_t is not defined. "nbase/nbase.h", line 194: Error: int64_t is not defined. "nbase/getopt.h", line 46: Error: Only one of a set of overloaded functions can be extern "C". "nbase/nbase.h", line 436: Error: fd_set is not defined. "nbase/nbase.h", line 436: Error: "," expected instead of ")". "nbase/nbase.h", line 455: Error: "fselect(int)" is expected to return a value. "nmap.h", line 124: Error: Only one of a set of overloaded functions can be extern "C". "nmap.h", line 125: Error: Only one of a set of overloaded functions can be extern "C". "/usr/include/sys/time.h", line 450: Error: Only one of a set of overloaded functions can be extern "C". "/usr/include/stdio.h", line 324: Error: Only one of a set of overloaded functions can be extern "C". "/usr/include/netinet/ip.h", line 57: Error: In this declaration "ip_src" is of an incomplete type "in_addr". "/usr/include/netinet/ip.h", line 57: Error: In this declaration "ip_dst" is of an incomplete type "in_addr". "/usr/include/netinet/ip.h", line 144: Error: In this declaration "ipt_addr" is of an incomplete type "in_addr". "/opt/sunstudio12.1/prod/include/CC/Cstd/rw/rwdispatch.h", line 33: Error: Template declarations cannot have extern "C" linkage. "/opt/sunstudio12.1/prod/include/CC/Cstd/rw/rwdispatch.h", line 41: Error: Only one of a set of overloaded functions can be extern "C". "/opt/sunstudio12.1/prod/include/CC/Cstd/rw/rwdispatch.h", line 44: Error: Only one of a set of overloaded functions can be extern "C". "/opt/sunstudio12.1/prod/include/CC/Cstd/rw/rwdispatch.h", line 44: Error: Only one of a set of overloaded functions can be extern "C". "/opt/sunstudio12.1/prod/include/CC/Cstd/rw/rwdispatch.h", line 47: Error: Only one of a set of overloaded functions can be extern "C". "/opt/sunstudio12.1/prod/include/CC/Cstd/rw/rwdispatch.h", line 47: Error: Only one of a set of overloaded functions can be extern "C". Compilation aborted, too many Error messages. Compile Problem: The normal compile breaks on osscan.cc with some C++ stuff that's beyond me to fix. I don't know the language at all. I've exhausted google hunting for a solution. Any help you can provide would be great. CC -features=extensions -c -I/usr/include/lua -I/usr/local/include -Ilibdnet-stripped/include -I/usr/local/include -I/usr/local/include -I/usr/local/include -L/usr/local/lib -I/usr/local/include -Inbase -Insock/include -g -DHAVE_CONFIG_H -DNMAP_NAME=\"Nmap\" -DNMAP_URL=\" http://nmap.org\" -DNMAP_PLATFORM=\"i386-pc-solaris2.11\" -DNMAPDATADIR=\"/nmap/share/nmap\" -D_FORTIFY_SOURCE=2 osscan.cc -o osscan.o "nbase/nbase.h", line 250: Warning: attribute format is unsupported and will be skipped.. "nbase/nbase.h", line 256: Warning: attribute format is unsupported and will be skipped.. "nbase/nbase.h", line 385: Warning: attribute format is unsupported and will be skipped.. "nbase/nbase.h", line 387: Warning: attribute format is unsupported and will be skipped.. "osscan.cc", line 196: Warning: name hides FingerTest::name. "osscan.cc", line 743: Error: Could not find a match for std::list<const FingerTest*>::sort(bool(const FingerTest*,const FingerTest*)) needed in mergeFPs(FingerPrint**, int, bool, const in_addr*const, int, dist_calc_method, const unsigned char*, int, int, int, bool). 1 Error(s) and 5 Warning(s) detected. gmake[1]: *** [osscan.o] Error 1 gmake[1]: Leaving directory `/var/tmp/nmap-5.21' gmake: *** [all] Error 2
My best guess is that the C++ STL (Standard Template Library) is missing the std::list::sort member function. This link appears to confirm it: http://docs.sun.com/source/820-4155/c++_faq.html#LibComp3 There's some information at that link about using an alternate library called STLport that might work for you. David Fifield _______________________________________________ Sent through the nmap-dev mailing list http://cgi.insecure.org/mailman/listinfo/nmap-dev Archived at http://seclists.org/nmap-dev/
Current thread:
- nmap 5.21 on Solaris with Sun Studio 12u1 fails Mark Ashley (Nov 10)
- Re: nmap 5.21 on Solaris with Sun Studio 12u1 fails David Fifield (Nov 22)