#!/usr/bin/make -f include /usr/share/dpkg/pkg-info.mk export BUILD_TIME := $(shell LC_ALL=C date --date=@$(SOURCE_DATE_EPOCH) --utc +'%A %b %-d, %Y at %H:%M:%S %Z') ASCIIDOCTOR_OPTS := -a nofooter -a webfonts! -a toc=left -a toclevels=5 %: dh $@ override_dh_auto_configure: # Setup symlinks: ant mkdir -p lib/ant/lib ln -sf /usr/share/ant/lib/ant.jar lib/ant/lib # JUnit mkdir -p lib/junit ln -sf /usr/share/java/junit.jar lib/junit # commons-logging mkdir -p lib/commons ln -sf /usr/share/java/commons-logging.jar lib/commons/commons.jar dh_auto_configure override_dh_auto_build: # Build the manpages docbook-to-man debian/aj.sgml > debian/aj.1 docbook-to-man debian/ajbrowser.sgml > debian/ajbrowser.1 asciidoctor -b manpage -D debian debian/ajc.adoc debian/ajdoc.adoc dh_auto_build # Build the documentation for guide in adk15notebook devguide pdguide progguide; do \ asciidoctor $(ASCIIDOCTOR_OPTS) -D aj-build/dist/docs/doc/$$guide docs/$$guide/*.adoc; \ done asciidoctor $(ASCIIDOCTOR_OPTS) -D aj-build/dist/docs/doc docs/release/*.adoc cp -r docs/progguide/images aj-build/dist/docs/doc/progguide/ cp -r docs/release/images aj-build/dist/docs/doc/ override_dh_auto_install: mh_installpom -plibaspectj-java -e$(DEB_VERSION_UPSTREAM) aspectjrt/target/flattened-pom.xml mh_installjar -plibaspectj-java -e$(DEB_VERSION_UPSTREAM) -l aspectjrt/target/flattened-pom.xml aspectjrt/target/aspectjrt-$(DEB_VERSION_UPSTREAM).jar mh_installpom -plibaspectj-java -e$(DEB_VERSION_UPSTREAM) aspectjtools/target/flattened-pom.xml mh_installjar -plibaspectj-java -e$(DEB_VERSION_UPSTREAM) -l aspectjtools/target/flattened-pom.xml aspectjtools/target/aspectjtools-$(DEB_VERSION_UPSTREAM).jar mh_installpom -plibaspectj-java -e$(DEB_VERSION_UPSTREAM) aspectjweaver/target/flattened-pom.xml mh_installjar -plibaspectj-java -e$(DEB_VERSION_UPSTREAM) -l aspectjweaver/target/flattened-pom.xml aspectjweaver/target/aspectjweaver-$(DEB_VERSION_UPSTREAM).jar cp aj-build/dist/docs/doc/changes.html docs/target/changelog.html html2text -o docs/target/changelog.txt docs/target/changelog.html dh_installchangelogs docs/target/changelog.html dh_installchangelogs docs/target/changelog.txt