# HG changeset patch # User Pascal Bellard # Date 1240430246 -7200 # Node ID 965cc9d8722a141c69247b1f5890f9e3ee0325de # Parent 1392ada2e985bf8366719b3e229057d0ac2719de move mount-packages from rcS to bootopts.sh diff -r 1392ada2e985 -r 965cc9d8722a etc/init.d/bootopts.sh --- a/etc/init.d/bootopts.sh Tue Apr 21 11:01:37 2009 +0200 +++ b/etc/init.d/bootopts.sh Wed Apr 22 21:57:26 2009 +0200 @@ -207,3 +207,17 @@ if grep -q "mount" /proc/cmdline; then mount_partitions fi + +# Mount and install packages-XXX.iso (usefull without Internet connection) +if grep -q " mount-packages" /proc/cmdline; then + PKGSIGN="LABEL=\"packages-$(cat /etc/slitaz-release)\" TYPE=\"iso9660\"" + PKGDEV=$(blkid | grep "$PKGSIGN" | cut -d: -f1) + [ -z "$PKGDEV" -a -L /dev/cdrom ] && PKGDEV=$(blkid /dev/cdrom | grep "$PKGSIGN" | cut -d: -f1) + if [ -n "$PKGDEV" ]; then + echo -n "Mounting packages archive from $PKGDEV..." + mkdir /packages && mount -t iso9660 -o ro $PKGDEV /packages + status + /packages/install.sh + fi +fi + diff -r 1392ada2e985 -r 965cc9d8722a etc/init.d/rcS --- a/etc/init.d/rcS Tue Apr 21 11:01:37 2009 +0200 +++ b/etc/init.d/rcS Wed Apr 22 21:57:26 2009 +0200 @@ -198,19 +198,6 @@ # Back to a verbose mode. echo "7 4 1 7" > /proc/sys/kernel/printk -# Mount and install packages-XXX.iso (usefull without Internet connection) -if grep -q " mount-packages" /proc/cmdline; then - PKGSIGN="LABEL=\"packages-$(cat /etc/slitaz-release)\" TYPE=\"iso9660\"" - PKGDEV=$(blkid | grep "$PKGSIGN" | cut -d: -f1) - [ -z "$PKGDEV" -a -L /dev/cdrom ] && PKGDEV=$(blkid /dev/cdrom | grep "$PKGSIGN" | cut -d: -f1) - if [ -n "$PKGDEV" ]; then - echo -n "Mounting packages archive from $PKGDEV..." - mkdir /packages && mount -t iso9660 -o ro $PKGDEV /packages - status - /packages/install.sh - fi -fi - # Reset screen and display a bold message. if [ -n "$MESSAGE" ]; then /usr/bin/reset