Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 633648 - app-emulation/virtualbox-guest-additions-5.1.28 (and 5.1.26 as well) do not emerge with sys-kernel/gentoo-sources-4.9.53
Summary: app-emulation/virtualbox-guest-additions-5.1.28 (and 5.1.26 as well) do not e...
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Lars Wendler (Polynomial-C) (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-10-06 21:00 UTC by Stefan Trenker
Modified: 2018-10-31 15:40 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Emerge log (app-emulation:virtualbox-guest-additions-5.1.28:20171006-204854.log.gz,156.60 KB, application/gzip)
2017-10-06 21:00 UTC, Stefan Trenker
Details
emerge --info (emerge--info,6.67 KB, text/plain)
2017-10-06 21:02 UTC, Stefan Trenker
Details
Kernel .config file (config-4.9.53-gentoo,120.07 KB, text/plain)
2017-10-06 21:02 UTC, Stefan Trenker
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Trenker 2017-10-06 21:00:45 UTC
Created attachment 497924 [details]
Emerge log

Emerge fails when entering build of kernel modules:

mkdir -p /var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest/.tmp_versions ; rm -f /var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest/.tmp_versions/*
make -f ./scripts/Makefile.build obj=/var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest
make[2]: *** No rule to make target '/var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest/VBoxGuest-linux.o', needed by '/var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest/vboxguest.o'.  Stop.
make[1]: *** [Makefile:1493: _module_/var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest] Error 2
make[1]: Leaving directory '/usr/src/linux-4.9.53-gentoo'
make: *** [/var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest/Makefile.include.footer:85: vboxguest] Error 2
 * ERROR: app-emulation/virtualbox-guest-additions-5.1.28::gentoo failed (compile phas
Comment 1 Stefan Trenker 2017-10-06 21:02:01 UTC
Created attachment 497926 [details]
emerge --info
Comment 2 Stefan Trenker 2017-10-06 21:02:39 UTC
Created attachment 497928 [details]
Kernel .config file
Comment 3 Tomáš Mózes 2017-10-06 21:16:37 UTC
echo >&2 "  ERROR: Kernel configuration is invalid.";           \
echo >&2 "         include/generated/autoconf.h or include/config/auto.conf are missing.";\
echo >&2 "         Run 'make oldconfig && make prepare' on kernel src to fix it.";      \
Comment 4 Stefan Trenker 2017-10-06 21:46:29 UTC
(In reply to Tomáš Mózes from comment #3)
> echo >&2 "  ERROR: Kernel configuration is invalid.";           \
> echo >&2 "         include/generated/autoconf.h or include/config/auto.conf
> are missing.";\
> echo >&2 "         Run 'make oldconfig && make prepare' on kernel src to fix
> it.";      \

I am sorry, but this does not help. Same errors.

Kernel compiles fine with genkernel:
genkernel /usr/src/linux-4.9.53-gentoo/ --oldconfig --loglevel=2 --luks --gpg --lvm --all-ramdisk-modules --save-config --no-mrproper --no-clean --no-menuconfig --install all

emerge @module-rebuild ... fails for virtualbox-guest-additions

The build kernel boots fine ... just systemd complaining to load the missing virtualbox-guest-additions modules
Comment 5 Jouni Kosonen 2017-10-07 02:36:31 UTC
(In reply to Stefan Trenker from comment #4)
> Kernel compiles fine with genkernel:
> genkernel /usr/src/linux-4.9.53-gentoo/ ...

So you are telling genkernel what path to use for kernel sources but you aren't telling emerge the same thing. From your log:

>  * Preparing vboxguest module
> make -j3 HOSTCC=x86_64-pc-linux-gnu-gcc CROSS_COMPILE=x86_64-pc-linux-gnu- 
> 'LDFLAGS=-m elf_x86_64' KERN_DIR=/lib/modules/4.9.53-gentoo/build 
> KERNOUT=/lib/modules/4.9.53-gentoo/build all 
> grep: /lib/modules/4.9.53-gentoo/build/include/linux/version.h: 
> No such file or directory

it looks like it guesses the wrong directory.

Does it help if you make /usr/src/linux a soft link to linux-4.9.53-gentoo ?
eselect kernel would do this too.
Comment 6 Stefan Trenker 2017-10-07 11:23:40 UTC
(In reply to Jouni Kosonen from comment #5)
> (In reply to Stefan Trenker from comment #4)
> > Kernel compiles fine with genkernel:
> > genkernel /usr/src/linux-4.9.53-gentoo/ ...
> 
> So you are telling genkernel what path to use for kernel sources but you
> aren't telling emerge the same thing. From your log:
> 
> >  * Preparing vboxguest module
> > make -j3 HOSTCC=x86_64-pc-linux-gnu-gcc CROSS_COMPILE=x86_64-pc-linux-gnu- 
> > 'LDFLAGS=-m elf_x86_64' KERN_DIR=/lib/modules/4.9.53-gentoo/build 
> > KERNOUT=/lib/modules/4.9.53-gentoo/build all 
> > grep: /lib/modules/4.9.53-gentoo/build/include/linux/version.h: 
> > No such file or directory
> 
> it looks like it guesses the wrong directory.
> 
> Does it help if you make /usr/src/linux a soft link to linux-4.9.53-gentoo ?
> eselect kernel would do this too.

That's not the problem either.

~ # eselect kernel list
Available kernel symlink targets:
  [1]   linux-4.4.90-gentoo
  [2]   linux-4.9.53-gentoo *

For linux-4.4.90-gentoo emerging the guest additions work. And there i see the same grep error message for a missing version.h file in the 4.4.90 path.

The problem lies a few lines later:
mkdir -p /var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest/.tmp_versions ; rm -f /var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest/.tmp_versions/*
make -f ./scripts/Makefile.build obj=/var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest
make[2]: *** No rule to make target '/var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest/VBoxGuest-linux.o', needed by '/var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest/vboxguest.o'.  Stop.
make[1]: *** [Makefile:1493: _module_/var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest] Error 2
make[1]: Leaving directory '/usr/src/linux-4.9.53-gentoo'
make: *** [/var/tmp/portage/app-emulation/virtualbox-guest-additions-5.1.28/work/vboxguest/Makefile.include.footer:85: vboxguest] Error 2

This make-error does not pop up when compiling for 4.4.90
Comment 7 Stefan Trenker 2017-10-07 11:32:55 UTC
When I look into the attached build log, I find in the "Src Prepare" block the following message:

---8<---
Checking for Linux kernel sources: found version 4.9.53, OK.
Detected Linux >= 4.8 -- disabling compiling of Linux kernel modules.
---8<---

Reading this, the ebuild should skip emerging the kernel modules. But it does not skip, it bails out. 

BTW ... are VirtualBox guest additions no longer supported for the latest long-term kernel?
Comment 8 Gerold Schellstede 2017-11-03 15:02:58 UTC
Have the same problem. 

Additionally: 4.9 is not only the latest long-term kernel, but also the last grsecurity-featured long-term kernel.
Comment 9 Ben Kohler gentoo-dev 2018-10-31 15:40:05 UTC
Please reopen if this still affects 5.2.x