wok view linux-source/stuff/get-linux-source @ rev 6977
Fixed linux-source again (i hope).
author | Christopher Rogers <slaxemulator@gmail.com> |
---|---|
date | Thu Oct 28 05:47:06 2010 +0000 (2010-10-28) |
parents | a1cd19a9e269 |
children | bd3ed7d16aca |
line source
1 #!/bin/sh
3 source /etc/tazwok.conf
4 VERSION=XXX
6 url=$(cat /usr/src/kernel-patches/url)
8 if [ -f $SOURCES_REPOSITORY/$(basename $url) ]; then
9 cd /usr/src/
10 tar xjf $(basename $url)
11 else
12 wget -O $SOURCES_REPOSITORY/$(basename $url)
13 cd /usr/src/
14 tar xjf $(basename $url)
15 fi
17 cp -a /usr/src/kernel-patches/slitaz /usr/src/linux-$VERSION
19 cp -pa /usr/src/linux-$VERSION/slitaz/aufs2/* /usr/src/linux-$VERSION
20 # Add tazpkg support
21 if [ -d "/usr/src/linux-$VERSION/scripts/package" ]; then
22 cp -pa /usr/src/linux-$VERSION/slitaz/buildtaz /usr/src/linux-$VERSION/scripts/package
23 cd /usr/src/linux-$VERSION
24 patch -p1 -i slitaz/make-tazpkg.u
25 fi
27 cd /usr/src/linux-$VERSION
28 while read patch_file; do
29 echo "Apply $patch_file"
30 patch -p1 < slitaz/$patch_file
31 done < slitaz/patches
32 [ ! -f System.map ] && cp slitaz/config .config &&
33 make oldconfig && make modules_prepare
35 cat <<EOT
36 ----
37 To modify the kernel configuration:
38 $ cd /usr/src/linux-$VERSION
39 $ make menuconfig
41 To build the kernel and the modules:
42 $ cd /usr/src/linux-$VERSION
43 $ make bzImage && make modules
45 To install the new kernel and the modules:
46 $ make modules_install
47 $ cp -a arch/x86/boot/bzImage /boot/vmlinuz-$VERSION-slitaz
49 To make a Slitaz package with the new kernel and the modules:
50 $ make tazpkg
52 See /usr/src/linux-$VERSION/README
53 ----
54 EOT