Skip to content

Commit

Permalink
Add GO_VERSION to makefile
Browse files Browse the repository at this point in the history
This will allow building with alternate go versions.
  • Loading branch information
zorchenhimer committed Jan 11, 2021
1 parent 145a952 commit 1e8b021
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ all: fmt $(CMD_SERVER)
data: fmt $(CMD_DATA)

server: cmd/server.go fmt $(SOURCES)
GOOS=linux GOARCH=386 go build -o bin/MoviePolls $<
GOOS=linux GOARCH=386 go$(GO_VERSION) build -o bin/MoviePolls $<

clean:
rm -f $(CMD_SERVER) $(CMD_DATA) bin/MoviePolls
Expand All @@ -43,10 +43,10 @@ fmt:
gofmt -w .

$(CMD_SERVER): cmd/server.go $(SOURCES)
go build -o $@ $<
go$(GO_VERSION) build -o $@ $<

$(CMD_DATA): cmd/mkdata.go $(SOURCES)
go build -o $@ $<
go$(GO_VERSION) build -o $@ $<

run: all
cmd/server

0 comments on commit 1e8b021

Please sign in to comment.