Include race condition binary target.

The race condition binary target is special in that it needs to
explicitly link against the dependent libraries and recompile the CGO
bindings.  Because of this, we have a new build target that produces
these binaries.
This commit is contained in:
Matt T. Proud 2013-06-05 13:56:15 +02:00
parent 6c36beb764
commit 9215580488
2 changed files with 7 additions and 2 deletions

View File

@ -23,6 +23,9 @@ advice:
binary: build
go build -o prometheus $(BUILDFLAGS) .
race_condition_binary: build
CGO_CFLAGS="-I$(PWD)/build/root/include" CGO_LDFLAGS="-L$(PWD)/build/root/lib" go build -race -o prometheus $(BUILDFLAGS) .
build: preparation config model tools web
clean:
@ -79,4 +82,4 @@ tools:
web: preparation config model
$(MAKE) -C web
.PHONY: advice binary build clean config documentation format model package preparation run search_index source_path test tools
.PHONY: advice binary build clean config documentation format model package preparation race_condition_binary run search_index source_path test tools

View File

@ -55,7 +55,9 @@ APT_GET_INSTALL := sudo apt-get install -y
BREW_INSTALL := brew install
# By default, wget sets the creation time to match the server's, which throws
# off Make. :-(
WGET := wget --no-use-server-timestamps -c
#
# Set WGET_OPTIONS to include ``--no-use-server-timestamps`` to alleviate this.
WGET := wget $(WGET_OPTIONS) -c
REV := $(shell git rev-parse --short HEAD)
BRANCH := $(shell git rev-parse --abbrev-ref HEAD)