You are right,
it is defined in /usr/include/netinet/in.h
The problem was that:
when I execute "make" in /sema/home/palmenti/net-snmp-5.4/snmplib
I have the following error:
gcc -I../include -I. -I../snmplib -g -O2 -Uhpux11 -Dhpux11=hpux11
-D_LABEL_T -c snmp_api.c -fPIC -DPIC -o .libs/snmp_api.o
In file included from snmp_api.c:88:
/usr/include/sys/socket.h:484: parse error before "sendfile"
/usr/include/sys/socket.h:485: parse error before "bsize_t"
/usr/include/sys/socket.h:486: parse error before "sendpath"
/usr/include/sys/socket.h:487: parse error before "bsize_t"
snmp_api.c: In function `snmp_add_var':
snmp_api.c:6928: warning: assignment makes pointer from integer without
a cast
snmp_api.c:6928: warning: assignment makes pointer from integer without
a cast
*** Error exit code 1
To avoid this, I put on gcc line the "-D_XOPEN_SOURCE_EXTENDED=1"
And this eliminate the problem, BUT
In /usr/include/netinet/in.h there is:
#ifndef _XOPEN_SOURCE_EXTENDED
/*
* Macros for number representation conversion.
*/
#ifndef ntohl
#define ntohl(x) (x)
#define ntohs(x) (x)
#define htonl(x) (x)
#define htons(x) (x)
#endif
#endif /* ! _XOPEN_SOURCE_EXTENDED */
So, how Can I do?
Nunzio Palmentieri
Web Care Solution
Atos Origin
Via Antiniana 2/a
80078 Pozzuoli (NA) - ITALY
Direct +39 081 6103 388
Mobile +39 335 1214 806
Fax +39 081 6103 200
e-mail mailto:[EMAIL PROTECTED]
Web www.atosorigin.com
This electronic message contains information from Atos Origin, which may
be privileged and confidential. The information is intended to be use of
the individual(s) or entity named above. If you are not the intended
recipient, be aware that any disclosure, copying, distribution or use of
the contents of this information is prohibited.
-----Messaggio originale-----
Da: Thomas Anders [mailto:[EMAIL PROTECTED]
Inviato: giovedì 29 marzo 2007 15.17
A: Palmentieri Nunzio
Cc: net-snmp-coders@lists.sourceforge.net
Oggetto: Re: R: netsnmp on HP-UX 11.11
Palmentieri Nunzio wrote:
> /usr/lib/dld.sl: Unresolved symbol: htonl (code)
That's likely related to your custom build hacks. htonl() is a macro
defined as
#define htonl(x) (x)
so shouldn't end up as an external symbol at all.
+Thomas
--
Thomas Anders (thomas.anders at blue-cable.de)
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Net-snmp-coders mailing list
Net-snmp-coders@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders