wellington / go-libsass

Go wrapper for libsass, the only Sass 3.5 compiler for Go
http://godoc.org/github.com/wellington/go-libsass
Apache License 2.0
205 stars 28 forks source link

Cross compile windows from OS X #37

Open drewwells opened 8 years ago

drewwells commented 8 years ago

Install mingw with this script https://gist.github.com/drewwells/ee5d42dc29b70b7b61af

Now you should be able to issue this,

GOOS=windows GOARCH=386 CGO_ENABLED=1 CC=i686-w64-ming32-gcc CXX=i686-w64-mingw32-g++ CGO_LDFLAGS="-static" go build -i -v -x -ldflags "-extldflags '-static' -extld=$CC"

Would be nice to have the gist script turned into a homebrew package.