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. Linking third party library for debug and release

Linking third party library for debug and release

Scheduled Pinned Locked Moved Unsolved General and Desktop
3 Posts 3 Posters 450 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.
  • Y Offline
    Y Offline
    yugosonegi
    wrote on last edited by
    #1

    I was wondering, how to configure the pro file to compile different versions of a third party library. I have a library that has a 32bit version in release and debug version and a 64bit verrsion in release and debug version.
    How to do that?

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

      Hi

      something like

      CONFIG += 32bit // or 64

      CONFIG(32bit) {
      LIBS += -L<path to 32bit libraries>
      }
      CONFIG(64bit) {
      LIBS += -L<path to 64bit libraries>
      }

      or

      contains(QT_ARCH, i386) {
      message("32-bit")
      } else {
      message("64-bit")
      }

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

        Hi,

        To add to @mrjj

        CONFIG(debug, debug|release) {
        # debug config
        }
        

        and

        CONFIG(release, debug|release) {
        # release config
        }
        

        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

        • Login

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