summaryrefslogtreecommitdiffstats
path: root/scripts/package/mkspec
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/package/mkspec')
-rwxr-xr-xscripts/package/mkspec12
1 files changed, 7 insertions, 5 deletions
diff --git a/scripts/package/mkspec b/scripts/package/mkspec
index a83b17b4a0d9..9b2b4386019d 100755
--- a/scripts/package/mkspec
+++ b/scripts/package/mkspec
@@ -38,6 +38,8 @@ EXCLUDES="$RCS_TAR_IGNORE --exclude=*vmlinux* --exclude=*.mod \
# $S: this line is enabled only when building source package
# $M: this line is enabled only when CONFIG_MODULES is enabled
sed -e '/^DEL/d' -e 's/^\t*//' <<EOF
+%{!?make: %define make make}
+
Name: kernel
Summary: The Linux Kernel
Version: $__KERNELRELEASE
@@ -89,19 +91,19 @@ $S cp %{SOURCE1} .config
$S patch -p1 < %{SOURCE2}
$S
$S %build
-$S $MAKE %{?_smp_mflags} KERNELRELEASE=$KERNELRELEASE KBUILD_BUILD_VERSION=%{release}
+$S %{make} %{?_smp_mflags} KERNELRELEASE=$KERNELRELEASE KBUILD_BUILD_VERSION=%{release}
$S
%install
mkdir -p %{buildroot}/boot
%ifarch ia64
mkdir -p %{buildroot}/boot/efi
- cp \$($MAKE -s image_name) %{buildroot}/boot/efi/vmlinuz-$KERNELRELEASE
+ cp \$(%{make} -s image_name) %{buildroot}/boot/efi/vmlinuz-$KERNELRELEASE
ln -s efi/vmlinuz-$KERNELRELEASE %{buildroot}/boot/
%else
- cp \$($MAKE -s image_name) %{buildroot}/boot/vmlinuz-$KERNELRELEASE
+ cp \$(%{make} -s image_name) %{buildroot}/boot/vmlinuz-$KERNELRELEASE
%endif
-$M $MAKE %{?_smp_mflags} INSTALL_MOD_PATH=%{buildroot} modules_install
- $MAKE %{?_smp_mflags} INSTALL_HDR_PATH=%{buildroot}/usr headers_install
+$M %{make} %{?_smp_mflags} INSTALL_MOD_PATH=%{buildroot} modules_install
+ %{make} %{?_smp_mflags} INSTALL_HDR_PATH=%{buildroot}/usr headers_install
cp System.map %{buildroot}/boot/System.map-$KERNELRELEASE
cp .config %{buildroot}/boot/config-$KERNELRELEASE
$S$M rm -f %{buildroot}/lib/modules/$KERNELRELEASE/build