# Virtualbox will not compile



## Grell (May 23, 2011)

Hey guys, I have tried and tried to get virtualbox-ose from ports to compile.  Some google results said that I need COMPAT_FREEBSD32 enabled in the kernel.  So I recompiled not only the kernel (which had COMPAT_FREEBSD32 enabled by default) but I have updated my whole system to 8.2-STABLE.  When I compile virtualbox-ose without X or QT it compiles fine.  I also notice that I can no longer compile even the old virtualbox (the legacy version).  Here is the output from ports when I try to compile virtualbox.
	
	



```
...
kBuild: Generating python - /usr/ports/emulators/virtualbox-ose/work/VirtualBox-4.0.8_OSE/out/freebsd.amd64/release/obj/VBoxOGLgen/spu_dispatch_table.h
  File "/usr/ports/emulators/virtualbox-ose/work/VirtualBox-4.0.8_OSE/src/VBox/GuestHost/OpenGL/spu_loader/dispatchheader.py", line 29
    """
      ^
SyntaxError: invalid syntax
kmk: *** [/usr/ports/emulators/virtualbox-ose/work/VirtualBox-4.0.8_OSE/out/freebsd.amd64/release/obj/VBoxOGLgen/spu_dispatch_table.h] Error 1
kmk: *** Deleting file `/usr/ports/emulators/virtualbox-ose/work/VirtualBox-4.0.8_OSE/out/freebsd.amd64/release/obj/VBoxOGLgen/spu_dispatch_table.h'
kmk: *** Waiting for unfinished jobs....
kmk: *** Exiting with status 2
*** Error code 2

Stop in /usr/ports/emulators/virtualbox-ose.
*** Error code 1

Stop in /usr/ports/emulators/virtualbox-ose.
```
I would appreciate any help, thanks again.


----------



## OmIkRoNiXz (May 23, 2011)

Had similar error, recompiling icu-* and dependencies helped me.

`portupgrade -rf icu-\*`


----------



## _martin (May 23, 2011)

Hm, I did compile it yesterday without any problems. Here's my configuration to compare:

Kernel (8.2-RELEASE amd64):

`# grep -i ^[options].*COMPAT /usr/src/sys/amd64/conf/FOXI`

```
options         COMPAT_43TTY            # BSD 4.3 TTY compat (sgtty)
options         COMPAT_FREEBSD32        # Compatible with i386 binaries
options         COMPAT_FREEBSD4         # Compatible with FreeBSD4
options         COMPAT_FREEBSD5         # Compatible with FreeBSD5
options         COMPAT_FREEBSD6         # Compatible with FreeBSD6
options         COMPAT_FREEBSD7         # Compatible with FreeBSD7
```

Options used to install virtualbox:

`# cat /var/db/ports/virtualbox-ose/options`

```
# This file is auto-generated by 'make config'.
# No user-servicable parts inside!
# Options for virtualbox-ose-4.0.8
_OPTIONS_READ=virtualbox-ose-4.0.8
WITHOUT_QT4=true
WITHOUT_DEBUG=true
WITHOUT_GUESTADDITIONS=true
WITH_DBUS=true
WITHOUT_PULSEAUDIO=true
WITH_X11=true
WITH_VDE=true
WITH_VNC=true
WITHOUT_WEBSERVICE=true
WITHOUT_NLS=true
```

And packages:

`# ll /var/db/pkg/|grep -iE 'pyth|virtual'`

```
drwxr-xr-x    2 root  wheel      512 May 22 20:39 python25-2.5.5_1
drwxr-xr-x    2 root  wheel      512 May 22 20:39 virtualbox-ose-4.0.8
drwxr-xr-x    2 root  wheel      512 May 22 20:39 virtualbox-ose-kmod-4.0.8
```

This seems like a problem with python itself. Which version are you running?


----------



## Grell (May 24, 2011)

Well I'm at a loss.  I've been fiddling around all day trying to get this working.  I installed lang/python25 and lang/python26, setting the PYTHON_DEFAULT_VERSION to 2.5 and 2.6 respectively.  I did `# portmaster -d -f icu\*`.  I keep getting the same compile error as I listed in the topic post.  My _actual_ default python version is 2.7, if that helps.  Please help.


----------



## mix_room (May 24, 2011)

I am assuming that you have run 
`# make clean`
in the appropriate places, otherwise you might try this.


----------

