Fix: always use an interface lib for flatsample#8897
Fix: always use an interface lib for flatsample#8897jtdavis777 wants to merge 1 commit intogoogle:masterfrom
Conversation
|
I don't know about the MSVC case but i added the second case for old cmake versions here #8173 i think we break cmake older than 3.20.0 (https://github.com/Kitware/CMake/releases/tag/v3.20.0 released 2021) I guess this will still break older systems like debian bullseye https://packages.debian.org/bullseye/cmake If we want to do that i would propose to set |
|
We definitely can't do that -- what specifically breaks in the older versions? Interface libs have been supported since 3.0 |
|
It might be supported since 3.0 but it it started working properly only with 3.20 or something. To reproduce -> But it looks like it is already broken right now (using the type |
| add_library(flatsample INTERFACE) | ||
|
|
||
| # Since flatsample has no sources, we have to explicitly set the linker lang. | ||
| set_target_properties(flatsample PROPERTIES LINKER_LANGUAGE CXX) |
There was a problem hiding this comment.
looking at the issue again i would propose to remove this line (578) as well and then it works with old cmake version, no idea about the MSVC case but i prose to fix that later if that still breaks for someone and we understand what the issues is
|
Yeah the static failure is what was reported in the issue I'm looking to fix. Thanks for the repro steps!! |
Fixes #8889
I'm not sure why the STATIC fallback case exists, so removing it.