qgis: 3.10.13 -> 3.16.5

The file has been reformated using nixpkgs-fmt.
This commit is contained in:
Lancelot SIX 2021-04-13 21:50:04 +01:00 committed by tomberek
parent 5268ee2eba
commit f8da9ce9fc

View File

@ -1,25 +1,38 @@
{ mkDerivation, lib, fetchFromGitHub, cmake, ninja, flex, bison, proj, geos, xlibsWrapper, sqlite, gsl { mkDerivation, lib, fetchFromGitHub, cmake, ninja, flex, bison, proj, geos
, qwt, fcgi, python3Packages, libspatialindex, libspatialite, postgresql , xlibsWrapper, sqlite, gsl, qwt, fcgi, python3Packages, libspatialindex
, txt2tags, openssl, libzip, hdf5, netcdf, exiv2 , libspatialite, postgresql, txt2tags, openssl, libzip, hdf5, netcdf, exiv2
, qtbase, qtsensors, qca-qt5, qtkeychain, qscintilla, qtserialport, qtxmlpatterns , protobuf, qtbase, qtsensors, qca-qt5, qtkeychain, qscintilla, qtserialport
, withGrass ? true, grass , qtxmlpatterns, withGrass ? true, grass, withWebKit ? true, qtwebkit }:
, withWebKit ? true, qtwebkit
}:
with lib; with lib;
let let
pythonBuildInputs = with python3Packages; pythonBuildInputs = with python3Packages; [
[ qscintilla-qt5 gdal jinja2 numpy psycopg2 qscintilla-qt5
chardet dateutil pyyaml pytz requests urllib3 pygments pyqt5 sip owslib six ]; gdal
jinja2
numpy
psycopg2
chardet
dateutil
pyyaml
pytz
requests
urllib3
pygments
pyqt5
sip
owslib
six
];
in mkDerivation rec { in mkDerivation rec {
version = "3.10.13"; version = "3.16.5";
pname = "qgis"; pname = "qgis";
name = "${pname}-unwrapped-${version}"; name = "${pname}-unwrapped-${version}";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "qgis"; owner = "qgis";
repo = "QGIS"; repo = "QGIS";
rev = "final-${lib.replaceStrings ["."] ["_"] version}"; rev = "final-${lib.replaceStrings [ "." ] [ "_" ] version}";
sha256 = "0za77znk1phrxzy2cgxpwrld3d0pi0xvhsg78rg4wkb23vaqv6zb"; sha256 = "1xkvgj1v2jgp107jyh9xmk1dzbbqxwkqy69z56vsaa8lf9gwgn5h";
}; };
passthru = { passthru = {
@ -27,10 +40,32 @@ in mkDerivation rec {
inherit python3Packages; inherit python3Packages;
}; };
buildInputs = [ openssl proj geos xlibsWrapper sqlite gsl qwt exiv2 buildInputs = [
fcgi libspatialindex libspatialite postgresql txt2tags libzip hdf5 netcdf openssl
qtbase qtsensors qca-qt5 qtkeychain qscintilla qtserialport qtxmlpatterns ] proj
++ lib.optional withGrass grass geos
xlibsWrapper
sqlite
gsl
qwt
exiv2
protobuf
fcgi
libspatialindex
libspatialite
postgresql
txt2tags
libzip
hdf5
netcdf
qtbase
qtsensors
qca-qt5
qtkeychain
qscintilla
qtserialport
qtxmlpatterns
] ++ lib.optional withGrass grass
++ lib.optional withWebKit qtwebkit ++ lib.optional withWebKit qtwebkit
++ pythonBuildInputs; ++ pythonBuildInputs;
@ -41,15 +76,16 @@ in mkDerivation rec {
# TODO: Correct PyQt5 to provide the expected directory and fix # TODO: Correct PyQt5 to provide the expected directory and fix
# build to use PYQT5_SIP_DIR consistently. # build to use PYQT5_SIP_DIR consistently.
postPatch = '' postPatch = ''
substituteInPlace cmake/FindPyQt5.py \ substituteInPlace cmake/FindPyQt5.py \
--replace 'sip_dir = cfg.default_sip_dir' 'sip_dir = "${python3Packages.pyqt5}/share/sip/PyQt5"' --replace 'sip_dir = cfg.default_sip_dir' 'sip_dir = "${python3Packages.pyqt5}/share/sip/PyQt5"'
''; '';
cmakeFlags = [ "-DCMAKE_SKIP_BUILD_RPATH=OFF" cmakeFlags = [
"-DPYQT5_SIP_DIR=${python3Packages.pyqt5}/share/sip/PyQt5" "-DCMAKE_SKIP_BUILD_RPATH=OFF"
"-DQSCI_SIP_DIR=${python3Packages.qscintilla-qt5}/share/sip/PyQt5" ] "-DPYQT5_SIP_DIR=${python3Packages.pyqt5}/share/sip/PyQt5"
++ lib.optional (!withWebKit) "-DWITH_QTWEBKIT=OFF" "-DQSCI_SIP_DIR=${python3Packages.qscintilla-qt5}/share/sip/PyQt5"
++ lib.optional withGrass "-DGRASS_PREFIX7=${grass}/${grass.name}"; ] ++ lib.optional (!withWebKit) "-DWITH_QTWEBKIT=OFF"
++ lib.optional withGrass "-DGRASS_PREFIX7=${grass}/${grass.name}";
meta = { meta = {
description = "A Free and Open Source Geographic Information System"; description = "A Free and Open Source Geographic Information System";