-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
44 lines (35 loc) · 871 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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
.PHONY: build preprocess clean install install-release
preprocess:
echo "using makefile"
@echo "Preprocessing..."
go build ./cmd/ybbuilder
./ybbuilder
@-rm -f ybbuilder
@-del .\ybbuilder.exe
@echo "Done."
build:preprocess
@echo "Building..."
go build ./cmd/ybcli
go build ./cmd/yb
@echo "Done."
clean:
@echo "Cleaning..."
@-rm -f yb
@-rm -f ybbuilder
@-rm -f ybcli
@-del .\yb.exe
@-del .\ybbuilder.exe
@-del .\ybcli.exe
@echo "Done."
install:preprocess
@echo "Installing..."
go install ./cmd/yb
go install ./cmd/ybcli
go install ./cmd/ybbuilder
@echo "Done."
install-release:preprocess
@echo "Installing..."
go install -ldflags "-s -w" -tags=release ./cmd/yb
go install -ldflags "-s -w" -tags=release ./cmd/ybcli
go install -ldflags "-s -w" -tags=release ./cmd/ybbuilder
@echo "Done."