Skip to content

Commit

Permalink
fixed building
Browse files Browse the repository at this point in the history
  • Loading branch information
jrouwe committed Aug 3, 2023
1 parent 161ab27 commit 865873a
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 42 deletions.
41 changes: 0 additions & 41 deletions Build/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -228,44 +228,3 @@ if (TARGET_UNIT_TESTS)
enable_testing()
add_test(UnitTests UnitTests)
endif()

if (NOT "${CMAKE_SYSTEM_NAME}" STREQUAL "WindowsStore")
if (TARGET_HELLO_WORLD)
# Example 'Hello World' application
include(${PHYSICS_REPO_ROOT}/HelloWorld/HelloWorld.cmake)
add_executable(HelloWorld ${HELLO_WORLD_SRC_FILES})
target_include_directories(HelloWorld PUBLIC ${HELLO_WORLD_ROOT})
target_link_libraries(HelloWorld LINK_PUBLIC Jolt)
if ("${CMAKE_SYSTEM_NAME}" STREQUAL "Windows" AND NOT MINGW)
target_link_options(HelloWorld PUBLIC "/SUBSYSTEM:CONSOLE")
endif()
endif()

if (TARGET_PERFORMANCE_TEST)
# Performance Test application
include(${PHYSICS_REPO_ROOT}/PerformanceTest/PerformanceTest.cmake)
add_executable(PerformanceTest ${PERFORMANCE_TEST_SRC_FILES})
target_include_directories(PerformanceTest PUBLIC ${PERFORMANCE_TEST_ROOT})
target_link_libraries(PerformanceTest LINK_PUBLIC Jolt)
if ("${CMAKE_SYSTEM_NAME}" STREQUAL "Windows" AND NOT MINGW)
target_link_options(PerformanceTest PUBLIC "/SUBSYSTEM:CONSOLE")
endif()
set_property(TARGET PerformanceTest PROPERTY VS_DEBUGGER_WORKING_DIRECTORY "${PHYSICS_REPO_ROOT}")

# Copy the assets folder
add_custom_command(TARGET PerformanceTest PRE_BUILD COMMAND ${CMAKE_COMMAND} -E copy_directory ${PHYSICS_REPO_ROOT}/Assets/ $<TARGET_FILE_DIR:PerformanceTest>/Assets/)
endif()
endif()

if ("${CMAKE_SYSTEM_NAME}" STREQUAL "Windows")
# Windows only targets
if (TARGET_SAMPLES OR TARGET_VIEWER)
include(${PHYSICS_REPO_ROOT}/TestFramework/TestFramework.cmake)
endif()
if (TARGET_SAMPLES)
include(${PHYSICS_REPO_ROOT}/Samples/Samples.cmake)
endif()
if (TARGET_VIEWER)
include(${PHYSICS_REPO_ROOT}/JoltViewer/JoltViewer.cmake)
endif()
endif()
2 changes: 1 addition & 1 deletion UnitTests/Test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ TEST_SUITE("Suite")
{
TEST_CASE("Test")
{
CHECK(false);
CHECK(true);
}
}

0 comments on commit 865873a

Please sign in to comment.