Error while loading shared libraries during cross-compiling



  • Well if I add this in my *.pro file:

    QT += core
    

    I have error when I try cross-compiling:

    error while loading shared libraries: libQt5Core.so.5: cannot open shared object file: No such file or directory
    

    Anyone knows the solution? Maybe I must installing some library in rpi?


  • Lifetime Qt Champion

    Hi,

    Did you cross-compile Qt ?



  • I not very understand what you mean.
    I think the raspberry don't have the library, maybe install qt in raspberry would help?



  • Yeah, I have right. I copy all Qt library to RPI and use this in rpi terminal:

        export LD_LIBRARY_PATH="/home/pi/QtBase-5.7.0/lib"
        ./Test
    

    and everything work.
    Tomorrow I'll try just install qt in rpi, and this should work without terminal.
    Another topic solved.


Log in to reply