gnu: inkscape: Fix copyright year displayed in about dialog.

* gnu/packages/inkscape.scm (%inkscape-release-year): New variable.
(inkscape) [#:phases] <patch-inkscape-build-year>: New phase.

Fixes: #45
Change-Id: I4fced673252f39b1d45ab4345055fe8963e29e24
This commit is contained in:
Maxim Cournoyer 2025-05-27 10:39:14 +09:00
parent 6c1cc9e360
commit 2e699377e9
No known key found for this signature in database
GPG key ID: 1260E46482E63562

View file

@ -337,6 +337,9 @@ as the native format.")
(define-deprecated/public-alias inkscape/stable inkscape/pinned) (define-deprecated/public-alias inkscape/stable inkscape/pinned)
;;; The Inkscape release year used in the about dialog. Please keep it sync
;;; when updating the package!
(define %inkscape-release-year 2023)
(define-public inkscape (define-public inkscape
(package (package
(inherit inkscape/pinned) (inherit inkscape/pinned)
@ -359,6 +362,12 @@ as the native format.")
#~(delete "-DWITH_IMAGE_MAGICK=OFF" #$flags)) #~(delete "-DWITH_IMAGE_MAGICK=OFF" #$flags))
((#:phases phases) ((#:phases phases)
#~(modify-phases #$phases #~(modify-phases #$phases
(add-after 'unpack 'patch-inkscape-build-year
(lambda _
(substitute* "CMakeScripts/inkscape-version.cmake"
(("string\\(TIMESTAMP INKSCAPE_BUILD_YEAR.*")
(format #f "set(INKSCAPE_BUILD_YEAR ~a)~%"
#$%inkscape-release-year)))))
#$@(if (target-x86-32?) #$@(if (target-x86-32?)
#~() ;XXX: there are remaining failures on i686 #~() ;XXX: there are remaining failures on i686
#~((replace 'check #~((replace 'check