RaspberryPI undefined reference to clock_gettime@GLIBC_2.17

Sysprogs forums Forums VisualGDB RaspberryPI undefined reference to clock_gettime@GLIBC_2.17

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #6205
    Tristan Rybak
    Participant

    Hi,

    I just upgraded to new crosscompiler toolchain for raspberry pi.

    When I link my code, linker complaints:

    c:/sysgcc/raspberry/bin/../lib/gcc/arm-linux-gnueabihf/4.9/../../../../arm-linux-gnueabihf/lib/libstdc++.so: undefined reference to `clock_gettime@GLIBC_2.17′

    How can I fix it?

    Regards,

    Tristan

    #6210
    support
    Keymaster

    Hi,

    This looks like a known problem. Please follow the solution described here: http://qt-project.org/forums/viewthread/49098

    #6213
    Tristan Rybak
    Participant

    The link points to upgrading eglibc on x86 linux. I didn’t found any source of newer eglibc for armhf linux (the one on raspberry pi).

    There were some people on raspberry pi forums trying to upgrade eglibc but nobody succeded AFAIK.

    What is the point of giving a selection of cross-compile toochain for raspberry pi project that doesn’t work by default?

    Regards,

    Tristan

    #6219
    support
    Keymaster

    Hi,

    The toolchain does work by default. In this case it looks like there is a mismatch between different library versions on your Raspberry Pi and resynchronizing the toolchain’s sysroot with your device downloaded those incompatible libraries to the toolchain. Please re-check if it can be reproduced with the default toolchain. If yes, please provide a simple repro project so that we could fix it. If no, please revert to the default Raspberry Pi image to ensure that your libraries are in sync.

    #6271
    michael.s
    Participant

    Hi Tristan (Fishermen;),

    we just had the same problem and the reason and solution is quiet simple. VisualGDB offer you 2 toolchains to download for the raspberry…the older one seems to be for the standard Wheezy image from the raspberry pi homepage. the second and newer toolchain seems to be for the new ‘Jessie’-upgrade.

    so you either use the old toolchain or you upgrade your pi to Jessie (that’s what we did)…here is how it’s done

    http://raspberrypi.stackexchange.com/questions/27858/upgrade-to-raspbian-jessie

    the upgrade took us a couple of hours!!! but in the end it compiled just fine with the newer toolchain. I hope that works for you too..

    Michael

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.