mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-09 19:13:26 +03:00
mapnik: 4.0.7 -> 4.1.0 (#414803)
This commit is contained in:
commit
5f226d4da4
5 changed files with 17 additions and 51 deletions
|
@ -27,15 +27,15 @@
|
|||
sparsehash,
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
pname = "mapnik";
|
||||
version = "4.0.7";
|
||||
version = "4.1.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "mapnik";
|
||||
repo = "mapnik";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-gJktRWcJiSGxxjvWFt+Kl9d7g+TOSPk2PfGP0LIVxt4=";
|
||||
tag = "v${finalAttrs.version}";
|
||||
hash = "sha256-EhRMG0xPOGwcRAMQD2B4z7nVlXQf4HFFfL3oUaUfXBY=";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
|
||||
|
@ -47,18 +47,14 @@ stdenv.mkDerivation rec {
|
|||
rm -r scons
|
||||
# Remove bundled 'sparsehash' directory in favor of 'sparsehash' package
|
||||
rm -r deps/mapnik/sparsehash
|
||||
# Remove bundled 'protozero' directory in favor of 'protozero' package
|
||||
rm -r deps/mapbox/protozero
|
||||
'';
|
||||
|
||||
# a distinct dev output makes python-mapnik fail
|
||||
outputs = [ "out" ];
|
||||
|
||||
patches = [
|
||||
# The lib/cmake/harfbuzz/harfbuzz-config.cmake file in harfbuzz.dev is faulty,
|
||||
# as it provides the wrong libdir. The workaround is to just rely on
|
||||
# pkg-config to locate harfbuzz shared object files.
|
||||
# Upstream HarfBuzz wants to drop CMake support anyway.
|
||||
# See discussion: https://github.com/mapnik/mapnik/issues/4265
|
||||
./cmake-harfbuzz.patch
|
||||
# Account for full paths when generating libmapnik.pc
|
||||
./export-pkg-config-full-paths.patch
|
||||
# Use 'sparsehash' package.
|
||||
|
@ -75,7 +71,7 @@ stdenv.mkDerivation rec {
|
|||
cairo
|
||||
freetype
|
||||
gdal
|
||||
harfbuzz
|
||||
(harfbuzz.override { withIcu = true; })
|
||||
icu
|
||||
libjpeg
|
||||
libpng
|
||||
|
@ -97,6 +93,8 @@ stdenv.mkDerivation rec {
|
|||
(lib.cmakeBool "BUILD_DEMO_CPP" false)
|
||||
## Would require QT otherwise.
|
||||
(lib.cmakeBool "BUILD_DEMO_VIEWER" false)
|
||||
# disable the find_package call and force pkg-config, see https://github.com/mapnik/mapnik/pull/4270
|
||||
(lib.cmakeBool "CMAKE_DISABLE_FIND_PACKAGE_harfbuzz" true)
|
||||
# Use 'protozero' package.
|
||||
(lib.cmakeBool "USE_EXTERNAL_MAPBOX_PROTOZERO" true)
|
||||
# macOS builds fail when using memory mapped file cache.
|
||||
|
@ -118,19 +116,19 @@ stdenv.mkDerivation rec {
|
|||
'';
|
||||
|
||||
preInstall = ''
|
||||
mkdir -p $out/bin
|
||||
cp ../utils/mapnik-config/mapnik-config $out/bin/mapnik-config
|
||||
install -Dm755 ../utils/mapnik-config/mapnik-config -t $out/bin
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
meta = {
|
||||
description = "Open source toolkit for developing mapping applications";
|
||||
homepage = "https://mapnik.org";
|
||||
maintainers = with maintainers; [
|
||||
changelog = "https://github.com/mapnik/mapnik/blob/${finalAttrs.src.tag}/CHANGELOG.md";
|
||||
maintainers = with lib.maintainers; [
|
||||
hrdinka
|
||||
hummeltech
|
||||
];
|
||||
teams = [ teams.geospatial ];
|
||||
license = licenses.lgpl21Plus;
|
||||
platforms = platforms.all;
|
||||
teams = [ lib.teams.geospatial ];
|
||||
license = lib.licenses.lgpl21Plus;
|
||||
platforms = lib.platforms.all;
|
||||
};
|
||||
}
|
||||
})
|
|
@ -1,26 +0,0 @@
|
|||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index ffb86d4ac..1775b986f 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -177,19 +177,8 @@ endif()
|
||||
|
||||
mapnik_find_package(Freetype REQUIRED)
|
||||
|
||||
-# try to find harfbuzz with the native configuration and fallback to our "own" FindHarfBuzz
|
||||
-mapnik_find_package(harfbuzz CONFIG QUIET)
|
||||
-if(harfbuzz_FOUND)
|
||||
- message(STATUS "Found harfbuzz native cmake")
|
||||
- list(APPEND MAPNIK_OPTIONAL_LIBS harfbuzz::harfbuzz)
|
||||
-else()
|
||||
- # Use pkg-config when harfbuzz is not found.
|
||||
- # It might be possible that in future version harfbuzz could only be found via pkg-config.
|
||||
- # harfbuzz related discussion: https://github.com/harfbuzz/harfbuzz/issues/2653
|
||||
- message(STATUS "harfbuzz not found via cmake. Searching via pkg-config...")
|
||||
- mapnik_pkg_check_modules(harfbuzz REQUIRED IMPORTED_TARGET harfbuzz>=${HARFBUZZ_MIN_VERSION})
|
||||
- list(APPEND MAPNIK_OPTIONAL_LIBS PkgConfig::harfbuzz)
|
||||
-endif()
|
||||
+pkg_check_modules(harfbuzz REQUIRED IMPORTED_TARGET harfbuzz)
|
||||
+list(APPEND MAPNIK_OPTIONAL_LIBS PkgConfig::harfbuzz)
|
||||
|
||||
if(USE_EXTERNAL_MAPBOX_GEOMETRY)
|
||||
# this is used to provide a way to specify include dirs with CACHE VARIABLES
|
|
@ -9007,12 +9007,6 @@ with pkgs;
|
|||
asciidoc = asciidoc-full;
|
||||
};
|
||||
|
||||
mapnik = callPackage ../development/libraries/mapnik {
|
||||
harfbuzz = harfbuzz.override {
|
||||
withIcu = true;
|
||||
};
|
||||
};
|
||||
|
||||
matterhorn =
|
||||
# TODO: Erroneous references to GHC on aarch64-darwin: https://github.com/NixOS/nixpkgs/issues/318013
|
||||
(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue