package virtualbox-ose-dkms * failed to install/upgrade: virtualbox-ose kernel module failed to build (types.h:97:31: fatal error: linux/autoconf.h: No such file or directory)

Bug #705593 reported by Cristian Aravena Romero
782
This bug affects 87 people
Affects Status Importance Assigned to Milestone
Virtualbox
Fix Released
Unknown
virtualbox-ose (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

Binary package hint: virtualbox-ose

Update to kernel 2.6.38-rc1:
http://kernel.ubuntu.com/~kernel-ppa/mainline/v2.6.38-rc1-natty/

And error of apport

ProblemType: Package
DistroRelease: Ubuntu 10.10
Package: virtualbox-ose-dkms 3.2.8-dfsg-2ubuntu1
Uname: Linux 2.6.37-020637-generic x86_64
Architecture: amd64
Date: Thu Jan 20 17:01:01 2011
ErrorMessage: virtualbox-ose kernel module failed to build
InstallationMedia: Ubuntu 10.10 "Maverick Meerkat" - Release amd64 (20101007)
PackageArchitecture: all
PackageVersion: 3.2.8-dfsg-2ubuntu1
SourcePackage: virtualbox-ose
Title: package virtualbox-ose-dkms 3.2.8-dfsg-2ubuntu1 failed to install/upgrade: virtualbox-ose kernel module failed to build

Related branches

Revision history for this message
Cristian Aravena Romero (caravena) wrote :
Revision history for this message
bishoptf (bishoptf) wrote :

This is affecting me also, running 10.10 with the latest 2.6.38RC1 kernel amd64, however I am running 4.0.2 package version.

Revision history for this message
Oli (oli) wrote :

Confirmed.This appears to effect both the closed-source and open source versions' DKMS modules. (I'm also on Maverick with .38-rc1 using the PPA of Virtualbox).

I've tried stepping through the DKMS script but it's a nightmare to follow if, like me, you're not really sure what you're looking at.

Revision history for this message
SoftExpert (marian.popescu) wrote :

You need to change the following line
# include <linux/autoconf.h>
with
# include <generated/autoconf.h>
on every .h file in the /usr/share/virtualbox/src/vboxhost directory.

After that it compiles with no problem with DKMS. Just use
sudo /etc/init.d/vboxdrv setup

This page https://patchwork.kernel.org/patch/72714/ gave me the idea ...

Felix Geyer (debfx)
summary: - package virtualbox-ose-dkms 3.2.8-dfsg-2ubuntu1 failed to
- install/upgrade: virtualbox-ose kernel module failed to build
+ vboxdrv module fails to build with kernel 2.6.38
Changed in virtualbox-ose (Ubuntu):
status: New → Confirmed
Changed in virtualbox:
status: Unknown → New
Revision history for this message
bishoptf (bishoptf) wrote : Re: vboxdrv module fails to build with kernel 2.6.38

It appears that these are all of the files that need to be patched....

hostname:/usr/share/virtualbox/src/vboxhost$ grep -d recurse '<linux/autoconf.h>' *

vboxdrv/SUPDrvInternal.h:# include <linux/autoconf.h>
vboxdrv/include/iprt/types.h:# include <linux/autoconf.h>
vboxdrv/include/internal/iprt.h:# include <linux/autoconf.h>
vboxdrv/r0drv/linux/the-linux-kernel.h:# include <linux/autoconf.h>
vboxnetadp/include/iprt/types.h:# include <linux/autoconf.h>
vboxnetadp/include/internal/iprt.h:# include <linux/autoconf.h>
vboxnetadp/r0drv/linux/the-linux-kernel.h:# include <linux/autoconf.h>
vboxnetflt/include/iprt/types.h:# include <linux/autoconf.h>
vboxnetflt/r0drv/linux/the-linux-kernel.h:# include <linux/autoconf.h>

Revision history for this message
Oli (oli) wrote :

For the lazies:

sudo find /usr/share/virtualbox/src/vboxhost -name *.h -exec perl -pi -w -e 's/linux\/autoconf/generated\/autoconf/g;' {} \;
sudo /etc/init.d/vboxdrv setup

Revision history for this message
Mattia Tavernini (maathias) wrote :

It isn't better doing

sudo cp /usr/src/linux-headers-`uname -r`/include/generated/autoconf.h /usr/src/linux-headers-`uname -r`/include/linux/

???

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package virtualbox-ose - 4.0.2-dfsg-1ubuntu1

---------------
virtualbox-ose (4.0.2-dfsg-1ubuntu1) natty; urgency=low

  * Merge from Debian unstable, remaining changes:
    - Add Apport hook.
      - debian/virtualbox-ose.files/source_virtualbox-ose.py
      - debian/virtualbox-ose.install
    - Drop *-source packages.
  * Drop ubuntu-01-fix-build-gcc45.patch, fixed upstream.
  * Drop ubuntu-02-as-needed.patch, added to the Debian package.

virtualbox-ose (4.0.2-dfsg-1) unstable; urgency=low

  * New upstream release. (LP: #709027)
    - Ships with a manual and upstream changelog.
      (Closes: #483702, #541127; LP: #243782)
  * Adapt patches for new upstream version.
  * Add new required build-dependencies:
    default-jdk, genisoimage, makeself, texlive-fonts-extra,
    texlive-fonts-recommended, texlive-latex-extra, texlive-latex-recommended.
  * Set VBOX_JAVA_HOME to /usr/lib/jvm/default-java.
  * Add 28-no-selinux-fedora.patch so VirtualBox doesn't try to install
    selinux-fedora/vbox_x11.pp which is stripped by the dfsg-free target.
  * Update install files.
  * Add 29-fix-ftbfs-as-needed.patch to fix FTBFS with ld --as-needed.
  * Automatically generate the pixmap icon from png.
  * Fix the watch file.
  * Update man pages.
  * Support passing through USB 1.1 devices to virtual machines.
  * Update vdfuse for VirtualBox 4.
  * Make the kernel modules buildable with kernel 2.6.38-rc2. (LP: #705593)
    - Add 30-kernel-2.6.38.diff
 -- Felix Geyer <email address hidden> Sun, 30 Jan 2011 23:27:25 +0100

Changed in virtualbox-ose (Ubuntu):
status: Confirmed → Fix Released
Revision history for this message
Marcos Magalhães (marcos-daekdroom) wrote :

It affects Natty Narwhal's packages as well.

Revision history for this message
Marcos Magalhães (marcos-daekdroom) wrote :

Ok. That was poorly timed. Sorry.

Changed in virtualbox:
status: New → Fix Released
summary: - vboxdrv module fails to build with kernel 2.6.38
+ package virtualbox-ose-dkms * failed to install/upgrade: virtualbox-ose
+ kernel module failed to build (types.h:97:31: fatal error:
+ linux/autoconf.h: No such file or directory)
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

This bug is still affecting Ubuntu 10.04 users as seen by regular duplicates. Yes, it seems a lot of lucid users have upgraded their kernels.

Revision history for this message
mantis (mantis-1) wrote :

In 10.4 there is no such folder "usr/share/virtualbox/src/vboxhost" even there is no src.
I install it from ubuntu's repo

cheers

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

All,

If you get this bug after doing an upgrade, it's likely because virtualbox doesn't seem to always upgrade with the system. You'll likely have to uninstall the old version and install the newer one (>= 4.0.2 according to comment #8).

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.