Skip to content

Commit 38176a9

Browse files
committed
Adjust MSVC flags.
1 parent 5fe93a9 commit 38176a9

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

CMakeLists.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,10 @@ function(tiny_engine_configure_target TARGET_NAME)
2828

2929
# More warnings.
3030
if(MSVC)
31-
target_compile_options(${TARGET_NAME} PUBLIC /W3 /WX /wd4996 /wd4090) # disable warnings: unsafe function, different const qualifiers
31+
target_compile_options(${TARGET_NAME} PUBLIC /W3 /WX /wd4996)
32+
if(CMAKE_SIZEOF_VOID_P EQUAL 4)
33+
target_compile_options(${TARGET_NAME} PUBLIC /wd4090)
34+
endif()
3235
else()
3336
target_compile_options(${TARGET_NAME} PUBLIC -Wall -Wextra -Werror -Wconversion -Wno-unused-but-set-parameter -Wno-incompatible-function-pointer-types)
3437
if(CMAKE_SIZEOF_VOID_P EQUAL 4)

0 commit comments

Comments
 (0)