[bullet3] Fix wrong target_link_libraries printed (#28214)

* [bullet3] Fix wrong target_link_libraries printed

* x-add-version

* update patch

* x-add-version
This commit is contained in:
Lily Wang 2022-12-08 15:23:12 -08:00 committed by GitHub
parent 3211a42c6c
commit 4a2a09b905
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 22 additions and 13 deletions

View File

@ -35,7 +35,7 @@ index f5dc7bd..50b3d67 100644
+ set(_DIR) + set(_DIR)
+endif() +endif()
diff --git a/CMakeLists.txt b/CMakeLists.txt diff --git a/CMakeLists.txt b/CMakeLists.txt
index a695b71..607edde 100644 index a695b71..f98cf4d 100644
--- a/CMakeLists.txt --- a/CMakeLists.txt
+++ b/CMakeLists.txt +++ b/CMakeLists.txt
@@ -1,4 +1,4 @@ @@ -1,4 +1,4 @@
@ -44,7 +44,7 @@ index a695b71..607edde 100644
set(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS true) set(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS true)
cmake_policy(SET CMP0017 NEW) cmake_policy(SET CMP0017 NEW)
#this line has to appear before 'PROJECT' in order to be able to disable incremental linking #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) SUBDIRS(test)
ENDIF() ENDIF()
@ -58,17 +58,19 @@ index a695b71..607edde 100644
+ +
+set (BULLET_CONFIG_CMAKE_PATH share/bullet ) +set (BULLET_CONFIG_CMAKE_PATH share/bullet )
list (APPEND BULLET_DEFINITIONS ${BULLET_DOUBLE_DEF}) list (APPEND BULLET_DEFINITIONS ${BULLET_DOUBLE_DEF})
list (APPEND BULLET_LIBRARIES LinearMath) -list (APPEND BULLET_LIBRARIES LinearMath)
list (APPEND BULLET_LIBRARIES Bullet3Common) list (APPEND BULLET_LIBRARIES Bullet3Common)
@@ -497,16 +504,18 @@ list (APPEND BULLET_LIBRARIES BulletInverseDynamics) list (APPEND BULLET_LIBRARIES BulletInverseDynamics)
list (APPEND BULLET_LIBRARIES BulletCollision) -list (APPEND BULLET_LIBRARIES BulletCollision)
list (APPEND BULLET_LIBRARIES BulletDynamics) list (APPEND BULLET_LIBRARIES BulletDynamics)
+list (APPEND BULLET_LIBRARIES BulletCollision)
list (APPEND BULLET_LIBRARIES BulletSoftBody) list (APPEND BULLET_LIBRARIES BulletSoftBody)
-set (BULLET_USE_FILE ${BULLET_CONFIG_CMAKE_PATH}/UseBullet.cmake) -set (BULLET_USE_FILE ${BULLET_CONFIG_CMAKE_PATH}/UseBullet.cmake)
-configure_file ( ${CMAKE_CURRENT_SOURCE_DIR}/BulletConfig.cmake.in -configure_file ( ${CMAKE_CURRENT_SOURCE_DIR}/BulletConfig.cmake.in
- ${CMAKE_CURRENT_BINARY_DIR}/BulletConfig.cmake - ${CMAKE_CURRENT_BINARY_DIR}/BulletConfig.cmake
- @ONLY ESCAPE_QUOTES - @ONLY ESCAPE_QUOTES
- ) - )
+list (APPEND BULLET_LIBRARIES LinearMath)
+configure_package_config_file( +configure_package_config_file(
+ ${CMAKE_CURRENT_SOURCE_DIR}/BulletConfig.cmake.in + ${CMAKE_CURRENT_SOURCE_DIR}/BulletConfig.cmake.in
+ ${CMAKE_CURRENT_BINARY_DIR}/BulletConfig.cmake + ${CMAKE_CURRENT_BINARY_DIR}/BulletConfig.cmake

View File

@ -1,9 +1,10 @@
vcpkg_check_linkage(ONLY_STATIC_LIBRARY) vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
vcpkg_minimum_required(VERSION 2022-10-12) # for ${VERSION}
vcpkg_from_github( vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH OUT_SOURCE_PATH SOURCE_PATH
REPO bulletphysics/bullet3 REPO bulletphysics/bullet3
REF 3.22 REF "${VERSION}"
SHA512 edacf643ca9621523812effe69a7499716bc65282c58c1f5b4eb4f17b2b1ab55a4f71b06a73483f57e57a5b032c234d09ba5fab9881321f2cbc3c27b43fdc95d SHA512 edacf643ca9621523812effe69a7499716bc65282c58c1f5b4eb4f17b2b1ab55a4f71b06a73483f57e57a5b032c234d09ba5fab9881321f2cbc3c27b43fdc95d
HEAD_REF master HEAD_REF master
PATCHES PATCHES
@ -19,7 +20,7 @@ vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
) )
vcpkg_cmake_configure( vcpkg_cmake_configure(
SOURCE_PATH ${SOURCE_PATH} SOURCE_PATH "${SOURCE_PATH}"
OPTIONS OPTIONS
-DUSE_MSVC_RUNTIME_LIBRARY_DLL=ON -DUSE_MSVC_RUNTIME_LIBRARY_DLL=ON
-DBUILD_CPU_DEMOS=OFF -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}/debug/include")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/include/bullet/BulletInverseDynamics/details") 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")

View File

@ -1,4 +1,4 @@
The package bullet3 provides CMake targets: Bullet3 provides CMake targets:
find_package(Bullet CONFIG REQUIRED) find_package(Bullet CONFIG REQUIRED)
target_link_libraries(main PRIVATE LinearMath Bullet3Common BulletDynamics BulletSoftBody) target_link_libraries(main PRIVATE ${BULLET_LIBRARIES})

View File

@ -1,7 +1,7 @@
{ {
"name": "bullet3", "name": "bullet3",
"version": "3.22", "version": "3.22",
"port-version": 1, "port-version": 2,
"description": "Bullet Physics is a professional collision detection, rigid body, and soft body dynamics library", "description": "Bullet Physics is a professional collision detection, rigid body, and soft body dynamics library",
"homepage": "https://github.com/bulletphysics/bullet3", "homepage": "https://github.com/bulletphysics/bullet3",
"license": "Zlib", "license": "Zlib",

View File

@ -1,5 +1,10 @@
{ {
"versions": [ "versions": [
{
"git-tree": "fa19f46a232f321eca98906bc2b25dbf782b924b",
"version": "3.22",
"port-version": 2
},
{ {
"git-tree": "0f5ea7c8c35304edd8b2eadb5b60b7300a97b772", "git-tree": "0f5ea7c8c35304edd8b2eadb5b60b7300a97b772",
"version": "3.22", "version": "3.22",

View File

@ -1222,7 +1222,7 @@
}, },
"bullet3": { "bullet3": {
"baseline": "3.22", "baseline": "3.22",
"port-version": 1 "port-version": 2
}, },
"bustache": { "bustache": {
"baseline": "1.1.0", "baseline": "1.1.0",