summaryrefslogtreecommitdiffstats
path: root/update_kernel
diff options
context:
space:
mode:
authorMystery Man <unknown@mandriva.org>2001-06-11 11:44:34 +0000
committerMystery Man <unknown@mandriva.org>2001-06-11 11:44:34 +0000
commit7507023403933bbd0d851a250a474f85ba6a89d2 (patch)
treec212a6c0eae5ed2c9964c390ebb72970ec08fd08 /update_kernel
parentab5559aaabd1167a18ac882e64d97c5adc0e7d03 (diff)
downloaddrakx-7507023403933bbd0d851a250a474f85ba6a89d2.tar
drakx-7507023403933bbd0d851a250a474f85ba6a89d2.tar.gz
drakx-7507023403933bbd0d851a250a474f85ba6a89d2.tar.bz2
drakx-7507023403933bbd0d851a250a474f85ba6a89d2.tar.xz
drakx-7507023403933bbd0d851a250a474f85ba6a89d2.zip
This commit was manufactured by cvs2svn to create branch 'ppp'.topic/ppp
Diffstat (limited to 'update_kernel')
-rwxr-xr-xupdate_kernel137
1 files changed, 0 insertions, 137 deletions
diff --git a/update_kernel b/update_kernel
deleted file mode 100755
index 7d4002b51..000000000
--- a/update_kernel
+++ /dev/null
@@ -1,137 +0,0 @@
-#!/bin/bash
-
-ALL_KERNELS="all.kernels"
-
-function f() {
- echo -n "."
- v=`perl -Iperl-install -Mmodules -e "print qq(\\$_.o\n) foreach modules::module_of_type__4update_kernel(\"$1\")"`
-}
-
-function create_marfile() {
- marfile=$1
- shift
- for i in $*
- do
- j=`basename $i .o`
- needed=`cat modules.dep | perl -ne "print "'$1'" if /^$j: (.*)/"`
- for k in $needed
- do
- [ -z "`echo $* | grep $k`" ] \
- && [ -z "`echo $PCMCIA_COREMODULES | grep $k`" ] \
- && echo "WARNING! in $marfile, $k is missing (required by $i)"
- done
- done
- $GIBASEDIR/mdk-stage1/mar/mar -c $marfile $(ls $*)
-}
-
-function create_modules() {
- kernel_path=$1
- kern=$2
- echo "Updating modules in '`pwd`' for kernel '$kern'"
- cp -f `find $kernel_path/lib/modules/ -name "*.o"` .
- /sbin/depmod -F $kernel_path/boot/System.map* -e *.o | perl -pe 's/\\\n//' \
- | perl -ne 's/\.o//g; s/[ \t]+/ /g; print if /: /' > modules.dep
- perl -pi -e 's/((plip|ppa|imm): parport)/$1 parport_pc/' modules.dep
- ls *.o | packdrake -b9s "modules.cz" 400000
- mv modules.cz ../modules.cz-$kern
- create_marfile network_modules.mar $NETWORK_MODULES $GENERIC_MODULES
- create_marfile cdrom_modules.mar $CDROM_MODULES $GENERIC_MODULES
- create_marfile hd_modules.mar $HD_MODULES $GENERIC_MODULES
- create_marfile pcmcia_modules.mar $PCMCIA_MODULES $PCMCIA_COREMODULES $GENERIC_MODULES
- create_marfile other_modules.mar $BIG_MODULES $GENERIC_MODULES
- create_marfile all_modules.mar $ALL_MODULES $GENERIC_MODULES
- rm -f $ALL_MODULES $PCMCIA_COREMODULES $NOT_USEFULL_IN_STAGE1 # leave in the directory non-install1 used modules
-}
-
-[ -e $ALL_KERNELS/.main ] && main=$(cat $ALL_KERNELS/.main)
-[ -n "$main" -a -e $ALL_KERNELS/$main ] || {
- pushd . >/dev/null
- cd $ALL_KERNELS
- main=$(echo 2.* | sed 's/.* //')
- echo "Choosing $main"
- echo $main > .main
- popd >/dev/null
-}
-
-ARCH=`uname -m | sed -e 's/i.86/i386/' -e 's/sparc.*/sparc/'`
-
-echo -n "Finding modules categories"
-f "scsi" ; SCSI_DRIVERS=$v
-f "disk" ; DISK_DRIVERS=$v
-f "net" ; NETWORK_DRIVERS=$v
-f "scsi cdrom" ; CD_DRIVERS=$v
-f "pcmcia net_raw cdrom_raw scsi_raw disk_raw" ; PCMCIA_DRIVERS=$v
-f "big net_raw cdrom_raw scsi_raw disk_raw" ; BIG_DRIVERS=$v
-f "pcmcia net cdrom scsi disk keepbig" ; ALL_DRIVERS=$v
-[ $ARCH == "i386" ] && DOSMODULES="vfat.o fat.o"
-echo "done."
-
-NETWORK_MODULES=" $NETWORK_DRIVERS"
-CDROM_MODULES=" $CD_DRIVERS"
-if [ "$ARCH" == "ppc" ]; then
- HD_MODULES=" $DOSMODULES $SCSI_DRIVERS $DISK_DRIVERS loop.o isofs.o reiserfs.o hfs.o"
-else
- HD_MODULES=" $DOSMODULES $SCSI_DRIVERS $DISK_DRIVERS loop.o isofs.o reiserfs.o"
-fi
-PCMCIA_MODULES=" $DOSMODULES $PCMCIA_DRIVERS"
-BIG_MODULES=" $BIG_DRIVERS"
-if [ "$ARCH" == "ppc" ]; then
- ALL_MODULES=" $DOSMODULES $ALL_DRIVERS loop.o isofs.o reiserfs.o hfs.o"
-else
- ALL_MODULES=" $DOSMODULES $ALL_DRIVERS loop.o isofs.o reiserfs.o"
-fi
-NOT_USEFULL_IN_STAGE1="nls_*.o parport_probe.o raid*.o serial.o smbfs.o usb-*.o"
-
-GENERIC_MODULES="isa-pnp.o floppy.o"
-
-PCMCIA_COREMODULES="pcmcia_core.o tcic.o ds.o i82365.o"
-
-
-if [ "$ARCH" == "i386" ]; then
- for i in $ALL_KERNELS/*/boot/vmlinuz*; do
- #disable any existing resolution!!!
- /usr/sbin/rdev -v $i 65535 #788 #785
- done
-else
- if [ "$ARCH" == "ppc" ]; then
- cp -f "$KERNEL_BOOT_PATH"/boot/vmlinux .
- else
- cp -f "$KERNEL_BOOT_PATH"/boot/vmlinux.gz .
- fi
-fi
-
-
-GIBASEDIR=`pwd`
-
-rm -rf all.modules ; mkdir all.modules
-for i in $ALL_KERNELS/*; do
- kern=`basename $i`
- [ -e $i/cardmgr ] && (
- cd $i/cardmgr
- touch main.c
- nm cardmgr.o | grep -q cardmgr_main && echo "int main(int argc, char **argv) { cardmgr_main(argc, argv); }" > main.c
- gcc -o cardmgr-$kern *.o main.c
- )
- (
- mkdir all.modules/$kern
- cd all.modules/$kern
- if [ "$kern" = "$main" ]; then
- create_modules ../../$i $kern
- else
- echo "$kern ($main)"
- create_modules ../../$i $kern 2>/dev/null
- fi
- )
-done
-
-
-install_kernel() {
- v=2.4.3-BOOT4
- scp kenobi:~chmou/work/kernel/archive/kernel-$v.tar.bz2 /tmp
- cd ~/gi/all.kernels ; rm -rf $v ; mkdir $v ; cd $v ; tar xfj /tmp/kernel-$v.tar.bz2
- cd ~/gi ; ./update_kernel ; rm -f images/network.rdz ; ./make_boot_img images/network.rdz network
- scp all.kernels/$v/boot/vmlinu* kenobi:/tftpboot/vmlinuz
- scp images/network.rdz kenobi:/tftpboot
- cp -f ~/gi/all.modules/modules.cz-$v /export/Mandrake/mdkinst/lib/modules.cz
-}
-# scp kenobi:~mbadaire/kernel/boot/archive/kernel-$v.tar.bz2 /tmp