Alex is really the VC++ authority of the bunch, but it looks to me like maybe a winsock issue? Is wsock32 (I believe) being linked in properly? Is the winsock header in your include path?
Something is wrong here.. It looks like you need the Platform SDK installed to compile the non-SDK project.
socklen_t is defined in the SDK's WS2tcpip.h and WSPiApi.h. I tested this by unregistering the SDK with my MSVC. I'll have to look into this.
Until it's fixed, installing the Platform SDK should solve your problem. If you already installed it, did you remember to register it via the shortcut in the start menu?
Alex
Regards, Andy
A B wrote:
Hi,
I'm trying to install net-snmp 5.1.2 in a Windows XP, but I keep get compilation errors. I've tried using the build.bat utility and also the provided VC++ workspaces, but the result is the same ( I'm compiling both Debug and Release )
I've tried both with and without the SDK option. I'm not using SSL.
According to the documentation this should be a simple process. I've searched the web for similar problems but nothing is reported. I'm using Windows XP SP1, net-snmp 5.1.2, MS VC++ 6.0.
Here�s a sample of the output results when I try to build:
(start) ************* --------------------Configuration: libsnmp - Win32 Release--------------------
Compiling...
asn1.c
callback.c
check_varbind.c
cmu_compat.c
container.c
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\container.c(31) : warning C4090: 'function' : different 'const' qualifiers
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\container.c(31) : warning C4022: 'free' : pointer mismatch for actual parameter 1
container_binary_array.c
container_iterator.c
container_list_ssll.c
container_null.c
data_list.c
default_store.c
getopt.c
inet_ntop.c
inet_pton.c
int64.c
keytools.c
lcd_time.c
md5.c
mib.c
mt_support.c
oid_stash.c
parse.c
read_config.c
scapi.c
snmp-tc.c
snmp.c
snmp_alarm.c
snmp_api.c
snmp_auth.c
snmp_client.c
snmp_debug.c
snmp_enum.c
snmp_logging.c
snmp_parse_args.c
snmp_secmod.c
snmp_transport.c
snmp_version.c
snmpCallbackDomain.c
snmpTCPDomain.c
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpTCPDomain.c(172) : error C2065: 'socklen_t' : undeclared identifier
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpTCPDomain.c(172) : error C2146: syntax error : missing ';' before identifier 'farendlen'
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpTCPDomain.c(172) : error C2065: 'farendlen' : undeclared identifier
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpTCPDomain.c(173) : error C2143: syntax error : missing ';' before 'type'
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpTCPDomain.c(201) : error C2065: 'string' : undeclared identifier
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpTCPDomain.c(201) : warning C4047: '=' : 'int ' differs in levels of indirection from 'char *'
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpTCPDomain.c(203) : warning C4022: 'free' : pointer mismatch for actual parameter 1
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpTCPDomain.c(233) : error C2143: syntax error : missing '{' before '*'
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpTCPDomain.c(235) : error C2371: 'netsnmp_tcp_transport' : redefinition; different basic types
..\..\include\net-snmp/library/snmpTCPDomain.h(22) : see declaration of 'netsnmp_tcp_transport'
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpTCPDomain.c(372) : warning C4133: 'return' : incompatible types - from 'struct netsnmp_transport_s *' to 'int *'
snmpTCPIPv6Domain.c
snmpUDPDomain.c
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpUDPDomain.c(109) : error C2065: 'socklen_t' : undeclared identifier
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpUDPDomain.c(109) : error C2146: syntax error : missing ';' before identifier 'fromlen'
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpUDPDomain.c(109) : error C2065: 'fromlen' : undeclared identifier
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpUDPDomain.c(110) : error C2143: syntax error : missing ';' before 'type'
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpUDPDomain.c(113) : error C2065: 'from' : undeclared identifier
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpUDPDomain.c(113) : warning C4047: '=' : 'int ' differs in levels of indirection from 'struct sockaddr *'
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpUDPDomain.c(114) : warning C4047: '==' : 'int ' differs in levels of indirection from 'void *'
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpUDPDomain.c(119) : warning C4022: 'memset' : pointer mismatch for actual parameter 1
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpUDPDomain.c(123) : warning C4047: 'function' : 'struct sockaddr *' differs in levels of indirection from 'int '
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpUDPDomain.c(123) : warning C4024: 'recvfrom' : different types for formal and actual parameter 5
C:\Program Files\Net-SNMP 5.1.2\net-snmp-5.1.2\snmplib\snmpUDPDomain.c(130) : warning C4022: 'netsnmp_udp_fmtaddr' : pointer mismatch for actual parameter 2
snmpUDPIPv6Domain.c
snmpusm.c
snmpv3.c
strlcpy.c
system.c
tools.c
ucd_compat.c
vacm.c
winpipe.c
Error executing cl.exe.
netsnmp.lib - 12 error(s), 11 warning(s)
(end)*****************************
Thanks,
------------------------------------------------------- This SF.net email is sponsored by: IT Product Guide on ITManagersJournal Use IT products in your business? Tell us what you think of them. Give us Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more http://productguide.itmanagersjournal.com/guidepromo.tmpl _______________________________________________ Net-snmp-coders mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
------------------------------------------------------- This SF.net email is sponsored by: IT Product Guide on ITManagersJournal Use IT products in your business? Tell us what you think of them. Give us Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more http://productguide.itmanagersjournal.com/guidepromo.tmpl _______________________________________________ Net-snmp-coders mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
