From 75f65210f392a59ff0caf13f4551b362c0bb5eef Mon Sep 17 00:00:00 2001 From: Ludwig Nussel Date: Mon, 11 Jan 2010 16:58:45 +0100 Subject: [PATCH] also set %_smp_mflags to BUILD_JOBS --- build | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/build b/build index 9cc49f9..85f0174 100755 --- a/build +++ b/build @@ -1377,6 +1377,13 @@ for SPECFILE in "${SPECFILES[@]}" ; do ' >> $BUILD_ROOT/root/.rpmmacros fi + + if [ -n "$BUILD_JOBS" ]; then + cat >> $BUILD_ROOT/root/.rpmmacros <<-EOF + %jobs $BUILD_JOBS + %_smp_mflags -j$BUILD_JOBS + EOF + fi test $BUILD_USER = abuild && cp -p $BUILD_ROOT/root/.rpmmacros $BUILD_ROOT/home/abuild/.rpmmacros # extract optflags from configuration getoptflags --dist "$BUILD_DIST" --configdir "$BUILD_DIR/configs" --archpath "$BUILD_ARCH" ${BUILD_DEBUG:+--debug} > $BUILD_ROOT/root/.rpmrc @@ -1494,10 +1501,6 @@ for SPECFILE in "${SPECFILES[@]}" ; do if [ -n "$ABUILD_TARGET_ARCH" ]; then rpmbopts[${#rpmbopts[@]}]="--target=$ABUILD_TARGET_ARCH" fi - if [ -n "$BUILD_JOBS" ]; then - rpmbopts[${#rpmbopts[@]}]='--define' - rpmbopts[${#rpmbopts[@]}]="jobs $BUILD_JOBS" - fi if [ -n "$DISTURL" ]; then rpmbopts[${#rpmbopts[@]}]='--define' rpmbopts[${#rpmbopts[@]}]="disturl $DISTURL" -- 2.7.4