Skip to content

Commit

Permalink
Fixed PCH for Demos and Test
Browse files Browse the repository at this point in the history
  • Loading branch information
WillisMedwell committed Jan 30, 2024
1 parent 88bfe82 commit 1a303c1
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion code/Demos/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ file(COPY ${CMAKE_SOURCE_DIR}/.clang-tidy DESTINATION ${CMAKE_CURRENT_BINARY_DIR

add_executable(Demos ${DEMOS_SOURCES} ${DEMOS_HEADERS})

target_precompile_headers(Demos PUBLIC ${CMAKE_CURRENT_INCLUDE_DIR}/Engine.hpp)
target_precompile_headers(Demos PRIVATE ../Engine/include/Engine.hpp)

if(DEFINED EMSCRIPTEN)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -s EXPORTED_FUNCTIONS='_main' -s EXPORT_NAME=\"'WasmModuleDemos'\"")
Expand Down
2 changes: 1 addition & 1 deletion code/Test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ file(COPY ${CMAKE_SOURCE_DIR}/.clang-tidy DESTINATION ${CMAKE_CURRENT_BINARY_DIR

add_executable(Test ${TEST_SOURCES} ${TEST_HEADERS})

target_precompile_headers(Test PRIVATE include/TestPch.hpp ${CMAKE_CURRENT_INCLUDE_DIR}/Engine.hpp)
target_precompile_headers(Test PRIVATE include/TestPch.hpp ../Engine/include/Engine.hpp)

if(DEFINED EMSCRIPTEN)
set(CMAKE_EXECUTABLE_SUFFIX ".html")
Expand Down
8 changes: 4 additions & 4 deletions code/build-native.bat
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ cd build-native
call cmake .. -G "Ninja" -DCMAKE_TOOLCHAIN_FILE=%VCPKG_PATH%/scripts/buildsystems/vcpkg.cmake -DVCPKG_TARGET_TRIPLET=x64-windows -DCMAKE_BUILD_TYPE=%BUILD_TYPE%
call cmake --build . --config %BUILD_TYPE%

@REM cd Test
@REM call Test
@REM cd ../Demos
@REM call Demos
cd Test
call Test
cd ../Demos
call Demos

0 comments on commit 1a303c1

Please sign in to comment.