Menu

#381 Undefined symbol when building Perl Modu

closed
library (262)
5
2012-11-08
2002-04-12
Anonymous
No

I am attempting to build the Perl modules for 4.2.4
under Win2000. After playing with the Makefile,
changing paths and such, SNMP.c complies, but upon
attempting to link, I get:

"unresolved symbol _tree_head"

I see tree_head in parse.c. The library, libsnmp.lib,
built Ok using Visual Studio.

Other changes:

1. used GNU regex.h
2. commented-out "#include system.h" in SNMP.xs. The
compiler claimed that both direct and _dir_struc were
multiply defined. SNMP.c will not compile with
system.h.
3. commented-out "#include <unistd.h>"

I see that _tree_head is referred to in libsnmp.lib.
Could this be a compiler issue when the library was
created?

Discussion

  • ronit reger

    ronit reger - 2002-04-29

    Logged In: YES
    user_id=529343

    I'm getting this same problem!! Please respond ASAP if the
    solution is known...
    (Please send response to ronit_r@sanrad.com -- THANKS!!)

     
  • Nobody/Anonymous

    Logged In: NO

    I changed the following line (line 809 of SNMP.xs) :
    extern struct tree *tree_head;
    in
    DLL_IMPORT struct tree *tree_head;
    this fixes the compiler error.
    (The problem is that the tree_head is one of the
    three DATA symbols defined in libnsmp.def (visible data
    symbols in dll). the MIB symbol has the DLL_IMPORT
    declaration so it refers to a symbol in a DLL.

    Willem Dekker

     
  • Wes Hardaker

    Wes Hardaker - 2002-06-23

    Logged In: YES
    user_id=76242

    Thanks for the bug report! We've fixed the problem for the next release of the net-snmp package.

     
  • Wes Hardaker

    Wes Hardaker - 2002-06-23

    Logged In: YES
    user_id=76242

     

Log in to post a comment.