aboutsummaryrefslogtreecommitdiff
path: root/Makefile
blob: e498b3570b613b0e1ce10d4b35440036bc63e39d (plain)
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
BIN?=jnfilter
PREFIX?=/usr/local
BINDIR?=$(PREFIX)/bin

OUT=./bin/$(BIN)
SERVER=./main.go

GO_BUILD=go build -v -ldflags '-w -s'
GO_RUN=go run -v
all: build

install: build
	install -Dm755 $(OUT) $(BINDIR)/$(BIN)

build:
	$(GO_BUILD) -o $(OUT) .

compress: build
	upx -1 $(OUT)

compress_into_oblivion: build
	upx --best --ultra-brute $(OUT)

run:
	$(GO_RUN) .