summary refs log tree commit diff
path: root/gnu/packages/package-management.scm
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/packages/package-management.scm')
-rw-r--r--gnu/packages/package-management.scm13
1 files changed, 11 insertions, 2 deletions
diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm
index 85c1c3a9fa..820c9bb468 100644
--- a/gnu/packages/package-management.scm
+++ b/gnu/packages/package-management.scm
@@ -842,13 +842,22 @@ features of Stow with some extensions.")
     (outputs '("out" "debug"))
     (build-system gnu-build-system)
     (arguments
-     '(#:configure-flags '("--enable-python")
+     '(#:configure-flags '("--enable-python"
+                           ;; The RPM database must be writable.
+                           "--localstatedir=/var")
        #:phases (modify-phases %standard-phases
                   (add-after 'unpack 'fix-lua-check
                     (lambda _
                       (substitute* "configure"
                         (("lua >= ?.?")
-                         "lua-5.3 >= 5.3")))))))
+                         "lua-5.3 >= 5.3"))))
+                  (add-after 'unpack 'patch-build-system
+                    (lambda _
+                      ;; The build system attempts to create /var in the build
+                      ;; chroot, and fails.
+                      (substitute* "Makefile.in"
+                        ((".*MKDIR_P) \\$\\(DESTDIR)\\$\\(localstatedir.*")
+                         "")))))))
     (native-inputs
      (list pkg-config
            python))