Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Modular library and its paths
Qt 6.12 LTS is out! See what's new in the release blog

Modular library and its paths

Scheduled Pinned Locked Moved Unsolved General and Desktop
8 Posts 2 Posters 1.0k 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.
  • A Offline
    A Offline
    AndrzejB
    wrote on last edited by AndrzejB
    #1

    Library libqxt with my small changes is here: https://github.com/borneq/libqxt

    is compilable from batch, but examples still not compilable.
    I have added to examples pro "QT += core gui" but is is not enough:
    in displaysettingsdialog.h file is #include <QxtScreen>
    QxtScreen is in directory libqxt\include\QxtWidgets
    but is invisible
    https://github.com/borneq/libqxt/blob/dc5798cfecbc454c6486969ed778cebf3d2bb5a4/examples/displaysettings/displaysettingsdialog.h#L4

    What are rules to add module directories

    1 Reply Last reply
    0
    • sierdzioS Offline
      sierdzioS Offline
      sierdzio
      Moderators
      wrote on last edited by
      #2

      You need QT += core gui widgets to get QtWidgets module.

      And to use <SomeHeader> you need to point qmake to it's parent directory using INCLUDEPATH.

      (Z(:^

      1 Reply Last reply
      0
      • A Offline
        A Offline
        AndrzejB
        wrote on last edited by
        #3

        Problems:
        I add full paths and even add qxtletterboxwidget.cpp with path to my project, but is error:

        :-1: error: No rule to make target 'QxtLetterBoxWidget', needed by 'ui_displaysettingsdialog.h'.  Stop.
        

        My pro is:

        QT  += core gui widgets
        TEMPLATE = app
        TARGET = displaysettings
        DEPENDPATH += .
        INCLUDEPATH += .
        INCLUDEPATH += d:/wazne/github_my/libqxt/include
        INCLUDEPATH += d:/wazne/github_my/libqxt/src/widgets
        INCLUDEPATH += d:/wazne/github_my/libqxt/src/core
        CONFIG += qxt
        QXT += core gui widgets
        
        # Input
        FORMS += displaysettingsdialog.ui
        HEADERS += displaysettingsdialog.h
        SOURCES += displaysettingsdialog.cpp main.cpp
        SOURCES += d:/wazne/github_my/libqxt/src/widgets/qxtletterboxwidget.cpp
        
        1 Reply Last reply
        0
        • sierdzioS Offline
          sierdzioS Offline
          sierdzio
          Moderators
          wrote on last edited by
          #4

          That's wrong. Qxt is a library, you should have a precompiled dll or lib package. Then use INCLUDEPATH to point Qt to the includes, and LIBS to point it to the libraries.

          What you did here is a manual compilation of qxtletterboxwidget.cpp which won't work.

          (Z(:^

          1 Reply Last reply
          1
          • A Offline
            A Offline
            AndrzejB
            wrote on last edited by
            #5

            Problem is probably with ui, I not used it previous.
            I have

            LIBS += d:/wazne/github_my/libqxt/lib -lQxtCore -lQxtWidgets
            

            but still the same error.

            1 Reply Last reply
            0
            • sierdzioS Offline
              sierdzioS Offline
              sierdzio
              Moderators
              wrote on last edited by
              #6

              @AndrzejB said in Modular library and its paths:

              SOURCES += d:/wazne/github_my/libqxt/src/widgets/qxtletterboxwidget.cpp

              Remove that line from .pro file.

              (Z(:^

              1 Reply Last reply
              0
              • A Offline
                A Offline
                AndrzejB
                wrote on last edited by
                #7

                Removed, instead this is LIBS.

                1 Reply Last reply
                0
                • sierdzioS Offline
                  sierdzioS Offline
                  sierdzio
                  Moderators
                  wrote on last edited by
                  #8

                  Should work, then. Make a full rebuild.

                  • Is there anything special in "ui_displaysettingsdialog.h"?
                  • Have you checked if file "QxtScreen" is there in on of the INCLUDEPATHs you added?

                  (Z(:^

                  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
                  • Unsolved