pythonPackages.python-mapnik: refactor move to python-modules
This commit is contained in:
parent
ab656c8772
commit
ed1ee313e4
58
pkgs/development/python-modules/python-mapnik/default.nix
Normal file
58
pkgs/development/python-modules/python-mapnik/default.nix
Normal file
@ -0,0 +1,58 @@
|
||||
{ stdenv
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, isPyPy
|
||||
, python
|
||||
, pkgs
|
||||
, pillow
|
||||
, pycairo
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "python-mapnik";
|
||||
version = "3.0.16";
|
||||
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "mapnik";
|
||||
repo = "python-mapnik";
|
||||
rev = "v${version}";
|
||||
sha256 = "1gqs4kvmjawdgl80j0ab5r8y0va9kw0rvwix3093xsv4hwd00lcc";
|
||||
};
|
||||
|
||||
disabled = isPyPy;
|
||||
doCheck = false; # doesn't find needed test data files
|
||||
preBuild = let
|
||||
pythonVersion = with stdenv.lib.versions; "${major python.version}${minor python.version}";
|
||||
in ''
|
||||
export BOOST_PYTHON_LIB="boost_python${pythonVersion}"
|
||||
export BOOST_THREAD_LIB="boost_thread"
|
||||
export BOOST_SYSTEM_LIB="boost_system"
|
||||
'';
|
||||
buildInputs = with pkgs; [
|
||||
(boost.override {
|
||||
enablePython = true;
|
||||
inherit python;
|
||||
})
|
||||
(mapnik.override {
|
||||
inherit python;
|
||||
boost = (boost.override { enablePython = true; inherit python; });
|
||||
})
|
||||
cairo
|
||||
harfbuzz
|
||||
icu
|
||||
libjpeg
|
||||
libpng
|
||||
libtiff
|
||||
libwebp
|
||||
proj
|
||||
zlib
|
||||
];
|
||||
propagatedBuildInputs = [ pillow pycairo ];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "Python bindings for Mapnik";
|
||||
homepage = http://mapnik.org;
|
||||
license = licenses.lgpl21;
|
||||
};
|
||||
|
||||
}
|
@ -1970,53 +1970,7 @@ in {
|
||||
|
||||
mailchimp = callPackage ../development/python-modules/mailchimp { };
|
||||
|
||||
python-mapnik = buildPythonPackage rec {
|
||||
name = "python-mapnik-${version}";
|
||||
version = "3.0.16";
|
||||
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "mapnik";
|
||||
repo = "python-mapnik";
|
||||
rev = "v${version}";
|
||||
sha256 = "1gqs4kvmjawdgl80j0ab5r8y0va9kw0rvwix3093xsv4hwd00lcc";
|
||||
};
|
||||
|
||||
disabled = isPyPy;
|
||||
doCheck = false; # doesn't find needed test data files
|
||||
preBuild = let
|
||||
pythonVersion = with stdenv.lib.versions; "${major python.version}${minor python.version}";
|
||||
in ''
|
||||
export BOOST_PYTHON_LIB="boost_python${pythonVersion}"
|
||||
export BOOST_THREAD_LIB="boost_thread"
|
||||
export BOOST_SYSTEM_LIB="boost_system"
|
||||
'';
|
||||
buildInputs = with pkgs; [
|
||||
(boost.override {
|
||||
enablePython = true;
|
||||
inherit python;
|
||||
})
|
||||
(mapnik.override {
|
||||
inherit python;
|
||||
boost = (boost.override { enablePython = true; inherit python; });
|
||||
})
|
||||
cairo
|
||||
harfbuzz
|
||||
icu
|
||||
libjpeg
|
||||
libpng
|
||||
libtiff
|
||||
libwebp
|
||||
proj
|
||||
zlib
|
||||
];
|
||||
propagatedBuildInputs = with self; [ pillow pycairo ];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "Python bindings for Mapnik";
|
||||
homepage = http://mapnik.org;
|
||||
license = licenses.lgpl21;
|
||||
};
|
||||
};
|
||||
python-mapnik = callPackage ../development/python-modules/python-mapnik { };
|
||||
|
||||
misaka = callPackage ../development/python-modules/misaka {};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user