summaryrefslogtreecommitdiffstats
path: root/meta/classes
diff options
context:
space:
mode:
authorPeter Kjellerstedt <pkj@axis.com>2020-02-09 07:06:58 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2020-02-21 17:48:09 +0000
commitb64563009023a2db1f182164195e8f0402711d13 (patch)
tree850fa7f5a5079f5e30155cc62c778dc57298412e /meta/classes
parent68df350abfd490009dea7582060c1758ce6af0d4 (diff)
downloadpoky-b64563009023a2db1f182164195e8f0402711d13.tar.gz
Revert "rootfs: Make BUILDNAME a weak default in reproducible_build_simple"
This reverts commit 8380df6566db49ef184b837432558750f77f592f. Giving BUILDNAME a static default in reproducible_build_simple.bbclass to have /etc/version be generated with that name lead to other users of BUILDNAME no longer working as expected. E.g., buildstats.bcclass would now write its information in a single directory, overwriting the statistics for each build. (From OE-Core rev: dcd1fbe153369634c73370cbe22e1dbdac080146) Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
-rw-r--r--meta/classes/reproducible_build_simple.bbclass1
-rw-r--r--meta/classes/rootfs-postcommands.bbclass5
2 files changed, 5 insertions, 1 deletions
diff --git a/meta/classes/reproducible_build_simple.bbclass b/meta/classes/reproducible_build_simple.bbclass
index 3e5fd82432..393372993d 100644
--- a/meta/classes/reproducible_build_simple.bbclass
+++ b/meta/classes/reproducible_build_simple.bbclass
@@ -7,4 +7,3 @@ export PERL_HASH_SEED = "0"
7export SOURCE_DATE_EPOCH ??= "1520598896" 7export SOURCE_DATE_EPOCH ??= "1520598896"
8 8
9REPRODUCIBLE_TIMESTAMP_ROOTFS ??= "1520598896" 9REPRODUCIBLE_TIMESTAMP_ROOTFS ??= "1520598896"
10BUILDNAME ??= "${REPRODUCIBLE_TIMESTAMP_ROOTFS}"
diff --git a/meta/classes/rootfs-postcommands.bbclass b/meta/classes/rootfs-postcommands.bbclass
index e40097444d..2f171836fa 100644
--- a/meta/classes/rootfs-postcommands.bbclass
+++ b/meta/classes/rootfs-postcommands.bbclass
@@ -356,6 +356,11 @@ python rootfs_log_check_recommends() {
356# Perform any additional adjustments needed to make rootf binary reproducible 356# Perform any additional adjustments needed to make rootf binary reproducible
357rootfs_reproducible () { 357rootfs_reproducible () {
358 if [ "${REPRODUCIBLE_TIMESTAMP_ROOTFS}" != "" ]; then 358 if [ "${REPRODUCIBLE_TIMESTAMP_ROOTFS}" != "" ]; then
359 # Convert UTC into %4Y%2m%2d%2H%2M%2S
360 sformatted=`date -u -d @${REPRODUCIBLE_TIMESTAMP_ROOTFS} +%4Y%2m%2d%2H%2M%2S`
361 echo $sformatted > ${IMAGE_ROOTFS}/etc/version
362 bbnote "rootfs_reproducible: set /etc/version to $sformatted"
363
359 if [ -d ${IMAGE_ROOTFS}${sysconfdir}/gconf ]; then 364 if [ -d ${IMAGE_ROOTFS}${sysconfdir}/gconf ]; then
360 find ${IMAGE_ROOTFS}${sysconfdir}/gconf -name '%gconf.xml' -print0 | xargs -0r \ 365 find ${IMAGE_ROOTFS}${sysconfdir}/gconf -name '%gconf.xml' -print0 | xargs -0r \
361 sed -i -e 's@\bmtime="[0-9][0-9]*"@mtime="'${REPRODUCIBLE_TIMESTAMP_ROOTFS}'"@g' 366 sed -i -e 's@\bmtime="[0-9][0-9]*"@mtime="'${REPRODUCIBLE_TIMESTAMP_ROOTFS}'"@g'