summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Arnold <nerdboy@gentoo.org>2013-11-18 01:14:50 +0000
committerSteve Arnold <nerdboy@gentoo.org>2013-11-18 01:14:50 +0000
commit10b3245e5034194eb5afbf8150661b57f7c894b4 (patch)
tree20164523027aff5e2e3fa19ab600f5a40559c44d /sci-geosciences
parentVersion bump. (diff)
downloadgentoo-2-10b3245e5034194eb5afbf8150661b57f7c894b4.tar.gz
gentoo-2-10b3245e5034194eb5afbf8150661b57f7c894b4.tar.bz2
gentoo-2-10b3245e5034194eb5afbf8150661b57f7c894b4.zip
Adding latest upstream version; tested on x86 and amd64.
(Portage version: 2.2.7/cvs/Linux x86_64, signed Manifest commit with key )
Diffstat (limited to 'sci-geosciences')
-rw-r--r--sci-geosciences/mapnik/ChangeLog11
-rw-r--r--sci-geosciences/mapnik/files/mapnik-2.2.0-configure-only-once.patch20
-rw-r--r--sci-geosciences/mapnik/files/mapnik-2.2.0-dont-run-ldconfig.patch11
-rw-r--r--sci-geosciences/mapnik/files/mapnik-2.2.0-python3.patch16
-rw-r--r--sci-geosciences/mapnik/files/mapnik-2.2.0-scons.patch11
-rw-r--r--sci-geosciences/mapnik/mapnik-2.2.0.ebuild132
6 files changed, 200 insertions, 1 deletions
diff --git a/sci-geosciences/mapnik/ChangeLog b/sci-geosciences/mapnik/ChangeLog
index a24cd343dc2e..48781a424c9f 100644
--- a/sci-geosciences/mapnik/ChangeLog
+++ b/sci-geosciences/mapnik/ChangeLog
@@ -1,6 +1,15 @@
# ChangeLog for sci-geosciences/mapnik
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sci-geosciences/mapnik/ChangeLog,v 1.40 2013/02/17 07:31:01 swegener Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-geosciences/mapnik/ChangeLog,v 1.41 2013/11/18 01:14:50 nerdboy Exp $
+
+*mapnik-2.2.0 (18 Nov 2013)
+
+ 18 Nov 2013; Steve Arnold <nerdboy@gentoo.org> +mapnik-2.2.0.ebuild,
+ +files/mapnik-2.2.0-configure-only-once.patch,
+ +files/mapnik-2.2.0-dont-run-ldconfig.patch,
+ +files/mapnik-2.2.0-python3.patch, +files/mapnik-2.2.0-scons.patch:
+ Adding version 2.2.0 to keep Pinkbyte happy (among other things).
+ Tested on x86 and amd64 (full ~arch).
17 Feb 2013; Sven Wegener <swegener@gentoo.org>
files/mapnik-2.1.0-dont-run-ldconfig.patch:
diff --git a/sci-geosciences/mapnik/files/mapnik-2.2.0-configure-only-once.patch b/sci-geosciences/mapnik/files/mapnik-2.2.0-configure-only-once.patch
new file mode 100644
index 000000000000..89541cb85ed7
--- /dev/null
+++ b/sci-geosciences/mapnik/files/mapnik-2.2.0-configure-only-once.patch
@@ -0,0 +1,20 @@
+--- a/SConstruct
++++ b/SConstruct
+@@ -503,16 +503,7 @@ for opt in pickle_store:
+ #print 'missing opt', opt
+ preconfigured = False
+
+-# if custom arguments are supplied make sure to accept them
+-if opts.args:
+- # since we have custom arguments update environment with all opts to
+- # make sure to absorb the custom ones
+- opts.Update(env)
+- # now since we've got custom arguments we'll disregard any
+- # pickled environment and force another configuration
+- preconfigured = False
+-
+-elif preconfigured:
++if preconfigured:
+ if not HELP_REQUESTED:
+ color_print(4,'Using previous successful configuration...')
+ color_print(4,'Re-configure by running "python scons/scons.py configure".')
diff --git a/sci-geosciences/mapnik/files/mapnik-2.2.0-dont-run-ldconfig.patch b/sci-geosciences/mapnik/files/mapnik-2.2.0-dont-run-ldconfig.patch
new file mode 100644
index 000000000000..c92c0e9a02a7
--- /dev/null
+++ b/sci-geosciences/mapnik/files/mapnik-2.2.0-dont-run-ldconfig.patch
@@ -0,0 +1,11 @@
+--- a/src/build.py
++++ b/src/build.py
+@@ -38,7 +38,7 @@ def call(cmd, silent=True):
+ print stderr
+
+ def ldconfig(*args,**kwargs):
+- call('ldconfig')
++ pass
+
+ if env['LINKING'] == 'static':
+ lib_env.Append(CXXFLAGS="-fPIC")
diff --git a/sci-geosciences/mapnik/files/mapnik-2.2.0-python3.patch b/sci-geosciences/mapnik/files/mapnik-2.2.0-python3.patch
new file mode 100644
index 000000000000..4266f624070d
--- /dev/null
+++ b/sci-geosciences/mapnik/files/mapnik-2.2.0-python3.patch
@@ -0,0 +1,16 @@
+diff --git a/bindings/python/mapnik_datasource.cpp b/bindings/python/mapnik_datasource.cpp
+index 07383b3..85e2ff7 100644
+--- a/bindings/python/mapnik_datasource.cpp
++++ b/bindings/python/mapnik_datasource.cpp
+@@ -61,7 +61,11 @@ boost::shared_ptr<mapnik::datasource> create_datasource(dict const& d)
+ PyObject* temp = PyUnicode_AsUTF8String(obj.ptr());
+ if (temp)
+ {
++#if PY_VERSION_HEX >= 0x03000000
++ char* c_str = PyBytes_AsString(temp);
++#else
+ char* c_str = PyString_AsString(temp);
++#endif
+ params[key] = std::string(c_str);
+ Py_DecRef(temp);
+ }
diff --git a/sci-geosciences/mapnik/files/mapnik-2.2.0-scons.patch b/sci-geosciences/mapnik/files/mapnik-2.2.0-scons.patch
new file mode 100644
index 000000000000..0ddcd0f9e0dd
--- /dev/null
+++ b/sci-geosciences/mapnik/files/mapnik-2.2.0-scons.patch
@@ -0,0 +1,11 @@
+--- a/SConstruct
++++ b/SConstruct
+@@ -291,7 +291,7 @@ opts.AddVariables(
+ ('LINK_PRIORITY','Priority list in which to sort library and include paths (default order is internal, other, frameworks, user, then system - see source of `sort_paths` function for more detail)',','.join(DEFAULT_LINK_PRIORITY)),
+
+ # Install Variables
+- ('PREFIX', 'The install path "prefix"', '/usr/local'),
++ ('PREFIX', 'The install path "prefix"', '/usr'),
+ ('LIBDIR_SCHEMA', 'The library sub-directory appended to the "prefix", sometimes lib64 on 64bit linux systems', LIBDIR_SCHEMA_DEFAULT),
+ ('PYTHON_PREFIX','Custom install path "prefix" for python bindings (default of no prefix)',''),
+ ('DESTDIR', 'The root directory to install into. Useful mainly for binary package building', '/'),
diff --git a/sci-geosciences/mapnik/mapnik-2.2.0.ebuild b/sci-geosciences/mapnik/mapnik-2.2.0.ebuild
new file mode 100644
index 000000000000..1075eb8ac7be
--- /dev/null
+++ b/sci-geosciences/mapnik/mapnik-2.2.0.ebuild
@@ -0,0 +1,132 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sci-geosciences/mapnik/mapnik-2.2.0.ebuild,v 1.1 2013/11/18 01:14:50 nerdboy Exp $
+
+EAPI=5
+
+PYTHON_COMPAT=( python{2_5,2_6,2_7,3_2,3_3} )
+MY_P="${PN}-v${PV}"
+
+inherit eutils python-single-r1 scons-utils toolchain-funcs
+
+DESCRIPTION="A Free Toolkit for developing mapping applications."
+HOMEPAGE="http://www.mapnik.org/"
+SRC_URI="http://mapnik.s3.amazonaws.com/dist/v${PV}/${MY_P}.tar.bz2"
+
+LICENSE="LGPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
+IUSE="cairo debug doc gdal postgres python sqlite"
+
+RDEPEND="
+ >=dev-libs/boost-1.48[threads,python?]
+ dev-libs/icu
+ sys-libs/zlib
+ media-libs/freetype
+ dev-libs/libxml2
+ media-libs/libpng
+ media-libs/tiff
+ virtual/jpeg
+ media-libs/libwebp
+ sci-libs/proj
+ media-fonts/dejavu
+ x11-libs/agg[truetype]
+ net-misc/curl
+ cairo? (
+ x11-libs/cairo
+ dev-cpp/cairomm
+ python? ( dev-python/pycairo[${PYTHON_USEDEP}] )
+ )
+ postgres? ( >=dev-db/postgresql-base-8.3 )
+ gdal? ( sci-libs/gdal )
+ sqlite? ( dev-db/sqlite:3 )
+ python_single_target_python3_2? ( >=dev-libs/boost-1.53[${PYTHON_USEDEP}] )
+ python_single_target_python3_3? ( >=dev-libs/boost-1.53[${PYTHON_USEDEP}] )
+"
+
+DEPEND="${RDEPEND}"
+
+REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
+
+S="${WORKDIR}/${MY_P}"
+
+pkg_setup() {
+ use python && python-single-r1_pkg_setup
+}
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/${P}-configure-only-once.patch \
+ "${FILESDIR}"/${P}-dont-run-ldconfig.patch \
+ "${FILESDIR}"/${P}-scons.patch \
+ "${FILESDIR}"/${P}-python3.patch
+
+ # 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
+
+ epatch_user
+}
+
+src_configure() {
+ local PLUGINS=shape,csv,raster,geojson,osm
+ use gdal && PLUGINS+=,gdal,ogr
+ use postgres && PLUGINS+=,postgis
+ use sqlite && PLUGINS+=,sqlite
+ use python && PLUGINS+=,python
+
+ myesconsargs=(
+ "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)"
+ "SYSTEM_FONTS=/usr/share/fonts"
+ $(use_scons python BINDINGS all none)
+ $(use python && use_scons python PYTHON $PYTHON)
+ $(use_scons python BOOST_PYTHON_LIB boost_python-$(echo $EPYTHON | sed 's/python//'))
+ $(use_scons cairo CAIRO)
+ $(use_scons debug DEBUG)
+ $(use_scons debug XML_DEBUG)
+ $(use_scons doc DEMO)
+ $(use_scons doc SAMPLE_INPUT_PLUGINS)
+ "CUSTOM_LDFLAGS=${LDFLAGS}"
+ "CUSTOM_LDFLAGS+=-L${ED}/usr/$(get_libdir)"
+ )
+
+ escons configure
+}
+
+src_compile() {
+ escons
+}
+
+src_install() {
+ escons install
+
+ if use python ; then
+ python_optimize
+ fperms 0644 "$(python_get_sitedir)"/${PN}/paths.py
+ dobin utils/stats/mapdef_stats.py
+ fi
+
+ dodoc AUTHORS.md README.md CHANGELOG.md
+}
+
+pkg_postinst() {
+ elog ""
+ elog "See the home page or wiki (http://trac.mapnik.org/) for more info"
+ elog "or the installed examples for the default mapnik ogcserver config."
+ elog ""
+}