1 2 3 4 5 6 7 8
add_library(objects OBJECT empty.cpp) add_library(empty empty.cpp $<TARGET_OBJECTS:objects>) get_target_property(srcs empty SOURCES) message("Sources: \"${srcs}\"")