summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--src/Makefile13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/Makefile b/src/Makefile
index 4ef8199..5b23ecc 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -1,9 +1,12 @@
-BINARY=wireguard-go
+all: wireguard-go
-build:
- go build -o ${BINARY}
+wireguard-go: $(wildcard *.go)
+ go build -o $@
clean:
- if [ -f ${BINARY} ]; then rm ${BINARY}; fi
+ rm -f wireguard-go
-.PHONY: clean
+cloc:
+ cloc $(filter-out xchacha20.go $(wildcard *_test.go), $(wildcard *.go))
+
+.PHONY: clean cloc