Last active
August 29, 2015 14:15
-
-
Save deankarn/6c638781bc3c022b2305 to your computer and use it in GitHub Desktop.
Go Cross compile setup + build
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Step #1 setup cross compiler(s) you want/need to use | |
cd $(go env GOROOT)/src | |
GOOS=linux GOARCH=amd64 ./make.bash <- GOOS=operating system - linux, darwin, windows etc... GOARCH=architechture - amd64, x86_64 386... | |
Step #2 navigate to go project | |
cd /path/of/go/project | |
env GOOS=linux GOARCH=amd64 go build |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment