

Code: Select all
mkdir /trial
mkdir /trail/tmp
# copy everything into /trial, except /trial, /boot, /tmp
# (Should /mnt and /proc be copied??)
cp -R /bin /trial
cp -R /dev /trial
cp -R /etc /trial
cp -R /home /trial
cp -R /lib /trial
cp -R /mnt /trial
cp -R /opt /trial
cp -R /proc /trial
cp -R /root /trial
cp -R /sbin /trial
cp -R /service /trial
cp -R /usr /trial
cp -R /var /trial
# change file hierarchy root
chroot /trial /bin/bash
env-update && source /etc/profile
# update: but only the file hierarchy originally rooted at /trial
emerge rsync
emerge -u world
etc-update
# recompile the new kernel
cd /usr/src/linux
# Clueless noob IQ test failure: At this point need to somehow
# magically switch to new kernel and daemons without rebooting...
# because if the update failed, we want a reboot to return us to
# the known good kernel and daemons. Will need to start a new ssh
# session.
#
# Presuming everything worked, replace the originals with updates.
# First reboot. Then...
rm -R /bin
rm -R /dev
rm -R /etc
rm -R /home
rm -R /lib
rm -R /mnt
rm -R /opt
rm -R /proc
rm -R /root
rm -R /sbin
rm -R /service
rm -R /usr
rm -R /var
cp -R /trial/bin /bin
cp -R /trial/dev /dev
cp -R /trial/etc /etc
cp -R /trial/home /home
cp -R /trial/lib /lib
cp -R /trial/mnt /mnt
cp -R /trial/opt /opt
cp -R /trial/proc /proc
cp -R /trial/root /root
cp -R /trial/sbin /sbin
cp -R /trial/service /service
cp -R /trial/usr /usr
cp -R /trial/var /var
# Replace the old kernel with the tested one (I use grub)
mount /dev/hda1 /boot
cp /usr/src/linux/arch/i386/boot/bzImage /boot
umount /boot
reboot

This is the reason why i want to stick to a special version of a program.Anyway works fine but a updating world led to a few pages not work
Code: Select all
emerge cleanCode: Select all
gcc-config