diff options
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/test.sh | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/tools/test.sh b/tools/test.sh index 937974b..b4e7470 100755 --- a/tools/test.sh +++ b/tools/test.sh @@ -23,12 +23,15 @@ init() { for p in aarch64-linux-musl aarch64-linux-gnu do cc="$p-gcc -no-pie" - qemu="qemu-aarch64 -L /usr/$p" + qemu="qemu-aarch64" if $cc -v >/dev/null 2>&1 && - $qemu -version >/dev/null 2>&1 && - test -d /usr/$p + $qemu -version >/dev/null 2>&1 then + if sysroot=$($cc -print-sysroot) && test -n "$sysroot" + then + qemu="$qemu -L $sysroot" + fi break fi cc= |