Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ports/gdal/vcpkg-cmake-wrapper.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ if(GDAL_FOUND)
if(NOT WIN32)
_gdal_add_dependency(json-c::json-c json-c CONFIG)
endif()
_gdal_add_dependency(geotiff_library geotiff CONFIG)
_gdal_add_dependency(geotiff_library GeoTIFF CONFIG)
_gdal_add_dependency(JPEG::JPEG JPEG)
_gdal_add_dependency(liblzma::liblzma liblzma CONFIG)
_gdal_add_dependency(png libpng CONFIG)
Expand Down
2 changes: 1 addition & 1 deletion ports/gdal/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "gdal",
"version-semver": "3.3.2",
"port-version": 3,
"port-version": 4,
"description": "The Geographic Data Abstraction Library for reading and writing geospatial raster and vector data",
"homepage": "https://gdal.org",
"supports": "!arm",
Expand Down
44 changes: 1 addition & 43 deletions ports/libgeotiff/cmakelists.patch
Original file line number Diff line number Diff line change
@@ -1,49 +1,7 @@
diff --git a/libgeotiff/CMakeLists.txt b/libgeotiff/CMakeLists.txt
index 43113fa..46331ad 100644
--- a/libgeotiff/CMakeLists.txt
+++ b/libgeotiff/CMakeLists.txt
@@ -172,6 +172,7 @@ IF(WITH_TIFF)
endif ()

IF(TIFF_FOUND)
+ IF (0)
# Confirm required API is available
INCLUDE(CheckFunctionExists)
SET(CMAKE_REQUIRED_LIBRARIES ${TIFF_LIBRARIES})
@@ -187,6 +188,7 @@ IF(WITH_TIFF)
SET(TIFF_FOUND) # ReSET to NOT found for TIFF library
MESSAGE(FATAL_ERROR "Failed to link with libtiff - TIFFMergeFieldInfo function not found. libtiff 3.6.0 Beta or later required. Please upgrade or use an older version of libgeotiff")
ENDIF()
+ ENDIF()

INCLUDE_DIRECTORIES(${TIFF_INCLUDE_DIR})
ADD_DEFINITIONS(-DHAVE_TIFF=1)
@@ -298,11 +300,6 @@ INSTALL(FILES ${GEOTIFF_MAN_PAGES} DESTINATION share/man/man1)
# INSTALL(FILES ${GEOTIFF_LIB_HEADERS} DESTINATION ${GEOTIFF_INCLUDE_DIR})
INSTALL(FILES ${GEOTIFF_LIB_HEADERS} DESTINATION include)

-###############################################################################
-# Build libxtiff library
-
-ADD_SUBDIRECTORY(libxtiff)
-
###############################################################################
# Build libgeotiff library

diff --git a/libgeotiff/bin/CMakeLists.txt b/libgeotiff/bin/CMakeLists.txt
index 7b12341..b6b1d0c 100644
--- a/libgeotiff/bin/CMakeLists.txt
+++ b/libgeotiff/bin/CMakeLists.txt
@@ -6,9 +6,6 @@
#
###############################################################################

-INCLUDE_DIRECTORIES(
- .
- ${CMAKE_SOURCE_DIR})

IF(WIN32 AND MSVC)
SET(GETOPT_SOURCE getopt.c)
@@ -22,12 +19,11 @@ MESSAGE(STATUS "Adding GeoTIFF utilities to build")

FOREACH(utility ${GEOTIFF_UTILITIES})
Expand Down Expand Up @@ -75,7 +33,7 @@ index 47a2b00..3809ba3 100644
set (PROJECT_ROOT_DIR "..")
endif ()
+else()
+ set (INSTALL_CMAKE_DIR "share/${PROJECT_NAME_LOWER}")
+ set (INSTALL_CMAKE_DIR "share/${PROJECT_NAME}")
+ set (PROJECT_ROOT_DIR "../..")
+endif()

Expand Down
21 changes: 0 additions & 21 deletions ports/libgeotiff/fix-config-version.patch

This file was deleted.

32 changes: 0 additions & 32 deletions ports/libgeotiff/fix-proj4.patch

This file was deleted.

15 changes: 6 additions & 9 deletions ports/libgeotiff/fix-staticbuild.patch
Original file line number Diff line number Diff line change
@@ -1,19 +1,16 @@
diff --git a/libgeotiff/CMakeLists.txt b/libgeotiff/CMakeLists.txt
index 80fe121..5c1430d 100644
index b4a3cee..fd9f0a5 100644
--- a/libgeotiff/CMakeLists.txt
+++ b/libgeotiff/CMakeLists.txt
@@ -80,8 +80,12 @@ SET(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib)
@@ -80,7 +80,11 @@ SET(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib)

IF(WIN32)
IF(MSVC)
- ADD_DEFINITIONS(-DBUILD_AS_DLL=1)
- ADD_DEFINITIONS(/DW4)
+ IF(BUILD_SHARED_LIBS)
+ ADD_DEFINITIONS(-DBUILD_AS_DLL=1)
ADD_DEFINITIONS(-DBUILD_AS_DLL=1)
+ ELSE()
+ ADD_DEFINITIONS(-DBUILD_AS_DLL=0)
+ ENDIF()
+ ADD_DEFINITIONS(/DW4)
+ ADD_DEFINITIONS(-DBUILD_AS_DLL=0)
+ ENDIF()
ADD_DEFINITIONS(/DW4)
if (NOT (MSVC_VERSION VERSION_LESS 1400))
ADD_DEFINITIONS(-D_CRT_SECURE_NO_DEPRECATE)
ADD_DEFINITIONS(-D_CRT_SECURE_NO_WARNINGS)
29 changes: 13 additions & 16 deletions ports/libgeotiff/geotiff-config.patch
Original file line number Diff line number Diff line change
@@ -1,17 +1,14 @@
diff --git a/cmake/project-config.cmake.in b/cmake/project-config.cmake.in
index 0dd376aca..0615081bd 100644
--- a/libgeotiff/cmake/project-config.cmake.in
diff --git a/libgeotiff/cmake/project-config.cmake.in b/libgeotiff/cmake/project-config.cmake.in
index dc5b999..2ce07fd 100644
--- a/libgeotiff/cmake/project-config.cmake.in
+++ b/libgeotiff/cmake/project-config.cmake.in
@@ -23,6 +23,12 @@ message (STATUS "Reading ${CMAKE_CURRENT_LIST_FILE}")
message (STATUS
"@PROJECT_NAME@ configuration, version ${@PROJECT_NAME@_VERSION}")

+#Find dependencies
+if(@WITH_PROJ4@)
+ include(CMakeFindDependencyMacro)
+ find_dependency(PROJ4)
+endif()
+
# Tell the user project where to find our headers and libraries
get_filename_component (_DIR ${CMAKE_CURRENT_LIST_FILE} PATH)
get_filename_component (_ROOT "${_DIR}/@PROJECT_ROOT_DIR@" ABSOLUTE)
@@ -23,6 +23,9 @@ message (STATUS "Reading ${CMAKE_CURRENT_LIST_FILE}")
message (STATUS
"@PROJECT_NAME@ configuration, version ${@PROJECT_NAME@_VERSION}")

+include(CMakeFindDependencyMacro)
+find_dependency(PROJ)
+
# Tell the user project where to find our headers and libraries
get_filename_component (_DIR ${CMAKE_CURRENT_LIST_FILE} PATH)
get_filename_component (_ROOT "${_DIR}/@PROJECT_ROOT_DIR@" ABSOLUTE)
45 changes: 22 additions & 23 deletions ports/libgeotiff/portfile.cmake
Original file line number Diff line number Diff line change
@@ -1,49 +1,48 @@
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO OSGeo/libgeotiff
REF 8b1a8f52bc909f86e04ceadd699db102208074a2 #v1.6.0
SHA512 41715d6a416307a93b2f95874c00ed27c3a0450d70311e77ed45f7ff477bd85f4a69b549bde01dfb9412a62a482467222fc8ed398478e2829e4d112012aab852
REF 7da5bacae7814c65ebb78f0b64e1141fbcb3de1e #v1.7.0
SHA512 36047778fbbb4a533a7b65e7b32ab8c0955f59b95417b68b68e7ddd398191445e730e00271756213bf657cbf7cd5eb028b25d4b0741e5b309c78c207b4ec01c6
HEAD_REF master
PATCHES
cmakelists.patch
geotiff-config.patch
fix-proj4.patch
fix-staticbuild.patch
fix-config-version.patch
skip-doc-install.patch
)

set(SOURCE_PATH ${SOURCE_PATH}/libgeotiff)

# Delete FindPROJ4.cmake
file(REMOVE ${SOURCE_PATH}/cmake/FindPROJ4.cmake)
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
FEATURES
tools WITH_JPEG
tools WITH_UTILITIES
)

vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
PREFER_NINJA
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}/libgeotiff"
OPTIONS
-DGEOTIFF_BIN_SUBDIR=bin
-DGEOTIFF_DATA_SUBDIR=share
-DWITH_TIFF=1
-DWITH_PROJ4=1
-DWITH_ZLIB=1
-DWITH_JPEG=1
-DWITH_UTILITIES=1
-DHAVE_TIFFOPEN=1
-DHAVE_TIFFMERGEFIELDINFO=1
-DCMAKE_MACOSX_BUNDLE=0
${FEATURE_OPTIONS}
)

vcpkg_install_cmake()
vcpkg_cmake_install()

vcpkg_copy_tools(TOOL_NAMES applygeo geotifcp listgeo makegeo AUTO_CLEAN)
if(WITH_UTILITIES)
vcpkg_copy_tools(TOOL_NAMES applygeo geotifcp listgeo makegeo AUTO_CLEAN)
endif()

vcpkg_copy_pdbs()
vcpkg_fixup_cmake_targets(CONFIG_PATH share/geotiff TARGET_PATH share/geotiff)
vcpkg_cmake_config_fixup(PACKAGE_NAME GeoTIFF)

if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
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)
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")
endif()

file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include ${CURRENT_PACKAGES_DIR}/debug/doc ${CURRENT_PACKAGES_DIR}/debug/share)

file(INSTALL ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include" "${CURRENT_PACKAGES_DIR}/debug/share")

file(INSTALL "${SOURCE_PATH}/libgeotiff/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
20 changes: 20 additions & 0 deletions ports/libgeotiff/skip-doc-install.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
diff --git a/libgeotiff/CMakeLists.txt b/libgeotiff/CMakeLists.txt
index b4a3cee..f838a36 100644
--- a/libgeotiff/CMakeLists.txt
+++ b/libgeotiff/CMakeLists.txt
@@ -286,6 +286,7 @@ SET(GEOTIFF_LIB_DIR ${GEOTIFF_LIB_SUBDIR})
SET(GEOTIFF_INCLUDE_DIR ${GEOTIFF_INCLUDE_SUBDIR})
SET(GEOTIFF_DATA_DIR ${GEOTIFF_DATA_SUBDIR})

+if(0)
# Install doc files
INSTALL(FILES
AUTHORS ChangeLog COPYING INSTALL LICENSE README README_BIN README.WIN
@@ -294,6 +295,7 @@ INSTALL(FILES

# Install man pages
INSTALL(FILES ${GEOTIFF_MAN_PAGES} DESTINATION share/man/man1)
+endif()


# Install header files for development distribution
5 changes: 5 additions & 0 deletions ports/libgeotiff/usage
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
The package libgeotiff provides a CMake config file:

find_package(GeoTIFF CONFIG REQUIRED)
target_include_directories(main PRIVATE ${GEOTIFF_INCLUDE_DIR})
target_link_libraries(main PRIVATE ${GEOTIFF_LIBRARIES})
30 changes: 23 additions & 7 deletions ports/libgeotiff/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,29 @@
{
"name": "libgeotiff",
"version-string": "1.6.0",
"port-version": 4,
"description": "Libgeotiff is an open source library normally hosted on top of libtiff for reading, and writing GeoTIFF information tags.",
"version": "1.7.0",
"description": "Libgeotiff is an open source library on top of libtiff for reading and writing GeoTIFF information tags.",
"homepage": "https://github.com/OSGeo/libgeotiff",
"dependencies": [
"libjpeg-turbo",
"proj4",
"tiff",
"zlib"
]
{
"name": "tiff",
"default-features": false
},
{
"name": "vcpkg-cmake",
"host": true
},
{
"name": "vcpkg-cmake-config",
"host": true
}
],
"features": {
"tools": {
"description": "Install libgeotiff utility programs",
"dependencies": [
"libjpeg-turbo"
]
}
}
}
25 changes: 0 additions & 25 deletions ports/liblas/fix-geotiff.patch

This file was deleted.

1 change: 0 additions & 1 deletion ports/liblas/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ vcpkg_extract_source_archive_ex(
OUT_SOURCE_PATH SOURCE_PATH
PATCHES
fix-boost-headers.patch
fix-geotiff.patch
)

file(REMOVE ${SOURCE_PATH}/cmake/modules/FindPROJ4.cmake)
Expand Down
4 changes: 2 additions & 2 deletions ports/liblas/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "liblas",
"version-string": "1.8.1",
"port-version": 8,
"version": "1.8.1",
"port-version": 9,
"description": "A C/C++ library for reading and writing the very common LAS LiDAR format.",
"dependencies": [
"boost-detail",
Expand Down
2 changes: 1 addition & 1 deletion ports/pdal/fix-dependency.patch
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ index a03ef14..9d073e6 100644
endforeach(_dir)

+include(CMakeFindDependencyMacro)
+find_dependency(geotiff)
+find_dependency(GeoTIFF)
+find_dependency(CURL)
+find_dependency(Boost COMPONENTS system filesystem)
+find_dependency(geos CONFIG)
Expand Down
15 changes: 0 additions & 15 deletions ports/pdal/geotiff.patch

This file was deleted.

Loading