Re: [CMake] PROPERTY for list of link libraries

2016-01-25 Thread Tom Kacvinsky
Thanks. Upgrading cmake right now is problematic. On Mon, Jan 25, 2016 at 4:33 AM, Tamás Kenéz wrote: > I think you need something like CMakeExpandImportedTargets.cmake ( > https://cmake.org/cmake/help/latest/module/CMakeExpandImportedTargets.html). > But that module has been deprecated for a w

Re: [CMake] PROPERTY for list of link libraries

2016-01-25 Thread Tamás Kenéz
I think you need something like CMakeExpandImportedTargets.cmake ( https://cmake.org/cmake/help/latest/module/CMakeExpandImportedTargets.html). But that module has been deprecated for a while and does not support some newer CMake features. Instead, feel free to try out my fork: https://gist.github

Re: [CMake] PROPERTY for list of link libraries

2016-01-22 Thread Tom Kacvinsky
Ah yes, that was it. Switching to 3.3.2 did the trick. Time to upgrade cmake. On Fri, Jan 22, 2016 at 4:40 PM, Tom Kacvinsky wrote: > I am now having a problem with transitive dependencies. I need all > libraries that are linked in. I am missing the ones that are linked in > transitively. M

Re: [CMake] PROPERTY for list of link libraries

2016-01-22 Thread Tom Kacvinsky
I am now having a problem with transitive dependencies. I need all libraries that are linked in. I am missing the ones that are linked in transitively. Modified code is, ignoring J. Decker's suggestion about using generator expressions to get the path to the target's output. get_property(libs T

Re: [CMake] PROPERTY for list of link libraries

2016-01-22 Thread Hendrik Sattler
Am 22. Januar 2016 15:23:53 MEZ, schrieb Tom Kacvinsky : >I have need for a cross platform methods of getting libraries linked >into an executable. > >Say for instance, we have > >add_library(foo STATIC a.c) >add_exceutable(bar b.c) >target_link_libraries(bar foo) > >So I know for that bar has a

Re: [CMake] PROPERTY for list of link libraries

2016-01-22 Thread J Decker
LOCATION was/is deprecated... the preferred method is generator expressions https://cmake.org/cmake/help/v3.3/manual/cmake-generator-expressions.7.html $ $ On Fri, Jan 22, 2016 at 7:19 AM, Tom Kacvinsky wrote: > On Fri, Jan 22, 2016 at 9:23 AM, Tom Kacvinsky > wrote: >> I have need for a cross p

Re: [CMake] PROPERTY for list of link libraries

2016-01-22 Thread Tom Kacvinsky
On Fri, Jan 22, 2016 at 9:23 AM, Tom Kacvinsky wrote: > I have need for a cross platform methods of getting libraries linked > into an executable. > > Say for instance, we have > > add_library(foo STATIC a.c) > add_exceutable(bar b.c) > target_link_libraries(bar foo) > > So I know for that bar has

[CMake] PROPERTY for list of link libraries

2016-01-22 Thread Tom Kacvinsky
I have need for a cross platform methods of getting libraries linked into an executable. Say for instance, we have add_library(foo STATIC a.c) add_exceutable(bar b.c) target_link_libraries(bar foo) So I know for that bar has a dependency on foo.lib (on Windows) and libfoo.a on Linux. And so for