]> git.xonotic.org Git - xonotic/xonotic.git/commitdiff
Add support for schroot builds
authorbones_was_here <bones_was_here@xonotic.au>
Sun, 15 Oct 2023 11:11:59 +0000 (21:11 +1000)
committerbones_was_here <bones_was_here@xonotic.au>
Sun, 15 Oct 2023 14:09:18 +0000 (00:09 +1000)
misc/infrastructure/xonotic-release-build.cron
misc/tools/all/release.subr

index ef433c5498f7d1b17a4a23f5743815095ba58184..8e80bf77104e8ed8b8e4455c2da6da10c043f8dc 100755 (executable)
@@ -31,7 +31,8 @@ export CACHEDIR=$HOME/.xonotic-cached-converter-crunch
 export dds_tool=crunch
 
 # Build locally.
-export HOSTS_THAT_ARE_MYSELF='xonotic-build-linux64 xonotic-build-win32 xonotic-build-win64 xonotic-build-osx'
+export HOSTS_THAT_ARE_MYSELF='xonotic-build-win32 xonotic-build-win64 xonotic-build-osx'
+export HOSTS_THAT_ARE_SCHROOT='xonotic-build-linux64'
 
 mepwd=$PWD
 me=$0
index e92d12e8c3aa81fc31bed10d0dd790d281f87363..8a43458c424f51e12415f85f46f8d17598b013b3 100644 (file)
@@ -215,6 +215,7 @@ case "$cmd" in
                srcdir=$5
                depsdir=$6
                targetfiles=$7
+               schroot=
                set -x
                if [ -z "$targetfiles" ]; then
                        exit
@@ -224,13 +225,18 @@ case "$cmd" in
                                exit
                                ;;
                esac
-               case " $HOSTS_THAT_ARE_MYSELF " in
+               case " $HOSTS_THAT_ARE_SCHROOT " in
+                       *\ $host\ *)
+                               schroot="schroot -c $host --"
+                               ;;
+               esac
+               case " $HOSTS_THAT_ARE_MYSELF $HOSTS_THAT_ARE_SCHROOT " in
                        *\ $host\ *)
                                verbose rsync --delete -zLvaSHP "$srcdir"/ "$buildpath/"
                                verbose rsync --delete -zLvaSHP misc/logos/icons_ico/xonotic.ico "$buildpath"/darkplaces.ico
                                verbose rsync --delete -zLvaSHP "$depsdir"/*/ "$buildpath.deps/"
                                verbose ln -snf "$buildpath.deps" "$buildpath/.deps"
-                               verbose eval make -C "$buildpath" clean $maketargets $makeflags
+                               verbose eval $schroot make -C "$buildpath" clean $maketargets $makeflags
                                for f in $targetfiles; do
                                        verbose mv "$buildpath/${f%:*}" "${f##*:}" || true
                                done