#!/usr/bin/make -f STEMS = cycle json2 json_parse json_parse_state override_dh_auto_build: $(patsubst %, %.min.js.gz, $(STEMS)) # unset bogus executable bits override_dh_fixperms: dh_fixperms chmod --recursive a-x,a+X -- debian/*/usr/share/javascript # optimize JavaScript for browser use # * include source-map %.min.js: %.js uglifyjs --compress --mangle \ --source-map "url='$*.min.map'" \ --output $@ \ -- $< # pre-compress for browser use %.gz: % pigz --force --keep -11 -- $< brotli --force --keep --best -- $< %: dh $@ .SECONDARY: