[CMake] adding dependencies to a target

2014-06-27 Thread abid rahman
Hello, I am adding a new target using "add_library(target source1 source2)". Then add the dependencies of targets by "target_link_libraries(target deps)" But this source2 is generated by another python script based on dependencies of target. ie, I need to specify the dependencies of target before

[CMake] fixup_bundle and bundle install names

2014-06-27 Thread Mikael Sundell
fixup_bundle can't resolve dynamic libraries with non-absolute install_names. I'm linking my macosx cmake project against an sdk inside an application bundle, the sdk libraries are relative to the application bundle configuration. It seems as if the fixup_bundle uses the install name even if it's n

Re: [CMake] Add libraries to end of compilation line ...

2014-06-27 Thread Hendrik Sattler
Hi, IIRC the old function is preserved as the same name with an underscore as prefix... Regards, HS On 27. Juni 2014 10:23:07 MESZ, Kornel Benko wrote: >Am Donnerstag, 26. Juni 2014 um 20:12:12, schrieb Hendrik Sattler > >> Hi, >> >> you can also override the target_link_libraries function w

Re: [CMake] Preventing search for libraries in random prefixes

2014-06-27 Thread Ben Morgan
Hi Mojca, On 27 June 2014 10:26, Mojca Miklavec wrote: > On Fri, Jun 27, 2014 at 10:42 AM, Angeliki Chrysochou wrote: > > Hi Mojca, > > > > From what I know cmake will look for libraries in the directories > specified > > in link_directories(${LIBRARY_DIRS}) and for headers in the directories >

Re: [CMake] Preventing search for libraries in random prefixes

2014-06-27 Thread Mojca Miklavec
On Fri, Jun 27, 2014 at 11:28 AM, Angeliki Chrysochou wrote: > Hi Mojca, > > I don't know if removing these paths would break your build maybe...I'm > sorry I couldn't help. It wouldn't break my build, but it seems weird and unnatural to do such extensive patching to CMake's Find modules. Mojca -

Re: [CMake] Preventing search for libraries in random prefixes

2014-06-27 Thread Angeliki Chrysochou
Hi Mojca, I don't know if removing these paths would break your build maybe...I'm sorry I couldn't help. Angeliki On Fri, Jun 27, 2014 at 11:26 AM, Mojca Miklavec wrote: > On Fri, Jun 27, 2014 at 10:42 AM, Angeliki Chrysochou wrote: > > Hi Mojca, > > > > From what I know cmake will look for

Re: [CMake] Preventing search for libraries in random prefixes

2014-06-27 Thread Mojca Miklavec
On Fri, Jun 27, 2014 at 10:42 AM, Angeliki Chrysochou wrote: > Hi Mojca, > > From what I know cmake will look for libraries in the directories specified > in link_directories(${LIBRARY_DIRS}) and for headers in the directories > specified in include_directories(${INCLUDE_DIRS}) and the property > I

Re: [CMake] Preventing search for libraries in random prefixes

2014-06-27 Thread Angeliki Chrysochou
Hi Mojca, >From what I know cmake will look for libraries in the directories specified in link_directories(${LIBRARY_DIRS}) and for headers in the directories specified in include_directories(${INCLUDE_DIRS}) and the property INCLUDE_DIRECTORIES. http://www.cmake.org/cmake/help/v2.8.8/cmake.html#

Re: [CMake] Add libraries to end of compilation line ...

2014-06-27 Thread Kornel Benko
Am Donnerstag, 26. Juni 2014 um 20:12:12, schrieb Hendrik Sattler > Hi, > > you can also override the target_link_libraries function with your own in the > top-level lists file and call the original one from within that function. > This way you only have to edit one file. Nice idea, but how

Re: [CMake] Add libraries to end of compilation line ...

2014-06-27 Thread Michael Burns via CMake
Hello. That is a good idea, Hendrik. I'll look into that. Angeliki, we set the CMAKE_CXX_FLAGS... and CMAKE_C_FLAGS... values with various options. I simply added the -static and -static-libstdc++ to those. Again, I'm trying to do this without having to modi