[mapnik] update port (#20557)

* update to latest commit

* remove demo feature

* update to latest

* fix pkgconfig

* speed up copy tools

* update mapnik

* update sha

* remove debug messages

* update version

* add coretext to harfbuzz for osx

* version

* [skip actions] Trigger CI

* fix issue on macos

* version database

* apply ras0219-msft suggestions

* remove core

* version

* version

* [skip actions] Trigger CI

* test latest commit

* v

* update to latest

* version

* update to latest master

* version

* revert portfile.cmake format

* update version

Co-authored-by: nicole mazzuca <mazzucan@outlook.com>
Co-authored-by: Jonliu1993 <13720414433@163.com>
This commit is contained in:
Mathis Logemann 2021-10-16 04:14:06 +02:00 committed by GitHub
parent 02fc26bbe9
commit e47ab01d40
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 41 additions and 63 deletions

View File

@ -4,11 +4,9 @@ vcpkg_check_linkage(ONLY_DYNAMIC_LIBRARY)
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO mapnik/mapnik
REF 1ccbbf95b5e7bf254ab5b4dc21bdc373978c36a1
SHA512 21b4fc6e64d9b53550a046c5c9bcc32524324d7df39816b74b23a7ce2a64c4eeb291ad1c1aa09a3d5d79158f889ba8b7182cd0bf3435c39d1f17f33e4ffdce05
REF 0edb018465790cd156d6849557fa7fd568755ebb
SHA512 cd6180b96dbfbc1bafbc8f2a4ff2091a0e8c0c42b0569ef83640ad1f5766ff74ea95f8c6cef53f879396cbceebc6396c1a977676eca67c401b8e145a9ceae7e2
HEAD_REF master
PATCHES
use-proj.patch
)
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
@ -34,7 +32,6 @@ vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
"input-sqlite" USE_PLUGIN_INPUT_SQLITE
"input-topojson" USE_PLUGIN_INPUT_TOPOJSON
"viewer" BUILD_DEMO_VIEWER
"demo" BUILD_DEMO_CPP
"utility-geometry-to-wkb" BUILD_UTILITY_GEOMETRY_TO_WKB
"utility-mapnik-index" BUILD_UTILITY_MAPNIK_INDEX
"utility-mapnik-render" BUILD_UTILITY_MAPNIK_RENDER
@ -53,61 +50,64 @@ vcpkg_cmake_configure(
-DINSTALL_DEPENDENCIES=OFF
-DBUILD_TEST=OFF
-DBUILD_BENCHMARK=OFF
-DBUILD_DEMO_CPP=OFF
-DUSE_EXTERNAL_MAPBOX_GEOMETRY=ON
-DUSE_EXTERNAL_MAPBOX_POLYLABEL=ON
-DUSE_EXTERNAL_MAPBOX_PROTOZERO=ON
-DUSE_EXTERNAL_MAPBOX_VARIANT=ON
-DINSTALL_CMAKE_DIR=share/mapnik/cmake
-DMAPNIK_CMAKE_DIR=share/mapnik/cmake
-DFONTS_INSTALL_DIR=share/mapnik/fonts
-DMAPNIK_PKGCONF_DIR=lib/pkgconfig
)
vcpkg_cmake_install()
# copy plugins into tool path, if any plugin is installed
if(IS_DIRECTORY "${CURRENT_PACKAGES_DIR}/bin/plugins")
file(COPY "${CURRENT_PACKAGES_DIR}/bin/plugins" DESTINATION "${CURRENT_PACKAGES_DIR}/tools/${PORT}")
file(COPY "${CURRENT_PACKAGES_DIR}/bin/plugins" DESTINATION "${CURRENT_PACKAGES_DIR}/tools/${PORT}")
endif()
vcpkg_copy_pdbs()
if("demo" IN_LIST FEATURES)
file(COPY "${SOURCE_PATH}/demo/data" DESTINATION "${CURRENT_PACKAGES_DIR}/tools/${PORT}/demo")
vcpkg_copy_tools(TOOL_NAMES mapnik-demo AUTO_CLEAN)
endif()
set(_tool_names "")
if("viewer" IN_LIST FEATURES)
# copy the ini file to reference the plugins correctly
file(COPY "${CURRENT_PACKAGES_DIR}/bin/viewer.ini" DESTINATION "${CURRENT_PACKAGES_DIR}/tools/${PORT}")
vcpkg_copy_tools(TOOL_NAMES mapnik-viewer AUTO_CLEAN)
# copy the ini file to reference the plugins correctly
file(COPY "${CURRENT_PACKAGES_DIR}/bin/viewer.ini" DESTINATION "${CURRENT_PACKAGES_DIR}/tools/${PORT}")
list(APPEND _tool_names mapnik-viewer)
endif()
if("utility-geometry-to-wkb" IN_LIST FEATURES)
vcpkg_copy_tools(TOOL_NAMES geometry_to_wkb AUTO_CLEAN)
list(APPEND _tool_names geometry_to_wkb)
endif()
if("utility-mapnik-index" IN_LIST FEATURES)
vcpkg_copy_tools(TOOL_NAMES mapnik-index AUTO_CLEAN)
list(APPEND _tool_names mapnik-index)
endif()
if("utility-mapnik-render" IN_LIST FEATURES)
vcpkg_copy_tools(TOOL_NAMES mapnik-render AUTO_CLEAN)
list(APPEND _tool_names mapnik-render)
endif()
if("utility-ogrindex" IN_LIST FEATURES)
# build is currently not supported
# vcpkg_copy_tools(TOOL_NAMES ogrindex AUTO_CLEAN)
# build is currently not supported
# vcpkg_copy_tools(TOOL_NAMES ogrindex AUTO_CLEAN)
endif()
if("utility-pgsql2sqlite" IN_LIST FEATURES)
vcpkg_copy_tools(TOOL_NAMES pgsql2sqlite AUTO_CLEAN)
list(APPEND _tool_names pgsql2sqlite)
endif()
if("utility-shapeindex" IN_LIST FEATURES)
vcpkg_copy_tools(TOOL_NAMES shapeindex AUTO_CLEAN)
list(APPEND _tool_names shapeindex)
endif()
if("utility-svg2png" IN_LIST FEATURES)
vcpkg_copy_tools(TOOL_NAMES svg2png AUTO_CLEAN)
list(APPEND _tool_names svg2png)
endif()
if(_tool_names)
vcpkg_copy_tools(TOOL_NAMES ${_tool_names} AUTO_CLEAN)
endif()
vcpkg_cmake_config_fixup(CONFIG_PATH share/mapnik/cmake)
vcpkg_fixup_pkgconfig()
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
file(WRITE "${CURRENT_PACKAGES_DIR}/share/mapnik/mapnikPlugins-debug.cmake" "set(MAPNIK_PLUGINS_DIR_DEBUG \"\${PACKAGE_PREFIX_DIR}/debug/bin/mapnik/input\" CACHE STRING \"\")")
file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
file(INSTALL "${SOURCE_PATH}/fonts/unifont_license.txt" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME fonts_copyright)
file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}")

View File

@ -4,6 +4,4 @@ The package mapnik provides CMake targets:
target_link_libraries(main PRIVATE mapnik::mapnik mapnik::json mapnik::wkt)
If you only need the compile definitions without any sources, use target mapnik::core.
If any plugins were installed, the variable ${MAPNIK_PLUGINS_DIR} contains the plugin directory
Fonts are available with the variable ${MAPNIK_FONTS_DIR}
If any plugins were installed, call the function `mapnik_find_plugin_dir(MAPNIK_PLUGIN_DIR)` to get the plugin installation folder for the currently used configuration. See the docs for more information.

View File

@ -1,28 +0,0 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 54dda37..e82a817 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -254,21 +254,21 @@ endif()
if(USE_PROJ)
#https://proj.org/development/cmake.html
mapnik_find_package(PROJ QUIET)
# currently the cmake files are not installed, when installing proj via apt-get. So search via pkg-config
if(NOT PROJ_FOUND)
message(STATUS "PROJ not found via FindPROJ. Searching via pkg-config...")
pkg_check_modules(PROJ REQUIRED IMPORTED_TARGET proj)
string(REGEX MATCH "([0-9]+)\.([0-9]+)\.([0-9]+)" _dummy "${PROJ_VERSION}")
set(PROJ_VERSION_MAJOR "${CMAKE_MATCH_1}")
set(PROJ_VERSION_MINOR "${CMAKE_MATCH_2}")
set(PROJ_VERSION_PATCH "${CMAKE_MATCH_3}")
endif()
math(EXPR MAPNIK_PROJ_VERSION "${PROJ_VERSION_MAJOR}*10000 + ${PROJ_VERSION_MINOR}*100 + ${PROJ_VERSION_PATCH}" OUTPUT_FORMAT DECIMAL)
message(STATUS "Using mapnik PROJ version: ${MAPNIK_PROJ_VERSION}")
list(APPEND MAPNIK_COMPILE_DEFS MAPNIK_USE_PROJ MAPNIK_PROJ_VERSION=${MAPNIK_PROJ_VERSION})
- list(APPEND MAPNIK_OPTIONAL_LIBS ${PROJ_LIBRARIES})
- list(APPEND MAPNIK_OPTIONAL_LIBS_INCLUDE ${PROJ_INCLUDE_DIRS})
+ list(APPEND MAPNIK_OPTIONAL_LIBS ${PROJ_LIBRARIES})
+ # list(APPEND MAPNIK_OPTIONAL_LIBS_INCLUDE ${PROJ_INCLUDE_DIRS}) # this adds some non existent directory when building with vcpgk -> commented out
endif()
if(USE_GRID_RENDERER)

View File

@ -1,7 +1,6 @@
{
"name": "mapnik",
"version-date": "2021-09-15",
"port-version": 1,
"version-date": "2021-10-13",
"description": "Mapnik is an open source toolkit for developing mapping applications.",
"homepage": "https://github.com/mapnik/mapnik",
"supports": "!(static & windows)",
@ -41,6 +40,13 @@
"icu"
]
},
{
"name": "harfbuzz",
"features": [
"coretext"
],
"platform": "osx"
},
"icu",
"mapbox-geometry",
"mapbox-polylabel",
@ -73,9 +79,6 @@
"cairomm"
]
},
"demo": {
"description": "Make demo application"
},
"grid-renderer": {
"description": "Grid renderer"
},

View File

@ -4177,8 +4177,8 @@
"port-version": 0
},
"mapnik": {
"baseline": "2021-09-15",
"port-version": 1
"baseline": "2021-10-13",
"port-version": 0
},
"marble": {
"baseline": "19.08.2",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "b7f061c560ab0a4c5c137f88ab43826c05ece6ad",
"version-date": "2021-10-13",
"port-version": 0
},
{
"git-tree": "d75a684e7f654d0fc2485c4fa501a8821056c92b",
"version-date": "2021-09-15",