Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Windows + Cmake multiproject template
Forum Updated to NodeBB v4.3 + New Features

Windows + Cmake multiproject template

Scheduled Pinned Locked Moved Solved Qt Creator and other tools
qtcreatorcmakelists.txtwindowscmake
1 Posts 1 Posters 409 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.
  • artwawA Offline
    artwawA Offline
    artwaw
    wrote on last edited by
    #1

    Good morning.

    I switched to Qt 6.2 and cmake some weeks ago and, however bumpy sometimes that friendship is, we get along with cmake.
    But this morning I need to revisit some old tool of mine, designed to work on Windows only, so I thought "why not convert it from qmake?". Usually I don't have a problem with that, I just write cmakelists file by hand looking at the .pro file and done.

    But this project is good old multidir one, simple as can be. But somewhat problematic. The .pro file goes:

    TEMPLATE = subdirs
    
    SUBDIRS += \
        NameOfMyTool \
        icmp
    
    DISTFILES += \
        README.md \
        Doxyfile
    

    (the tool itself is a library named icmp and the tool itself, it is simple connectivity tester for my users using Windows, it performs several network tests with visual gui, icmp library is just a wrapper around WinAPI calls)

    So according to the cmake docs this should be straightforward as add_subdirectory() and so on, after writing cmake lists for library and the executable but I wanted to see how Qt does that - so I started to create new multi project in QtCreator (5.0.3) but it resulted in the new qmake project? With single project I am given a choice between qmake/cmake.

    1. is this a bug or a feature?
    2. what is the QtCreator template for this use case - is it just regular cmake grammar or anything specific?

    I am using, in this case, Qt 6.2.1/MinGW 8 + Windows 10/11, cmake from Qt installation.

    Many thanks in advance,
    Artur

    For more information please re-read.

    Kind Regards,
    Artur

    1 Reply Last reply
    0
    • artwawA artwaw 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