aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJack·Boos·Yu <47264268+JackBoosY@users.noreply.github.com>2021-09-28 11:57:22 +0800
committerGitHub <noreply@github.com>2021-09-27 20:57:22 -0700
commit878d3514eb247da3cb09db37f4ff3b4c7899d7a6 (patch)
tree9629c033f818108a599c175c59e2a5e931b5864b
parent1ea790bb36e7922f6feb612261d92126a506897e (diff)
downloadvcpkg-878d3514eb247da3cb09db37f4ff3b4c7899d7a6.tar.gz
vcpkg-878d3514eb247da3cb09db37f4ff3b4c7899d7a6.zip
[vtk] fix usage and add the usage file (#20356)
* [vtk] fix usage and add the usage file * version stuff * typo * version * Change qt5-base as a host port * version * Revert 433fe479010215756d26448e345bd874134a9324, push in wrong branch * Replace deprecate functions * version
-rw-r--r--ports/vtk/portfile.cmake14
-rw-r--r--ports/vtk/usage5
-rw-r--r--ports/vtk/vcpkg.json10
-rw-r--r--versions/baseline.json2
-rw-r--r--versions/v-/vtk.json5
5 files changed, 30 insertions, 6 deletions
diff --git a/ports/vtk/portfile.cmake b/ports/vtk/portfile.cmake
index b9af50ad8..adfb0f3a0 100644
--- a/ports/vtk/portfile.cmake
+++ b/ports/vtk/portfile.cmake
@@ -164,9 +164,8 @@ file(COPY "${CURRENT_PORT_DIR}/FindHDF5.cmake" DESTINATION "${SOURCE_PATH}/CMake
# Configure & Install
# We set all libraries to "system" and explicitly list the ones that should use embedded copies
-vcpkg_configure_cmake(
+vcpkg_cmake_configure(
SOURCE_PATH ${SOURCE_PATH}
- PREFER_NINJA
OPTIONS ${FEATURE_OPTIONS}
-DBUILD_TESTING=OFF
-DVTK_BUILD_TESTING=OFF
@@ -185,12 +184,12 @@ vcpkg_configure_cmake(
${ADDITIONAL_OPTIONS}
)
-vcpkg_install_cmake()
+vcpkg_cmake_install()
vcpkg_copy_pdbs()
# =============================================================================
# Fixup target files
-vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake/vtk-9.0)
+vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/vtk-9.0)
# =============================================================================
# Clean-up other directories
@@ -306,6 +305,13 @@ else()
endif()
endforeach()
+# Use vcpkg provided find method
+file(REMOVE "${CURRENT_PACKAGES_DIR}/share/${PORT}/FindEXPAT.cmake")
+
+file(RENAME "${CURRENT_PACKAGES_DIR}/share/licenses" "${CURRENT_PACKAGES_DIR}/share/${PORT}/licenses")
+
# =============================================================================
+# Usage
+configure_file("${CMAKE_CURRENT_LIST_DIR}/usage" "${CURRENT_PACKAGES_DIR}/share/${PORT}/usage" COPYONLY)
# Handle copyright
file(INSTALL "${SOURCE_PATH}/Copyright.txt" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME "copyright")
diff --git a/ports/vtk/usage b/ports/vtk/usage
new file mode 100644
index 000000000..bba2f6390
--- /dev/null
+++ b/ports/vtk/usage
@@ -0,0 +1,5 @@
+The package vtk provides CMake targets:
+
+ find_package(VTK REQUIRED)
+ include("${VTK_USE_FILE}")
+ target_link_libraries(main PRIVATE ${VTK_LIBRARIES})
diff --git a/ports/vtk/vcpkg.json b/ports/vtk/vcpkg.json
index a22785db3..2437c2292 100644
--- a/ports/vtk/vcpkg.json
+++ b/ports/vtk/vcpkg.json
@@ -1,7 +1,7 @@
{
"name": "vtk",
"version-semver": "9.0.3-pv5.9.1",
- "port-version": 1,
+ "port-version": 2,
"description": "Software system for 3D computer graphics, image processing, and visualization",
"homepage": "https://github.com/Kitware/VTK",
"dependencies": [
@@ -35,6 +35,14 @@
"sqlite3",
"tiff",
"utfcpp",
+ {
+ "name": "vcpkg-cmake",
+ "host": true
+ },
+ {
+ "name": "vcpkg-cmake-config",
+ "host": true
+ },
"zlib"
],
"features": {
diff --git a/versions/baseline.json b/versions/baseline.json
index 38f12cf85..9d985fe91 100644
--- a/versions/baseline.json
+++ b/versions/baseline.json
@@ -6886,7 +6886,7 @@
},
"vtk": {
"baseline": "9.0.3-pv5.9.1",
- "port-version": 1
+ "port-version": 2
},
"vtk-dicom": {
"baseline": "0.8.12",
diff --git a/versions/v-/vtk.json b/versions/v-/vtk.json
index 5b6741917..6022f3fef 100644
--- a/versions/v-/vtk.json
+++ b/versions/v-/vtk.json
@@ -1,6 +1,11 @@
{
"versions": [
{
+ "git-tree": "5e50a05b2ff0cc2f4df601ddb146c75a2f266a6a",
+ "version-semver": "9.0.3-pv5.9.1",
+ "port-version": 2
+ },
+ {
"git-tree": "413d7fcbff9b50e57e486d1249c841a5e25c0def",
"version-semver": "9.0.3-pv5.9.1",
"port-version": 1