From: SourceForge.net <no...@so...> - 2004-03-01 18:33:17
|
Bugs item #829403, was opened at 2003-10-24 01:01 Message generated for change (Settings changed) made by slif You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=112694&aid=829403&group_id=12694 Category: library Group: None >Status: Open >Resolution: None Priority: 1 Submitted By: Moby (mobster_) Assigned to: Michael J. Slifcak (slif) Summary: Perl modules all fail with undefined macro errors Initial Comment: I downloaded net-snmp-5.0.9. I was able to successfully compile and build it on Win32 with MSVC. Once that was done, I built the perl libraries by following the directions in the perl\SNMP\README file. I hit a problem during the make phase, since perl\OID\OID.c referecens a function called snprintf_objid which does not exist anywhere! After I overcame this issue (I just replaces the call to snprintf_objid with a call to snprintf and adjusted the parameters accordingly), the build and the install completed successfully. However, now whenever I try to run any Perl scripts that use any net-snmp functions, they fail with the error: Your vendor has not defined NetSNMP::default_store macro NETSNMP_DS_LIBRARY_ID For the life of me I cannot figure out why I am getting this error. This appears to be a bug in the Perl libraries that are shipped with net-snmp-5.0.9. ---------------------------------------------------------------------- Comment By: Michael J. Slifcak (slif) Date: 2004-02-27 14:44 Message: Logged In: YES user_id=88697 please try V-5-1-patches. The patches described earlier are now incorporated. ---------------------------------------------------------------------- Comment By: Michael J. Slifcak (slif) Date: 2004-02-17 05:49 Message: Logged In: YES user_id=88697 Did you build the libsnmp_dll project ? If not, you will have errors with the default_store (Perl modules need the DLL to share values). Suggest that you consider using a newer version, like net-snmp-5.1.1 (V5-1-patches branch at this writing), apply patch #898464, and use the instructions in README.win32. ---------------------------------------------------------------------- Comment By: Moby (mobster_) Date: 2003-10-24 16:01 Message: Logged In: YES user_id=893777 Looking at perl\ODI\ODI.c at lines 177 through 187, you will see the following: Perl_croak(aTHX_ "oid1 is not of type netsnmp_oidPtr"); #line 98 "OID.xs" { if (oid1->len == 0) snprintf(mystr, sizeof(mystr), "Illegal OID"); else snprintf_objid(mystr, sizeof(mystr), (oid *) oid1->name, oid1->len); RETVAL = mystr; } Anyways, I think the write of this code meant to use the snprint_objid function that you mention below. I will edit the code to use that instead. The other issue relating to the Perl modules complaining about undefined constants I think is not related to this. I have a feeling that that problem is caused because perhaps the net-snmp Perl pieces were designed for Perl 5.6 but I am using Perl 5.8. ---------------------------------------------------------------------- Comment By: Alex Burger (alex_b) Date: 2003-10-24 11:17 Message: Logged In: YES user_id=85836 I haven't tried 5.0.9 on Windows, but I have tried 5.0.8 with the win32 patches. I don't see a snprintf_objid (with an f) in OID.c, but I do see a snprint_objid. snprint_objid is defined in snmplib/mib.c. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=112694&aid=829403&group_id=12694 |