Marcel Tricolici
Marcel Tricolici

Reputation: 440

c++ windows, compile with mingw as static library and include in visual studio c++ project

c++, windows (in my case windows phone 8, arm & x86 for emulator). I've compiled boost libraries with mingw. as a result I have such files for ex "libboost_random-mgw48-mt-sd-1_53.a".

Is there any possibility to include this static library in visual studio c++ project? Maybe compile with special options... or convert this ".a" file to a visual studio compatible ".lib" file.

I've tried to rename .. but I receive some 'undefined reference' errors.. so they're not directly compatible.

please note that this library (boost) cannot be compiled with visual studio. I've an open question that still has no answer: https://stackoverflow.com/questions/23831050/compile-boost-as-static-library-for-windows-phone-8-arm

Upvotes: 0

Views: 771

Answers (1)

Cheers and hth. - Alf
Cheers and hth. - Alf

Reputation: 145289

You can't use the g++ object files with visual c++. However, you can use all the header only modules of boost without building anything. For the rest, such as Boost filesystem, build it with visual c++ for use with visual c++.


Re

“please note that this library (boost) cannot be compiled with visual studio”

that's incorrect.

Upvotes: 2

Related Questions