diff options
author | Chris Larson <clarson@kergoth.com> | 2004-11-09 00:36:47 +0000 |
---|---|---|
committer | Chris Larson <clarson@kergoth.com> | 2004-11-09 00:36:47 +0000 |
commit | f96441b9faf769c9ecdd4d338b605ea3d0cc4010 (patch) | |
tree | edb17ec2c4ea13c5acb1c7350957a249a820e28d /nslu2-binary-only | |
parent | b6588aa6851fb220cedc387d21c51513ef8d67f4 (diff) |
Disable bk EOLN_NATIVE conversions on all files in packages FILESPATHs, to prevent it screwing up patches.
BKrev: 4190111fA4MuVozAqwE7xOSL9fr-TA
Diffstat (limited to 'nslu2-binary-only')
-rw-r--r-- | nslu2-binary-only/nslu2-unslung-ramdisk/able/linuxrc | 47 | ||||
-rw-r--r-- | nslu2-binary-only/nslu2-unslung-ramdisk/flashfs | 53 | ||||
-rw-r--r-- | nslu2-binary-only/nslu2-unslung-ramdisk/linuxrc | 46 | ||||
-rw-r--r-- | nslu2-binary-only/nslu2-unslung-ramdisk/rc.unslung | 27 |
4 files changed, 173 insertions, 0 deletions
diff --git a/nslu2-binary-only/nslu2-unslung-ramdisk/able/linuxrc b/nslu2-binary-only/nslu2-unslung-ramdisk/able/linuxrc index e69de29bb2..4b364b2032 100644 --- a/nslu2-binary-only/nslu2-unslung-ramdisk/able/linuxrc +++ b/nslu2-binary-only/nslu2-unslung-ramdisk/able/linuxrc @@ -0,0 +1,47 @@ +#!/bin/sh + +echo "Firmware Version: `cat /.unslung`" + +mounted= + +/bin/mount -t proc proc /proc +/bin/mount -t usbdevfs usbdevfs /proc/bus/usb +echo "0x0100" > /proc/sys/kernel/real-root-dev + +/bin/sleep 10 + +if [ -z "$mounted" ] && /bin/mount -rt ext3 /dev/sda2 /mnt/tmpmnt ; then + + if [ -x /mnt/tmpmnt/bin/init ] && + [ -d /mnt/tmpmnt/unslung ] && [ -r /mnt/tmpmnt/.unslung ] && + [ "`cat /.unslung`" = "`cat /mnt/tmpmnt/.unslung`" ] ; then + echo "Root filesystem will be mounted from /dev/sda2 ..." + mounted=/mnt/tmpmnt + echo "0x0802" > /proc/sys/kernel/real-root-dev + [ -r $mounted/unslung/rc.linuxrc ] && . $mounted/unslung/rc.linuxrc + fi + + /bin/umount /mnt/tmpmnt +fi + +if [ -z "$mounted" ] && /bin/mount -rt ext3 /dev/sdb2 /mnt/tmpmnt ; then + + if [ -x /mnt/tmpmnt/bin/init ] && + [ -d /mnt/tmpmnt/unslung ] && [ -r /mnt/tmpmnt/.unslung ] && + [ "`cat /.unslung`" = "`cat /mnt/tmpmnt/.unslung`" ] ; then + echo "Root filesystem will be mounted from /dev/sdb2 ..." + mounted=/mnt/tmpmnt + echo "0x0812" > /proc/sys/kernel/real-root-dev + [ -r $mounted/unslung/rc.linuxrc ] && . $mounted/unslung/rc.linuxrc + fi + + /bin/umount /mnt/tmpmnt +fi + +if [ -z "$mounted" ] ; then + echo "Root filesystem will be mounted from /dev/ram0 ..." +fi + +/bin/umount /proc + +exit 0 diff --git a/nslu2-binary-only/nslu2-unslung-ramdisk/flashfs b/nslu2-binary-only/nslu2-unslung-ramdisk/flashfs index e69de29bb2..c5d63c8e0e 100644 --- a/nslu2-binary-only/nslu2-unslung-ramdisk/flashfs +++ b/nslu2-binary-only/nslu2-unslung-ramdisk/flashfs @@ -0,0 +1,53 @@ +#!/bin/sh +# +# Copyright (C) 2004 by Oleg I. Vdovikin <oleg@cs.msu.su> +# Modified for Unslung by Rod Whitby +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# + +VERSION="$(cat /.unslung)" +FLASHFS=/share/flash/data/flashfs.tar.gz + +case "$1" in + status) + echo "$VERSION" + ;; + start) + if [ -f ${FLASHFS} ]; then + tar -C / -zxf ${FLASHFS} + fi + ;; + clear) + rm -f ${FLASHFS} + ;; + load) + tar -C / -zxvf ${FLASHFS} + ;; + list) + tar -C / -ztf ${FLASHFS} + ;; + save) + [ -f /unslung/.files ] && FILES=$(cat /unslung/.files) + rm -f /tmp/flash.tar.gz + tar -C / -zcvf /tmp/flash.tar.gz /unslung $FILES && + cp /tmp/flash.tar.gz ${FLASHFS} && + ls -l ${FLASHFS} && + echo "Saved." + ;; + *) + echo "Usage: $0 status|clear|load|list|save" + ;; +esac diff --git a/nslu2-binary-only/nslu2-unslung-ramdisk/linuxrc b/nslu2-binary-only/nslu2-unslung-ramdisk/linuxrc index e69de29bb2..d80b748f08 100644 --- a/nslu2-binary-only/nslu2-unslung-ramdisk/linuxrc +++ b/nslu2-binary-only/nslu2-unslung-ramdisk/linuxrc @@ -0,0 +1,46 @@ +#!/bin/sh + +echo "Firmware Version: `cat /.unslung`" + +mounted= + +/bin/mount -t proc proc /proc +echo "0x0100" > /proc/sys/kernel/real-root-dev + +/bin/sleep 10 + +if [ -z "$mounted" ] && /bin/mount -rt ext3 /dev/sda2 /mnt/tmpmnt ; then + + if [ -x /mnt/tmpmnt/bin/init ] && + [ -d /mnt/tmpmnt/unslung ] && [ -r /mnt/tmpmnt/.unslung ] && + [ "`cat /.unslung`" = "`cat /mnt/tmpmnt/.unslung`" ] ; then + echo "Root filesystem will be mounted from /dev/sda2 ..." + mounted=/mnt/tmpmnt + echo "0x0802" > /proc/sys/kernel/real-root-dev + [ -r $mounted/unslung/rc.linuxrc ] && . $mounted/unslung/rc.linuxrc + fi + + /bin/umount /mnt/tmpmnt +fi + +if [ -z "$mounted" ] && /bin/mount -rt ext3 /dev/sdb2 /mnt/tmpmnt ; then + + if [ -x /mnt/tmpmnt/bin/init ] && + [ -d /mnt/tmpmnt/unslung ] && [ -r /mnt/tmpmnt/.unslung ] && + [ "`cat /.unslung`" = "`cat /mnt/tmpmnt/.unslung`" ] ; then + echo "Root filesystem will be mounted from /dev/sdb2 ..." + mounted=/mnt/tmpmnt + echo "0x0812" > /proc/sys/kernel/real-root-dev + [ -r $mounted/unslung/rc.linuxrc ] && . $mounted/unslung/rc.linuxrc + fi + + /bin/umount /mnt/tmpmnt +fi + +if [ -z "$mounted" ] ; then + echo "Root filesystem will be mounted from /dev/ram0 ..." +fi + +/bin/umount /proc + +exit 0 diff --git a/nslu2-binary-only/nslu2-unslung-ramdisk/rc.unslung b/nslu2-binary-only/nslu2-unslung-ramdisk/rc.unslung index e69de29bb2..86bfdf0029 100644 --- a/nslu2-binary-only/nslu2-unslung-ramdisk/rc.unslung +++ b/nslu2-binary-only/nslu2-unslung-ramdisk/rc.unslung @@ -0,0 +1,27 @@ +#!/bin/sh + +if ( [ -f /unslung/rc.unslung ] && . /unslung/rc.unslung ) ; then return 0 ; fi + +# Start all init scripts in /opt/etc/init.d +# executing them in numerical order. +# +for i in /opt/etc/init.d/S??* ;do + + # Ignore dangling symlinks (if any). + [ ! -f "$i" ] && continue + + case "$i" in + *.sh) + # Source shell script for speed. + ( + trap - INT QUIT TSTP + set start + . $i + ) + ;; + *) + # No sh extension, so fork subprocess. + $i start + ;; + esac +done |