File: rules

package info (click to toggle)
geneweb 6.05.1-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd, wheezy
  • size: 8,260 kB
  • ctags: 3,968
  • sloc: ml: 63,910; sh: 1,032; makefile: 579
file content (69 lines) | stat: -rwxr-xr-x 1,705 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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
#!/usr/bin/make -f
%:
	dh $@

PACKAGE=geneweb

WAY=$(shell if [ -f "/usr/bin/ocamlc.opt" ]; then echo "opt"; \
else echo "out"; \
fi)

ifeq ($(WAY),out)
override_dh_strip:
	# Don't strip ocaml bytecode executables
endif   


override_dh_installdeb:
	# Use of the dh-buildinfo package: see http://people.debian.org/~dirson/buildinfo/
	dh_buildinfo
	dh_installdeb
	
override_dh_auto_install:

override_dh_auto_build:
	# Move the proper makefile into place	
	cp -f `pwd`/tools/Makefile.inc.$(WAY) `pwd`/tools/Makefile.inc
	chmod a+x tools/*.sh
	$(MAKE) $(WAY)
	$(MAKE) distrib

override_dh_clean:
	rm -rf debian/iso-codes
	rm -rf debian/pobuild
	rm -f debian/geneweb.templates.tmp
	rm -f debian/geneweb.templates
	debconf-updatepo
	# Add here commands to clean up after the build process.
	[ ! -f tools/Makefile.inc ] || [ ! -f Makefile ] || $(MAKE) clean
	# Clean out cruft left by former builds
	rm -f tools/Makefile.inc
	rm -f compilation.ml
	dh_clean

override_dh_install:
	dh_install
	# Doc files go to the appropriate directory
	install -m 644 `pwd`/CHANGES \
	        `pwd`/debian/geneweb/usr/share/doc/geneweb/changelog
	# The CGI script
	chmod 755 `pwd`/debian/gwtp/usr/lib/cgi-bin/gwtp/gwtp.cgi
	# The wrappers
	chmod 755 `pwd`/debian/gwsetup/usr/lib/geneweb/gwsetup.wrapper

override_dh_installdocs:
	dh_installdocs
	# License files should not be duplicated
	rm `pwd`/debian/geneweb/usr/share/doc/geneweb/LICENSE.htm || true

override_dh_installdebconf:
	# Grab ISO 639 language code translations
	chmod u+x debian/get-iso-codes
	debian/get-iso-codes
	# Build templates
	chmod u+x debian/mktemplates
	debian/mktemplates
	dh_installdebconf

override_dh_builddeb:
	dh_builddeb -- -Zxz -Sextreme -z9