Whamcloud - gitweb
b=24092 build src.rpm for lustre if requested
authorBrian J. Murrell <brian.murrell@oracle.com>
Mon, 8 Nov 2010 11:20:49 +0000 (19:20 +0800)
committerVitaly Fertman <vitaly.fertman@sun.com>
Mon, 8 Nov 2010 20:56:13 +0000 (23:56 +0300)
Fix a bug where we were not building the lustre SRPM even if
requested.

i=wangyb
i=cliff

build/lbuild

index fd97a12..f18a5a3 100755 (executable)
@@ -869,6 +869,20 @@ build_lustre() {
         --define "_topdir $TOPDIR" 2>&1 || \
         fatal 1 "Error building rpms for $BUILD_ARCHS."
 
+    if $DO_SRC; then
+        if ! $RPMBUILD -ts "$LUSTRE" \
+                 ${is_patchless:+--define "lustre_name lustre-client"} \
+                 ${lustre_tests:+--define "build_lustre_tests 0"} \
+                 ${FIND_REQUIRES:+--define "__find_requires $FIND_REQUIRES"} \
+                 --define "configure_args $confoptions ${CONFIGURE_FLAGS}" \
+                 --define "kdir $linux" \
+                 ${linuxobj:+--define "kobjdir $linuxobj"} \
+                 --define "_tmppath $TMPDIR" \
+                 --define "_topdir $TOPDIR" 2>&1; then
+            popd
+            return 255
+        fi
+    fi
     popd >/dev/null
 
 }