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. Quazip not building up: Throwing "Undefined symbols for architecture x86_64"
Qt 6.11 is out! See what's new in the release blog

Quazip not building up: Throwing "Undefined symbols for architecture x86_64"

Scheduled Pinned Locked Moved General and Desktop
14 Posts 10 Posters 11.5k 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.
  • G Offline
    G Offline
    goetz
    wrote on last edited by
    #3

    The error means that the linker is trying to find the code for some symbols, but fails to do so. The lib (zlib) is installed on your system, otherwise the compiler would have bailed out already (due to missing include files). Fortunately the solution is easy: The developers forgot to include linkage to zlib in the .pro file, so just add to the file mvim quazip/quazip.pro the following line in the unix scope:

    @
    LIBS += -lz
    @

    The complete snippet that works for me (I had the very same errors on a 10.6 Mac box) is:

    @
    unix:!symbian {
    headers.path=$$PREFIX/include/quazip
    headers.files=$$HEADERS
    target.path=$$PREFIX/lib
    INSTALLS += headers target
    // the following line needs to be added
    LIBS += -lz

    OBJECTS_DIR=.obj
    MOC_DIR=.moc

    }
    @

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

    1 Reply Last reply
    1
    • C Offline
      C Offline
      continuata
      wrote on last edited by
      #4

      Volker, you just saved me after a weekend of pain ... was having exactly the same issue, couldn't figure it out.

      Was even considering completely different approaches ... thank you so much!

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

        You're welcome - that's what these forums have been made for :-)

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

        1 Reply Last reply
        0
        • H Offline
          H Offline
          Holly.Deng
          wrote on last edited by
          #6

          Hi,Volker. I'm a novice in using Qt creator. I have the same problem which confused me for two days. Thank you so much for your answer. Thank you !

          1 Reply Last reply
          0
          • D Offline
            D Offline
            drpclind
            wrote on last edited by
            #7

            Thanks, Volker, for the information about needing to add "LIBS += -lz". That worked perfectly, and saved me a lot of time!

            1 Reply Last reply
            0
            • Y Offline
              Y Offline
              Yash
              wrote on last edited by
              #8

              Thank you Volker

              http://kineticwing.com : Web IDE, QSS Editor
              http://speedovation.com : Development Lab

              1 Reply Last reply
              0
              • K Offline
                K Offline
                karlox
                wrote on last edited by
                #9

                Thank you Wolker this help me too. I'm fresh on Mac and some erro messages get me on the wrong way

                1 Reply Last reply
                0
                • K Offline
                  K Offline
                  karlox
                  wrote on last edited by
                  #10

                  Thank you Wolker this help me too. I'm fresh on Mac and some erro messages get me on the wrong way

                  1 Reply Last reply
                  0
                  • L Offline
                    L Offline
                    Leanor
                    wrote on last edited by
                    #11

                    Hi , please anybody can help me, how to solve this issue when I'm using CMake and not qmake?

                    jsulmJ 1 Reply Last reply
                    0
                    • L Leanor

                      Hi , please anybody can help me, how to solve this issue when I'm using CMake and not qmake?

                      jsulmJ Offline
                      jsulmJ Offline
                      jsulm
                      Lifetime Qt Champion
                      wrote on last edited by
                      #12

                      @Leanor This is quite old thread. Please provide more information about your situation:

                      • What OS?
                      • What Qt version?
                      • What exact error messages do you get?

                      https://forum.qt.io/topic/113070/qt-code-of-conduct

                      L 1 Reply Last reply
                      0
                      • jsulmJ jsulm

                        @Leanor This is quite old thread. Please provide more information about your situation:

                        • What OS?
                        • What Qt version?
                        • What exact error messages do you get?
                        L Offline
                        L Offline
                        Leanor
                        wrote on last edited by
                        #13
                        This post is deleted!
                        jsulmJ 1 Reply Last reply
                        0
                        • L Leanor

                          This post is deleted!

                          jsulmJ Offline
                          jsulmJ Offline
                          jsulm
                          Lifetime Qt Champion
                          wrote on last edited by
                          #14

                          @Leanor Seems like you do not link the quazip libs.
                          Show your pro file.

                          Also

                          #include <QuaZip-Qt5-1.3/quazip/quazip.h>
                          

                          this should look differently:

                          #include <quazip/quazip.h>
                          

                          just add QuaZip-Qt5-1.3 as include path in your pro file.

                          https://forum.qt.io/topic/113070/qt-code-of-conduct

                          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