Skip to content

Commit c71eb5d

Browse files
[cpp-qt-client] Fix CMakeLists.txt.mustache and CMakeLists.txt for Qt5 (fix #17712) (#17721)
* [cpp-qt-client] Fix CMakeLists.txt.mustache and CMakeLists.txt for Qt5 (fix #17712) * Restore CMAKE_AUTOMOC
1 parent 0202bac commit c71eb5d

2 files changed

Lines changed: 6 additions & 0 deletions

File tree

modules/openapi-generator/src/main/resources/cpp-qt-client/CMakeLists.txt.mustache

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@ cmake_minimum_required(VERSION 3.5)
22

33
project({{{packageName}}})
44

5+
set(CMAKE_AUTOMOC ON)
6+
7+
find_package(QT NAMES Qt6 Qt5 REQUIRED COMPONENTS Core Network Gui)
58
find_package(Qt${QT_VERSION_MAJOR} REQUIRED COMPONENTS Core Network Gui)
69

710
include(GNUInstallDirs)

samples/client/petstore/cpp-qt/client/CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@ cmake_minimum_required(VERSION 3.5)
22

33
project(CppQtPetstoreClient)
44

5+
set(CMAKE_AUTOMOC ON)
6+
7+
find_package(QT NAMES Qt6 Qt5 REQUIRED COMPONENTS Core Network Gui)
58
find_package(Qt${QT_VERSION_MAJOR} REQUIRED COMPONENTS Core Network Gui)
69

710
include(GNUInstallDirs)

0 commit comments

Comments
 (0)