Add support for building .nosrc.rpm using the '--with nosrc' flag.
This saves time and bandwidth as you dont have to re-download
the kernel.org tarball every time.

This patch is already used in kernel-mm, kernel-tmb and 2006.0
main kernels.

Signed-off-by: Thomas Backlund <[EMAIL PROTECTED]>

--- kernel-2.6.spec.old	2006-09-12 19:15:15.000000000 +0300
+++ kernel-2.6.spec	2006-09-12 19:15:27.000000000 +0300
@@ -107,6 +107,10 @@
 %{?_with_100: %global build_100 1}
 %{?_with_101: %global build_101 1}
 
+### THis is for the .nosrc.rpm
+%define build_nosrc     0
+%{?_with_nosrc: %global build_nosrc 1}
+
 %if %(if [ -z "$CC" ] ; then echo 0; else echo 1; fi)
 %define kmake %make CC="$CC"
 %else
@@ -141,6 +145,11 @@ Source15: linux-mdkconfig.h
 Source16: linux-merge-config.awk
 Source100: linux-%{patches_ver}.tar.bz2
 
+### This is for .nosrc.rpm
+%if %build_nosrc
+NoSource: 0
+%endif
+
 ####################################################################
 #
 # Patches

Reply via email to