Define CMake library object lists globally
OBJECT collections in CMake don't generate any artifacts so these are safe to hoist out and define globally. library OBJECT targets are just a list of filenames. It can be useful for other projects to include lists of sources directly regardless of build mode (shared, static, or library).
This commit is contained in:
@@ -48,8 +48,8 @@ set(
|
||||
t1_srvr.c
|
||||
)
|
||||
|
||||
add_library(ssl-objects OBJECT ${SSL_SRC})
|
||||
if (BUILD_SHARED)
|
||||
add_library(ssl-objects OBJECT ${SSL_SRC})
|
||||
add_library(ssl STATIC $<TARGET_OBJECTS:ssl-objects>)
|
||||
add_library(ssl-shared SHARED $<TARGET_OBJECTS:ssl-objects>)
|
||||
if (WIN32)
|
||||
|
Reference in New Issue
Block a user