[vbox-dev] RuntimeGuestR3Mini linkages with thread.cpp due RT_WITH_ICONV_CACHE

Evgeny Sinelnikov sin at altlinux.ru
Mon Jun 14 07:30:00 PDT 2010


Hello,

During VirtualBox-3.2.4 building to ALTLinux Sisyphus I found a
problem with xorg drivers linkage.
http://git.altlinux.org/tasks/25568/task/log.3
       i586: NEW bad_elf_symbols detected:
xorg-x11-drv-vboxmouse-3.2.4-alt2.i586.rpm
/usr/lib/X11/modules/input/vboxmouse_drv.so     U       rtThreadGet
xorg-x11-drv-vboxvideo-3.2.4-alt2.i586.rpm
/usr/lib/X11/modules/drivers/vboxvideo_drv.so   U       rtThreadGet
       x86_64: NEW bad_elf_symbols detected:
xorg-x11-drv-vboxmouse-3.2.4-alt2.x86_64.rpm
/usr/lib64/X11/modules/input/vboxmouse_drv.so   U       rtThreadGet
xorg-x11-drv-vboxvideo-3.2.4-alt2.x86_64.rpm
/usr/lib64/X11/modules/drivers/vboxvideo_drv.so U       rtThreadGet
2010-Jun-10 22:52:02 :: ELF symbols check FAILED
2010-Jun-10 22:52:02 :: task #25568 for sisyphus FAILED

The problem comes from RuntimeGuestR3Mini linkage without including
thread.o, but with RT_WITH_ICONV_CACHE defined.

RuntimeGuestR3Mini includes src/VBox/Runtime/r3/posix/utf8-posix.cpp,
which consists next code:

DECLINLINE(int) rtStrConvertWrapper(const char *pchInput, size_t
cchInput, const char *pszInputCS,
                                    char **ppszOutput, size_t
cbOutput, const char *pszOutputCS,
                                    unsigned cFactor, RTSTRICONV
enmCacheIdx)
{
#ifdef RT_WITH_ICONV_CACHE
    RTTHREAD hSelf = RTThreadSelf();
    if (hSelf != NIL_RTTHREAD)
    {
        PRTTHREADINT pThread = rtThreadGet(hSelf);
        if (   pThread
            && (pThread->fIntFlags & (RTTHREADINT_FLAGS_ALIEN |
RTTHREADINT_FLAGS_MAIN)) != RTTHREADINT_FLAGS_ALIEN)
            return rtstrConvertCached(pchInput, cchInput, pszInputCS,
                                      (void **)ppszOutput, cbOutput,
pszOutputCS,
                                      cFactor, (iconv_t
*)&pThread->ahIconvs[enmCacheIdx]);
    }
#endif
    return rtStrConvertUncached(pchInput, cchInput, pszInputCS,
                                (void **)ppszOutput, cbOutput,
pszOutputCS,
                                cFactor);
}

I solved this problem with includes patch.
In this patch I replace rtThreadGet() function into common
threadbasic.cpp, which includes into RuntimeGuestR3 and
RuntimeGuestR3Mini.

-- 
Sin (Sinelnikov Evgeny)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: virtualbox-3.2.4-RuntimeGuestR3Mini.patch
Type: text/x-patch
Size: 4558 bytes
Desc: not available
Url : http://www.virtualbox.org/pipermail/vbox-dev/attachments/20100614/28de8f1b/attachment-0001.bin 


More information about the vbox-dev mailing list