summaryrefslogtreecommitdiff
path: root/Meta
diff options
context:
space:
mode:
authorTim Schumacher <timschumi@gmx.de>2022-04-16 17:18:59 +0200
committerBrian Gianforcaro <b.gianfo@gmail.com>2022-04-17 10:53:31 -0700
commit8c278bba43b6a0951f82f950ea5358b3221a8e77 (patch)
tree69921a001fc99e10bf93ec10f7cd529e28c332e7 /Meta
parent196dada7e2cab2b6ab26e3ad7a17a2ddc46fd208 (diff)
downloadserenity-8c278bba43b6a0951f82f950ea5358b3221a8e77.zip
Meta: Keep timestamps of manually copied toolchain output
Diffstat (limited to 'Meta')
-rwxr-xr-xMeta/build-root-filesystem.sh14
1 files changed, 7 insertions, 7 deletions
diff --git a/Meta/build-root-filesystem.sh b/Meta/build-root-filesystem.sh
index 88a94d9e18..01ae733145 100755
--- a/Meta/build-root-filesystem.sh
+++ b/Meta/build-root-filesystem.sh
@@ -10,7 +10,7 @@ window_gid=13
CP="cp"
-# cp on macOS and BSD systems do not support the -d option.
+# cp on macOS and BSD systems do not support the --preserve= option.
# gcp comes with coreutils, which is already a dependency.
OS="$(uname -s)"
if [ "$OS" = "Darwin" ] || echo "$OS" | grep -qe 'BSD$'; then
@@ -46,14 +46,14 @@ LLVM_VERSION="${LLVM_VERSION:-13.0.0}"
if [ "$SERENITY_TOOLCHAIN" = "Clang" ]; then
TOOLCHAIN_DIR="$SERENITY_SOURCE_DIR"/Toolchain/Local/clang/
- $CP "$TOOLCHAIN_DIR"/lib/"$SERENITY_ARCH"-pc-serenity/* mnt/usr/lib
+ $CP --preserve=timestamps "$TOOLCHAIN_DIR"/lib/"$SERENITY_ARCH"-pc-serenity/* mnt/usr/lib
mkdir -p mnt/usr/include/"$SERENITY_ARCH"-pc-serenity
- $CP -r "$TOOLCHAIN_DIR"/include/c++ mnt/usr/include
- $CP -r "$TOOLCHAIN_DIR"/include/"$SERENITY_ARCH"-pc-serenity/c++ mnt/usr/include/"$SERENITY_ARCH"-pc-serenity
+ $CP --preserve=timestamps -r "$TOOLCHAIN_DIR"/include/c++ mnt/usr/include
+ $CP --preserve=timestamps -r "$TOOLCHAIN_DIR"/include/"$SERENITY_ARCH"-pc-serenity/c++ mnt/usr/include/"$SERENITY_ARCH"-pc-serenity
elif [ "$SERENITY_ARCH" != "aarch64" ]; then
- $CP "$SERENITY_SOURCE_DIR"/Toolchain/Local/"$SERENITY_ARCH"/"$SERENITY_ARCH"-pc-serenity/lib/libgcc_s.so mnt/usr/lib
- $CP "$SERENITY_SOURCE_DIR"/Toolchain/Local/"$SERENITY_ARCH"/"$SERENITY_ARCH"-pc-serenity/lib/libstdc++.a mnt/usr/lib
- $CP -r "$SERENITY_SOURCE_DIR"/Toolchain/Local/"$SERENITY_ARCH"/"$SERENITY_ARCH"-pc-serenity/include/c++ mnt/usr/include
+ $CP --preserve=timestamps "$SERENITY_SOURCE_DIR"/Toolchain/Local/"$SERENITY_ARCH"/"$SERENITY_ARCH"-pc-serenity/lib/libgcc_s.so mnt/usr/lib
+ $CP --preserve=timestamps "$SERENITY_SOURCE_DIR"/Toolchain/Local/"$SERENITY_ARCH"/"$SERENITY_ARCH"-pc-serenity/lib/libstdc++.a mnt/usr/lib
+ $CP --preserve=timestamps -r "$SERENITY_SOURCE_DIR"/Toolchain/Local/"$SERENITY_ARCH"/"$SERENITY_ARCH"-pc-serenity/include/c++ mnt/usr/include
fi
# If umask was 027 or similar when the repo was cloned,