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. Static build xmpp
Forum Updated to NodeBB v4.3 + New Features

Static build xmpp

Scheduled Pinned Locked Moved Unsolved General and Desktop
13 Posts 2 Posters 3.8k 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.
  • RIVOPICOR Offline
    RIVOPICOR Offline
    RIVOPICO
    wrote on last edited by RIVOPICO
    #1

    Hi i am trying to do static build with xmpp, i used this command:
    nmake qxmpp.pro -DQXMPP_STATIC

    page:
    https://github.com/qxmpp-project/qxmpp

    But anyways doesnt work and when i do static build with my static compilation and show me this message:
    Qdnslookup require a Qcoreapplication
    and take me obviously xmpp.dll

    So please someone with more experience or know more about this library. thx.

    1 Reply Last reply
    0
    • VRoninV Offline
      VRoninV Offline
      VRonin
      wrote on last edited by VRonin
      #2

      from the page you linked: https://github.com/qxmpp-project/qxmpp#building-qxmpp

      You can pass the following arguments to qmake:
      QXMPP_LIBRARY_TYPE=staticlib to build a static version of QXmpp

      also you normally do not use make on the pro file directly but use qmake to generate the makefile

      "La mort n'est rien, mais vivre vaincu et sans gloire, c'est mourir tous les jours"
      ~Napoleon Bonaparte

      On a crusade to banish setIndexWidget() from the holy land of Qt

      1 Reply Last reply
      0
      • RIVOPICOR Offline
        RIVOPICOR Offline
        RIVOPICO
        wrote on last edited by RIVOPICO
        #3

        But how i add thsi because i tried to put nmake qxmpp.pro -QXMPP_LIBRARY_TYPE=staticlib and show me error. i am using msvc2013. Show me this error : qxmpp.pro(2) : U1035: error de sintaxis : se esperaba el separador ':' o '='
        Stop.
        So i think i need to include of other way.

        1 Reply Last reply
        0
        • VRoninV Offline
          VRoninV Offline
          VRonin
          wrote on last edited by
          #4

          as mentoned above, you need to run qmake with that option, not nmake and no -

          "La mort n'est rien, mais vivre vaincu et sans gloire, c'est mourir tous les jours"
          ~Napoleon Bonaparte

          On a crusade to banish setIndexWidget() from the holy land of Qt

          1 Reply Last reply
          0
          • RIVOPICOR Offline
            RIVOPICOR Offline
            RIVOPICO
            wrote on last edited by
            #5
            This post is deleted!
            1 Reply Last reply
            0
            • VRoninV Offline
              VRoninV Offline
              VRonin
              wrote on last edited by
              #6

              you need to run qtenv2.bat something like "C:\Qt\5.7\msvc2013\bin\qtenv2.bat"

              "La mort n'est rien, mais vivre vaincu et sans gloire, c'est mourir tous les jours"
              ~Napoleon Bonaparte

              On a crusade to banish setIndexWidget() from the holy land of Qt

              1 Reply Last reply
              1
              • RIVOPICOR Offline
                RIVOPICOR Offline
                RIVOPICO
                wrote on last edited by
                #7

                and when he say this: Note: by default QXmpp is built as a shared library. If you decide to build a static library instead, you will need to pass -DQXMPP_STATIC when building your programs against QXmpp.

                I need to include this too? with qmake or only build all sorry and thx

                1 Reply Last reply
                0
                • VRoninV Offline
                  VRoninV Offline
                  VRonin
                  wrote on last edited by
                  #8

                  first you need the library, when you use it in your application then you need to include that definition, not when you build the library itself

                  "La mort n'est rien, mais vivre vaincu et sans gloire, c'est mourir tous les jours"
                  ~Napoleon Bonaparte

                  On a crusade to banish setIndexWidget() from the holy land of Qt

                  1 Reply Last reply
                  1
                  • RIVOPICOR Offline
                    RIVOPICOR Offline
                    RIVOPICO
                    wrote on last edited by RIVOPICO
                    #9

                    Ok the library works very well but i now want to include to my project you can finish me saying how? You said that i need to include this? -DQXMPP_STATIC in my project thanks in advance.

                    1 Reply Last reply
                    0
                    • VRoninV Offline
                      VRoninV Offline
                      VRonin
                      wrote on last edited by VRonin
                      #10

                      in your .pro file you'll need to add DEFINES += QXMPP_STATIC the rest is just the usual including of 3rd party libraries:

                      General: http://doc.qt.io/qt-5/third-party-libraries.html
                      With Qt Creator: http://doc.qt.io/qtcreator/creator-project-qmake-libraries.html

                      "La mort n'est rien, mais vivre vaincu et sans gloire, c'est mourir tous les jours"
                      ~Napoleon Bonaparte

                      On a crusade to banish setIndexWidget() from the holy land of Qt

                      1 Reply Last reply
                      1
                      • RIVOPICOR Offline
                        RIVOPICOR Offline
                        RIVOPICO
                        wrote on last edited by
                        #11

                        so with this way i can add libraries to my Project. any library. Ok i have question with qtcreator where is the menĂº to add these libraries. sorry and thx

                        1 Reply Last reply
                        0
                        • VRoninV Offline
                          VRoninV Offline
                          VRonin
                          wrote on last edited by
                          #12

                          from http://doc.qt.io/qtcreator/creator-project-qmake-libraries.html#to-add-libraries

                          In the Projects pane, right-click the project name to open the context menu and select Add Library.
                          Follow the instructions of the wizard

                          "La mort n'est rien, mais vivre vaincu et sans gloire, c'est mourir tous les jours"
                          ~Napoleon Bonaparte

                          On a crusade to banish setIndexWidget() from the holy land of Qt

                          1 Reply Last reply
                          0
                          • RIVOPICOR Offline
                            RIVOPICOR Offline
                            RIVOPICO
                            wrote on last edited by
                            #13

                            Ok so for adding one library i only take the steps i put if it's static or dynamic and add to my Project ok thx alot

                            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