20 lines
301 B
Makefile
20 lines
301 B
Makefile
BINARY := weircon-random-proxy
|
|
PREFIX ?= /usr/local
|
|
|
|
.PHONY: build run tidy clean install
|
|
|
|
build:
|
|
CGO_ENABLED=0 go build -trimpath -ldflags="-s -w" -o $(BINARY) .
|
|
|
|
run:
|
|
go run .
|
|
|
|
tidy:
|
|
go mod tidy
|
|
|
|
clean:
|
|
rm -f $(BINARY)
|
|
|
|
install: build
|
|
install -Dm755 $(BINARY) $(DESTDIR)$(PREFIX)/bin/$(BINARY)
|