From 04922d1bd77015c81bc81b0ac04721392646257e Mon Sep 17 00:00:00 2001 From: Bjorn Andersson Date: Sun, 21 Apr 2024 11:55:13 -0700 Subject: [PATCH] Makefile: Override owner of files in cpio archive In the typical scenario where the bootrr cpio archive is concatenated onto some ramdisk, attributes of this cpio archive will overwrite those previously extracted. When used in combination with a ramdisk with systemd, this results in many services failing to start, because the namespaced services does not have permission to open e.g. / Fix this my overriding the owner and group. Signed-off-by: Bjorn Andersson --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 3951bab..95c2a18 100644 --- a/Makefile +++ b/Makefile @@ -37,7 +37,7 @@ install: $(all-install) CPIO := $(PWD)/$(CPIONAME).cpio $(CPIO): $(all-install) - @cd $(DESTDIR) && find ./$(prefix) | cpio -o -H newc > $(CPIO) + @cd $(DESTDIR) && find ./$(prefix) | cpio -o -H newc -R +0:+0 > $(CPIO) %.cpio.gz: %.cpio @gzip < $< > $@