compiler: add syscalls for 64-bit arm

This commit is contained in:
Ayke van Laethem
2019-02-05 20:13:39 +01:00
committed by Ron Evans
parent 93d5269fef
commit 3cba36f2ba
4 changed files with 49 additions and 1 deletions
+2 -1
View File
@@ -224,10 +224,11 @@ func defaultTarget(goos, goarch, triple string) (*TargetSpec, error) {
spec.GDB = "arm-linux-gnueabi-gdb"
spec.Emulator = []string{"qemu-arm", "-L", "/usr/arm-linux-gnueabi"}
}
if goarch == "arm64" {
if goarch == "arm64" && goos == "linux" {
spec.Linker = "aarch64-linux-gnu-gcc"
spec.Objcopy = "aarch64-linux-gnu-objcopy"
spec.GDB = "aarch64-linux-gnu-gdb"
spec.Emulator = []string{"qemu-aarch64", "-L", "/usr/aarch64-linux-gnu"}
}
if goarch == "386" {
spec.CFlags = []string{"-m32"}