early-access version 2853
This commit is contained in:
96
externals/vcpkg/ports/matplotplusplus/fix-dependencies.patch
vendored
Executable file
96
externals/vcpkg/ports/matplotplusplus/fix-dependencies.patch
vendored
Executable file
@@ -0,0 +1,96 @@
|
||||
diff --git a/source/3rd_party/CMakeLists.txt b/source/3rd_party/CMakeLists.txt
|
||||
index ab58bbd..f9fed7e 100644
|
||||
--- a/source/3rd_party/CMakeLists.txt
|
||||
+++ b/source/3rd_party/CMakeLists.txt
|
||||
@@ -67,57 +67,69 @@ find_package(PkgConfig)
|
||||
# Lots of optional packages are not a good idea in general.
|
||||
# It makes the library much less "packagable" (https://youtu.be/sBP17HQAQjk)
|
||||
# and much more difficult to make sure it works on multiple OSs
|
||||
-find_package(JPEG)
|
||||
-if(JPEG_FOUND)
|
||||
+
|
||||
+if (WITH_JPEG)
|
||||
+find_package(JPEG REQUIRED)
|
||||
+if(1)
|
||||
target_compile_definitions(cimg INTERFACE cimg_use_jpeg)
|
||||
target_link_libraries(cimg INTERFACE ${JPEG_LIBRARIES})
|
||||
target_include_directories(cimg INTERFACE ${JPEG_INCLUDE_DIRS})
|
||||
endif()
|
||||
+endif()
|
||||
|
||||
-find_package(TIFF)
|
||||
-if(TIFF_FOUND)
|
||||
+if (WITH_TIFF)
|
||||
+find_package(TIFF REQUIRED)
|
||||
+if(1)
|
||||
target_compile_definitions(cimg INTERFACE cimg_use_tiff)
|
||||
target_link_libraries(cimg INTERFACE ${TIFF_LIBRARIES})
|
||||
target_include_directories(cimg INTERFACE ${TIFF_INCLUDE_DIRS})
|
||||
endif()
|
||||
+endif()
|
||||
|
||||
-find_package(ZLIB)
|
||||
-if(ZLIB_FOUND)
|
||||
- find_package(PNG)
|
||||
- if (PNG_FOUND)
|
||||
+if (WITH_ZLIB)
|
||||
+find_package(ZLIB REQUIRED)
|
||||
+if(1)
|
||||
+ find_package(libpng CONFIG REQUIRED)
|
||||
+ if (1)
|
||||
target_compile_definitions(cimg INTERFACE cimg_use_zlib cimg_use_png)
|
||||
- target_include_directories(cimg INTERFACE ${ZLIB_INCLUDE_DIRS} ${PNG_INCLUDE_DIRS})
|
||||
- target_link_libraries(cimg INTERFACE ${ZLIB_LIBRARIES} ${PNG_LIBRARIES})
|
||||
+ target_link_libraries(cimg INTERFACE ZLIB::ZLIB png)
|
||||
endif ()
|
||||
endif()
|
||||
+endif()
|
||||
|
||||
-find_package(LAPACK)
|
||||
-if(LAPACK_FOUND)
|
||||
+if (WITH_LAPACK)
|
||||
+find_package(LAPACK REQUIRED)
|
||||
+if(1)
|
||||
target_compile_definitions(cimg INTERFACE cimg_use_lapack)
|
||||
target_link_libraries(cimg INTERFACE ${LAPACK_LIBRARIES})
|
||||
target_include_directories(cimg INTERFACE ${LAPACK_INCLUDE_DIRS})
|
||||
endif()
|
||||
+endif()
|
||||
|
||||
-find_package(BLAS)
|
||||
-if(BLAS_FOUND)
|
||||
+if (WITH_BLAS)
|
||||
+find_package(BLAS REQUIRED)
|
||||
+if(1)
|
||||
target_compile_definitions(cimg INTERFACE cimg_use_blas)
|
||||
target_link_libraries(cimg INTERFACE ${BLAS_LIBRARIES})
|
||||
target_include_directories(cimg INTERFACE ${BLAS_INCLUDE_DIRS})
|
||||
endif()
|
||||
+endif()
|
||||
|
||||
-find_package(FFTW)
|
||||
-if(FFTW_FOUND)
|
||||
+if (WITH_FFTW3)
|
||||
+find_package(FFTW3 CONFIG REQUIRED)
|
||||
+if(1)
|
||||
target_compile_definitions(cimg INTERFACE cimg_use_fftw3)
|
||||
- target_link_libraries(cimg INTERFACE ${FFTW_LIBRARIES})
|
||||
- target_include_directories(cimg INTERFACE ${FFTW_INCLUDE_DIRS})
|
||||
+ target_link_libraries(cimg INTERFACE FFTW3::fftw3)
|
||||
+endif()
|
||||
endif()
|
||||
|
||||
if (CMAKE_MODULE_PATH)
|
||||
- find_package(OpenCV QUIET)
|
||||
- if (OpenCV_FOUND)
|
||||
+ if (WITH_OPENCV)
|
||||
+ find_package(OpenCV CONFIG REQUIRED)
|
||||
+ if (1)
|
||||
target_compile_definitions(cimg INTERFACE cimg_use_opencv)
|
||||
- target_link_libraries(cimg INTERFACE ${OpenCV_LIBRARIES})
|
||||
- target_include_directories(cimg INTERFACE ${OpenCV_INCLUDE_DIRS})
|
||||
+ target_link_libraries(cimg INTERFACE opencv_core)
|
||||
+ endif()
|
||||
endif()
|
||||
else()
|
||||
message("No CMAKE_MODULE_PATH path for OpenCV configured")
|
15
externals/vcpkg/ports/matplotplusplus/install-3rd-libraries.patch
vendored
Executable file
15
externals/vcpkg/ports/matplotplusplus/install-3rd-libraries.patch
vendored
Executable file
@@ -0,0 +1,15 @@
|
||||
diff --git a/source/3rd_party/CMakeLists.txt b/source/3rd_party/CMakeLists.txt
|
||||
index bef0c08..e7521a7 100644
|
||||
--- a/source/3rd_party/CMakeLists.txt
|
||||
+++ b/source/3rd_party/CMakeLists.txt
|
||||
@@ -41,7 +41,9 @@ endif()
|
||||
if(MASTER_PROJECT AND NOT BUILD_SHARED_LIBS)
|
||||
install(TARGETS nodesoup
|
||||
EXPORT Matplot++Targets
|
||||
- ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/Matplot++)
|
||||
+ RUNTIME DESTINATION bin
|
||||
+ LIBRARY DESTINATION lib
|
||||
+ ARCHIVE DESTINATION lib)
|
||||
endif()
|
||||
|
||||
|
54
externals/vcpkg/ports/matplotplusplus/portfile.cmake
vendored
Executable file
54
externals/vcpkg/ports/matplotplusplus/portfile.cmake
vendored
Executable file
@@ -0,0 +1,54 @@
|
||||
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
|
||||
PATCHES
|
||||
install-3rd-libraries.patch # Remove this patch when nodesoup is added in vcpkg
|
||||
fix-dependencies.patch
|
||||
)
|
||||
|
||||
vcpkg_check_features(
|
||||
OUT_FEATURE_OPTIONS FEATURE_OPTIONS
|
||||
FEATURES
|
||||
opengl BUILD_EXPERIMENTAL_OPENGL_BACKEND
|
||||
jpeg WITH_JPEG
|
||||
tiff WITH_TIFF
|
||||
zlib WITH_ZLIB
|
||||
lapack WITH_LAPACK
|
||||
blas WITH_BLAS
|
||||
fftw3 WITH_FFTW3
|
||||
opencv WITH_OPENCV
|
||||
)
|
||||
|
||||
vcpkg_cmake_configure(
|
||||
SOURCE_PATH "${SOURCE_PATH}"
|
||||
OPTIONS ${FEATURE_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
|
||||
-DBUILD_HIGH_RESOLUTION_WORLD_MAP=${BUILD_WORLD_MAP}
|
||||
)
|
||||
|
||||
vcpkg_cmake_install()
|
||||
|
||||
vcpkg_copy_pdbs()
|
||||
|
||||
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)
|
67
externals/vcpkg/ports/matplotplusplus/vcpkg.json
vendored
Executable file
67
externals/vcpkg/ports/matplotplusplus/vcpkg.json
vendored
Executable file
@@ -0,0 +1,67 @@
|
||||
{
|
||||
"name": "matplotplusplus",
|
||||
"version-date": "2021-04-11",
|
||||
"port-version": 6,
|
||||
"description": "A C++ graphics library for data visualization",
|
||||
"homepage": "https://alandefreitas.github.io/matplotplusplus/",
|
||||
"license": "MIT",
|
||||
"supports": "!uwp & !(windows & arm)",
|
||||
"dependencies": [
|
||||
"cimg",
|
||||
{
|
||||
"name": "vcpkg-cmake",
|
||||
"host": true
|
||||
},
|
||||
{
|
||||
"name": "vcpkg-cmake-config",
|
||||
"host": true
|
||||
}
|
||||
],
|
||||
"features": {
|
||||
"blas": {
|
||||
"description": "BLAS support for Matplot++",
|
||||
"dependencies": [
|
||||
"blas"
|
||||
]
|
||||
},
|
||||
"fftw": {
|
||||
"description": "fftw3 support for Matplot++",
|
||||
"dependencies": [
|
||||
"fftw3"
|
||||
]
|
||||
},
|
||||
"jpeg": {
|
||||
"description": "JPEG support for Matplot++",
|
||||
"dependencies": [
|
||||
"libjpeg-turbo"
|
||||
]
|
||||
},
|
||||
"lapack": {
|
||||
"description": "LAPACK support for Matplot++",
|
||||
"dependencies": [
|
||||
"lapack"
|
||||
]
|
||||
},
|
||||
"opencv": {
|
||||
"description": "opencv support for Matplot++",
|
||||
"dependencies": [
|
||||
"opencv"
|
||||
]
|
||||
},
|
||||
"opengl": {
|
||||
"description": "OpenGL backend for Matplot++",
|
||||
"dependencies": [
|
||||
"glad",
|
||||
"glfw3",
|
||||
"opengl"
|
||||
]
|
||||
},
|
||||
"zlib": {
|
||||
"description": "ZLIB and libpng support for Matplot++",
|
||||
"dependencies": [
|
||||
"libpng",
|
||||
"zlib"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user