File: rules

package info (click to toggle)
king 2.24%2Bdfsg2-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 78,572 kB
  • sloc: java: 111,577; xml: 1,868; cpp: 209; perl: 127; sh: 102; python: 99; makefile: 60; ansic: 7
file content (64 lines) | stat: -rwxr-xr-x 2,254 bytes parent folder | download | duplicates (3)
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
#!/usr/bin/make -f
# -*- makefile -*-

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

%:
	dh $@ --with javahelper

override_dh_auto_configure:
	dh_auto_configure
	# Converting my home-made svg icons into png ones
	cd debian/icons && \
	        for F in $$(ls *.svg); do \
	                inkscape -o $${F%%.svg}.png $$F; \
	        done && \
	        mv *.png ../../king/resource/king/images/

override_dh_auto_build:
	# Build the native lib
	cd quickies/native/ && \
	        gcc -shared -I/usr/lib/jvm/default-java/include/ -I/usr/lib/jvm/default-java/include/linux NativeSpeed.c -o libnativespeed.so
	# Build the pdf docs from lyx and tex files.
	debian/makePdfDoc
	# create backups of original buildnum resources to enable building twice in a row
	for component in chiropraxis driftwood extratools king molikin ; do \
	  if [ -e $$component/resource/$$component/buildnum.props ] ; then \
	    cp -a $$component/resource/$$component/buildnum.props $$component/resource/$$component/buildnum.props.orig ; \
	  fi ; \
	done
	mkdir -p lib
	ant -buildfile chiropraxis/build.xml
	ant -buildfile extratools/build.xml
	ant -buildfile king/build.xml dist-exe

override_dh_auto_clean:
	mkdir -p king/plugins
	ant -buildfile king/build.xml clean
	ant -buildfile chiropraxis/build.xml clean
	ant -buildfile driftwood/build.xml clean
	ant -buildfile extratools/build.xml clean
	ant -buildfile molikin/build.xml clean
	rm -rf king_jar

	# Removing the png icons we created from our set of DFSG-free icons
	if [ -e king/resource/king/images/Add16.png ]; then \
	        find king/resource/king/images -name "*.png" | grep -E '[A-Z][a-z]*[0-9]{2}.png' | xargs rm ; \
	fi

	# restore backups of original buildnum resources to enable building twice in a row
	for component in chiropraxis driftwood extratools king molikin ; do \
	  rm -rf $$component/resource/$$component/buildnum.props ; \
	  if [ -e $$component/resource/$$component/buildnum.props.orig ] ; then \
	    mv $$component/resource/$$component/buildnum.props.orig $$component/resource/$$component/buildnum.props ; \
	  fi ; \
	done

	find . -name "*.class" -delete
	rm -rf lib
	rm -rf king/plugins
	-rm quickies/native/libnativespeed.so

override_dh_compress:
	dh_compress --exclude=.pdf