Home
Repository 32bit  Forum
Repository 64bit  Wiki

Modifiche

Slackware Chroot AutoBuilder

146 byte aggiunti, 11:06, 5 dic 2010
Script
elif [ $(uname -m) = x86_64 ]; then
echo
echo -e "\E[34m>\E[0m Select \E[1mSelect the architecture for Slackware\E[0m"
echo
echo " [1] x86"
echo
echo
echo -e "\E[34m>\E[0m Select \E[1mSelect your chroot directory\E[0m"
echo
echo " Write a path for your chroot"
# Remove directories if that is necessary
echo
echo -ne "\E[34m>\E[0m Checking \E[1mChecking for directories... \E[0m"
rm -rf /tmp/Slack_*
rm -rf $chrootdir
# Check available space on hard disk
echo -ne "\E[34m>\E[0m Checking \E[1mChecking for space... \E[0m"
CHECK=$(space_check)
if [ $CHECK = 0 -o $CHECK = 2 ]; then
cd /tmp/$SLACKDIR/
echo
echo -e "\E[34m>\E[0m \E[1m$DISTRO Linux $version Setup\E[0m"
echo
echo " Choose installation type"
cd /tmp/Slack_$version/kdei
echo
echo -e "\E[34m>\E[0m KDE \E[1mKDE SC and KOffice localization\E[0m"
echo
echo " if you selected Full mode installation you can choose"
if [ $main_ver != current ]; then
echo
echo -e "\E[34m>\E[0m Security \E[1mSecurity patches for $DISTRO $version\E[0m"
echo
echo " This step provide to install security patches automatically."
# Copy host name and host partition table
echo -ne "\E[34m>\E[0m Configuring \E[1mConfiguring $DISTRO... \E[0m"
cp -a $HOSTFILE $chrootdir/etc/hosts
cp -a $FSTABFILE $chrootdir/etc/fstab
# Remove packages
echo -ne "\E[34m>\E[0m Cleaning \E[1mCleaning Cache... \E[0m"
cd /tmp
rm -r /tmp/$SLACKDIR
# End script
echo
echo -e "\E[1;32mFinish!!!\E[0;0m"
echo
echo -e "\E[36m+----------------------------------+\E[0m"
echo "#####################################################"
echo " If you want to start this chroot environment:"
echo -e " \E[1m mount -o bind /proc $chrootdir/proc\E[0m"echo -e " \E[1m mount -o bind /dev $chrootdir/dev\E[0m"echo -e " \E[1m chroot $chrootdir /bin/bash\E[0m"
echo
echo " If you want have more info about chroot, read:"
echo -e " \E[1m man chroot\E[0m"
echo "#####################################################"
</pre>
45
contributi