guix_mirror_bot pushed a commit to branch mesa-updates
in repository guix.
commit 87ebd01a05087d8fc2f29e585b795318fb3eed95
Author: Maxim Cournoyer <[email protected]>
AuthorDate: Tue Sep 30 15:44:15 2025 +0900
gnu: rpm: Restore localstatedir to /var.
Commit 51e1f76 migrated the build system to CMake, and in the process, the
localstatedir value became $prefix/var (inside the package prefix), which
is not useful as this place should be writable for proper operation.
* gnu/packages/package-management.scm (rpm) [#:phases]
{install-macros-file}: New phase.
Change-Id: I1d069243d3b1aff3b0cf0ae79ad5823f8c2a4aeb
---
gnu/packages/package-management.scm | 15 ++++++++++++---
1 file changed, 12 insertions(+), 3 deletions(-)
diff --git a/gnu/packages/package-management.scm
b/gnu/packages/package-management.scm
index 9b0c4f1857..abae481dab 100644
--- a/gnu/packages/package-management.scm
+++ b/gnu/packages/package-management.scm
@@ -18,7 +18,7 @@
;;; Copyright © 2020 Martin Becze <[email protected]>
;;; Copyright © 2020 Vincent Legoll <[email protected]>
;;; Copyright © 2021 Ivan Gankevich <[email protected]>
-;;; Copyright © 2021, 2022, 2023 Maxim Cournoyer <[email protected]>
+;;; Copyright © 2021, 2022, 2023, 2025 Maxim Cournoyer <[email protected]>
;;; Copyright © 2021 John Kehayias <[email protected]>
;;; Copyright © 2022, 2023 Zhu Zihao <[email protected]>
;;; Copyright © 2023 jgart <[email protected]>
@@ -1043,7 +1043,7 @@ features of Stow with some extensions.")
(build-system cmake-build-system)
(arguments
(list
- #:tests? #f ; TEST need fhs envirnment.
+ #:tests? #f ;tests require FHS environment
#:configure-flags
#~(list
;; TODO: Add rpm-sequoia
@@ -1073,7 +1073,16 @@ features of Stow with some extensions.")
site)))
(substitute* "plugins/CMakeLists.txt"
(("\\$[{]dbus-1_DATADIR[}]")
- (string-append #$output "/share"))))))))
+ (string-append #$output "/share")))))
+ (add-after 'install 'install-macros-file
+ (lambda _
+ (define macros (string-append #$output "/etc/rpm/macros"))
+ (mkdir-p (dirname macros))
+ (call-with-output-file macros
+ (lambda (p)
+ (format p "\
+%_var /var
+%_localstatedir /var~%"))))))))
(native-inputs
(list pkg-config
python