Ubuntu Pastebin

Paste from smoser at Thu, 12 Feb 2015 18:25:09 +0000

Download as text
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
#!/bin/sh
set -f

getcpu() {
   CPU="unknown"
   [ -r /proc/cpuinfo ] || return
   local line
   while read line; do
      set -- $line
      [ "$1" = "cpu" ] && CPU="$3" && return 0;
   done < /proc/cpuinfo
   return
}

getcpu
case "$CPU" in
  e500*|e6500*) qemu=qemu-system-ppcemb;;
  POWER*) qemu=qemu-system-ppc64;;
  *) qemu=qemu-system-ppc;
esac
exec "$qemu" -enable-kvm "$@"
Download as text