summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xscripts/build-and-install16
-rwxr-xr-xscripts/prepare11
2 files changed, 21 insertions, 6 deletions
diff --git a/scripts/build-and-install b/scripts/build-and-install
index 0bd0314..98d63f1 100755
--- a/scripts/build-and-install
+++ b/scripts/build-and-install
@@ -16,10 +16,10 @@ make -j $(nproc)
sudo make modules_install
sudo ln -s /lib/modules/$V-* /lib/modules/$V
-# cp to /boot + lilo
+# cp to /boot + run lilo
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 sha1sum /boot/kernel > /tmp/kernel.sha1
+sudo mv /tmp/kernel.sha1 /boot/kernel.sha1
sudo /sbin/lilo
# /usr/src/linux symlink
@@ -29,16 +29,20 @@ find . -type f | xargs chmod a+r
find . -executable | xargs chmod a+x
sudo ln -s $(pwd) /usr/src/linux
+pushd .
+
# tp smapi
-cd ~/.local/src/kernel/tp_smapi/
+cd ../extra_modules/tp_smapi/
sudo make HDAPS=0 install KVER=$V KSRC=/home/pks/.local/src/kernel/linux-$V KBUILD=/home/pks/.local/src/kernel/linux-$V
sudo make clean
# phc intel
-cd ~/.local/src/kernel/phc_intel/
+cd ../phc_intel/
KERNELRELEASE=$V KERNELSRC=../linux-$V make
sudo make install
make clean
sudo depmod
-sudo chown -R pks:pks * .* ~/.local/src/kernel/tp_smapi/ ~/.local/src/kernel/linux-*
+popd
+
+sudo chown -R pks:pks * .* ../extra_modules
diff --git a/scripts/prepare b/scripts/prepare
new file mode 100755
index 0000000..e5a781c
--- /dev/null
+++ b/scripts/prepare
@@ -0,0 +1,11 @@
+#!env zsh
+
+if [[ ! -f ../config || ! -d ../patches ]]; then
+ echo "Likely not in kernel dir, exiting"
+ exit 1
+fi
+
+cp ../config .config
+patch -p1 < ../patches/O3.patch
+patch -p1 < ../patches/patch-*.*-ck1
+make oldconfig