Le 31/08/2018 à 16:31, Eric Noulard a écrit :
Le ven. 31 août 2018 à 15:59, Stéphane Ancelot
mailto:sance...@numalliance.com>> a écrit :
I ended with :
add_custom_target(combined ALL
COMMAND ${CMAKE_AR} rc libcombined.a $
$)
Quick & dirty :-)
There is the "thin"
Le ven. 31 août 2018 à 15:59, Stéphane Ancelot a
écrit :
> I ended with :
>
> add_custom_target(combined ALL
>COMMAND ${CMAKE_AR} rc libcombined.a $ $ FILE:lib2>)
>
Quick & dirty :-)
There is the "thin" option of ar as well:
I ended with :
add_custom_target(combined ALL
COMMAND ${CMAKE_AR} rc libcombined.a $
$)
Le 31/08/2018 à 15:24, Eric Noulard a écrit :
First create OBJECT libraries instead of static
Then create as many STATIC libraries as you want that includes as many
OBJECT libraries content as you
First create OBJECT libraries instead of static
Then create as many STATIC libraries as you want that includes as many
OBJECT libraries content as you want.
Le ven. 31 août 2018 à 15:17, Stéphane Ancelot a
écrit :
> Hi,
>
> I have got some static libraries generated, that I would like to put
Hi,
I have got some static libraries generated, that I would like to put in
a common one.
how can I proceed ?
Regards,
S.Ancelot
--
Powered by www.kitware.com
Please keep messages on-topic and check the CMake FAQ at:
http://www.cmake.org/Wiki/CMake_FAQ
Kitware offers various services
Thanks to all who have replied for your efforts in trying to help me. My
apologies for any lack of clarity in describing my problem.
With the various information and advice you provided, I have been able to
get my CMake configuration working.
Thanks again!
..chris
On Wed, Nov 26, 2014 at
, 2014 01:36
To: cmake@cmake.org
Subject: [CMake] Creating a library from subdirectories
This CMake wiki page (http://www.cmake.org/Wiki/CMake/Tutorials/Object_Library)
claims one can create a library from subdirectories containing libraries, which
is exactly what I want to do. However, it doesn't
-Roemer, Johannes Sebastian
Sent: Wednesday, November 26, 2014 13:50
To: 'Chris Johnson'; cmake@cmake.org
Subject: RE: [CMake] Creating a library from subdirectories
In the example on that site an OBJECT library is created (the output consists
of multiple .obj files), you used STATIC libraries instead
, Johannes Sebastian
*Sent:* Wednesday, November 26, 2014 13:50
*To:* 'Chris Johnson'; cmake@cmake.org
*Subject:* RE: [CMake] Creating a library from subdirectories
In the example on that site an OBJECT library is created (the output
consists of multiple .obj files), you used STATIC libraries
that CMake knows that those have to be linked
as well.
From: Chris Johnson [cxjohn...@gmail.com]
Sent: Wednesday, November 26, 2014 8:45 PM
To: Mueller-Roemer, Johannes Sebastian
Cc: cmake@cmake.org
Subject: Re: [CMake] Creating a library from subdirectories
I
, November 26, 2014 8:45 PM
To: Mueller-Roemer, Johannes Sebastian
Cc: cmake@cmake.org
Subject: Re: [CMake] Creating a library from subdirectories
I know that one cannot link static libraries together; they're just
archives of objects, really. But since CMake abstracts the actual
construction
Chris Johnson wrote:
* I do not want to use the add_library(component1 OBJECT
${component1_sources}) and add_library(toplevel
$TARGET_OBJECTS:component1 ... ) syntax if it can be avoided.
Is the constraint that you want a top-level something like
# All components:
set(components
This CMake wiki page (
http://www.cmake.org/Wiki/CMake/Tutorials/Object_Library) claims one can
create a library from subdirectories containing libraries, which is exactly
what I want to do. However, it doesn't seem to work. Here's my SSCCE (
http://sscce.org) toy example file structure:
.
|--
thanks Eric!
Cristobal
On Tue, Sep 13, 2011 at 7:12 PM, Eric Noulard eric.noul...@gmail.comwrote:
2011/9/13 Cristobal Navarro axisch...@gmail.com:
hello everyone!
this is my first post on the mailing list
i am making a shared library
i have everything configured properly so that cmake
hello everyone!
this is my first post on the mailing list
i am making a shared library
i have everything configured properly so that cmake creates de makefile
scripts as espected
at the moment cmake is installing my library by default into:
/usr/local/lib/mylib.so.0.1 (and the symlink mylib.so)
2011/9/13 Cristobal Navarro axisch...@gmail.com:
hello everyone!
this is my first post on the mailing list
i am making a shared library
i have everything configured properly so that cmake creates de makefile
scripts as espected
at the moment cmake is installing my library by default into:
If I have many executables in the same project (ie same CMakeLists.txt
file), it seems like I shouldn't have to do this:
set(Sources File1.cpp File1.cpp )
ADD_EXECUTABLE(Test1 Test1.cpp ${Sources})
ADD_EXECUTABLE(Test2 Test2.cpp ${Sources})
because it is compiling File1 and File2 twice when
Off the top of my head I think
TARGET_LINK_LIBRARIES(Test1 ${MyLibs})
should be
TARGET_LINK_LIBRARIES(Test1 MyLibs)
Also, I think you need to specify a static library if you want one. It seems
like a static library is what you want in this case.
I wrote this up really quick, and could be wrong
David Doria wrote:
If I have many executables in the same project (ie same CMakeLists.txt
file), it seems like I shouldn't have to do this:
set(Sources File1.cpp File1.cpp )
ADD_EXECUTABLE(Test1 Test1.cpp ${Sources})
ADD_EXECUTABLE(Test2 Test2.cpp ${Sources})
because it is compiling File1
Ah of course! I am just used to doing
ADD_EXECUTABLE(Test1 Test1.cpp ${Sources})
So I guess I wasn't thinking and assumed it would be the same for
libraries, but now MyLibs is an actual thing, not a list of files
like ${Sources} is.
Thanks guys.
David
On Wed, Feb 18, 2009 at 12:46 PM, Bill
2007/6/14, David Cole [EMAIL PROTECTED]:
It's advanced CMake use, but you might want to have a look at overriding
the CMake rule variable CMAKE_CXX_CREATE_STATIC_LIBRARY.
(Or _C_ if it's C source code.) You should be able to add some linker flags
in there, although they may apply to all static
2007/6/15, kitts [EMAIL PROTECTED]:
On Thursday 14 Jun 2007 12:23:07 pm Jesper Eskilson wrote:
Is it really impossible to pass an option to the linker when creating a
static library?
I have not gone through the whole thread but i think the function
SET_TARGET_PROPERTIES(TARGET LINK_FLAGS
On Thursday 14 Jun 2007 12:23:07 pm Jesper Eskilson wrote:
Is it really impossible to pass an option to the linker when creating a
static library?
I have not gone through the whole thread but i think the function
SET_TARGET_PROPERTIES(TARGET LINK_FLAGS XYZ) can do it.
The problem i foresee
2007/6/14, Brandon Van Every [EMAIL PROTECTED]:
On 6/13/07, Jesper Eskilson [EMAIL PROTECTED] wrote:
2007/6/13, Brandon Van Every [EMAIL PROTECTED]:
But why don't you just ship your users a dynamic lib? As far as I
know, there are no restrictions on dynamic libs including static libs.
It's advanced CMake use, but you might want to have a look at overriding
the CMake rule variable CMAKE_CXX_CREATE_STATIC_LIBRARY. (Or _C_ if it's C
source code.) You should be able to add some linker flags in there, although
they may apply to all static libraries built in the whole project. I'm
On 6/14/07, Jesper Eskilson [EMAIL PROTECTED] wrote:
Is it really impossible to pass an option to the linker when creating a
static library?
It's not terribly difficult. But I thought I'd save you the learning
curve if it wasn't necessary.
Cheers,
Brandon Van Every
On 6/12/07, Jesper Eskilson [EMAIL PROTECTED] wrote:
2007/6/12, Brandon Van Every [EMAIL PROTECTED]:
I don't know what the MSVC linker can accomplish. Would suggest reading
the MSVC docs to make sure it can be done.
I *know* that it can be done, since our current hand-written .vcproj files
Forgot to cc the list.
-- Forwarded message --
From: Jesper Eskilson [EMAIL PROTECTED]
Date: 2007-jun-13 19:56
Subject: Re: [CMake] creating static library with references to other .lib files
To: Brandon Van Every [EMAIL PROTECTED]
2007/6/13, Brandon Van Every [EMAIL PROTECTED
On 6/12/07 5:36 PM, Jesper Eskilson wrote:
What you're asking for seems kinda weird. What's the motive?
foo.obj and bar.obj uses symbols in mydll.dll, and I want to allow users
of mystatic.lib to just have to link with mystaticlib.lib, and not with
mydll.lib.
Note that an import
On 6/13/07, Jesper Eskilson [EMAIL PROTECTED] wrote:
2007/6/13, Brandon Van Every [EMAIL PROTECTED]:
But why don't you just ship your users a dynamic lib? As far as I
know, there are no restrictions on dynamic libs including static libs.
That is an alternative, but it requires a non-trivial
2007/6/7, Jesper Eskilson [EMAIL PROTECTED]:
2007/6/7, Brandon Van Every [EMAIL PROTECTED]:
On 6/7/07, Jesper Eskilson [EMAIL PROTECTED] wrote:
Hi all,
I would like to be able to create a static library on Windows which
includes an import library to a DLL, so that users of the
On 6/12/07, Jesper Eskilson [EMAIL PROTECTED] wrote:
2007/6/7, Jesper Eskilson [EMAIL PROTECTED]:
2007/6/7, Brandon Van Every [EMAIL PROTECTED]:
On 6/7/07, Jesper Eskilson [EMAIL PROTECTED] wrote:
Hi all,
I would like to be able to create a static library on Windows which
2007/6/12, Brandon Van Every [EMAIL PROTECTED]:
On some platforms, I bet the underlying linker AR can't even do it. I
know it can't put static libraries inside of static libraries, thats' why
everyone wants convenience libraries and I had to work on all that object
file fakery. Possibly it
Hi all,
I would like to be able to create a static library on Windows which
includes an import library to a DLL, so that users of the static
library do not need to specify the import library.
CMake does not allow me to do this.
TARGET_LINK_LIBRARIES( FooLib BarLib )
does not work when
On 6/7/07, Jesper Eskilson [EMAIL PROTECTED] wrote:
Hi all,
I would like to be able to create a static library on Windows which
includes an import library to a DLL, so that users of the static
library do not need to specify the import library.
By chance, is your library a C library that is
2007/6/7, Brandon Van Every [EMAIL PROTECTED]:
On 6/7/07, Jesper Eskilson [EMAIL PROTECTED] wrote:
Hi all,
I would like to be able to create a static library on Windows which
includes an import library to a DLL, so that users of the static
library do not need to specify the import library.
36 matches
Mail list logo