--- /dev/null
+CLOSURE = closure-compiler --language_in ECMASCRIPT5
+
+all:
+
+%.js.min: %.js
+ $(CLOSURE) $< > $@
+
+JS_FILES = $(shell grep '[.]js$$' manifest.files)
+js-min: $(JS_FILES:=.min)
+
+check: js-min
+
+.PHONY: all clean check js-min
[[ ${line} == */* ]] && mkdir -p "${P}/${line%/*}"
ln "${line}" "${P}/${line}"
done < <(sed 's:#.*::' manifest.files)
-cp manifest.json "${P}/"
+cp Makefile manifest.files manifest.json "${P}/"
+
+make -C "${P}" -j js-min
+while read line ; do
+ mv "${line}.min" "${line}"
+done < <(find "${P}" -name '*.js')
+rm "${P}"/{manifest.files,Makefile}
sed -i \
-e '/"version"/s:"[^"]*",:"'${PVR}'",:' \