-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
38 lines (28 loc) · 830 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
tsc = node typescript/tsc.js
r.js = node node_modules/.bin/r.js
all: focal.js depends
.PHONY: depends
depends: require.js raphael.js
typescripts = $(filter-out typescript/%, $(wildcard *.ts */*.ts */*/*.ts))
compiled = $(patsubst %.ts, build/%.js, $(typescripts))
require.js : node_modules/requirejs/require.js
cp "$<" "$@"
focal.js : build/timestamps/compiled
echo typescripts: $(typescripts)
echo compiled: $(compiled)
$(r.js) -o build.js
build/timestamps/typescripts : $(typescripts)
@mkdir -p build/timestamps
@touch $@
build/timestamps/compiled : build/timestamps/typescripts
$(tsc) --module amd src/index.ts --outDir build/
@touch $@
.PHONY: clean
clean:
@rm -rf build/
@rm -rf focal.js
.PHONY: server
server: FORCE
server --execute /build/index.js:make --execute /focal.js:make
.PHONY: FORCE
FORCE : ;