[physx] Update to 4.1.1 (with support for Visual Studio 2019) (#7679)

This commit is contained in:
RT222 2019-08-14 23:05:02 +02:00 committed by Curtis J Bezault
parent e756a7564d
commit 885370d30c
3 changed files with 22 additions and 4 deletions

View File

@ -1,3 +1,3 @@
Source: physx
Version: commit-624f2cb6c0392013d54b235d9072a49d01c3cb6c
Version: 4.1.1-1
Description: The NVIDIA PhysX SDK is a scalable multi-platform physics solution supporting a wide range of devices, from smartphones to high-end multicore CPUs and GPUs

View File

@ -0,0 +1,13 @@
diff --git a/physx/source/foundation/include/windows/PsWindowsInlineAoS.h b/physx/source/foundation/include/windows/PsWindowsInlineAoS.h
index 881dffb..7111189 100644
--- a/physx/source/foundation/include/windows/PsWindowsInlineAoS.h
+++ b/physx/source/foundation/include/windows/PsWindowsInlineAoS.h
@@ -363,7 +363,7 @@
PX_FORCE_INLINE Vec3V V3LoadA(const PxF32* const f)
{
ASSERT_ISALIGNED16(f);
- return V4ClearW(_mm_load_ps(f));
+ return [ & ](){ return V4ClearW(_mm_load_ps(f)); }(); // MSVC 142 bug workaround
}
PX_FORCE_INLINE Vec3V V3LoadU(const PxF32* const i)

View File

@ -20,6 +20,9 @@ if (VCPKG_PLATFORM_TOOLSET STREQUAL "v140")
elseif (VCPKG_PLATFORM_TOOLSET STREQUAL "v141")
set(MSVC_VERSION "15")
set(TOOLSET_VERSION "141")
elseif (VCPKG_PLATFORM_TOOLSET STREQUAL "v142")
set(MSVC_VERSION "16")
set(TOOLSET_VERSION "142")
else()
message(FATAL_ERROR "Unsupported platform toolset.")
endif()
@ -27,9 +30,10 @@ endif()
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO NVIDIAGameWorks/PhysX
REF 624f2cb6c0392013d54b235d9072a49d01c3cb6c
SHA512 80b465f6214434fd53954fe124d8f8aa1ddfcb60d80261f1dc06713bf7fb0f42d8cd96a393fbc46547d9c2199039f386220d7eea63c849ad98863ff26b731e0c
REF ae80dede0546d652040ae6260a810e53e20a06fa
SHA512 f3a690039cf39fe2db9a728b82af0d39eaa02340a853bdad4b5152d63532367eb24fc7033a614882168049b80d803b6225fc60ed2900a9d0deab847f220540be
HEAD_REF master
PATCHES msvc_142_bug_workaround.patch
)
set(BUILD_SNIPPETS "False")
@ -73,13 +77,14 @@ set(RELEASE_CONFIGURATION "release")
set(DEBUG_CONFIGURATION "debug")
vcpkg_build_msbuild(
PROJECT_PATH ${SOURCE_PATH}/physx/compiler/vc15win${WINDOWS_PLATFORM}/PhysXSDK.sln
PROJECT_PATH ${SOURCE_PATH}/physx/compiler/vc${MSVC_VERSION}win${WINDOWS_PLATFORM}/PhysXSDK.sln
RELEASE_CONFIGURATION ${RELEASE_CONFIGURATION}
DEBUG_CONFIGURATION ${DEBUG_CONFIGURATION}
PLATFORM ${MSBUILD_PLATFORM}
)
file(INSTALL ${SOURCE_PATH}/physx/include/ DESTINATION ${CURRENT_PACKAGES_DIR}/include/physx/)
file(INSTALL ${SOURCE_PATH}/pxshared/include/ DESTINATION ${CURRENT_PACKAGES_DIR}/include/physx/)
if (VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
file(GLOB RELEASE_BINS ${SOURCE_PATH}/physx/bin/win.x86_${WINDOWS_PLATFORM}.vc${TOOLSET_VERSION}.${RUNTIME_LIBRARY_LINKAGE}/${RELEASE_CONFIGURATION}/*.dll)