File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change 1
1
prefix ?= /usr
2
2
3
+ SOURCE_DATE_EPOCH ?= $(shell git log -1 --pretty=% ct)
4
+ # https://reproducible-builds.org/docs/archives/
5
+ TAR_REPRODUCIBLE = tar --mtime="@${SOURCE_DATE_EPOCH}" --sort=name --owner=0 --group=0 --numeric-owner --pax-option=exthdr.name=%d/PaxHeaders/%f,delete=atime,delete=ctime
6
+
3
7
all :
4
8
cargo build --release
5
9
@@ -23,10 +27,10 @@ install-with-tests: install
23
27
install -D -m 0755 target/release/tests-integration $(DESTDIR )$(prefix ) /bin/bootc-integration-tests
24
28
25
29
bin-archive : all
26
- $(MAKE ) install DESTDIR=tmp-install && tar --zstd -C tmp-install -cf target/bootc.tar.zst . && rm tmp-install -rf
30
+ $(MAKE ) install DESTDIR=tmp-install && $( TAR_REPRODUCIBLE ) --zstd -C tmp-install -cf target/bootc.tar.zst . && rm tmp-install -rf
27
31
28
32
test-bin-archive : all
29
- $(MAKE ) install-with-tests DESTDIR=tmp-install && tar --zstd -C tmp-install -cf target/bootc.tar.zst . && rm tmp-install -rf
33
+ $(MAKE ) install-with-tests DESTDIR=tmp-install && $( TAR_REPRODUCIBLE ) --zstd -C tmp-install -cf target/bootc.tar.zst . && rm tmp-install -rf
30
34
31
35
install-kola-tests :
32
36
install -D -t $(DESTDIR )$(prefix ) /lib/coreos-assembler/tests/kola/bootc tests/kolainst/*
You can’t perform that action at this time.
0 commit comments