File: rules

package info (click to toggle)
java-imaging-utilities 0.14.3-2
  • links: PTS
  • area: main
  • in suites: stretch
  • size: 2,500 kB
  • ctags: 3,737
  • sloc: java: 31,233; python: 71; xml: 30; makefile: 27; sh: 5
file content (42 lines) | stat: -rwxr-xr-x 1,372 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#!/usr/bin/make -f

# Create versioned jar file; strip off the debian source revision and package revision
VERSION=$(shell dpkg-parsechangelog | sed -n 's/Version: \([0-9.]*\).*/\1/p')

# If the user has not explicitly set JAVA_HOME, export sensible value
# to make sure that the correct compiler is used by ant.
JAVA_HOME ?= /usr/lib/jvm/java-gcj
export JAVA_HOME

# Set the locale to make API documentation reproducible
LC_ALL = C.UTF-8
export LC_ALL

# Force pdflatex to use SOURCE_DATE_EPOCH for \today too
FORCE_SOURCE_DATE = 1
export FORCE_SOURCE_DATE

%:
	dh $@

override_dh_auto_build:
	ant -DVERSION=$(VERSION) -Dbasedir=. -f debian/build.xml jar
	JAVA_HOME=/usr/lib/jvm/default-java \
	  ant -DVERSION=$(VERSION) -Dbasedir=. -f debian/build.xml doc
	cd doc/manual                            ; \
	pdflatex java-imaging-utilities-manual   ; \
	pdflatex java-imaging-utilities-manual

override_dh_auto_clean:
	find . -name \*.jar -exec rm -f {} \;
	find . -name \*.class -exec rm -f {} \;
	rm -f doc/manual/*.aux doc/manual/*.log doc/manual/*.out doc/manual/*.pdf doc/manual/*.toc
	rm -rf api

override_dh_link:
	dh_link -p libjiu-java usr/share/java/net.sourceforge.jiu-$(VERSION).jar usr/share/java/net.sourceforge.jiu.jar

override_dh_auto_test:
	for cmd in '--version' '--system' '--help'; do \
	    java -jar net.sourceforge.jiu-$(VERSION).jar $$cmd ; \
	done