CMake: Provide proper interface targets from dependencies
This commit is contained in:
1 parent
aec309a533
commit
6564fcffdf
23 files changed
+465
-237
No files matched your search
+17
-12
@@ -10,17 +10,22 @@
|
||||
|
||||
file(GLOB sources *.cpp *.h)
|
||||
|
||||
set(gsoap_STAT_SRCS
|
||||
${sources}
|
||||
)
|
||||
|
||||
include_directories(
|
||||
${CMAKE_CURRENT_SOURCE_DIR}
|
||||
)
|
||||
|
||||
# Little fix for MSVC / Windows platforms
|
||||
add_definitions(-D_CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES=0)
|
||||
|
||||
add_library(gsoap STATIC ${gsoap_STAT_SRCS})
|
||||
add_library(gsoap STATIC ${sources})
|
||||
|
||||
set_target_properties(gsoap PROPERTIES LINKER_LANGUAGE CXX)
|
||||
|
||||
target_include_directories(gsoap
|
||||
PUBLIC
|
||||
${CMAKE_CURRENT_SOURCE_DIR})
|
||||
|
||||
set_target_properties(gsoap
|
||||
PROPERTIES
|
||||
FOLDER
|
||||
"dep")
|
||||
|
||||
if (MSVC)
|
||||
# Little fix for MSVC / Windows platforms
|
||||
target_compile_definitions(gsoap
|
||||
PRIVATE
|
||||
-D_CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES=0)
|
||||
endif()
|
||||
Reference in new issue
Block a user