-
Notifications
You must be signed in to change notification settings - Fork 16
/
Copy pathMakefile
66 lines (51 loc) · 1.78 KB
/
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
VERBOSE=-v
all: vendor grammar test release
build:
go build -o spiff
grammar:
go generate ./...
release: spiff_linux_amd64.zip spiff_darwin_amd64.zip spiff_linux_ppc64le.zip spiff_linux_arm64.zip spiff_windows_amd64.zip spiff_windows_386.zip
linux:
GOOS=linux GOARCH=amd64 go build -o spiff++/spiff++ .
test:
go test $(VERBOSE) --count=1 ./...
spiff_linux_amd64.zip:
GOOS=linux GOARCH=amd64 go build -o spiff++/spiff++ .
rm -f spiff++/spiff_linux_amd64.zip
(cd spiff++; zip spiff_linux_amd64.zip spiff++)
rm spiff++/spiff++
spiff_linux_arm64.zip:
GOOS=linux GOARCH=arm64 go build -o spiff++/spiff++ .
rm -f spiff++/spiff_linux_arm64.zip
(cd spiff++; zip spiff_linux_arm64.zip spiff++)
rm spiff++/spiff++
spiff_darwin_amd64.zip:
GOOS=darwin GOARCH=amd64 go build -o spiff++/spiff++ .
rm -f spiff++/spiff_spiff_darwin_amd64.zip
(cd spiff++; zip spiff_darwin_amd64.zip spiff++)
rm spiff++/spiff++
spiff_linux_ppc64le.zip:
GOOS=linux GOARCH=ppc64le go build -o spiff++/spiff++ .
rm -f spiff++/spiff_linux_ppc64le.zip
(cd spiff++; zip spiff_linux_ppc64le.zip spiff++)
rm spiff++/spiff++
spiff_windows_amd64.zip:
GOOS=windows GOARCH=amd64 go build -o spiff++/spiff++.exe .
rm -f spiff++/spiff_windows_amd64.zip
(cd spiff++; zip spiff_windows_amd64.zip spiff++.exe)
rm spiff++/spiff++.exe
spiff_windows_386.zip:
GOOS=windows GOARCH=386 go build -o spiff++/spiff++_386.exe .
rm -f spiff++/spiff_windows_386.zip
(cd spiff++; zip spiff_windows_386.zip spiff++_386.exe)
rm spiff++/spiff++_386.exe
.PHONY: vendor
vendor:
go mod vendor
clean:
rm -rf ./spiff++
tidy:
go mod tidy
# restore patched version of candiedyaml/decode.go
#git checkout -- vendor/github.com/cloudfoundry-incubator/candiedyaml/decode.go
#git checkout -- vendor/github.com/cloudfoundry-incubator/candiedyaml/emitter.go