Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] Virtualbox modules ebuild failure
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
filoo
n00b
n00b


Joined: 29 Jul 2017
Posts: 12
Location: Norway

PostPosted: Thu Oct 05, 2017 1:46 pm    Post subject: [SOLVED] Virtualbox modules ebuild failure Reply with quote

I am running my own vanilla kernel. I want to install virtualbox-modules. My kernel directory has all the sources (and compiled files). I am running this very kernel.
Code:

ls -l /usr/src/linux
lrwxrwxrwx 1 root root 20 Oct  3 11:43 /usr/src/linux -> /root/linux-4.14-rc2

It fails to find kernel directory:
Code:

>>> Emerging (1 of 1) app-emulation/virtualbox-modules-5.1.26::gentoo
 * vbox-kernel-module-src-5.1.26.tar.xz SHA256 SHA512 WHIRLPOOL size ;-) ...                                                                                         [ ok ]
 * Determining the location of the kernel source code
 * Found kernel source directory:
 *     /usr/src/linux
 * Found sources for kernel version:
 *     4.14.0-rc2
 * Checking for suitable kernel configuration options...                                                                                                             [ ok ]
>>> Unpacking source...
>>> Unpacking vbox-kernel-module-src-5.1.26.tar.xz to /home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work
>>> Source unpacked in /home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work
>>> Preparing source in /home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work ...
>>> Source prepared.
>>> Configuring source in /home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work ...
>>> Source configured.
>>> Compiling source in /home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work ...                                                                                 
ln: failed to create symbolic link 'Module.symvers': File exists                                                                                                           
 * Preparing vboxdrv module
make -j6 HOSTCC=x86_64-pc-linux-gnu-gcc CROSS_COMPILE=x86_64-pc-linux-gnu- 'LDFLAGS=-m elf_x86_64' KERN_DIR=/usr/src/linux O=/usr/src/linux V=1 KBUILD_VERBOSE=1 all
=== Building 'vboxdrv' module ===
make[1]: Entering directory '/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxdrv'
Makefile:196: *** Error: KERN_DIR does not point to a directory.  Stop.
make[1]: Leaving directory '/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxdrv'
make: *** [Makefile:41: all] Error 2
 * ERROR: app-emulation/virtualbox-modules-5.1.26::gentoo failed (compile phase):
 *   emake failed
 *
 * If you need support, post the output of `emerge --info '=app-emulation/virtualbox-modules-5.1.26::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=app-emulation/virtualbox-modules-5.1.26::gentoo'`.
 * The complete build log is located at '/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/temp/build.log'.
 * The ebuild environment file is located at '/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/temp/environment'.
 * Working directory: '/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work'
 * S: '/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work'

>>> Failed to emerge app-emulation/virtualbox-modules-5.1.26, Log file:

>>>  '/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/temp/build.log'

 * Messages for package app-emulation/virtualbox-modules-5.1.26:

 * ERROR: app-emulation/virtualbox-modules-5.1.26::gentoo failed (compile phase):
 *   emake failed
 *
 * If you need support, post the output of `emerge --info '=app-emulation/virtualbox-modules-5.1.26::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=app-emulation/virtualbox-modules-5.1.26::gentoo'`.
 * The complete build log is located at '/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/temp/build.log'.
 * The ebuild environment file is located at '/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/temp/environment'.
 * Working directory: '/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work'
 * S: '/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work'


Code:

Portage 2.3.6 (python 3.4.5-final-0, default/linux/amd64/13.0/desktop/plasma, gcc-5.4.0, glibc-2.23-r4, 4.14.0-rc2ala1 x86_64)
=================================================================
System uname: Linux-4.14.0-rc2ala1-x86_64-Intel-R-_Core-TM-_i7-7500U_CPU_@_2.70GHz-with-gentoo-2.3
KiB Mem:    16302876 total,   2782364 free
KiB Swap:          0 total,         0 free
Timestamp of repository gentoo: Wed, 27 Sep 2017 15:30:01 +0000
sh bash 4.3_p48-r1
ld GNU ld (Gentoo 2.28.1 p1.0) 2.28.1
app-shells/bash:          4.3_p48-r1::gentoo
dev-java/java-config:     2.2.0-r3::gentoo
dev-lang/perl:            5.24.1-r2::gentoo
dev-lang/python:          2.7.12::gentoo, 3.4.5::gentoo
dev-util/cmake:           3.7.2::gentoo
dev-util/pkgconfig:       0.28-r2::gentoo
sys-apps/baselayout:      2.3::gentoo
sys-apps/openrc:          0.28::gentoo
sys-apps/sandbox:         2.10-r3::gentoo
sys-devel/autoconf:       2.13::gentoo, 2.69::gentoo
sys-devel/automake:       1.11.6-r1::gentoo, 1.15-r2::gentoo
sys-devel/binutils:       2.28.1::gentoo
sys-devel/gcc:            5.4.0-r3::gentoo
sys-devel/gcc-config:     1.7.3::gentoo
sys-devel/libtool:        2.4.6-r3::gentoo
sys-devel/make:           4.2.1::gentoo
sys-kernel/linux-headers: 4.12::gentoo (virtual/os-headers)
sys-libs/glibc:           2.23-r4::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000

eclipse
    location: /var/lib/layman/eclipse
    masters: gentoo
    priority: 50

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe -march=native"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php7.0/ext-active/ /etc/php/cgi-php7.0/ext-active/ /etc/php/cli-php7.0/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe -march=native"
DISTDIR="/home/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j6"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/home/tmp"
USE="X a52 aac acl acpi acps activities alsa amd64 audiofile bash-completion bcmath berkdb bluetooth branding btrfs bzip2 cairo calendar cdda cdr cgi cli client consolekit cracklib crypt cups curl cxx dbus declarative djvu dri dts dvd dvdr emboss encode exif fam fastcgi ffmpeg firefox flac fltk fortran gd gdbm gif git glamor gnuplot gpm graphviz gtk gtk3 gzip i965 iconv icu imagemagick ipv6 jpeg kde kipi kwallet lcms ldap libnotify lua lzma mad mhash minizip mng modules mp3 mp4 mpeg mplayer multilib mysql mysqli ncurses networkmanager nls nptl nsplugin ntfs offensive ogg okteta opengl openmp pam pango pcntl pcre pdf phonon php plasma plotutils png policykit portaudio posix ppds python qml qt3support qt4 qt5 rdp readline rss samba sdl seccomp semantic-desktop server session sockets sox spell sqlite ssl startup-notification subversion svg syslog sysvipc tcpd threads tiff truetype udev udisks unicode upower usb vnc vorbis webkit widgets wifi wxwidgets x264 xattr xcb xcomposite xinerama xml xmlrpc xscreensaver xv xvid zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx avx2 fma3 mmx mmxext pclmul popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="libinput keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-6" POSTGRES_TARGETS="postgres9_5" PYTHON_SINGLE_TARGET="python3_4" PYTHON_TARGETS="python2_7 python3_4" RUBY_TARGETS="ruby22" USERLAND="GNU" VIDEO_CARDS="intel i965" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS


Thanks for help


Last edited by filoo on Fri Oct 06, 2017 6:06 am; edited 1 time in total
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 16875
Location: here

PostPosted: Thu Oct 05, 2017 2:01 pm    Post subject: Reply with quote

Code:
Makefile:196: *** Error: KERN_DIR does not point to a directory.  Stop.

You can post output of
Code:
$ ls -l /usr/src/

_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
filoo
n00b
n00b


Joined: 29 Jul 2017
Posts: 12
Location: Norway

PostPosted: Thu Oct 05, 2017 4:03 pm    Post subject: Reply with quote

Code:

ls -l /usr/src
total 4
lrwxrwxrwx 1 root root  20 Oct  3 11:43 linux -> /root/linux-4.14-rc2
drwxr-xr-x 1 root root 482 Oct  3 11:22 linux-4.12.12-gentoo

ls -l /root
total 0
drwxrwxr-x 1 root root 1028 Oct  5 12:35 linux-4.14-rc2
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 16875
Location: here

PostPosted: Thu Oct 05, 2017 7:31 pm    Post subject: Reply with quote

It seems that kernel source need to be located in /usr/src
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
filoo
n00b
n00b


Joined: 29 Jul 2017
Posts: 12
Location: Norway

PostPosted: Thu Oct 05, 2017 7:39 pm    Post subject: Reply with quote

Wow - thanks! I moved the sources to /usr/src and updated the symlink. Now the ebuild starts, but I get the following build failure:
Code:

/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt/linux/VBoxNetFlt-linux.c: In function 'vboxNetFltLinuxSkBufFromSG':
/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt/linux/VBoxNetFlt-linux.c:726:24: error: 'SKB_GSO_UDP' undeclared (first use in this function)
             fGsoType = SKB_GSO_UDP;
                        ^
/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt/linux/VBoxNetFlt-linux.c:726:24: note: each undeclared identifier is reported only once for each function it appears in
In file included from /home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt/include/iprt/types.h:29:0,
                 from /home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt/r0drv/linux/the-linux-kernel.h:34,
                 from /home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt/linux/VBoxNetFlt-linux.c:24:
/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt/linux/VBoxNetFlt-linux.c: In function 'vboxNetFltLinuxCanForwardAsGso':
/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt/linux/VBoxNetFlt-linux.c:1112:53: error: 'SKB_GSO_UDP' undeclared (first use in this function)
     if (RT_UNLIKELY( skb_shinfo(pSkb)->gso_type & ~(SKB_GSO_UDP | SKB_GSO_DODGY | SKB_GSO_TCPV6 | SKB_GSO_TCPV4) ))
                                                     ^
/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt/include/iprt/cdefs.h:1612:53: note: in definition of macro 'RT_UNLIKELY'
 #  define RT_UNLIKELY(expr)     __builtin_expect(!!(expr), 0)
                                                     ^
/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt/linux/VBoxNetFlt-linux.c: In function 'vboxNetFltLinuxForwardToIntNet':
/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt/linux/VBoxNetFlt-linux.c:1405:47: error: 'SKB_GSO_UDP' undeclared (first use in this function)
         if (   (skb_shinfo(pBuf)->gso_type & (SKB_GSO_UDP | SKB_GSO_TCPV6 | SKB_GSO_TCPV4))
                                               ^
make[4]: *** [/usr/src/linux-4.14-rc2/scripts/Makefile.build:311: /home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt/linux/VBoxNetFlt-linux.o] Error 1
make[3]: *** [/usr/src/linux-4.14-rc2/Makefile:1498: _module_/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt] Error 2
make[3]: Leaving directory '/usr/src/linux-4.14-rc2'
make[2]: *** [Makefile:145: sub-make] Error 2
make[2]: Leaving directory '/usr/src/linux-4.14-rc2'
make[1]: *** [Makefile:211: vboxnetflt] Error 2
make[1]: Leaving directory '/home/tmp/portage/app-emulation/virtualbox-modules-5.1.26/work/vboxnetflt'
make: *** [Makefile:44: all] Error 1

I can't google what SKB_GSO_UDP is and why it is missing :?
Back to top
View user's profile Send private message
joanandk
n00b
n00b


Joined: 12 Feb 2017
Posts: 34

PostPosted: Thu Oct 05, 2017 7:53 pm    Post subject: Reply with quote

filoo wrote:
I can't google what SKB_GSO_UDP is and why it is missing :?


AFAIK is the Kernel 4.12 supported by virtualbox-modules 5.1.26, but 4.14 is too new.
Back to top
View user's profile Send private message
fedeliallalinea
Bodhisattva
Bodhisattva


Joined: 08 Mar 2003
Posts: 16875
Location: here

PostPosted: Thu Oct 05, 2017 7:58 pm    Post subject: Reply with quote

Not sure but probably version 5.1.26 isn't compatible with kernel 4.14
_________________
Questions are guaranteed in life; Answers aren't.
Back to top
View user's profile Send private message
filoo
n00b
n00b


Joined: 29 Jul 2017
Posts: 12
Location: Norway

PostPosted: Thu Oct 05, 2017 8:10 pm    Post subject: Reply with quote

Thank you all.

I've just tried 5.1.28 with identical results. I'll just have to wait a little bit for virtualbox-modules to catch up with the latest kernel.
Back to top
View user's profile Send private message
HerbMillerJW
n00b
n00b


Joined: 16 Feb 2012
Posts: 34

PostPosted: Sat Oct 21, 2017 3:21 am    Post subject: Reply with quote

This was removed from the Linux kernel: https://github.com/torvalds/linux/commit/d9d30adf56777c402c0027c0e6ae21f17cc0a365

Plop this in your user patches and it should get you going again: https://gist.github.com/herbmillerjr/039c129e9c25b047b906e19ad1f23a59

If you want to build 5.1.30, just rename the patch and put it in the appropriate directory. It should work just the same.
Back to top
View user's profile Send private message
medianperson
n00b
n00b


Joined: 01 Nov 2017
Posts: 1

PostPosted: Wed Nov 01, 2017 3:59 pm    Post subject: Reply with quote

Thanks, that fixed it for me for virtualbox-modules-5.1.30 on kernel 4.14-rc7.
Back to top
View user's profile Send private message
kernelOfTruth
Watchman
Watchman


Joined: 20 Dec 2005
Posts: 6102
Location: Vienna, Austria; Germany; hello world :)

PostPosted: Fri Nov 24, 2017 2:48 am    Post subject: Reply with quote

medianperson wrote:
Thanks, that fixed it for me for virtualbox-modules-5.1.30 on kernel 4.14-rc7.


++

thanks HerbMillerJW :)
_________________
https://github.com/kernelOfTruth/ZFS-for-SystemRescueCD/tree/ZFS-for-SysRescCD-4.9.0
https://github.com/kernelOfTruth/pulseaudio-equalizer-ladspa

Hardcore Gentoo Linux user since 2004 :D
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 39266
Location: 56N 3W

PostPosted: Fri Nov 24, 2017 11:09 am    Post subject: Reply with quote

HerbMillerJW,

Thank you.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 2035
Location: Illinois, USA

PostPosted: Tue Nov 28, 2017 1:27 am    Post subject: Reply with quote

NeddySeagoon wrote:
HerbMillerJW,

Thank you.
ditto!
Back to top
View user's profile Send private message
aldinomis
n00b
n00b


Joined: 28 Nov 2017
Posts: 1

PostPosted: Tue Nov 28, 2017 7:18 pm    Post subject: Reply with quote

+1
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum