Re: [CMake] [Boost-users] link error in Visual Studio when using boost from CMake

2012-05-01 Thread Hui Wang
Yes, target_link_libraries works well, I had problem before because I used find_package(Boost) instead of find_package(Boost COMPONENTS thread), so when I used target_link_libraries( MyProject ${Boost_LIBRARIES} ), it didn't link anything, after I specify the components in find_package, it has no p

Re: [CMake] [Boost-users] link error in Visual Studio when using boost from CMake

2012-05-01 Thread Michael Jackson
On May 1, 2012, at 11:37 AM, Mourad Boufarguine wrote: > > On Tue, May 1, 2012 at 9:10 AM, Rolf Eike Beer wrote: > On Di., 1. Mai. 2012 00:20:58 CEST, Mourad Boufarguine > wrote: > > > Hi, > > > > add this : > > > > link_directories(${Boost_LIBRARY_DIRS}) > > > > after the include_director

Re: [CMake] [Boost-users] link error in Visual Studio when using boost from CMake

2012-05-01 Thread Mourad Boufarguine
On Tue, May 1, 2012 at 9:10 AM, Rolf Eike Beer wrote: > On Di., 1. Mai. 2012 00:20:58 CEST, Mourad Boufarguine < > mou...@boufarguine.name> wrote: > > > Hi, > > > > add this : > > > > link_directories(${Boost_LIBRARY_DIRS}) > > > > after the include_directories command. > > No, please don't. Th

Re: [CMake] [Boost-users] link error in Visual Studio when using boost from CMake

2012-05-01 Thread Rolf Eike Beer
On Di.,  1. Mai. 2012 00:20:58 CEST, Mourad Boufarguine wrote: > Hi, > > add this : > > link_directories(${Boost_LIBRARY_DIRS}) > > after the include_directories command. No, please don't. The target_link_libraries command is what you really want. Please stop advertising link_directories,

Re: [CMake] [Boost-users] link error in Visual Studio when using boost from CMake

2012-04-30 Thread Mourad Boufarguine
Hi, add this : link_directories(${Boost_LIBRARY_DIRS}) after the include_directories command. Cheers, Mourad * * On Mon, Apr 30, 2012 at 10:26 PM, Hui Wang wrote: > Yes, I tried with find_package( Boost COMPONENTS thread ) and > target_link_libraries( ShowEngine ${Boost_LIBRARIES}), and tha

Re: [CMake] [Boost-users] link error in Visual Studio when using boost from CMake

2012-04-30 Thread Hui Wang
Yes, I tried with find_package( Boost COMPONENTS thread ) and target_link_libraries( ShowEngine ${Boost_LIBRARIES}), and that works. Thank you so much! On Mon, Apr 30, 2012 at 3:27 PM, Alain Leblanc wrote: > Don't have much experience with boost in combination with cmake, but don't > you still n