diff options
| -rw-r--r-- | ports/lerc/CONTROL | 4 | ||||
| -rw-r--r-- | ports/lerc/enable_static_build.patch | 16 | ||||
| -rw-r--r-- | ports/lerc/install_lib_to_archive_path.patch | 16 | ||||
| -rw-r--r-- | ports/lerc/portfile.cmake | 22 |
4 files changed, 58 insertions, 0 deletions
diff --git a/ports/lerc/CONTROL b/ports/lerc/CONTROL new file mode 100644 index 000000000..54f928539 --- /dev/null +++ b/ports/lerc/CONTROL @@ -0,0 +1,4 @@ +Source: lerc
+Version: 2.2
+Homepage: https://github.com/Esri/lerc
+Description: An open-source image or raster format which supports rapid encoding and decoding for any pixel type
diff --git a/ports/lerc/enable_static_build.patch b/ports/lerc/enable_static_build.patch new file mode 100644 index 000000000..92f0d7852 --- /dev/null +++ b/ports/lerc/enable_static_build.patch @@ -0,0 +1,16 @@ + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index d22ad11..e90fcdd 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -12,7 +12,7 @@ file(GLOB SOURCES + ) + message(${SOURCES}) + +-add_library(LercLib SHARED ${SOURCES}) ++add_library(LercLib ${SOURCES}) + + target_link_libraries (LercLib) + diff --git a/ports/lerc/install_lib_to_archive_path.patch b/ports/lerc/install_lib_to_archive_path.patch new file mode 100644 index 000000000..3262a7ca5 --- /dev/null +++ b/ports/lerc/install_lib_to_archive_path.patch @@ -0,0 +1,16 @@ + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index ececeed..d22ad11 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -20,7 +20,7 @@ install( + TARGETS LercLib + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} +- ARCHIVE DESTINATION ${CMAKE_INSTALL_BINDIR} ++ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} + ) + diff --git a/ports/lerc/portfile.cmake b/ports/lerc/portfile.cmake new file mode 100644 index 000000000..44695d79f --- /dev/null +++ b/ports/lerc/portfile.cmake @@ -0,0 +1,22 @@ +vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO Esri/lerc
+ REF v2.2
+ SHA512 5ddf1e8f0c123d3c1329e980021e25e6ff9b79c96588115e5b48ba7637f0b2bf3ebb2ab6ebf94cfbde45ea1521f14405f669e23f0b74d9ae8f9b2cf80a908215
+ HEAD_REF master
+ PATCHES
+ "install_lib_to_archive_path.patch"
+ "enable_static_build.patch"
+)
+
+vcpkg_configure_cmake(
+ SOURCE_PATH ${SOURCE_PATH}
+ PREFER_NINJA
+)
+
+vcpkg_install_cmake()
+
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
+
+file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
+
|
