-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
32 lines (22 loc) · 743 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
.PHONY: all build build-debug
VERSION ?= v0.0.0
VERSION_LD_FLAGS := -X github.com/DataDog/dd-otel-host-profiler/version.version=$(VERSION)
GO_FLAGS := -ldflags="${VERSION_LD_FLAGS} -extldflags=-static" -tags osusergo,netgo
all: build
build:
go build $(GO_FLAGS)
GOLANGCI_LINT_VERSION = "v1.61.0"
GO = $(shell go env GOROOT)/bin/go
lint:
$(GO) run github.com/golangci/golangci-lint/cmd/golangci-lint@$(GOLANGCI_LINT_VERSION) version
$(GO) run github.com/golangci/golangci-lint/cmd/golangci-lint@$(GOLANGCI_LINT_VERSION) run
linter-version:
@echo $(GOLANGCI_LINT_VERSION)
test:
go test -v -race ./...
check-copyrights:
$(GO) run tools/checkcopyright.go
licenses:
tools/make-licenses.sh
check-licenses:
tools/check-licenses.sh