gnu: qgis: Update to 3.26.2.

* gnu/packages/geo.scm (qgis): Update to 3.26.2.
  [native-inputs]: Add python-pyqt-builder.
  [inputs]: Add bash-minimal and zstd:lib.
  [arguments]: Update 'configure-pyqt5-sip-path' and 'check' phases. Remove
  trailing booleans.
This commit is contained in:
Guillaume Le Vaillant 2022-09-02 16:31:26 +02:00
parent 0f51eb2890
commit db2cd42178
No known key found for this signature in database
GPG key ID: 6BE8208ADF21FE3F

View file

@ -2377,14 +2377,14 @@ (define-public saga
(define-public qgis (define-public qgis
(package (package
(name "qgis") (name "qgis")
(version "3.16.3") (version "3.26.2")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
(uri (string-append "https://qgis.org/downloads/qgis-" (uri (string-append "https://qgis.org/downloads/qgis-"
version ".tar.bz2")) version ".tar.bz2"))
(sha256 (sha256
(base32 "012dv8dcg7w4lf6k37i41wialwhi0kpkxw2dnq19yqqk35632mzx")))) (base32 "1hsq3wchsf7db7134fgg9xzzap35q1s4r6649d0krbw80xw5asca"))))
(build-system cmake-build-system) (build-system cmake-build-system)
(arguments (arguments
`(#:modules ((guix build cmake-build-system) `(#:modules ((guix build cmake-build-system)
@ -2405,7 +2405,7 @@ (define-public qgis
(("sip_dir = cfg.default_sip_dir") (("sip_dir = cfg.default_sip_dir")
(string-append "sip_dir = \"" (string-append "sip_dir = \""
(assoc-ref inputs "python-pyqt+qscintilla") (assoc-ref inputs "python-pyqt+qscintilla")
"/share/sip\"")) "/share/sip\"")))
;; Fix building with python-sip@5. ;; Fix building with python-sip@5.
;; ;;
;; The reason for this is that python-sip@5 introduces some ;; The reason for this is that python-sip@5 introduces some
@ -2416,31 +2416,15 @@ (define-public qgis
;; are, messing up the build. The long term solution is to fully ;; are, messing up the build. The long term solution is to fully
;; upgrade SIP, use sip-build and fix all failing packages, but ;; upgrade SIP, use sip-build and fix all failing packages, but
;; for now I just want to get the build working. ;; for now I just want to get the build working.
((".pyqt_sip_dir...os.path.join.*,") (substitute* "cmake/FindPyQt5.cmake"
(string-append "'pyqt_sip_dir': \"" (("SET\\(PYQT5_SIP_DIR \"\\$\\{Python_SITEARCH\\}/PyQt5/bindings\"\\)")
(string-append "SET(PYQT5_SIP_DIR \""
(assoc-ref inputs "python-pyqt+qscintilla") (assoc-ref inputs "python-pyqt+qscintilla")
"/share/sip" "\","))) "/share/sip\")")))
(substitute* (list "scripts/prepare_commit.sh" (substitute* (list "tests/code_layout/test_qt_imports.sh"
"scripts/qstringfixup.sh" "tests/code_layout/test_qgsscrollarea.sh")
"scripts/release.pl"
"scripts/runtests_local_travis_config.sh"
"scripts/sip_include.sh"
"scripts/sipdiff"
"scripts/sipify_all.sh"
"scripts/spell_check/check_spelling.sh"
"scripts/spell_check/spell_test.sh"
"scripts/verify_indentation.sh"
"tests/code_layout/test_banned_keywords.sh"
"tests/code_layout/test_licenses.sh"
"tests/code_layout/test_shellcheck.sh"
"tests/code_layout/test_sip_include.sh"
"tests/code_layout/test_sipfiles.sh"
"tests/code_layout/test_sipify.sh")
(("\\$\\(git rev-parse --show-toplevel\\)") (("\\$\\(git rev-parse --show-toplevel\\)")
(getcwd))) (getcwd)))))
(substitute* "tests/code_layout/test_sip_include.sh"
(("^REV=.*") "REV=currentrev\n"))
#t))
(replace 'check (replace 'check
(lambda* (#:key inputs tests? #:allow-other-keys) (lambda* (#:key inputs tests? #:allow-other-keys)
(when tests? (when tests?
@ -2454,113 +2438,85 @@ (define-public qgis
'(;; Disable tests that require network access '(;; Disable tests that require network access
"qgis_filedownloader" "qgis_filedownloader"
;; TODO: Find why the following tests fail ;; TODO: Find why the following tests fail
"ProcessingGdalAlgorithmsRasterTest"
"ProcessingGdalAlgorithmsVectorTest"
"ProcessingGrass7AlgorithmsImageryTest"
"ProcessingGrass7AlgorithmsRasterTest"
"ProcessingGrass7AlgorithmsVectorTest"
"ProcessingOtbAlgorithmsTest"
"ProcessingQgisAlgorithmsTestPt1" "ProcessingQgisAlgorithmsTestPt1"
"ProcessingQgisAlgorithmsTestPt2" "ProcessingQgisAlgorithmsTestPt2"
"ProcessingQgisAlgorithmsTestPt3" "ProcessingQgisAlgorithmsTestPt3"
"ProcessingQgisAlgorithmsTestPt4" "ProcessingQgisAlgorithmsTestPt4"
"PyCoreAdittions" "ProcessingGdalAlgorithmsVectorTest"
"ProcessingGrass7AlgorithmsImageryTest"
"ProcessingGrass7AlgorithmsRasterTestPt1"
"ProcessingGrass7AlgorithmsRasterTestPt2"
"ProcessingGrass7AlgorithmsVectorTest"
"ProcessingOtbAlgorithmsTest"
"test_core_authmanager"
"test_core_compositionconverter"
"test_core_gdalutils"
"test_core_labelingengine"
"test_core_layout"
"test_core_layouthtml"
"test_core_layoutlabel"
"test_core_layoutmultiframe"
"test_core_layoutpicture"
"test_core_legendrenderer"
"test_core_networkaccessmanager"
"test_core_tiledownloadmanager"
"test_gui_dualview"
"test_gui_htmlwidgetwrapper"
"test_gui_filedownloader"
"test_gui_queryresultwidget"
"test_analysis_processingalgspt2"
"test_analysis_processing"
"test_provider_wcsprovider"
"qgis_grassprovidertest7"
"test_app_gpsinformationwidget"
"PyQgsAnnotation" "PyQgsAnnotation"
"PyQgsAppStartup" "PyQgsAttributeTableModel"
"PyQgsAuthBasicMethod"
"PyQgsAuthenticationSystem" "PyQgsAuthenticationSystem"
"PyQgsAuxiliaryStorage" "PyQgsExternalStorageWebDAV"
"PyQgsDBManagerGpkg" "PyQgsFieldFormattersTest"
"PyQgsDBManagerSpatialite"
"PyQgsDataItem"
"PyQgsFieldValidator"
"PyQgsFileUtils" "PyQgsFileUtils"
"PyQgsGeometryTest" "PyQgsGeometryTest"
"PyQgsImageCache" "PyQgsGoogleMapsGeocoder"
"PyQgsImportIntoPostGIS" "PyQgsHashLineSymbolLayer"
"PyQgsLayerDependencies"
"PyQgsLayerMetadata"
"PyQgsLayout"
"PyQgsLayoutExporter" "PyQgsLayoutExporter"
"PyQgsLayoutHtml" "PyQgsLayoutHtml"
"PyQgsLayoutLegend" "PyQgsLineSymbolLayers"
"PyQgsLayoutMapGrid"
"PyQgsMapClippingUtils"
"PyQgsMapLayer" "PyQgsMapLayer"
"PyQgsMetadataBase" "PyQgsNetworkContentFetcherRegistry"
"PyQgsOGRProvider"
"PyQgsOGRProviderGpkg" "PyQgsOGRProviderGpkg"
"PyQgsOapifProvider" "PyQgsOGRProviderSqlite"
"PyQgsPalLabelingCanvas"
"PyQgsPalLabelingLayout" "PyQgsPalLabelingLayout"
"PyQgsProcessingInPlace" "PyQgsPalLabelingPlacement"
"PyQgsProject" "PyQgsProcessExecutable"
"PyQgsProviderConnectionGpkg" "PyQgsProviderConnectionGpkg"
"PyQgsProviderConnectionPostgres"
"PyQgsProviderConnectionSpatialite" "PyQgsProviderConnectionSpatialite"
"PyQgsPythonProvider" "PyQgsOGRProvider"
"PyQgsRasterLayer"
"PyQgsRasterResampler"
"PyQgsRulebasedRenderer"
"PyQgsSelectiveMasking"
"PyQgsSettings"
"PyQgsShapefileProvider"
"PyQgsSpatialiteProvider" "PyQgsSpatialiteProvider"
"PyQgsSvgCache"
"PyQgsSymbolExpressionVariables"
"PyQgsTextRenderer"
"PyQgsVectorFileWriter" "PyQgsVectorFileWriter"
"PyQgsVectorLayer" "PyQgsVectorLayerEditBuffer"
"PyQgsVectorLayerUtils" "PyQgsVectorLayerEditBufferGroup"
"PyQgsVectorLayerProfileGenerator"
"PyQgsVirtualLayerProvider" "PyQgsVirtualLayerProvider"
"PyQgsWFSProvider" "PyQgsWFSProvider"
"qgis_arcgisrestutilstest" "PyQgsWFSProviderGUI"
"qgis_authmanagertest" "PyQgsOapifProvider"
"qgis_compositionconvertertest" "PyQgsLayerDependencies"
"qgis_coordinatereferencesystemtest" "PyQgsDBManagerGpkg"
"qgis_expressiontest" "PyQgsDBManagerSpatialite"
"qgis_fontmarkertest" "PyQgsAuxiliaryStorage"
"qgis_geometrycheckstest" "PyQgsSelectiveMasking"
"qgis_geometrytest"
"qgis_gpsinformationwidget"
"qgis_grassprovidertest7"
"qgis_imagecachetest"
"qgis_labelingenginetest"
"qgis_layouthtmltest"
"qgis_layoutlabeltest"
"qgis_layoutmanualtabletest"
"qgis_layoutmapgridtest"
"qgis_layoutmapoverviewtest"
"qgis_layoutmaptest"
"qgis_layoutmultiframetest"
"qgis_layoutpicturetest"
"qgis_layouttabletest"
"qgis_layouttest"
"qgis_mapdevicepixelratiotest"
"qgis_maprendererjobtest"
"qgis_meshcontourstest"
"qgis_ogrproviderguitest"
"qgis_painteffecttest"
"qgis_pallabelingtest"
"qgis_processingtest"
"qgis_rasterlayertest"
"qgis_shellcheck" "qgis_shellcheck"
"qgis_sip_include"
"qgis_sip_uptodate"
"qgis_sipify" "qgis_sipify"
"qgis_styletest" "qgis_sip_include"
"qgis_svgmarkertest" "qgis_sip_uptodate")
"qgis_taskmanagertest"
"qgis_wcsprovidertest"
"qgis_ziplayertest"
"TestQgsRandomMarkerSymbolLayer")
"|"))))) "|")))))
(add-after 'install 'wrap-python (add-after 'install 'wrap-python
(assoc-ref python:%standard-phases 'wrap)) (assoc-ref python:%standard-phases 'wrap))
(add-after 'wrap-python 'wrap-qt (add-after 'wrap-python 'wrap-qt
(lambda* (#:key outputs inputs #:allow-other-keys) (lambda* (#:key outputs inputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out"))) (let ((out (assoc-ref outputs "out")))
(wrap-qt-program "qgis" #:output out #:inputs inputs)) (wrap-qt-program "qgis" #:output out #:inputs inputs))))
#t))
(add-after 'wrap-qt 'wrap-gis (add-after 'wrap-qt 'wrap-gis
(lambda* (#:key inputs outputs #:allow-other-keys) (lambda* (#:key inputs outputs #:allow-other-keys)
;; TODO: Find if there is a way to get SAGA to work. ;; TODO: Find if there is a way to get SAGA to work.
@ -2578,10 +2534,10 @@ (define-public qgis
(wrap-program (string-append out "/bin/qgis") (wrap-program (string-append out "/bin/qgis")
;;`("PATH" ":" prefix (,saga)) ;;`("PATH" ":" prefix (,saga))
`("QGIS_PREFIX_PATH" = (,out)) `("QGIS_PREFIX_PATH" = (,out))
`("GISBASE" = (,grass)))) `("GISBASE" = (,grass)))))))))
#t)))))
(inputs (inputs
(list exiv2 (list bash-minimal
exiv2
expat expat
gdal gdal
geos geos
@ -2623,8 +2579,9 @@ (define-public qgis
qtserialport qtserialport
qtsvg-5 qtsvg-5
qwt qwt
;;("saga" ,saga) ;; saga
sqlite)) sqlite
(list zstd "lib")))
(native-inputs (native-inputs
(list bison (list bison
flex flex
@ -2633,6 +2590,7 @@ (define-public qgis
pkg-config pkg-config
python-mock python-mock
python-nose2 python-nose2
python-pyqt-builder
qttools-5 qttools-5
shellcheck shellcheck
xorg-server-for-tests)) xorg-server-for-tests))