Skip to content

Commit

Permalink
scripts/package: don't break if %{_smp_mflags} isn't set
Browse files Browse the repository at this point in the history
Currently, if we do a 'make rpm-pkg' without the _smp_mflags rpm macro
defined, the build fails with:

  [snip]
  Executing(%build): /bin/bash -e /var/tmp/rpm-tmp.67959
  + umask 022
  + cd /home/jk/devel/kernel-snapshot/rpm/BUILD
  + cd kernel-2.6.26
  + make clean
  + make '%{_smp_mflags}'
  make[3]: *** No rule to make target `%{_smp_mflags}'.  Stop.
  error: Bad exit status from /var/tmp/rpm-tmp.67959 (%build)

This change uses the 'null if not set' reference to the _smp_mflags
macro instead.

Signed-off-by: Jeremy Kerr <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Sam Ravnborg <[email protected]>
  • Loading branch information
jk-ozlabs authored and sravnborg committed Oct 29, 2008
1 parent e3da2fb commit 13797b7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/package/mkspec
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ fi
echo "%build"

if ! $PREBUILT; then
echo "make clean && make %{_smp_mflags}"
echo "make clean && make %{?_smp_mflags}"
echo ""
fi

Expand Down

0 comments on commit 13797b7

Please sign in to comment.