build: fix the build version

Fixes #178
This commit is contained in:
Bassam Tabbara committed 2016-11-14 14:54:51 -08:00
1 parent d8cc9512a3
commit 31f3abaf23
1 file changed
+6 -6
+6 -6
View File
@@ -69,12 +69,6 @@ else
MAKEFLAGS += --no-print-directory
endif
# set the version number.
ifeq ($(origin VERSION), undefined)
VERSION = $(shell git describe --dirty --always)
endif
LDFLAGS += -X $(REPO)/pkg/version.Version=$(VERSION)
# the operating system and arch to build
GOOS ?= $(shell go env GOOS)
GOARCH ?= $(shell go env GOARCH)
@@ -92,6 +86,12 @@ ALL_PLATFORMS ?= $(CLIENT_SERVER_PLATFORMS) $(CLIENT_ONLY_PLATFORMS)
GO_PROJECT=github.com/rook/rook
# set the version number.
ifeq ($(origin VERSION), undefined)
VERSION = $(shell git describe --dirty --always)
endif
LDFLAGS += -X $(GO_PROJECT)/pkg/version.Version=$(VERSION)
# ====================================================================================
# Setup rookd