From owner-freebsd-ports@FreeBSD.ORG Thu Feb 28 21:20:54 2008 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id ADD3D1065673 for ; Thu, 28 Feb 2008 21:20:54 +0000 (UTC) (envelope-from edwin@mavetju.org) Received: from mail5out.barnet.com.au (mail5.barnet.com.au [202.83.178.78]) by mx1.freebsd.org (Postfix) with ESMTP id 0F0CB8FC19 for ; Thu, 28 Feb 2008 21:20:54 +0000 (UTC) (envelope-from edwin@mavetju.org) Received: by mail5out.barnet.com.au (Postfix, from userid 1001) id 6A25A2218A6C; Fri, 29 Feb 2008 08:20:52 +1100 (EST) X-Viruscan-Id: <47C725B40000B0B884DA74@BarNet> Received: from mail5auth.barnet.com.au (mail5.barnet.com.au [202.83.178.78]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "mail5auth.barnet.com.au", Issuer "*.barnet.com.au" (verified OK)) by mail5.barnet.com.au (Postfix) with ESMTP id 124A421B1F63; Fri, 29 Feb 2008 08:20:52 +1100 (EST) Received: from k7.mavetju (k7.mavetju.org [10.251.1.18]) by mail5auth.barnet.com.au (Postfix) with ESMTP id 7FF182218A64; Fri, 29 Feb 2008 08:20:51 +1100 (EST) Received: by k7.mavetju (Postfix, from userid 1001) id 37EAEC4; Fri, 29 Feb 2008 08:20:51 +1100 (EST) Date: Fri, 29 Feb 2008 08:20:51 +1100 From: Edwin Groothuis To: Miroslav Lachman <000.fbsd@quip.cz>, freebsd-ports-mailinglist Message-ID: <20080228212051.GA2962@k7.mavetju> References: <3131aa530802260145y48e37284j4b03e6cd1f933027@mail.gmail.com> <47C412E4.9020305@quip.cz> <20080228134436.GA2759@k7.mavetju> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="5vNYLRcllDrimb99" Content-Disposition: inline In-Reply-To: <20080228134436.GA2759@k7.mavetju> User-Agent: Mutt/1.4.2.3i Cc: Subject: Re: VirtualBox looks for FreeBSD developer X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Feb 2008 21:20:54 -0000 --5vNYLRcllDrimb99 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Fri, Feb 29, 2008 at 12:44:36AM +1100, Edwin Groothuis wrote: > On Tue, Feb 26, 2008 at 02:23:48PM +0100, Miroslav Lachman wrote: > > Olivier Cochard-Labbe wrote: > > >Hi all, > > >In a post concerning ?porting VirtualBox on FreeBSD?, an Innotek developer > > >answer that they start to port it, but ?hope some developers from the > > >FreeBSD community will pick up where we left off and complete the port?. > > >Original post here: http://forums.virtualbox.org/viewtopic.php?t=3234 > > > > > >Are there any developers motivated here ? > > > > I am not a developer, but it would be nice to have VirtualBox on FreeBSD > > (I am using it on Windows to run FreeBSD guests :]) > > > > I am available for testing etc. > > Patches to get it working against the current SVN version. > > Problem lies with the kernel driver. But that's an issue for other > people to worry about later. New patches, which actually make it compile this time :-) This works: [~svn/vbox/out/freebsd.x86/release] edwin@k7>export LD_LIBRARY_PATH=`pwd`/bin:`pwd`/lib [~svn/vbox/out/freebsd.x86/release] edwin@k7>cd bin [~svn/vbox/out/freebsd.x86/release/bin] edwin@k7>kldload vboxdrv.ko [~svn/vbox/out/freebsd.x86/release/bin] edwin@k7>cd .. [~svn/vbox/out/freebsd.x86/release] edwin@k7>bin/VirtualBox But it still complains about the kernel driver: VM creation failed (GVMM). VBox status code: -37 (VERR_NOT_SUPPORTED). And panics while unloading... I will continue on my test box (a multitude slower than my desktop but at least I don't lose all my $realjob work when it panics) Edwin -- Edwin Groothuis | Personal website: http://www.mavetju.org edwin@mavetju.org | Weblog: http://www.mavetju.org/weblog/ --5vNYLRcllDrimb99 Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=a Index: configure =================================================================== --- configure (revision 7199) +++ configure (working copy) @@ -60,9 +60,9 @@ LIBXCURSOR="-lXcursor" INCZ="" LIBZ="-lz" -INCPNG="" -LIBPNG="-lpng" -QTDIR="/usr/qt/3 /usr/lib/qt3 /usr/lib/qt-3.3 /usr/share/qt3 /usr/lib64/qt-3.3 /usr/X11R6 /usr/lib/qt" +INCPNG="-I/usr/local/include" +LIBPNG="-L/usr/local/lib -lpng" +QTDIR="/usr/local/ /usr/lib/qt3 /usr/lib/qt-3.3 /usr/share/qt3 /usr/lib64/qt-3.3 /usr/X11R6 /usr/lib/qt" KBUILDDIR="`cd \`dirname $0\`; pwd`/kBuild" DEVDIR="`cd \`dirname $0\`; pwd`/tools" if [ -d "/lib/modules/`uname -r`/build" ]; then @@ -573,6 +573,7 @@ if test_execute; then cnf_append "SDK_VBOX_LIBXML2_INCS" "$INCXML2" cnf_append "SDK_VBOX_LIBXML2_LIBS" "`strip_l "$LIBXML2"`" + cnf_append "SDK_VBOX_LIBXML2_LIBPATH" "`strip_L "$LIBXML2"`" fi fi fi Index: Config.kmk =================================================================== --- Config.kmk (revision 7199) +++ Config.kmk (working copy) @@ -345,14 +345,19 @@ endif ifeq ($(BUILD_TARGET),freebsd) - VBOX_WITH_INSTALLER= VBOX_WITH_SECURELABEL= VBOX_WITH_VRDP_AUTHMOD= VBOX_WITH_VRDP_RDESKTOP= VBOX_WITH_TESTSUITE= + VBOX_WITH_EHCI= + + VBOX_WITH_INSTALLER= VBOX_WITH_USB= - VBOX_WITH_EHCI= VBOX_WITH_DOCS= +#VBOX_WITH_INSTALLER= +#VBOX_WITH_USB= +#VBOX_WITH_DOCS= +# XXX Mavvie endif Index: src/VBox/VMM/VMMR0/HWACCMR0A.asm =================================================================== --- src/VBox/VMM/VMMR0/HWACCMR0A.asm (revision 7199) +++ src/VBox/VMM/VMMR0/HWACCMR0A.asm (working copy) @@ -24,6 +24,22 @@ %include "VBox/cpum.mac" %include "VBox/x86.mac" +%ifdef RT_OS_FREEBSD ;; @todo fix OMF support in yasm and kick nasm out completely. + %macro vmwrite 2, + int3 + %endmacro + %define vmlaunch int3 + %define vmresume int3 + %define vmsave int3 + %define vmload int3 + %define vmrun int3 + %define clgi int3 + %define stgi int3 + %macro invlpga 2, + int3 + %endmacro +%endif + %ifdef RT_OS_OS2 ;; @todo fix OMF support in yasm and kick nasm out completely. %macro vmwrite 2, int3 Index: src/VBox/Main/ConsoleImpl.cpp =================================================================== --- src/VBox/Main/ConsoleImpl.cpp (revision 7199) +++ src/VBox/Main/ConsoleImpl.cpp (working copy) @@ -18,15 +18,21 @@ #include /* for stdint.h constants */ #if defined(RT_OS_WINDOWS) -#elif defined(RT_OS_LINUX) +#elif defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD) # include # include # include # include # include # include +#if defined(RT_OS_FREEBSD) +# include +# include +#endif # include +#if defined(RT_OS_LINUX) # include +#endif # include # include # include --5vNYLRcllDrimb99--