VirtualBox

Ticket #14564 (closed defect: fixed)

Opened 3 years ago

Last modified 3 years ago

Build error (5.0.4) on Linux 32-bit system => Fixed in SVN

Reported by: Larry998 Owned by:
Priority: major Component: host support
Version: VirtualBox 5.0.4 Keywords: C++ compiler error
Cc: Guest type: other
Host type: Linux

Description

As the VirtualBox maintainer for openSUSE, I need to build both 32- and 64-bit versions. For a 64-bit system, all is fine. On a 32-bit platform with gcc 5.1.1, I get the following errors:

[  528s] /home/abuild/rpmbuild/BUILD/VirtualBox-5.0.4/src/VBox/ExtPacks/VNC/VBoxVNC.cpp: In static member function 'static int VNCServerImpl::VRDEEnableConnections(HVRDESERVER, bool)':
[  528s] /home/abuild/rpmbuild/BUILD/VirtualBox-5.0.4/src/VBox/ExtPacks/VNC/VBoxVNC.cpp:339:30: error: invalid conversion from 'rfbNewClientAction (__attribute__((regparm(0), cdecl)) *)(rfbClientPtr) {aka rfbNewClientAction (__attribute__((regparm(0), cdecl)) *)(_rfbClientRec*)}' to 'rfbNewClientHookPtr {aka rfbNewClientAction (*)(_rfbClientRec*)}' [-fpermissive]
[  528s]      vncServer->newClientHook = rfbNewClientEvent;
[  528s]                               ^
[  528s] /home/abuild/rpmbuild/BUILD/VirtualBox-5.0.4/src/VBox/ExtPacks/VNC/VBoxVNC.cpp:341:28: error: invalid conversion from 'void (__attribute__((regparm(0), cdecl)) *)(int, int, int, rfbClientPtr) {aka void (__attribute__((regparm(0), cdecl)) *)(int, int, int, _rfbClientRec*)}' to 'rfbPtrAddEventProcPtr {aka void (*)(int, int, int, _rfbClientRec*)}' [-fpermissive]
[  528s]      vncServer->ptrAddEvent = vncMouseEvent;
[  528s]                             ^
[  528s] kmk: *** [/home/abuild/rpmbuild/BUILD/VirtualBox-5.0.4/out/linux.x86/release/obj/VBoxVNC/VBoxVNC.o] Error 1

My C++ skills are not good, and I have no idea how to fix this.

Change History

comment:1 Changed 3 years ago by jpalus

We face the same issue here at PLD. The issue was tracked down to this commit:

r57336 | vboxsync | 2015-08-14 00:17:35 +0200 (pią, 14 sie 2015) | 1 line

iprt/cdefs.h,PGMDbg.cpp: Align DECLASM and DECLCALLBACK (and the rest) so we won't get into trouble with newer gcc versions finally checking for compatible calling conventions.

Reverting above commit fixes 32bit build but build for x32 ABI is still broken with multiple errors:

/tmp/B.b6eec353-b4f1-4cad-8990-af0914885009/BUILD/VirtualBox-5.0.4/include/iprt/types.h:726:37: error: 'cdecl' attribute ignored [-Werror=attributes] 

comment:2 Changed 3 years ago by frank

Already fixed in r57658.

comment:3 Changed 3 years ago by frank

  • Summary changed from Build error (5.0.4) on Linux 32-bit system to Build error (5.0.4) on Linux 32-bit system => Fixed in SVN

comment:4 Changed 3 years ago by jpalus

After applying fix from SVN there is new error:

/tmp/B.77ef36aa-4579-4e40-b692-860116fb03e4/BUILD/VirtualBox-5.0.4/src/VBox/Additions/linux/lightdm-greeter/vbox-greeter.cpp:929:64: error: invalid conversion from 'void (*)(PRTLOGGER, RTLOGPHASE, PFNRTLOGPHASEMSG) {aka void (*)(RTLOGGER*, RTLOGPHASE, void (__attribute__((regparm(0), cdecl)) *)(RTLOGGER*, const char*, ...))}' to 'PFNRTLOGPHASE {aka void (__attribute__((regparm(0), cdecl)) *)(RTLOGGER*, RTLOGPHASE, void (__attribute__((regparm(0), cdecl)) *)(RTLOGGER*, const char*, ...))}' [-fpermissive]

comment:5 Changed 3 years ago by frank

Thanks. That one should be fixed in r57690.

comment:6 Changed 3 years ago by Larry998

Thanks for the quick response. The updated 5.0.4 has not been submitte4d to the openSUSE Factory build system to produce a new package.

comment:7 Changed 3 years ago by frank

  • Status changed from new to closed
  • Resolution set to fixed

Fix is part of VBox 5.0.6.

Note: See TracTickets for help on using tickets.

www.oracle.com
ContactPrivacy policyTerms of Use