Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Library ABI compatibility
Forum Updated to NodeBB v4.3 + New Features

Library ABI compatibility

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
linux makefilelibrary
9 Posts 3 Posters 2.7k 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.
  • P Offline
    P Offline
    Pppp
    wrote on last edited by Pppp
    #1

    Hi,

    can anyone give me the picture on how to ensure qt picks up the right flags when I need to link a non-qt linux makefile project against a qt compiled lib.

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

      Hi and welcome to devnet,

      What kind of ABI to you have in mind ?

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

      1 Reply Last reply
      0
      • P Offline
        P Offline
        Pppp
        wrote on last edited by
        #3

        Both the project and library are C++, so name-mangling besides compiler flags affecting e.g. struct alignment etc. are at issue.

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

          Then it's up to you to ensure you are using the right stuff.

          If you are using your distribution provided Qt and development libraries, you won't have any problem. If using custom built libraries, then you should ensure that everything is using the same flags correctly.

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

          1 Reply Last reply
          3
          • P Offline
            P Offline
            Pppp
            wrote on last edited by Pppp
            #5

            The project using the custom qt lib seems to also compile qmake itself. This looks a bit circumvent to me - is this really necessary or can you e.g. take the flags and just generate a .pro file?

            aha_1980A 1 Reply Last reply
            0
            • P Pppp

              The project using the custom qt lib seems to also compile qmake itself. This looks a bit circumvent to me - is this really necessary or can you e.g. take the flags and just generate a .pro file?

              aha_1980A Offline
              aha_1980A Offline
              aha_1980
              Lifetime Qt Champion
              wrote on last edited by
              #6

              Hi @Pppp,

              Your description is a bit vague, can you get more specific?

              You only need to compile qmake yourself if you build Qt from source code, e.g. if you cross compile for an embedded system. Otherwise using the prebuild binaries is just fine.

              And you don't even need QMake to build a Qt-based program or library; Qbs and CMake are used often for this task also. I've even seen projects with handcrafted Makefiles.

              Regards

              Qt has to stay free or it will die.

              1 Reply Last reply
              2
              • P Offline
                P Offline
                Pppp
                wrote on last edited by Pppp
                #7

                Sorry, I didn't mention the project is cross compile, targeting embedded.
                So I understand it's usual to compile the target-specific cross-compiler on the host platform, but is that really necessary for the makemake (qmake, not the dwarf planet) also?

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

                  What are you using for cross-compilation ?

                  It sounds strange that you have to re-build Qt each time you want to build your project.

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

                  1 Reply Last reply
                  1
                  • P Offline
                    P Offline
                    Pppp
                    wrote on last edited by Pppp
                    #9

                    gcc...
                    So if I got that right, you just configure and manually run the same qmake binary to output for different platforms and then use the generated makefile in the parent makefile project or optionally one step earlier call qmake from the script (but generally not still one step earlier and...)?

                    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