Nmap Development mailing list archives
Re: [PATCH] Get nmap 3.77 compiling on HP-UX
From: Albert Chin <nmap-dev () mlists thewrittenword com>
Date: Tue, 23 Nov 2004 12:07:52 -0600
On Wed, Nov 17, 2004 at 05:14:38PM +0100, Petter Reinholdtsen wrote:
The following patch fixes the build on HP-UX. The namespace hacking is to work around a problem on HP-UX 11.00, lacking the std namespace (but the compiler understand the notation, and refuses to compile 'using namespace std;' as long as the name space is undefined. diff -ur src-3.77/output.cc src-3.77-local/output.cc --- src-3.77/output.cc 2004-11-06 04:41:53.000000000 +0100 +++ src-3.77-local/output.cc 2004-11-17 17:04:03.000000000 +0100 @@ -111,6 +111,10 @@ #include <string> +/* Workaround for lack of namespace std on HP-UX 11.00 */ +namespace std {}; +using namespace std; + extern NmapOps o; static char *logtypes[LOG_TYPES]=LOG_NAMES; @@ -120,7 +124,7 @@ // returns 0 for success. static int getServiceXMLBuf(struct serviceDeductions *sd, char *xmlbuf, unsigned int xmlbuflen) { - std::string versionxmlstring; + string versionxmlstring; char rpcbuf[128]; char *xml_product = NULL, *xml_version = NULL, *xml_extrainfo = NULL;
What version of the aCC compiler are you using? With A.03.52 and -AA, the patch above is not needed. -- albert chin (china () thewrittenword com) --------------------------------------------------------------------- For help using this (nmap-dev) mailing list, send a blank email to nmap-dev-help () insecure org . List archive: http://seclists.org
Current thread:
- [PATCH] Get nmap 3.77 compiling on HP-UX Petter Reinholdtsen (Nov 17)
- Re: [PATCH] Get nmap 3.77 compiling on HP-UX Fyodor (Nov 17)
- Re: [PATCH] Get nmap 3.77 compiling on HP-UX Petter Reinholdtsen (Nov 17)
- Re: [PATCH] Get nmap 3.77 compiling on HP-UX Fyodor (Nov 17)
- Re: [PATCH] Get nmap 3.77 compiling on HP-UX Petter Reinholdtsen (Nov 17)
- Re: [PATCH] Get nmap 3.77 compiling on HP-UX Albert Chin (Nov 23)
- Re: [PATCH] Get nmap 3.77 compiling on HP-UX Petter Reinholdtsen (Nov 23)
- Re: [PATCH] Get nmap 3.77 compiling on HP-UX Albert Chin (Nov 23)
- Performance Tuning NMAP Bill Petersen (Dec 17)
- Re: Performance Tuning NMAP Okan Demirmen (Dec 17)
- Re: Performance Tuning NMAP Martin Mačok (Dec 18)
- Re: [PATCH] Get nmap 3.77 compiling on HP-UX Petter Reinholdtsen (Nov 23)
- Re: [PATCH] Get nmap 3.77 compiling on HP-UX Fyodor (Nov 17)