aboutsummaryrefslogtreecommitdiff
path: root/cube
diff options
context:
space:
mode:
authorCharles Giessen <charles@lunarg.com>2023-06-27 17:25:55 -0600
committerCharles Giessen <46324611+charles-lunarg@users.noreply.github.com>2023-06-28 12:06:37 -0600
commit2e5260d44c662d31357e0cd3e430957cddcf1a6e (patch)
tree1b938e8865073d704cbb2eecc4257799d5784ecf /cube
parentea8ea35f4e61ca90f5c8bec43e506ee77b9b57a7 (diff)
downloadusermoji-2e5260d44c662d31357e0cd3e430957cddcf1a6e.tar.xz
build: Default to using the static CRT for MSVC
CMake 3.15 introduced CMAKE_MSVC_RUNTIME_LIBRARY as a way to control the CRT linked to by default. The old way of searching and replacing CMAKE_<LANG>_FLAGS does not work because CMake no longer adds the /MD flag in newer versions. Thus we can remove that code and replace it with a single instance of CMAKE_MSVC_RUNTIME_LIBRARY.
Diffstat (limited to 'cube')
-rw-r--r--cube/CMakeLists.txt22
1 files changed, 0 insertions, 22 deletions
diff --git a/cube/CMakeLists.txt b/cube/CMakeLists.txt
index 5ed07775..9b16da31 100644
--- a/cube/CMakeLists.txt
+++ b/cube/CMakeLists.txt
@@ -177,28 +177,6 @@ endif()
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS}")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
-if(WIN32)
- # Use static MSVCRT libraries
- foreach(configuration
- in
- CMAKE_C_FLAGS_DEBUG
- CMAKE_C_FLAGS_MINSIZEREL
- CMAKE_C_FLAGS_RELEASE
- CMAKE_C_FLAGS_RELWITHDEBINFO
- CMAKE_CXX_FLAGS_DEBUG
- CMAKE_CXX_FLAGS_MINSIZEREL
- CMAKE_CXX_FLAGS_RELEASE
- CMAKE_CXX_FLAGS_RELWITHDEBINFO)
- if(${configuration} MATCHES "/MD")
- string(REGEX
- REPLACE "/MD"
- "/MT"
- ${configuration}
- "${${configuration}}")
- endif()
- endforeach()
-endif()
-
add_custom_command(COMMENT "Compiling cube vertex shader"
OUTPUT cube.vert.inc
COMMAND ${GLSLANG_VALIDATOR} -V -x -o ${CMAKE_CURRENT_BINARY_DIR}/cube.vert.inc