-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile
103 lines (73 loc) · 2.06 KB
/
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
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
#! /usr/bin/make -f
default: all
package?=mapo
version?=0.0.0
wgt?=${package}-${version}.wgt
archive?=${package}-${version}.zip
all?=${wgt} \
tmp/512x512.png \
tmp/480x854/gmaps.png tmp/480x854/openlayers-gmaps.png tmp/screenshot.jpg \
#eol
all: ${all} package dist
icon.png: docs/logo.png Makefile
convert -resize 117x117! $< $@
docs/logo.png:
sleep 5 ; import $@
docs/screenshot.png: docs/logo.png
echo cp $< $@
tmp/screenshot.jpg: docs/screenshot.png
convert $< $@
tmp/117x177/%: %
mkdir -p ${@D}
convert -resize '117x117!' $< $@
tmp/512x512.png: docs/logo.png
mkdir -p ${@D}
convert -resize '512x512!' $< $@
tmp/512x512.jpg: docs/logo.png
mkdir -p ${@D}
convert -resize '512x512!' $< $@
tmp/480x854/gmaps.png: docs/gmaps.png
mkdir -p ${@D}
convert -resize '480x854!' $< $@
tmp/480x854/openlayers-gmaps.png: docs/openlayers-gmaps.png
mkdir -p ${@D}
convert -resize '480x854!' $< $@
distclean: clean
rm -f *.wgt *.zip
clean:
rm -rf .package tmp
rm -vf *~ .*~ .*.orig .*.mine
check: index.html wgt
webtidy $<
unzip -t ${wgt}
package: ${wgt}
wgt: ${wgt}
${wgt}: Makefile distclean
@rm -f [email protected]
zip -r9 [email protected] . -x "tmp/*" "docs/*" *.git* *.sign* ".*" "*.zip" "*.wgt" -x Makefile $< && \
mv [email protected] $@
archive: ${archive}
${archive}: img
@rm -f [email protected]
zip -r9 [email protected] . -x "tmp/*" "docs/*" *.git* *.sign* ".*" "*.zip" "*.wgt" -x Makefile $< && \
mv [email protected] $@
manifest.webapp:Makefile
sed -e "s|\"version\": \".*\"|\"version\": \"${version}\"|g" -i $@
deploy: ${wgt} check
sdb install $<
sdb shell pkgcmd -l grep -i "\"${package}\""
tizen-1.0/deploy: ${wgt}
sdb push $< /tmp/
sdb shell pkgcmd -i -t wgt -p /tmp/${<}
echo "press confirm on device"
setup/debian:
which webtidy || sudo apt-get install make git zip libhtml-tidy-perl.
dist: distclean wgt archive
img: docs/logo.png Makefile
@mkdir -p img/icons
convert -resize 16x16! $< img/icons/logo-16.png
convert -resize 48x48! $< img/icons/logo-48.png
convert -resize 60x60! $< img/icons/logo-60.png
convert -resize 128x128! $< img/icons/logo-128.png
run: index.html
firefox index.html