boostorg / boostorg/boost_install
Exclusion of static libs for static runtime usage
- Dominant language
- C
- Stars
- 11
- Forks
- 37
- PR merge metrics
- No merged PRs in 30d
Description
If I do a build with default settings (e.g. just `./b2 install`) on linux, I get dynamic and static libs built using the `system` naming convention. By default, boost assumes a shared runtime. For static libs, however, does it really matter? For instance, my consuming application specifies both `Boost_USE_STATIC_LIBS` and `Boost_USE_STATIC_RUNTIME` and thus the default install fails to find the library because of this cmake config code (just using chrono as an example here) :
```cmake
# runtime-link=shared
if(Boost_USE_STATIC_RUNTIME)
_BOOST_SKIPPED("libboost_chrono.a" "shared runtime, Boost_USE_STATIC_RUNTIME=${Boost_USE_STATIC_RUNTIME}")
return()
endif()
```
When I switch to a `tagged` layout and build versions for both static and shared runtime, I get two copies of what appear to be the same static library. Couldn't we just make an exception and allow the system layout to work for either runtime choice? I realize this might be OS dependent since windows is clearly different in this regard and apple-clang doesn't allow static runtime at all (I believe).
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.