Skip to content

Commit

Permalink
fixing cross compile
Browse files Browse the repository at this point in the history
  • Loading branch information
Russell Endicott committed Oct 19, 2018
1 parent b57ab34 commit 69c55bb
Showing 1 changed file with 4 additions and 10 deletions.
14 changes: 4 additions & 10 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -38,23 +38,17 @@ configure:


build-linux:
export GOOS=linux
export GOARCH=amd64
go build -o ./$(build_dir_linux)/gossamer -ldflags "-X main.version=$(version)"
env GOOS=linux GOARCH=amd64 go build -o ./$(build_dir_linux)/gossamer -ldflags "-X main.version=$(version)"
chmod +x ./$(build_dir_linux)/gossamer
@cd ./$(build_dir_linux) && tar zcf ../$(build_dir)/$(packageNameNix) .

build-mac:
export GOOS=darwin
export GOARCH=amd64
go build -o ./$(build_dir_mac)/gossamer -ldflags "-X main.version=$(version)"
./$(build_dir_mac)/gossamer
env GOOS=darwin GOARCH=amd64 go build -o ./$(build_dir_mac)/gossamer -ldflags "-X main.version=$(version)"
chmod +x ./$(build_dir_mac)/gossamer
@cd ./$(build_dir_mac) && tar zcf ../$(build_dir)/$(packageNameMac) .

build-windows:
export GOOS=windows
export GOARCH=amd64
go build -o ./$(build_dir_windows)/gossamer.exe -ldflags "-X main.version=$(version)"
env GOOS=windows GOARCH=amd64 go build -o ./$(build_dir_windows)/gossamer.exe -ldflags "-X main.version=$(version)"
@cd ./$(build_dir_windows) && tar zcf ../$(build_dir)/$(packageNameWindows) .

clean:
Expand Down

0 comments on commit 69c55bb

Please sign in to comment.