On 2013-10-17 12:58, James Bigler wrote:
It doesn't seem to work.
I can't use target_link_libraries on an imported target.
add_library(imported_lib STATIC IMPORTED GLOBAL)
set_target_properties(imported_lib PROPERTIES IMPOARTED_LOCATION
"${imported_lib_location}")
target_link_libraries(imported
Hi James,
On Thu, Oct 17, 2013 at 6:58 PM, James Bigler wrote:
> It doesn't seem to work.
>
> I can't use target_link_libraries on an imported target.
>
> add_library(imported_lib STATIC IMPORTED GLOBAL)
> set_target_properties(imported_lib PROPERTIES IMPOARTED_LOCATION
> "${imported_lib_locatio
It doesn't seem to work.
I can't use target_link_libraries on an imported target.
add_library(imported_lib STATIC IMPORTED GLOBAL)
set_target_properties(imported_lib PROPERTIES IMPOARTED_LOCATION
"${imported_lib_location}")
target_link_libraries(imported_lib other_lib)
Produces an error:
Attemp
Can you try something like this?
https://github.com/robertmaynard/Sandbox/blob/master/ImportedLibrary/CMakeLists.txt
I don't see the second shared library linking to the imported static library.
On Wed, Oct 16, 2013 at 3:44 PM, James Bigler wrote:
> On Wed, Oct 16, 2013 at 1:34 PM, Giordano Kh
On Wed, Oct 16, 2013 at 1:34 PM, Giordano Khouri wrote:
> The static libraries must be compiled with -fvisibility=hidden. Symbols
> with default visibility are marked as “public” and will leak from a shared
> library. With hidden visibility, they symbols are marked as “private
> extern”, allowing
Nikon-1-AW1.html?cid=eml-0913-n1aw1-signature>
From: cmake-boun...@cmake.org [mailto:cmake-boun...@cmake.org] On Behalf Of
James Bigler
Sent: Wednesday, October 16, 2013 2:06 PM
To: cmake@cmake.org
Subject: [CMake] Transitive linking and static libraries
Is it possible to stop known static libr
This seems to do what I want.
Is there a version of this that works for IMPORTED targets.
There's *IMPORTED_LINK_INTERFACE_LIBRARIES*, but I'm not sure how to make
them private for static libraries.
Thanks,
James
On Wed, Oct 16, 2013 at 12:17 PM, Robert Maynard wrote:
> Have you tried using
Have you tried using the LINK_PRIVATE signature to target link libraries?
On Wed, Oct 16, 2013 at 2:05 PM, James Bigler wrote:
> Is it possible to stop known static libraries from being carried through
> shared libraries?
>
> add_library(mystatic1 STATIC ...)
> add_library(mystatic2 STATIC ...)
>
On 2013-10-16 14:05, James Bigler wrote:
Is it possible to stop known static libraries from being carried through
shared libraries?
Did you try using 'LINK_PRIVATE' in your target_link_libraries?
--
Matthew
--
Powered by www.kitware.com
Please keep messages on-topic and check the CMake FAQ
Is it possible to stop known static libraries from being carried through
shared libraries?
add_library(mystatic1 STATIC ...)
add_library(mystatic2 STATIC ...)
add_library(myshared SHARED ...)
target_link_libraries(myshared mystatic1 mystatic2)
add_executable(myexe)
target_link_libraries(myexe mysh
On 03/07/2012 11:29 AM, Alexander Dahl wrote:
> Hello Michael,
>
> Am 2012-03-06 16:46, schrieb Michael Hertling:
>> or possibly better:
>>
>> # libbar/bar-config.cmake.in:
>> FIND_PACKAGE(FOO PATHS @FOO_DIR@ NO_DEFAULT_PATH)
>
> I used
>
> FIND_PACKAGE(FOO 0.1.0 REQUIRED)
>
> in the package c
Hello Michael,
Am 2012-03-06 16:46, schrieb Michael Hertling:
> or possibly better:
>
> # libbar/bar-config.cmake.in:
> FIND_PACKAGE(FOO PATHS @FOO_DIR@ NO_DEFAULT_PATH)
I used
FIND_PACKAGE(FOO 0.1.0 REQUIRED)
in the package config file now, which works, too.
> BTW, find modules / config fil
On 03/06/2012 02:47 PM, Alexander Dahl wrote:
> Hei hei,
>
> we faced a build problem with transitive linking of separate projects
> where I can't find the right solution on my own. I hope someone can give
> me a hint. I prepared a test case with two libraries libfoo and libbar
> and an applicati
Hei hei,
we faced a build problem with transitive linking of separate projects
where I can't find the right solution on my own. I hope someone can give
me a hint. I prepared a test case with two libraries libfoo and libbar
and an application baz. libfoo is on his own, libbar calls a function
from
Am 24.11.2011 09:47, schrieb Rolf Eike Beer:
Oops. You are right. I had never ever heard of applications
exporting symbols before. Live and learn.
You use one every day:
$ /lib/libc.so.6
GNU C Library stable release version 2.11.3 (20110203), by Roland
McGrath
et al.
Copyright (C) 2009 Fr
> On 2011-11-23 10:44+0100 Michael Wild wrote:
>
>> On 11/23/2011 10:25 AM, Alan W. Irwin wrote:
>>> cmake-2.8.6 has the following documentation of the
>>> LINK_INTERFACE_LIBRARIES property for targets:
>>>
>>> LINK_INTERFACE_LIBRARIES
>>>List public interface libraries for a shared libra
lf. I was just commenting on the
CMake transitive linking implications of what Orion told me about
rpmlint warnings he had encountered (which I confirmed with "ldd -u").
Since I wrote "all this to quiet rpmlint warnings", it turns out the
PLplot Debian packager (again not me) confir
On 2011-11-23 10:44+0100 Michael Wild wrote:
On 11/23/2011 10:25 AM, Alan W. Irwin wrote:
cmake-2.8.6 has the following documentation of the
LINK_INTERFACE_LIBRARIES property for targets:
LINK_INTERFACE_LIBRARIES
List public interface libraries for a shared library or executable.
On 11/19/2011 08:02 AM, James Bigler wrote:
> On Fri, Nov 18, 2011 at 5:51 PM, Michael Hertling wrote:
>
>> On 11/18/2011 10:03 PM, James Bigler wrote:
>>> 2011/11/18 Alexander Neundorf
>>>
On Friday 18 November 2011, James Bigler wrote:
> I thought CMake knew how to not drag all the dep
On Nov 19, 2011, at 2:02 AM, James Bigler wrote:
> On Fri, Nov 18, 2011 at 5:51 PM, Michael Hertling wrote:
> On 11/18/2011 10:03 PM, James Bigler wrote:
> > 2011/11/18 Alexander Neundorf
> >
> >> On Friday 18 November 2011, James Bigler wrote:
> >>> I thought CMake knew how to not drag all t
On 19.11.11 00:02:22, James Bigler wrote:
> On Fri, Nov 18, 2011 at 5:51 PM, Michael Hertling wrote:
>
> > On 11/18/2011 10:03 PM, James Bigler wrote:
> > > 2011/11/18 Alexander Neundorf
> > >
> > >> On Friday 18 November 2011, James Bigler wrote:
> > >>> I thought CMake knew how to not drag all
On Saturday 19 November 2011, Michael Hertling wrote:
> On 11/18/2011 10:03 PM, James Bigler wrote:
> > 2011/11/18 Alexander Neundorf
> >
> >> On Friday 18 November 2011, James Bigler wrote:
> >>> I thought CMake knew how to not drag all the dependent libraries once
> >>> you linked an executable
On Fri, Nov 18, 2011 at 5:51 PM, Michael Hertling wrote:
> On 11/18/2011 10:03 PM, James Bigler wrote:
> > 2011/11/18 Alexander Neundorf
> >
> >> On Friday 18 November 2011, James Bigler wrote:
> >>> I thought CMake knew how to not drag all the dependent libraries once
> you
> >>> linked an execu
On 11/18/2011 10:03 PM, James Bigler wrote:
> 2011/11/18 Alexander Neundorf
>
>> On Friday 18 November 2011, James Bigler wrote:
>>> I thought CMake knew how to not drag all the dependent libraries once you
>>> linked an executable module.
>>>
>>> add_library(A STATIC a.cpp)
>>> add_library(B SHA
2011/11/18 Alexander Neundorf
> On Friday 18 November 2011, James Bigler wrote:
> > I thought CMake knew how to not drag all the dependent libraries once you
> > linked an executable module.
> >
> > add_library(A STATIC a.cpp)
> > add_library(B SHARED b.cpp)
> > target_link_libraries(B A)
> > add
On Friday 18 November 2011, James Bigler wrote:
> I thought CMake knew how to not drag all the dependent libraries once you
> linked an executable module.
>
> add_library(A STATIC a.cpp)
> add_library(B SHARED b.cpp)
> target_link_libraries(B A)
> add_library(C SHARED c.cpp)
> target_link_librarie
I thought CMake knew how to not drag all the dependent libraries once you
linked an executable module.
add_library(A STATIC a.cpp)
add_library(B SHARED b.cpp)
target_link_libraries(B A)
add_library(C SHARED c.cpp)
target_link_libraries(C B)
add_executable(run run.cpp)
target_link_libraries(run C)
On Mar 31, 2009, at 21:10, Hendrik Sattler wrote:
Am Dienstag 31 März 2009 19:48:49 schrieb Tobias Rudolph:
add_library( iLib SHARED IMPORTED )
set_target_properties( iLib PROPERTIES IMPORTED_LOCATION "/opt/local/
lib/libzip.dylib" )
add_library( libFoo SHARED foo.cpp )
target_link_libra
Am Dienstag 31 März 2009 19:48:49 schrieb Tobias Rudolph:
>
> add_library( iLib SHARED IMPORTED )
> set_target_properties( iLib PROPERTIES IMPORTED_LOCATION "/opt/local/
> lib/libzip.dylib" )
>
> add_library( libFoo SHARED foo.cpp )
> target_link_libraries( libFoo iLib )
>
>
> According t
Hi All,
I am trying to build a project containing several subprojects that are
included via add_subdirectory. Now, here is an example demonstrating
the problem:
The test project contains the following CMakeLists.txt:
project( CMakeTest )
cmake_minimum_required( VERSION 2.6 )
add_subdi
30 matches
Mail list logo