Hello,
The libraries I developing can be used as a shared libraries, static
libraries or header-only libraries.
I want to let the users to:
- install all three variants side by side;
- choice what variant of library to use for linkage.
I see 2 options here:
1. use different config files. For
All,
The new 2020 signing key for the APT repository
(https://apt.kitware.com/) has been generated for 2020, with
fingerprint A8E5EF3A02600268. The 2019 key, with fingerprint
C1F34CDD40CD72DA, will remain in effect until the beginning of 2020, at
which point the 2020 key will go into effect. The
I completely forgot that the Makefiles based generators in CMake have
a separate heuristic for determining system headers.
If you use the Ninja generator I see the expected behavior:
~/W/t/nbuild $ sudo touch /usr/include/c++/7/array
~/W/t/nbuild $ ninja -d explain -v
ninja explain: output test/CM
Thank. Yeah, I've seen BLT through it's use in RAJA. You're right, it'd
work, but I'm reluctant to stray away from "vanilla" cmake too much, since
other people will have to deal with this code, and cmake itself is already
quite a step up from the regular Makefiles that they're used to.
--Kai
On
On Wed, 2019-07-03 at 18:55 +0530, vinay kumar Kotegowder wrote:
> I want to build lib2 static library with pre-built lib1 static
> library.
> Does this work?
>
> add_library(lib1 STATIC lib1.c)
> add_library(lib2 STATIC lib2.c)
> target_link_libraries(lib2 INTERFACE lib1)
Yes, this will wor
I want to build lib2 static library with pre-built lib1 static library.
Does this work?
add_library(lib1 STATIC lib1.c)
add_library(lib2 STATIC lib2.c)
target_link_libraries(lib2 INTERFACE lib1)
Also, Kyle said linking against lib2 will link against both lib1 and
lib2. Is there a static way
I want to build lib2 static array with pre-built lib1 static array.
Does this work?
add_library(lib1 STATIC lib1.c)
add_library(lib2 STATIC lib2.c)
target_link_libraries(lib2 INTERFACE lib1)
Also, Kyle said linking against lib2 will link against both lib1 and
lib2. Is there a static way of
I think there is no platform-independent way to solve this. Maybe you
could create two OBJECT libraries that are "linked" together into one
static lib.
Best regards,
Rainer
On Tue, Jul 2, 2019 at 5:30 PM Cristian Adam wrote:
>
>
> On Tue, Jul 2, 2019 at 5:14 PM vinay kumar Kotegowder
> wrote
Have a look at variables ‘CMAKE_*_OUTPUT_DIRECTORY’ (Like
CMAKE_ARCHIVE_OUTPUT_DIRECTORY. See
https://cmake.org/cmake/help/latest/manual/cmake-variables.7.html) and target
properties ‘*_OUTPUT_DIRECTORY’ (Like ARCHIVE_OUTPUT_DIRECTORY. See
https://cmake.org/cmake/help/latest/manual/cmake-proper