Whamcloud - gitweb
LU-10569 build: properly package lustre for Debian/Ubuntu 48/31348/17
authorJames Simmons <uja.ornl@yahoo.com>
Tue, 6 Mar 2018 20:10:56 +0000 (15:10 -0500)
committerOleg Drokin <oleg.drokin@intel.com>
Mon, 26 Mar 2018 20:39:53 +0000 (20:39 +0000)
Remove the obsolete linux-patch since patched kernels for lustre
clients have been long gone. Place only the static libraries and
*.so symlinks for the dynamic libraries in lustre-dev. The normal
dynamic libraries are placed into the utilities packages. Add in
all the missing dependencies and fix how the lustre debs are
dependent on each other. Lastly add in the missing lustre-iokit
that is present for rpm packages. Only thing missing is a package
for lustre resources which can be done at a latter time.

Test-Parameters: trivial

Change-Id: I5fd2a23bc1ae73434cef8dcf3679b50878256ab3
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Signed-off-by: Minh Diep <minh.diep@intel.com>
Reviewed-on: https://review.whamcloud.com/31348
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Thomas Stibor <t.stibor@gsi.de>
Tested-by: James Nunez <james.a.nunez@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
17 files changed:
autoMakefile.am
debian/.gitignore
debian/control
debian/control.main
debian/control.modules.in
debian/linux-patch-lustre.apply [deleted file]
debian/linux-patch-lustre.dirs [deleted file]
debian/linux-patch-lustre.kpatches [deleted file]
debian/linux-patch-lustre.unpatch [deleted file]
debian/lustre-client-modules.install
debian/lustre-client-utils.install
debian/lustre-dev.install
debian/lustre-iokit.docs [new file with mode: 0644]
debian/lustre-iokit.install [new file with mode: 0644]
debian/lustre-server-utils.install
debian/lustre-tests.install
debian/rules

index b5f7c22..fb20ce8 100644 (file)
@@ -292,11 +292,11 @@ debs: undef.h
        popd && \
        VER=$$(sed -ne '1s/^lustre (\(.*-[0-9][0-9]*\)).*$$/\1/p' debian/changelog) && \
        mkdir -p debs && \
-       mv ../linux-patch-lustre_$${VER}_all.deb ../lustre-dev_$${VER}_*.deb \
-          ../lustre-source_$${VER}_all.deb ../lustre-tests_$${VER}_*.deb \
-          ../lustre-*-utils_$${VER}_*.deb ../lustre_$${VER}.dsc \
-          ../lustre_$${VER}_*.changes ../lustre_$${VER}.tar.gz \
-          ../lustre-*-modules-$${KVERS}_$${VER}_*.deb \
+       mv ../lustre-dev_$${VER}_*.deb ../lustre-source_$${VER}_all.deb \
+          ../lustre-iokit_$${VER}_*.deb ../lustre-tests_$${VER}_*.deb \
+          ../lustre-*-utils_$${VER}_*.deb \
+          ../lustre_$${VER}.dsc ../lustre_$${VER}_*.changes \
+          ../lustre_$${VER}.tar.gz ../lustre-*-modules-$${KVERS}_$${VER}_*.deb \
           debs/
 
 if USES_DPKG
index 6391d78..3ec93ea 100644 (file)
@@ -2,12 +2,11 @@
 /*.substvars
 /.debhelper
 /files
-/linux-patch-lustre
 /lustre-dev
 /lustre-source
+/lustre-iokit
 /lustre-tests
-/lustre-tests.substvars
 /lustre-utils
-/lustre-utils.substvars
+/lustre-*.substvars
 /lustre-*-utils
 /tmp
index 30f17d0..c8a2a35 100644 (file)
@@ -4,35 +4,15 @@ Priority: optional
 Maintainer: Brian J. Murrell <brian.murrell@intel.com>
 Uploaders: Brian J. Murrell <brian.murrell@intel.com>
 Standards-Version: 3.8.3
-Build-Depends: module-assistant, libreadline-dev, debhelper (>=7.0.0), dpatch, automake (>=1.7) | automake1.7 | automake1.8 | automake1.9, libsnmp-dev, bzip2, quilt, linux-headers-generic | linux-headers | linux-headers-amd64, rsync
+Build-Depends: module-assistant, libreadline-dev, debhelper (>=7.0.0), dpatch, automake (>=1.7) | automake1.7 | automake1.8 | automake1.9, libtool, libyaml-dev, libselinux-dev, libsnmp-dev, bzip2, quilt, linux-headers-generic | linux-headers | linux-headers-amd64, rsync
 Homepage: https://wiki.hpdd.intel.com/
 Vcs-Git: git://git.hpdd.intel.com/fs/lustre-release.git
 
-Package: linux-patch-lustre
-Section: devel
-Architecture: all
-Priority: optional
-Depends: ${kpatch:Depends}
-Recommends: kernel-package, quilt
-Description: Linux kernel patch for the Lustre Filesystem
- Lustre is a scalable, secure, robust, highly-available
- cluster file system. This release is maintained by Intel Corporation
- and available from https://wiki.hpdd.intel.com/
- .
- Lustre servers require a number of patches to the core Linux kernel,
- mostly to export new functions, add features to ext3, and add
- a new locking path to the VFS. This package provides these patches
- for kernel versions 2.6.18, 2.6.21 and 2.6.22 on i386, amd64, powerpc
- and ia64 architectures.
- .
- For Lustre clients, you will also need to build a lustre-modules
- package, using the lustre-source package and module-assistant.
-
 Package: lustre-source
 Section: admin
 Architecture: all
 Priority: optional
-Depends: module-assistant, bzip2, debhelper (>= 7.0.0), libsnmp-dev, dpatch
+Depends: module-assistant, bzip2, debhelper (>= 7.0.0), libtool, libyaml-dev, libselinux-dev, libsnmp-dev, dpatch
 Description: source for Lustre filesystem client kernel modules
  Lustre is a scalable, secure, robust, highly-available cluster file system.
  This release is maintained by Intel Corporation and available from
@@ -46,7 +26,7 @@ Package: lustre-client-utils
 Section: utils
 Architecture: i386 powerpc ppc64el amd64 ia64 arm64
 Priority: optional
-Depends: ${shlibs:Depends}, ${misc:Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, libyaml-0-2, libselinux1, libsnmp30, zlib1g, perl
 Description: Userspace utilities for the Lustre filesystem (client)
  Lustre is a scalable, secure, robust, highly-available cluster file system.
  This release is maintained by Intel Corporation and available from
@@ -58,9 +38,9 @@ Description: Userspace utilities for the Lustre filesystem (client)
 
 Package: lustre-server-utils
 Section: utils
-Architecture: i386 powerpc ppc64el amd64 ia64
+Architecture: i386 powerpc ppc64el amd64 ia64 arm64
 Priority: optional
-Depends: ${shlibs:Depends}, ${misc:Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, libyaml-0-2, libselinux1, libsnmp30, zlib1g, perl
 Provides: lustre-server-utils, lustre-client-utils
 Conflicts: lustre-client-utils
 Replaces: lustre-client-utils
@@ -74,11 +54,23 @@ Description: Userspace utilities for the Lustre filesystem (server)
  If you only need to access the LFS cluster, install lustre-client-utils
  instead.
 
+Package: lustre-iokit
+Section: utils
+Architecture: i386 powerpc ppc64el amd64 ia64 arm64
+Priority: optional
+Depends: lustre-client-utils (= ${binary:Version}), python, perl, sg3-utils
+Description: Collection of benchmark tools for the Lustre filesystem
+ Lustre is a scalable, secure, robust, highly-available cluster file system.
+ This release is maintained by Intel Corporation and available from
+ https://wiki.hpdd.intel.com/
+ .
+ This package provides a collection of benchmark tools
+
 Package: lustre-tests
 Section: utils
 Architecture: i386 powerpc ppc64el amd64 ia64 arm64
 Priority: optional
-Depends: lustre-client-utils (= ${binary:Version})
+Depends: lustre-iokit (= ${binary:Version}), attr, rsync, perl, lsof
 Description: Test suite for the Lustre filesystem
  Lustre is a scalable, secure, robust, highly-available cluster file system.
  This release is maintained by Intel Corporation and available from
index 30f17d0..c8a2a35 100644 (file)
@@ -4,35 +4,15 @@ Priority: optional
 Maintainer: Brian J. Murrell <brian.murrell@intel.com>
 Uploaders: Brian J. Murrell <brian.murrell@intel.com>
 Standards-Version: 3.8.3
-Build-Depends: module-assistant, libreadline-dev, debhelper (>=7.0.0), dpatch, automake (>=1.7) | automake1.7 | automake1.8 | automake1.9, libsnmp-dev, bzip2, quilt, linux-headers-generic | linux-headers | linux-headers-amd64, rsync
+Build-Depends: module-assistant, libreadline-dev, debhelper (>=7.0.0), dpatch, automake (>=1.7) | automake1.7 | automake1.8 | automake1.9, libtool, libyaml-dev, libselinux-dev, libsnmp-dev, bzip2, quilt, linux-headers-generic | linux-headers | linux-headers-amd64, rsync
 Homepage: https://wiki.hpdd.intel.com/
 Vcs-Git: git://git.hpdd.intel.com/fs/lustre-release.git
 
-Package: linux-patch-lustre
-Section: devel
-Architecture: all
-Priority: optional
-Depends: ${kpatch:Depends}
-Recommends: kernel-package, quilt
-Description: Linux kernel patch for the Lustre Filesystem
- Lustre is a scalable, secure, robust, highly-available
- cluster file system. This release is maintained by Intel Corporation
- and available from https://wiki.hpdd.intel.com/
- .
- Lustre servers require a number of patches to the core Linux kernel,
- mostly to export new functions, add features to ext3, and add
- a new locking path to the VFS. This package provides these patches
- for kernel versions 2.6.18, 2.6.21 and 2.6.22 on i386, amd64, powerpc
- and ia64 architectures.
- .
- For Lustre clients, you will also need to build a lustre-modules
- package, using the lustre-source package and module-assistant.
-
 Package: lustre-source
 Section: admin
 Architecture: all
 Priority: optional
-Depends: module-assistant, bzip2, debhelper (>= 7.0.0), libsnmp-dev, dpatch
+Depends: module-assistant, bzip2, debhelper (>= 7.0.0), libtool, libyaml-dev, libselinux-dev, libsnmp-dev, dpatch
 Description: source for Lustre filesystem client kernel modules
  Lustre is a scalable, secure, robust, highly-available cluster file system.
  This release is maintained by Intel Corporation and available from
@@ -46,7 +26,7 @@ Package: lustre-client-utils
 Section: utils
 Architecture: i386 powerpc ppc64el amd64 ia64 arm64
 Priority: optional
-Depends: ${shlibs:Depends}, ${misc:Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, libyaml-0-2, libselinux1, libsnmp30, zlib1g, perl
 Description: Userspace utilities for the Lustre filesystem (client)
  Lustre is a scalable, secure, robust, highly-available cluster file system.
  This release is maintained by Intel Corporation and available from
@@ -58,9 +38,9 @@ Description: Userspace utilities for the Lustre filesystem (client)
 
 Package: lustre-server-utils
 Section: utils
-Architecture: i386 powerpc ppc64el amd64 ia64
+Architecture: i386 powerpc ppc64el amd64 ia64 arm64
 Priority: optional
-Depends: ${shlibs:Depends}, ${misc:Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}, libyaml-0-2, libselinux1, libsnmp30, zlib1g, perl
 Provides: lustre-server-utils, lustre-client-utils
 Conflicts: lustre-client-utils
 Replaces: lustre-client-utils
@@ -74,11 +54,23 @@ Description: Userspace utilities for the Lustre filesystem (server)
  If you only need to access the LFS cluster, install lustre-client-utils
  instead.
 
+Package: lustre-iokit
+Section: utils
+Architecture: i386 powerpc ppc64el amd64 ia64 arm64
+Priority: optional
+Depends: lustre-client-utils (= ${binary:Version}), python, perl, sg3-utils
+Description: Collection of benchmark tools for the Lustre filesystem
+ Lustre is a scalable, secure, robust, highly-available cluster file system.
+ This release is maintained by Intel Corporation and available from
+ https://wiki.hpdd.intel.com/
+ .
+ This package provides a collection of benchmark tools
+
 Package: lustre-tests
 Section: utils
 Architecture: i386 powerpc ppc64el amd64 ia64 arm64
 Priority: optional
-Depends: lustre-client-utils (= ${binary:Version})
+Depends: lustre-iokit (= ${binary:Version}), attr, rsync, perl, lsof
 Description: Test suite for the Lustre filesystem
  Lustre is a scalable, secure, robust, highly-available cluster file system.
  This release is maintained by Intel Corporation and available from
index 8b24a54..c4d10ec 100644 (file)
@@ -36,4 +36,4 @@ Description: Lustre Server Linux kernel module (kernel _KVERS_)
  These server modules provide and supersede the client modules, if they
  are compiled against same Kernel version.
  .
- These modules are compiled for the _KVERS_ linux kernel.
\ No newline at end of file
+ These modules are compiled for the _KVERS_ linux kernel.
diff --git a/debian/linux-patch-lustre.apply b/debian/linux-patch-lustre.apply
deleted file mode 100644 (file)
index 444b264..0000000
+++ /dev/null
@@ -1,118 +0,0 @@
-#! /bin/bash
-set -x
-
-if ! [ -d kernel -a -d Documentation ]
-then
-    echo >&2 "Not in kernel top level directory. Exiting"
-    exit 1
-fi
-TOPPATCHDIR=/usr/src/kernel-patches/lustre
-ARCHITECTURE=`dpkg --print-installation-architecture`
-
-QUILT="quilt --quiltrc /dev/null"
-export QUILT_PATCHES="$TOPPATCHDIR/patches"
-
-[ -f debian/APPLIED_all_lustre ] && exit 0
-VERSION=$(grep ^VERSION Makefile 2>/dev/null | \
-        sed -e 's/[^0-9]*\([0-9]*\)/\1/')
-PATCHLEVEL=$( grep ^PATCHLEVEL Makefile 2>/dev/null | \
-        sed -e 's/[^0-9]*\([0-9]*\)/\1/')
-SUBLEVEL=$(grep ^SUBLEVEL Makefile 2>/dev/null | \
-        sed -e 's/[^0-9]*\([0-9]*\)/\1/')
-#EXTRAVERSION=$(grep ^EXTRAVERSION Makefile | head -1 2>/dev/null | \
-#        sed -e 's/EXTRAVERSION =[       ]*\([^  ]*\)$/\1/')
-#KERNELBRANCHLET=${VERSION}.${PATCHLEVEL}.${SUBLEVEL}
-#KERNELRELEASE=${KERNELBRANCHLET}${EXTRAVERSION}
-KERNELRELEASE=${VERSION}.${PATCHLEVEL}.${SUBLEVEL}
-
-cleanup() {
-  echo >&2 Cleaning up
-  if [ -e series ]; then
-    echo >&2 Removing series file
-    rm series
-  fi
-  if [ -e debian/APLLIED_all_lustre_tmp/series.orig ]; then
-    echo >&1 Restoring orig series file
-    mv debian/APLLIED_all_lustre_tmp/series.orig series
-  fi
-  if [ -e .pc ]; then
-    echo >&2 Removing .pc dir
-    rm -r .pc
-  fi
-  if [ -e debian/APPLIED_all_lustre_tmp/.pc.orig ]; then
-    echo >&2 Restoring orig .pc dir
-    mv debian/APPLIED_all_lustre_tmp/.pc.orig .pc
-  fi
-}
-
-mkdir -p debian/APPLIED_all_lustre_tmp
-if [ -e series ]; then
-  echo >&2 Preserving existing series file
-  mv series debian/APPLIED_all_lustre_tmp/series.orig
-fi
-if [ -e .pc ]; then
-  echo >&2 Preserving existing .pc dir
-  mv .pc debian/APPLIED_all_lustre_tmp/.pc.orig
-fi
-
-trap cleanup EXIT
-
-echo >&2 Setting up quilt
-$QUILT setup $TOPPATCHDIR/series/$KERNELRELEASE-vanilla.series 2>/dev/null
-ERR=$?
-if ! [ $ERR = 0 ]; then
-  echo >&2 Quilt failed to initialize
-  cleanup
-  exit $ERR
-fi
-
-echo >&2 Applying lustre patches
-$QUILT push -a
-ERR=$?
-if ! [ $ERR = 0 ]; then
-  echo >&2 Lustre patched failed to apply
-  echo >&2 Reverting partialy applied patch
-  $QUILT pop -a
-  cleanup
-  exit $ERR
-fi
-
-echo >&2 Finalizing lustre patch
-mv series debian/APPLIED_all_lustre_tmp/series.lustre
-mv .pc debian/APPLIED_all_lustre_tmp/.pc.lustre
-cleanup
-
-
-echo >&2 "\"Lustre Filesystem patch for the Linux kernel\" patch for $KVERSION succeeded"
-
-echo >&2 "Removing empty files:"
-# make an exception for ./debian, or else the stamp files will go too.
-find . -path ./debian -prune -o \
-       -type f -size 0 ! -name 'APPLIED*' -exec rm {} \; -print
-echo >&2 "Done."
-
-mkdir -p debian
-cat > 'debian/APPLIED_all_lustre' <<EOF
-SERIES=$KERNELRELEASE-vanilla.series
-EOF
-mkdir -p debian/image.d
-PKGNAME=`dpkg -S $TOPPATCHDIR/series/$KERNELRELEASE-vanilla.series | cut -d: -f1`
-PKGVERS=`grep-dctrl -n -P $PKGNAME -s Version -X /var/lib/dpkg/status`
-cat > 'debian/image.d/register-lustre' <<EOF
-#!/bin/sh
-
-# This scripts documents the "Lustre Filesystem patch for the Linux kernel" kernel patch into the
-# kernel-image package, as being applied to the kernel.
-
-docdir=\${IMAGE_TOP}/usr/share/doc/kernel-image-\${version}
-
-mkdir -p \${docdir}
-
-(
-    printf 'Lustre Filesystem patch for the Linux kernel (lustre)${KPATCH_lustre:+ for kernel ${KPATCH_lustre}},'
-    echo ' from package $PKGNAME, version $PKGVERS'
-) >> \${docdir}/applied-patches
-EOF
-chmod +x 'debian/image.d/register-lustre'
-
-echo >&2 "END applying lustre patch"
diff --git a/debian/linux-patch-lustre.dirs b/debian/linux-patch-lustre.dirs
deleted file mode 100644 (file)
index b9d3f39..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-usr/src/kernel-patches/lustre/scripts
-usr/src/kernel-patches/lustre/series
-usr/src/kernel-patches/lustre/patches
diff --git a/debian/linux-patch-lustre.kpatches b/debian/linux-patch-lustre.kpatches
deleted file mode 100644 (file)
index 0bf1ef0..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-Patch-name: Lustre Filesystem patch for the Linux kernel
-Patch-id: lustre
-Architecture: amd64, ia64, i386, powerpc
-Path-strip-level: 1
-
-Patch-file: debian/kpatches/patch-vanilla-2.6.18
-Kernel-version: 2.6.18
-
-Patch-file: debian/kpatches/patch-vanilla-2.6.20
-Kernel-version: 2.6.20
-
-Patch-file: debian/kpatches/patch-vanilla-2.6.21
-Kernel-version: 2.6.21
diff --git a/debian/linux-patch-lustre.unpatch b/debian/linux-patch-lustre.unpatch
deleted file mode 100644 (file)
index befc542..0000000
+++ /dev/null
@@ -1,117 +0,0 @@
-#! /bin/bash
-set -x
-
-if ! [ -d kernel -a -d Documentation ]
-then
-    echo >&2 "Not in kernel top level directory. Exiting"
-    exit 1
-fi
-TOPPATCHDIR=/usr/src/kernel-patches/lustre
-ARCHITECTURE=`dpkg --print-installation-architecture`
-
-QUILT="quilt --quiltrc /dev/null"
-export QUILT_PATCHES="$TOPPATCHDIR/patches"
-
-if ! [ -f debian/APPLIED_all_lustre ]; then
-  echo >&2 "Lustre patch not applied."
-  exit 0
-fi
-VERSION=$(grep ^VERSION Makefile 2>/dev/null | \
-        sed -e 's/[^0-9]*\([0-9]*\)/\1/')
-PATCHLEVEL=$( grep ^PATCHLEVEL Makefile 2>/dev/null | \
-        sed -e 's/[^0-9]*\([0-9]*\)/\1/')
-SUBLEVEL=$(grep ^SUBLEVEL Makefile 2>/dev/null | \
-        sed -e 's/[^0-9]*\([0-9]*\)/\1/')
-#EXTRAVERSION=$(grep ^EXTRAVERSION Makefile | head -1 2>/dev/null | \
-#        sed -e 's/EXTRAVERSION =[       ]*\([^  ]*\)$/\1/')
-#KERNELBRANCHLET=${VERSION}.${PATCHLEVEL}.${SUBLEVEL}
-#KERNELRELEASE=${KERNELBRANCHLET}${EXTRAVERSION}
-KERNELRELEASE=${VERSION}.${PATCHLEVEL}.${SUBLEVEL}
-
-# Check for depends on lustre
-if grep -l "^DEPENDS=.*[' ]all/unpatch/lustre[' ]" debian/APPLIED_* >/dev/null 2>/dev/null; then
-    # There are patches depending on this one, to be removed before.
-    # the dep will be removed by the last of those other patches.
-    echo >&2 "NOT unpatching \"Lustre Filesystem patch for the Linux kernel\" since other patches still rely on it"
-    exit 0
-fi
-
-if ! [ -d debian/APPLIED_all_lustre_tmp/.pc.lustre ]; then
-  cat >&2 <<EOF
-ERROR: .pc directory missing for unpatching. I strongly suggest
-you remove this kernel tree and unpack a clean one.
-EOF
-  exit 1
-fi
-
-if ! [ -e debian/APPLIED_all_lustre_tmp/series.lustre ]; then
-  cat >&2 <<EOF
-ERROR: series file missing for unpatching. I strongly suggest
-you remove this kernel tree and unpack a clean one.
-EOF
-  exit 1
-fi
-
-cleanup() {
-  echo >&2 Cleaning up
-  if [ -e series ]; then
-    echo >&2 Removing series file
-    rm series
-  fi
-  if [ -e debian/APPLIED_all_lustre_tmp/series.orig ]; then
-    echo >&1 Restoring orig series file
-    mv debian/APPLIED_all_lustre_tmp/series.orig series
-  fi
-  if [ -e .pc ]; then
-    echo >&2 Removing .pc dir
-    rm -r .pc
-  fi
-  if [ -e debian/APPLIED_all_lustre_tmp/.pc.orig ]; then
-    echo >&2 Restoring orig .pc dir
-    mv debian/APPLIED_all_lustre_tmp/.pc.orig .pc
-  fi
-}
-
-if [ -e series ]; then
-  echo >&2 Preserving existing series file
-  mv series debian/APPLIED_all_lustre_tmp/series.orig
-fi
-if [ -e .pc ]; then
-  echo >&2 Preserving existing .pc dir
-  mv .pc debian/APPLIED_all_lustre_tmp/.pc.orig
-fi
-
-trap cleanup EXIT
-
-echo >&2 Restoring lustre quilt
-mv debian/APPLIED_all_lustre_tmp/series.lustre series
-mv debian/APPLIED_all_lustre_tmp/.pc.lustre .pc
-
-echo >&2 Unpatching lustre patches
-$QUILT pop -a
-ERR=$?
-if ! [ $ERR = 0 ]; then
-  cat >&2 <<EOF
-ERROR: Lustre patches failed to unpatch. I strongly suggest
-you remove this kernel tree and unpack a clean one.
-EOF
-  cleanup
-  exit $ERR
-fi
-
-echo >&2 Removing lustre quilt
-rm -rf .pc series
-cleanup
-rm debian/APPLIED_all_lustre debian/image.d/register-lustre
-
-echo >&2 "\"Lustre Filesystem patch for the Linux kernel\" patch for $KVERSION removed successfully"
-
-echo >&2 "Removing empty files:"
-# make an exception for ./debian, or else the stamp files will go too.
-find . -path ./debian -prune -o \
-       -type f -size 0 ! -name 'APPLIED*' -exec rm {} \; -print
-echo >&2 "Done."
-
-rmdir debian/image.d debian/APPLIED_all_lustre_tmp || true
-
-echo >&2 "END unpatching lustre patch"
index dd93d15..4e22858 100644 (file)
@@ -1 +1,3 @@
 debian/tmp/lib /
+debian/tmp/usr/include/linux/lnet/*            usr/include/linux/lnet
+debian/tmp/usr/include/linux/libcfs/*          usr/include/linux/libcfs
index 4eac081..ae8149d 100644 (file)
@@ -1,6 +1,4 @@
 debian/tmp/sbin/*                      sbin
 debian/tmp/usr/sbin/*                  usr/sbin
 debian/tmp/usr/bin/*                   usr/bin
-debian/tmp/usr/lib/*.a                 usr/lib
-debian/tmp/usr/lib/*.la                        usr/lib
-debian/tmp/usr/lib/*.so*               usr/lib
+debian/tmp/usr/lib/*.so.*              usr/lib
index bce2c9d..851d6af 100644 (file)
@@ -1,3 +1,3 @@
 debian/tmp/usr/include/lustre/*                usr/include/lustre
-debian/tmp/usr/lib/*.so*               usr/lib
+debian/tmp/usr/lib/*.so                        usr/lib
 debian/tmp/usr/lib/*.a                 usr/lib
diff --git a/debian/lustre-iokit.docs b/debian/lustre-iokit.docs
new file mode 100644 (file)
index 0000000..2466a68
--- /dev/null
@@ -0,0 +1,2 @@
+lustre-iokit/*-survey/README*
+lustre-iokit/stats-collect/README.*
diff --git a/debian/lustre-iokit.install b/debian/lustre-iokit.install
new file mode 100644 (file)
index 0000000..ef12955
--- /dev/null
@@ -0,0 +1,2 @@
+debian/tmp/usr/bin/iokit-*     usr/bin
+debian/tmp/usr/bin/*-survey    usr/bin
index adb5d39..1f12be6 100644 (file)
@@ -1,7 +1,5 @@
 debian/tmp/sbin/*                      sbin
 debian/tmp/usr/sbin/*                  usr/sbin
 debian/tmp/usr/bin/*                   usr/bin
-debian/tmp/usr/lib/*.a                 usr/lib
-debian/tmp/usr/lib/*.la                        usr/lib
-debian/tmp/usr/lib/*.so*               usr/lib
+debian/tmp/usr/lib/*.so.*              usr/lib
 debian/tmp/usr/lib/lustre/*.so*                usr/lib/lustre
index 1c00088..882ca28 100644 (file)
@@ -1 +1,4 @@
 debian/tmp/usr/lib/lustre/tests/*      usr/lib/lustre/tests
+debian/tmp/usr/bin/mcreate             usr/bin
+debian/tmp/usr/bin/munlink             usr/bin
+debian/tmp/usr/sbin/wire*              usr/sbin
index b32e447..66cf294 100755 (executable)
@@ -30,7 +30,7 @@ endif
 #export CC
 
 # This is the debhelper compatibility version to use.
-export DH_COMPAT=7
+export DH_COMPAT=9
 
 # Module-assistant stuff
 ifneq (,$(findstring server,$(DEB_BUILD_PROFILES)))
@@ -62,11 +62,10 @@ KSRC_TREE?=$(LINUX)
 IB_OPTIONS?=""
 
 # Packages provided for both client and server builds
-PATCH_PKG=linux-patch-lustre
+IOKIT_PKG=lustre-iokit
 TESTS_PKG=lustre-tests
 DEV_PKG=lustre-dev
 SOURCE_PKG=lustre-source
-SOURCE_PKG=lustre-source
 
 # Packages that are only built for server OR client builds
 # The difference is that server build contain more modules & utils
@@ -191,50 +190,13 @@ build-stamp: patch-stamp configure-stamp
 # instead we will build the modules with m-a in the "make debs" target
 # binary-arch: binary-$(UTILS_PKG) binary-$(TESTS_PKG) binary-$(DEV_PKG) \
 # binary-$(MODS_PKG) binary-kern-mods
-binary-arch: binary-$(UTILS_PKG) binary-$(TESTS_PKG) binary-$(DEV_PKG)
+binary-arch: binary-$(UTILS_PKG) binary-$(DEV_PKG) \
+            binary-$(IOKIT_PKG) binary-$(TESTS_PKG)
 
-binary-indep: binary-$(PATCH_PKG) binary-$(SOURCE_PKG)
+binary-indep: binary-$(SOURCE_PKG)
 
 binary: binary-indep binary-arch
 
-binary-$(PATCH_PKG): patch-stamp
-       dh_testdir
-       dh_testroot
-       dh_installdirs -p $(PATCH_PKG)
-       dh_installdocs -p $(PATCH_PKG)
-#      dh_installkpatches -p $(PATCH_PKG)
-       dh_install -p $(PATCH_PKG)
-
-       # Install apply script
-       cp $(TOP_DIR)/debian/linux-patch-lustre.apply $(TOP_DIR)/debian/$(PATCH_PKG)/usr/src/kernel-patches/lustre/scripts/apply
-       chmod a+x $(TOP_DIR)/debian/$(PATCH_PKG)/usr/src/kernel-patches/lustre/scripts/apply
-       set -e; for KERNEL in $(SUPPORTED_KERNELS); do \
-         mkdir -p $(TOP_DIR)/debian/$(PATCH_PKG)/usr/src/kernel-patches/all/$$KERNEL/apply/; \
-         ln -s ../../../lustre/scripts/apply $(TOP_DIR)/debian/$(PATCH_PKG)/usr/src/kernel-patches/all/$$KERNEL/apply/lustre; \
-       done
-
-       # Install unpatch script
-       cp $(TOP_DIR)/debian/linux-patch-lustre.unpatch $(TOP_DIR)/debian/$(PATCH_PKG)/usr/src/kernel-patches/lustre/scripts/unpatch
-       chmod a+x $(TOP_DIR)/debian/$(PATCH_PKG)/usr/src/kernel-patches/lustre/scripts/unpatch
-       set -e; for KERNEL in $(SUPPORTED_KERNELS); do \
-         mkdir -p $(TOP_DIR)/debian/$(PATCH_PKG)/usr/src/kernel-patches/all/$$KERNEL/unpatch/; \
-         ln -s ../../../lustre/scripts/unpatch $(TOP_DIR)/debian/$(PATCH_PKG)/usr/src/kernel-patches/all/$$KERNEL/unpatch/lustre; \
-       done
-
-       # Install series
-       cp lustre/kernel_patches/series/*.series $(TOP_DIR)/debian/$(PATCH_PKG)/usr/src/kernel-patches/lustre/series/
-
-       # Install patches
-       cp lustre/kernel_patches/patches/*.patch $(TOP_DIR)/debian/$(PATCH_PKG)/usr/src/kernel-patches/lustre/patches/
-
-       dh_installchangelogs -p $(PATCH_PKG) lustre/ChangeLog
-       dh_compress -p $(PATCH_PKG)
-       dh_installdeb -p $(PATCH_PKG)
-       dh_fixperms -p $(PATCH_PKG)
-       dh_gencontrol -p $(PATCH_PKG)
-       dh_md5sums -p $(PATCH_PKG)
-       dh_builddeb -p $(PATCH_PKG)
-
 binary-$(UTILS_PKG): build-stamp
        dh_testdir
        dh_testroot
@@ -242,6 +204,12 @@ binary-$(UTILS_PKG): build-stamp
        dh_installdocs -p  $(UTILS_PKG)
        dh_installman -p $(UTILS_PKG)
        dh_install -p $(UTILS_PKG)
+       rm -rf debian/$(UTILS_PKG)/usr/bin/iokit-* \
+              debian/$(UTILS_PKG)/usr/bin/*-survey \
+              debian/$(UTILS_PKG)/usr/bin/mcreate \
+              debian/$(UTILS_PKG)/usr/bin/munlink \
+              debian/$(UTILS_PKG)/usr/sbin/wirecheck \
+              debian/$(UTILS_PKG)/usr/sbin/wiretest
        dh_makeshlibs -p $(UTILS_PKG)
        dh_installexamples -p $(UTILS_PKG)
        dh_installchangelogs -p $(UTILS_PKG) lustre/ChangeLog
@@ -253,6 +221,27 @@ binary-$(UTILS_PKG): build-stamp
        dh_md5sums -p $(UTILS_PKG)
        dh_builddeb -p $(UTILS_PKG)
 
+binary-$(IOKIT_PKG): build-stamp
+       dh_testdir
+       dh_testroot
+       dh_installdirs -p $(IOKIT_PKG)
+       dh_installdocs -p  $(IOKIT_PKG)
+       dh_installman -p $(IOKIT_PKG)
+       dh_install -p $(IOKIT_PKG)
+       rm -rf debian/$(IOKIT_PKG)/usr/bin/lustre_req_history \
+              debian/$(IOKIT_PKG)/usr/bin/*ll*stat \
+              debian/$(IOKIT_PKG)/usr/bin/lfs-*
+       dh_makeshlibs -p $(IOKIT_PKG)
+       dh_installexamples -p $(IOKIT_PKG)
+       dh_installchangelogs -p $(IOKIT_PKG) lustre/ChangeLog
+       dh_compress -p $(IOKIT_PKG)
+       dh_strip -p $(IOKIT_PKG)
+       dh_installdeb -p $(IOKIT_PKG)
+       dh_fixperms -p $(IOKIT_PKG)
+       dh_gencontrol -p $(IOKIT_PKG)
+       dh_md5sums -p $(IOKIT_PKG)
+       dh_builddeb -p $(IOKIT_PKG)
+
 binary-$(TESTS_PKG): build-stamp
        dh_testdir
        dh_testroot
@@ -426,7 +415,7 @@ binary-modules: prep-deb-files
        $(MAKE) $(PMAKEARGS)
        $(MAKE) install DESTDIR=$(CURDIR)/debian/$(PKGNAME)
        # Remove stuff that doesn't belong (no module-only target)
-       cd $(CURDIR)/debian/$(PKGNAME) && rm -rf usr sbin etc
+       cd $(CURDIR)/debian/$(PKGNAME) && rm -rf usr/bin usr/sbin usr/lib usr/share usr/include/lustre sbin etc
        dh_installdocs -p$(PKGNAME)
        dh_installchangelogs -p$(PKGNAME)
        dh_installmodules -p $(PKGNAME)
@@ -443,7 +432,7 @@ clean:
        dh_testroot
        dpatch deapply-all -v
        -$(MAKE) distclean
-       rm -rf  debian/substvars debian/*.bak debian/*~ *~  *-stamp debian/$(PATCH_PKG)
+       rm -rf  debian/substvars debian/*.bak debian/*~ *~  *-stamp
        ls -d debian/lustre-*-modules-* | grep -v _KVERS_ | xargs rm -f || true
        # only remove this if the clean was not called from kdist_clean
        if [ "$$MA_SOURCE_PKG" = "" ]; then \