diff options
| author | Victor Romero <romerosanchezv@gmail.com> | 2019-01-23 16:27:52 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-01-23 16:27:52 -0800 |
| commit | 69892980b25309b537eedb6be20c8872ca559751 (patch) | |
| tree | baac32219b2f98341708ed4b69fe54d908a3310b | |
| parent | c292cdcc456d2dbea68e1b5140df81e343c7d8ef (diff) | |
| parent | 10d5e84b0135b07f9665418aebb42bc44ab2c7ca (diff) | |
| download | vcpkg-69892980b25309b537eedb6be20c8872ca559751.tar.gz vcpkg-69892980b25309b537eedb6be20c8872ca559751.zip | |
Merge pull request #5206 from Simverge/pdalc
[pdal-c] Add pdal-c port files
| -rw-r--r-- | ports/pdal-c/CONTROL | 4 | ||||
| -rw-r--r-- | ports/pdal-c/fix-docs-version.patch | 14 | ||||
| -rw-r--r-- | ports/pdal-c/portfile.cmake | 38 | ||||
| -rw-r--r-- | ports/pdal-c/preserve-install-dir.patch | 13 | ||||
| -rw-r--r-- | ports/pdal-c/remove-tests.patch | 12 |
5 files changed, 81 insertions, 0 deletions
diff --git a/ports/pdal-c/CONTROL b/ports/pdal-c/CONTROL new file mode 100644 index 000000000..2a52378b5 --- /dev/null +++ b/ports/pdal-c/CONTROL @@ -0,0 +1,4 @@ +Source: pdal-c +Version: 1.8-1 +Description: C API for the Point Data Abstraction Library (PDAL) +Build-Depends: pdal diff --git a/ports/pdal-c/fix-docs-version.patch b/ports/pdal-c/fix-docs-version.patch new file mode 100644 index 000000000..d44b50b61 --- /dev/null +++ b/ports/pdal-c/fix-docs-version.patch @@ -0,0 +1,14 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 1fbc4a4..c8a325a 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -23,7 +23,8 @@ set(CMAKE_RELWITHDEBINFO_POSTFIX "" CACHE STRING "CMake RelWithDebInfo suffix") + set(PDALC_ENABLE_CODE_COVERAGE ON CACHE BOOL "Enable code coverage calculation") + set(PDALC_GCC_PARAM_GGC_MIN_HEAPSIZE "131072" CACHE STRING "GCC garbage collection minimum heap size") + +-include(ObtainProjectVersion) ++set(${PROJECT_NAME}_VERSION "1.8") ++set(BUILD_ID "vcpkg build") + include_directories("${CMAKE_SOURCE_DIR}/source") + + if(CMAKE_COMPILER_IS_GNUCXX) diff --git a/ports/pdal-c/portfile.cmake b/ports/pdal-c/portfile.cmake new file mode 100644 index 000000000..8a478c547 --- /dev/null +++ b/ports/pdal-c/portfile.cmake @@ -0,0 +1,38 @@ +# vcpkg portfile.cmake for pdal-c, the C API for PDAL + +include(vcpkg_common_functions) +if (VCPKG_LIBRARY_LINKAGE STREQUAL static) + message(STATUS "Warning: Static building will not support load data through plugins.") + set(VCPKG_LIBRARY_LINKAGE dynamic) +endif() + +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO PDAL/CAPI + REF 1.8 + SHA512 6a5f4cb3d36b419f3cd195028c3e6dc17abf3cdb7495aa3df638bc1f842ba98243c73e051e9cfcd3afe22787309cb871374b152ded92e6e06f404cd7b1ae50bf + HEAD_REF master + PATCHES + ${CMAKE_CURRENT_LIST_DIR}/fix-docs-version.patch + ${CMAKE_CURRENT_LIST_DIR}/preserve-install-dir.patch + ${CMAKE_CURRENT_LIST_DIR}/remove-tests.patch +) + +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} + PREFER_NINJA + OPTIONS + -DPDALC_ENABLE_CODE_COVERAGE:BOOL=OFF +) + +vcpkg_install_cmake() +vcpkg_copy_pdbs() + +# Remove headers from debug +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) + +# Install copyright +file(INSTALL ${SOURCE_PATH}/LICENSE.md + DESTINATION ${CURRENT_PACKAGES_DIR}/share/pdal-c + RENAME copyright +) diff --git a/ports/pdal-c/preserve-install-dir.patch b/ports/pdal-c/preserve-install-dir.patch new file mode 100644 index 000000000..87377ab2f --- /dev/null +++ b/ports/pdal-c/preserve-install-dir.patch @@ -0,0 +1,13 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 1fbc4a4..075c86c 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -13,8 +13,6 @@ set(CMAKE_CXX_STANDARD 11) + set(CMAKE_CXX_STANDARD_REQUIRED ON) + set(CMAKE_CXX_EXTENSIONS OFF) + +-# Install to the build directory +-set(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}" CACHE STRING "CMake install prefix" FORCE) + + # Use "d" suffix for debug builds + # Do not use a suffix for RelWithDebInfo diff --git a/ports/pdal-c/remove-tests.patch b/ports/pdal-c/remove-tests.patch new file mode 100644 index 000000000..c50914e57 --- /dev/null +++ b/ports/pdal-c/remove-tests.patch @@ -0,0 +1,12 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 1fbc4a4..e31e552 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -44,7 +44,3 @@ endif() + + add_subdirectory("source/pdal") + add_subdirectory("doc") +- +-include(CTest) +-add_subdirectory("tests/data") +-add_subdirectory("tests/pdal") |
