-
Notifications
You must be signed in to change notification settings - Fork 236
/
Makefile
62 lines (47 loc) · 1.22 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
all: install.dependencies generate generate.stdlib build.bazel test tidy
.PHONY: all
install.dependencies:
git submodule init
git submodule update
.PHONY: install.dependencies
build.bazel:
bazel build //cmd/jsonnet
.PHONY: build.bazel
_build.bazel.os:
bazel build --platforms=@io_bazel_rules_go//go/toolchain:$(OS)_amd64 //cmd/jsonnet
.PHONY: build.bazel.os
build.bazel.linux : OS=linux
build.bazel.linux: _build.bazel.os
.PHONY: build.bazel.linux
build.bazel.darwin : OS=darwin
build.bazel.darwin: _build.bazel.os
.PHONY: build.bazel.darwin
build.bazel.windows : OS=windows
build.bazel.windows: _build.bazel.os
.PHONY: build.bazel.windows
build:
go build ./cmd/jsonnet
.PHONY: build
build.old:
go build -o jsonnet-old ./cmd/jsonnet
.PHONY: build.old
test:
./tests.sh
.PHONY: test
benchmark : FILTER ?= Builtin
benchmark: build
./benchmark.sh ${FILTER}
.PHONY: benchmark
generate:
go generate
.PHONY: generate
generate.stdlib:
go run cmd/dumpstdlibast/dumpstdlibast.go cpp-jsonnet/stdlib/std.jsonnet > astgen/stdast.go
.PHONY: generate.stdlib
tidy:
go mod tidy
bazel run //:gazelle -- update-repos -from_file=go.mod -to_macro=bazel/deps.bzl%jsonnet_go_dependencies
.PHONY: tidy
gazelle:
bazel run //:gazelle
.PHONY: gazelle