Codebase list findbugs / 64363ba debian / rules
64363ba

Tree @64363ba (Download .tar.gz)

rules @64363baraw · history · blame

#!/usr/bin/make -f
# -*- makefile -*-

# Uncomment this to turn on verbose mode.
export DH_VERBOSE=1
#JAVA_HOME = /usr/lib/jvm/default-java

%:
	dh $@ --with maven_repo_helper

override_dh_auto_build:
	ant docs build -Dant.java.version=1.8

override_dh_auto_install:
	chmod -x $(CURDIR)/bin/findbugs.ico

	mkdir -p $(CURDIR)/debian/findbugs/usr/bin

	# install docs here
	mkdir -p $(CURDIR)/debian/findbugs/usr/share/doc/findbugs
	cp -Rv $(CURDIR)/build/doc/manual $(CURDIR)/debian/findbugs/usr/share/doc/findbugs/html

	dh_install --sourcedir=$(CURDIR)
	dh_link

	mh_installpom -pfindbugs debian/poms/findbugs-annotations.pom
	mh_installjar -pfindbugs debian/poms/findbugs-annotations.pom \
		--usj-name=findbugs-annotations -l lib/annotations.jar

	# prepare findbugs.1
	help2man -h "-help" -v "-version" \
		-n "Static Java Code Analyzer" \
		$(CURDIR)/debian/findbugs/usr/bin/fb \
		-o $(CURDIR)/debian/fb.1
	help2man -h "-textui" -v "-version" \
		-n "Static Java Code Analyzer" \
		$(CURDIR)/debian/findbugs/usr/bin/findbugs \
		-o $(CURDIR)/debian/findbugs.1

override_dh_auto_clean:
	rm -f $(CURDIR)/debian/findbugs.1 $(CURDIR)/debian/fb.1
	rm -f lib/*.jar
	rm -rf classesEclipse/
	rm -f src/doc/allBugDescriptions.html src/doc/bugDescriptions.html src/doc/bugDescriptions_??.html
	dh_auto_clean

override_dh_auto_test:
	ant test -Dant.java.version=1.8
	dh_auto_test