]> git.sven.stormbind.net Git - sven/java-package.git/blob - debian/rules
Support of .jinfo for udpate-java-alternatives tool
[sven/java-package.git] / debian / rules
1 #!/usr/bin/make -f
2 # debian/rules for java-package
3
4 # Uncomment this to turn on verbose mode.
5 #export DH_VERBOSE=1
6
7 # Extract source package version number from changelog
8 VERSION := $(shell head -n 1 $(CURDIR)/debian/changelog | sed 's/.*(//;s/).*//')
9 B := $(CURDIR)/debian/java-package
10
11 build: build-stamp 
12
13 build-stamp:
14         dh_testdir
15         # Add here commands to compile the indep part of the package.
16         sed s/@VERSION@/$(VERSION)/ make-jpkg > make-jpkg.out
17         touch $@
18
19 clean:
20         dh_testdir
21         dh_testroot
22         rm -f build-stamp SUPPORTED make-jpkg.out debian/semantic.cache
23         dh_clean
24
25 install: build
26         dh_testdir
27         dh_testroot
28         dh_clean -k
29         dh_installdirs
30
31         install -m 755 make-jpkg.out $(B)/usr/bin/make-jpkg
32         cp lib/*.sh $(B)/usr/share/java-package/
33         find $(B) -type d -name .svn | xargs -r rm -r
34
35 # Generate SUPPORTED
36         echo "java-package currently supports the following binary packages:" > SUPPORTED
37         echo >> SUPPORTED
38         echo "(This list is automatically generated, do not edit)" >> SUPPORTED
39         echo >> SUPPORTED
40         grep -h "SUPPORTED$$" $(wildcard $(CURDIR)/lib/*-*.sh) | sed 's/"//g;s/).*//' >> SUPPORTED
41
42         dh_install
43
44 binary: binary-indep
45
46 binary-arch:
47
48 binary-indep: build install
49         dh_testdir
50         dh_testroot
51         dh_installchangelogs 
52         dh_installdocs
53         dh_installman make-jpkg.1
54         dh_link
55 #       dh_strip
56         dh_compress 
57         dh_fixperms
58         dh_makeshlibs
59         dh_installdeb
60         dh_shlibdeps
61         dh_gencontrol
62         dh_md5sums
63         dh_builddeb
64
65 .PHONY: build clean binary-indep binary install