diff --git a/ports/bullet3/cmake-fix.patch b/ports/bullet3/cmake-fix.patch index 12457f4ca0..3b80ac00a0 100644 --- a/ports/bullet3/cmake-fix.patch +++ b/ports/bullet3/cmake-fix.patch @@ -35,7 +35,7 @@ index f5dc7bd..50b3d67 100644 + set(_DIR) +endif() diff --git a/CMakeLists.txt b/CMakeLists.txt -index a695b71..607edde 100644 +index a695b71..f98cf4d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ @@ -44,7 +44,7 @@ index a695b71..607edde 100644 set(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS true) cmake_policy(SET CMP0017 NEW) #this line has to appear before 'PROJECT' in order to be able to disable incremental linking -@@ -489,7 +489,14 @@ IF (BUILD_UNIT_TESTS) +@@ -489,24 +489,33 @@ IF (BUILD_UNIT_TESTS) SUBDIRS(test) ENDIF() @@ -58,17 +58,19 @@ index a695b71..607edde 100644 + +set (BULLET_CONFIG_CMAKE_PATH share/bullet ) list (APPEND BULLET_DEFINITIONS ${BULLET_DOUBLE_DEF}) - list (APPEND BULLET_LIBRARIES LinearMath) +-list (APPEND BULLET_LIBRARIES LinearMath) list (APPEND BULLET_LIBRARIES Bullet3Common) -@@ -497,16 +504,18 @@ list (APPEND BULLET_LIBRARIES BulletInverseDynamics) - list (APPEND BULLET_LIBRARIES BulletCollision) + list (APPEND BULLET_LIBRARIES BulletInverseDynamics) +-list (APPEND BULLET_LIBRARIES BulletCollision) list (APPEND BULLET_LIBRARIES BulletDynamics) ++list (APPEND BULLET_LIBRARIES BulletCollision) list (APPEND BULLET_LIBRARIES BulletSoftBody) -set (BULLET_USE_FILE ${BULLET_CONFIG_CMAKE_PATH}/UseBullet.cmake) -configure_file ( ${CMAKE_CURRENT_SOURCE_DIR}/BulletConfig.cmake.in - ${CMAKE_CURRENT_BINARY_DIR}/BulletConfig.cmake - @ONLY ESCAPE_QUOTES - ) ++list (APPEND BULLET_LIBRARIES LinearMath) +configure_package_config_file( + ${CMAKE_CURRENT_SOURCE_DIR}/BulletConfig.cmake.in + ${CMAKE_CURRENT_BINARY_DIR}/BulletConfig.cmake diff --git a/ports/bullet3/portfile.cmake b/ports/bullet3/portfile.cmake index 685d44da1d..81053e1f3c 100644 --- a/ports/bullet3/portfile.cmake +++ b/ports/bullet3/portfile.cmake @@ -1,9 +1,10 @@ vcpkg_check_linkage(ONLY_STATIC_LIBRARY) +vcpkg_minimum_required(VERSION 2022-10-12) # for ${VERSION} vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO bulletphysics/bullet3 - REF 3.22 + REF "${VERSION}" SHA512 edacf643ca9621523812effe69a7499716bc65282c58c1f5b4eb4f17b2b1ab55a4f71b06a73483f57e57a5b032c234d09ba5fab9881321f2cbc3c27b43fdc95d HEAD_REF master PATCHES @@ -19,7 +20,7 @@ vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS ) vcpkg_cmake_configure( - SOURCE_PATH ${SOURCE_PATH} + SOURCE_PATH "${SOURCE_PATH}" OPTIONS -DUSE_MSVC_RUNTIME_LIBRARY_DLL=ON -DBUILD_CPU_DEMOS=OFF @@ -46,4 +47,5 @@ file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share") file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include") file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/include/bullet/BulletInverseDynamics/details") -file(INSTALL "${SOURCE_PATH}/LICENSE.txt" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright) +file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}") +vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE.txt") diff --git a/ports/bullet3/usage b/ports/bullet3/usage index 43b6d667a3..fde1ec3564 100644 --- a/ports/bullet3/usage +++ b/ports/bullet3/usage @@ -1,4 +1,4 @@ -The package bullet3 provides CMake targets: +Bullet3 provides CMake targets: -find_package(Bullet CONFIG REQUIRED) -target_link_libraries(main PRIVATE LinearMath Bullet3Common BulletDynamics BulletSoftBody) + find_package(Bullet CONFIG REQUIRED) + target_link_libraries(main PRIVATE ${BULLET_LIBRARIES}) diff --git a/ports/bullet3/vcpkg.json b/ports/bullet3/vcpkg.json index d9a5b050fa..a1cfcbb322 100644 --- a/ports/bullet3/vcpkg.json +++ b/ports/bullet3/vcpkg.json @@ -1,7 +1,7 @@ { "name": "bullet3", "version": "3.22", - "port-version": 1, + "port-version": 2, "description": "Bullet Physics is a professional collision detection, rigid body, and soft body dynamics library", "homepage": "https://github.com/bulletphysics/bullet3", "license": "Zlib", diff --git a/versions/b-/bullet3.json b/versions/b-/bullet3.json index 96aed05e6a..00607c2c59 100644 --- a/versions/b-/bullet3.json +++ b/versions/b-/bullet3.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "fa19f46a232f321eca98906bc2b25dbf782b924b", + "version": "3.22", + "port-version": 2 + }, { "git-tree": "0f5ea7c8c35304edd8b2eadb5b60b7300a97b772", "version": "3.22", diff --git a/versions/baseline.json b/versions/baseline.json index 2fd1846449..e9ba6c23ce 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -1222,7 +1222,7 @@ }, "bullet3": { "baseline": "3.22", - "port-version": 1 + "port-version": 2 }, "bustache": { "baseline": "1.1.0",