It can be hacked by moving /usr/bin/qemu to /usr/bin/qemu-original and inserting this script as /usr/bin/qemu (remember permissions):
#!/usr/bin/env python
#
# Wrapper for /usr/bin/qemu to forcefully enable kqemu support
#
# Morten Siebuhr
# <sbhr sbhr dk>
from sys import argv
from os import system, execv
from os.path import exists
original_file = "/usr/bin/qemu-original"
if not exists('/dev/kqemu'):
print "Cannot run kqemu - the device does not exist!"
else:
if '-no-kqemu' in argv: argv[argv.index('-no-kqemu')] = '-kernel-kqemu'
It can be hacked by moving /usr/bin/qemu to /usr/bin/ qemu-original and inserting this script as /usr/bin/qemu (remember permissions):
#!/usr/bin/env python
#
# Wrapper for /usr/bin/qemu to forcefully enable kqemu support
#
# Morten Siebuhr
# <sbhr sbhr dk>
from sys import argv
from os import system, execv
from os.path import exists
original_file = "/usr/bin/ qemu-original"
if not exists( '/dev/kqemu' ):
argv[argv. index(' -no-kqemu' )] = '-kernel-kqemu'
print "Cannot run kqemu - the device does not exist!"
else:
if '-no-kqemu' in argv:
execv(original_ file, argv)