From e8c9cba0db6bce398a3a15bd228bb0acc11b0201 Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Mon, 25 Nov 2024 20:40:19 +1100 Subject: [PATCH 01/14] manifold port --- ports/manifold/portfile.cmake | 32 ++++++++++++++++++++++++++++++++ ports/manifold/usage | 4 ++++ ports/manifold/vcpkg.json | 19 +++++++++++++++++++ 3 files changed, 55 insertions(+) create mode 100644 ports/manifold/portfile.cmake create mode 100644 ports/manifold/usage create mode 100644 ports/manifold/vcpkg.json diff --git a/ports/manifold/portfile.cmake b/ports/manifold/portfile.cmake new file mode 100644 index 00000000000000..471e79927cc703 --- /dev/null +++ b/ports/manifold/portfile.cmake @@ -0,0 +1,32 @@ +vcpkg_check_linkage(ONLY_DYNAMIC_LIBRARY) + +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO elalish/manifold + REF v3.0.0 + SHA512 881d3b0e3ff03794ce66b09c4a7be675e5dcd5d5b269d62ad5c5de177e76a01460f6f0fb55a2973a92abda3bf32b8a08bafdff5c0b379ae095d9806eb5669022 +) + +# Configure the project +vcpkg_cmake_configure( + SOURCE_PATH ${SOURCE_PATH} + OPTIONS + -DMANIFOLD_DEBUG=OFF + -DMANIFOLD_TEST=OFF # Disable tests to avoid overhead + -DMANIFOLD_CROSS_SECTION=ON # Enable cross-section support + -DMANIFOLD_CBIND=ON # Enable C bindings + -DMANIFOLD_PYBIND=OFF # Enable Python bindings + -DMANIFOLD_JSBIND=OFF # Disable JS bindings + OPTIONS_RELEASE + -DMANIFOLD_DEBUG=OFF + OPTIONS_DEBUG + -DMANIFOLD_DEBUG=ON +) + +# Build and install +vcpkg_cmake_build() +vcpkg_cmake_install() +vcpkg_fixup_pkgconfig() + +file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}") +vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE") diff --git a/ports/manifold/usage b/ports/manifold/usage new file mode 100644 index 00000000000000..7a06df0a797300 --- /dev/null +++ b/ports/manifold/usage @@ -0,0 +1,4 @@ +The package manifold provides CMake targets: + + find_package(manifold CONFIG REQUIRED) + target_link_libraries(main PRIVATE manifold::manifold) diff --git a/ports/manifold/vcpkg.json b/ports/manifold/vcpkg.json new file mode 100644 index 00000000000000..b9a4ec2ec98f61 --- /dev/null +++ b/ports/manifold/vcpkg.json @@ -0,0 +1,19 @@ +{ + "name": "manifold", + "version": "3.0.0", + "description": "Geometry library for topological robustness.", + "homepage": "https://github.com/elalish/manifold", + "license": "Apache-2.0", + "dependencies": [ + "clipper2", + "tbb", + { + "name": "vcpkg-cmake", + "host": true + }, + { + "name": "vcpkg-cmake-config", + "host": true + } + ] +} From 89692e582b8f795f488ede8311706c8e92e5090b Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Mon, 25 Nov 2024 20:40:49 +1100 Subject: [PATCH 02/14] add manifold to version database --- versions/baseline.json | 4 ++++ versions/m-/manifold.json | 9 +++++++++ 2 files changed, 13 insertions(+) create mode 100644 versions/m-/manifold.json diff --git a/versions/baseline.json b/versions/baseline.json index 3b519efe645aae..0aaaf25e1e3e6b 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -5764,6 +5764,10 @@ "baseline": "2023-07-17", "port-version": 0 }, + "manifold": { + "baseline": "3.0.0", + "port-version": 0 + }, "mapbox-geojson-cpp": { "baseline": "0.5.1", "port-version": 1 diff --git a/versions/m-/manifold.json b/versions/m-/manifold.json new file mode 100644 index 00000000000000..69277726c13992 --- /dev/null +++ b/versions/m-/manifold.json @@ -0,0 +1,9 @@ +{ + "versions": [ + { + "git-tree": "37cede1a4497c1a31c1e519d6ca158d324ebc912", + "version": "3.0.0", + "port-version": 0 + } + ] +} From 1354baf50d2e1b0fb9f328430316c4b28400a836 Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Mon, 25 Nov 2024 21:00:53 +1100 Subject: [PATCH 03/14] ignore warnings --- ports/manifold/portfile.cmake | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ports/manifold/portfile.cmake b/ports/manifold/portfile.cmake index 471e79927cc703..bd27a0da23cca7 100644 --- a/ports/manifold/portfile.cmake +++ b/ports/manifold/portfile.cmake @@ -1,3 +1,7 @@ +add set(VCPKG_POLICY_ALLOW_DEBUG_INCLUDE enabled) +set(VCPKG_POLICY_SKIP_MISPLACED_CMAKE_FILES_CHECK enabled) +add set(VCPKG_POLICY_SKIP_LIB_CMAKE_MERGE_CHECK enabled) + vcpkg_check_linkage(ONLY_DYNAMIC_LIBRARY) vcpkg_from_github( From aa4a59512cdc2ddefaa8bdbc5037945ea60cced3 Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Mon, 25 Nov 2024 21:15:24 +1100 Subject: [PATCH 04/14] update version --- versions/m-/manifold.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/versions/m-/manifold.json b/versions/m-/manifold.json index 69277726c13992..4a53699a767dff 100644 --- a/versions/m-/manifold.json +++ b/versions/m-/manifold.json @@ -1,7 +1,7 @@ { "versions": [ { - "git-tree": "37cede1a4497c1a31c1e519d6ca158d324ebc912", + "git-tree": "49bdb037ac1068b043e2102b4a898204c3a59275", "version": "3.0.0", "port-version": 0 } From 3de64dbd2072043d507a0430d30ef51424b8b00c Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Tue, 26 Nov 2024 22:17:42 +1100 Subject: [PATCH 05/14] address comments --- ports/manifold/portfile.cmake | 28 ++++++++++++---------------- ports/manifold/usage | 6 +++--- 2 files changed, 15 insertions(+), 19 deletions(-) diff --git a/ports/manifold/portfile.cmake b/ports/manifold/portfile.cmake index bd27a0da23cca7..b4ddddbea4cea7 100644 --- a/ports/manifold/portfile.cmake +++ b/ports/manifold/portfile.cmake @@ -1,36 +1,32 @@ -add set(VCPKG_POLICY_ALLOW_DEBUG_INCLUDE enabled) -set(VCPKG_POLICY_SKIP_MISPLACED_CMAKE_FILES_CHECK enabled) -add set(VCPKG_POLICY_SKIP_LIB_CMAKE_MERGE_CHECK enabled) - vcpkg_check_linkage(ONLY_DYNAMIC_LIBRARY) vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO elalish/manifold - REF v3.0.0 + REF v${VERSION} SHA512 881d3b0e3ff03794ce66b09c4a7be675e5dcd5d5b269d62ad5c5de177e76a01460f6f0fb55a2973a92abda3bf32b8a08bafdff5c0b379ae095d9806eb5669022 ) -# Configure the project vcpkg_cmake_configure( - SOURCE_PATH ${SOURCE_PATH} + SOURCE_PATH "${SOURCE_PATH}" OPTIONS -DMANIFOLD_DEBUG=OFF - -DMANIFOLD_TEST=OFF # Disable tests to avoid overhead - -DMANIFOLD_CROSS_SECTION=ON # Enable cross-section support - -DMANIFOLD_CBIND=ON # Enable C bindings - -DMANIFOLD_PYBIND=OFF # Enable Python bindings - -DMANIFOLD_JSBIND=OFF # Disable JS bindings + -DMANIFOLD_TEST=OFF + -DMANIFOLD_CROSS_SECTION=ON + -DMANIFOLD_CBIND=ON + -DMANIFOLD_PYBIND=OFF + -DMANIFOLD_JSBIND=OFF OPTIONS_RELEASE -DMANIFOLD_DEBUG=OFF - OPTIONS_DEBUG - -DMANIFOLD_DEBUG=ON ) -# Build and install -vcpkg_cmake_build() vcpkg_cmake_install() +vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/manifold) vcpkg_fixup_pkgconfig() +file(REMOVE_RECURSE + "${CURRENT_PACKAGES_DIR}/debug/include" +) + file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}") vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE") diff --git a/ports/manifold/usage b/ports/manifold/usage index 7a06df0a797300..4187e315af9a25 100644 --- a/ports/manifold/usage +++ b/ports/manifold/usage @@ -1,4 +1,4 @@ -The package manifold provides CMake targets: +manifold provides CMake targets: - find_package(manifold CONFIG REQUIRED) - target_link_libraries(main PRIVATE manifold::manifold) + find_package(manifold CONFIG REQUIRED) + target_link_libraries(main PRIVATE manifold::manifold) \ No newline at end of file From d33c19b059db44018fd8280fee16e7a32023d029 Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Tue, 26 Nov 2024 22:19:14 +1100 Subject: [PATCH 06/14] update manifold version git tree --- versions/m-/manifold.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/versions/m-/manifold.json b/versions/m-/manifold.json index 4a53699a767dff..4dd20b84eb8eda 100644 --- a/versions/m-/manifold.json +++ b/versions/m-/manifold.json @@ -1,7 +1,7 @@ { "versions": [ { - "git-tree": "49bdb037ac1068b043e2102b4a898204c3a59275", + "git-tree": "2264bd7dd273b142157272cb05d5683a1267e24b", "version": "3.0.0", "port-version": 0 } From e5a9e1f5b428108f51cf7cfb5c4df31d4d724810 Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Wed, 27 Nov 2024 11:51:51 +1100 Subject: [PATCH 07/14] remove check for dynamic lib --- ports/manifold/portfile.cmake | 2 -- 1 file changed, 2 deletions(-) diff --git a/ports/manifold/portfile.cmake b/ports/manifold/portfile.cmake index b4ddddbea4cea7..5a886cf57a8271 100644 --- a/ports/manifold/portfile.cmake +++ b/ports/manifold/portfile.cmake @@ -1,5 +1,3 @@ -vcpkg_check_linkage(ONLY_DYNAMIC_LIBRARY) - vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO elalish/manifold From 43bbc470f4a567a0fef6c9df664ef284c39c58a3 Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Wed, 27 Nov 2024 11:52:40 +1100 Subject: [PATCH 08/14] update manifold git tree --- versions/m-/manifold.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/versions/m-/manifold.json b/versions/m-/manifold.json index 4dd20b84eb8eda..991bae7794173b 100644 --- a/versions/m-/manifold.json +++ b/versions/m-/manifold.json @@ -1,7 +1,7 @@ { "versions": [ { - "git-tree": "2264bd7dd273b142157272cb05d5683a1267e24b", + "git-tree": "53b61d07ad8b7eb4d0070a771f5edeef00d02d0b", "version": "3.0.0", "port-version": 0 } From 73b499f4d78fcd0c59da466c8abd3f1ddef3cfff Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Wed, 27 Nov 2024 12:08:56 +1100 Subject: [PATCH 09/14] add manifold debug option --- ports/manifold/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ports/manifold/portfile.cmake b/ports/manifold/portfile.cmake index 5a886cf57a8271..2059b87df62477 100644 --- a/ports/manifold/portfile.cmake +++ b/ports/manifold/portfile.cmake @@ -14,8 +14,8 @@ vcpkg_cmake_configure( -DMANIFOLD_CBIND=ON -DMANIFOLD_PYBIND=OFF -DMANIFOLD_JSBIND=OFF - OPTIONS_RELEASE - -DMANIFOLD_DEBUG=OFF + OPTIONS_DEBUG + -DMANIFOLD_DEBUG=ON ) vcpkg_cmake_install() From 77f3c300c94cbab0abf41bf329c2dbe8c02d1442 Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Wed, 27 Nov 2024 12:09:24 +1100 Subject: [PATCH 10/14] update manifold git tree --- versions/m-/manifold.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/versions/m-/manifold.json b/versions/m-/manifold.json index 991bae7794173b..5b932209fbe324 100644 --- a/versions/m-/manifold.json +++ b/versions/m-/manifold.json @@ -1,7 +1,7 @@ { "versions": [ { - "git-tree": "53b61d07ad8b7eb4d0070a771f5edeef00d02d0b", + "git-tree": "523ed5859a2c37a2130b793fb48bf8fac0dbcc28", "version": "3.0.0", "port-version": 0 } From 1bebd19263a6bc4a72851600132a841ad42c407d Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Wed, 27 Nov 2024 12:39:45 +1100 Subject: [PATCH 11/14] remove debug option from manifold port --- ports/manifold/portfile.cmake | 2 -- 1 file changed, 2 deletions(-) diff --git a/ports/manifold/portfile.cmake b/ports/manifold/portfile.cmake index 2059b87df62477..51ee9bb988e96d 100644 --- a/ports/manifold/portfile.cmake +++ b/ports/manifold/portfile.cmake @@ -14,8 +14,6 @@ vcpkg_cmake_configure( -DMANIFOLD_CBIND=ON -DMANIFOLD_PYBIND=OFF -DMANIFOLD_JSBIND=OFF - OPTIONS_DEBUG - -DMANIFOLD_DEBUG=ON ) vcpkg_cmake_install() From 4ba6d08a1240a6c44aa0b3579dd18db515eecd25 Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Wed, 27 Nov 2024 12:40:18 +1100 Subject: [PATCH 12/14] update manifold version git tree --- versions/m-/manifold.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/versions/m-/manifold.json b/versions/m-/manifold.json index 5b932209fbe324..82c4283d8689a2 100644 --- a/versions/m-/manifold.json +++ b/versions/m-/manifold.json @@ -1,7 +1,7 @@ { "versions": [ { - "git-tree": "523ed5859a2c37a2130b793fb48bf8fac0dbcc28", + "git-tree": "ef3de50dc5aae8c34ad0eb1a95a4934678958d93", "version": "3.0.0", "port-version": 0 } From 27484f85211c7c4fec37c824b0054a424b0ca501 Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Wed, 27 Nov 2024 19:06:23 +1100 Subject: [PATCH 13/14] remove unused lines in manifold port --- ports/manifold/portfile.cmake | 1 - ports/manifold/usage | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/ports/manifold/portfile.cmake b/ports/manifold/portfile.cmake index 51ee9bb988e96d..5091fe1dad8349 100644 --- a/ports/manifold/portfile.cmake +++ b/ports/manifold/portfile.cmake @@ -8,7 +8,6 @@ vcpkg_from_github( vcpkg_cmake_configure( SOURCE_PATH "${SOURCE_PATH}" OPTIONS - -DMANIFOLD_DEBUG=OFF -DMANIFOLD_TEST=OFF -DMANIFOLD_CROSS_SECTION=ON -DMANIFOLD_CBIND=ON diff --git a/ports/manifold/usage b/ports/manifold/usage index 4187e315af9a25..401910838ba742 100644 --- a/ports/manifold/usage +++ b/ports/manifold/usage @@ -1,4 +1,4 @@ manifold provides CMake targets: find_package(manifold CONFIG REQUIRED) - target_link_libraries(main PRIVATE manifold::manifold) \ No newline at end of file + target_link_libraries(main PRIVATE manifold::manifold) From b497d441c7efea2b5ee947178867bc39152d2469 Mon Sep 17 00:00:00 2001 From: Jeffrey Wardman Date: Wed, 27 Nov 2024 19:07:01 +1100 Subject: [PATCH 14/14] update manifold version git tree --- versions/m-/manifold.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/versions/m-/manifold.json b/versions/m-/manifold.json index 82c4283d8689a2..a674995ae1032a 100644 --- a/versions/m-/manifold.json +++ b/versions/m-/manifold.json @@ -1,7 +1,7 @@ { "versions": [ { - "git-tree": "ef3de50dc5aae8c34ad0eb1a95a4934678958d93", + "git-tree": "d3885feb3202f23105c65b533abbfe05c42850ec", "version": "3.0.0", "port-version": 0 }