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