mirror of
https://git.yoctoproject.org/poky
synced 2026-03-25 10:02:22 +01:00
kernel: Set SOURCE_DATE_EPOCH to kernel git timestamp if not set
If SOURCE_DATE_EPOCH is unset (in addition to the existing "0" behaviour) parse out the top most commit timestamp from the kernel tree to use as the timestamp. (From OE-Core rev: 2f0dd67a5a8d4269f5155004d532d8fa972b3223) Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
3c46673100
commit
8d33b69ed0
@@ -288,7 +288,7 @@ kernel_do_compile() {
|
||||
if [ "${BUILD_REPRODUCIBLE_BINARIES}" = "1" ]; then
|
||||
# kernel sources do not use do_unpack, so SOURCE_DATE_EPOCH may not
|
||||
# be set....
|
||||
if [ "$SOURCE_DATE_EPOCH" = "0" ]; then
|
||||
if [ "${SOURCE_DATE_EPOCH}" = "" -o "${SOURCE_DATE_EPOCH}" = "0" ]; then
|
||||
olddir=`pwd`
|
||||
cd ${S}
|
||||
SOURCE_DATE_EPOCH=`git log -1 --pretty=%ct`
|
||||
|
||||
Reference in New Issue
Block a user