mirror of
https://github.com/microsoft/vcpkg.git
synced 2025-06-07 01:24:47 +08:00
[physx] Fix x86 Linux build errors (#30014)
As per comments in the source, "some GCC compilers need the compiler
flag -malign-double to be set."
a2c0428aca/pxshared/include/foundation/PxPreprocessor.h (L473)
This commit is contained in:
parent
7d5f1f3e13
commit
e12d82b8eb
@ -56,3 +56,20 @@ index a1ab3596..dbd20fb0 100644
|
||||
|
||||
# cache lib type defs
|
||||
IF(PX_GENERATE_STATIC_LIBRARIES)
|
||||
diff --git a/physx/source/compiler/cmake/linux/CMakeLists.txt b/physx/source/compiler/cmake/linux/CMakeLists.txt
|
||||
index 6246e488..7bf0cc30 100644
|
||||
--- a/physx/source/compiler/cmake/linux/CMakeLists.txt
|
||||
+++ b/physx/source/compiler/cmake/linux/CMakeLists.txt
|
||||
@@ -36,6 +36,11 @@ IF ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
|
||||
SET(PHYSX_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-rtti -fno-exceptions -ffunction-sections -fdata-sections -fstrict-aliasing ${CLANG_WARNINGS}" CACHE INTERNAL "PhysX CXX")
|
||||
ELSEIF ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
|
||||
SET(PHYSX_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-rtti -fno-exceptions -ffunction-sections -fdata-sections -fno-strict-aliasing ${GCC_WARNINGS}" CACHE INTERNAL "PhysX CXX")
|
||||
+
|
||||
+ # Enable SSE2 and fix double alignment for 32-bit x86 builds
|
||||
+ IF (CMAKE_SYSTEM_PROCESSOR MATCHES "i686.*|i386.*|x86.*")
|
||||
+ STRING(APPEND PHYSX_CXX_FLAGS " -malign-double -msse2")
|
||||
+ ENDIF()
|
||||
ENDIF()
|
||||
|
||||
# Build debug info for all configurations
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "physx",
|
||||
"version": "4.1.2",
|
||||
"port-version": 5,
|
||||
"port-version": 6,
|
||||
"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",
|
||||
"homepage": "https://github.com/NVIDIAGameWorks/PhysX",
|
||||
"license": null,
|
||||
|
@ -6050,7 +6050,7 @@
|
||||
},
|
||||
"physx": {
|
||||
"baseline": "4.1.2",
|
||||
"port-version": 5
|
||||
"port-version": 6
|
||||
},
|
||||
"picojson": {
|
||||
"baseline": "1.3.0",
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "038801f9419a356c7082b1501620bdef60da6d66",
|
||||
"version": "4.1.2",
|
||||
"port-version": 6
|
||||
},
|
||||
{
|
||||
"git-tree": "b081926dc46f3fadf1696719e4b708f4cd136f25",
|
||||
"version": "4.1.2",
|
||||
|
Loading…
Reference in New Issue
Block a user