| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
ifeq (,$(filter nodoc,$(DEB_BUILD_OPTIONS))) |
| 5 |
DOCS = README.html README.txt |
| 6 |
CHANGELOGS = History.html History.txt |
| 7 |
endif |
| 8 |
|
| 9 |
GRUNT = grunt --no-color |
| 10 |
|
| 11 |
%: |
| 12 |
dh $@ |
| 13 |
|
| 14 |
%.html: %.md |
| 15 |
pandoc --from gfm-raw_html --to html --standalone --output $@ $< |
| 16 |
|
| 17 |
%.txt: %.md |
| 18 |
pandoc --from gfm-raw_html --to plain --output $@ $< |
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
%.min.js: %.js |
| 23 |
uglifyjs --compress --mangle \ |
| 24 |
--source-map "url='$*.min.map'" \ |
| 25 |
--output $@ \ |
| 26 |
-- $< |
| 27 |
|
| 28 |
|
| 29 |
%.gz: % |
| 30 |
pigz --force --keep -11 -- $< |
| 31 |
brotli --force --keep --best --suffix=.brotli -- $< |
| 32 |
|
| 33 |
dist/qunit.js: |
| 34 |
$(GRUNT) concat:src-js concat:src-css |
| 35 |
|
| 36 |
override_dh_auto_build: $(DOCS) $(CHANGELOGS) dist/qunit.min.js.gz |
| 37 |
sed -i '/ Date: /d' dist/qunit.* |
| 38 |
|
| 39 |
override_dh_auto_test: |
| 40 |
$(GRUNT) test-on-node |
| 41 |
|
| 42 |
override_dh_installdocs: |
| 43 |
dh_installdocs --all -- $(DOCS) |
| 44 |
|
| 45 |
override_dh_installchangelogs: |
| 46 |
dh_installchangelogs -- $(CHANGELOGS) |
| 47 |
|
| 48 |
override_dh_clean: |
| 49 |
dh_clean -- $(DOCS) $(CHANGELOGS) |
| 50 |
|
| 51 |
.SECONDARY: |