On Tue, Sep 28, 2010 at 9:44 AM, Michael Jäger <michael.jae...@hs-owl.de>wrote:

> I compiled and "made" the net-snmp libraries from version 5.6-rc3.
>
> When I set up a new project in eclipse and compile my application the
> following error occurs. I made no specific adjustments regarding including
> libraries or something like that in eclipse.
> The #include statements are not marked as an error.
>
> **** Internal Builder is used for build               ****
> gcc -oSNMPWin.exe MIBExtraction.o
> MIBExtraction.o: In function `main':
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:31: undefined
> reference to `init_snmp'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:34: undefined
> reference to `snmp_sess_init'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:39: undefined
> reference to `snmp_open'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:43: undefined
> reference to `snmp_perror'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:44: undefined
> reference to `snmp_log'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:96: undefined
> reference to `snmp_close'
> MIBExtraction.o: In function `macAddrReq':
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:137: undefined
> reference to `snmp_pdu_create'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:138: undefined
> reference to `read_objid'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:139: undefined
> reference to `snmp_add_null_var'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:141: undefined
> reference to `snmp_synch_response'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:145: undefined
> reference to `print_value'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:157: undefined
> reference to `snmp_free_pdu'
> MIBExtraction.o: In function `getBulkTest':
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:169: undefined
> reference to `snmp_pdu_create'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:170: undefined
> reference to `read_objid'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:171: undefined
> reference to `snmp_add_null_var'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:172: undefined
> reference to `snmp_synch_response'
> C:\Eclipse_CDT_Workspace\SNMPWin\Debug/../MIBExtraction.c:176: undefined
> reference to `snmp_free_pdu'
> collect2: ld returned 1 exit status
> Build error occurred, build is stopped
> Time consumed: 290  ms.
>
>
> It seems to be the same error as before? I don't know. When I press right
> click -> open declaration on function of the net-snmp library I am
> redirected to the respective header file, thus I am wondering why
> such an error occurs .
>

It's not really the same. All the functions listed above are defined in the
Net-SNMP library. If you want to use functions from that library, you have
to tell your compilation environment that it has to link against that
library.

Bart.
------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
Net-snmp-coders mailing list
Net-snmp-coders@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to