From: Brian J. Murrell Date: Tue, 19 Oct 2010 02:01:35 +0000 (-0400) Subject: b=20744 set arch correctly for ofed-devel X-Git-Tag: 2.0.54.0~8 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=5478f5729ee45da557617a5578fb7adea3fa3746;p=fs%2Flustre-release.git b=20744 set arch correctly for ofed-devel Oh boy, more fallout from our not building i586 kernels for sles. If we are building lustre servers and NOT rebuilding the Suse ofed RPM, then we need to look for the i586 ofed-devel package. i=yangsheng i=yibin.wang --- diff --git a/build/lbuild b/build/lbuild index 9177661..dfc6f1c 100755 --- a/build/lbuild +++ b/build/lbuild @@ -1177,7 +1177,6 @@ reuse() { find $dir -type f | xargs ln -t $dest/RPMS/${dir##*/} -s done - fi return 0 else @@ -1506,14 +1505,14 @@ EOF local dir for dir in RPMS/*; do pushd $dir - for file in *; do - if [ -h $file ]; then - cp $file foo - mv foo $file - fi - done + for file in $(ls); do + if [ -h $file ]; then + cp $file foo + mv foo $file + fi done - popd + popd + done # also, for i?86, make sure all of the RPMs are in RPMS/$TARGET_ARCH # as that's where LTS expects to find them for dir in RPMS/*; do diff --git a/build/lbuild-sles b/build/lbuild-sles index 6d886c6..8037bca 100644 --- a/build/lbuild-sles +++ b/build/lbuild-sles @@ -97,7 +97,7 @@ resolve_arch() { ;; i?86) if $canonical; then arch=i386 - elif $for_patchless; then + elif $(eval $for_patchless); then arch=i586 fi ;; diff --git a/build/lbuild-sles10 b/build/lbuild-sles10 index 6330d1c..aece52b 100644 --- a/build/lbuild-sles10 +++ b/build/lbuild-sles10 @@ -227,11 +227,11 @@ build_ofed-sles10() { # temporary hack until we get a base O/S intalled ofed-devel local arch=$TARGET_ARCH if [ -n "$OFED_VERSION" -a "$OFED_VERSION" = "inkernel" ]; then - local ofed_devel="${OFED_DEVEL_LOCATION}/ofed-devel-${OFED_DEVEL_VERSION}.$(resolve_arch $TARGET_ARCH $PATCHLESS).rpm" + local ofed_devel="${OFED_DEVEL_LOCATION}/ofed-devel-${OFED_DEVEL_VERSION}.$(resolve_arch $TARGET_ARCH "$PATCHLESS || ! $REBUILD_OFED_DEVEL_RPM").rpm" if ! rpm2cpio < $ofed_devel | cpio -id; then fatal 1 "could not unpack the ofed-devel rpm." fi - echo "$(pwd)/usr/src/kernel-modules-ofed/$(resolve_arch $TARGET_ARCH $PATCHLESS)/$RPMSMPTYPE" + echo "$(pwd)/usr/src/kernel-modules-ofed/$(resolve_arch $TARGET_ARCH "$PATCHLESS || ! $REBUILD_OFED_DEVEL_RPM")/$RPMSMPTYPE" fi return 0