Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Qt Creator debugging static lib
Forum Updated to NodeBB v4.3 + New Features

Qt Creator debugging static lib

Scheduled Pinned Locked Moved General and Desktop
19 Posts 5 Posters 10.3k Views 1 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.
  • M Offline
    M Offline
    mirswith
    wrote on last edited by
    #10

    Shouldn't it link the static lib though since changes in the static lib occurred?

    -=ben

    1 Reply Last reply
    0
    • G Offline
      G Offline
      goetz
      wrote on last edited by
      #11

      only if you add to your .pro file:

      @
      PRE_TARGETDEPS = ../path/to/your/lib/liba.a
      @

      http://www.catb.org/~esr/faqs/smart-questions.html

      1 Reply Last reply
      0
      • M Offline
        M Offline
        mirswith
        wrote on last edited by
        #12

        AHHH.. THANK YOU! That is the bit of magic that I was missing. :D One would think that check marking the project as a Dependency in the Projects setting would accomplish this, but I am sure that would be WAY to easy! ;)

        -=ben

        1 Reply Last reply
        0
        • G Offline
          G Offline
          goetz
          wrote on last edited by
          #13

          The dependency in the project configuration basically influences the build order (that's one thing that Creator handles itself). Without the PRE_TARGETDEPS (or one of its friends), the lib is not in the dependency list of qmake (and subsequently of the Makefile) and so none of the tools cares if it changed.

          http://www.catb.org/~esr/faqs/smart-questions.html

          1 Reply Last reply
          0
          • T Offline
            T Offline
            tobias.hunger
            wrote on last edited by
            #14

            mirswith: The inter-project dependencies have severe limitations. In fact we discussed to remove them again...

            Please use your build system to link to sub-projects together. All of them provide means to add proper dependency tracking between (sub-)projects. We do not want to introduce a similar logic into creator itself: It would be prone to errors, hardly tested and will require the developer to understand a new set of dependency logics in addition to the one already required by the build system.

            1 Reply Last reply
            0
            • G Offline
              G Offline
              goetz
              wrote on last edited by
              #15

              Tobias, but there will remain a configuration option to set the build order in Qt Creator?

              http://www.catb.org/~esr/faqs/smart-questions.html

              1 Reply Last reply
              0
              • T Offline
                T Offline
                tobias.hunger
                wrote on last edited by
                #16

                Volker: We only talked about it and did not change any code.

                1 Reply Last reply
                0
                • G Offline
                  G Offline
                  goetz
                  wrote on last edited by
                  #17

                  Thanks Tobias for clarification. I like the dependency tool, but it would be sufficient for my use cases to set the build order. So, at least this should remain.

                  http://www.catb.org/~esr/faqs/smart-questions.html

                  1 Reply Last reply
                  0
                  • T Offline
                    T Offline
                    tobias.hunger
                    wrote on last edited by
                    #18

                    mirswith: You could have actually used Qt Creators wizard to add a library. That does add the required qmake magic:-) Another hidden gem in Qt Creator...

                    Open the .pro-file you want to add a library to. Right click anywhere in the editor and select "Add library" from the context menu to bring up a wizard to help with the task.

                    Yes, that is very well hidden, I only found this by accident right now. I'll open a issue with our bug tracker to make that way more visible.

                    1 Reply Last reply
                    0
                    • D Offline
                      D Offline
                      dialingo
                      wrote on last edited by
                      #19

                      better use cmake for real projects.
                      cmake rebuilds all libs and dependent executables when a source file changes. In qmake you need to specify dependencies and I found this all very fragile. The trolls continue to use qmake because of requirements you probably do not have, for example running on esoteric platforms, continuing backwards compatibility, etc.
                      Give cmake a try!

                      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