aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhlysunnaram <hlysunnaram@users.noreply.github.com>2018-10-16 03:56:14 +0200
committerRobert Schumacher <roschuma@microsoft.com>2018-10-15 18:56:14 -0700
commit9bc8ed32d196a04f352ce09a7121b18ba7f8f6f9 (patch)
tree770ae72f7153a14b593095afba7621b128bc2757
parent4f3e3fcdcb9e922533120aa92e8f8faf775e0d29 (diff)
downloadvcpkg-9bc8ed32d196a04f352ce09a7121b18ba7f8f6f9.tar.gz
vcpkg-9bc8ed32d196a04f352ce09a7121b18ba7f8f6f9.zip
[geos] update to 3.6.3 (fix port build) (#4433)
* [geos] update to 3.6.3 * [geos] Slight modernization * [geos] Move geos-config to /share/geos/ * [geos] Make share/geos directory
-rw-r--r--ports/geos/CONTROL2
-rw-r--r--ports/geos/portfile.cmake55
2 files changed, 22 insertions, 35 deletions
diff --git a/ports/geos/CONTROL b/ports/geos/CONTROL
index 1a32a8103..0a4421eea 100644
--- a/ports/geos/CONTROL
+++ b/ports/geos/CONTROL
@@ -1,3 +1,3 @@
Source: geos
-Version: 3.6.2-3
+Version: 3.6.3-2
Description: Geometry Engine Open Source
diff --git a/ports/geos/portfile.cmake b/ports/geos/portfile.cmake
index e5a404254..2f374e79d 100644
--- a/ports/geos/portfile.cmake
+++ b/ports/geos/portfile.cmake
@@ -1,53 +1,40 @@
-# Common Ambient Variables:
-# VCPKG_ROOT_DIR = <C:\path\to\current\vcpkg>
-# TARGET_TRIPLET is the current triplet (x86-windows, etc)
-# PORT is the current port name (zlib, etc)
-# CURRENT_BUILDTREES_DIR = ${VCPKG_ROOT_DIR}\buildtrees\${PORT}
-# CURRENT_PACKAGES_DIR = ${VCPKG_ROOT_DIR}\packages\${PORT}_${TARGET_TRIPLET}
-#
-
include(vcpkg_common_functions)
-set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/geos-3.6.2)
+
+set(GEOS_VERSION 3.6.3)
vcpkg_download_distfile(ARCHIVE
- URLS "http://download.osgeo.org/geos/geos-3.6.2.tar.bz2"
- FILENAME "geos-3.6.2.tar.bz2"
- SHA512 515d8700b8a28282678e481faee355e3a43d7b70160472a63335b8d7225d9ba10437be782378f18f31a15288118126d411a2d862f01ce35d27c96f6bc0a73016
+ URLS "http://download.osgeo.org/geos/geos-${GEOS_VERSION}.tar.bz2"
+ FILENAME "geos-${GEOS_VERSION}.tar.bz2"
+ SHA512 f88adcf363433e247a51fb1a2c0b53f39b71aba8a6c01dd08aa416c2e980fe274a195e6edcb5bb5ff8ea81b889da14a1a8fb2849e04669aeba3b6d55754dc96a
)
-vcpkg_extract_source_archive(${ARCHIVE})
-vcpkg_apply_patches(
-
-SOURCE_PATH ${SOURCE_PATH}
- PATCHES ${CMAKE_CURRENT_LIST_DIR}/geos_c-static-support.patch
+vcpkg_extract_source_archive_ex(
+ OUT_SOURCE_PATH SOURCE_PATH
+ ARCHIVE ${ARCHIVE}
+ REF ${GEOS_VERSION}
+ PATCHES geos_c-static-support.patch
)
# NOTE: GEOS provides CMake as optional build configuration, it might not be actively
# maintained, so CMake build issues may happen between releases.
-# Pull modules referred in the main CMakeLists.txt but missing from the released package.
-# TODO: GEOS 3.6.3 or later will include the missing script in release package.
-file(DOWNLOAD http://svn.osgeo.org/geos/branches/3.6/cmake/modules/GenerateSourceGroups.cmake
- ${SOURCE_PATH}/cmake/modules/GenerateSourceGroups.cmake)
-
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
- PREFER_NINJA # Disable this option if project cannot be built with Ninja
+ PREFER_NINJA
OPTIONS
- -DCMAKE_DEBUG_POSTFIX=d
- -DGEOS_ENABLE_TESTS=False
+ -DCMAKE_DEBUG_POSTFIX=d
+ -DGEOS_ENABLE_TESTS=False
)
vcpkg_install_cmake()
+
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
-# Handle copyright
-file(COPY ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/geos)
-file(RENAME ${CURRENT_PACKAGES_DIR}/share/geos/COPYING ${CURRENT_PACKAGES_DIR}/share/geos/copyright)
-if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
- file(REMOVE ${CURRENT_PACKAGES_DIR}/lib/libgeos.lib ${CURRENT_PACKAGES_DIR}/debug/lib/libgeosd.lib)
-else()
- file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin ${CURRENT_PACKAGES_DIR}/debug/bin)
- file(REMOVE ${CURRENT_PACKAGES_DIR}/lib/geos.lib ${CURRENT_PACKAGES_DIR}/debug/lib/geosd.lib)
- file(REMOVE ${CURRENT_PACKAGES_DIR}/lib/geos_c.lib ${CURRENT_PACKAGES_DIR}/debug/lib/geos_cd.lib)
+if(EXISTS ${CURRENT_PACKAGES_DIR}/bin/geos-config)
+ file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/share/geos)
+ file(RENAME ${CURRENT_PACKAGES_DIR}/bin/geos-config ${CURRENT_PACKAGES_DIR}/share/geos/geos-config)
+ file(REMOVE ${CURRENT_PACKAGES_DIR}/debug/bin/geos-config)
endif()
+# Handle copyright
+configure_file(${SOURCE_PATH}/COPYING ${CURRENT_PACKAGES_DIR}/share/geos/copyright COPYONLY)
+
vcpkg_copy_pdbs()