Skip to content

Commit

Permalink
Fix JoltPhysics compile error on later clang and Xcode (#449)
Browse files Browse the repository at this point in the history
* Fix JoltPhysics compile error on later clang

* Fix typo in macOS build script hints
  • Loading branch information
Mlekow committed May 12, 2023
1 parent dfa6430 commit f7a2751
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
4 changes: 2 additions & 2 deletions build_macos.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

if test \( $# -ne 1 \);
then
echo "Usage: build.sh arch config"
echo "Usage: ./build_macos.sh config"
echo ""
echo "Configs:"
echo "config:"
echo " debug - build with the debug configuration"
echo " release - build with the release configuration"
echo ""
Expand Down
8 changes: 8 additions & 0 deletions engine/3rdparty/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,14 @@ if(NOT TARGET Jolt)

add_subdirectory(JoltPhysics/Build)

if(CMAKE_CXX_COMPILER_ID MATCHES "Clang")
include(CheckCXXCompilerFlag)
check_cxx_compiler_flag("-Wno-unqualified-std-cast-call" COMPILER_CHECK_UNQUALIFIED)
if(COMPILER_CHECK_UNQUALIFIED)
target_compile_options(Jolt PRIVATE "-Wno-unqualified-std-cast-call")
endif()
endif()

if(ENABLE_PHYSICS_DEBUG_RENDERER)
set_target_properties(Jolt TestFramework
PROPERTIES
Expand Down

0 comments on commit f7a2751

Please sign in to comment.