]> git.proxmox.com Git - mirror_spl-debian.git/commitdiff
Initial master branch for git-buildpackage.
authorDarik Horn <dajhorn@vanadac.com>
Tue, 22 Feb 2011 16:13:11 +0000 (10:13 -0600)
committerDarik Horn <dajhorn@vanadac.com>
Tue, 22 Feb 2011 16:13:11 +0000 (10:13 -0600)
14 files changed:
debian/changelog [new file with mode: 0644]
debian/compat [new file with mode: 0644]
debian/control [new file with mode: 0644]
debian/dkms [new file with mode: 0644]
debian/patches/kludge-version.patch [new file with mode: 0644]
debian/patches/series [new file with mode: 0644]
debian/patches/use-linux-flock-struct.patch [new file with mode: 0644]
debian/rules [new file with mode: 0755]
debian/source/format [new file with mode: 0644]
debian/spl-dkms.install [new file with mode: 0644]
debian/spl-dkms.postinst [new file with mode: 0644]
debian/spl-dkms.prerm [new file with mode: 0644]
debian/spl.install [new file with mode: 0644]
debian/watch [new file with mode: 0644]

diff --git a/debian/changelog b/debian/changelog
new file mode 100644 (file)
index 0000000..a6108da
--- /dev/null
@@ -0,0 +1,26 @@
+spl-linux (0.6.0.1rc-1~maverick.2) maverick; urgency=low
+
+  * Add use-linux-flock-struct.patch for 32-bit systems.
+    (Commit: ac35ef7e3c107e972250bcd15143328e7aef5943)
+
+ -- Darik Horn <dajhorn@vanadac.com>  Mon, 21 Feb 2011 08:48:03 -0600
+
+spl-linux (0.6.0.1rc-1~lucid.1) lucid; urgency=low
+
+  * Upstream spl-0.6.0-rc1.tar.gz release.
+  * Kludge the "rc1" version for packaging convenience.
+
+ -- Darik Horn <dajhorn@vanadac.com>  Fri, 18 Feb 2011 19:10:09 -0600
+
+spl-linux (0.5.2-1~lucid.7) lucid; urgency=low
+
+  * Add conflict for spl-dev, which is a package in universe
+    that also installs a /usr/lib/libspl.a file.
+
+ -- Darik Horn <dajhorn@vanadac.com>  Fri, 18 Feb 2011 17:43:52 -0600
+
+spl-linux (0.5.2-1~lucid.6) lucid; urgency=low
+
+  * Initial DKMS packaging for Debian and Ubuntu.
+
+ -- Darik Horn <dajhorn@vanadac.com>  Thu, 17 Feb 2011 18:57:36 -0600
diff --git a/debian/compat b/debian/compat
new file mode 100644 (file)
index 0000000..7f8f011
--- /dev/null
@@ -0,0 +1 @@
+7
diff --git a/debian/control b/debian/control
new file mode 100644 (file)
index 0000000..b8568c0
--- /dev/null
@@ -0,0 +1,22 @@
+Source: spl-linux
+Section: kernel
+Priority: extra
+Maintainer: Darik Horn <dajhorn@vanadac.com>
+Build-Depends: autotools-dev, debhelper, dkms, gawk, linux-headers-generic
+Standards-Version: 3.8.4
+Homepage: http://www.zfsonlinux.org/
+Vcs-Git: git://github.com/behlendorf/spl.git
+Vcs-Browser: https://github.com/behlendorf/spl/
+
+Package: spl-dkms
+Architecture: all
+Depends: ${shlibs:Depends}, ${misc:Depends}, dkms
+Recommends: spl
+Description: Solaris Porting Layer kernel modules for Linux
+
+Package: spl
+Architecture: any
+Conflicts: spl-dev
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Recommends: spl-dkms
+Description: Solaris Porting Layer utilities for Linux
diff --git a/debian/dkms b/debian/dkms
new file mode 100644 (file)
index 0000000..c77e85e
--- /dev/null
@@ -0,0 +1,14 @@
+AUTOINSTALL="yes"
+PACKAGE_NAME="spl"
+PACKAGE_VERSION="#MODULE_VERSION#"
+PRE_BUILD="configure --prefix=/usr --with-config=kernel --with-linux=${kernel_source_dir} --with-linux-obj=${kernel_source_dir}"
+POST_REMOVE="rm -r /usr/src/spl-#MODULE_VERSION#/${kernelver}"
+REMAKE_INITRD="no"
+MAKE[0]="make && make install-data-local && make -C include install"
+BUILT_MODULE_NAME[0]="spl"
+BUILT_MODULE_LOCATION[0]="module/spl/"
+DEST_MODULE_LOCATION[0]="/extra/spl/spl"
+MAKE[1]="true"
+BUILT_MODULE_NAME[1]="splat"
+BUILT_MODULE_LOCATION[1]="module/splat/"
+DEST_MODULE_LOCATION[1]="/extra/spl/splat"
diff --git a/debian/patches/kludge-version.patch b/debian/patches/kludge-version.patch
new file mode 100644 (file)
index 0000000..9e831f3
--- /dev/null
@@ -0,0 +1,12 @@
+Index: spl-linux-0.6.0.1rc/META
+===================================================================
+--- spl-linux-0.6.0.1rc.orig/META      2011-02-18 19:28:53.352179001 -0600
++++ spl-linux-0.6.0.1rc/META   2011-02-18 19:29:03.202179002 -0600
+@@ -1,6 +1,6 @@
+ Meta:         1
+ Name:         spl
+ Branch:       1.0
+-Version:      0.6.0
++Version:      0.6.0.1rc
+ Release:      rc1
+ Release-Tags: relext
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644 (file)
index 0000000..e10180f
--- /dev/null
@@ -0,0 +1,2 @@
+kludge-version.patch
+use-linux-flock-struct.patch
diff --git a/debian/patches/use-linux-flock-struct.patch b/debian/patches/use-linux-flock-struct.patch
new file mode 100644 (file)
index 0000000..277f1d8
--- /dev/null
@@ -0,0 +1,22 @@
+diff --git a/include/sys/fcntl.h b/include/sys/fcntl.h
+index c7bc02a..4e260a4 100644
+--- a/include/sys/fcntl.h
++++ b/include/sys/fcntl.h
+@@ -28,12 +28,10 @@
+ #define F_FREESP 11
+-typedef struct flock64 {
+-      short   l_type;
+-      short   l_whence;
+-      loff_t  l_start;
+-      loff_t  l_len;
+-      pid_t   l_pid;
+-} flock64_t;
++#ifdef CONFIG_64BIT
++typedef struct flock flock64_t;
++#else
++typedef struct flock64 flock64_t;
++#endif /* CONFIG_64BIT */
+ #endif /* _SPL_FCNTL_H */
diff --git a/debian/rules b/debian/rules
new file mode 100755 (executable)
index 0000000..c1c2f19
--- /dev/null
@@ -0,0 +1,42 @@
+#!/usr/bin/make -f
+
+NAME := $(shell awk '/^Name:/{print $$2}' META)
+VERSION := $(shell awk '/^Version:/{print $$2}' META)
+
+%:
+       dh $@
+
+override_dh_auto_configure:
+       # Build the userland, but don't build the kernel modules.
+       ./configure --prefix=/usr --with-config=user
+       
+override_dh_auto_test:
+       # scripts/check.sh tries insmod and rmmod, so it cannot
+       # run in an unprivileged build environment.
+
+override_dh_auto_install:
+       # Install the utilities.
+       make install DESTDIR='$(CURDIR)/debian/tmp'
+
+       # Get a bare copy of the source code. This creates the $(CURDIR)/$(NAME)-$(VERSION)/ tree.
+       make distdir
+
+       # This shunt allows DKMS to delete header files that are peculiar to each
+       # module instance through the POST_REMOVE directive in the dkms.conf file.
+       echo '#!/bin/sh'  >'$(CURDIR)/$(NAME)-$(VERSION)/rm'
+       echo 'rm "$$@"'  >>'$(CURDIR)/$(NAME)-$(VERSION)/rm'
+       chmod 755 '$(CURDIR)/$(NAME)-$(VERSION)/rm'
+
+       # Install the DKMS source.
+       mkdir -p '$(CURDIR)/debian/tmp/usr/src/'
+       mv '$(CURDIR)/$(NAME)-$(VERSION)' '$(CURDIR)/debian/tmp/usr/src/'
+
+       # Install the dkms.conf file.
+       dh_dkms -V $(VERSION)
+
+       # @FIXME: `make distclean` fails when --with-config=user is set.
+       # Kludge by creating dummy makefiles.
+       echo 'distclean:'         >$(CURDIR)/include/Makefile
+       echo '  -rm -f Makefile' >>$(CURDIR)/include/Makefile
+       echo 'distclean:'         >$(CURDIR)/module/Makefile
+       echo '  -rm -f Makefile' >>$(CURDIR)/module/Makefile
diff --git a/debian/source/format b/debian/source/format
new file mode 100644 (file)
index 0000000..163aaf8
--- /dev/null
@@ -0,0 +1 @@
+3.0 (quilt)
diff --git a/debian/spl-dkms.install b/debian/spl-dkms.install
new file mode 100644 (file)
index 0000000..b601f22
--- /dev/null
@@ -0,0 +1 @@
+usr/src
diff --git a/debian/spl-dkms.postinst b/debian/spl-dkms.postinst
new file mode 100644 (file)
index 0000000..6ba2336
--- /dev/null
@@ -0,0 +1,39 @@
+#!/bin/sh
+set -e
+
+NAME=spl
+PACKAGE_NAME=$NAME-dkms
+DEBVERS=$(dpkg-query -W -f='${Version}' $PACKAGE_NAME | awk -F- '{print $1}')
+VERSION=$(echo $DEBVERS |sed -e 's/[+-].*//' -e 's/~//g')
+
+ARCH=$(dpkg --print-architecture)
+case $ARCH in
+        amd64)
+                ARCH="x86_64"
+                ;;
+        i386)
+                ARCH="i686"
+                ;;
+        *)
+                echo "WARNING: unsupported arch: $ARCH"
+                ARCH="$ARCH"
+                ;;
+esac
+
+case "$1" in
+        configure)
+               /usr/lib/dkms/common.postinst $NAME $VERSION
+               exit $?
+        ;;
+
+        abort-upgrade|abort-remove|abort-deconfigure)
+        ;;
+
+        *)
+                echo "postinst called with unknown argument \`$1'" >&2
+                exit 1
+        ;;
+esac
+
+#DEBHELPER#
+
diff --git a/debian/spl-dkms.prerm b/debian/spl-dkms.prerm
new file mode 100644 (file)
index 0000000..08f73ec
--- /dev/null
@@ -0,0 +1,18 @@
+#!/bin/sh
+set -e
+
+NAME=spl
+PACKAGE_NAME=$NAME-dkms
+DEBVERS=$(dpkg-query -W -f='${Version}' $PACKAGE_NAME | awk -F- '{print $1}')
+VERSION=$(echo $DEBVERS |sed -e 's/[+-].*//' -e 's/~//g')
+
+case "$1" in
+    remove|upgrade)
+               echo "Removing all DKMS Modules"
+               dkms remove -m $NAME -v $VERSION --all > /dev/null || echo "Ignoring error"
+               echo "Done."
+        ;;
+esac
+
+#DEBHELPER#
+
diff --git a/debian/spl.install b/debian/spl.install
new file mode 100644 (file)
index 0000000..236670a
--- /dev/null
@@ -0,0 +1 @@
+usr/sbin
diff --git a/debian/watch b/debian/watch
new file mode 100644 (file)
index 0000000..b2a39f3
--- /dev/null
@@ -0,0 +1,2 @@
+version=3
+http://githubredir.debian.net/github/behlendorf/spl/([\d\.].*).tar.gz