ansible-later: 2.0.22 -> 2.0.23
[NixPkgs.git] / pkgs / development / python-modules / python-mapnik / default.nix
blob2d888518ff4541be3cc79d18828889b52c5009b4
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , isPyPy
5 , python
6 , pillow
7 , pycairo
8 , pkg-config
9 , boost
10 , cairo
11 , harfbuzz
12 , icu
13 , libjpeg
14 , libpng
15 , libtiff
16 , libwebp
17 , mapnik
18 , proj
19 , zlib
22 buildPythonPackage rec {
23   pname = "python-mapnik";
24   version = "unstable-2020-02-24";
26   src = fetchFromGitHub {
27     owner = "mapnik";
28     repo = "python-mapnik";
29     rev = "7da019cf9eb12af8f8aa88b7d75789dfcd1e901b";
30     sha256 = "0snn7q7w1ab90311q8wgd1z64kw1svm5w831q0xd6glqhah86qc8";
31   };
33   disabled = isPyPy;
34   doCheck = false; # doesn't find needed test data files
35   preBuild = ''
36     export BOOST_PYTHON_LIB="boost_python${"${lib.versions.major python.version}${lib.versions.minor python.version}"}"
37     export BOOST_THREAD_LIB="boost_thread"
38     export BOOST_SYSTEM_LIB="boost_system"
39     export PYCAIRO=true
40   '';
42   nativeBuildInputs = [
43     mapnik # for mapnik_config
44     pkg-config
45   ];
47   patches = [
48     ./find-pycairo-with-pkg-config.patch
49   ];
51   buildInputs = [
52     mapnik
53     boost
54     cairo
55     harfbuzz
56     icu
57     libjpeg
58     libpng
59     libtiff
60     libwebp
61     proj
62     zlib
63   ];
65   propagatedBuildInputs = [ pillow pycairo ];
67   pythonImportsCheck = [ "mapnik" ];
69   meta = with lib; {
70     description = "Python bindings for Mapnik";
71     maintainers = with maintainers; [ erictapen ];
72     homepage = "https://mapnik.org";
73     license = licenses.lgpl21;
74   };