git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #138479 from dotlambda/proj-8.1.1

proj: 7.2.1 -> 8.1.1

commit54e1db21522a61ca771aeafbbd77c4a474e82f8e authorRobert Schütz <nix@dotlambda.de> dateMon 27 Sep 2021, 16:46 (5 years ago) parentd0e4e9b7d38eec
13 files changed+226−88
pkgs/applications/gis/qgis/unwrapped.nix+47−8 pkgs/applications/misc/osm2xmap/default.nix+3−3 pkgs/applications/misc/survex/default.nix+2−2 pkgs/applications/misc/xygrib/default.nix+2−2 pkgs/applications/science/misc/gplates/default.nix+54−16 pkgs/development/libraries/mapnik/default.nix+2 pkgs/development/libraries/proj/7.nix+58 pkgs/development/libraries/proj/default.nix+5−22 pkgs/development/python-modules/cartopy/default.nix+9−2 pkgs/development/python-modules/geopandas/default.nix+14−1 pkgs/development/python-modules/pyproj/001.proj.patch+17−25 pkgs/development/python-modules/pyproj/default.nix+2−2 pkgs/top-level/all-packages.nix+11−5
pkgs/applications/gis/qgis/unwrapped.nix+47−8
@@ -1,9 +1,42 @@
1−{ mkDerivation, lib, fetchFromGitHub, cmake, ninja, flex, bison, proj, geos
2−, xlibsWrapper, sqlite, gsl, qwt, fcgi, python3Packages, libspatialindex
3−, libspatialite, postgresql, txt2tags, openssl, libzip, hdf5, netcdf, exiv2
4−, protobuf, qtbase, qtsensors, qca-qt5, qtkeychain, qscintilla, qtserialport
5−, qtxmlpatterns, withGrass ? true, grass, withWebKit ? true, qtwebkit }:
6−with lib;
1+{ lib
2+, mkDerivation
3+, fetchFromGitHub
4+, fetchpatch
5+, cmake
6+, ninja
7+, flex
8+, bison
9+, proj
10+, geos
11+, xlibsWrapper
12+, sqlite
13+, gsl
14+, qwt
15+, fcgi
16+, python3Packages
17+, libspatialindex
18+, libspatialite
19+, postgresql
20+, txt2tags
21+, openssl
22+, libzip
23+, hdf5
24+, netcdf
25+, exiv2
26+, protobuf
27+, qtbase
28+, qtsensors
29+, qca-qt5
30+, qtkeychain
31+, qscintilla
32+, qtserialport
33+, qtxmlpatterns
34+, withGrass ? true
35+, grass
36+, withWebKit ? true
37+, qtwebkit
38+}:
39+
740let
841 pythonBuildInputs = with python3Packages; [
942 qscintilla-qt5
@@ -25,8 +58,7 @@ let
2558 ];
2659in mkDerivation rec {
2760 version = "3.16.10";
28− pname = "qgis";
29− name = "${pname}-unwrapped-${version}";
61+ pname = "qgis-unwrapped";
3062
3163 src = fetchFromGitHub {
3264 owner = "qgis";
@@ -35,6 +67,13 @@ in mkDerivation rec {
3567 sha256 = "sha256-/lsfyTDlkZNIVHg5qgZW7qfOyTC2+1r3ZbsnQmEdy30=";
3668 };
3769
70+ patches = [
71+ (fetchpatch {
72+ url = "https://github.com/qgis/QGIS/commit/fc1ac8bef8dcc3194857ecd32519aca4867b4fa1.patch";
73+ sha256 = "106smg3drx8c7yxzfhd1c7xrq757l5cfxx8lklihyvr4a7wc9gpy";
74+ })
75+ ];
76+
3877 passthru = {
3978 inherit pythonBuildInputs;
4079 inherit python3Packages;
pkgs/applications/misc/osm2xmap/default.nix+3−3
@@ -1,4 +1,4 @@
1−{ lib, stdenv, fetchFromGitHub, libroxml, proj, libyamlcpp, boost } :
1+{ lib, stdenv, fetchFromGitHub, libroxml, proj_7, libyamlcpp, boost } :
22
33stdenv.mkDerivation rec {
44 pname = "osm2xmap";
@@ -14,14 +14,14 @@ stdenv.mkDerivation rec {
1414 makeFlags = [
1515 "GIT_VERSION=${version}"
1616 "GIT_TIMESTAMP="
17− "SHAREDIR=${placeholder "out"}/share/osm2xmap"
17+ "SHAREDIR=${placeholder "out"}/share/osm2xmap/"
1818 "INSTALL_BINDIR=${placeholder "out"}/bin"
1919 "INSTALL_MANDIR=${placeholder "out"}/share/man/man1"
2020 ];
2121
2222 NIX_CFLAGS_COMPILE = "-DACCEPT_USE_OF_DEPRECATED_PROJ_API_H";
2323
24− buildInputs = [ libroxml proj libyamlcpp boost ];
24+ buildInputs = [ libroxml proj_7 libyamlcpp boost ];
2525
2626 meta = with lib; {
2727 homepage = "https://github.com/sembruk/osm2xmap";
pkgs/applications/misc/survex/default.nix+2−2
@@ -6,7 +6,7 @@
66, wxGTK30-gtk3
77, wxmac
88, ffmpeg
9−, proj
9+, proj_7
1010, perl532
1111, unscii
1212, python
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
2929 nativeBuildInputs = [ docbook5 docbook2x autoreconfHook pkg-config perlenv python ];
3030
3131 buildInputs = [
32− libGL libGLU ffmpeg proj
32+ libGL libGLU ffmpeg proj_7
3333 ] ++ lib.optionals stdenv.hostPlatform.isDarwin [
3434 wxmac Carbon Cocoa
3535 ] ++ lib.optionals stdenv.hostPlatform.isLinux [
pkgs/applications/misc/xygrib/default.nix+2−2
@@ -1,4 +1,4 @@
1−{ lib, stdenv, fetchFromGitHub, wrapQtAppsHook, cmake, bzip2, qtbase, qttools, libnova, proj, libpng, openjpeg }:
1+{ lib, stdenv, fetchFromGitHub, wrapQtAppsHook, cmake, bzip2, qtbase, qttools, libnova, proj_7, libpng, openjpeg }:
22
33stdenv.mkDerivation rec {
44 version = "1.2.6.1";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
1212 };
1313
1414 nativeBuildInputs = [ cmake qttools wrapQtAppsHook ];
15− buildInputs = [ bzip2 qtbase libnova proj openjpeg libpng ];
15+ buildInputs = [ bzip2 qtbase libnova proj_7 openjpeg libpng ];
1616 cmakeFlags = [ "-DOPENJPEG_INCLUDE_DIR=${openjpeg.dev}/include/openjpeg-${lib.versions.majorMinor openjpeg.version}" ]
1717 ++ lib.optionals stdenv.isDarwin [ "-DLIBNOVA_LIBRARY=${libnova}/lib/libnova.dylib" ];
1818
pkgs/applications/science/misc/gplates/default.nix+54−16
@@ -1,31 +1,69 @@
1−{ lib, stdenv, fetchurl, qt4, qwt6_qt4, libGLU, libGL, glew, gdal, cgal
2−, proj, boost, cmake, python2, doxygen, graphviz, gmp, mpfr }:
1+{ lib
2+, mkDerivation
3+, fetchurl
4+, cmake
5+, doxygen
6+, graphviz
7+, boost
8+, cgal_5
9+, gdal
10+, glew
11+, gmp
12+, libGL
13+, libGLU
14+, mpfr
15+, proj
16+, python3
17+, qtxmlpatterns
18+, qwt
19+}:
320
4−stdenv.mkDerivation rec {
21+let
22+ python = python3.withPackages (ps: with ps; [
23+ numpy
24+ ]);
25+ boost' = boost.override {
26+ enablePython = true;
27+ inherit python;
28+ };
29+ cgal = cgal_5.override {
30+ boost = boost';
31+ };
32+in mkDerivation rec {
533 pname = "gplates";
6− version = "2.2.0";
34+ version = "2.3.0";
735
836 src = fetchurl {
9− url = "mirror://sourceforge/gplates/${pname}-${version}-unixsrc.tar.bz2";
10− sha256 = "1jrcv498vpcs8xklhbsgg12yfa90f96p2mwq6x5sjnrlpf8mh50b";
37+ name = "gplates_${version}_src.tar.bz2";
38+ url = "https://www.earthbyte.org/download/8421/?uid=b89bb31428";
39+ sha256 = "0lrcmcxc924ixddii8cyglqlwwxvk7f00g4yzbss5i3fgcbh8n96";
1140 };
1241
13− nativeBuildInputs = [ cmake ];
14− buildInputs = [
15− qt4 qwt6_qt4 libGLU libGL glew gdal cgal proj python2
16− doxygen graphviz gmp mpfr
17− (boost.override {
18− enablePython = true;
19− python = python2;
20− })
42+ nativeBuildInputs = [
43+ cmake
44+ doxygen
45+ graphviz
2146 ];
2247
23− NIX_CFLAGS_LINK="-ldl -lpthread -lutil";
48+ buildInputs = [
49+ boost'
50+ cgal
51+ gdal
52+ glew
53+ gmp
54+ libGL
55+ libGLU
56+ mpfr
57+ proj
58+ python
59+ qtxmlpatterns
60+ qwt
61+ ];
2462
2563 meta = with lib; {
2664 description = "Desktop software for the interactive visualisation of plate-tectonics";
2765 homepage = "https://www.gplates.org";
28− license = licenses.gpl2;
66+ license = licenses.gpl2Only;
2967 platforms = platforms.all;
3068 };
3169}
pkgs/development/libraries/mapnik/default.nix+2
@@ -96,5 +96,7 @@ stdenv.mkDerivation rec {
9696 maintainers = with maintainers; [ hrdinka ];
9797 license = licenses.lgpl21;
9898 platforms = platforms.all;
99+ # https://github.com/mapnik/mapnik/issues/4232
100+ broken = lib.versionAtLeast proj.version "8.0.0";
99101 };
100102}
pkgs/development/libraries/proj/7.nixnew file+58
@@ -0,0 +1,58 @@
1+{ lib
2+, stdenv
3+, fetchFromGitHub
4+, cmake
5+, pkg-config
6+, sqlite
7+, libtiff
8+, curl
9+, gtest
10+, fetchpatch
11+}:
12+
13+stdenv.mkDerivation rec {
14+ pname = "proj";
15+ version = "7.2.1";
16+
17+ src = fetchFromGitHub {
18+ owner = "OSGeo";
19+ repo = "PROJ";
20+ rev = version;
21+ sha256 = "0mymvfvs8xggl4axvlj7kc1ksd9g94kaz6w1vdv0x2y5mqk93gx9";
22+ };
23+
24+ patches = [
25+ (fetchpatch { # https://github.com/OSGeo/PROJ/issues/2557
26+ name = "gie_self_tests-fail.diff"; # included in >= 8.0.1
27+ url = "https://github.com/OSGeo/PROJ/commit/6f1a3c4648bf06862dca0b3725cbb3b7ee0284e3.diff";
28+ sha256 = "0gapny0a9c3r0x9szjgn86sspjrrf4vwbija77b17w6ci5cq4pdf";
29+ })
30+ ];
31+
32+ postPatch = lib.optionalString (version == "7.2.1") ''
33+ substituteInPlace CMakeLists.txt \
34+ --replace "MAJOR 7 MINOR 2 PATCH 0" "MAJOR 7 MINOR 2 PATCH 1"
35+ '';
36+
37+ outputs = [ "out" "dev"];
38+
39+ nativeBuildInputs = [ cmake pkg-config ];
40+
41+ buildInputs = [ sqlite libtiff curl ];
42+
43+ checkInputs = [ gtest ];
44+
45+ cmakeFlags = [
46+ "-DUSE_EXTERNAL_GTEST=ON"
47+ ];
48+
49+ doCheck = true;
50+
51+ meta = with lib; {
52+ description = "Cartographic Projections Library";
53+ homepage = "https://proj4.org";
54+ license = licenses.mit;
55+ platforms = platforms.unix;
56+ maintainers = with maintainers; [ vbgl dotlambda ];
57+ };
58+}
pkgs/development/libraries/proj/default.nix+5−22
@@ -7,33 +7,19 @@
77, libtiff
88, curl
99, gtest
10−, fetchpatch
1110}:
1211
1312stdenv.mkDerivation rec {
1413 pname = "proj";
15− version = "7.2.1";
14+ version = "8.1.1";
1615
1716 src = fetchFromGitHub {
1817 owner = "OSGeo";
1918 repo = "PROJ";
2019 rev = version;
21− sha256 = "0mymvfvs8xggl4axvlj7kc1ksd9g94kaz6w1vdv0x2y5mqk93gx9";
20+ sha256 = "sha256-Z2nruyowC3NG4Wb8AFBL0PME/zp9D7SwQdMSl6VjH/w=";
2221 };
2322
24− patches = [
25− (fetchpatch { # https://github.com/OSGeo/PROJ/issues/2557
26− name = "gie_self_tests-fail.diff"; # included in >= 8.0.1
27− url = "https://github.com/OSGeo/PROJ/commit/6f1a3c4648bf06862dca0b3725cbb3b7ee0284e3.diff";
28− sha256 = "0gapny0a9c3r0x9szjgn86sspjrrf4vwbija77b17w6ci5cq4pdf";
29− })
30− ];
31−
32− postPatch = lib.optionalString (version == "7.2.1") ''
33− substituteInPlace CMakeLists.txt \
34− --replace "MAJOR 7 MINOR 2 PATCH 0" "MAJOR 7 MINOR 2 PATCH 1"
35− '';
36−
3723 outputs = [ "out" "dev"];
3824
3925 nativeBuildInputs = [ cmake pkg-config ];
@@ -44,17 +30,14 @@ stdenv.mkDerivation rec {
4430
4531 cmakeFlags = [
4632 "-DUSE_EXTERNAL_GTEST=ON"
33+ "-DRUN_NETWORK_DEPENDENT_TESTS=OFF"
4734 ];
4835
49− doCheck = stdenv.is64bit;
50−
51− preCheck = ''
52− export HOME=$TMPDIR
53− '';
36+ doCheck = true;
5437
5538 meta = with lib; {
5639 description = "Cartographic Projections Library";
57− homepage = "https://proj4.org";
40+ homepage = "https://proj.org/";
5841 license = licenses.mit;
5942 platforms = platforms.unix;
6043 maintainers = with maintainers; [ vbgl dotlambda ];
pkgs/development/python-modules/cartopy/default.nix+9−2
@@ -8,14 +8,21 @@
88
99buildPythonPackage rec {
1010 pname = "cartopy";
11− version = "0.19.0.post1";
11+ version = "0.20.0";
1212
1313 src = fetchPypi {
1414 inherit version;
1515 pname = "Cartopy";
16− sha256 = "0xnm8z3as3hriivdfd26s6vn5b63gb46x6vxw6gh1mwfm5rlg2sb";
16+ sha256 = "eae58aff26806e63cf115b2bce9477cedc4aa9f578c5e477b2c25cfa404f2b7a";
1717 };
1818
19+ postPatch = ''
20+ # https://github.com/SciTools/cartopy/issues/1880
21+ substituteInPlace lib/cartopy/tests/test_crs.py \
22+ --replace "test_osgb(" "dont_test_osgb(" \
23+ --replace "test_epsg(" "dont_test_epsg("
24+ '';
25+
1926 buildInputs = [
2027 geos proj
2128 ];
pkgs/development/python-modules/geopandas/default.nix+14−1
@@ -1,4 +1,4 @@
1−{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
1+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, fetchpatch, pythonOlder
22, pandas, shapely, fiona, pyproj
33, pytestCheckHook, Rtree }:
44
@@ -14,6 +14,19 @@ buildPythonPackage rec {
1414 sha256 = "sha256-58X562OkRzZ4UTNMTwXW4U5czoa5tbSMBCcE90DqbaE=";
1515 };
1616
17+ patches = [
18+ (fetchpatch {
19+ name = "skip-pandas-master-fillna-test.patch";
20+ url = "https://github.com/geopandas/geopandas/pull/1878.patch";
21+ sha256 = "1yw3i4dbhaq7f02n329b9y2cqxbwlz9db81mhgrfc7af3whwysdb";
22+ })
23+ (fetchpatch {
24+ name = "fix-proj4strings-test.patch";
25+ url = "https://github.com/geopandas/geopandas/pull/1958.patch";
26+ sha256 = "0kzmpq5ry87yvhqr6gnh9p2606b06d3ynzjvw0hpp9fncczpc2yn";
27+ })
28+ ];
29+
1730 propagatedBuildInputs = [
1831 pandas
1932 shapely
pkgs/development/python-modules/pyproj/001.proj.patch+17−25
@@ -1,19 +1,21 @@
1−diff -Nur a/pyproj/datadir.py b/pyproj/datadir.py
2−--- a/pyproj/datadir.py 2021-04-10 18:26:52.829018483 +0100
3−+++ b/pyproj/datadir.py 2021-04-10 18:44:59.155190614 +0100
4−@@ -70,7 +70,7 @@
1+diff --git a/pyproj/datadir.py b/pyproj/datadir.py
2+index 9ca1d25..4198490 100644
3+--- a/pyproj/datadir.py
4++++ b/pyproj/datadir.py
5+@@ -70,7 +70,7 @@ def get_data_dir() -> str:
6+ global _VALIDATED_PROJ_DATA
57 if _VALIDATED_PROJ_DATA is not None:
68 return _VALIDATED_PROJ_DATA
7− global _USER_PROJ_DATA
89- internal_datadir = Path(__file__).absolute().parent / "proj_dir" / "share" / "proj"
910+ internal_datadir = Path("@proj@/share/proj")
1011 proj_lib_dirs = os.environ.get("PROJ_LIB", "")
1112 prefix_datadir = Path(sys.prefix, "share", "proj")
1213
13−diff -Nur a/setup.py b/setup.py
14−--- a/setup.py 2021-04-10 18:26:52.817018512 +0100
15−+++ b/setup.py 2021-04-10 18:46:01.652324424 +0100
16−@@ -11,7 +11,7 @@
14+diff --git a/setup.py b/setup.py
15+index 6bb0c6c..b3d0321 100644
16+--- a/setup.py
17++++ b/setup.py
18+@@ -12,7 +12,7 @@ from setuptools import Extension, setup
1719 PROJ_MIN_VERSION = parse_version("7.2.0")
1820 CURRENT_FILE_PATH = Path(__file__).absolute().parent
1921 BASE_INTERNAL_PROJ_DIR = Path("proj_dir")
@@ -22,7 +24,7 @@ diff -Nur a/setup.py b/setup.py
2224
2325
2426 def get_proj_version(proj_dir: Path) -> str:
25−@@ -150,7 +150,7 @@
27+@@ -155,7 +155,7 @@ def get_extension_modules():
2628 # By default we'll try to get options PROJ_DIR or the local version of proj
2729 proj_dir = get_proj_dir()
2830 library_dirs = get_proj_libdirs(proj_dir)
@@ -31,21 +33,11 @@ diff -Nur a/setup.py b/setup.py
3133
3234 proj_version = get_proj_version(proj_dir)
3335 check_proj_version(proj_version)
34−diff -Nur a/test/conftest.py b/test/conftest.py
35−--- a/test/conftest.py 2021-04-10 18:26:52.831018478 +0100
36−+++ b/test/conftest.py 2021-04-10 18:37:01.605682432 +0100
37−@@ -2,6 +2,7 @@
38− from contextlib import contextmanager
39− from distutils.version import LooseVersion
40− from pathlib import Path
41−+import stat
42−
43− import pyproj
44− from pyproj.datadir import get_data_dir, get_user_data_dir, set_data_dir
45−diff -Nur a/test/test_cli.py b/test/test_cli.py
46−--- a/test/test_cli.py 2021-04-10 18:26:52.831018478 +0100
47−+++ b/test/test_cli.py 2021-04-10 22:17:04.665088162 +0100
48−@@ -14,7 +14,7 @@
36+diff --git a/test/test_cli.py b/test/test_cli.py
37+index 7a696de..1b9b777 100644
38+--- a/test/test_cli.py
39++++ b/test/test_cli.py
40+@@ -14,7 +14,7 @@ from pyproj.sync import _load_grid_geojson
4941 from test.conftest import grids_available, proj_env, tmp_chdir
5042
5143 PYPROJ_CLI_ENDPONTS = pytest.mark.parametrize(
pkgs/development/python-modules/pyproj/default.nix+2−2
@@ -17,14 +17,14 @@
1717
1818buildPythonPackage rec {
1919 pname = "pyproj";
20− version = "3.1.0";
20+ version = "3.2.1";
2121 disabled = pythonOlder "3.7";
2222
2323 src = fetchFromGitHub {
2424 owner = "pyproj4";
2525 repo = "pyproj";
2626 rev = version;
27− sha256 = "sha256-UN8cJk5Lgd+d2tKmFuF6QvKr36w1435RKovzGfMXi1E=";
27+ sha256 = "sha256-r343TvXpSr+EMAbvzSUpsfipwP8TFmitOfT0gjgoO00=";
2828 };
2929
3030 # force pyproj to use ${proj}
pkgs/top-level/all-packages.nix+11−5
@@ -18545,6 +18545,8 @@ with pkgs;
1854518545
1854618546 proj = callPackage ../development/libraries/proj { };
1854718547
18548+ proj_7 = callPackage ../development/libraries/proj/7.nix { };
18549+
1854818550 proj-datumgrid = callPackage ../development/libraries/proj-datumgrid { };
1854918551
1855018552 proselint = callPackage ../tools/text/proselint {
@@ -26957,7 +26959,14 @@ with pkgs;
2695726959
2695826960 qimgv = libsForQt5.callPackage ../applications/graphics/qimgv { };
2695926961
26960− qlandkartegt = libsForQt514.callPackage ../applications/misc/qlandkartegt {};
26962+ qlandkartegt = libsForQt514.callPackage ../applications/misc/qlandkartegt {
26963+ gdal = gdal.override {
26964+ libgeotiff = libgeotiff.override { proj = proj_7; };
26965+ libspatialite = libspatialite.override { proj = proj_7; };
26966+ proj = proj_7;
26967+ };
26968+ proj = proj_7;
26969+ };
2696126970
2696226971 garmindev = callPackage ../applications/misc/qlandkartegt/garmindev.nix {};
2696326972
@@ -31121,10 +31130,7 @@ with pkgs;
3112131130
3112231131 gildas = callPackage ../applications/science/astronomy/gildas { };
3112331132
31124− gplates = callPackage ../applications/science/misc/gplates {
31125− boost = boost160;
31126− cgal = cgal.override { boost = boost160; };
31127− };
31133+ gplates = libsForQt5.callPackage ../applications/science/misc/gplates { };
3112831134
3112931135 gravit = callPackage ../applications/science/astronomy/gravit { };
3113031136