Skip to content

Commit

Permalink
msvc fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
ScrelliCopter committed Apr 10, 2024
1 parent 0dd9074 commit b630881
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
3 changes: 2 additions & 1 deletion ext/base64/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
add_library(base64
base64.cpp base64.h)
add_library(base64::base64 ALIAS base64)
set_target_properties(base64 PROPERTIES CXX_STANDARD 17)
set_target_properties(base64 PROPERTIES CXX_STANDARD 17 CXX_STANDARD_REQUIRED ON)
target_compile_options(base64 PUBLIC $<$<CXX_COMPILER_ID:MSVC>:/Zc:__cplusplus>)
target_include_directories(base64
PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
4 changes: 3 additions & 1 deletion src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ configure_file(config.h.in config.h @ONLY)
target_sources(tmx2gba PRIVATE ${CMAKE_CURRENT_BINARY_DIR}/config.h)
target_include_directories(tmx2gba PRIVATE ${CMAKE_CURRENT_BINARY_DIR})

set_target_properties(tmx2gba PROPERTIES CXX_STANDARD 20)
set_target_properties(tmx2gba PROPERTIES
CXX_STANDARD 20
CXX_STANDARD_REQUIRED ON)

target_compile_definitions(${PROJECT_NAME} PRIVATE
$<$<BOOL:${MSVC}>:_CRT_SECURE_NO_WARNINGS> # disable msvc warning
Expand Down
1 change: 1 addition & 0 deletions src/tmxmap.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#include <limits>
#include <cerrno>
#include <optional>
#include <algorithm>


template <typename T>
Expand Down

0 comments on commit b630881

Please sign in to comment.