Makefile: yacc config before make
This commit is contained in:
parent
1dcefba5c4
commit
bffdcbaede
12
Makefile
12
Makefile
|
@ -16,27 +16,31 @@ export CGO_CFLAGS CGO_LDFLAGS PATH
|
||||||
|
|
||||||
default: test
|
default: test
|
||||||
|
|
||||||
dev: libucl
|
dev: config/y.go libucl
|
||||||
@sh -c "$(CURDIR)/scripts/build.sh"
|
@sh -c "$(CURDIR)/scripts/build.sh"
|
||||||
|
|
||||||
libucl: vendor/libucl/$(LIBUCL_NAME)
|
libucl: vendor/libucl/$(LIBUCL_NAME)
|
||||||
|
|
||||||
test: libucl
|
test: config/y.go libucl
|
||||||
TF_ACC= go test $(TEST) $(TESTARGS) -timeout=10s
|
TF_ACC= go test $(TEST) $(TESTARGS) -timeout=10s
|
||||||
|
|
||||||
testacc: libucl
|
testacc: config/y.go libucl
|
||||||
@if [ "$(TEST)" = "./..." ]; then \
|
@if [ "$(TEST)" = "./..." ]; then \
|
||||||
echo "ERROR: Set TEST to a specific package"; \
|
echo "ERROR: Set TEST to a specific package"; \
|
||||||
exit 1; \
|
exit 1; \
|
||||||
fi
|
fi
|
||||||
TF_ACC=1 go test $(TEST) -v $(TESTARGS)
|
TF_ACC=1 go test $(TEST) -v $(TESTARGS)
|
||||||
|
|
||||||
testrace: libucl
|
testrace: config/y.go libucl
|
||||||
TF_ACC= go test -race $(TEST) $(TESTARGS)
|
TF_ACC= go test -race $(TEST) $(TESTARGS)
|
||||||
|
|
||||||
updatedeps:
|
updatedeps:
|
||||||
go get -u -v ./...
|
go get -u -v ./...
|
||||||
|
|
||||||
|
config/y.go: config/expr.y
|
||||||
|
cd config/ && \
|
||||||
|
go tool yacc -p "expr" expr.y
|
||||||
|
|
||||||
vendor/libucl/libucl.a: vendor/libucl
|
vendor/libucl/libucl.a: vendor/libucl
|
||||||
cd vendor/libucl && \
|
cd vendor/libucl && \
|
||||||
cmake cmake/ && \
|
cmake cmake/ && \
|
||||||
|
|
Loading…
Reference in New Issue