Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. [QT LTS 6.5.2] - Cmake build does not install include files into prefix path
Forum Update on Tuesday, May 27th 2025

[QT LTS 6.5.2] - Cmake build does not install include files into prefix path

Scheduled Pinned Locked Moved Solved Installation and Deployment
5 Posts 2 Posters 932 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.
  • M Offline
    M Offline
    morphax2k
    wrote on last edited by
    #1

    Hey folks,

    since ever I'm compiling my QT LTS versions from Source and installing with help of --prefix. My software is using those installed libraries and includes during compilation, linking and run. I only use the QtBase package as this is absolutely enough for my case.

    Now comes my problem, I'm trying to compile the latest QT LTS 6.5.2, all fine no issue with that. Also the installation succeeded but it misses all include files.

    Here are the steps I do for years:

    • Downloading the QtBase package
    $ wget http://download.qt.io/archive/qt/6.5/6.5.2/submodules/qtbase-everywhere-src-6.5.2.tar.xz
    
    • Call configure after extracting the tarball as followed
    $ ./configure -platform linux-g++-64 -prefix /services/lib/qt_6.5.2-0 -release -no-opengl -nomake tests -nomake examples -confirm-license -opensource
    
    • Compile the QtBase Sources
    $ cmake --build . --parallel
    
    • And finally install it in my defined target folder /services/lib/qt_6.5.2-0
    cmake --install .
    

    If I now check the installed data I'm missing all include files. As an example take the QString class which requires the qstring.h. In the --prefix path you do not find it:

    $ ls qt_6.5.2-0/include/QtCore/QString
    qt_6.5.2-0/include/QtCore/QString
    
    $ cat qt_6.5.2-0/include/QtCore/QString
    #include "qstring.h"
    
    $ ls qt_6.5.2-0/include/QtCore/*.h
    qt_6.5.2-0/include/QtCore/qtcoreversion.h
    

    The include file exists in source folder but was not installed into defined --prefix path.

    find qtbase-everywhere-src-6.5.2/ -name qstring.h
    qtbase-everywhere-src-6.5.2/src/corelib/text/qstring.h
    qtbase-everywhere-src-6.5.2/include/QtCore/qstring.h
    

    This issue exists for all other classes as well. Did I missed something? Any ideas welcome.

    Thanks in advance
    Sven

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

      Hi and welcome to devnet,

      It might be related to the fact that you are doing an in source build. At the very least you should create a build folder and call configure from within it. I usually do a completely out of source build so I am sure I don't have any stray file that might wreak havoc in there.

      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
      • M Offline
        M Offline
        morphax2k
        wrote on last edited by morphax2k
        #3

        Hello and good morning @SGaist,

        thanks for your feedback. I tried your proposal and build the QT Sources from a seperate build folder. It's the very same picture: Configuring and build no issue, the installation succeed into my defined -prefix path, but still not as expected. The include files are not released into target folder.

        $ find /services/lib/qt_6.5.2-0/ -name qstring.h
        !!! NO RESULT
        

        I repeated the same steps with QT LTS 6.2.4, did not observed a problem. All as expected and complete. The include files are all present in target folder:

        $ find /services/lib/qt_6.2.4-0/ -name qstring.h
        /services/lib/qt_6.2.4/include/QtCore/qstring.h
        

        The difference is clearly visible with simple counting
        QT 6.5

        $ find /services/lib/qt_6.5.2-0/ -name *.h | wc -l
        901
        

        vs. QT 6.2

        $ find /services/lib/qt_6.2.4-0/ -name *.h | wc -l
        2006
        
        SGaistS 1 Reply Last reply
        0
        • M morphax2k

          Hello and good morning @SGaist,

          thanks for your feedback. I tried your proposal and build the QT Sources from a seperate build folder. It's the very same picture: Configuring and build no issue, the installation succeed into my defined -prefix path, but still not as expected. The include files are not released into target folder.

          $ find /services/lib/qt_6.5.2-0/ -name qstring.h
          !!! NO RESULT
          

          I repeated the same steps with QT LTS 6.2.4, did not observed a problem. All as expected and complete. The include files are all present in target folder:

          $ find /services/lib/qt_6.2.4-0/ -name qstring.h
          /services/lib/qt_6.2.4/include/QtCore/qstring.h
          

          The difference is clearly visible with simple counting
          QT 6.5

          $ find /services/lib/qt_6.5.2-0/ -name *.h | wc -l
          901
          

          vs. QT 6.2

          $ find /services/lib/qt_6.2.4-0/ -name *.h | wc -l
          2006
          
          SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          You may have found a bug then :-)
          Did you already check the bug report system ?

          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
          • M Offline
            M Offline
            morphax2k
            wrote on last edited by
            #5

            As proposed, I've created a bug ticket
            https://bugreports.qt.io/browse/QTBUG-116137

            Thanks for the support.

            1 Reply Last reply
            1
            • M morphax2k has marked this topic as solved on

            • Login

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