Code

* first try at debianization
[fusedav.git] / debian / rules
1 #!/usr/bin/make -f
3 # Uncomment this to turn on verbose mode.
4 #export DH_VERBOSE=1
6 # These are used for cross-compiling and for saving the configure script
7 # from having to guess our platform (since we know it already)
8 DEB_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
9 DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
12 CFLAGS = -Wall -g
14 ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
15         CFLAGS += -O0
16 else
17         CFLAGS += -O2
18 endif
20 config.status: configure
21         dh_testdir
22         CFLAGS="$(CFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) --prefix=/usr --mandir=\$${prefix}/share/man --infodir=\$${prefix}/share/info
24 build: build-stamp
26 build-stamp:  config.status
27         dh_testdir
28         $(MAKE)
29         touch build-stamp
31 clean:
32         dh_testdir
33         dh_testroot
34         rm -f build-stamp 
35         -$(MAKE) distclean
36 ifneq "$(wildcard /usr/share/misc/config.sub)" ""
37         cp -f /usr/share/misc/config.sub config.sub
38 endif
39 ifneq "$(wildcard /usr/share/misc/config.guess)" ""
40         cp -f /usr/share/misc/config.guess config.guess
41 endif
42         dh_clean 
44 install: build
45         dh_testdir
46         dh_testroot
47         dh_clean -k 
48         dh_installdirs
49         $(MAKE) install DESTDIR=$(CURDIR)/debian/fusedav
51 binary-indep: build install
53 binary-arch: build install
54         dh_testdir
55         dh_testroot
56         dh_installchangelogs
57         dh_installdocs
58         dh_installman
59         dh_link
60         dh_strip
61         dh_compress
62         dh_fixperms
63         dh_installdeb
64         dh_shlibdeps
65         dh_gencontrol
66         dh_md5sums
67         dh_builddeb
69 binary: binary-indep binary-arch
70 .PHONY: build clean binary-indep binary-arch binary install