diff options
author | Patrick Simianer <p@simianer.de> | 2017-02-12 21:42:56 +0100 |
---|---|---|
committer | Patrick Simianer <p@simianer.de> | 2017-02-12 21:42:56 +0100 |
commit | 8c06d3d046f51490eb378ab474f685072d2ddddb (patch) | |
tree | 004ec54592602d5ed33e18e2dcb0fa6d41be03db | |
parent | 48e531c50c71ad4b94b2ef419cd57440e847de50 (diff) |
upgrade-kernel
-rwxr-xr-x | upgrade-kernel | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/upgrade-kernel b/upgrade-kernel new file mode 100755 index 0000000..32336c3 --- /dev/null +++ b/upgrade-kernel @@ -0,0 +1,23 @@ +#!/bin/sh + +if [ ! -f .config ]; then echo "Call from kernel source dir!"; exit; fi +V=`pwd | ruby -e "puts STDIN.gets.split('/').last.split('-')[1..-1].join '-'"`; +make mrproper +cp -v ../config .config +make +sudo make modules_install +sudo cp -v arch/x86/boot/bzImage /boot/kernel +sudo md5sum /boot/kernel > /tmp/kernel.md5 +sudo mv /tmp/kernel.md5 /boot/kernel.md5 +sudo /sbin/lilo +sudo rm /usr/src/linux +sudo ln -s $(pwd) /usr/src/linux +cd ~/.local/src/kernel/tp_smapi/ +sudo make HDAPS=1 install KVER=$V KSRC=/home/pks/.local/src/kernel/linux-$V KBUILD=/home/pks/.local/src/kernel/linux-$V +sudo make clean +sudo chown -R pks:pks * .* /home/pks/.local/src/kernel/tp_smapi/ /home/pks/.local/src/kernel/linux-* +echo "=================" +cd /lib/modules/ +pwd +ls -lah + |