Boost logo

Boost Users :

From: John Maddock (john_at_[hidden])
Date: 2008-04-24 13:09:59


Ali F wrote:
>> Hi.
>>
>> I'm using vs2008 and the way I have my project set up is that there
>> is a common framework which I build into a static library, and this
>> framework uses boost signals which I've built into a static library
>> as well. The thing is that when I compile the test project that uses
>> the framework, it tries to link with the dynamic signals library.

Are you sure?

>> My
>> framework lib also doesnt try and link with the static lib of
>> signals. I went into the auto link.hpp boost file, and saw that if
>> _DLL is defined then it will link with dynamic lib,

No: _DLL is used to determine which build variant is used (which MSVC
runtime library the code is built against), not whether to link to a dll or
static library build of Boost.Signals.

>> else it will use
>> the static lib. I tried removing _DLL from the preprocessor visual
>> studio defines and the same thing happens.

Don't do that, the define is there for a reason.

>> Is there a way to force boost to auto link with the static lib? I
>> know there's a way to force link with dynamic lib but wondering if
>> the opposite is possible.

It should be doing that already: which library is it trying to link too?
Build with BOOST_LIB_DIAGNOSTIC defined if you're not sure and there'll be a
compiler message with the library name.

HTH, John.


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net