mirror of
https://git.savannah.gnu.org/git/guix.git
synced 2026-05-02 07:15:53 +02:00
linux-initrd: Make sure 'build-initrd' can delete files.
Fixes <https://bugs.gnu.org/33297>.
Reported by Mark H Weaver <mhw@netris.org>.
This fixes a regression introduced in
72dc64f8f7, which made files read-only.
* gnu/build/linux-initrd.scm (build-initrd): Call 'make-file-writable'
on all the files under contents/.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
;;; GNU Guix --- Functional package management for GNU
|
||||
;;; Copyright © 2013, 2014, 2015 Ludovic Courtès <ludo@gnu.org>
|
||||
;;; Copyright © 2013, 2014, 2015, 2018 Ludovic Courtès <ludo@gnu.org>
|
||||
;;;
|
||||
;;; This file is part of GNU Guix.
|
||||
;;;
|
||||
@@ -139,6 +139,12 @@ REFERENCES-GRAPHS."
|
||||
|
||||
(write-cpio-archive output "." #:gzip gzip))
|
||||
|
||||
;; Make sure directories are writable so we can delete files.
|
||||
(for-each make-file-writable
|
||||
(find-files "contents"
|
||||
(lambda (file stat)
|
||||
(eq? 'directory (stat:type stat)))
|
||||
#:directories? #t))
|
||||
(delete-file-recursively "contents"))
|
||||
|
||||
;;; linux-initrd.scm ends here
|
||||
|
||||
Reference in New Issue
Block a user