Skip to content

Commit

Permalink
Fix utf 8 charset and formatting cmake
Browse files Browse the repository at this point in the history
  • Loading branch information
Stepanov Igor committed Jan 9, 2025
1 parent d89cb57 commit b417a01
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
5 changes: 1 addition & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,7 @@ if(VOXELENGINE_BUILD_APPDIR)
endif()

if(MSVC)
target_compile_options(
VoxelEngine
PRIVATE /source-charset:UTF-8 /D_DISABLE_CONSTEXPR_MUTEX_CONSTRUCTOR
/W4)

else()
target_compile_options(
VoxelEngine
Expand Down
5 changes: 5 additions & 0 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ target_include_directories(
VoxelEngineSrc
PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}
PRIVATE ${LUA_INCLUDE_DIR})

target_link_libraries(
VoxelEngineSrc
PRIVATE glfw
Expand All @@ -80,3 +81,7 @@ target_link_libraries(
PUBLIC glm::glm # Need public for src/delegates.hpp, which including to
# main.cpp
)

target_compile_options(
VoxelEngineSrc PUBLIC /source-charset:UTF-8
/D_DISABLE_CONSTEXPR_MUTEX_CONSTRUCTOR /W4)
3 changes: 1 addition & 2 deletions vctest/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@ add_executable(vctest ${CMAKE_CURRENT_LIST_DIR}/main.cpp)
target_include_directories(vctest PRIVATE ${CMAKE_SOURCE_DIR}/src)

if(MSVC)
target_compile_options(
vctest PRIVATE /W4)
target_compile_options(vctest PRIVATE /W4)
else()
target_compile_options(
vctest
Expand Down

0 comments on commit b417a01

Please sign in to comment.