diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2018-07-11 05:25:58 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2018-07-11 05:26:21 +0200 |
commit | e573612baa03780683d20edad74e95bdf59c5681 (patch) | |
tree | 894fcae70bd5788cce94d8e5dbde96bf5cc82ce7 /cmake | |
parent | 8562e190d63710f77bf00b1b2cd7ccde6153eef0 (diff) |
cmake: fix build
Diffstat (limited to 'cmake')
-rw-r--r-- | cmake/msvc.cmake | 6 | ||||
-rw-r--r-- | cmake/opentrack-i18n.cmake | 5 | ||||
-rw-r--r-- | cmake/opentrack-platform.cmake | 1 |
3 files changed, 7 insertions, 5 deletions
diff --git a/cmake/msvc.cmake b/cmake/msvc.cmake index dfc6b59c..a4a1f5c6 100644 --- a/cmake/msvc.cmake +++ b/cmake/msvc.cmake @@ -105,18 +105,18 @@ endforeach() foreach(k "" _DEBUG _RELEASE) #set(CMAKE_STATIC_LINKER_FLAGS${k} "${CMAKE_STATIC_LINKER_FLAGS${k}} ${_LDFLAGS_STATIC${k}}") - set(CMAKE_STATIC_LINKER_FLAGS${k} "${_LDFLAGS_STATIC${k}} ${FLAGS_ARCHIVE${k}}") + set(CMAKE_STATIC_LINKER_FLAGS${k} "${_LDFLAGS_STATIC${k}} ${FLAGS_ARCHIVE${k}}" CACHE STRING "" FORCE) endforeach() foreach(j "" _DEBUG _RELEASE) foreach(i MODULE EXE SHARED) #set(CMAKE_${i}_LINKER_FLAGS${j} "${CMAKE_${i}_LINKER_FLAGS${j}} ${_LDFLAGS${j}}") - set(CMAKE_${i}_LINKER_FLAGS${j} "${_LDFLAGS${j}} ${FLAGS_LD${j}}") + set(CMAKE_${i}_LINKER_FLAGS${j} "${_LDFLAGS${j}} ${FLAGS_LD${j}}" CACHE STRING "" FORCE) endforeach() endforeach() foreach(j C CXX) foreach(i "" _DEBUG _RELEASE) #set(CMAKE_${j}_FLAGS${i} "${CMAKE_${j}_FLAGS${i}} ${_${j}FLAGS${i}}") - set(CMAKE_${j}_FLAGS${i} "${_${j}FLAGS${i}} ${FLAGS_${j}${i}}") + set(CMAKE_${j}_FLAGS${i} "${_${j}FLAGS${i}} ${FLAGS_${j}${i}}" CACHE STRING "" FORCE) endforeach() endforeach() diff --git a/cmake/opentrack-i18n.cmake b/cmake/opentrack-i18n.cmake index 8e8a74df..7557c642 100644 --- a/cmake/opentrack-i18n.cmake +++ b/cmake/opentrack-i18n.cmake @@ -9,8 +9,9 @@ function(otr_i18n_for_target_directory n) set(t2 "${CMAKE_CURRENT_BINARY_DIR}/lang/${i}.ts") set(input "${${k}-all}") if (NOT EXISTS "${t}") - file(READ "${CMAKE_CURRENT_LIST_DIR}/translation-stub.ts") - file(WRITE "${t}") + file(MAKE_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/lang") + file(READ "${CMAKE_SOURCE_DIR}/cmake/translation-stub.ts" stub) + file(WRITE "${t}" "${stub}") endif() add_custom_command(OUTPUT "${t2}" COMMAND "${CMAKE_COMMAND}" -E make_directory "${CMAKE_CURRENT_SOURCE_DIR}/lang" diff --git a/cmake/opentrack-platform.cmake b/cmake/opentrack-platform.cmake index 285c07c7..5ad2709c 100644 --- a/cmake/opentrack-platform.cmake +++ b/cmake/opentrack-platform.cmake @@ -135,6 +135,7 @@ set_property(GLOBAL PROPERTY USE_FOLDERS OFF) if(MINGW) add_definitions(-DMINGW_HAS_SECURE_API) + add_definitions(-DSTRSAFE_NO_DEPRECATE) endif() # assume binutils |