https://github.com/cilium/cilium
Raw File
Tip revision: cb71be13a343c09bcbe55a06978a415ead3e4cf2 authored by Thomas Graf on 30 May 2018, 14:07:44 UTC
Prepare for 1.1.0-rc2 release
Tip revision: cb71be1
Makefile.defs
ROOT_DIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
include $(ROOT_DIR)/Makefile.quiet

PREFIX?=/usr
BINDIR?=$(PREFIX)/bin
RUNDIR?=/var/run
CONFDIR?=/etc

GO = $(QUIET)go
INSTALL = $(QUIET)install

VERSION = $(shell cat $(dir $(lastword $(MAKEFILE_LIST)))/VERSION)
# Use git only if in a Git repo
ifneq ($(wildcard $(dir $(lastword $(MAKEFILE_LIST)))/.git),)
	GIT_VERSION = $(shell git show -s --format='format:%h %aI')
else
	GIT_VERSION = $(shell cat $(ROOT_DIR)/GIT_VERSION)
endif
BUILD = $(VERSION) $(GIT_VERSION) $(shell go version)
GOBUILD = -ldflags '-X "github.com/cilium/cilium/pkg/version.Version=$(BUILD)"'

# Uncomment to enable race detection
#GOBUILD += -race

# Uncomment to enable deadlock detection
#GOBUILD += -tags lockdebug

ifneq ($(LOCKDEBUG),)
    GOBUILD += -tags lockdebug
endif

# Set DOCKER_IMAGE_TAG with "latest" by default
ifeq ($(DOCKER_IMAGE_TAG),)
    DOCKER_IMAGE_TAG="latest"
endif
back to top