-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathMakefile
More file actions
41 lines (31 loc) · 1.37 KB
/
Makefile
File metadata and controls
41 lines (31 loc) · 1.37 KB
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
all: clean setup1 minify setup2 package
VERSION=$(shell cat src/DEBIAN/control | grep Version | cut -d " " -f 2)
ifeq ($(mode),release)
debug = false
else
debug = true
endif
clean:
rm -rf build
rm -rf CDevReporter-*.deb
setup1:
mkdir build
cp -R src/* build/
rm build/usr/local/chronic-dev.CDevReporter/launch.js
rm build/usr/local/chronic-dev.CDevReporter/clean.js
touch build/usr/local/chronic-dev.CDevReporter/launch.js
echo \#\!/usr/bin/env node >> build/usr/local/chronic-dev.CDevReporter/launch.js
echo "var DEBUG=$(debug);" >> build/usr/local/chronic-dev.CDevReporter/launch.js
minify:
java -XX:ReservedCodeCacheSize=64m -jar utils/google-compiler-20111003.jar --js src/usr/local/chronic-dev.CDevReporter/launch.js --js_output_file build/usr/local/chronic-dev.CDevReporter/launch_new.js
java -XX:ReservedCodeCacheSize=64m -jar utils/google-compiler-20111003.jar --js src/usr/local/chronic-dev.CDevReporter/clean.js --js_output_file build/usr/local/chronic-dev.CDevReporter/clean.js
setup2:
cat build/usr/local/chronic-dev.CDevReporter/launch_new.js >> build/usr/local/chronic-dev.CDevReporter/launch.js
rm build/usr/local/chronic-dev.CDevReporter/launch_new.js
package:
chmod -R 755 build/
chown -R root:wheel build/
mkdir -p binaries
dpkg-deb -b build binaries/CDevReporter-$(VERSION).deb
install:
dpkg -i binaries/CDevReporter-$(VERSION).deb