diff options
Diffstat (limited to 'bin/bump_ati_drivers')
-rwxr-xr-x | bin/bump_ati_drivers | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/bin/bump_ati_drivers b/bin/bump_ati_drivers new file mode 100755 index 0000000..e0e5040 --- /dev/null +++ b/bin/bump_ati_drivers @@ -0,0 +1,22 @@ +#!/bin/sh + +. /kogaion/bin/kernels.inc +packages="x11-drivers/ati-drivers::kogaion-desktop" + +# build for latest kernel +KERNEL_DIR="/usr/src/linux-${running_kernel}" emerge $packages media-video/amdcccle::kogaion-desktop +echo -5 | etc-update +eit commit + +for kernel in $kernels; do + if [ "${kernel}" = "${running_kernel}" ]; then + continue + fi + rm -rf /usr/portage/packages/* + KERNEL_DIR="/usr/src/linux-${kernel}" emerge -B ${packages} || { echo "ouch unable to build" && exit 1; } + built_pkgs=$(find /usr/portage/packages -name "*.tbz2" | xargs echo) + [[ -z "${built_pkgs}" ]] && echo "ouch no kernel pkgs" && exit 2 + eit inject ${built_pkgs} || { echo "ouch unable to inject" && exit 3; } +done + +echo "Now you should remove old packages..." |