Thank you. Yes, I had forgotten I'd installed that (needed for kernel
building for the very same arm5 device).
Dan
On Thu, 2017-02-16 at 21:31 +1300, Michael Hudson-Doyle wrote:
> Do you have qemu-user-static or a similarly named package installed?
> Then
> the magic of binfmt_misc may be invokin
Do you have qemu-user-static or a similarly named package installed? Then
the magic of binfmt_misc may be invoking it. For me:
$ cat /proc/sys/fs/binfmt_misc/qemu-arm
enabled
interpreter /usr/bin/qemu-arm-static
flags: OC
offset 0
magic 7f454c460101010002002800
mask ff0
Can someone explain to me why this works? I am cross-compiling for
arm5, but the executable works on amd64.
$ cat hello.go
package main
import "fmt"
func main() {
fmt.Println("hello")
}
$ GOARCH=arm GOARM=5 go build hello.go
$ ./hello
hello
$ go env
GOARCH="amd64"
GOBIN=""
GOEXE=""
GO