Port VB to FreeBSD

Here you can provide suggestions on how to improve the product, website, etc.

Port VB to FreeBSD

Postby snowfox » 5. Dec 2007, 17:15

I have built VB 1.5.1 OSE version on FreeBSD 6.2 AMD64(Except vboxdrv.ko and some 32-bits test cases). I found following problems:

1. When I run ./VBoxBFE -m 4
I get error "value is too big to fit variable", the reason is that when VBoxBFE trys to load VMMR0.ro, it fails to relocate some symbols with relocation type R_X86_64_32S. It seems that VBoxBFE has load VMMR0.ro to a too high 32-bits address(0xef423420)

2. When I changed VMMR0.r0 load address from 0xef423420 to 0x0f423420, I got following error:
Log created: 2007-12-04T03:18:53.963490000Z
Executable: /data/home/rshen/opensrc/vbox/out/freebsd.amd64/debug/bin/VBoxBFE
Arg[0]: ./VBoxBFE
Arg[1]: -m
Arg[2]: 4

!!Assertion Failed!!
Expression: <NULL>
Location : /data/home/rshen/opensrc/vbox/src/VBox/HostDrivers/Support/SUPLib.cpp(480) int supCallVMMR0ExFake(PVMR0, unsigned int, uint64_t, SUPVMMR0REQHDR*)

Thanks.
snowfox
 
Posts: 3
Joined: 5. Dec 2007, 16:47

Postby snowfox » 5. Dec 2007, 17:18

OS information:
pc13new% uname -a
FreeBSD pc13new.asia.corp.platform.com 6.2-RELEASE-p8 FreeBSD 6.2-RELEASE-p8 #3: Wed Nov 21 15:42:48 UTC 2007 root@pc13new.asia.corp.platform.com:/usr/obj/data/src/sys/pc13smp amd64

I also use some .h and libraries from FreeBSD 6.2 i386 to compile guest related binaries.
snowfox
 
Posts: 3
Joined: 5. Dec 2007, 16:47

VB on freebsd 6.2 amd64

Postby snowfox » 10. Dec 2007, 16:05

I have compared the source code of Linux and FreeBSD. In FreeBSD 6.2, there is no address overflow check but in Linux 2.6, there is address check which is similar with VirtualBox.
snowfox
 
Posts: 3
Joined: 5. Dec 2007, 16:47

Postby olivier » 20. Feb 2008, 11:08

I'm very interressed by running Virtualbox on my FreeBSD too.
Is possible to know the official position of Innotek about a FreeBSD port ?
olivier
 
Posts: 4
Joined: 25. Oct 2007, 15:25

Postby serkoon » 21. Feb 2008, 02:03

I'd be interested in a FreeBSD host port myself, too.

Some work on this port is apparantly being done, but perhaps Innotek could shed some light on this? I'm happy to put it to the test if/when there's a working FreeBSD port :)
serkoon
 
Posts: 1
Joined: 21. Feb 2008, 01:57

Postby sandervl » 21. Feb 2008, 11:38

Very basic porting work has been done on a voluntary basis by one of my colleagues. We actually hope some developers from the FreeBSD community will pick up where we left off and complete the port.

There is a developer's mailinglist and a special developer irc channel where we'd be happy to answer any questions. See http://virtualbox.org/wiki/Community
Sander van Leeuwen
Sun Microsystems, Inc.
sandervl
Sun Microsystems, Inc.
 
Posts: 882
Joined: 10. May 2007, 10:27
Primary OS: MS Windows Vista
VBox Version: PUEL
Guest OSses: Windows, Linux, Solaris

Postby olivier » 28. Feb 2008, 19:13

A patch have just been posted on the FreeBSD port mailing list :

"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.
Edwin Groothuis"
olivier
 
Posts: 4
Joined: 25. Oct 2007, 15:25

Postby olivier » 1. Mar 2008, 01:31

One of the FreeBSD developper complain about "the documentation about the kernel module as described on
http://www.virtualbox.org/wiki/Porting_VirtualBox
that are lacking a bit of essential information."

(Original post on the freebsd mailing list archive.)

Is possible to update this documentation page ?

Actual state: VB start on FreeBSD 6.3 (not FreeBSD 7.0 with ULE) but crash when the VM start.
olivier
 
Posts: 4
Joined: 25. Oct 2007, 15:25

Postby mgp » 3. Mar 2008, 21:15

Hi sandervl,
do you plan to complete and support the FreeBSD port or you've left it off forever?
If you read this thread you'll see that one of the FreeBSD committers is doing some work to port VB...however he seems to be blocked...maybe if you join forces you'll get there pretty easy.
I hope you'll do so...
mgp
 
Posts: 5
Joined: 3. Mar 2008, 20:40

Postby sandervl » 3. Mar 2008, 21:39

We're talking to and helping two people that want to work on the FreeBSD port on the vbox-dev irc channel.
Sander van Leeuwen
Sun Microsystems, Inc.
sandervl
Sun Microsystems, Inc.
 
Posts: 882
Joined: 10. May 2007, 10:27
Primary OS: MS Windows Vista
VBox Version: PUEL
Guest OSses: Windows, Linux, Solaris

Postby outpaddling » 10. May 2008, 22:07

I've started working on a FreeBSD port framework, which is available at my web site:

http://personalpages.tds.net/~jwbacon/Ports/

I hit a snag with kbuild that I could use some help with. The link command lacks whitespace after -L[snip]/src/VBox/Main/, which yields "-L[snip]/src/VBox/Main/-L/usr/local/lib". Hence, nothing in /usr/local/lib is found. I grep'ed every plain file in the tree for parts of the link command, and it's not in there. Apparently it's generated on the fly, but how is a mystery to me.

Any tips would be appreciated.

Thanks,

Jason

Tail of the build output:

kmk[3]: Entering directory `/usr/home/bacon/Prog/Ports/ports/emulators/virtualbox-devel/work/VirtualBox-1.6.0_OSE/src/VBox/Main'
kBuild: Linking VBoxSettings
/usr/bin/ld: cannot find -lxslt
kmk[3]: *** [/usr/home/bacon/Prog/Ports/ports/emulators/virtualbox-devel/work/VirtualBox-1.6.0_OSE/out/freebsd.x86/debug/obj/src/VBox/Main/VBoxSettings/VBoxSettings.so] Error 1
The failing command:
@g++ -shared -g -m32 -o /usr/home/bacon/Prog/Ports/ports/emulators/virtualbox-devel/work/VirtualBox-1.6.0_OSE/out/freebsd.x86/debug/obj/src/VBox/Main/VBoxSettings/VBoxSettings.so -Wl,-soname=VBoxSettings.so /usr/home/bacon/Prog/Ports/ports/emulators/virtualbox-devel/work/VirtualBox-1.6.0_OSE/out/freebsd.x86/debug/obj/src/VBox/Main/VBoxSettings/xml/Settings.o -L/usr/home/bacon/Prog/Ports/ports/emulators/virtualbox-devel/work/VirtualBox-1.6.0_OSE/src/VBox/Main/-L/usr/local/lib -L/usr/home/bacon/Prog/Ports/ports/emulators/virtualbox-devel/work/VirtualBox-1.6.0_OSE/src/VBox/Main/-lxml2 /usr/home/bacon/Prog/Ports/ports/emulators/virtualbox-devel/work/VirtualBox-1.6.0_OSE/out/freebsd.x86/debug/bin/VBoxRT.so /usr/home/bacon/Prog/Ports/ports/emulators/virtualbox-devel/work/VirtualBox-1.6.0_OSE/out/freebsd.x86/debug/lib/VBoxCOM.a /usr/home/bacon/Prog/Ports/ports/emulators/virtualbox-devel/work/VirtualBox-1.6.0_OSE/out/freebsd.x86/debug/bin/VBoxXPCOM.so -lxslt -lz -liconv -lm -lxml2 -lxml2 -lz
kmk[3]: Leaving directory `/usr/home/bacon/Prog/Ports/ports/emulators/virtualbox-devel/work/VirtualBox-1.6.0_OSE/src/VBox/Main'
kmk[2]: *** [pass_dlls_before] Error 2
kmk[2]: Leaving directory `/usr/home/bacon/Prog/Ports/ports/emulators/virtualbox-devel/work/VirtualBox-1.6.0_OSE/src/VBox'
kmk[1]: *** [pass_dlls_before] Error 2
kmk[1]: Leaving directory `/usr/home/bacon/Prog/Ports/ports/emulators/virtualbox-devel/work/VirtualBox-1.6.0_OSE/src'
kmk: *** [pass_dlls_before] Error 2
*** Error code 2

Stop in /usr/home/bacon/Prog/Ports/ports/emulators/virtualbox-devel.
outpaddling
 
Posts: 1
Joined: 10. May 2008, 00:20

Postby sandervl » 11. May 2008, 10:06

Please post this to the developer's mailinglist (see http://www.virtualbox.org/wiki/Mailing_lists).
Sander van Leeuwen
Sun Microsystems, Inc.
sandervl
Sun Microsystems, Inc.
 
Posts: 882
Joined: 10. May 2007, 10:27
Primary OS: MS Windows Vista
VBox Version: PUEL
Guest OSses: Windows, Linux, Solaris


Return to Suggestions

Who is online

Users browsing this forum: No registered users and 2 guests