#!/bin/sh
# This script is intended to be used when booted to Slax 5 to create a Slax6 root
# so syscfg and the rest of the PDK can be run while booted to Slax5.
# Use this script whenever Slax6 fails to boot as it currently does on the S5500.
mkdir /slax6
./lzm2dir ../base/001-core.lzm /slax6
./lzm2dir ../modules/python-2.5.2-i486-1.lzm /slax6
cp -r ../rootcopy/* /slax6
find /dev -print | cpio -pmudv /slax6 >/dev/null 2>&1
cp /etc/fstab /slax6/etc
cp initpdk /slax6
echo "run 'initpdk' found in the root directory"
chroot /slax6
# do the remainder of this script in the chroot shell
umount /slax6/proc
