VirtualBox

Opened 8 years ago

Closed 8 years ago

#15322 closed defect (fixed)

vboxvideo compilation fails for kernel 3.10

Reported by: Jan Palus Owned by:
Component: other Version: VirtualBox 5.0.18
Keywords: Cc:
Guest type: other Host type: other

Description

vboxvideo fails to compile for an older LTS kernel version 3.10:

/tmp/B.fs0QZd/BUILD/VirtualBox-5.0.18/PLD-MODULE-BUILD/GuestDrivers/vboxvideo/vbox_mode.c:314:5: error: unknown field 'cursor_set2' specified in initializer
     .cursor_set2 = vbox_cursor_set2,
     ^
/tmp/B.fs0QZd/BUILD/VirtualBox-5.0.18/PLD-MODULE-BUILD/GuestDrivers/vboxvideo/vbox_mode.c:314:20: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
     .cursor_set2 = vbox_cursor_set2,
                    ^
/tmp/B.fs0QZd/BUILD/VirtualBox-5.0.18/PLD-MODULE-BUILD/GuestDrivers/vboxvideo/vbox_mode.c:314:20: note: (near initialization for 'vbox_crtc_funcs.gamma_set')
/usr/src/linux-3.10-3.10.101/scripts/Makefile.build:308: recipe for target '/tmp/B.fs0QZd/BUILD/VirtualBox-5.0.18/PLD-MODULE-BUILD/GuestDrivers/vboxvideo/vbox_mode.o' failed

Change History (10)

comment:1 by Frank Mehnert, 8 years ago

Which LTS version is this exactly?

in reply to:  1 comment:2 by Jan Palus, 8 years ago

Replying to frank:

Which LTS version is this exactly?

3.10.101

comment:3 by Frank Mehnert, 8 years ago

Right. Actually, which Linux distribution are you running? Asking to find out which guest video driver you need.

in reply to:  3 comment:4 by Jan Palus, 8 years ago

Replying to frank:

Right. Actually, which Linux distribution are you running? Asking to find out which guest video driver you need.

Not sure if that's relevant actually -- I'm one of maintainers in PLD Linux (http://www.pld-linux.org) for which we support multiple lines of kernel. Among them each LTS version starting with 3.10 and all of them until now had support for VirtualBox both as a host and guest. I'm not using 3.10 myself but we'd like to be able to deliver support for this line too.

comment:5 by Frank Mehnert, 8 years ago

Actually for Linux 3.10 there should be no real vboxvideo kernel module. Look at the Makefile:

ifeq ($(filter 1.% 2.% 3.0.% 3.1.% 3.2.% 3.3.% 3.4.% 3.5.% 3.6.% 3.7.% \
3.8.% 3.9.% 3.10.%,$(KERNELRELEASE)),)
MOD_OBJS   = HGSMIBase.o HGSMICommon.o HGSMIMemAlloc.o heapoffset.o \
             Modesetting.o vbox_drv.o vbox_fb.o vbox_irq.o vbox_main.o \
             vbox_mode.o vbox_ttm.o VBVABase.o
else
MOD_OBJS   = vbox_dummy.o
endif
Last edited 8 years ago by Frank Mehnert (previous) (diff)

in reply to:  5 comment:6 by Jan Palus, 8 years ago

Just had some time to look into this. In my case KERNELRELEASE is not defined, however what is defined is KERNELVERSION -- any idea what's the difference and whether KERNELVERSION could be used here?

comment:7 by Frank Mehnert, 8 years ago

KERNELVERSION could be probably used as well and we will think about changing this. But if KERNELRELEASE does not exist then include/config/kernel.release most likely does not exist either. Which means that your kernel sources are not configured.

in reply to:  7 comment:8 by Jan Palus, 8 years ago

Actually it does exist:

jan@cukinia /usr/src/linux-3.10-3.10.101[11:10:34] 
> $ cat include/config/kernel.release
3.10.101-1

but it appears to include distribution specific release suffix.

comment:9 by Jan Palus, 8 years ago

Feel free to close -- it appears passing standard kernel build option "O=<path to output directory>" breaks KERNELRELEASE evaluation. Without it modules for 3.10 build fine.

comment:10 by Frank Mehnert, 8 years ago

Resolution: fixed
Status: newclosed

Closing. Actually there should be a change in 5.0.22 which should prevent this kind of problems as well.

Note: See TracTickets for help on using tickets.

© 2023 Oracle
ContactPrivacy policyTerms of Use