Commit 6d956df7 authored by Dave Jones's avatar Dave Jones

[PATCH] updates for make rpm

- install .config in /boot
- provide kernel-drm package if drm is compiled
- handle extra '-' marks so that linux-2.5.8-dj3-voon works.
parent 565a20c7
...@@ -6,9 +6,15 @@ ...@@ -6,9 +6,15 @@
# The only gothic bit here is redefining install_post to avoid # The only gothic bit here is redefining install_post to avoid
# stripping the symbols from files in the kernel which we want # stripping the symbols from files in the kernel which we want
# #
if [ "`grep CONFIG_DRM=y .config | cut -f2 -d\=`" = "y" ]; then
PROVIDES=kernel-drm
fi
PROVIDES="$PROVIDES kernel-$VERSION.$PATCHLEVEL.$SUBLEVEL$EXTRAVERSION"
echo "Name: kernel" echo "Name: kernel"
echo "Summary: The Linux Kernel" echo "Summary: The Linux Kernel"
echo "Version: "$VERSION.$PATCHLEVEL.$SUBLEVEL$EXTRAVERSION | sed -e "s/-//" echo "Version: "$VERSION.$PATCHLEVEL.$SUBLEVEL$EXTRAVERSION | sed -e "s/-//g"
# we need to determine the NEXT version number so that uname and # we need to determine the NEXT version number so that uname and
# rpm -q will agree # rpm -q will agree
echo "Release: `. scripts/mkversion`" echo "Release: `. scripts/mkversion`"
...@@ -17,8 +23,9 @@ echo "Group: System Environment/Kernel" ...@@ -17,8 +23,9 @@ echo "Group: System Environment/Kernel"
echo "Vendor: The Linux Community" echo "Vendor: The Linux Community"
echo "URL: http://www.kernel.org" echo "URL: http://www.kernel.org"
echo -n "Source: kernel-$VERSION.$PATCHLEVEL.$SUBLEVEL" echo -n "Source: kernel-$VERSION.$PATCHLEVEL.$SUBLEVEL"
echo "$EXTRAVERSION.tar.gz" | sed -e "s/-//" echo "$EXTRAVERSION.tar.gz" | sed -e "s/-//g"
echo "BuildRoot: /var/tmp/%{name}-%{PACKAGE_VERSION}-root" echo "BuildRoot: /var/tmp/%{name}-%{PACKAGE_VERSION}-root"
echo "Provides: $PROVIDES"
echo "%define __spec_install_post /usr/lib/rpm/brp-compress || :" echo "%define __spec_install_post /usr/lib/rpm/brp-compress || :"
echo "" echo ""
echo "%description" echo "%description"
...@@ -35,6 +42,7 @@ echo 'mkdir -p $RPM_BUILD_ROOT/boot $RPM_BUILD_ROOT/lib $RPM_BUILD_ROOT/lib/modu ...@@ -35,6 +42,7 @@ echo 'mkdir -p $RPM_BUILD_ROOT/boot $RPM_BUILD_ROOT/lib $RPM_BUILD_ROOT/lib/modu
echo 'INSTALL_MOD_PATH=$RPM_BUILD_ROOT make modules_install' echo 'INSTALL_MOD_PATH=$RPM_BUILD_ROOT make modules_install'
echo 'cp arch/i386/boot/bzImage $RPM_BUILD_ROOT'"/boot/vmlinuz-$VERSION.$PATCHLEVEL.$SUBLEVEL$EXTRAVERSION" echo 'cp arch/i386/boot/bzImage $RPM_BUILD_ROOT'"/boot/vmlinuz-$VERSION.$PATCHLEVEL.$SUBLEVEL$EXTRAVERSION"
echo 'cp System.map $RPM_BUILD_ROOT'"/boot/System.map-$VERSION.$PATCHLEVEL.$SUBLEVEL$EXTRAVERSION" echo 'cp System.map $RPM_BUILD_ROOT'"/boot/System.map-$VERSION.$PATCHLEVEL.$SUBLEVEL$EXTRAVERSION"
echo 'cp .config $RPM_BUILD_ROOT'"/boot/config-$VERSION.$PATCHLEVEL.$SUBLEVEL$EXTRAVERSION"
echo "" echo ""
echo "%clean" echo "%clean"
echo '#echo -rf $RPM_BUILD_ROOT' echo '#echo -rf $RPM_BUILD_ROOT'
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment