forked from 89luca89/lilipod
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
28 lines (23 loc) · 903 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
.PHONY: all lilipod pty coverage
all: clean pty lilipod
clean:
@rm -f lilipod
@rm -f pty
@rm -f pty.tar.gz
lilipod:
@rm -f lilipod
CGO_ENABLED=0 go build -mod vendor -ldflags="-s -w -X 'github.com/89luca89/lilipod/pkg/constants.Version=$${RELEASE_VERSION:-0.0.0}'" -o lilipod main.go
coverage:
@rm -rf coverage/*
@mkdir -p coverage
CGO_ENABLED=0 go build -mod vendor -cover -o coverage/pty ptyagent/main.go ptyagent/pty.go
@rm -f pty
@rm -f pty.tar.gz
CGO_ENABLED=0 go build -mod vendor -gcflags=all="-l -B -C" -ldflags="-s -w" -o pty ptyagent/main.go ptyagent/pty.go
tar czfv pty.tar.gz pty
CGO_ENABLED=0 go build -mod vendor -cover -o coverage/lilipod main.go
pty:
@rm -f pty
@rm -f pty.tar.gz
CGO_ENABLED=0 go build -mod vendor -gcflags=all="-l -B -C" -ldflags="-s -w -X 'main.version=$${RELEASE_VERSION:-0.0.0}'" -o pty ptyagent/main.go ptyagent/pty.go
tar czfv pty.tar.gz pty