From 1cad0392d67a84f5f62c922f0b25e9d3a05cf1c3 Mon Sep 17 00:00:00 2001 From: voidedWarranties Date: Sat, 29 Jul 2023 13:48:43 -0700 Subject: [PATCH] Enable build cache in containers --- build_containers/build/.gitignore | 2 ++ build_containers/build_gls.sh | 4 +++- build_containers/build_scripts/linux.sh | 1 + build_containers/build_scripts/macos.sh | 1 + build_containers/build_scripts/windows.sh | 1 + 5 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 build_containers/build/.gitignore diff --git a/build_containers/build/.gitignore b/build_containers/build/.gitignore new file mode 100644 index 0000000..d6b7ef3 --- /dev/null +++ b/build_containers/build/.gitignore @@ -0,0 +1,2 @@ +* +!.gitignore diff --git a/build_containers/build_gls.sh b/build_containers/build_gls.sh index 72679de..7d2c84a 100755 --- a/build_containers/build_gls.sh +++ b/build_containers/build_gls.sh @@ -15,7 +15,9 @@ popd # Build podman_run() { podman run -it --rm -v ./files:/root/files:z,ro -v ./out:/root/out:z \ - -v "./build_scripts/$1.sh":/root/build.sh "gls-$1":$tag ./build.sh + -v "./build_scripts/$1.sh":/root/build.sh:ro \ + -v ./build:/root/build:z \ + "gls-$1":$tag ./build.sh } for arg in "$@" diff --git a/build_containers/build_scripts/linux.sh b/build_containers/build_scripts/linux.sh index 30cea52..3b156d3 100755 --- a/build_containers/build_scripts/linux.sh +++ b/build_containers/build_scripts/linux.sh @@ -5,6 +5,7 @@ cd godot-luau-script scons_opts_base="platform=linux arch=x86_64 use_llvm=yes" +export SCONS_CACHE=/root/build/linux scons target=editor $scons_opts_base scons target=template_release $scons_opts_base diff --git a/build_containers/build_scripts/macos.sh b/build_containers/build_scripts/macos.sh index 124332e..b7575a7 100755 --- a/build_containers/build_scripts/macos.sh +++ b/build_containers/build_scripts/macos.sh @@ -5,6 +5,7 @@ cd godot-luau-script scons_opts_base="platform=macos arch=universal osxcross_sdk=darwin22.4" +export SCONS_CACHE=/root/build/macos scons target=editor $scons_opts_base scons target=template_release $scons_opts_base diff --git a/build_containers/build_scripts/windows.sh b/build_containers/build_scripts/windows.sh index 542c428..451ab72 100755 --- a/build_containers/build_scripts/windows.sh +++ b/build_containers/build_scripts/windows.sh @@ -5,6 +5,7 @@ cd godot-luau-script scons_opts_base="platform=windows arch=x86_64" +export SCONS_CACHE=/root/build/windows scons target=editor $scons_opts_base scons target=template_release $scons_opts_base