From owner-freebsd-emulation@FreeBSD.ORG Mon Jul 19 16:32:06 2010 Return-Path: Delivered-To: freebsd-emulation@freebsd.org Received: from hub.freebsd.org (localhost [127.0.0.1]) by hub.freebsd.org (Postfix) with SMTP id A122A106566B; Mon, 19 Jul 2010 16:32:05 +0000 (UTC) (envelope-from nork@FreeBSD.org) Date: Tue, 20 Jul 2010 01:31:59 +0900 From: Norikatsu Shigemura To: Juergen Lock Message-Id: <20100720013159.84a3cb86.nork@FreeBSD.org> X-Mailer: Sylpheed 3.0.3 (GTK+ 2.20.1; i386-portbld-freebsd8.1) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-emulation@freebsd.org, nork@FreeBSD.org Subject: [ports/emulators/qemu-devel] Fix BSD User space emulator issue X-BeenThere: freebsd-emulation@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Development of Emulators of other operating systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Jul 2010 16:32:06 -0000 Hi nox. I found a minor issue on qemu-devel. We can't use BSD User space emulator by default. Because default bsd-type is OpenBSD:-(. In this time, we run always qemu-* with -bsd freebsd option, like qemu-x86_64 -bsd freebsd /bin/ls. But following patch fix default behavior. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - --- bsd-user/main.c.orig 2010-05-05 00:27:48.000000000 +0900 +++ bsd-user/main.c 2010-07-19 00:49:30.020088803 +0900 @@ -740,7 +740,7 @@ int gdbstub_port = 0; char **target_environ, **wrk; envlist_t *envlist = NULL; - bsd_type = target_openbsd; + bsd_type = target_freebsd; if (argc <= 1) usage(); - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - BTW, do you have any idea to support ARM? And, JFYI, I tried to test sparc64, i386, x86_64 on FreeBSD/amd64. But I confirmed that x86_64 is only OK like following: $ qemu-x86_64 -bsd freebsd /rescue/ls -lF / -r--r--r-- 1 root wheel 6196 Jan 3 2010 COPYRIGHT drwxr-xr-x 2 root wheel 47 Jul 18 01:49 bin/ drwxr-xr-x 9 root wheel 36 Jul 18 01:49 boot/ : $ make world TARGET_ARCH=sparc64 DESTDIR=/tmp/sparc64 $ qemu-sparc64 -bsd freebsd -L /tmp/sparc64 /tmp/sparc64/rescue/ls -lF / (in this case, qemu-sparc64 is cpu eater.) -- Norikatsu Shigemura