CMake/Tests/RunCMake/add_library/UNKNOWNwithNoSourcesButLinkObjects.cmake
Deniz Bahadir fe4b25ec2f Teach target_* commands to set INTERFACE properties of IMPORTED targets
Now, several `INTERFACE_*` properties can be set on `IMPORTED` targets,
not only via `set_property` and `set_target_properties` but also via
`target_compile_definitions`, `target_compile_features`,
`target_compile_options`, `target_include_directories`, `target_sources`
and `target_link_libraries`.

Fixes: #15689
Issue: #17197
2017-10-26 09:11:04 -04:00

6 lines
230 B
CMake

enable_language(CXX)
add_library(ObjectLibDependency OBJECT test.cpp)
add_library(TestUnknownLibWithoutSources UNKNOWN IMPORTED)
target_link_libraries(TestUnknownLibWithoutSources INTERFACE $<TARGET_OBJECTS:ObjectLibDependency>)