Hello all
With the patch from
http://codereview.appspot.com/2515043/
applied and with the following packages from Fedora 14:
mingw32-w32api-3.14-1.fc14.noarch
mingw32-binutils-2.20.1-1.fc14.x86_64
mingw32-cpp-4.5.0-1.fc14.x86_64
mingw32-gcc-4.5.0-1.fc14.x86_64
mingw32-runtime-3.15.2-5.fc13.noarch
I can now build most of Windows Go on Linux.
Recipe:
Get Linux tools in place:
cd src
GOOS=linux GOARCH=386 ./make.bash
Fix lib9 so that runtime can link:
cd lib9
HOST_AR=i686-pc-mingw32-ar GOHOSTARCH=386 CC=i686-pc-mingw32-gcc
GOOS=windows GOARCH=386 make clean all
Fix runtime so that it doesn't try to run mkversion:
cd ../pkg/runtime
fix version.go
fix clean-local Makefile target not to delete version.go
fix mkversion Makefile target not to compile mkversion.c
fix version.go Makefile target not to overwrite version.go
Compile all the packages:
cd ..
HOST_AR=i686-pc-mingw32-ar GOHOSTARCH=386 CC=i686-pc-mingw32-gcc
GOOS=windows GOARCH=386 make -k clean all install
It seems the only bit that doesn't build at this point is libcgo.
You can also build the compilers, etc with:
HOST_AR=i686-pc-mingw32-ar GOHOSTARCH=386 CC=i686-pc-mingw32-gcc
GOOS=windows GOARCH=386 ./make.bash
It would be nice if these also got .exe extensions so that they don't
overwrite the Linux tools, which would let the build run all the way
through.
Regards,
Albert