2018-05-15 02:15:16 +02:00
|
|
|
PREFIX ?= /usr
|
|
|
|
DESTDIR ?=
|
|
|
|
BINDIR ?= $(PREFIX)/bin
|
|
|
|
|
2017-08-01 14:41:32 +02:00
|
|
|
all: wireguard-go
|
2017-06-28 23:45:45 +02:00
|
|
|
|
2018-05-14 00:28:30 +02:00
|
|
|
wireguard-go: $(wildcard *.go) $(wildcard */*.go)
|
2018-05-15 02:15:16 +02:00
|
|
|
go get -d -v
|
|
|
|
go build -v -o $@
|
|
|
|
|
|
|
|
install: wireguard-go
|
|
|
|
@install -v -d "$(DESTDIR)$(BINDIR)" && install -m 0755 -v wireguard-go "$(DESTDIR)$(BINDIR)/wireguard-go"
|
2017-06-28 23:45:45 +02:00
|
|
|
|
|
|
|
clean:
|
2017-08-01 14:41:32 +02:00
|
|
|
rm -f wireguard-go
|
2017-06-28 23:45:45 +02:00
|
|
|
|
2018-05-15 02:15:16 +02:00
|
|
|
.PHONY: clean install
|