aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormyd7349 <myd7349@gmail.com>2021-04-20 08:17:38 +0800
committerGitHub <noreply@github.com>2021-04-19 17:17:38 -0700
commitdd2255ee31c726945c4fc91c6c6f4b2cb10cc91a (patch)
tree976e3ce0aeaa800c9e93be33645579a147456aa0
parent66ce4e9277f113bda4a83e76a9c612deddc7634c (diff)
downloadvcpkg-dd2255ee31c726945c4fc91c6c6f4b2cb10cc91a.tar.gz
vcpkg-dd2255ee31c726945c4fc91c6c6f4b2cb10cc91a.zip
[matplotplusplus] Add new port (#13725)
* [matplotplusplus] Add new port * [matplotplusplus] Update tips * [matplotplusplus] Update to fix opengl backend * [matplotplusplus] Update to lastest * [matplotplusplus] Update to 2021-03-07 * [matplotplusplus] Add FEATURES keyword * [matplotplusplus] Modernize * [matplotplusplus] Fix mistake * [matplotplusplus] UWP not supported * [matplotplusplus] Format manifest * [matplotplusplus] Add version file * [matplotplusplus] Experimental filesystem support * [matplotplusplus] Overwrite version * [matplotplusplus] Do not support arm64-windows yet * [matplotplusplus] Update to 2021-04-11 * [matplotplusplus] vcpkg x-add-version --overwrite-version matplotplusplus * [matplotplusplus] Modernize * [matplotplusplus] Overwrite version * [matplotplusplus] Fixup cmake targets * [matplotplusplus] Overwrite version * [matplotplusplus] Modernize * [matplotplusplus] Overwrite version
-rw-r--r--ports/matplotplusplus/portfile.cmake49
-rw-r--r--ports/matplotplusplus/vcpkg.json29
-rw-r--r--versions/baseline.json4
-rw-r--r--versions/m-/matplotplusplus.json9
4 files changed, 91 insertions, 0 deletions
diff --git a/ports/matplotplusplus/portfile.cmake b/ports/matplotplusplus/portfile.cmake
new file mode 100644
index 000000000..22ef026e0
--- /dev/null
+++ b/ports/matplotplusplus/portfile.cmake
@@ -0,0 +1,49 @@
+message(STATUS " ${PORT}'s gnuplot backend currently requires Gnuplot 5.2.6+.
+ Windows users may get a pre-built binary installer from http://www.gnuplot.info/download.html.
+ Linux and MacOS users may install it from the system package manager.
+ Please visit https://alandefreitas.github.io/matplotplusplus/ for more information."
+)
+
+vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
+
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO alandefreitas/matplotplusplus
+ REF 36d8dc6c3b94b7a71c4f129763f2c6ad8fc0b54a
+ SHA512 ac8902e953a2a9f6bd62e14e2eb0bd42e407bae6c0b2921ad16ce547e4921ba2c8d8a9cc68e75831676dce3cd89cdf8294862710e838510b68e20f8a6cdf806f
+ HEAD_REF master
+)
+
+vcpkg_check_features(
+ OUT_FEATURE_OPTIONS FEATURE_OPTIONS
+ FEATURES
+ opengl BUILD_EXPERIMENTAL_OPENGL_BACKEND
+)
+
+vcpkg_cmake_configure(
+ SOURCE_PATH ${SOURCE_PATH}
+ OPTIONS
+ -DCPM_USE_LOCAL_PACKAGES=ON
+ -DBUILD_EXAMPLES=OFF
+ -DBUILD_TESTS=OFF
+ -DBUILD_INSTALLER=ON
+ -DBUILD_PACKAGE=OFF
+ -DBUILD_WITH_PEDANTIC_WARNINGS=OFF
+ -DWITH_SYSTEM_CIMG=ON
+ ${FEATURE_OPTIONS}
+)
+
+vcpkg_cmake_install()
+
+# The official documentation says:
+# find_package(Matplot++ ...)
+file(RENAME
+ ${CURRENT_PACKAGES_DIR}/lib/cmake/Matplot++/matplot++-config.cmake
+ ${CURRENT_PACKAGES_DIR}/lib/cmake/Matplot++/Matplot++-config.cmake
+)
+
+vcpkg_cmake_config_fixup(PACKAGE_NAME Matplot++ CONFIG_PATH lib/cmake/Matplot++)
+
+file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include ${CURRENT_PACKAGES_DIR}/debug/share)
+
+file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
diff --git a/ports/matplotplusplus/vcpkg.json b/ports/matplotplusplus/vcpkg.json
new file mode 100644
index 000000000..4830e9353
--- /dev/null
+++ b/ports/matplotplusplus/vcpkg.json
@@ -0,0 +1,29 @@
+{
+ "name": "matplotplusplus",
+ "version-date": "2021-04-11",
+ "description": "A C++ graphics library for data visualization",
+ "homepage": "https://alandefreitas.github.io/matplotplusplus/",
+ "license": "MIT",
+ "supports": "!(arm | uwp)",
+ "dependencies": [
+ "cimg",
+ {
+ "name": "vcpkg-cmake",
+ "host": true
+ },
+ {
+ "name": "vcpkg-cmake-config",
+ "host": true
+ }
+ ],
+ "features": {
+ "opengl": {
+ "description": "OpenGL backend for Matplot++",
+ "dependencies": [
+ "glad",
+ "glfw3",
+ "opengl"
+ ]
+ }
+ }
+}
diff --git a/versions/baseline.json b/versions/baseline.json
index cc6c8e9b7..8cc8753bf 100644
--- a/versions/baseline.json
+++ b/versions/baseline.json
@@ -3844,6 +3844,10 @@
"baseline": "2020-08-27",
"port-version": 0
},
+ "matplotplusplus": {
+ "baseline": "2021-04-11",
+ "port-version": 0
+ },
"matroska": {
"baseline": "1.6.2",
"port-version": 0
diff --git a/versions/m-/matplotplusplus.json b/versions/m-/matplotplusplus.json
new file mode 100644
index 000000000..b163a0b79
--- /dev/null
+++ b/versions/m-/matplotplusplus.json
@@ -0,0 +1,9 @@
+{
+ "versions": [
+ {
+ "git-tree": "e4cf18b9e9c16d294f966bae3d1d89ecd698a47f",
+ "version-date": "2021-04-11",
+ "port-version": 0
+ }
+ ]
+}