mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-31 09:14:28 +00:00
qgis-ltr: 3.28.15 -> 3.34.4
This commit is contained in:
parent
453b69da7a
commit
825b40b8c6
@ -1,59 +0,0 @@
|
||||
diff --git a/cmake/FindPyQt5.cmake b/cmake/FindPyQt5.cmake
|
||||
index b51fd0075e..87ee317e05 100644
|
||||
--- a/cmake/FindPyQt5.cmake
|
||||
+++ b/cmake/FindPyQt5.cmake
|
||||
@@ -25,7 +25,7 @@ ELSE(EXISTS PYQT5_VERSION_STR)
|
||||
IF(SIP_BUILD_EXECUTABLE)
|
||||
# SIP >= 5.0 path
|
||||
|
||||
- FILE(GLOB _pyqt5_metadata "${Python_SITEARCH}/PyQt5-*.dist-info/METADATA")
|
||||
+ FILE(GLOB _pyqt5_metadata "@pyQt5PackageDir@/PyQt5-*.dist-info/METADATA")
|
||||
IF(_pyqt5_metadata)
|
||||
FILE(READ ${_pyqt5_metadata} _pyqt5_metadata_contents)
|
||||
STRING(REGEX REPLACE ".*\nVersion: ([^\n]+).*$" "\\1" PYQT5_VERSION_STR ${_pyqt5_metadata_contents})
|
||||
@@ -34,8 +34,8 @@ ELSE(EXISTS PYQT5_VERSION_STR)
|
||||
ENDIF(_pyqt5_metadata)
|
||||
|
||||
IF(PYQT5_VERSION_STR)
|
||||
- SET(PYQT5_MOD_DIR "${Python_SITEARCH}/PyQt5")
|
||||
- SET(PYQT5_SIP_DIR "${Python_SITEARCH}/PyQt5/bindings")
|
||||
+ SET(PYQT5_MOD_DIR "@pyQt5PackageDir@/PyQt5")
|
||||
+ SET(PYQT5_SIP_DIR "@pyQt5PackageDir@/PyQt5/bindings")
|
||||
FIND_PROGRAM(__pyuic5 "pyuic5")
|
||||
GET_FILENAME_COMPONENT(PYQT5_BIN_DIR ${__pyuic5} DIRECTORY)
|
||||
|
||||
diff --git a/cmake/FindQsci.cmake b/cmake/FindQsci.cmake
|
||||
index 69e41c1fe9..5456c3d59b 100644
|
||||
--- a/cmake/FindQsci.cmake
|
||||
+++ b/cmake/FindQsci.cmake
|
||||
@@ -24,7 +24,7 @@ ELSE(QSCI_MOD_VERSION_STR)
|
||||
IF(SIP_BUILD_EXECUTABLE)
|
||||
# SIP >= 5.0 path
|
||||
|
||||
- FILE(GLOB _qsci_metadata "${Python_SITEARCH}/QScintilla*.dist-info/METADATA")
|
||||
+ FILE(GLOB _qsci_metadata "@qsciPackageDir@/QScintilla*.dist-info/METADATA")
|
||||
IF(_qsci_metadata)
|
||||
FILE(READ ${_qsci_metadata} _qsci_metadata_contents)
|
||||
STRING(REGEX REPLACE ".*\nVersion: ([^\n]+).*$" "\\1" QSCI_MOD_VERSION_STR ${_qsci_metadata_contents})
|
||||
@@ -33,7 +33,7 @@ ELSE(QSCI_MOD_VERSION_STR)
|
||||
ENDIF(_qsci_metadata)
|
||||
|
||||
IF(QSCI_MOD_VERSION_STR)
|
||||
- SET(QSCI_SIP_DIR "${PYQT5_SIP_DIR}")
|
||||
+ SET(QSCI_SIP_DIR "@qsciPackageDir@/PyQt5/bindings")
|
||||
SET(QSCI_FOUND TRUE)
|
||||
ENDIF(QSCI_MOD_VERSION_STR)
|
||||
|
||||
diff --git a/python/CMakeLists.txt b/python/CMakeLists.txt
|
||||
index 4cd19c3af4..668cc6a5e6 100644
|
||||
--- a/python/CMakeLists.txt
|
||||
+++ b/python/CMakeLists.txt
|
||||
@@ -206,7 +206,7 @@ if (WITH_GUI)
|
||||
install(FILES ${QGIS_PYTHON_OUTPUT_DIRECTORY}/_gui.pyi DESTINATION ${QGIS_PYTHON_DIR})
|
||||
endif()
|
||||
if(QSCI_SIP_DIR)
|
||||
- set(SIP_EXTRA_OPTIONS ${SIP_EXTRA_OPTIONS} -I ${QSCI_SIP_DIR})
|
||||
+ set(SIP_BUILD_EXTRA_OPTIONS ${SIP_BUILD_EXTRA_OPTIONS} --include-dir=${QSCI_SIP_DIR})
|
||||
else()
|
||||
message(STATUS "Qsci sip file not found - disabling bindings for derived classes")
|
||||
set(SIP_DISABLE_FEATURES ${SIP_DISABLE_FEATURES} HAVE_QSCI_SIP)
|
@ -1,17 +1,17 @@
|
||||
{ lib
|
||||
, callPackage
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, makeWrapper
|
||||
, mkDerivation
|
||||
, substituteAll
|
||||
, wrapGAppsHook
|
||||
, wrapQtAppsHook
|
||||
|
||||
, withGrass ? true
|
||||
, withWebKit ? false
|
||||
|
||||
, bison
|
||||
, cmake
|
||||
, draco
|
||||
, exiv2
|
||||
, fcgi
|
||||
, flex
|
||||
@ -25,7 +25,7 @@
|
||||
, netcdf
|
||||
, ninja
|
||||
, openssl
|
||||
# , pdal
|
||||
, pdal
|
||||
, postgresql
|
||||
, proj
|
||||
, protobuf
|
||||
@ -36,6 +36,7 @@
|
||||
, qtbase
|
||||
, qtkeychain
|
||||
, qtlocation
|
||||
, qtmultimedia
|
||||
, qtsensors
|
||||
, qtserialport
|
||||
, qtwebkit
|
||||
@ -63,8 +64,8 @@ let
|
||||
owslib
|
||||
psycopg2
|
||||
pygments
|
||||
pyqt-builder
|
||||
pyqt5
|
||||
pyqt-builder
|
||||
python-dateutil
|
||||
pytz
|
||||
pyyaml
|
||||
@ -76,14 +77,14 @@ let
|
||||
urllib3
|
||||
];
|
||||
in mkDerivation rec {
|
||||
version = "3.28.15";
|
||||
version = "3.34.4";
|
||||
pname = "qgis-ltr-unwrapped";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "qgis";
|
||||
repo = "QGIS";
|
||||
rev = "final-${lib.replaceStrings [ "." ] [ "_" ] version}";
|
||||
hash = "sha256-R6p1MVeCMbaD74Eqn+OLQkTYP+00y9mBucJR1JXPEJ4=";
|
||||
hash = "sha256-yEltpPhNFT/XB1EB5FvhCKcP0YY4j/q7luhd1mI0ZJU=";
|
||||
};
|
||||
|
||||
passthru = {
|
||||
@ -94,6 +95,7 @@ in mkDerivation rec {
|
||||
nativeBuildInputs = [
|
||||
makeWrapper
|
||||
wrapGAppsHook
|
||||
wrapQtAppsHook
|
||||
|
||||
bison
|
||||
cmake
|
||||
@ -102,32 +104,34 @@ in mkDerivation rec {
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
openssl
|
||||
proj
|
||||
geos
|
||||
sqlite
|
||||
gsl
|
||||
qwt
|
||||
draco
|
||||
exiv2
|
||||
protobuf
|
||||
fcgi
|
||||
geos
|
||||
gsl
|
||||
hdf5
|
||||
libspatialindex
|
||||
libspatialite
|
||||
postgresql
|
||||
txt2tags
|
||||
libzip
|
||||
hdf5
|
||||
netcdf
|
||||
qtbase
|
||||
qtsensors
|
||||
openssl
|
||||
pdal
|
||||
postgresql
|
||||
proj
|
||||
protobuf
|
||||
qca-qt5
|
||||
qtkeychain
|
||||
qscintilla
|
||||
qt3d
|
||||
qtbase
|
||||
qtkeychain
|
||||
qtlocation
|
||||
qtmultimedia
|
||||
qtsensors
|
||||
qtserialport
|
||||
qtxmlpatterns
|
||||
qt3d
|
||||
# pdal
|
||||
qwt
|
||||
sqlite
|
||||
txt2tags
|
||||
zstd
|
||||
] ++ lib.optional withGrass grass
|
||||
++ lib.optional withWebKit qtwebkit
|
||||
@ -135,22 +139,22 @@ in mkDerivation rec {
|
||||
|
||||
patches = [
|
||||
(substituteAll {
|
||||
src = ./set-pyqt-package-dirs-ltr.patch;
|
||||
src = ./set-pyqt-package-dirs.patch;
|
||||
pyQt5PackageDir = "${py.pkgs.pyqt5}/${py.pkgs.python.sitePackages}";
|
||||
qsciPackageDir = "${py.pkgs.qscintilla-qt5}/${py.pkgs.python.sitePackages}";
|
||||
})
|
||||
(fetchpatch {
|
||||
name = "qgis-3.28.9-exiv2-0.28.patch";
|
||||
url = "https://gitweb.gentoo.org/repo/gentoo.git/plain/sci-geosciences/qgis/files/qgis-3.28.9-exiv2-0.28.patch?id=002882203ad6a2b08ce035a18b95844a9f4b85d0";
|
||||
hash = "sha256-mPRo0A7ko4GCHJrfJ2Ls0dUKvkFtDmhKekI2CR9StMw=";
|
||||
})
|
||||
];
|
||||
|
||||
# PDAL is disabled until https://github.com/qgis/QGIS/pull/54940
|
||||
# is backported.
|
||||
# Add path to Qt platform plugins
|
||||
# (offscreen is needed by "${APIS_SRC_DIR}/generate_console_pap.py")
|
||||
preBuild = ''
|
||||
export QT_QPA_PLATFORM_PLUGIN_PATH=${qtbase.bin}/lib/qt-${qtbase.version}/plugins/platforms
|
||||
'';
|
||||
|
||||
cmakeFlags = [
|
||||
"-DCMAKE_BUILD_TYPE=Release"
|
||||
"-DWITH_3D=True"
|
||||
"-DWITH_PDAL=False" # TODO: re-enable PDAL
|
||||
"-DWITH_PDAL=True"
|
||||
"-DENABLE_TESTS=False"
|
||||
] ++ lib.optional (!withWebKit) "-DWITH_QTWEBKIT=OFF"
|
||||
++ lib.optional withGrass (let
|
||||
@ -159,6 +163,10 @@ in mkDerivation rec {
|
||||
in "-DGRASS_PREFIX${gmajor}=${grass}/grass${gmajor}${gminor}"
|
||||
);
|
||||
|
||||
qtWrapperArgs = [
|
||||
"--set QT_QPA_PLATFORM_PLUGIN_PATH ${qtbase.bin}/lib/qt-${qtbase.version}/plugins/platforms"
|
||||
];
|
||||
|
||||
dontWrapGApps = true; # wrapper params passed below
|
||||
|
||||
postFixup = lib.optionalString withGrass ''
|
||||
|
Loading…
Reference in New Issue
Block a user