From 23f02ec7eeeac790c247ba084b8755c3b718ff01 Mon Sep 17 00:00:00 2001 From: Lyndon Brown Date: Sun, 3 May 2020 18:50:41 +0100 Subject: [PATCH] syslinux: support timezone date component since date is not obtained as UTC, timezone is an important detail of understanding the given time, which users may want to make use of. Gbp-Dch: Short --- scripts/build/binary_syslinux | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/build/binary_syslinux b/scripts/build/binary_syslinux index 21cb68fe2..c116937a2 100755 --- a/scripts/build/binary_syslinux +++ b/scripts/build/binary_syslinux @@ -222,6 +222,8 @@ _DAY="$(date -d "${_DATE}" +%d)" _HOUR="$(date -d "${_DATE}" +%H)" _MINUTE="$(date -d "${_DATE}" +%M)" _SECOND="$(date -d "${_DATE}" +%S)" +_TIMEZONE="$(date -d "${_DATE}" +%Z)" +_TIMEZONE_NUM="$(date -d "${_DATE}" +%z)" _LINUX_VERSIONS="$(for _LINUX in chroot/boot/vmlinuz-* ; do chroot chroot apt-cache policy $(basename ${_LINUX} | sed -e 's|vmlinuz-|linux-image-|') | awk '/Installed: / { print $2 }' ; done | sort -Vru | tr "\n" " ")" @@ -250,6 +252,8 @@ do -e "s|@HOUR@|${_HOUR}|g" \ -e "s|@MINUTE@|${_MINUTE}|g" \ -e "s|@SECOND@|${_SECOND}|g" \ + -e "s|@TIMEZONE@|${_TIMEZONE}|g" \ + -e "s|@TIMEZONE_NUM@|${_TIMEZONE_NUM}|g" \ -e "s|@LINUX_VERSIONS@|${_LINUX_VERSIONS}|g" \ -e "s|@LIVE_BUILD_VERSION@|${LIVE_BUILD_VERSION}|g" \ -e "s|@LIVE_BOOT_VERSION@|${_LIVE_BOOT_VERSION}|g" \