From owner-freebsd-emulation@FreeBSD.ORG Mon Jun 15 21:07:41 2009 Return-Path: Delivered-To: freebsd-emulation@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6E585106587E; Mon, 15 Jun 2009 21:07:39 +0000 (UTC) (envelope-from nox@jelal.kn-bremen.de) Received: from smtp.kn-bremen.de (gelbbaer.kn-bremen.de [78.46.108.116]) by mx1.freebsd.org (Postfix) with ESMTP id 929EE8FC1B; Mon, 15 Jun 2009 21:07:34 +0000 (UTC) (envelope-from nox@jelal.kn-bremen.de) Received: by smtp.kn-bremen.de (Postfix, from userid 10) id 1DF281E001E4; Mon, 15 Jun 2009 23:07:33 +0200 (CEST) Received: from triton.kn-bremen.de (noident@localhost [127.0.0.1]) by triton.kn-bremen.de (8.14.3/8.14.3) with ESMTP id n5FKohqn002335; Mon, 15 Jun 2009 22:50:43 +0200 (CEST) (envelope-from nox@triton.kn-bremen.de) Received: (from nox@localhost) by triton.kn-bremen.de (8.14.3/8.14.3/Submit) id n5FKohEC002334; Mon, 15 Jun 2009 22:50:43 +0200 (CEST) (envelope-from nox) From: Juergen Lock Date: Mon, 15 Jun 2009 22:50:43 +0200 To: miwi@FreeBSD.org Message-ID: <20090615205043.GA65621@triton.kn-bremen.de> References: <20090611194557.GC98175@bsdcrew.de> <200906112107.n5BL7Smh005706@triton.kn-bremen.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200906112107.n5BL7Smh005706@triton.kn-bremen.de> User-Agent: Mutt/1.5.19 (2009-01-05) Cc: freebsd-emulation@FreeBSD.org Subject: first in-tree vbox port patch :) (was: Re: [Call For Testing] VirtualBox for FreeBSD! take 6) 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, 15 Jun 2009 21:07:45 -0000 On Thu, Jun 11, 2009 at 11:07:28PM +0200, Juergen Lock wrote: > In article <20090611194557.GC98175@bsdcrew.de> you write: > >-----BEGIN PGP SIGNED MESSAGE----- > >Hash: SHA1 > > > >Huhu, > > > >Yes we life and that's good :-). > >Changes: > > > > - Fix build error when compiling in debug mode on FreeBSD HEAD > > - SemEvent?-r0drv/FreeBSD: Don't use tvtohz for an infinite timeout. > > - Some FreeBSD relate typos > > - Enable shared OpenGL service. Completely untested due to lack of > > appropriate hardware but it compiles at least > > I don't have working gl here either (ati RV730 PRO with xf86-video-ati), > but this caused the gui failing to start, ktrace'ing revealed it was > looking for /usr/local/lib/virtualbox/VBoxTestOGL which doesn't exist: > > [...] > 1184 VBoxSVC CALL _umtx_op(0x802711160,0x8,0,0x802711140,0x7fffffb3bdb0) > 1184 VBoxSVC CALL access(0x7340c0,X_OK) > 1184 VBoxSVC NAMI "/usr/local/lib/virtualbox/VBoxTestOGL" > 1184 VBoxSVC RET access -1 errno 2 No such file or directory > 1184 VBoxSVC CALL write(0x9,0x802414000,0xfc) > 1184 VBoxSVC GIO fd 9 wrote 252 bytes > " > !!Assertion Failed!! > Expression: > Location : /usr/home/nox/vbox/virtualbox/work/virtualbox-2.2.51r20457\ > /src/VBox/Runtime/r3/posix/process-posix.cpp(86) int RTProcCreate(cons\ > t char*, const char* const*, RTENVINTERNAL*, unsigned int, RTPROCESS*) > " > 1184 VBoxSVC RET write 252/0xfc > 1184 VBoxSVC CALL write(0x2,0x7fffffbdbeb0,0xfc) > 1184 VBoxSVC GIO fd 2 wrote 252 bytes > " > !!Assertion Failed!! > Expression: > Location : /usr/home/nox/vbox/virtualbox/work/virtualbox-2.2.51r20457\ > /src/VBox/Runtime/r3/posix/process-posix.cpp(86) int RTProcCreate(cons\ > t char*, const char* const*, RTENVINTERNAL*, unsigned int, RTPROCESS*) > " > 1184 VBoxSVC RET write 252/0xfc > 1184 VBoxSVC CALL write(0x9,0x802414000,0x3d) > 1184 VBoxSVC GIO fd 9 wrote 61 bytes > "'/usr/local/lib/virtualbox/VBoxTestOGL' VERR_FILE_NOT_FOUND! > " > 1184 VBoxSVC RET write 61/0x3d > 1184 VBoxSVC CALL write(0x2,0x7fffffbdc210,0x3d) > 1184 VBoxSVC GIO fd 2 wrote 61 bytes > "'/usr/local/lib/virtualbox/VBoxTestOGL' VERR_FILE_NOT_FOUND! > " > 1184 VBoxSVC RET write 61/0x3d > 1184 VBoxSVC PSIG SIGTRAP caught handler=0x547990 mask=0x2000 code=0x1 > [...] > > Disabling VBOX_WITH_CROGL in Config.kmk got me a working install then, > patch below. >[...] Ok I now have a better solution for this: 1. Actually install VBoxTestOGL (it was built, just not installed...) 2. fix libGL.so.1 search so it isn't expected in / and, unrelated: 3. fix packaging for vboxdrv.ko Patch against the new emulators/virtualbox port: Index: Makefile =================================================================== RCS file: /home/pcvs/ports/emulators/virtualbox/Makefile,v retrieving revision 1.1 diff -u -p -r1.1 Makefile --- Makefile 15 Jun 2009 18:01:41 -0000 1.1 +++ Makefile 15 Jun 2009 20:24:46 -0000 @@ -61,7 +61,7 @@ OPTIONS= QT4 "Build with QT4 Frontend" o .include KMODDIR= /boot/modules -PLIST_SUB+= KMODDIR=${KMODDIR} +PLIST_SUB+= KMODDIR=${KMODDIR:C,^/,,} KMK_BUILDTYPE= release KMK_CONFIG= VBOX_LIBPATH_X11=${LOCALBASE} VBOX_FREEBSD_SRC=${SRC_BASE}/sys KMK_FLAGS= @@ -157,7 +157,7 @@ do-install: (cd ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin && ${COPYTREE_SHARE} "*.so *.gc *.r0 components" ${PREFIX}/lib/virtualbox) ${MKDIR} ${PREFIX}/bin -.for f in VBoxManage VBoxNetDHCP VBoxSVC VBoxXPCOMIPCD ${VBOX_FRONTENDS} +.for f in VBoxManage VBoxNetDHCP VBoxSVC VBoxXPCOMIPCD ${VBOX_FRONTENDS} VBoxTestOGL ${INSTALL_PROGRAM} ${WRKSRC}/out/${KMK_ARCH}/${KMK_BUILDTYPE}/bin/$f ${PREFIX}/lib/virtualbox/ ${LN} -sf ${PREFIX}/lib/virtualbox/${f} ${PREFIX}/bin/ .endfor Index: pkg-plist =================================================================== RCS file: /home/pcvs/ports/emulators/virtualbox/pkg-plist,v retrieving revision 1.1 diff -u -p -r1.1 pkg-plist --- pkg-plist 15 Jun 2009 18:01:41 -0000 1.1 +++ pkg-plist 15 Jun 2009 20:24:46 -0000 @@ -23,6 +23,7 @@ lib/virtualbox/VBoxOGLhosterrorspu.so lib/virtualbox/VBoxOGLrenderspu.so lib/virtualbox/VBoxPython.so lib/virtualbox/VBoxREM.so +lib/virtualbox/VBoxTestOGL %%I386%%lib/virtualbox/VBoxREM32.so %%I386%%lib/virtualbox/VBoxREM64.so lib/virtualbox/VBoxRT.so Index: files/patch-glloader.py @@ -0,0 +1,10 @@ +Index: src/VBox/GuestHost/OpenGL/spu_loader/glloader.py +@@ -149,7 +149,7 @@ + }*/ + #endif + } +-#if !defined(__linux__) && !defined(SunOS) ++#if !defined(__linux__) && !defined(SunOS) && !defined(__FreeBSD__) + crStrcat( system_path, "/" ); + #endif + crStrcat( system_path, lib );