From 00c22ab57e4de6a17fd3e9d142426838ec17d36b Mon Sep 17 00:00:00 2001 From: Russ Kubes Date: Tue, 27 Aug 2019 12:16:24 -0500 Subject: [PATCH] Updated export-image to not depend on fake-hwclock and hardlink. (#326) --- export-image/04-finalise/01-run.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/export-image/04-finalise/01-run.sh b/export-image/04-finalise/01-run.sh index 9215dec..0864639 100755 --- a/export-image/04-finalise/01-run.sh +++ b/export-image/04-finalise/01-run.sh @@ -4,8 +4,12 @@ IMG_FILE="${STAGE_WORK_DIR}/${IMG_FILENAME}${IMG_SUFFIX}.img" INFO_FILE="${STAGE_WORK_DIR}/${IMG_FILENAME}${IMG_SUFFIX}.info" on_chroot << EOF -/etc/init.d/fake-hwclock stop -hardlink -t /usr/share/doc +if [ -x /etc/init.d/fake-hwclock ]; then + /etc/init.d/fake-hwclock stop +fi +if hash hardlink 2>/dev/null; then + hardlink -t /usr/share/doc +fi EOF if [ -d "${ROOTFS_DIR}/home/${FIRST_USER_NAME}/.config" ]; then