Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Special Interest Groups
  3. C++ Gurus
  4. Trouble with external libraries in a custom path

Trouble with external libraries in a custom path

Scheduled Pinned Locked Moved Solved C++ Gurus
2 Posts 1 Posters 279 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • mrdebugM Offline
    mrdebugM Offline
    mrdebug
    wrote on last edited by mrdebug
    #1

    I have an application called Test01 that uses a library called libtesseract.so
    In order to use that library placed in a custom path, in the .pro file I have:

    unix:!mac {
      LIBS += -Wl,-rpath=\\\$$ORIGIN/libs
    }
    LIBS += libs/libtesseract.so.3.0.5
    

    In the qt.conf file I have

    [Paths]
    Plugins=plugins
    Libraries=libs
    

    That works in Debian 10 but not in Debian 11.
    In Debian 11 I have

    ldd Test01 | grep tess
            libtesseract.so.3.0.5 => not found
    

    That behaviour it is not for all the libraries but only for someone.
    For example opencv* or poco* libraries don't have that problem.
    What can I do to resolve the problem?

    Need programmers to hire?
    www.labcsp.com
    www.denisgottardello.it
    GMT+1
    Skype: mrdebug

    1 Reply Last reply
    0
    • mrdebugM Offline
      mrdebugM Offline
      mrdebug
      wrote on last edited by
      #2

      Solved by changing the objects (.o) dependence sequence and using ldd / patchelf utilities, reviewing the path of the libraries that the executable depens, and the path of the libraries that the libraries depend on.

      Need programmers to hire?
      www.labcsp.com
      www.denisgottardello.it
      GMT+1
      Skype: mrdebug

      1 Reply Last reply
      1

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved