By default, if I specify --target=aarch64, AR=aarch64-ar is used, which is apparently not available. With this patch, I am able to build an aarch64 musl with: ../configure --target=aarch64 AR=llvm-ar RANLIB=true CC=clang CFLAGS=--target=aarch64-linux-musl LDFLAGS="-fuse-ld=lld -L/path/to/aarch64/libgcc.a/and/libgcc_eh.a" --enable-debug ASMSUBARCH is no longer in use as of commit 0f814a4e57e80d2512934820b878211e9d71c93e. You may also delete the following line test -z "$LIBCC" && tryldflag LIBCC -lcompiler_rt because compiler-rt (part of which is nearly a replacement of libgcc) is something like: /home/ray/llvm/Release/lib/clang/9.0.0/lib/linux/libclang_rt.builtins-x86_64.a not libcompiler_rt.a % clang -print-resource-dir /home/ray/llvm/Release/lib/clang/9.0.0 % clang -rtlib=compiler-rt -print-libgcc-file-name /home/ray/llvm/Release/lib/clang/9.0.0/lib/linux/libclang_rt.builtins-x86_64.a BTW, I am not sure if libgcc_eh.a is needed.