Closed IoIxD closed 2 years ago
Hi @IoIxD, could it be that the 32-bit version of SDL2 is not installed in the system? If you have it installed, I think it should work.
Another way you can try is to compile it statically. The following command would make it use the pre-compiled static libraries that we provide.
CGO_ENABLED=1 CC=gcc GOOS=linux GOARCH=386 go build -tags static -ldflags "-s -w" -a
@IoIxD You are missing CGO_ENABLED=1. When you are changing GOARCH to 386 you are cross-compiling, which means Go is running with CGO_ENABLED=0. Add CGO_ENABLED=1 so you can see the real error messages. i.e. missing 32bit lib etc.
CGO_ENABLED helped; actually I didn't get another error it was just that. I'm now getting a floating point exception so maybe this doesn't have great 32-bit support after all but at least it compiles. Thanks!
I get a very strange error when trying to compile a program using
GOOS=386
that I don't get otherwise...A copy of all the test project is available here