2020-10-14 05:38:05 +08:00
|
|
|
vcpkg_from_github(
|
2018-10-22 19:16:02 +08:00
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
2020-10-14 05:38:05 +08:00
|
|
|
REPO OSGeo/libgeotiff
|
2021-11-11 06:54:19 +08:00
|
|
|
REF 7da5bacae7814c65ebb78f0b64e1141fbcb3de1e #v1.7.0
|
|
|
|
SHA512 36047778fbbb4a533a7b65e7b32ab8c0955f59b95417b68b68e7ddd398191445e730e00271756213bf657cbf7cd5eb028b25d4b0741e5b309c78c207b4ec01c6
|
2020-10-14 05:38:05 +08:00
|
|
|
HEAD_REF master
|
2018-10-22 19:16:02 +08:00
|
|
|
PATCHES
|
2019-05-29 07:58:00 +08:00
|
|
|
cmakelists.patch
|
2019-05-25 06:11:42 +08:00
|
|
|
geotiff-config.patch
|
2020-10-14 05:38:05 +08:00
|
|
|
fix-staticbuild.patch
|
2021-11-11 06:54:19 +08:00
|
|
|
skip-doc-install.patch
|
2018-02-16 12:29:27 +08:00
|
|
|
)
|
2018-02-09 06:15:21 +08:00
|
|
|
|
2021-11-11 06:54:19 +08:00
|
|
|
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
|
|
|
|
FEATURES
|
|
|
|
tools WITH_JPEG
|
|
|
|
tools WITH_UTILITIES
|
|
|
|
)
|
2019-01-23 17:35:53 +08:00
|
|
|
|
2021-11-11 06:54:19 +08:00
|
|
|
vcpkg_cmake_configure(
|
|
|
|
SOURCE_PATH "${SOURCE_PATH}/libgeotiff"
|
2018-08-03 15:14:51 +08:00
|
|
|
OPTIONS
|
2021-04-13 02:14:09 +08:00
|
|
|
-DGEOTIFF_BIN_SUBDIR=bin
|
|
|
|
-DGEOTIFF_DATA_SUBDIR=share
|
2019-10-18 08:15:52 +08:00
|
|
|
-DWITH_TIFF=1
|
2021-11-11 06:54:19 +08:00
|
|
|
-DHAVE_TIFFOPEN=1
|
|
|
|
-DHAVE_TIFFMERGEFIELDINFO=1
|
2021-07-27 02:10:39 +08:00
|
|
|
-DCMAKE_MACOSX_BUNDLE=0
|
2021-11-11 06:54:19 +08:00
|
|
|
${FEATURE_OPTIONS}
|
2018-02-08 22:13:38 +08:00
|
|
|
)
|
|
|
|
|
2021-11-11 06:54:19 +08:00
|
|
|
vcpkg_cmake_install()
|
2018-02-08 22:13:38 +08:00
|
|
|
|
2021-11-11 06:54:19 +08:00
|
|
|
if(WITH_UTILITIES)
|
|
|
|
vcpkg_copy_tools(TOOL_NAMES applygeo geotifcp listgeo makegeo AUTO_CLEAN)
|
|
|
|
endif()
|
2018-02-09 12:39:22 +08:00
|
|
|
|
2020-10-14 05:38:05 +08:00
|
|
|
vcpkg_copy_pdbs()
|
2021-11-11 06:54:19 +08:00
|
|
|
vcpkg_cmake_config_fixup(PACKAGE_NAME GeoTIFF)
|
2018-02-17 19:14:58 +08:00
|
|
|
|
2019-05-29 07:58:00 +08:00
|
|
|
if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
|
2021-11-11 06:54:19 +08:00
|
|
|
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/share/GeoTIFF/geotiff-config.cmake" "if (GeoTIFF_USE_STATIC_LIBS)" "if (1)")
|
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/bin" "${CURRENT_PACKAGES_DIR}/bin")
|
2018-02-17 19:14:58 +08:00
|
|
|
endif()
|
2018-08-03 15:14:51 +08:00
|
|
|
|
2021-11-11 06:54:19 +08:00
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include" "${CURRENT_PACKAGES_DIR}/debug/share")
|
2019-05-29 07:58:00 +08:00
|
|
|
|
2021-11-11 06:54:19 +08:00
|
|
|
file(INSTALL "${SOURCE_PATH}/libgeotiff/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|