1

use .bazelrc for qemu configuration

This commit is contained in:
Motiejus Jakštys 2022-02-08 14:22:21 +02:00
parent 3325986971
commit 3d166c5671
3 changed files with 8 additions and 9 deletions

View File

@ -10,5 +10,6 @@ build --extra_toolchains @zig_sdk//:linux_amd64_gnu.2.19_toolchain
build --extra_toolchains @zig_sdk//:linux_arm64_gnu.2.28_toolchain
build --extra_toolchains @zig_sdk//:darwin_amd64_toolchain
build --extra_toolchains @zig_sdk//:darwin_arm64_toolchain
#build --incompatible_use_cc_configure_from_rules_cc
#build --incompatible_use_platforms_repo_for_constraints
test:qemu-aarch64 --test_env=QEMU_LD_PREFIX=/usr/aarch64-linux-gnu/
test:qemu-aarch64 --run_under=qemu-aarch64-static

View File

@ -16,8 +16,6 @@ triggers:
tasks:
- setup: |
sudo apt-get purge gcc -y && sudo apt-get autoremove -y
sudo mkdir -p /etc/qemu-binfmt
sudo ln -sf /usr/aarch64-linux-gnu /etc/qemu-binfmt/aarch64
- test_list_toolchains_platforms: |
cd bazel-zig-cc; . .envrc
echo "Available toolchains:"

10
ci/test
View File

@ -11,10 +11,10 @@ _run() {
"$@"
}
while read -r action platform toolchain run_under; do
while read -r action platform toolchain config; do
args=("$@")
if [[ $run_under != : ]]; then
args+=(--run_under="$run_under")
if [[ $config != : ]]; then
args+=(--config="$config")
fi
args+=(\
@ -28,7 +28,7 @@ while read -r action platform toolchain run_under; do
done <<EOF
test linux_amd64 linux_amd64_musl :
test linux_amd64 linux_amd64_gnu.2.19 :
test linux_arm64 linux_arm64_musl qemu-aarch64-static
test linux_arm64 linux_arm64_gnu.2.28 qemu-aarch64-static
test linux_arm64 linux_arm64_musl qemu-aarch64
test linux_arm64 linux_arm64_gnu.2.28 qemu-aarch64
build darwin_amd64 darwin_amd64 :
EOF