LDD on My Deployed Application



  • Hi all, I'm trying to create a installer to my application, and at moment I'm trying to build a debian package.
    So, when I try to make, I got some erros, with library on executable file.

    When I run the LDD on myy application I got this:

    @
    dvl@ubuntu:~/Desktop/debian/inove-bevsat-1.0.0$ ldd InoveBEVSAT
    linux-gate.so.1 => (0xb7779000)
    libQtWebKit.so.4 => /opt/QtSDK/Desktop/Qt/4.8.1/gcc/lib/libQtWebKit.so.4 (0xb61e6000)
    libQtSvg.so.4 => /opt/QtSDK/Desktop/Qt/4.8.1/gcc/lib/libQtSvg.so.4 (0xb618e000)
    libQtSql.so.4 => /opt/QtSDK/Desktop/Qt/4.8.1/gcc/lib/libQtSql.so.4 (0xb614d000)
    libQtGui.so.4 => /opt/QtSDK/Desktop/Qt/4.8.1/gcc/lib/libQtGui.so.4 (0xb562a000)
    libQtCore.so.4 => /opt/QtSDK/Desktop/Qt/4.8.1/gcc/lib/libQtCore.so.4 (0xb5343000)
    libpthread.so.0 => /lib/i386-linux-gnu/libpthread.so.0 (0xb5315000)
    libstdc++.so.6 => /usr/lib/i386-linux-gnu/libstdc++.so.6 (0xb5230000)
    libgcc_s.so.1 => /lib/i386-linux-gnu/libgcc_s.so.1 (0xb5211000)
    @

    Why some libraries is the /opt/QtSDK/Desktop/Qt/4.8.1/gcc/lib ? It's a kind of error?
    How to fix it?



  • When you compiled your application, you linked it against shared libraries of your version of Qt which is installed in /opt/QtSDK/Desktop/Qt/4.8.1/gcc/lib. There is something called RPATH that tells the dynamic linker where to look for the speficied libraries. What you want to do is to use an utility like "PatchELF":http://nixos.org/patchelf.html that will allow you to replace /opt/QtSDK/Desktop/Qt/4.8.1/gcc/lib/libQtWebKit.so.4 by a simpler libQtWebKit.so.4.
    Those libraries will be looked for in the default library paths, read the manpage for ld if you need more information about that.





  • Thanks o use chrpath comand line and fix the problem.
    Now my debian package is building without errors.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.