]> git.proxmox.com Git - mirror_zfs-debian.git/blob - debian/rules
Override dh_shlibdeps warnings.
[mirror_zfs-debian.git] / debian / rules
1 #!/usr/bin/make -f
2
3 NAME := $(shell awk '/^Name:/{print $$2}' META)
4 VERSION := $(shell awk '/^Version:/{print $$2}' META)
5
6 %:
7 dh $@
8
9 override_dh_auto_configure:
10 # Build the userland, but don't build the kernel modules.
11 ./configure \
12 --prefix=/ \
13 --bindir=/lib/udev \
14 --libexecdir=/usr/libexec \
15 --libdir=/lib \
16 --includedir=/usr/include \
17 --datarootdir=/usr/share \
18 --with-config=user \
19
20 override_dh_auto_test:
21 # `make check` cannot run in an unprivileged build environment.
22
23 override_dh_auto_install:
24 # Install the utilities.
25 make install DESTDIR='$(CURDIR)/debian/tmp'
26
27 # Get a bare copy of the source code.
28 # This creates the $(CURDIR)/$(NAME)-$(VERSION)/ tree.
29 make distdir
30
31 # @FIXME: Create a distdir_modules rule.
32 #
33 # Scripts distribution is disabled because Lintian complains about
34 # having them in the DKMS sources. Stub the automake files to prevent
35 # a spurious configure error until the distdir rule can be improved.
36 mkdir -p \
37 '$(CURDIR)/$(NAME)-$(VERSION)/scripts' \
38 '$(CURDIR)/$(NAME)-$(VERSION)/scripts/zpios-profile' \
39 '$(CURDIR)/$(NAME)-$(VERSION)/scripts/zpios-test' \
40 '$(CURDIR)/$(NAME)-$(VERSION)/scripts/zpool-config' \
41 '$(CURDIR)/$(NAME)-$(VERSION)/scripts/zpool-layout'
42 touch \
43 '$(CURDIR)/$(NAME)-$(VERSION)/scripts/common.sh.in' \
44 '$(CURDIR)/$(NAME)-$(VERSION)/scripts/Makefile.in' \
45 '$(CURDIR)/$(NAME)-$(VERSION)/scripts/zpios-profile/Makefile.in' \
46 '$(CURDIR)/$(NAME)-$(VERSION)/scripts/zpios-test/Makefile.in' \
47 '$(CURDIR)/$(NAME)-$(VERSION)/scripts/zpool-config/Makefile.in' \
48 '$(CURDIR)/$(NAME)-$(VERSION)/scripts/zpool-layout/Makefile.in'
49
50 # This shunt allows DKMS to delete header files that are peculiar
51 # to each module instance through the POST_REMOVE directive in the
52 # dkms.conf file.
53 echo '#!/bin/sh' >'$(CURDIR)/$(NAME)-$(VERSION)/rm'
54 echo 'rm "$$@"' >>'$(CURDIR)/$(NAME)-$(VERSION)/rm'
55 chmod 755 '$(CURDIR)/$(NAME)-$(VERSION)/rm'
56
57 # Install the DKMS source.
58 mkdir -p '$(CURDIR)/debian/tmp/usr/src/'
59 mv '$(CURDIR)/$(NAME)-$(VERSION)' '$(CURDIR)/debian/tmp/usr/src/'
60
61 # Install the dkms.conf file.
62 dh_dkms -V $(VERSION)
63
64 # Install the init.d file.
65 dh_installinit --name=zfs
66
67 override_dh_shlibdeps:
68 dh_shlibdeps -- --warnings=0