wok annotate linux/receipt @ rev 586

iFix: Typo in newt-dev
author Eric Joseph-Alexandre <erjo@slitaz.org>
date Wed Apr 16 01:14:00 2008 +0200 (2008-04-16)
parents 998d2b306f24
children d930832824c9
rev   line source
pankso@3 1 # SliTaz package receipt.
pankso@3 2
pankso@3 3 PACKAGE="linux"
pascal@214 4 VERSION="2.6.24.2"
pankso@3 5 CATEGORY="base-system"
pankso@3 6 SHORT_DESC="The Linux kernel and modules."
pankso@289 7 MAINTAINER="pascal.bellard@slitaz.org"
pankso@3 8 TARBALL="$PACKAGE-$VERSION.tar.bz2"
pankso@3 9 WEB_SITE="http://www.kernel.org/"
pankso@3 10 WGET_URL="http://www.eu.kernel.org/pub/linux/kernel/v2.6/$TARBALL"
pankso@3 11
pankso@3 12 # Rules to configure and make the package.
pankso@3 13 compile_rules()
pankso@3 14 {
erjo@253 15 cd $src
erjo@253 16 # lzma and boot patch from pascal
pascal@521 17 while read patch_file; do
pascal@521 18 echo "Apply $patch_file"
pascal@521 19 patch -p1 < ../stuff/$patch_file
pascal@521 20 done <<EOT
pascal@521 21 boot-kernel.u
pascal@521 22 $PACKAGE-lzma-$VERSION.u
pascal@521 23 decompress_unlzma.u
pascal@521 24 EOT
erjo@253 25 make mrproper
erjo@253 26 cp ../stuff/$PACKAGE-$VERSION-slitaz.config .config
pascal@521 27 while read patch_file; do
pascal@521 28 echo "Apply $patch_file"
pascal@521 29 patch -p1 < ../stuff/$patch_file
pascal@521 30 done <<EOT
pascal@521 31 config-acpi-$VERSION.u
pascal@521 32 linux-utf8-$VERSION.u
pascal@521 33 config-ieee1394-$VERSION.u
pascal@521 34 linux-lzma-export.u
pascal@521 35 config-tun-$VERSION.u
pascal@521 36 config-reiserfs-$VERSION.u
pascal@521 37 config-wireless-$VERSION.u
pascal@521 38 EOT
erjo@253 39 make oldconfig
erjo@253 40 make bzImage
erjo@253 41 make modules
erjo@253 42 make INSTALL_MOD_PATH=$PWD/_pkg modules_install
erjo@253 43 }
erjo@253 44
pankso@3 45 # Rules to gen a SliTaz package suitable for Tazpkg.
pankso@3 46 genpkg_rules()
pankso@3 47 {
pascal@521 48 local path
pankso@3 49 mkdir $fs/boot
pascal@214 50 cp -a $src/arch/x86/boot/bzImage $fs/boot/vmlinuz-$VERSION-slitaz
pankso@3 51 # Compress all modules.
pankso@3 52 # Package module-init-tools is compiled with zlib support.
pankso@3 53 #
pascal@521 54 ./stuff/gztazmod.sh $_pkg/lib/modules/$VERSION-slitaz
pascal@521 55 path=$fs/lib/modules/$VERSION-slitaz/kernel
pascal@521 56 mkdir -p $path
pascal@521 57 cp -a $_pkg/lib/modules/$VERSION-slitaz/mo* $fs/lib/modules/$VERSION-slitaz
pascal@521 58 while read module; do
pascal@521 59 dir=$(dirname $module)
pankso@535 60 [ -d $path/$dir ] || mkdir -p $path/$dir
pankso@535 61 cp -a $_pkg/lib/modules/$VERSION-slitaz/kernel/$module $path/$dir
pascal@521 62 done < stuff/modules-$VERSION.list
pascal@397 63 # Remove unresolved links
pascal@397 64 rm -f $fs/lib/modules/$VERSION-slitaz/build
pascal@397 65 rm -f $fs/lib/modules/$VERSION-slitaz/source
pankso@3 66 }
pankso@3 67
pankso@3 68 # Pre and post install commands for Tazpkg.
pankso@3 69 # GRUB stuf.
pankso@3 70 post_install()
pankso@3 71 {
pascal@521 72 echo "Processing post-install commands..."
pascal@532 73 depmod -a -b /$1
pascal@521 74 echo "----"
pascal@521 75 echo "If you have GRUB installed, you can add tree lines to boot SliTaz."
pascal@521 76 echo "Example /boot/grub/menu.lst"
pascal@521 77 echo -e "
pankso@3 78 title SliTaz GNU/Linux (Kernel $VERSION-slitaz)
pankso@3 79 root(hd0,0)
pankso@3 80 kernel /boot/vmlinuz-$VERSION-slitaz root=/dev/hda1 vga=771\n"
pascal@521 81 echo "----"
pankso@3 82 }