From: John Hodge Date: Sun, 21 Aug 2011 08:50:34 +0000 (+0800) Subject: Just some useful scripts X-Git-Tag: rel0.11~136 X-Git-Url: https://git.ucc.asn.au/?a=commitdiff_plain;h=cbad8d25ce1ad97678fb444668dc46974c872c58;p=tpg%2Facess2.git Just some useful scripts --- diff --git a/CleanAllArch b/CleanAllArch new file mode 100755 index 00000000..5ccf8119 --- /dev/null +++ b/CleanAllArch @@ -0,0 +1,2 @@ +#!/bin/sh +for a in i386 i486 i586 x86_64 arm host; do echo $a; ARCH=$a make clean; done diff --git a/EditBoot b/EditBoot new file mode 100755 index 00000000..ba547346 --- /dev/null +++ b/EditBoot @@ -0,0 +1,9 @@ +#!/bin/sh +#./MountDisk +#vim mnt/boot/menu.lst +#sudo umount mnt/ +DISK=a +mcopy $DISK:/boot/menu.lst .menu.lst.tmp +vim .menu.lst.tmp +mcopy -D o .menu.lst.tmp $DISK:/boot/menu.lst +rm .menu.lst.tmp diff --git a/RunQemu b/RunQemu new file mode 100755 index 00000000..bb94daf6 --- /dev/null +++ b/RunQemu @@ -0,0 +1,38 @@ +#!/bin/sh +#qemu-system-x86_64 -fda DiskImage.img -boot a -serial stdio -net user,hostname=prelude,dns=10.0.2.1 -net nic,model=ne2k_pci -vga std + +QEMU=qemu-system-x86_64 +USE_GDB= + +QEMU_PARAMS="-fda DiskImage.img -boot a" +QEMU_PARAMS=$QEMU_PARAMS" -hdb AcessHDD.img" +QEMU_PARAMS=$QEMU_PARAMS" -vga std" +QEMU_PARAMS=$QEMU_PARAMS" -smp 2" +QEMU_PARAMS=$QEMU_PARAMS" -net nic" +_NETTYPE="user" + +while [ $# -ne 0 ]; do + case $1 in + -gdb) + QEMU_PARAMS=$QEMU_PARAMS" -s -S" + ;; + -dbgbin) + QEMU=/home/tpg/apps/bin/qemu-system-x86_64 + ;; + -extramem) + QEMU_PARAMS=$QEMU_PARAMS" -m 768" + ;; + -e) + shift + QEMU_PARAMS=$QEMU_PARAMS" "$1 + ;; + -tuntap) + _NETTYPE="tap" + esac + shift +done +QEMU_PARAMS=$QEMU_PARAMS" -net "$_NETTYPE + +# /home/tpg/apps/bin/qemu-system-x86_64 $QEMU_PARAMS -serial stdio -serial file:QemuLog.txt +# qemu-system-x86_64 $QEMU_PARAMS -serial stdio | tee QemuLog.txt +$QEMU $QEMU_PARAMS -serial stdio | tee QemuLog.txt