Re: [CMake] target_link_libraries: prefer static to dynamic

2010-01-03 Thread Philip Lowman
On Sun, Jan 3, 2010 at 2:26 PM, Alexander Neundorf wrote: > Isn't there some "binutil" which can tell what kind of library some .lib is ? > Or maybe every dll (and that way the accompanying lib) has some functions > which only dlls have ? > Or maybe they references some special functions which may

Re: [CMake] target_link_libraries: prefer static to dynamic

2010-01-03 Thread Alexander Neundorf
On Monday 28 December 2009, Bill Hoffman wrote: > Pau Garcia i Quiles wrote: > > I'm using CMake 2.8.0 on Linux. Yes, Michael is right: I want it to > > happen automagically. That was the whole point of this thread :-) > > OK, well the thread has a very bad subject then > > It should be "force

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-30 Thread Michael Wild
On 30. Dec, 2009, at 18:02 , Jed Brown wrote: > On Wed, 30 Dec 2009 17:51:29 +0100, Michael Wild wrote: >> >> On 30. Dec, 2009, at 17:32 , Jed Brown wrote: >> >>> On Mon, 28 Dec 2009 12:29:05 +0100, Pau Garcia i Quiles >>> wrote: I'm using CMake 2.8.0 on Linux. Yes, Michael is right: I

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-30 Thread Jed Brown
On Wed, 30 Dec 2009 17:51:29 +0100, Michael Wild wrote: > > On 30. Dec, 2009, at 17:32 , Jed Brown wrote: > > > On Mon, 28 Dec 2009 12:29:05 +0100, Pau Garcia i Quiles > > wrote: > >> I'm using CMake 2.8.0 on Linux. Yes, Michael is right: I want it to > >> happen automagically. That was the wh

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-30 Thread Michael Wild
On 30. Dec, 2009, at 17:32 , Jed Brown wrote: > On Mon, 28 Dec 2009 12:29:05 +0100, Pau Garcia i Quiles > wrote: >> I'm using CMake 2.8.0 on Linux. Yes, Michael is right: I want it to >> happen automagically. That was the whole point of this thread :-) > > I would argue that FindXXX.cmake is t

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-30 Thread Jed Brown
On Mon, 28 Dec 2009 12:29:05 +0100, Pau Garcia i Quiles wrote: > I'm using CMake 2.8.0 on Linux. Yes, Michael is right: I want it to > happen automagically. That was the whole point of this thread :-) I would argue that FindXXX.cmake is the wrong place for the decision to be made since I may wan

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-28 Thread Bill Hoffman
Pau Garcia i Quiles wrote: I'm using CMake 2.8.0 on Linux. Yes, Michael is right: I want it to happen automagically. That was the whole point of this thread :-) OK, well the thread has a very bad subject then It should be "force find_library to choose static over shared". This really ha

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-28 Thread Michael Wild
On 28. Dec, 2009, at 12:40 , Pau Garcia i Quiles wrote: >> That sounds doable to me. However, you'd need a mechanism to express the >> same preference when calling find_package and then have find_package >> communicate that to find_library. Not sure how fine-grained >> the control should be for

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-28 Thread Pau Garcia i Quiles
> That sounds doable to me. However, you'd need a mechanism to express the same > preference when calling find_package and then have find_package communicate > that to find_library. Not sure how fine-grained > the control should be for FindXXX.cmake modules that find more than one > library (or

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-28 Thread Pau Garcia i Quiles
>> What version of CMake are you using?  This should work...  As of 2.6.2 (I >> think...) CMake uses full paths to libraries, see policy CMP0003: >> http://www.cmake.org/cmake/help/cmake-2-8-docs.html#policy:CMP0003.  It does >> not matter if there are two libraries in the same directory.  There

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-28 Thread Michael Wild
On 27. Dec, 2009, at 23:30 , Pau Garcia i Quiles wrote: > On Sun, Dec 27, 2009 at 10:16 PM, Michael Wild wrote: >> >> On 27. Dec, 2009, at 20:41 , Pau Garcia i Quiles wrote: >> >>> On Sun, Dec 27, 2009 at 10:59 AM, Michael Wild wrote: On 26. Dec, 2009, at 17:53 , Pau Garcia i Quile

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-28 Thread Michael Wild
On 28. Dec, 2009, at 5:38 , Bill Hoffman wrote: > Pau Garcia i Quiles wrote: >> On Sun, Dec 27, 2009 at 6:26 PM, Bill Hoffman >> wrote: >>> Pau Garcia i Quiles wrote: Hello, I think this has already been discussed and the answer is negative but still: when I do target_link_

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-27 Thread Bill Hoffman
Pau Garcia i Quiles wrote: On Sun, Dec 27, 2009 at 6:26 PM, Bill Hoffman wrote: Pau Garcia i Quiles wrote: Hello, I think this has already been discussed and the answer is negative but still: when I do target_link_libraries to an external library (for instance, my application needs to link to

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-27 Thread Pau Garcia i Quiles
On Sun, Dec 27, 2009 at 10:16 PM, Michael Wild wrote: > > On 27. Dec, 2009, at 20:41 , Pau Garcia i Quiles wrote: > >> On Sun, Dec 27, 2009 at 10:59 AM, Michael Wild wrote: >>> >>> On 26. Dec, 2009, at 17:53 , Pau Garcia i Quiles wrote: >>> Hello, I think this has already been disc

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-27 Thread Michael Wild
On 27. Dec, 2009, at 20:41 , Pau Garcia i Quiles wrote: > On Sun, Dec 27, 2009 at 10:59 AM, Michael Wild wrote: >> >> On 26. Dec, 2009, at 17:53 , Pau Garcia i Quiles wrote: >> >>> Hello, >>> >>> I think this has already been discussed and the answer is negative but >>> still: when I do targe

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-27 Thread Pau Garcia i Quiles
On Sun, Dec 27, 2009 at 6:26 PM, Bill Hoffman wrote: > Pau Garcia i Quiles wrote: >> >> Hello, >> >> I think this has already been discussed and the answer is negative but >> still: when I do target_link_libraries to an external library (for >> instance, my application needs to link to sqlite), is

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-27 Thread Pau Garcia i Quiles
On Sun, Dec 27, 2009 at 10:59 AM, Michael Wild wrote: > > On 26. Dec, 2009, at 17:53 , Pau Garcia i Quiles wrote: > >> Hello, >> >> I think this has already been discussed and the answer is negative but >> still: when I do target_link_libraries to an external library (for >> instance, my applicati

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-27 Thread Bill Hoffman
Pau Garcia i Quiles wrote: Hello, I think this has already been discussed and the answer is negative but still: when I do target_link_libraries to an external library (for instance, my application needs to link to sqlite), is it possible to tell CMake to link to the static version of sqlite inst

Re: [CMake] target_link_libraries: prefer static to dynamic

2009-12-27 Thread Michael Wild
On 26. Dec, 2009, at 17:53 , Pau Garcia i Quiles wrote: > Hello, > > I think this has already been discussed and the answer is negative but > still: when I do target_link_libraries to an external library (for > instance, my application needs to link to sqlite), is it possible to > tell CMake to

[CMake] target_link_libraries: prefer static to dynamic

2009-12-26 Thread Pau Garcia i Quiles
Hello, I think this has already been discussed and the answer is negative but still: when I do target_link_libraries to an external library (for instance, my application needs to link to sqlite), is it possible to tell CMake to link to the static version of sqlite instead of the dynamic version?