]> git.proxmox.com Git - zfsonlinux.git/blame - spl-patches/0001-remove-DKMS-and-module-build.patch
zfs/debian: add packaging files
[zfsonlinux.git] / spl-patches / 0001-remove-DKMS-and-module-build.patch
CommitLineData
6efadbff 1From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
23db3640
FG
2From: =?UTF-8?q?Fabian=20Gr=C3=BCnbichler?= <f.gruenbichler@proxmox.com>
3Date: Wed, 12 Oct 2016 10:57:39 +0200
4495daac 4Subject: [PATCH] remove DKMS and module build
2d5ff411
FG
5MIME-Version: 1.0
6Content-Type: text/plain; charset=UTF-8
7Content-Transfer-Encoding: 8bit
23db3640 8
2d5ff411 9Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
ad41a699 10Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
23db3640 11---
4e389d45 12 debian/control.in | 31 ----------------------
8dbff718 13 debian/control | 1 -
4e389d45 14 debian/rules | 67 +----------------------------------------------
ad41a699 15 3 files changed, 1 insertion(+), 98 deletions(-)
2d5ff411 16
23db3640 17diff --git a/debian/control.in b/debian/control.in
ad41a699 18index 0e6c3fc..c8fe170 100644
23db3640
FG
19--- a/debian/control.in
20+++ b/debian/control.in
ad41a699 21@@ -9,47 +9,16 @@ Build-Depends: autogen,
23db3640
FG
22 autotools-dev,
23 debhelper (>= 9),
24 dh-autoreconf,
25- dkms (>> 2.2.0.2-1~),
26 libtool
4495daac 27 Standards-Version: 4.1.2
23db3640 28 Homepage: http://www.zfsonlinux.org/
ad41a699 29 Vcs-Git: https://salsa.debian.org/zfsonlinux-team/spl.git
83240547 30 Vcs-Browser: https://salsa.debian.org/zfsonlinux-team/spl
e479455e
DM
31
32-Package: spl-dkms
33-Architecture: all
83240547
FG
34-Depends: dkms (>> 2.2.1.0),
35- file,
36- libc-dev,
37- libelf-dev,
38- lsb-release,
39- ${misc:Depends}
fccda2b9 40-Suggests: spl (>= ${source:Upstream-Version}),
83240547 41- @LINUX_COMPAT@
fccda2b9 42-Conflicts: spl (<< 0.7.9~)
e479455e
DM
43-Provides: spl-modules
44-Description: Solaris Porting Layer kernel modules for Linux
45- The Solaris Porting Layer (SPL) is a Linux kernel module which provides
46- many of the Solaris kernel APIs. This shim layer makes it possible to
47- run Solaris kernel code in the Linux kernel with relatively minimal
48- modification. The Solaris Porting LAyer Tests (SPLAT) is a Linux kernel
49- module which provides a testing harness for the SPL module.
50- .
51- SPL can be particularly useful when you want to track upstream Illumos
52- (or any other OpenSolaris fork) development closely and don't want the
53- overhead of maintaining a large patch which converts Solaris primitives
54- to Linux primitives.
55- .
56- This package contains the source code for the SPL and SPLAT Linux kernel
57- modules, which can be used with DKMS, so that local kernel modules are
58- automatically built and installed every time the kernel packages are
59- upgraded.
60-
61 Package: spl
62 Architecture: linux-any
23db3640
FG
63 Conflicts: spl-dev, splat
64 Depends: ${misc:Depends}, ${shlibs:Depends}
e479455e
DM
65-Recommends: spl-modules | spl-dkms
66 Description: Solaris Porting Layer user-space utilities for Linux
67 The Solaris Porting Layer (SPL) is a Linux kernel module which provides
68 many of the Solaris kernel APIs. This shim layer makes it possible to
4e389d45
FG
69diff --git a/debian/control b/debian/control
70index d83f962..f780c80 100644
71--- a/debian/control
72+++ b/debian/control
73@@ -9,7 +9,6 @@ Build-Depends: autogen,
74 autotools-dev,
75 debhelper (>= 9),
76 dh-autoreconf,
77- dkms (>> 2.2.0.2-1~),
78 libtool
79 Standards-Version: 4.1.2
80 Homepage: http://www.zfsonlinux.org/
23db3640 81diff --git a/debian/rules b/debian/rules
ad41a699 82index 72ded49..5abeebb 100755
23db3640
FG
83--- a/debian/rules
84+++ b/debian/rules
ad41a699 85@@ -14,11 +14,8 @@ ifndef KVERS
23db3640 86 KVERS=$(shell uname -r)
787716f7
DM
87 endif
88
23db3640 89-non_epoch_version=$(shell echo $(KVERS) | perl -pe 's/^\d+://')
ad41a699 90-pmodules = $(NAME)-modules-$(non_epoch_version)
23db3640 91-
e479455e 92 %:
23db3640
FG
93- dh $@ --with dkms,autoreconf --parallel
94+ dh $@ --with autoreconf --parallel
e479455e 95
23db3640 96 override_dh_auto_configure:
ad41a699
SI
97 sed "s/@LINUX_COMPAT@/linux-libc-dev \(<< $(LINUX_NEXT)~\)/" debian/control.in > debian/control
98@@ -44,69 +41,7 @@ override_dh_auto_install:
23db3640
FG
99 @# This creates the $(CURDIR)/$(NAME)-$(VERSION)/ tree.
100 $(MAKE) distdir
e479455e 101
e479455e
DM
102- @# This shunt allows DKMS to install the Module.symvers and spl_config.h
103- @# files to the ${dkms_tree} area through the POST_INSTALL directive.
23db3640
FG
104- echo '#!/bin/sh' >'$(CURDIR)/$(NAME)-$(VERSION)/cp'
105- echo 'cp "$$@"' >>'$(CURDIR)/$(NAME)-$(VERSION)/cp'
106- chmod 755 '$(CURDIR)/$(NAME)-$(VERSION)/cp'
107-
108- # Install the DKMS source.
109- mkdir -p '$(CURDIR)/debian/tmp/usr/src/'
110- mv '$(CURDIR)/$(NAME)-$(VERSION)' '$(CURDIR)/debian/tmp/usr/src/'
111-
112-override_dh_dkms:
113- dh_dkms -V $(VERSION)
114-
115 override_dh_auto_clean:
116 dh_auto_clean
117 @if test -e META.orig; then mv META.orig META; fi
ad41a699 118 sed "s/@LINUX_COMPAT@/linux-libc-dev \(<< $(LINUX_NEXT)~\)/" debian/control.in > debian/control
23db3640
FG
119-
120-# ------------
121-
122-override_dh_prep-deb-files:
123- for templ in $(wildcard $(CURDIR)/debian/*_KVERS_*.in); do \
124- sed -e 's/##KVERS##/$(KVERS)/g ; s/#KVERS#/$(KVERS)/g ; s/_KVERS_/$(KVERS)/g ; s/##KDREV##/$(KDREV)/g ; s/#KDREV#/$(KDREV)/g ; s/_KDREV_/$(KDREV)/g ; s/_ARCH_/$(DEB_HOST_ARCH)/g' \
125- < $$templ > `echo $$templ | sed -e 's/_KVERS_/$(KVERS)/g ; s/_ARCH_/$(DEB_HOST_ARCH)/g ; s/\.in$$//'` ; \
126- done
127- sed -e 's/##KVERS##/$(KVERS)/g ; s/#KVERS#/$(KVERS)/g ; s/_KVERS_/$(KVERS)/g ; s/##KDREV##/$(KDREV)/g ; s/#KDREV#/$(KDREV)/g ; s/_KDREV_/$(KDREV)/g ; s/_ARCH_/$(DEB_HOST_ARCH)/g' \
128- < debian/control.modules.in > debian/control
129-
130-override_dh_configure_modules: override_dh_configure_modules_stamp
131-override_dh_configure_modules_stamp:
132- ./configure --with-config=kernel --with-linux=$(KSRC) \
133- --with-linux-obj=$(KOBJ) \
134- --disable-debug-kmem
135- touch override_dh_configure_modules_stamp
136-
137-override_dh_binary-modules-udeb: override_dh_prep-deb-files override_dh_configure_modules
138- dh_testdir
139- dh_testroot
140- dh_prep
141-
142- $(MAKE) -C $(CURDIR)/module modules
143-
144- dh_installdirs -p${pmodules}-di
145- dh_install -p${pmodules}-di
146- dh_gencontrol -p${pmodules}-di
147-
148- dh_builddeb -p${pmodules}-di
149-
150-override_dh_binary-modules: override_dh_prep-deb-files override_dh_configure_modules
151- dh_testdir
152- dh_testroot
153- dh_prep
154-
155- $(MAKE) -C $(CURDIR)/module modules
156-
157- dh_installdocs -p${pmodules}
158- dh_install -p${pmodules}
159- dh_installchangelogs -p${pmodules}
160- dh_compress -p${pmodules}
161- dh_strip -p${pmodules}
162- dh_fixperms -p${pmodules}
163- dh_installdeb -p${pmodules}
164- dh_gencontrol -p${pmodules}
165- dh_md5sums -p${pmodules}
166-
167- dh_builddeb -p${pmodules}