From: bones_was_here Date: Sun, 23 Mar 2025 00:40:44 +0000 (+1000) Subject: rsync: support updating the mappingsupport package, reduce timestamp noise X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=refs%2Fheads%2Fbones_was_here%2Frsync-ssl;p=xonotic%2Fxonotic.git rsync: support updating the mappingsupport package, reduce timestamp noise The mappingsupport package has been available via rsync for years but it didn't include the updater and wasn't recognised by it. It also lacked the license (now required by the updater). --- diff --git a/misc/tools/all/release.subr b/misc/tools/all/release.subr index 62334a31..e1161e6d 100644 --- a/misc/tools/all/release.subr +++ b/misc/tools/all/release.subr @@ -306,13 +306,13 @@ case "$cmd" in arch=$1 buildpath=$2 targetdir=$3 - verbose mkdir -p "$targetdir" + # TODO: cache the dlls and skip rebuilding them if their package versions are unchanged ( cd "$d0/misc/buildsrc" verbose ./dlls.sh clean "$buildpath" verbose ./dlls.sh all "$buildpath" "$arch" ) - verbose cp -v $buildpath/out/$arch/* "$targetdir" + verbose cp -r --preserve=timestamps -v "$buildpath/out/$arch" "$targetdir" # SDL2 verbose mkdir -p "$d0/misc/builddeps/$arch/" @@ -351,7 +351,7 @@ case "$cmd" in # macOS prefers dylibs be marked executable (this one has no file extension) verbose chmod 755 SDL2/SDL2.framework/Versions/Current/SDL2 ) - cp -R "$d0/misc/builddeps/osx/SDL2/SDL2.framework" Xonotic/Xonotic.app/Contents/Frameworks/ + cp -R --preserve=timestamps "$d0/misc/builddeps/osx/SDL2/SDL2.framework" Xonotic/Xonotic.app/Contents/Frameworks/ ;; release-libs) release_common @@ -671,6 +671,8 @@ case "$cmd" in Xonotic/data/xonotic-$pk3stamp-nexcompat-high.pk3 \ Xonotic/data/xonotic-$pk3stamp-xoncompat-high.pk3 verbose mkzipr Xonotic-$stamp-mappingsupport.zip \ + Xonotic/misc/tools/rsync-updater/ \ + Xonotic/COPYING Xonotic/GPL-2 Xonotic/GPL-3 \ Xonotic/mapping verbose mkzip0 Xonotic-$stamp-mappingsupport.zip \ Xonotic/data/xonotic-$pk3stamp-maps-mapping.pk3 @@ -684,7 +686,7 @@ case "$cmd" in verbose "$d0"/misc/tools/msys2-linux.sh --schroot=sid rsync dash openssl sed targetroot="$PWD/Xonotic" verbose cd "$HOME/msys64" # see msys2-linux.sh - verbose cp --parents \ + verbose cp --parents --preserve=timestamps \ usr/bin/msys-2.0.dll \ usr/bin/msys-crypto-3.dll \ usr/bin/msys-iconv-2.dll \ @@ -699,7 +701,7 @@ case "$cmd" in usr/ssl/cert.pem \ "$targetroot/misc/tools/rsync-updater/" # msys2 sh.exe is currently bash - verbose cp usr/bin/dash.exe "$targetroot/misc/tools/rsync-updater/usr/bin/sh.exe" + verbose cp --preserve=timestamps usr/bin/dash.exe "$targetroot/misc/tools/rsync-updater/usr/bin/sh.exe" ;; release) release_common diff --git a/misc/tools/rsync-updater/update-to-autobuild.sh b/misc/tools/rsync-updater/update-to-autobuild.sh index a78b5eb5..2f5b3480 100755 --- a/misc/tools/rsync-updater/update-to-autobuild.sh +++ b/misc/tools/rsync-updater/update-to-autobuild.sh @@ -64,6 +64,9 @@ elif PWD="${PWD%/}" && [ "$PWD" != "${PWD%/misc/tools/rsync-updater}" ]; then package="Xonotic-high" elif [ -f ../../../data/xonotic-*-data.pk3 ]; then echo "Found Xonotic data files" + elif [ -f ../../../data/xonotic-*-maps-mapping.pk3 ]; then + echo "Found Xonotic-mappingsupport files" + package="Xonotic-mappingsupport" else printf "\033[1;31mNOTE: found misc/tools/rsync-updater parent directories but no data files!\033[m\n" fi