Home page logo
/

nmap-dev logo Nmap Development mailing list archives

Re: nmap-5.50 bug compile on OS X
From: alexandru <alex () hackd net>
Date: Sat, 29 Jan 2011 18:27:44 -0800


On 2011-01-29, at 1:08 AM, David Munoz wrote:

Hi

On OS X 10.6.6, in using ./configure CPP=/opt/local/bin/cpp (gcc 4.5.2) or ./configure CPP=/usr/bin/cpp (Apple gcc 
4.2), during make phase, I have this error:
g++ -Lnbase -Lnsock/src/   -o nmap main.o nmap.o targets.o tcpip.o nmap_error.o utils.o idle_scan.o osscan.o 
osscan2.o output.o payload.o scan_engine.o timing.o charpool.o services.o protocols.o nmap_rpc.o portlist.o NmapOps.o 
TargetGroup.o Target.o FingerPrintResults.o service_scan.o NmapOutputTable.o MACLookup.o nmap_tty.o nmap_dns.o  
traceroute.o portreasons.o xml.o   -lnbase -lnsock -lpcre libpcap/libpcap.a -lssl -lcrypto libnetutil/libnetutil.a 
./libdnet-stripped/src/.libs/libdnet.a  -lm 
Undefined symbols:
 "get_script_scan_results_obj()", referenced from:
     nmap_main(int, char**) in nmap.o
 "script_scan(std::vector<Target*, std::allocator<Target*> >&, stype)", referenced from:
     nmap_main(int, char**) in nmap.o
     nmap_main(int, char**) in nmap.o
     nmap_main(int, char**) in nmap.o
 "ScriptResult::get_id() const", referenced from:
     formatScriptOutput(ScriptResult)       in output.o
     printhostscriptresults(Target*)     in output.o
     printscriptresults(std::list<ScriptResult, std::allocator<ScriptResult> >*, stype) in output.o
     printportoutput(Target*, PortList*)    in output.o
 "ScriptResult::get_output() const", referenced from:
     formatScriptOutput(ScriptResult)       in output.o
     printhostscriptresults(Target*)     in output.o
     printscriptresults(std::list<ScriptResult, std::allocator<ScriptResult> >*, stype) in output.o
     printportoutput(Target*, PortList*)    in output.o
 "open_nse()", referenced from:
     nmap_main(int, char**) in nmap.o
     nmap_main(int, char**) in nmap.o
 "close_nse()", referenced from:
     nmap_free_mem()     in nmap.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
make[1]: *** [nmap] Error 1
make: *** [all] Error 2

Please, could you describe me the right procedure to compile Nmap 5.50 on OS X?

Yours looks like the proper procedure; I can't reproduce your errors on my machine, with either plain ./configure or 
./configure CPP=/usr/bin/cpp (I don't have the vanilla gcc version)


What is your Xcode version?


quicksilver:nmap alexandru$ ./usr/bin/cpp --version
i686-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5664)
Copyright (C) 2007 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

quicksilver:nmap alexandru$ /usr/bin/cpp -v
Using built-in specs.
Target: i686-apple-darwin10
Configured with: /var/tmp/gcc/gcc-5664~89/src/configure --disable-checking --enable-werror --prefix=/usr 
--mandir=/share/man --enable-languages=c,objc,c++,obj-c++ --program-transform-name=/^[cg][^.-]*$/s/$/-4.2/ 
--with-slibdir=/usr/lib --build=i686-apple-darwin10 --program-prefix=i686-apple-darwin10- --host=x86_64-apple-darwin10 
--target=i686-apple-darwin10 --with-gxx-include-dir=/include/c++/4.2.1
Thread model: posix
gcc version 4.2.1 (Apple Inc. build 5664)
 /Developer/usr/bin/../libexec/gcc/i686-apple-darwin10/4.2.1/cc1 -E -traditional-cpp -quiet -v -I/usr/include 
-imultilib x86_64 -iprefix /Developer/usr/bin/../lib/gcc/i686-apple-darwin10/4.2.1/ -D__DYNAMIC__ - -fPIC 
-mmacosx-version-min=10.6.6 -m64 -mtune=core2
ignoring nonexistent directory 
"/Developer/usr/bin/../lib/gcc/i686-apple-darwin10/4.2.1/../../../../i686-apple-darwin10/include"
ignoring nonexistent directory "/usr/lib/gcc/i686-apple-darwin10/4.2.1/../../../../i686-apple-darwin10/include"
ignoring duplicate directory "/usr/include"
  as it is a non-system directory that duplicates a system directory
#include "..." search starts here:
#include <...> search starts here:
 /Developer/usr/bin/../lib/gcc/i686-apple-darwin10/4.2.1/include
 /usr/local/include
 /usr/lib/gcc/i686-apple-darwin10/4.2.1/include
 /usr/include
 /System/Library/Frameworks (framework directory)
 /Library/Frameworks (framework directory)
End of search list.


--
ατ

Attachment: PGP.sig
Description: This is a digitally signed message part

_______________________________________________
Sent through the nmap-dev mailing list
http://cgi.insecure.org/mailman/listinfo/nmap-dev
Archived at http://seclists.org/nmap-dev/

  By Date           By Thread  

Current thread:
[ Nmap | Sec Tools | Mailing Lists | Site News | About/Contact | Advertising | Privacy ]