Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Managing .so and .pro references

Managing .so and .pro references

Scheduled Pinned Locked Moved Unsolved Qt Creator and other tools
9 Posts 3 Posters 2.1k Views 2 Watching
  • 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.
  • L Offline
    L Offline
    lfxciii
    wrote on last edited by A Former User
    #1

    Hi

    coming from an ide such as visual studio, it seem my biggest challenge is to manage the project lib/.so files.

    I am building a layered application but there is always some .so file needed by another .so file and I cant seem to get it working.
    is there any best practice or guideline I can use to sort this type of stuff out?

    any help appreciated, thanks

    1 Reply Last reply
    0
    • JohanSoloJ Offline
      JohanSoloJ Offline
      JohanSolo
      wrote on last edited by
      #2

      Hi,

      could you elaborate what you mean with

      I cant seem to get it working.

      Adding a dependency in a pro file is made using LIBS += in pro file. Are you trying to build a project consisting of multiple libraries?

      `They did not know it was impossible, so they did it.'
      -- Mark Twain

      L 1 Reply Last reply
      0
      • SGaistS Offline
        SGaistS Offline
        SGaist
        Lifetime Qt Champion
        wrote on last edited by
        #3

        Hi,

        Depending on your target platform, pkg_config can be a good option to alleviate that kind of problem.

        Otherwise tools like ldd or Dependency Walker can help you identify dependencies.

        At last, the documentation of the library you are using should also give you that kind of information.

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        L 1 Reply Last reply
        0
        • JohanSoloJ JohanSolo

          Hi,

          could you elaborate what you mean with

          I cant seem to get it working.

          Adding a dependency in a pro file is made using LIBS += in pro file. Are you trying to build a project consisting of multiple libraries?

          L Offline
          L Offline
          lfxciii
          wrote on last edited by lfxciii
          #4

          @JohanSolo yes i am trying to build a project based on multiple subprojects. I get .so files missing, so i copy it to folders manually but then I get vtable erorrs upon building, its really annoying. so i add the .so files to my project using the add lib function, its an internal lib as its in the same project structure, but it cant seem to find the .lib being referenced.

          cant seem to get it working means that everytime I build i get errors, .so missing, vtable etc....

          1 Reply Last reply
          0
          • SGaistS SGaist

            Hi,

            Depending on your target platform, pkg_config can be a good option to alleviate that kind of problem.

            Otherwise tools like ldd or Dependency Walker can help you identify dependencies.

            At last, the documentation of the library you are using should also give you that kind of information.

            L Offline
            L Offline
            lfxciii
            wrote on last edited by
            #5

            @SGaist my platform is Linux, its not an external library, its all internal libs in the same project

            1 Reply Last reply
            0
            • JohanSoloJ Offline
              JohanSoloJ Offline
              JohanSolo
              wrote on last edited by
              #6

              I think SUBDIR template is your friend, and ordered will take care of the build order.
              On Linux, there is no need to copy libraries, qmake takes care of setting the rpath for you.

              `They did not know it was impossible, so they did it.'
              -- Mark Twain

              L 1 Reply Last reply
              0
              • JohanSoloJ JohanSolo

                I think SUBDIR template is your friend, and ordered will take care of the build order.
                On Linux, there is no need to copy libraries, qmake takes care of setting the rpath for you.

                L Offline
                L Offline
                lfxciii
                wrote on last edited by
                #7

                @JohanSolo i am using the subdirs template.

                i got it sorted out thanks for your help.

                1 Reply Last reply
                0
                • SGaistS Offline
                  SGaistS Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on last edited by
                  #8

                  I'd recommend to avoid ordered. There's this very good article about setting up dependencies properly in a subdirs project.

                  Interested in AI ? www.idiap.ch
                  Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                  JohanSoloJ 1 Reply Last reply
                  1
                  • SGaistS SGaist

                    I'd recommend to avoid ordered. There's this very good article about setting up dependencies properly in a subdirs project.

                    JohanSoloJ Offline
                    JohanSoloJ Offline
                    JohanSolo
                    wrote on last edited by
                    #9

                    @SGaist said in managing .so and .pro references:

                    I'd recommend to avoid ordered. There's this very good article about setting up dependencies properly in a subdirs project.

                    Thanks for the hint!

                    `They did not know it was impossible, so they did it.'
                    -- Mark Twain

                    1 Reply Last reply
                    0

                    • Login

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