Add --release-sysroot flag to build.sh

When this flag is present, `build.sh` will pass `--release` to
`build_sysroot.sh`.
This commit is contained in:
yvt 2022-03-23 23:18:33 +09:00
parent 72306608e0
commit 842a5fba1c

View File

@ -4,6 +4,7 @@
set -e
codegen_channel=debug
sysroot_channel=debug
while [[ $# -gt 0 ]]; do
case $1 in
@ -11,6 +12,10 @@ while [[ $# -gt 0 ]]; do
codegen_channel=release
shift
;;
--release-sysroot)
sysroot_channel=release
shift
;;
*)
echo "Unknown option $1"
exit 1
@ -51,5 +56,9 @@ rm -r target/out || true
mkdir -p target/out/gccjit
echo "[BUILD] sysroot"
time ./build_sysroot/build_sysroot.sh $CHANNEL
if [[ "$sysroot_channel" == "release" ]]; then
time ./build_sysroot/build_sysroot.sh --release
else
time ./build_sysroot/build_sysroot.sh
fi