File: Makefile

package info (click to toggle)
golang-github-robertkrimen-otto 0.0~git20200922.ef014fd-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 1,796 kB
  • sloc: perl: 1,227; makefile: 79
file content (63 lines) | stat: -rw-r--r-- 1,131 bytes parent folder | download | duplicates (2)
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
.PHONY: test test-race test-release release release-check test-262
.PHONY: parser
.PHONY: otto assets underscore

TESTS := \
	~

TEST := -v --run
TEST := -v
TEST := -v --run Test\($(subst $(eval) ,\|,$(TESTS))\)
TEST := .

test: parser inline.go
	go test -i
	go test $(TEST)
	@echo PASS

parser:
	$(MAKE) -C parser

inline.go: inline.pl
	./$< > $@

#################
# release, test #
#################

release: test-race test-release
	for package in . parser token ast file underscore registry; do (cd $$package && godocdown --signature > README.markdown); done
	@echo \*\*\* make release-check
	@echo PASS

release-check: .test
	$(MAKE) -C test build test
	$(MAKE) -C .test/test262 build test
	@echo PASS

test-262: .test
	$(MAKE) -C .test/test262 build test
	@echo PASS

test-release:
	go test -i
	go test

test-race:
	go test -race -i
	go test -race

#################################
# otto, assets, underscore, ... #
#################################

otto:
	$(MAKE) -C otto

assets:
	mkdir -p .assets
	for file in underscore/test/*.js; do tr "\`" "_" < $$file > .assets/`basename $$file`; done

underscore:
	$(MAKE) -C $@