wok annotate linux64/receipt @ rev 17605

notify-python: fix notify_notification_new args
author Pascal Bellard <pascal.bellard@slitaz.org>
date Thu Feb 12 13:15:01 2015 +0100 (2015-02-12)
parents 51a123a3f6f5
children 08cf996a2307
rev   line source
pankso@12285 1 # SliTaz package receipt.
pankso@12285 2
pankso@12285 3 PACKAGE="linux64"
pascal@15670 4 VERSION="3.2.53"
pankso@12285 5 CATEGORY="base-system"
pankso@12285 6 SHORT_DESC="The Linux 64 bits kernel and modules."
pankso@12285 7 MAINTAINER="devel@slitaz.org"
pascal@14657 8 LICENSE="GPL2"
pankso@12285 9 WEB_SITE="http://www.kernel.org/"
pankso@12285 10 WANTED="linux"
pankso@12285 11 PROVIDE="linux"
pankso@15866 12
pankso@15866 13 # We want it regenerated on each kernel/module install
pascal@17028 14 #CONFIG_FILES="/lib/modules/$VERSION-slitaz64/modules.dep"
pankso@12285 15
pankso@12285 16 DEPENDS="depmod"
pankso@12285 17
pankso@12285 18 # Rules to gen a SliTaz package suitable for Tazpkg.
pankso@12285 19 genpkg_rules()
pankso@12285 20 {
pankso@12285 21 local path
pascal@16657 22 install=$install/linux64
pascal@17276 23 src=$WOK/$PACKAGE/source/tmp
pascal@16657 24 cp -a $install/boot $fs
pascal@17028 25 path=$fs/lib/modules/$VERSION-slitaz64/kernel
pankso@12285 26 mkdir -p $path
pascal@17028 27 cp -a $install/lib/modules/$VERSION-slitaz64/mo* \
pascal@17032 28 $fs/lib/modules/$VERSION-slitaz64
pankso@15866 29
pankso@12285 30 # Get the base modules
pankso@12285 31 export src
pascal@16657 32 export install
pankso@12285 33 mkdir -p $WOK/$PACKAGE/source/tmp
pankso@12285 34 $wanted_stuff/list_modules.sh \
pascal@13937 35 $(cat $stuff/modules64.list) > $WOK/$PACKAGE/source/tmp/modules.list
pankso@12285 36 while read module; do
pankso@12285 37 dir=$(dirname $module)
pankso@12285 38 [ -d $path/$dir ] || mkdir -p $path/$dir
pascal@17028 39 cp -a $install/lib/modules/$VERSION-slitaz64/kernel/$module $path/$dir
pankso@12285 40 done < $WOK/$PACKAGE/source/tmp/modules.list
pankso@12285 41 # Remove unresolved links
pascal@17028 42 rm -f $fs/lib/modules/$VERSION-slitaz64/build
pascal@17028 43 rm -f $fs/lib/modules/$VERSION-slitaz64/source
pankso@12285 44 # Cook all packages with a kernel module
pascal@17032 45 for i in $(cd $WOK; grep -l 'cook linux64$' */receipt)
pankso@12285 46 do
pascal@13937 47 echo cook ${i%/receipt}
pankso@12285 48 done
pankso@12285 49 # Fixed modules.dep to use right path
pankso@12285 50 # saves 100kb of space too
pascal@17028 51 sed -i "s|$install||g" $fs/lib/modules/$VERSION-slitaz64/modules.dep
pascal@17028 52 sed -i "s|99.98.$VERSION-slitaz|$VERSION-slitaz|g" $fs/lib/modules/$VERSION-slitaz64/modules.dep
pankso@12285 53 # Check and echo any module in kernel .config that's not added to
pankso@12285 54 # one of linux-* pkgs
pascal@13941 55 $wanted_stuff/check_modules.sh 2>&1 | grep -v files.list
pankso@12285 56 }
pankso@12285 57
pankso@12285 58 # Pre and post install commands for Tazpkg.
pankso@12285 59 post_install()
pankso@12285 60 {
pankso@12285 61 echo "Processing post-install commands..."
pascal@17032 62 chroot "$root/" depmod -a $VERSION-slitaz64
pankso@12285 63 # GRUB stuff.
pankso@15866 64 if [ -f "$root/boot/grub/menu.lst" ]; then
pankso@15866 65 root_dev=$(cat $root/boot/grub/menu.lst | grep root= | sed 's/.*root=\([^ ]*\).*/\1/' | head -n 1)
pankso@15866 66 grub_dev=$(cat $root/boot/grub/menu.lst | grep "root (" | head -n 1)
pankso@12285 67 # Add new kernel entry in case of upgrade for installed system.
pascal@17032 68 if ! grep -q $PACKAGE-$VERSION-slitaz64 $1/boot/grub/menu.lst; then
pankso@12285 69 cat >> $1/boot/grub/menu.lst << EOT
pankso@12285 70
pascal@17032 71 title SliTaz GNU/Linux (Kernel $VERSION-slitaz64)
pankso@12285 72 $grub_dev
pascal@17032 73 kernel /boot/vmlinuz-$VERSION-slitaz64 root=$root_dev
pankso@12285 74 EOT
pankso@12285 75 fi
pankso@12285 76 # Display information message.
pankso@12285 77 cat <<EOT
pankso@12285 78 ----
pankso@12285 79 GRUB is installed, these tree lines must be in your /boot/grub/menu.lst:
pankso@12285 80
pascal@17032 81 title SliTaz GNU/Linux (Kernel $VERSION-slitaz64)
pankso@12285 82 $grub_dev
pascal@17032 83 kernel /boot/vmlinuz-$VERSION-slitaz64 root=$root_dev
pankso@12285 84 ----
pankso@12285 85 EOT
pankso@12285 86 fi
pankso@12285 87 }