Hi, I'm a newbie using libsmi and I have a little problem.
I try to use the libsmi library in a c++ program (using MSVC++ 6.0)
but I obtain the following link error:
SMISurfer.obj : error LNK2001: unresolved external symbol "struct SmiModule
* __cdecl smiGetModule(char const *)" (?smiGetModule@@YAPAUSmiModule@@PBD@Z)
SMISurfer.obj : error LNK2001: unresolved external symbol "int __cdecl
smiInit(char const *)" (?smiInit@@YAHPBD@Z)
Debug/SnmpExtensionAgent.dll : fatal error LNK1120: 2 unresolved externals
Error executing link.exe.
I can use the library in a little C program (win32 console aplication)
without problems, but when I try to use the library in C++ (win32 dll
project), MSVC++ is unable to link the library.
This is an example of my code:
// Simple method for open .mib file
BOOL SMISurfer::openMib(char *filename)
{
SmiModule *module;
smiInit(NULL);
if ((module = smiGetModule(filename)) == NULL)
return FALSE;
else
return TRUE;
}
I include the smi.lib in the project settings.
Thanks.
_________________________________________________________________
Hable con sus amigos en línea, pruebe MSN Messenger: http://messenger.msn.es