[physx] Added a patch to fix missing typeinfo.h header with VS16.3 and missing pdb files (#8561)

* [physx] Added a patch to fix missing typeinfo.h header with VS16.3

* [physx] Fixed missing pdb files

* [physx] Fixed the remaining missing pdb files
This commit is contained in:
RT222 2019-10-18 02:38:26 +02:00 committed by dan-shaw
parent db411cbe64
commit 94ce38b45a
3 changed files with 43 additions and 13 deletions

View File

@ -1,3 +1,3 @@
Source: physx
Version: 4.1.1-1
Version: 4.1.1-2
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

@ -33,7 +33,9 @@ vcpkg_from_github(
REF ae80dede0546d652040ae6260a810e53e20a06fa
SHA512 f3a690039cf39fe2db9a728b82af0d39eaa02340a853bdad4b5152d63532367eb24fc7033a614882168049b80d803b6225fc60ed2900a9d0deab847f220540be
HEAD_REF master
PATCHES msvc_142_bug_workaround.patch
PATCHES
msvc_142_bug_workaround.patch
vs16_3_typeinfo_header_fix.patch
)
set(BUILD_SNIPPETS "False")
@ -54,7 +56,9 @@ elseif (VCPKG_CRT_LINKAGE STREQUAL "static")
set(RUNTIME_LIBRARY_LINKAGE "mt")
endif()
set(PRESET_FILE vc${MSVC_VERSION}win${WINDOWS_PLATFORM}-${RUNTIME_LIBRARY_LINKAGE}-${VCPKG_LIBRARY_LINKAGE})
set(VC_VERSION "vc${MSVC_VERSION}win${WINDOWS_PLATFORM}")
set(PRESET_FILE ${VC_VERSION}-${RUNTIME_LIBRARY_LINKAGE}-${VCPKG_LIBRARY_LINKAGE})
file(REMOVE ${SOURCE_PATH}/physx/buildtools/presets/public/${PRESET_FILE}.xml)
configure_file(${CMAKE_CURRENT_LIST_DIR}/preset.xml.in ${SOURCE_PATH}/physx/buildtools/presets/public/${PRESET_FILE}.xml)
@ -77,29 +81,43 @@ set(RELEASE_CONFIGURATION "release")
set(DEBUG_CONFIGURATION "debug")
vcpkg_build_msbuild(
PROJECT_PATH ${SOURCE_PATH}/physx/compiler/vc${MSVC_VERSION}win${WINDOWS_PLATFORM}/PhysXSDK.sln
PROJECT_PATH ${SOURCE_PATH}/physx/compiler/${VC_VERSION}/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/)
set(BUILD_PATH "win.x86_${WINDOWS_PLATFORM}.vc${TOOLSET_VERSION}.${RUNTIME_LIBRARY_LINKAGE}")
file(INSTALL ${SOURCE_PATH}/physx/include/ DESTINATION ${CURRENT_PACKAGES_DIR}/include/${PORT}/)
file(INSTALL ${SOURCE_PATH}/pxshared/include/ DESTINATION ${CURRENT_PACKAGES_DIR}/include/${PORT}/)
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)
file(GLOB RELEASE_BINS ${SOURCE_PATH}/physx/bin/${BUILD_PATH}/${RELEASE_CONFIGURATION}/*.dll)
file(INSTALL ${RELEASE_BINS} DESTINATION ${CURRENT_PACKAGES_DIR}/bin)
file(GLOB DEBUG_BINS ${SOURCE_PATH}/physx/bin/win.x86_${WINDOWS_PLATFORM}.vc${TOOLSET_VERSION}.${RUNTIME_LIBRARY_LINKAGE}/${DEBUG_CONFIGURATION}/*.dll)
file(GLOB DEBUG_BINS ${SOURCE_PATH}/physx/bin/${BUILD_PATH}/${DEBUG_CONFIGURATION}/*.dll)
file(INSTALL ${DEBUG_BINS} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/bin)
vcpkg_copy_pdbs()
endif()
file(GLOB RELEASE_LIBS ${SOURCE_PATH}/physx/bin/win.x86_${WINDOWS_PLATFORM}.vc${TOOLSET_VERSION}.${RUNTIME_LIBRARY_LINKAGE}/${RELEASE_CONFIGURATION}/*.lib)
file(
GLOB
RELEASE_LIBS
${SOURCE_PATH}/physx/bin/${BUILD_PATH}/${RELEASE_CONFIGURATION}/*.lib
${SOURCE_PATH}/physx/bin/${BUILD_PATH}/${RELEASE_CONFIGURATION}/*.pdb
${SOURCE_PATH}/physx/compiler/${VC_VERSION}/sdk_source_bin/${RELEASE_CONFIGURATION}/*.pdb
)
file(INSTALL ${RELEASE_LIBS} DESTINATION ${CURRENT_PACKAGES_DIR}/lib)
file(GLOB DEBUG_LIBS ${SOURCE_PATH}/physx/bin/win.x86_${WINDOWS_PLATFORM}.vc${TOOLSET_VERSION}.${RUNTIME_LIBRARY_LINKAGE}/${DEBUG_CONFIGURATION}/*.lib)
file(
GLOB
DEBUG_LIBS
${SOURCE_PATH}/physx/bin/${BUILD_PATH}/${DEBUG_CONFIGURATION}/*.lib
${SOURCE_PATH}/physx/bin/${BUILD_PATH}/${DEBUG_CONFIGURATION}/*.pdb
${SOURCE_PATH}/physx/compiler/${VC_VERSION}/sdk_source_bin/${DEBUG_CONFIGURATION}/*.pdb
)
file(INSTALL ${DEBUG_LIBS} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib)
vcpkg_copy_pdbs()
file(INSTALL ${SOURCE_PATH}/README.md DESTINATION ${CURRENT_PACKAGES_DIR}/share/physx RENAME copyright)
file(INSTALL ${SOURCE_PATH}/README.md DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)

View File

@ -0,0 +1,12 @@
diff --git a/physx/source/foundation/include/PsAllocator.h b/physx/source/foundation/include/PsAllocator.h
--- a/physx/source/foundation/include/PsAllocator.h
+++ b/physx/source/foundation/include/PsAllocator.h
@@ -37,7 +37,7 @@
#if(PX_WINDOWS_FAMILY || PX_XBOXONE)
#include <exception>
- #include <typeinfo.h>
+ #include <typeinfo>
#endif
#if(PX_APPLE_FAMILY)
#include <typeinfo>