Skip to content

Commit

Permalink
be sure to rebuild binary on build/mackerel-check task
Browse files Browse the repository at this point in the history
make will skip the recipe if the target is newer than dependencies.
  • Loading branch information
lufia committed Sep 14, 2020
1 parent 8b87e25 commit 806f816
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,15 @@ build:
`pwd | sed -e "s|${GOPATH_ROOT}/src/||"`/$$i; \
done

build/mackerel-check:
build/mackerel-check: $(patsubst %,depends_on,$(GOOS)$(GOARCH))
mkdir -p build
go build -ldflags="-s -w -X main.gitcommit=$(CURRENT_REVISION)" \
-o build/mackerel-check

.PHONY: depends_on
depends_on:
@:

.PHONY: rpm
rpm: rpm-v1 rpm-v2

Expand Down

0 comments on commit 806f816

Please sign in to comment.