Skip to content
Newer
Older
100644 81 lines (58 sloc) 2.65 KB
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 23, 2010
1 # Make sure $JSSHELL points to your js shell binary in .profile or .bashrc
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
2 TOOLSDIR=./tools
3
4 # Rule for making pure JS code from a .pde (runs through parser + beautify)
5 %.js : %.pde
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
6 $(TOOLSDIR)/pde2js.py $(JSSHELL) $?
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
7
8 all: release
9
10 create-release: clean
11 mkdir ./release
12
24a7561 @corbanbrook #314 Improve make release. (humphd)
corbanbrook authored Feb 13, 2010
13 # Version number used in naming release files.
14 VERSION ?= $(error Specify a version for your release (e.g., VERSION=0.5))
15
16 release: release-files zipped
17
50add05 @corbanbrook #464 Move to YUI Compressor, add make check-release (humphd)
corbanbrook authored Mar 22, 2010
18 release-files: pretty yui example release-docs
24a7561 @corbanbrook #314 Improve make release. (humphd)
corbanbrook authored Feb 13, 2010
19
20 zipped: release-files
50add05 @corbanbrook #464 Move to YUI Compressor, add make check-release (humphd)
corbanbrook authored Mar 22, 2010
21 gzip -c ./release/processing-$(VERSION).min.js > ./release/processing-$(VERSION).min.js.gz
05fd45e @corbanbrook #334 Rename zip file for make release.
corbanbrook authored Feb 22, 2010
22 find ./release -print | zip -j ./release/processing.js-$(VERSION).zip -@
24a7561 @corbanbrook #314 Improve make release. (humphd)
corbanbrook authored Feb 13, 2010
23
24 release-docs: create-release
6cdc099 @corbanbrook #332 Add AUTHORS to Makefile for release target.
corbanbrook authored Feb 23, 2010
25 cp AUTHORS ./release
24a7561 @corbanbrook #314 Improve make release. (humphd)
corbanbrook authored Feb 13, 2010
26 cp README ./release
7cd4e8c @corbanbrook Updated make release to include LICENSE and CHANGELOG.
corbanbrook authored Feb 16, 2010
27 cp LICENSE ./release
28 cp CHANGELOG ./release
24a7561 @corbanbrook #314 Improve make release. (humphd)
corbanbrook authored Feb 13, 2010
29
30 example: create-release pretty
31 echo "<script src=\"processing-$(VERSION).js\"></script>" > ./release/example.html
32 echo "<canvas datasrc=\"example.pjs\" width=\"200\" height=\"200\"></canvas>" >> ./release/example.html
33 cp example.pjs ./release
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
34
35 pretty: create-release
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
36 $(TOOLSDIR)/jsbeautify.py $(JSSHELL) processing.js > ./release/processing-$(VERSION).js
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
37 # check for any parsing errors in pretty version of processing.js
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
38 $(JSSHELL) -f $(TOOLSDIR)/fake-dom.js -f ./release/processing-$(VERSION).js
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
39
40 packed: create-release
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
41 $(TOOLSDIR)/packer.py $(JSSHELL) processing.js > ./release/processing-$(VERSION).packed.js
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
42 # check for any parsing errors in packed version of processing.js
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
43 $(JSSHELL) -f $(TOOLSDIR)/fake-dom.js -f ./release/processing-$(VERSION).packed.js
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
44
45 minified: create-release
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
46 $(TOOLSDIR)/minifier.py $(JSSHELL) processing.js > ./release/processing-$(VERSION).jsmin.js
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
47 # check for any parsing errors in minified version of processing.js
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
48 $(JSSHELL) -f $(TOOLSDIR)/fake-dom.js -f ./release/processing-$(VERSION).jsmin.js
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
49
50add05 @corbanbrook #464 Move to YUI Compressor, add make check-release (humphd)
corbanbrook authored Mar 22, 2010
50 yui: create-release
51 java -jar $(TOOLSDIR)/yui/yuicompressor-2.4.2.jar --nomunge processing.js -o ./release/processing-$(VERSION).min.js
76b770c @corbanbrook #229 Google Closure added.
corbanbrook authored Mar 21, 2010
52 # check for any parsing errors in compiled version of processing.js
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
53 $(JSSHELL) -f $(TOOLSDIR)/fake-dom.js -f ./release/processing-$(VERSION).min.js
76b770c @corbanbrook #229 Google Closure added.
corbanbrook authored Mar 21, 2010
54
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
55 check:
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
56 $(TOOLSDIR)/runtests.py $(JSSHELL)
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
57
50add05 @corbanbrook #464 Move to YUI Compressor, add make check-release (humphd)
corbanbrook authored Mar 22, 2010
58 check-release: yui
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
59 $(TOOLSDIR)/runtests.py $(JSSHELL) -l ./release/processing-$(VERSION).min.js
50add05 @corbanbrook #464 Move to YUI Compressor, add make check-release (humphd)
corbanbrook authored Mar 22, 2010
60
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
61 check-summary:
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
62 $(TOOLSDIR)/runtests.py -s $(JSSHELL)
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
63
64 check-lint:
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
65 $(TOOLSDIR)/jslint.py $(JSSHELL) processing.js
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
66
67 check-parser:
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
68 $(TOOLSDIR)/runtests.py -p $(JSSHELL)
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
69
70 check-unit:
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
71 $(TOOLSDIR)/runtests.py -u $(JSSHELL)
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
72
73 # If you want to test just one file or dir, use |make check-one TEST=<file or dir>|
74 TEST ?= $(error Specify a test filename/dir in TEST when using check-test)
75
76 check-one:
a75a91a @corbanbrook #470 Move out of Makefile (humphd)
corbanbrook authored Mar 24, 2010
77 $(TOOLSDIR)/runtests.py $(JSSHELL) -t $(TEST)
cb80c0d @corbanbrook #228 Staged the automated test suite.
corbanbrook authored Feb 1, 2010
78
79 clean:
80 rm -fr ./release
Something went wrong with that request. Please try again.