wok annotate linux/receipt @ rev 2804

update qt-4.4.1 to qt-4.5.0
author Allan Pinto <allan316@gmail.com>
date Wed Apr 29 09:28:07 2009 +0000 (2009-04-29)
parents d1f8fd6f6efe
children f306d126580e
rev   line source
pankso@3 1 # SliTaz package receipt.
pankso@3 2
pankso@3 3 PACKAGE="linux"
pascal@886 4 VERSION="2.6.25.5"
pankso@3 5 CATEGORY="base-system"
pankso@3 6 SHORT_DESC="The Linux kernel and modules."
pankso@1154 7 BUILD_DEPENDS="slitaz-toolchain perl"
pankso@289 8 MAINTAINER="pascal.bellard@slitaz.org"
pankso@3 9 TARBALL="$PACKAGE-$VERSION.tar.bz2"
pankso@3 10 WEB_SITE="http://www.kernel.org/"
pankso@3 11 WGET_URL="http://www.eu.kernel.org/pub/linux/kernel/v2.6/$TARBALL"
pascal@1909 12 CONFIG_FILES="/lib/modules/$VERSION-slitaz/modules.dep"
pankso@3 13
pankso@3 14 # Rules to configure and make the package.
pankso@3 15 compile_rules()
pankso@3 16 {
erjo@253 17 cd $src
pascal@2158 18 rm -rf slitaz 2> /dev/null
pascal@1093 19 mkdir slitaz
pascal@1093 20 echo "$WGET_URL" > slitaz/url
pascal@1093 21 cp ../stuff/gztazmod.sh ../stuff/list_modules.sh slitaz
pascal@886 22 # lzma and misc patches from pascal
pascal@521 23 while read patch_file; do
pascal@1442 24 if [ -f done.$patch_file ]; then
pascal@1442 25 echo "Skipping $patch_file"
pascal@1442 26 continue
pascal@1442 27 fi
pascal@521 28 echo "Apply $patch_file"
pascal@881 29 patch -p1 < ../stuff/$patch_file || return 1
pascal@1093 30 echo "$patch_file" >> slitaz/patches
pascal@1093 31 cp ../stuff/$patch_file slitaz/$patch_file
pascal@1442 32 touch done.$patch_file
pascal@521 33 done <<EOT
pascal@521 34 $PACKAGE-lzma-$VERSION.u
pascal@886 35 $PACKAGE-utf8-$VERSION.u
pascal@886 36 $PACKAGE-diff-$VERSION.u
pascal@905 37 $PACKAGE-rootdev.u
pascal@2777 38 $PACKAGE-ioremap-$VERSION.u
pascal@521 39 EOT
erjo@253 40 make mrproper
erjo@253 41 cp ../stuff/$PACKAGE-$VERSION-slitaz.config .config
erjo@253 42 make oldconfig
pascal@1093 43 ln .config slitaz/config
erjo@253 44 make bzImage
erjo@253 45 make modules
erjo@253 46 make INSTALL_MOD_PATH=$PWD/_pkg modules_install
pascal@886 47 make INSTALL_HDR_PATH=$PWD/_pkg/usr headers_install
erjo@253 48 }
erjo@253 49
pankso@3 50 # Rules to gen a SliTaz package suitable for Tazpkg.
pankso@3 51 genpkg_rules()
pankso@3 52 {
pascal@521 53 local path
pankso@3 54 mkdir $fs/boot
pascal@214 55 cp -a $src/arch/x86/boot/bzImage $fs/boot/vmlinuz-$VERSION-slitaz
pankso@3 56 # Compress all modules.
pankso@3 57 # Package module-init-tools is compiled with zlib support.
pankso@3 58 #
pascal@521 59 ./stuff/gztazmod.sh $_pkg/lib/modules/$VERSION-slitaz
pascal@521 60 path=$fs/lib/modules/$VERSION-slitaz/kernel
pascal@521 61 mkdir -p $path
pascal@521 62 cp -a $_pkg/lib/modules/$VERSION-slitaz/mo* $fs/lib/modules/$VERSION-slitaz
pascal@886 63 cp ./stuff/list_modules.sh $src
pascal@886 64 export src
pascal@886 65 export _pkg
pascal@886 66 $src/list_modules.sh $(cat stuff/modules-$VERSION.list) > $src/modules.list
pascal@521 67 while read module; do
pascal@521 68 dir=$(dirname $module)
pankso@535 69 [ -d $path/$dir ] || mkdir -p $path/$dir
pankso@535 70 cp -a $_pkg/lib/modules/$VERSION-slitaz/kernel/$module $path/$dir
pascal@886 71 done < $src/modules.list
pascal@397 72 # Remove unresolved links
pascal@397 73 rm -f $fs/lib/modules/$VERSION-slitaz/build
pascal@397 74 rm -f $fs/lib/modules/$VERSION-slitaz/source
pascal@886 75 # Package all linux pkgs
pascal@886 76 for i in $(cd $WOK; ls -d linux-*)
pankso@871 77 do
pascal@886 78 tazwok genpkg $i
pascal@886 79 done
pascal@886 80 # Cook all packages with a kernel module
pascal@886 81 for i in $(cd $WOK; grep -l 'tazwok cook linux$' */receipt)
pascal@886 82 do
pascal@886 83 echo tazwok cook ${i%/receipt}
pankso@871 84 done
pankso@3 85 }
pankso@3 86
pankso@3 87 # Pre and post install commands for Tazpkg.
pankso@3 88 # GRUB stuf.
pankso@3 89 post_install()
pankso@3 90 {
pascal@521 91 echo "Processing post-install commands..."
pascal@886 92 depmod -a -b "$1/" $VERSION-slitaz
pankso@1154 93 if [ -f "$1/boot/grub/menu.lst" ]; then
pankso@1154 94 root_dev=`cat $1/boot/grub/menu.lst | grep root= | sed 's/.*root=\([^ ]*\).*/\1/'`
pankso@1154 95 grub_dev=`cat $1/boot/grub/menu.lst | grep "root ("`
pankso@1154 96 # Add new kernel entry in case of upgrade for installed system.
pankso@1154 97 cat >> $1/boot/grub/menu.lst << EOT
pankso@1154 98
pankso@1154 99 title SliTaz GNU/Linux (Kernel $VERSION-slitaz)
pankso@1154 100 $grub_dev
pankso@1154 101 kernel /boot/vmlinuz-$VERSION-slitaz root=$root_dev
pankso@1154 102 EOT
pankso@1154 103 # Display information message.
pankso@1154 104 cat <<EOT
pascal@886 105 ----
pankso@1154 106 GRUB is installed, these tree lines has been added to the menu.lst:
pascal@886 107
pankso@3 108 title SliTaz GNU/Linux (Kernel $VERSION-slitaz)
pankso@1154 109 $grub_dev
pankso@1154 110 kernel /boot/vmlinuz-$VERSION-slitaz root=$root_dev
pascal@886 111 ----
pascal@886 112 EOT
pankso@1154 113 fi
pankso@3 114 }