mirror of
https://gitlab.kitware.com/cmake/cmake.git
synced 2026-09-25 04:09:36 +03:00
When `PRIVATE` sources are added to an `INTERFACE` target A and A is a dependency of B - the target A ends up in "direct dependencies" of the B targets and it messes up the generated `fbuild.bff` file. Fixes: #27644
7 lines
189 B
CMake
7 lines
189 B
CMake
add_library(iface_lib INTERFACE EXCLUDE_FROM_ALL)
|
|
target_sources(iface_lib PRIVATE header.hpp)
|
|
|
|
add_library(static_lib STATIC main.cpp)
|
|
|
|
target_link_libraries(static_lib PRIVATE iface_lib)
|