#!/bin/bash
#
# I'm getting more efficient/lazy now.
# This is only run when I've tested stuff and just make a few tweaks 
# to the packages, and want to be sure the packages are 
# all up to date -- I tend to lose track of what packages I put where,
# so this is just the script to rebuild everything once again
# prior to a complete reinstallation of the dev boxes.
# 
# Build:
#  * RiscPC Kernel;
#  * Versatile Kernel;
#  * Linux Kernel source package;
#  * Linux Kernel modules all-in-one package
#
~/armedslack/dbuild && \
./versatile && \
./kernel-2.6-sourcepackage.SlackBuild && \
cd ../a/kernel-modules/ && \
./arm/build || exit 

#
# and then 
# you wanna .. update the bootware for the RiscPC, so
# you've also updated the KERNELVERSION variable in 'grub.brew'..
cd ~/ac/source/bootware/riscos/
~/armedslack/dbuild
# And finally, let's plop the new zImage for the Versatile board
# onto my dev box, so I can pull it off and boot qemu into the installer
# and run an installation test.  Of course, the RiscPC requires more effort
# which is why I don't do it as often as I ought to.
cp -favv ~/tmp/build-kernel_versatile/linux-*/arch/arm/boot/zImage /mnt/prisroot/tmp/zImage-versatile

# And now build the Kernel headers.
# I don't usually do this but on this occasion I want to rebuild
# glibc afterwards:
#
#cd ~/ac/source/d/kernel-headers
#./arm/build
