From 8474cb78e64573c1f73cf63de12f9b67b68b29e3 Mon Sep 17 00:00:00 2001 From: yangsheng Date: Mon, 1 Jun 2009 11:21:19 +0000 Subject: [PATCH] Branch b1_8 b=18668 i=yangsheng, johann Fixed the patchless build issue specific sles11. Author: brian --- build/lbuild | 4 +++- build/lbuild-sles11 | 12 +++++++++--- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/build/lbuild b/build/lbuild index 9b8d965..d5ef88f 100755 --- a/build/lbuild +++ b/build/lbuild @@ -803,6 +803,8 @@ find_linux_release() { } +# XXX this needs to be re-written as a wrapper around find_rpm +# or just gotten rid of. :-) find_linux_rpm() { local prefix="$1" local delimiter=${2:-"-"} @@ -855,7 +857,7 @@ unpack_linux_devel_rpm() { # call a distro specific hook, if available if type -p unpack_linux_devel_rpm-$DISTRO; then - unpack_linux_devel_rpm-$DISTRO + unpack_linux_devel_rpm-$DISTRO "$kernelrpm" fi popd diff --git a/build/lbuild-sles11 b/build/lbuild-sles11 index 995c356..1c68eec 100644 --- a/build/lbuild-sles11 +++ b/build/lbuild-sles11 @@ -50,12 +50,18 @@ curl ftp://ftp.kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.17/2.6.17 } unpack_linux_devel_rpm-sles11() { + local callers_rpm="$1" + + local rpmdir="${callers_rpm%/*}" + local kernelrpm - if ! kernelrpm=$(find_rpm "$TOPDIR/RPMS/$arch/" provides "^kernel-lustre-default-base ="); then - fatal 1 "Could not find the kernel-lustre-default-base in $TOPDIR/RPMS/$arch/" + # this is a hack that should go away when the modified lustre kernel + # Provides kernel-default-base vvvvvvvvv + if ! kernelrpm=$(find_rpm "$rpmdir" provides "^kernel-(lustre-)?default-base ="); then + fatal 1 "Could not find the kernel-default-base in $rpmdir/" fi - if ! rpm2cpio < "$TOPDIR/RPMS/$arch/$kernelrpm" | cpio -id > /dev/null 2>&1; then + if ! rpm2cpio < "$rpmdir/$kernelrpm" | cpio -id > /dev/null 2>&1; then fatal 1 "Unpack error for $kernelrpm" fi -- 1.8.3.1