Linux下应用程序加载前是不是要有一段程序来做准备:
#! /bin/sh
#set -x
echo "eLinuxBSP RootDisk ver 0.3.6"
# Mount the /proc file system
mount -t proc proc /proc
# turn on flushing of buffers etc
update
# Tell the world things from /proc
echo > /proc/cpuinfo
# make some writable bits of filesystem
echo "Creating writable /tmp"
mount -t tmpfs -o size=32m none /tmp
#For PCMCIA support
mount -t tmpfs -o size=1m none /var
/bin/mkdir /var/lib
/bin/mkdir /var/run
/bin/mkdir /var/lib/pcmcia
/bin/mkdir /tmp/dev
# display the big penguin to cover the small one
lcdhcoff
cp /bitmap/penguin.bin /dev/fbdir/0
ln -s /dev/fbdir/0 /dev/fb
ln -s /dev/fbdir/0 /dev/fb0
# as we are using inverted mode, we better clear the screen first
# before that, we need to issue a dummy ls command
ls /
clear
# mount flash disk
mount /dev/fdisk /mnt/fdisk
if mount | grep /mnt/fdisk > /dev/null; then
if test -z `ls /mnt/fdisk/autorun 2> /dev/null | sed 's/ //'`; then
echo "No autorun script found in FLASH disk"
else
echo "Start autorun script in FLASH disk in 2 seconds,"
echo "press CTRL-C to abort ...."
sleep 2
sh /mnt/fdisk/autorun
fi
else
echo "Cannot mount FLASH disk"
fi
ls/
clear
deamon
# start up the logins (on serial ports)
# finished
echo "/etc/init.d/rcS done."
加载你的应用程序
# Fall through to a shell prompt
exit 0
麻烦告知我这段程序的具体含义,多谢。本人是菜鸟的说。 :-)