3 ms·
Just for completeness, my answer to the same Q on the blog: --- his doesn't solve cross compilation CGO. For that, you need the gcc cross compiler for the rasp
by discordianfish 12y ago
Just for completeness, my answer to the same Q on the blog:
---
his doesn't solve cross compilation CGO. For that, you need the gcc cross compiler for the raspberry pi. I've tried to build it with CGO enabled like this:
CC=arm-linux-gnueabihf-gcc GOARCH=arm CGO_ENABLED=1 go build -ldflags="-extld=$CC"
But the binary still segfaulted on the raspberry pi. I also tried the cc from https://github.com/raspberrypi.. https://github.com/raspberrypi... but with the same result.
- laumars 12y agoAh ok. Shame. Thanks for the update though :)