59 lines
1.8 KiB
Diff
59 lines
1.8 KiB
Diff
|
From 798e3e59b2af5057521c170268c03ab88aaf1307 Mon Sep 17 00:00:00 2001
|
||
|
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||
|
Date: Tue, 22 Oct 2024 09:14:15 +0100
|
||
|
Subject: [PATCH] appliance: Refactor the TAR_COMMAND macro
|
||
|
|
||
|
No change, just make it easier to understand.
|
||
|
|
||
|
Updates: commit 53632b4b8245a6dd67c95015d52d1f4c562b14ed
|
||
|
---
|
||
|
appliance/Makefile.am | 11 ++++++-----
|
||
|
1 file changed, 6 insertions(+), 5 deletions(-)
|
||
|
|
||
|
diff --git a/appliance/Makefile.am b/appliance/Makefile.am
|
||
|
index 7edc90e61..ce9940358 100644
|
||
|
--- a/appliance/Makefile.am
|
||
|
+++ b/appliance/Makefile.am
|
||
|
@@ -113,8 +113,9 @@ packagelist: packagelist.in Makefile guestfsd.deps
|
||
|
cmp -s $@ $@-t || mv $@-t $@
|
||
|
rm -f $@-t
|
||
|
|
||
|
-# Use stable times and owner/group (RHBZ#2320025).
|
||
|
-TAR_COMMAND := tar -z \
|
||
|
+# Use stable owner/group and mtimes (RHBZ#2320025).
|
||
|
+TAR_OPTIONS := \
|
||
|
+ -z \
|
||
|
--owner=0 --group=0 \
|
||
|
$${SOURCE_DATE_EPOCH:+--mtime=@"$$SOURCE_DATE_EPOCH"}
|
||
|
|
||
|
@@ -123,7 +124,7 @@ supermin.d/daemon.tar.gz: ../daemon/guestfsd
|
||
|
rm -rf tmp-d
|
||
|
mkdir -p tmp-d$(DAEMON_SUPERMIN_DIR) tmp-d/etc
|
||
|
ln ../daemon/guestfsd tmp-d$(DAEMON_SUPERMIN_DIR)/guestfsd
|
||
|
- ( cd tmp-d && $(TAR_COMMAND) -cf - * ) > $@-t
|
||
|
+ ( cd tmp-d && tar $(TAR_OPTIONS) -cf - * ) > $@-t
|
||
|
rm -r tmp-d
|
||
|
mv $@-t $@
|
||
|
|
||
|
@@ -144,7 +145,7 @@ supermin.d/hostfiles: hostfiles.in Makefile
|
||
|
|
||
|
supermin.d/init.tar.gz: init
|
||
|
rm -f $@ $@-t
|
||
|
- ( cd $(srcdir) && $(TAR_COMMAND) -cf - init ) > $@-t
|
||
|
+ ( cd $(srcdir) && tar $(TAR_OPTIONS) -cf - init ) > $@-t
|
||
|
mv $@-t $@
|
||
|
|
||
|
# We should put this file in /lib/udev/rules.d, but put it in /etc so
|
||
|
@@ -154,7 +155,7 @@ supermin.d/udev-rules.tar.gz: 99-guestfs-serial.rules
|
||
|
rm -rf tmp-u
|
||
|
mkdir -p tmp-u/etc/udev/rules.d
|
||
|
for f in $^; do ln $$f tmp-u/etc/udev/rules.d/$$(basename $$f); done
|
||
|
- ( cd tmp-u && $(TAR_COMMAND) -cf - etc ) > $@-t
|
||
|
+ ( cd tmp-u && tar $(TAR_OPTIONS) -cf - etc ) > $@-t
|
||
|
rm -r tmp-u
|
||
|
mv $@-t $@
|
||
|
|
||
|
--
|
||
|
2.43.0
|
||
|
|