You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by opernas <op...@indra.es> on 2010/04/13 18:40:35 UTC

ActiveMQ-CPP why .lib is needed?

In windows with VS 2005 I've compiled all apr utils and activemq and all went
fine. Now Im running my code and while it is linking I see:

Error	1	error LNK2019: unresolved external symbol "public: static void
__cdecl activemq::library::ActiveMQCPP::initializeLibrary(void)"
(?initializeLibrary@ActiveMQCPP@library@activemq@@SAXXZ) referenced in
function "public: __thiscall AMQConsumer::AMQConsumer(class
std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > const &,class std::basic_string<char,struct
std::char_traits<char>,class std::allocator<char> > const &,class
std::basic_string<char,struct std::char_traits<char>,class
std::allocator<char> > const &,class std::basic_string<char,struct
std::char_traits<char>,class std::allocator<char> > const &,bool,bool)"
(??0AMQConsumer@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@000_N1@Z)
AMQConsumer.obj	

Error	2	error LNK2019: unresolved external symbol "public: static void
__cdecl activemq::library::ActiveMQCPP::shutdownLibrary(void)"
(?shutdownLibrary@ActiveMQCPP@library@activemq@@SAXXZ) referenced in
function "public: void __thiscall AMQConsumer::close(void)"
(?close@AMQConsumer@@QAEXXZ)	AMQConsumer.obj	


... and more....

Do I need to put libactivemq-cpp.lib into the project? I wouldn't want to
use statics library, are there any problem with my compilation? If I put in
additional dependencies this libs:ws2_32.lib libapr-1.lib libaprutil-1.lib
libactivemq-cpp.lib, all goes fine, any idea?





-- 
View this message in context: http://old.nabble.com/ActiveMQ-CPP-why-.lib-is-needed--tp28232816p28232816.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Re: ActiveMQ-CPP why .lib is needed?

Posted by Timothy Bish <ta...@gmail.com>.
I don't have access to my Visual Studio project files right now but I think
that you should be linking against the lib file from the DLL build which is
activemq-cpp.lib.  Then when your application runs you will need to have the
activemq-cpp.dll on the PATH.

Regards
Tim.

On Tue, Apr 13, 2010 at 12:40 PM, opernas <op...@indra.es> wrote:

>
> In windows with VS 2005 I've compiled all apr utils and activemq and all
> went
> fine. Now Im running my code and while it is linking I see:
>
> Error   1       error LNK2019: unresolved external symbol "public: static
> void
> __cdecl activemq::library::ActiveMQCPP::initializeLibrary(void)"
> (?initializeLibrary@ActiveMQCPP@library@activemq@@SAXXZ) referenced in
> function "public: __thiscall AMQConsumer::AMQConsumer(class
> std::basic_string<char,struct std::char_traits<char>,class
> std::allocator<char> > const &,class std::basic_string<char,struct
> std::char_traits<char>,class std::allocator<char> > const &,class
> std::basic_string<char,struct std::char_traits<char>,class
> std::allocator<char> > const &,class std::basic_string<char,struct
> std::char_traits<char>,class std::allocator<char> > const &,bool,bool)"
> (??0AMQConsumer@@QAE@ABV?$basic_string@DU?$char_traits@D@std@
> @V?$allocator@D@2@@std@@000_N1@Z)
> AMQConsumer.obj
>
> Error   2       error LNK2019: unresolved external symbol "public: static
> void
> __cdecl activemq::library::ActiveMQCPP::shutdownLibrary(void)"
> (?shutdownLibrary@ActiveMQCPP@library@activemq@@SAXXZ) referenced in
> function "public: void __thiscall AMQConsumer::close(void)"
> (?close@AMQConsumer@@QAEXXZ)    AMQConsumer.obj
>
>
> ... and more....
>
> Do I need to put libactivemq-cpp.lib into the project? I wouldn't want to
> use statics library, are there any problem with my compilation? If I put in
> additional dependencies this libs:ws2_32.lib libapr-1.lib libaprutil-1.lib
> libactivemq-cpp.lib, all goes fine, any idea?
>
>
>
>
>
> --
> View this message in context:
> http://old.nabble.com/ActiveMQ-CPP-why-.lib-is-needed--tp28232816p28232816.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>
>