|
|
@@ -1,19 +1,26 @@
|
|
|
function(build_boxing_module build_static_flag build_shared_flag module_name module_name_core source_files)
|
|
|
+ include(${CMAKE_CURRENT_LIST_DIR}/cmake/Security.cmake)
|
|
|
+
|
|
|
if (${build_static_flag})
|
|
|
add_library("${${module_name}}" STATIC ${${source_files}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
endif ()
|
|
|
|
|
|
if (${build_shared_flag})
|
|
|
add_library("${${module_name}}" SHARED ${${source_files}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
target_link_libraries("${${module_name}}" ${module_name_core})
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
endif ()
|
|
|
endfunction()
|
|
|
|
|
|
function(build_core_module build_static_flag build_shared_flag build_jni_flag module_name source_files jni_source_files)
|
|
|
+ include(${CMAKE_CURRENT_LIST_DIR}/cmake/Security.cmake)
|
|
|
+
|
|
|
if (${build_static_flag})
|
|
|
add_library("${${module_name}}" STATIC ${${source_files}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
endif ()
|
|
|
|
|
|
@@ -21,56 +28,73 @@ function(build_core_module build_static_flag build_shared_flag build_jni_flag mo
|
|
|
if (${build_jni_flag})
|
|
|
message("${${module_name}}: building with JNI...")
|
|
|
add_library("${${module_name}}" SHARED ${${source_files}} ${${jni_source_files}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
else ()
|
|
|
add_library("${${module_name}}" SHARED ${${source_files}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
endif ()
|
|
|
endif ()
|
|
|
endfunction()
|
|
|
|
|
|
function(build_encoding_module build_static_flag build_shared_flag module_name module_name_core source_files)
|
|
|
+ include(${CMAKE_CURRENT_LIST_DIR}/cmake/Security.cmake)
|
|
|
+
|
|
|
if (${build_static_flag})
|
|
|
add_library("${${module_name}}" STATIC ${${source_files}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
endif ()
|
|
|
|
|
|
if (${build_shared_flag})
|
|
|
add_library("${${module_name}}" SHARED ${${source_files}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
target_link_libraries("${${module_name}}" ${module_name_core})
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
endif ()
|
|
|
endfunction()
|
|
|
|
|
|
function(build_event_module build_static_flag build_shared_flag module_name module_name_core source_files)
|
|
|
+ include(${CMAKE_CURRENT_LIST_DIR}/cmake/Security.cmake)
|
|
|
+
|
|
|
if (${build_static_flag})
|
|
|
add_library("${${module_name}}" STATIC ${${source_files}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
endif ()
|
|
|
|
|
|
if (${build_shared_flag})
|
|
|
add_library("${${module_name}}" SHARED ${${source_files}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
target_link_libraries("${${module_name}}" ${module_name_core})
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
endif ()
|
|
|
endfunction()
|
|
|
|
|
|
function(build_io_module build_static_flag build_shared_flag module_name module_name_core source_files)
|
|
|
+ include(${CMAKE_CURRENT_LIST_DIR}/cmake/Security.cmake)
|
|
|
+
|
|
|
if (${build_static_flag})
|
|
|
add_library("${${module_name}}" STATIC ${${source_files}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
endif ()
|
|
|
|
|
|
if (${build_shared_flag})
|
|
|
add_library("${${module_name}}" SHARED ${${source_files}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
target_link_libraries("${${module_name}}" ${module_name_core})
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
endif ()
|
|
|
endfunction()
|
|
|
|
|
|
function(build_time_module build_static_flag build_shared_flag build_jni_flag module_name module_name_core source_files source_files_linux source_files_windows source_files_jni)
|
|
|
+ include(${CMAKE_CURRENT_LIST_DIR}/cmake/Security.cmake)
|
|
|
+
|
|
|
if (${build_static_flag})
|
|
|
add_library("${${module_name}}" STATIC ${${source_files}} ${${source_files_linux}} ${${source_files_windows}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
endif ()
|
|
|
|
|
|
@@ -78,10 +102,12 @@ function(build_time_module build_static_flag build_shared_flag build_jni_flag mo
|
|
|
if (${build_jni_flag})
|
|
|
message("${${module_name}}: building with JNI...")
|
|
|
add_library("${${module_name}}" SHARED ${${source_files}} ${${source_files_linux}} ${${source_files_windows}} ${${source_files_jni}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
target_link_libraries("${${module_name}}" ${module_name_core})
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
else ()
|
|
|
add_library("${${module_name}}" SHARED ${${source_files}} ${${source_files_linux}} ${${source_files_windows}})
|
|
|
+ enable_strict_warnings(module_name)
|
|
|
target_link_libraries("${${module_name}}" ${module_name_core})
|
|
|
set_target_properties("${${module_name}}" PROPERTIES DEBUG_POSTFIX "-d")
|
|
|
endif ()
|