diff options
author | Amy Liffey <amynka@gentoo.org> | 2017-11-02 20:04:06 +0100 |
---|---|---|
committer | Amy Liffey <amynka@gentoo.org> | 2017-11-02 20:06:54 +0100 |
commit | aa58770021c587f3a16b4bb9dbb6621dc9da4be6 (patch) | |
tree | fbbc7163f9dee607252e66e5b5133382498c3d2e /sci-geosciences/mapnik | |
parent | sys-kernel/vanilla-sources: Version bump to 4.9.60 (diff) | |
download | gentoo-aa58770021c587f3a16b4bb9dbb6621dc9da4be6.tar.gz gentoo-aa58770021c587f3a16b4bb9dbb6621dc9da4be6.tar.bz2 gentoo-aa58770021c587f3a16b4bb9dbb6621dc9da4be6.zip |
sci-geosciences/mapnik: fix icu and libs
Submitted-by: calimeroteknik@free.fr
Closes:https://bugs.gentoo.org/618674
Closes:https://bugs.gentoo.org/630948
Package-Manager: Portage-2.3.8, Repoman-2.3.1
Diffstat (limited to 'sci-geosciences/mapnik')
3 files changed, 143 insertions, 0 deletions
diff --git a/sci-geosciences/mapnik/files/mapnik-3.0.9-harbuzz_sharper-upstream.patch b/sci-geosciences/mapnik/files/mapnik-3.0.9-harbuzz_sharper-upstream.patch new file mode 100644 index 000000000000..cb81f526568c --- /dev/null +++ b/sci-geosciences/mapnik/files/mapnik-3.0.9-harbuzz_sharper-upstream.patch @@ -0,0 +1,25 @@ +--- a/include/mapnik/text/harfbuzz_shaper.hpp 2017-10-31 17:45:30.737250086 +0100 ++++ b/include/mapnik/text/harfbuzz_shaper.hpp 2017-10-31 17:46:56.002247847 +0100 +@@ -39,10 +39,11 @@ + // harfbuzz + #include <harfbuzz/hb.h> + #include <harfbuzz/hb-ft.h> +- ++#include <unicode/uvernum.h> + // icu + #include <unicode/uscript.h> + ++ + namespace mapnik + { + +@@ -55,7 +56,8 @@ + static inline const uint16_t * uchar_to_utf16(const UChar* src) + { + static_assert(sizeof(UChar) == sizeof(uint16_t),"UChar is eq size to uint16_t"); +-#if defined(_MSC_VER) ++#if defined(_MSC_VER) || (U_ICU_VERSION_MAJOR_NUM >= 59) ++ // ^^ http://site.icu-project.org/download/59#TOC-ICU4C-char16_t1 + return reinterpret_cast<const uint16_t *>(src); + #else + return src; diff --git a/sci-geosciences/mapnik/files/mapnik-3.0.9-unicode-upstream.patch b/sci-geosciences/mapnik/files/mapnik-3.0.9-unicode-upstream.patch new file mode 100644 index 000000000000..0233eb4e3fdd --- /dev/null +++ b/sci-geosciences/mapnik/files/mapnik-3.0.9-unicode-upstream.patch @@ -0,0 +1,11 @@ +--- a/include/mapnik/unicode.hpp 2017-10-31 17:53:23.507237672 +0100 ++++ b/include/mapnik/unicode.hpp 2017-10-31 17:53:47.096237053 +0100 +@@ -31,6 +31,8 @@ + // std + #include <cstdint> + #include <string> ++// icu ++#include <unicode/unistr.h> + + struct UConverter; + diff --git a/sci-geosciences/mapnik/mapnik-3.0.9-r1.ebuild b/sci-geosciences/mapnik/mapnik-3.0.9-r1.ebuild new file mode 100644 index 000000000000..bcaadad2a45f --- /dev/null +++ b/sci-geosciences/mapnik/mapnik-3.0.9-r1.ebuild @@ -0,0 +1,107 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit eutils scons-utils toolchain-funcs + +DESCRIPTION="A Free Toolkit for developing mapping applications" +HOMEPAGE="http://www.mapnik.org/" +SRC_URI="https://github.com/mapnik/mapnik/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="LGPL-3" +SLOT="0" +KEYWORDS="~amd64 ~ppc ~ppc64 ~x86" +IUSE="cairo debug doc gdal postgres sqlite" + +RDEPEND=" + >=dev-libs/boost-1.48[threads] + dev-libs/icu:= + sys-libs/zlib + media-libs/freetype + media-libs/harfbuzz + dev-libs/libxml2 + media-libs/libpng:0= + media-libs/tiff:0= + virtual/jpeg:0= + media-libs/libwebp + sci-libs/proj + media-fonts/dejavu + x11-libs/agg[truetype] + cairo? ( + x11-libs/cairo + dev-cpp/cairomm + ) + postgres? ( >=dev-db/postgresql-8.3:* ) + gdal? ( sci-libs/gdal ) + sqlite? ( dev-db/sqlite:3 )" +DEPEND="${RDEPEND}" + +PATCHES=( + "${FILESDIR}/${PN}-2.2.0-configure-only-once.patch" + "${FILESDIR}/${PN}-2.2.0-dont-run-ldconfig.patch" + "${FILESDIR}/${PN}-2.2.0-scons.patch" + "${FILESDIR}/${P}-harbuzz_sharper-upstream.patch" # upstream patches ported from + "${FILESDIR}/${P}-unicode-upstream.patch" # https://github.com/mapnik/mapnik/commit/9e58c890430db6f0b6f1f7a1690877c9d913d92a +) + +src_prepare() { + default + + # do not version epidoc data + sed -i \ + -e 's:-`mapnik-config --version`::g' \ + utils/epydoc_config/build_epydoc.sh || die + + # force user flags, optimization level + sed -i -e "s:\-O%s:%s:" \ + -i -e "s:env\['OPTIMIZATION'\]:'${CXXFLAGS}':" \ + SConstruct || die +} + +src_configure() { + local PLUGINS=shape,csv,raster,geojson + use gdal && PLUGINS+=,gdal,ogr + use postgres && PLUGINS+=,postgis + use sqlite && PLUGINS+=,sqlite + + MYSCONS=( + "CC=$(tc-getCC)" + "CXX=$(tc-getCXX)" + "INPUT_PLUGINS=${PLUGINS}" + "PREFIX=/usr" + "DESTDIR=${D}" + "XMLPARSER=libxml2" + "LINKING=shared" + "RUNTIME_LINK=shared" + "PROJ_INCLUDES=/usr/include" + "PROJ_LIBS=/usr/$(get_libdir)" + "LIBDIR_SCHEMA=$(get_libdir)" + "SYSTEM_FONTS=/usr/share/fonts" + CAIRO="$(usex cairo 1 0)" + DEBUG="$(usex debug 1 0)" + XML_DEBUG="$(usex debug 1 0)" + DEMO="$(usex doc 1 0)" + SAMPLE_INPUT_PLUGINS="$(usex doc 1 0)" + "CUSTOM_LDFLAGS=${LDFLAGS}" + "CUSTOM_LDFLAGS+=-L${ED}/usr/$(get_libdir)" + ) + escons "${MYSCONS[@]}" configure +} + +src_compile() { + escons "${MYSCONS[@]}" +} + +src_install() { + escons "${MYSCONS[@]}" DESTDIR="${D}" install + + dodoc AUTHORS.md README.md CHANGELOG.md +} + +pkg_postinst() { + elog "" + elog "See the home page or wiki (https://github.com/mapnik/mapnik/wiki) for more info" + elog "or the installed examples for the default mapnik ogcserver config." + elog "" +} |