summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.gitignore16
-rw-r--r--CMakeLists.txt96
-rw-r--r--bin/qt-cmake.bat.in1
-rwxr-xr-xbin/qt-cmake.in3
-rw-r--r--cmake/3rdparty/extra-cmake-modules/COPYING-CMAKE-SCRIPTS22
-rw-r--r--cmake/3rdparty/extra-cmake-modules/find-modules/ECMFindModuleHelpersStub.cmake1
-rw-r--r--cmake/3rdparty/extra-cmake-modules/find-modules/FindEGL.cmake172
-rw-r--r--cmake/3rdparty/extra-cmake-modules/find-modules/FindGLIB2.cmake101
-rw-r--r--cmake/3rdparty/extra-cmake-modules/find-modules/FindWayland.cmake143
-rw-r--r--cmake/3rdparty/extra-cmake-modules/find-modules/FindWaylandScanner.cmake167
-rw-r--r--cmake/3rdparty/extra-cmake-modules/find-modules/FindX11_XCB.cmake118
-rw-r--r--cmake/3rdparty/extra-cmake-modules/find-modules/FindXCB.cmake201
-rw-r--r--cmake/3rdparty/extra-cmake-modules/modules/ECMEnableSanitizers.cmake173
-rw-r--r--cmake/3rdparty/extra-cmake-modules/modules/ECMFindModuleHelpers.cmake297
-rw-r--r--cmake/3rdparty/extra-cmake-modules/qt_attribution.json15
-rw-r--r--cmake/3rdparty/kwin/COPYING-CMAKE-SCRIPTS22
-rw-r--r--cmake/3rdparty/kwin/FindLibdrm.cmake126
-rw-r--r--cmake/3rdparty/kwin/FindLibinput.cmake125
-rw-r--r--cmake/3rdparty/kwin/FindXKB.cmake101
-rw-r--r--cmake/3rdparty/kwin/Findgbm.cmake125
-rw-r--r--cmake/3rdparty/kwin/qt_attribution.json17
-rw-r--r--cmake/3rdpartyConfig.cmake.in15
-rw-r--r--cmake/FindATSPI2.cmake7
-rw-r--r--cmake/FindAtomic.cmake44
-rw-r--r--cmake/FindCups.cmake98
-rw-r--r--cmake/FindDB2.cmake59
-rw-r--r--cmake/FindDirectFB.cmake7
-rw-r--r--cmake/FindGLESv2.cmake72
-rw-r--r--cmake/FindGSSAPI.cmake39
-rw-r--r--cmake/FindGTK3.cmake7
-rw-r--r--cmake/FindLibproxy.cmake7
-rw-r--r--cmake/FindLibsystemd.cmake7
-rw-r--r--cmake/FindLibudev.cmake7
-rw-r--r--cmake/FindMtdev.cmake7
-rw-r--r--cmake/FindMySQL.cmake50
-rw-r--r--cmake/FindOracle.cmake48
-rw-r--r--cmake/FindPPS.cmake19
-rw-r--r--cmake/FindSlog2.cmake19
-rw-r--r--cmake/FindTslib.cmake7
-rw-r--r--cmake/FindWrapDBus1.cmake35
-rw-r--r--cmake/FindWrapDoubleConversion.cmake61
-rw-r--r--cmake/FindWrapFreetype.cmake33
-rw-r--r--cmake/FindWrapHarfbuzz.cmake45
-rw-r--r--cmake/FindWrapPCRE2.cmake23
-rw-r--r--cmake/FindWrapRt.cmake34
-rw-r--r--cmake/FindXKB_COMMON_X11.cmake7
-rw-r--r--cmake/FindXRender.cmake11
-rw-r--r--cmake/FindZSTD.cmake50
-rw-r--r--cmake/Finddouble-conversion.cmake32
-rw-r--r--cmake/ModuleDescription.json.in11
-rw-r--r--cmake/QtAutoDetect.cmake161
-rw-r--r--cmake/QtBaseCMakeTesting.cmake9
-rw-r--r--cmake/QtBaseConfigureTests.cmake192
-rw-r--r--cmake/QtBaseGlobalTargets.cmake267
-rw-r--r--cmake/QtBuild.cmake4055
-rw-r--r--cmake/QtBuildInformation.cmake35
-rw-r--r--cmake/QtBuildInternals/QtBuildInternalsAndroid.cmake217
-rw-r--r--cmake/QtBuildInternals/QtBuildInternalsConfig.cmake237
-rw-r--r--cmake/QtBuildInternalsExtra.cmake.in35
-rw-r--r--cmake/QtCompilerFlags.cmake6
-rw-r--r--cmake/QtCompilerOptimization.cmake123
-rw-r--r--cmake/QtConfig.cmake.in59
-rw-r--r--cmake/QtFeature.cmake760
-rw-r--r--cmake/QtInternalTargets.cmake114
-rw-r--r--cmake/QtModuleConfig.cmake.in46
-rw-r--r--cmake/QtModuleDependencies.cmake.in66
-rw-r--r--cmake/QtModuleToolsConfig.cmake.in17
-rw-r--r--cmake/QtModuleToolsDependencies.cmake.in16
-rw-r--r--cmake/QtModuleToolsVersionlessTargets.cmake.in23
-rw-r--r--cmake/QtPlatformAndroid.cmake378
-rw-r--r--cmake/QtPlatformSupport.cmake81
-rw-r--r--cmake/QtPluginConfig.cmake.in17
-rw-r--r--cmake/QtPluginDependencies.cmake.in42
-rw-r--r--cmake/QtPlugins.cmake.in114
-rw-r--r--cmake/QtPostProcess.cmake376
-rw-r--r--cmake/QtProperties.cmake107
-rw-r--r--cmake/QtResource.cmake.in313
-rw-r--r--cmake/QtSetup.cmake164
-rw-r--r--cmake/QtStandaloneTestsConfig.cmake.in2
-rw-r--r--cmake/QtToolsConfig.cmake.in35
-rw-r--r--cmake/README.md308
-rw-r--r--cmake/qt.toolchain.cmake.in20
-rw-r--r--cmake/tests/CMakeLists.txt48
-rw-r--r--cmake/tests/empty.cpp0
-rw-r--r--cmake/tests/features/CMakeLists.txt42
-rw-r--r--cmake/tests/features/configure.cmake35
-rw-r--r--cmake/tests/features/src/CMakeLists.txt7
-rw-r--r--cmake/tests/main.cpp1
-rw-r--r--cmake/tests/qt_make_output_file/CMakeLists.txt22
-rw-r--r--cmake/tests/test.cmake54
-rw-r--r--coin/instructions/call_cmake.yaml23
-rw-r--r--coin/instructions/cmake_build_and_upload_test_artifacts.yaml29
-rw-r--r--coin/instructions/cmake_cross_compilation.yaml58
-rw-r--r--coin/instructions/cmake_module_build_instructions.yaml46
-rw-r--r--coin/instructions/cmake_qtbase_build_instructions.yaml49
-rw-r--r--coin/instructions/cmake_regular_test_instructions.yaml26
-rw-r--r--coin/instructions/prepare_building_env.yaml202
-rw-r--r--coin/module_config.yaml40
-rw-r--r--config.tests/arch/CMakeLists.txt6
-rw-r--r--config.tests/x86_simd/CMakeLists.txt23
-rwxr-xr-xconfigure208
-rw-r--r--configure.cmake695
-rw-r--r--configure.json11
-rw-r--r--doc/CMakeLists.txt7
-rw-r--r--doc/global/macros.qdocconf1
-rw-r--r--examples/CMakeLists.txt54
-rw-r--r--examples/corelib/CMakeLists.txt10
-rw-r--r--examples/corelib/ipc/CMakeLists.txt14
-rw-r--r--examples/corelib/ipc/localfortuneclient/CMakeLists.txt29
-rw-r--r--examples/corelib/ipc/localfortuneserver/CMakeLists.txt29
-rw-r--r--examples/corelib/ipc/sharedmemory/CMakeLists.txt27
-rw-r--r--examples/corelib/mimetypes/CMakeLists.txt6
-rw-r--r--examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt28
-rw-r--r--examples/corelib/serialization/CMakeLists.txt5
-rw-r--r--examples/corelib/serialization/cbordump/CMakeLists.txt27
-rw-r--r--examples/corelib/serialization/convert/CMakeLists.txt34
-rw-r--r--examples/corelib/serialization/savegame/CMakeLists.txt30
-rw-r--r--examples/corelib/threads/CMakeLists.txt9
-rw-r--r--examples/corelib/threads/mandelbrot/CMakeLists.txt28
-rw-r--r--examples/corelib/threads/queuedcustomtype/CMakeLists.txt29
-rw-r--r--examples/corelib/threads/semaphores/CMakeLists.txt26
-rw-r--r--examples/corelib/threads/waitconditions/CMakeLists.txt26
-rw-r--r--examples/corelib/tools/CMakeLists.txt5
-rw-r--r--examples/corelib/tools/contiguouscache/CMakeLists.txt27
-rw-r--r--examples/corelib/tools/customtype/CMakeLists.txt27
-rw-r--r--examples/corelib/tools/customtypesending/CMakeLists.txt28
-rw-r--r--examples/dbus/CMakeLists.txt13
-rw-r--r--examples/dbus/chat/CMakeLists.txt44
-rw-r--r--examples/dbus/complexpingpong/CMakeLists.txt27
-rw-r--r--examples/dbus/listnames/CMakeLists.txt27
-rw-r--r--examples/dbus/pingpong/CMakeLists.txt28
-rw-r--r--examples/dbus/remotecontrolledcar/CMakeLists.txt4
-rw-r--r--examples/dbus/remotecontrolledcar/car/CMakeLists.txt39
-rw-r--r--examples/dbus/remotecontrolledcar/controller/CMakeLists.txt37
-rw-r--r--examples/embedded/CMakeLists.txt8
-rw-r--r--examples/embedded/digiflip/CMakeLists.txt26
-rw-r--r--examples/embedded/flickable/CMakeLists.txt27
-rw-r--r--examples/embedded/flightinfo/CMakeLists.txt30
-rw-r--r--examples/embedded/lightmaps/CMakeLists.txt31
-rw-r--r--examples/embedded/raycasting/CMakeLists.txt27
-rw-r--r--examples/embedded/styleexample/CMakeLists.txt28
-rw-r--r--examples/gui/CMakeLists.txt8
-rw-r--r--examples/gui/analogclock/CMakeLists.txt33
-rw-r--r--examples/gui/openglwindow/CMakeLists.txt32
-rw-r--r--examples/gui/rasterwindow/CMakeLists.txt32
-rw-r--r--examples/network/CMakeLists.txt45
-rw-r--r--examples/network/bearermonitor/CMakeLists.txt37
-rw-r--r--examples/network/blockingfortuneclient/CMakeLists.txt31
-rw-r--r--examples/network/broadcastreceiver/CMakeLists.txt30
-rw-r--r--examples/network/broadcastsender/CMakeLists.txt30
-rw-r--r--examples/network/dnslookup/CMakeLists.txt29
-rw-r--r--examples/network/download/CMakeLists.txt29
-rw-r--r--examples/network/downloadmanager/CMakeLists.txt31
-rw-r--r--examples/network/fortuneclient/CMakeLists.txt30
-rw-r--r--examples/network/fortuneserver/CMakeLists.txt30
-rw-r--r--examples/network/googlesuggest/CMakeLists.txt31
-rw-r--r--examples/network/http/CMakeLists.txt31
-rw-r--r--examples/network/loopback/CMakeLists.txt30
-rw-r--r--examples/network/multicastreceiver/CMakeLists.txt30
-rw-r--r--examples/network/multicastsender/CMakeLists.txt30
-rw-r--r--examples/network/multistreamclient/CMakeLists.txt34
-rw-r--r--examples/network/multistreamserver/CMakeLists.txt34
-rw-r--r--examples/network/network-chat/CMakeLists.txt34
-rw-r--r--examples/network/securesocketclient/CMakeLists.txt33
-rw-r--r--examples/network/secureudpclient/CMakeLists.txt32
-rw-r--r--examples/network/secureudpserver/CMakeLists.txt32
-rw-r--r--examples/network/threadedfortuneserver/CMakeLists.txt32
-rw-r--r--examples/network/torrent/.prev_CMakeLists.txt41
-rw-r--r--examples/network/torrent/CMakeLists.txt43
-rw-r--r--examples/opengl/2dpainting/CMakeLists.txt35
-rw-r--r--examples/opengl/CMakeLists.txt16
-rw-r--r--examples/opengl/computegles31/CMakeLists.txt43
-rw-r--r--examples/opengl/contextinfo/CMakeLists.txt33
-rw-r--r--examples/opengl/cube/CMakeLists.txt57
-rw-r--r--examples/opengl/hellogl2/CMakeLists.txt35
-rw-r--r--examples/opengl/hellogles3/CMakeLists.txt44
-rw-r--r--examples/opengl/hellowindow/CMakeLists.txt34
-rw-r--r--examples/opengl/legacy/CMakeLists.txt13
-rw-r--r--examples/opengl/legacy/framebufferobject2/CMakeLists.txt47
-rw-r--r--examples/opengl/legacy/grabber/CMakeLists.txt35
-rw-r--r--examples/opengl/legacy/hellogl/CMakeLists.txt39
-rw-r--r--examples/opengl/legacy/overpainting/CMakeLists.txt39
-rw-r--r--examples/opengl/legacy/pbuffers/CMakeLists.txt48
-rw-r--r--examples/opengl/legacy/pbuffers2/CMakeLists.txt50
-rw-r--r--examples/opengl/legacy/samplebuffers/CMakeLists.txt34
-rw-r--r--examples/opengl/paintedwindow/CMakeLists.txt30
-rw-r--r--examples/opengl/qopenglwidget/CMakeLists.txt47
-rw-r--r--examples/opengl/qopenglwindow/CMakeLists.txt46
-rw-r--r--examples/opengl/textures/CMakeLists.txt51
-rw-r--r--examples/opengl/threadedqopenglwidget/CMakeLists.txt33
-rw-r--r--examples/qpa/CMakeLists.txt4
-rw-r--r--examples/qpa/qrasterwindow/CMakeLists.txt25
-rw-r--r--examples/qpa/windows/CMakeLists.txt34
-rw-r--r--examples/qtconcurrent/CMakeLists.txt9
-rw-r--r--examples/qtconcurrent/imagescaling/CMakeLists.txt30
-rw-r--r--examples/qtconcurrent/map/.prev_CMakeLists.txt26
-rw-r--r--examples/qtconcurrent/map/CMakeLists.txt28
-rw-r--r--examples/qtconcurrent/progressdialog/CMakeLists.txt29
-rw-r--r--examples/qtconcurrent/runfunction/CMakeLists.txt29
-rw-r--r--examples/qtconcurrent/wordcount/CMakeLists.txt29
-rw-r--r--examples/qtestlib/CMakeLists.txt7
-rw-r--r--examples/qtestlib/tutorial1/CMakeLists.txt28
-rw-r--r--examples/qtestlib/tutorial2/CMakeLists.txt28
-rw-r--r--examples/qtestlib/tutorial3/CMakeLists.txt28
-rw-r--r--examples/qtestlib/tutorial4/CMakeLists.txt28
-rw-r--r--examples/qtestlib/tutorial5/CMakeLists.txt28
-rw-r--r--examples/sql/CMakeLists.txt17
-rw-r--r--examples/sql/books/CMakeLists.txt36
-rw-r--r--examples/sql/cachedtable/CMakeLists.txt31
-rw-r--r--examples/sql/drilldown/CMakeLists.txt34
-rw-r--r--examples/sql/masterdetail/CMakeLists.txt35
-rw-r--r--examples/sql/querymodel/CMakeLists.txt32
-rw-r--r--examples/sql/relationaltablemodel/CMakeLists.txt30
-rw-r--r--examples/sql/sqlbrowser/CMakeLists.txt33
-rw-r--r--examples/sql/sqlwidgetmapper/CMakeLists.txt30
-rw-r--r--examples/sql/tablemodel/CMakeLists.txt30
-rw-r--r--examples/vulkan/CMakeLists.txt11
-rw-r--r--examples/vulkan/hellovulkancubes/CMakeLists.txt63
-rw-r--r--examples/vulkan/hellovulkantexture/CMakeLists.txt45
-rw-r--r--examples/vulkan/hellovulkantriangle/CMakeLists.txt50
-rw-r--r--examples/vulkan/hellovulkanwidget/CMakeLists.txt53
-rw-r--r--examples/vulkan/hellovulkanwindow/CMakeLists.txt30
-rw-r--r--examples/widgets/CMakeLists.txt33
-rw-r--r--examples/widgets/animation/CMakeLists.txt8
-rw-r--r--examples/widgets/animation/animatedtiles/CMakeLists.txt28
-rw-r--r--examples/widgets/animation/easing/CMakeLists.txt31
-rw-r--r--examples/widgets/animation/moveblocks/CMakeLists.txt27
-rw-r--r--examples/widgets/animation/states/CMakeLists.txt28
-rw-r--r--examples/widgets/animation/stickman/CMakeLists.txt33
-rw-r--r--examples/widgets/animation/sub-attaq/CMakeLists.txt44
-rw-r--r--examples/widgets/desktop/CMakeLists.txt4
-rw-r--r--examples/widgets/desktop/screenshot/CMakeLists.txt28
-rw-r--r--examples/widgets/desktop/systray/CMakeLists.txt29
-rw-r--r--examples/widgets/dialogs/CMakeLists.txt14
-rw-r--r--examples/widgets/dialogs/classwizard/CMakeLists.txt28
-rw-r--r--examples/widgets/dialogs/extension/CMakeLists.txt28
-rw-r--r--examples/widgets/dialogs/findfiles/CMakeLists.txt28
-rw-r--r--examples/widgets/dialogs/licensewizard/CMakeLists.txt30
-rw-r--r--examples/widgets/dialogs/standarddialogs/CMakeLists.txt28
-rw-r--r--examples/widgets/dialogs/tabdialog/CMakeLists.txt28
-rw-r--r--examples/widgets/dialogs/trivialwizard/CMakeLists.txt27
-rw-r--r--examples/widgets/draganddrop/CMakeLists.txt7
-rw-r--r--examples/widgets/draganddrop/draggableicons/CMakeLists.txt29
-rw-r--r--examples/widgets/draganddrop/draggabletext/CMakeLists.txt29
-rw-r--r--examples/widgets/draganddrop/dropsite/CMakeLists.txt29
-rw-r--r--examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt30
-rw-r--r--examples/widgets/draganddrop/puzzle/CMakeLists.txt31
-rw-r--r--examples/widgets/effects/CMakeLists.txt4
-rw-r--r--examples/widgets/effects/blurpicker/CMakeLists.txt29
-rw-r--r--examples/widgets/effects/fademessage/CMakeLists.txt28
-rw-r--r--examples/widgets/gestures/CMakeLists.txt3
-rw-r--r--examples/widgets/gestures/imagegestures/CMakeLists.txt29
-rw-r--r--examples/widgets/graphicsview/CMakeLists.txt20
-rw-r--r--examples/widgets/graphicsview/anchorlayout/CMakeLists.txt27
-rw-r--r--examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt30
-rw-r--r--examples/widgets/graphicsview/boxes/CMakeLists.txt39
-rw-r--r--examples/widgets/graphicsview/chip/CMakeLists.txt39
-rw-r--r--examples/widgets/graphicsview/collidingmice/CMakeLists.txt29
-rw-r--r--examples/widgets/graphicsview/diagramscene/CMakeLists.txt32
-rw-r--r--examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt29
-rw-r--r--examples/widgets/graphicsview/elasticnodes/CMakeLists.txt30
-rw-r--r--examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt30
-rw-r--r--examples/widgets/graphicsview/flowlayout/CMakeLists.txt29
-rw-r--r--examples/widgets/graphicsview/padnavigator/.prev_CMakeLists.txt45
-rw-r--r--examples/widgets/graphicsview/padnavigator/CMakeLists.txt38
-rw-r--r--examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt27
-rw-r--r--examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt28
-rw-r--r--examples/widgets/itemviews/CMakeLists.txt27
-rw-r--r--examples/widgets/itemviews/addressbook/CMakeLists.txt32
-rw-r--r--examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt28
-rw-r--r--examples/widgets/itemviews/chart/CMakeLists.txt30
-rw-r--r--examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt29
-rw-r--r--examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt28
-rw-r--r--examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt31
-rw-r--r--examples/widgets/itemviews/dirview/CMakeLists.txt27
-rw-r--r--examples/widgets/itemviews/editabletreemodel/CMakeLists.txt31
-rw-r--r--examples/widgets/itemviews/fetchmore/CMakeLists.txt29
-rw-r--r--examples/widgets/itemviews/flattreeview/CMakeLists.txt27
-rw-r--r--examples/widgets/itemviews/frozencolumn/CMakeLists.txt29
-rw-r--r--examples/widgets/itemviews/interview/CMakeLists.txt29
-rw-r--r--examples/widgets/itemviews/pixelator/CMakeLists.txt37
-rw-r--r--examples/widgets/itemviews/puzzle/CMakeLists.txt31
-rw-r--r--examples/widgets/itemviews/simpledommodel/CMakeLists.txt32
-rw-r--r--examples/widgets/itemviews/simpletreemodel/CMakeLists.txt30
-rw-r--r--examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt28
-rw-r--r--examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt28
-rw-r--r--examples/widgets/itemviews/spreadsheet/CMakeLists.txt37
-rw-r--r--examples/widgets/itemviews/stardelegate/CMakeLists.txt30
-rw-r--r--examples/widgets/itemviews/storageview/CMakeLists.txt32
-rw-r--r--examples/widgets/layouts/CMakeLists.txt6
-rw-r--r--examples/widgets/layouts/basiclayouts/CMakeLists.txt28
-rw-r--r--examples/widgets/layouts/borderlayout/CMakeLists.txt29
-rw-r--r--examples/widgets/layouts/dynamiclayouts/CMakeLists.txt28
-rw-r--r--examples/widgets/layouts/flowlayout/CMakeLists.txt29
-rw-r--r--examples/widgets/mac/CMakeLists.txt7
-rw-r--r--examples/widgets/mac/qmaccocoaviewcontainer/CMakeLists.txt28
-rw-r--r--examples/widgets/mac/qmacnativewidget/CMakeLists.txt28
-rw-r--r--examples/widgets/mainwindows/CMakeLists.txt8
-rw-r--r--examples/widgets/mainwindows/application/CMakeLists.txt29
-rw-r--r--examples/widgets/mainwindows/dockwidgets/CMakeLists.txt35
-rw-r--r--examples/widgets/mainwindows/mainwindow/CMakeLists.txt30
-rw-r--r--examples/widgets/mainwindows/mdi/CMakeLists.txt30
-rw-r--r--examples/widgets/mainwindows/menus/CMakeLists.txt28
-rw-r--r--examples/widgets/mainwindows/sdi/CMakeLists.txt29
-rw-r--r--examples/widgets/painting/CMakeLists.txt14
-rw-r--r--examples/widgets/painting/affine/CMakeLists.txt34
-rw-r--r--examples/widgets/painting/basicdrawing/CMakeLists.txt30
-rw-r--r--examples/widgets/painting/composition/CMakeLists.txt33
-rw-r--r--examples/widgets/painting/concentriccircles/CMakeLists.txt29
-rw-r--r--examples/widgets/painting/deform/CMakeLists.txt34
-rw-r--r--examples/widgets/painting/fontsampler/CMakeLists.txt29
-rw-r--r--examples/widgets/painting/gradients/CMakeLists.txt33
-rw-r--r--examples/widgets/painting/imagecomposition/CMakeLists.txt29
-rw-r--r--examples/widgets/painting/painterpaths/CMakeLists.txt29
-rw-r--r--examples/widgets/painting/pathstroke/CMakeLists.txt35
-rw-r--r--examples/widgets/painting/shared/CMakeLists.txt27
-rw-r--r--examples/widgets/painting/transformations/CMakeLists.txt29
-rw-r--r--examples/widgets/richtext/CMakeLists.txt6
-rw-r--r--examples/widgets/richtext/calendar/CMakeLists.txt28
-rw-r--r--examples/widgets/richtext/orderform/CMakeLists.txt33
-rw-r--r--examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt29
-rw-r--r--examples/widgets/richtext/textedit/CMakeLists.txt34
-rw-r--r--examples/widgets/scroller/CMakeLists.txt3
-rw-r--r--examples/widgets/scroller/graphicsview/CMakeLists.txt27
-rw-r--r--examples/widgets/statemachine/CMakeLists.txt11
-rw-r--r--examples/widgets/statemachine/eventtransitions/CMakeLists.txt27
-rw-r--r--examples/widgets/statemachine/factorial/CMakeLists.txt27
-rw-r--r--examples/widgets/statemachine/pingpong/CMakeLists.txt27
-rw-r--r--examples/widgets/statemachine/rogue/CMakeLists.txt29
-rw-r--r--examples/widgets/statemachine/trafficlight/CMakeLists.txt27
-rw-r--r--examples/widgets/statemachine/twowaybutton/CMakeLists.txt27
-rw-r--r--examples/widgets/tools/CMakeLists.txt22
-rw-r--r--examples/widgets/tools/codecs/CMakeLists.txt31
-rw-r--r--examples/widgets/tools/completer/CMakeLists.txt30
-rw-r--r--examples/widgets/tools/customcompleter/CMakeLists.txt30
-rw-r--r--examples/widgets/tools/echoplugin/CMakeLists.txt4
-rw-r--r--examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt29
-rw-r--r--examples/widgets/tools/echoplugin/plugin/CMakeLists.txt10
-rw-r--r--examples/widgets/tools/i18n/CMakeLists.txt30
-rw-r--r--examples/widgets/tools/plugandpaint/CMakeLists.txt4
-rw-r--r--examples/widgets/tools/plugandpaint/app/CMakeLists.txt34
-rw-r--r--examples/widgets/tools/plugandpaint/plugins/CMakeLists.txt4
-rw-r--r--examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt13
-rw-r--r--examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt9
-rw-r--r--examples/widgets/tools/regexp/CMakeLists.txt28
-rw-r--r--examples/widgets/tools/regularexpression/CMakeLists.txt29
-rw-r--r--examples/widgets/tools/settingseditor/CMakeLists.txt31
-rw-r--r--examples/widgets/tools/styleplugin/CMakeLists.txt19
-rw-r--r--examples/widgets/tools/styleplugin/plugin/CMakeLists.txt9
-rw-r--r--examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt28
-rw-r--r--examples/widgets/tools/treemodelcompleter/CMakeLists.txt29
-rw-r--r--examples/widgets/tools/undo/CMakeLists.txt31
-rw-r--r--examples/widgets/tools/undoframework/CMakeLists.txt32
-rw-r--r--examples/widgets/touch/CMakeLists.txt6
-rw-r--r--examples/widgets/touch/dials/CMakeLists.txt28
-rw-r--r--examples/widgets/touch/fingerpaint/CMakeLists.txt35
-rw-r--r--examples/widgets/touch/knobs/CMakeLists.txt28
-rw-r--r--examples/widgets/touch/pinchzoom/CMakeLists.txt30
-rw-r--r--examples/widgets/tutorials/CMakeLists.txt7
-rw-r--r--examples/widgets/tutorials/addressbook/CMakeLists.txt9
-rw-r--r--examples/widgets/tutorials/addressbook/part1/CMakeLists.txt28
-rw-r--r--examples/widgets/tutorials/addressbook/part2/CMakeLists.txt28
-rw-r--r--examples/widgets/tutorials/addressbook/part3/CMakeLists.txt28
-rw-r--r--examples/widgets/tutorials/addressbook/part4/CMakeLists.txt28
-rw-r--r--examples/widgets/tutorials/addressbook/part5/CMakeLists.txt29
-rw-r--r--examples/widgets/tutorials/addressbook/part6/CMakeLists.txt29
-rw-r--r--examples/widgets/tutorials/addressbook/part7/CMakeLists.txt29
-rw-r--r--examples/widgets/tutorials/gettingStarted/CMakeLists.txt2
-rw-r--r--examples/widgets/tutorials/gettingStarted/gsQt/CMakeLists.txt7
-rw-r--r--examples/widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt27
-rw-r--r--examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt27
-rw-r--r--examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt27
-rw-r--r--examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt27
-rw-r--r--examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt27
-rw-r--r--examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt28
-rw-r--r--examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt28
-rw-r--r--examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt28
-rw-r--r--examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt28
-rw-r--r--examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt29
-rw-r--r--examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt28
-rw-r--r--examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt28
-rw-r--r--examples/widgets/tutorials/modelview/CMakeLists.txt9
-rw-r--r--examples/widgets/tutorials/notepad/.prev_CMakeLists.txt49
-rw-r--r--examples/widgets/tutorials/notepad/CMakeLists.txt36
-rw-r--r--examples/widgets/tutorials/widgets/CMakeLists.txt6
-rw-r--r--examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt27
-rw-r--r--examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt27
-rw-r--r--examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt27
-rw-r--r--examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt27
-rw-r--r--examples/widgets/widgets/CMakeLists.txt27
-rw-r--r--examples/widgets/widgets/analogclock/CMakeLists.txt28
-rw-r--r--examples/widgets/widgets/calculator/CMakeLists.txt29
-rw-r--r--examples/widgets/widgets/calendarwidget/CMakeLists.txt28
-rw-r--r--examples/widgets/widgets/charactermap/CMakeLists.txt29
-rw-r--r--examples/widgets/widgets/codeeditor/CMakeLists.txt28
-rw-r--r--examples/widgets/widgets/digitalclock/CMakeLists.txt28
-rw-r--r--examples/widgets/widgets/elidedlabel/CMakeLists.txt33
-rw-r--r--examples/widgets/widgets/groupbox/CMakeLists.txt28
-rw-r--r--examples/widgets/widgets/icons/CMakeLists.txt33
-rw-r--r--examples/widgets/widgets/imageviewer/CMakeLists.txt34
-rw-r--r--examples/widgets/widgets/lineedits/CMakeLists.txt28
-rw-r--r--examples/widgets/widgets/mousebuttons/CMakeLists.txt30
-rw-r--r--examples/widgets/widgets/movie/CMakeLists.txt28
-rw-r--r--examples/widgets/widgets/scribble/CMakeLists.txt35
-rw-r--r--examples/widgets/widgets/shapedclock/CMakeLists.txt28
-rw-r--r--examples/widgets/widgets/sliders/CMakeLists.txt29
-rw-r--r--examples/widgets/widgets/spinboxes/CMakeLists.txt28
-rw-r--r--examples/widgets/widgets/styles/CMakeLists.txt30
-rw-r--r--examples/widgets/widgets/stylesheet/CMakeLists.txt30
-rw-r--r--examples/widgets/widgets/tablet/CMakeLists.txt31
-rw-r--r--examples/widgets/widgets/tetrix/CMakeLists.txt30
-rw-r--r--examples/widgets/widgets/tooltips/CMakeLists.txt30
-rw-r--r--examples/widgets/widgets/validators/CMakeLists.txt31
-rw-r--r--examples/widgets/widgets/wiggly/CMakeLists.txt29
-rw-r--r--examples/widgets/widgets/windowflags/CMakeLists.txt29
-rw-r--r--examples/widgets/windowcontainer/CMakeLists.txt31
-rw-r--r--examples/xml/CMakeLists.txt14
-rw-r--r--examples/xml/dombookmarks/CMakeLists.txt30
-rw-r--r--examples/xml/htmlinfo/CMakeLists.txt26
-rw-r--r--examples/xml/rsslisting/CMakeLists.txt31
-rw-r--r--examples/xml/streambookmarks/CMakeLists.txt31
-rw-r--r--examples/xml/xmlstreamlint/CMakeLists.txt27
-rw-r--r--qmake/.prev_CMakeLists.txt186
-rw-r--r--qmake/CMakeLists.txt216
-rw-r--r--qmake/generators/makefiledeps.cpp2
-rw-r--r--qmake/generators/makefiledeps.h2
-rw-r--r--qmake/main.cpp2
-rw-r--r--src/3rdparty/CMakeLists.txt8
-rw-r--r--src/3rdparty/double-conversion/CMakeLists.txt21
-rw-r--r--src/3rdparty/gradle/CMakeLists.txt21
-rw-r--r--src/3rdparty/harfbuzz/CMakeLists.txt14
-rw-r--r--src/CMakeLists.txt60
-rw-r--r--src/android/CMakeLists.txt14
-rw-r--r--src/android/jar/.prev_CMakeLists.txt30
-rw-r--r--src/android/jar/CMakeLists.txt31
-rw-r--r--src/android/java/CMakeLists.txt12
-rw-r--r--src/android/templates/CMakeLists.txt19
-rw-r--r--src/concurrent/CMakeLists.txt46
-rw-r--r--src/corelib/.prev_CMakeLists.txt1056
-rw-r--r--src/corelib/CMakeLists.txt1166
-rw-r--r--src/corelib/Qt5CoreConfigExtras.cmake.in179
-rw-r--r--src/corelib/Qt6CTestMacros.cmake (renamed from src/corelib/Qt5CTestMacros.cmake)0
-rw-r--r--src/corelib/Qt6Config.cmake.in (renamed from src/corelib/Qt5Config.cmake.in)0
-rw-r--r--src/corelib/Qt6CoreConfigExtras.cmake.in53
-rw-r--r--src/corelib/Qt6CoreConfigExtrasMkspecDir.cmake.in (renamed from src/corelib/Qt5CoreConfigExtrasMkspecDir.cmake.in)0
-rw-r--r--src/corelib/Qt6CoreConfigExtrasMkspecDirForInstall.cmake.in (renamed from src/corelib/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in)0
-rw-r--r--src/corelib/Qt6CoreMacros.cmake (renamed from src/corelib/Qt5CoreMacros.cmake)315
-rw-r--r--src/corelib/Qt6ModuleLocation.cmake.in (renamed from src/corelib/Qt5ModuleLocation.cmake.in)0
-rw-r--r--src/corelib/Qt6ModuleLocationForInstall.cmake.in (renamed from src/corelib/Qt5ModuleLocationForInstall.cmake.in)0
-rw-r--r--src/corelib/configure.cmake954
-rw-r--r--src/corelib/configure.json27
-rw-r--r--src/corelib/global/qconfig.cpp.in32
-rw-r--r--src/corelib/global/qlibraryinfo.cpp2
-rw-r--r--src/corelib/io/qfilesystemiterator_unix.cpp2
-rw-r--r--src/corelib/kernel/qvariant.cpp4
-rw-r--r--src/corelib/mimetypes/mimetypes_resources.cmake21
-rw-r--r--src/dbus/.prev_CMakeLists.txt74
-rw-r--r--src/dbus/CMakeLists.txt77
-rw-r--r--src/dbus/Qt5DBusConfigExtras.cmake.in33
-rw-r--r--src/dbus/Qt6DBusMacros.cmake (renamed from src/dbus/Qt5DBusMacros.cmake)22
-rw-r--r--src/gui/.prev_CMakeLists.txt658
-rw-r--r--src/gui/CMakeLists.txt806
-rw-r--r--src/gui/Qt5GuiConfigExtras.cmake.in193
-rw-r--r--src/gui/configure.cmake1106
-rw-r--r--src/gui/configure.json19
-rw-r--r--src/network/.prev_CMakeLists.txt429
-rw-r--r--src/network/CMakeLists.txt445
-rw-r--r--src/network/configure.cmake359
-rw-r--r--src/network/configure.json10
-rw-r--r--src/network/socket/qabstractsocketengine.cpp2
-rw-r--r--src/network/socket/qhttpsocketengine.cpp2
-rw-r--r--src/network/socket/qnativesocketengine.cpp2
-rw-r--r--src/network/socket/qsocks5socketengine.cpp2
-rw-r--r--src/opengl/.prev_CMakeLists.txt57
-rw-r--r--src/opengl/CMakeLists.txt57
-rw-r--r--src/openglextensions/CMakeLists.txt20
-rw-r--r--src/platformheaders/.prev_CMakeLists.txt2
-rw-r--r--src/platformheaders/CMakeLists.txt13
-rw-r--r--src/platformheaders/fake.cpp0
-rw-r--r--src/platformsupport/CMakeLists.txt49
-rw-r--r--src/platformsupport/accessibility/CMakeLists.txt23
-rw-r--r--src/platformsupport/clipboard/CMakeLists.txt31
-rw-r--r--src/platformsupport/devicediscovery/CMakeLists.txt42
-rw-r--r--src/platformsupport/edid/CMakeLists.txt23
-rw-r--r--src/platformsupport/eglconvenience/.prev_CMakeLists.txt53
-rw-r--r--src/platformsupport/eglconvenience/CMakeLists.txt56
-rw-r--r--src/platformsupport/eventdispatchers/.prev_CMakeLists.txt45
-rw-r--r--src/platformsupport/eventdispatchers/CMakeLists.txt47
-rw-r--r--src/platformsupport/fbconvenience/CMakeLists.txt29
-rw-r--r--src/platformsupport/fontdatabases/.prev_CMakeLists.txt130
-rw-r--r--src/platformsupport/fontdatabases/CMakeLists.txt133
-rw-r--r--src/platformsupport/fontdatabases/fake.cpp0
-rw-r--r--src/platformsupport/glxconvenience/.prev_CMakeLists.txt24
-rw-r--r--src/platformsupport/glxconvenience/CMakeLists.txt26
-rw-r--r--src/platformsupport/graphics/CMakeLists.txt23
-rw-r--r--src/platformsupport/input/.prev_CMakeLists.txt107
-rw-r--r--src/platformsupport/input/CMakeLists.txt112
-rw-r--r--src/platformsupport/input/xkbcommon/CMakeLists.txt35
-rw-r--r--src/platformsupport/kmsconvenience/.prev_CMakeLists.txt24
-rw-r--r--src/platformsupport/kmsconvenience/CMakeLists.txt26
-rw-r--r--src/platformsupport/linuxaccessibility/.prev_CMakeLists.txt45
-rw-r--r--src/platformsupport/linuxaccessibility/CMakeLists.txt47
-rw-r--r--src/platformsupport/linuxofono/CMakeLists.txt20
-rw-r--r--src/platformsupport/platformcompositor/CMakeLists.txt24
-rw-r--r--src/platformsupport/services/CMakeLists.txt33
-rw-r--r--src/platformsupport/themes/CMakeLists.txt57
-rw-r--r--src/platformsupport/vkconvenience/.prev_CMakeLists.txt26
-rw-r--r--src/platformsupport/vkconvenience/CMakeLists.txt28
-rw-r--r--src/platformsupport/windowsuiautomation/CMakeLists.txt31
-rw-r--r--src/plugins/CMakeLists.txt25
-rw-r--r--src/plugins/bearer/.prev_CMakeLists.txt12
-rw-r--r--src/plugins/bearer/CMakeLists.txt14
-rw-r--r--src/plugins/bearer/android/CMakeLists.txt4
-rw-r--r--src/plugins/bearer/android/jar/.prev_CMakeLists.txt16
-rw-r--r--src/plugins/bearer/android/jar/CMakeLists.txt22
-rw-r--r--src/plugins/bearer/android/src/CMakeLists.txt22
-rw-r--r--src/plugins/bearer/connman/.prev_CMakeLists.txt25
-rw-r--r--src/plugins/bearer/connman/CMakeLists.txt25
-rw-r--r--src/plugins/bearer/corewlan/CMakeLists.txt33
-rw-r--r--src/plugins/bearer/generic/CMakeLists.txt31
-rw-r--r--src/plugins/bearer/networkmanager/.prev_CMakeLists.txt25
-rw-r--r--src/plugins/bearer/networkmanager/CMakeLists.txt25
-rw-r--r--src/plugins/generic/.prev_CMakeLists.txt23
-rw-r--r--src/plugins/generic/CMakeLists.txt23
-rw-r--r--src/plugins/generic/evdevkeyboard/CMakeLists.txt24
-rw-r--r--src/plugins/generic/evdevmouse/CMakeLists.txt24
-rw-r--r--src/plugins/generic/evdevtablet/CMakeLists.txt24
-rw-r--r--src/plugins/generic/evdevtouch/CMakeLists.txt24
-rw-r--r--src/plugins/generic/libinput/CMakeLists.txt24
-rw-r--r--src/plugins/generic/tslib/.prev_CMakeLists.txt25
-rw-r--r--src/plugins/generic/tslib/CMakeLists.txt27
-rw-r--r--src/plugins/generic/tuiotouch/CMakeLists.txt30
-rw-r--r--src/plugins/imageformats/CMakeLists.txt11
-rw-r--r--src/plugins/imageformats/gif/.prev_CMakeLists.txt19
-rw-r--r--src/plugins/imageformats/gif/CMakeLists.txt20
-rw-r--r--src/plugins/imageformats/ico/.prev_CMakeLists.txt22
-rw-r--r--src/plugins/imageformats/ico/CMakeLists.txt21
-rw-r--r--src/plugins/imageformats/jpeg/.prev_CMakeLists.txt23
-rw-r--r--src/plugins/imageformats/jpeg/CMakeLists.txt25
-rw-r--r--src/plugins/platforminputcontexts/CMakeLists.txt8
-rw-r--r--src/plugins/platforminputcontexts/compose/.prev_CMakeLists.txt24
-rw-r--r--src/plugins/platforminputcontexts/compose/CMakeLists.txt27
-rw-r--r--src/plugins/platforminputcontexts/ibus/CMakeLists.txt29
-rw-r--r--src/plugins/platforms/.prev_CMakeLists.txt57
-rw-r--r--src/plugins/platforms/CMakeLists.txt57
-rw-r--r--src/plugins/platforms/android/.prev_CMakeLists.txt87
-rw-r--r--src/plugins/platforms/android/CMakeLists.txt96
-rw-r--r--src/plugins/platforms/cocoa/.prev_CMakeLists.txt154
-rw-r--r--src/plugins/platforms/cocoa/CMakeLists.txt158
-rw-r--r--src/plugins/platforms/directfb/.prev_CMakeLists.txt67
-rw-r--r--src/plugins/platforms/directfb/CMakeLists.txt71
-rw-r--r--src/plugins/platforms/eglfs/.prev_CMakeLists.txt121
-rw-r--r--src/plugins/platforms/eglfs/CMakeLists.txt108
-rw-r--r--src/plugins/platforms/eglfs/deviceintegration/.prev_CMakeLists.txt38
-rw-r--r--src/plugins/platforms/eglfs/deviceintegration/CMakeLists.txt38
-rw-r--r--src/plugins/platforms/eglfs/deviceintegration/eglfs_emu/CMakeLists.txt30
-rw-r--r--src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/CMakeLists.txt41
-rw-r--r--src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/CMakeLists.txt38
-rw-r--r--src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/CMakeLists.txt32
-rw-r--r--src/plugins/platforms/eglfs/deviceintegration/eglfs_x11/CMakeLists.txt30
-rw-r--r--src/plugins/platforms/ios/.prev_CMakeLists.txt81
-rw-r--r--src/plugins/platforms/ios/CMakeLists.txt72
-rw-r--r--src/plugins/platforms/ios/optional/CMakeLists.txt6
-rw-r--r--src/plugins/platforms/ios/optional/nsphotolibrarysupport/CMakeLists.txt30
-rw-r--r--src/plugins/platforms/linuxfb/.prev_CMakeLists.txt55
-rw-r--r--src/plugins/platforms/linuxfb/CMakeLists.txt56
-rw-r--r--src/plugins/platforms/minimal/.prev_CMakeLists.txt40
-rw-r--r--src/plugins/platforms/minimal/CMakeLists.txt41
-rw-r--r--src/plugins/platforms/minimalegl/.prev_CMakeLists.txt43
-rw-r--r--src/plugins/platforms/minimalegl/CMakeLists.txt44
-rw-r--r--src/plugins/platforms/offscreen/.prev_CMakeLists.txt45
-rw-r--r--src/plugins/platforms/offscreen/CMakeLists.txt46
-rw-r--r--src/plugins/platforms/vnc/.prev_CMakeLists.txt51
-rw-r--r--src/plugins/platforms/vnc/CMakeLists.txt52
-rw-r--r--src/plugins/platforms/windows/.prev_CMakeLists.txt243
-rw-r--r--src/plugins/platforms/windows/CMakeLists.txt237
-rw-r--r--src/plugins/platforms/windows/qwindowscontext.cpp2
-rw-r--r--src/plugins/platforms/xcb/.prev_CMakeLists.txt177
-rw-r--r--src/plugins/platforms/xcb/CMakeLists.txt221
-rw-r--r--src/plugins/platforms/xcb/gl_integrations/CMakeLists.txt8
-rw-r--r--src/plugins/platforms/xcb/gl_integrations/xcb_egl/CMakeLists.txt31
-rw-r--r--src/plugins/platforms/xcb/gl_integrations/xcb_glx/CMakeLists.txt44
-rw-r--r--src/plugins/platformthemes/CMakeLists.txt8
-rw-r--r--src/plugins/platformthemes/gtk3/.prev_CMakeLists.txt29
-rw-r--r--src/plugins/platformthemes/gtk3/CMakeLists.txt33
-rw-r--r--src/plugins/platformthemes/xdgdesktopportal/CMakeLists.txt26
-rw-r--r--src/plugins/printsupport/.prev_CMakeLists.txt11
-rw-r--r--src/plugins/printsupport/CMakeLists.txt11
-rw-r--r--src/plugins/printsupport/cocoa/CMakeLists.txt24
-rw-r--r--src/plugins/printsupport/cups/.prev_CMakeLists.txt30
-rw-r--r--src/plugins/printsupport/cups/CMakeLists.txt32
-rw-r--r--src/plugins/sqldrivers/.prev_CMakeLists.txt15
-rw-r--r--src/plugins/sqldrivers/CMakeLists.txt55
-rw-r--r--src/plugins/sqldrivers/configure.cmake58
-rw-r--r--src/plugins/sqldrivers/configure.json4
-rw-r--r--src/plugins/sqldrivers/db2/CMakeLists.txt34
-rw-r--r--src/plugins/sqldrivers/mysql/CMakeLists.txt26
-rw-r--r--src/plugins/sqldrivers/oci/CMakeLists.txt34
-rw-r--r--src/plugins/sqldrivers/odbc/.prev_CMakeLists.txt34
-rw-r--r--src/plugins/sqldrivers/odbc/CMakeLists.txt36
-rw-r--r--src/plugins/sqldrivers/odbc/qsql_odbc.cpp2
-rw-r--r--src/plugins/sqldrivers/psql/.prev_CMakeLists.txt26
-rw-r--r--src/plugins/sqldrivers/psql/CMakeLists.txt31
-rw-r--r--src/plugins/sqldrivers/sqlite/.prev_CMakeLists.txt95
-rw-r--r--src/plugins/sqldrivers/sqlite/CMakeLists.txt35
-rw-r--r--src/plugins/styles/.prev_CMakeLists.txt11
-rw-r--r--src/plugins/styles/CMakeLists.txt11
-rw-r--r--src/plugins/styles/mac/CMakeLists.txt24
-rw-r--r--src/plugins/styles/windowsvista/CMakeLists.txt39
-rw-r--r--src/printsupport/CMakeLists.txt176
-rw-r--r--src/printsupport/configure.cmake58
-rw-r--r--src/sql/CMakeLists.txt55
-rw-r--r--src/sql/configure.cmake21
-rw-r--r--src/testlib/.prev_CMakeLists.txt143
-rw-r--r--src/testlib/CMakeLists.txt129
-rw-r--r--src/testlib/Qt5TestConfigExtras.cmake.in5
-rw-r--r--src/testlib/configure.cmake31
-rw-r--r--src/testlib/qtestcase.cpp22
-rw-r--r--src/testlib/qtestcase.h11
-rw-r--r--src/tools/CMakeLists.txt13
-rw-r--r--src/tools/androiddeployqt/.prev_CMakeLists.txt27
-rw-r--r--src/tools/androiddeployqt/CMakeLists.txt27
-rw-r--r--src/tools/androidtestrunner/CMakeLists.txt27
-rw-r--r--src/tools/androidtestrunner/main.cpp19
-rw-r--r--src/tools/bootstrap/.prev_CMakeLists.txt211
-rw-r--r--src/tools/bootstrap/CMakeLists.txt224
-rw-r--r--src/tools/cmake_automoc_parser/CMakeLists.txt18
-rw-r--r--src/tools/cmake_automoc_parser/main.cpp389
-rw-r--r--src/tools/moc/.prev_CMakeLists.txt35
-rw-r--r--src/tools/moc/CMakeLists.txt36
-rw-r--r--src/tools/qdbuscpp2xml/.prev_CMakeLists.txt49
-rw-r--r--src/tools/qdbuscpp2xml/CMakeLists.txt48
-rw-r--r--src/tools/qdbusxml2cpp/.prev_CMakeLists.txt36
-rw-r--r--src/tools/qdbusxml2cpp/CMakeLists.txt35
-rw-r--r--src/tools/qlalr/.prev_CMakeLists.txt26
-rw-r--r--src/tools/qlalr/CMakeLists.txt27
-rw-r--r--src/tools/qvkgen/.prev_CMakeLists.txt16
-rw-r--r--src/tools/qvkgen/CMakeLists.txt17
-rw-r--r--src/tools/rcc/.prev_CMakeLists.txt37
-rw-r--r--src/tools/rcc/CMakeLists.txt38
-rw-r--r--src/tools/tracegen/.prev_CMakeLists.txt20
-rw-r--r--src/tools/tracegen/CMakeLists.txt21
-rw-r--r--src/tools/uic/.prev_CMakeLists.txt44
-rw-r--r--src/tools/uic/CMakeLists.txt45
-rw-r--r--src/widgets/.prev_CMakeLists.txt845
-rw-r--r--src/widgets/CMakeLists.txt847
-rw-r--r--src/widgets/Qt5WidgetsConfigExtras.cmake.in19
-rw-r--r--src/widgets/Qt6WidgetsMacros.cmake (renamed from src/widgets/Qt5WidgetsMacros.cmake)2
-rw-r--r--src/widgets/configure.cmake563
-rw-r--r--src/winmain/.prev_CMakeLists.txt48
-rw-r--r--src/winmain/CMakeLists.txt28
-rw-r--r--src/xml/CMakeLists.txt32
-rw-r--r--src/xml/configure.cmake22
-rw-r--r--tests/.prev_CMakeLists.txt7
-rw-r--r--tests/CMakeLists.txt13
-rw-r--r--tests/auto/CMakeLists.txt62
-rw-r--r--tests/auto/concurrent/CMakeLists.txt8
-rw-r--r--tests/auto/concurrent/qtconcurrentfilter/.prev_CMakeLists.txt14
-rw-r--r--tests/auto/concurrent/qtconcurrentfilter/CMakeLists.txt15
-rw-r--r--tests/auto/concurrent/qtconcurrentiteratekernel/CMakeLists.txt12
-rw-r--r--tests/auto/concurrent/qtconcurrentmap/.prev_CMakeLists.txt17
-rw-r--r--tests/auto/concurrent/qtconcurrentmap/CMakeLists.txt18
-rw-r--r--tests/auto/concurrent/qtconcurrentmedian/CMakeLists.txt12
-rw-r--r--tests/auto/concurrent/qtconcurrentrun/CMakeLists.txt15
-rw-r--r--tests/auto/concurrent/qtconcurrentthreadengine/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/.prev_CMakeLists.txt18
-rw-r--r--tests/auto/corelib/CMakeLists.txt18
-rw-r--r--tests/auto/corelib/animation/CMakeLists.txt6
-rw-r--r--tests/auto/corelib/animation/qabstractanimation/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/animation/qanimationgroup/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/animation/qparallelanimationgroup/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/animation/qpauseanimation/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/animation/qsequentialanimationgroup/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/animation/qvariantanimation/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/codecs/CMakeLists.txt3
-rw-r--r--tests/auto/corelib/codecs/qtextcodec/CMakeLists.txt5
-rw-r--r--tests/auto/corelib/codecs/qtextcodec/echo/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/codecs/utf8/CMakeLists.txt11
-rw-r--r--tests/auto/corelib/global/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/global/q_func_info/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/global/qflags/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/global/qfloat16/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/global/qgetputenv/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/global/qglobal/CMakeLists.txt14
-rw-r--r--tests/auto/corelib/global/qglobalstatic/CMakeLists.txt15
-rw-r--r--tests/auto/corelib/global/qhooks/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/global/qlogging/CMakeLists.txt25
-rw-r--r--tests/auto/corelib/global/qlogging/test/test.pro1
-rw-r--r--tests/auto/corelib/global/qlogging/tst_qlogging.cpp15
-rw-r--r--tests/auto/corelib/global/qnumeric/CMakeLists.txt26
-rw-r--r--tests/auto/corelib/global/qrand/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/global/qrandomgenerator/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/global/qtendian/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/io/.prev_CMakeLists.txt56
-rw-r--r--tests/auto/corelib/io/CMakeLists.txt56
-rw-r--r--tests/auto/corelib/io/largefile/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/io/qabstractfileengine/CMakeLists.txt25
-rw-r--r--tests/auto/corelib/io/qbuffer/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/io/qdataurl/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/io/qdebug/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/io/qdir/CMakeLists.txt99
-rw-r--r--tests/auto/corelib/io/qdir/testdir/dir/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/io/qdiriterator/CMakeLists.txt38
-rw-r--r--tests/auto/corelib/io/qfile/.prev_CMakeLists.txt89
-rw-r--r--tests/auto/corelib/io/qfile/CMakeLists.txt89
-rw-r--r--tests/auto/corelib/io/qfile/stdinprocess/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/io/qfileinfo/CMakeLists.txt47
-rw-r--r--tests/auto/corelib/io/qfilesystementry/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/io/qfilesystemmetadata/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/io/qfilesystemwatcher/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/io/qiodevice/CMakeLists.txt36
-rw-r--r--tests/auto/corelib/io/qipaddress/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/io/qlockfile/CMakeLists.txt23
-rw-r--r--tests/auto/corelib/io/qlockfile/qlockfiletesthelper/.prev_CMakeLists.txt11
-rw-r--r--tests/auto/corelib/io/qlockfile/qlockfiletesthelper/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/io/qloggingcategory/CMakeLists.txt15
-rw-r--r--tests/auto/corelib/io/qloggingregistry/CMakeLists.txt36
-rw-r--r--tests/auto/corelib/io/qnodebug/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/io/qprocess-noapplication/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/io/qprocessenvironment/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/io/qsavefile/CMakeLists.txt14
-rw-r--r--tests/auto/corelib/io/qsettings/CMakeLists.txt51
-rw-r--r--tests/auto/corelib/io/qstandardpaths/CMakeLists.txt26
-rw-r--r--tests/auto/corelib/io/qstorageinfo/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/io/qtemporarydir/CMakeLists.txt15
-rw-r--r--tests/auto/corelib/io/qtemporaryfile/CMakeLists.txt47
-rw-r--r--tests/auto/corelib/io/qurl/CMakeLists.txt20
-rw-r--r--tests/auto/corelib/io/qurlinternal/CMakeLists.txt20
-rw-r--r--tests/auto/corelib/io/qurlquery/CMakeLists.txt14
-rw-r--r--tests/auto/corelib/itemmodels/CMakeLists.txt19
-rw-r--r--tests/auto/corelib/itemmodels/qabstractitemmodel/CMakeLists.txt17
-rw-r--r--tests/auto/corelib/itemmodels/qabstractproxymodel/CMakeLists.txt14
-rw-r--r--tests/auto/corelib/itemmodels/qconcatenatetablesproxymodel/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/itemmodels/qidentityproxymodel/CMakeLists.txt15
-rw-r--r--tests/auto/corelib/itemmodels/qitemmodel/CMakeLists.txt14
-rw-r--r--tests/auto/corelib/itemmodels/qitemselectionmodel/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/itemmodels/qsortfilterproxymodel_recursive/CMakeLists.txt14
-rw-r--r--tests/auto/corelib/itemmodels/qsortfilterproxymodel_regexp/CMakeLists.txt18
-rw-r--r--tests/auto/corelib/itemmodels/qsortfilterproxymodel_regularexpression/CMakeLists.txt18
-rw-r--r--tests/auto/corelib/itemmodels/qstringlistmodel/CMakeLists.txt11
-rw-r--r--tests/auto/corelib/itemmodels/qtransposeproxymodel/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/kernel/.prev_CMakeLists.txt40
-rw-r--r--tests/auto/corelib/kernel/CMakeLists.txt40
-rw-r--r--tests/auto/corelib/kernel/qdeadlinetimer/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/kernel/qelapsedtimer/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/kernel/qeventdispatcher/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/kernel/qeventloop/CMakeLists.txt27
-rw-r--r--tests/auto/corelib/kernel/qmath/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/kernel/qmetaenum/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/kernel/qmetamethod/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/kernel/qmetaobject/CMakeLists.txt15
-rw-r--r--tests/auto/corelib/kernel/qmetaobjectbuilder/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/kernel/qmetaproperty/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/kernel/qmetatype/.prev_CMakeLists.txt42
-rw-r--r--tests/auto/corelib/kernel/qmetatype/CMakeLists.txt42
-rw-r--r--tests/auto/corelib/kernel/qmimedata/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/kernel/qobject/CMakeLists.txt29
-rw-r--r--tests/auto/corelib/kernel/qobject/signalbug/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/kernel/qpointer/CMakeLists.txt18
-rw-r--r--tests/auto/corelib/kernel/qsharedmemory/CMakeLists.txt30
-rw-r--r--tests/auto/corelib/kernel/qsharedmemory/producerconsumer/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/kernel/qsignalblocker/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/kernel/qsignalmapper/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/kernel/qsocketnotifier/CMakeLists.txt39
-rw-r--r--tests/auto/corelib/kernel/qsystemsemaphore/CMakeLists.txt20
-rw-r--r--tests/auto/corelib/kernel/qsystemsemaphore/acquirerelease/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/kernel/qtimer/CMakeLists.txt15
-rw-r--r--tests/auto/corelib/kernel/qtranslator/CMakeLists.txt47
-rw-r--r--tests/auto/corelib/kernel/qvariant/.prev_CMakeLists.txt34
-rw-r--r--tests/auto/corelib/kernel/qvariant/CMakeLists.txt34
-rw-r--r--tests/auto/corelib/kernel/qwineventnotifier/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/mimetypes/CMakeLists.txt14
-rw-r--r--tests/auto/corelib/mimetypes/qmimedatabase/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-cache/.prev_CMakeLists.txt107
-rw-r--r--tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-cache/CMakeLists.txt103
-rw-r--r--tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/.prev_CMakeLists.txt107
-rw-r--r--tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt103
-rw-r--r--tests/auto/corelib/mimetypes/qmimetype/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/plugin/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/plugin/qfactoryloader/CMakeLists.txt5
-rw-r--r--tests/auto/corelib/plugin/qfactoryloader/plugin1/CMakeLists.txt36
-rw-r--r--tests/auto/corelib/plugin/qfactoryloader/plugin2/CMakeLists.txt36
-rw-r--r--tests/auto/corelib/plugin/qfactoryloader/test/.prev_CMakeLists.txt42
-rw-r--r--tests/auto/corelib/plugin/qfactoryloader/test/CMakeLists.txt68
-rw-r--r--tests/auto/corelib/plugin/qlibrary/CMakeLists.txt5
-rw-r--r--tests/auto/corelib/plugin/qlibrary/lib/.prev_CMakeLists.txt34
-rw-r--r--tests/auto/corelib/plugin/qlibrary/lib/CMakeLists.txt43
-rw-r--r--tests/auto/corelib/plugin/qlibrary/lib2/CMakeLists.txt104
-rw-r--r--tests/auto/corelib/plugin/qlibrary/tst/.prev_CMakeLists.txt37
-rw-r--r--tests/auto/corelib/plugin/qlibrary/tst/CMakeLists.txt50
-rw-r--r--tests/auto/corelib/plugin/qplugin/.prev_CMakeLists.txt3
-rw-r--r--tests/auto/corelib/plugin/qplugin/CMakeLists.txt25
-rw-r--r--tests/auto/corelib/plugin/qplugin/debugplugin/CMakeLists.txt19
-rw-r--r--tests/auto/corelib/plugin/qplugin/invalidplugin/CMakeLists.txt19
-rw-r--r--tests/auto/corelib/plugin/qplugin/releaseplugin/CMakeLists.txt19
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/almostplugin/.prev_CMakeLists.txt30
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/almostplugin/CMakeLists.txt32
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/lib/.prev_CMakeLists.txt34
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/lib/CMakeLists.txt41
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/machtest/CMakeLists.txt2
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/staticplugin/.prev_CMakeLists.txt23
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/staticplugin/CMakeLists.txt25
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/theplugin/CMakeLists.txt31
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/tst/.prev_CMakeLists.txt45
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/tst/CMakeLists.txt45
-rw-r--r--tests/auto/corelib/plugin/quuid/CMakeLists.txt4
-rw-r--r--tests/auto/corelib/plugin/quuid/test/.prev_CMakeLists.txt29
-rw-r--r--tests/auto/corelib/plugin/quuid/test/CMakeLists.txt30
-rw-r--r--tests/auto/corelib/plugin/quuid/testProcessUniqueness/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/serialization/CMakeLists.txt17
-rw-r--r--tests/auto/corelib/serialization/json/CMakeLists.txt36
-rw-r--r--tests/auto/corelib/serialization/qcborstreamreader/CMakeLists.txt15
-rw-r--r--tests/auto/corelib/serialization/qcborstreamwriter/CMakeLists.txt14
-rw-r--r--tests/auto/corelib/serialization/qcborvalue/CMakeLists.txt15
-rw-r--r--tests/auto/corelib/serialization/qcborvalue_json/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/serialization/qdatastream/CMakeLists.txt35
-rw-r--r--tests/auto/corelib/serialization/qdatastream_core_pixmap/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/serialization/qtextstream/CMakeLists.txt6
-rw-r--r--tests/auto/corelib/serialization/qtextstream/readAllStdinProcess/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/serialization/qtextstream/readLineStdinProcess/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/serialization/qtextstream/stdinProcess/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/serialization/qtextstream/test/CMakeLists.txt56
-rw-r--r--tests/auto/corelib/serialization/qxmlstream/CMakeLists.txt18
-rw-r--r--tests/auto/corelib/statemachine/CMakeLists.txt2
-rw-r--r--tests/auto/corelib/statemachine/qstate/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/text/CMakeLists.txt22
-rw-r--r--tests/auto/corelib/text/qbytearraylist/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/text/qbytedatabuffer/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/text/qregexp/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/text/qregularexpression/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/text/qstring_no_cast_from_bytearray/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/text/qstringbuilder/qstringbuilder1/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/text/qstringbuilder/qstringbuilder2/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/text/qstringbuilder/qstringbuilder3/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/text/qstringbuilder/qstringbuilder4/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/text/qstringiterator/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/text/qstringlist/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/text/qstringmatcher/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/text/qstringref/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/thread/CMakeLists.txt24
-rw-r--r--tests/auto/corelib/thread/qatomicint/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/CMakeLists.txt18
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/char/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/char16_t/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/char32_t/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/int/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/long/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/qlonglong/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/qptrdiff/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/quintptr/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/qulonglong/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/schar/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/short/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/uchar/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/uint/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/ulong/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/ushort/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicinteger/wchar_t/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicpointer/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/thread/qfuture/.prev_CMakeLists.txt14
-rw-r--r--tests/auto/corelib/thread/qfuture/CMakeLists.txt15
-rw-r--r--tests/auto/corelib/thread/qfuturesynchronizer/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/thread/qfuturewatcher/CMakeLists.txt14
-rw-r--r--tests/auto/corelib/thread/qmutex/CMakeLists.txt20
-rw-r--r--tests/auto/corelib/thread/qmutexlocker/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/thread/qreadlocker/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/thread/qreadwritelock/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/thread/qresultstore/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/thread/qsemaphore/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/thread/qthread/.prev_CMakeLists.txt16
-rw-r--r--tests/auto/corelib/thread/qthread/CMakeLists.txt18
-rw-r--r--tests/auto/corelib/thread/qthreadonce/CMakeLists.txt11
-rw-r--r--tests/auto/corelib/thread/qthreadpool/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/thread/qthreadstorage/CMakeLists.txt21
-rw-r--r--tests/auto/corelib/thread/qthreadstorage/crashonexit/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/corelib/thread/qthreadstorage/crashonexit/CMakeLists.txt15
-rw-r--r--tests/auto/corelib/thread/qwaitcondition/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/thread/qwritelocker/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/time/CMakeLists.txt7
-rw-r--r--tests/auto/corelib/time/qcalendar/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/time/qdate/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/time/qdatetime/CMakeLists.txt26
-rw-r--r--tests/auto/corelib/time/qtime/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/time/qtimezone/CMakeLists.txt27
-rw-r--r--tests/auto/corelib/tools/CMakeLists.txt50
-rw-r--r--tests/auto/corelib/tools/qalgorithms/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qarraydata/CMakeLists.txt11
-rw-r--r--tests/auto/corelib/tools/qbitarray/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qcache/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qcommandlineparser/CMakeLists.txt11
-rw-r--r--tests/auto/corelib/tools/qcommandlineparser/testhelper/CMakeLists.txt11
-rw-r--r--tests/auto/corelib/tools/qcontiguouscache/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qeasingcurve/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qexplicitlyshareddatapointer/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qhash/.prev_CMakeLists.txt12
-rw-r--r--tests/auto/corelib/tools/qhash/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/tools/qhashfunctions/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qlinkedlist/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/corelib/tools/qlinkedlist/CMakeLists.txt15
-rw-r--r--tests/auto/corelib/tools/qmakearray/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/tools/qmap/.prev_CMakeLists.txt12
-rw-r--r--tests/auto/corelib/tools/qmap/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/tools/qmargins/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qmessageauthenticationcode/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qpair/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/tools/qpoint/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qpointf/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qqueue/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qrect/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qringbuffer/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/tools/qscopedpointer/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qscopedvaluerollback/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qscopeguard/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qset/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/corelib/tools/qset/CMakeLists.txt15
-rw-r--r--tests/auto/corelib/tools/qsize/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qsizef/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qstl/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qtimeline/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/tools/qvarlengtharray/CMakeLists.txt13
-rw-r--r--tests/auto/dbus/CMakeLists.txt29
-rw-r--r--tests/auto/dbus/qdbusabstractadaptor/CMakeLists.txt14
-rw-r--r--tests/auto/dbus/qdbusabstractadaptor/qmyserver/.prev_CMakeLists.txt14
-rw-r--r--tests/auto/dbus/qdbusabstractadaptor/qmyserver/CMakeLists.txt15
-rw-r--r--tests/auto/dbus/qdbusabstractinterface/CMakeLists.txt21
-rw-r--r--tests/auto/dbus/qdbusabstractinterface/qdbusabstractinterface/.prev_CMakeLists.txt19
-rw-r--r--tests/auto/dbus/qdbusabstractinterface/qdbusabstractinterface/CMakeLists.txt9
-rw-r--r--tests/auto/dbus/qdbusabstractinterface/qpinger/.prev_CMakeLists.txt14
-rw-r--r--tests/auto/dbus/qdbusabstractinterface/qpinger/CMakeLists.txt15
-rw-r--r--tests/auto/dbus/qdbusconnection/CMakeLists.txt12
-rw-r--r--tests/auto/dbus/qdbusconnection_delayed/CMakeLists.txt14
-rw-r--r--tests/auto/dbus/qdbusconnection_no_app/CMakeLists.txt16
-rw-r--r--tests/auto/dbus/qdbusconnection_no_bus/CMakeLists.txt12
-rw-r--r--tests/auto/dbus/qdbusconnection_no_libdbus/CMakeLists.txt15
-rw-r--r--tests/auto/dbus/qdbusconnection_no_libdbus/tst_qdbusconnection_no_libdbus.cpp73
-rw-r--r--tests/auto/dbus/qdbusconnection_spyhook/CMakeLists.txt16
-rw-r--r--tests/auto/dbus/qdbuscontext/CMakeLists.txt12
-rw-r--r--tests/auto/dbus/qdbusinterface/CMakeLists.txt41
-rw-r--r--tests/auto/dbus/qdbusinterface/qmyserver/.prev_CMakeLists.txt14
-rw-r--r--tests/auto/dbus/qdbusinterface/qmyserver/CMakeLists.txt15
-rw-r--r--tests/auto/dbus/qdbusinterface/qmyserver/qmyserver.pro2
-rw-r--r--tests/auto/dbus/qdbusinterface/tst_qdbusinterface.cpp2
-rw-r--r--tests/auto/dbus/qdbuslocalcalls/CMakeLists.txt12
-rw-r--r--tests/auto/dbus/qdbusmarshall/CMakeLists.txt4
-rw-r--r--tests/auto/dbus/qdbusmarshall/qdbusmarshall/.prev_CMakeLists.txt32
-rw-r--r--tests/auto/dbus/qdbusmarshall/qdbusmarshall/CMakeLists.txt35
-rw-r--r--tests/auto/dbus/qdbusmarshall/qpong/CMakeLists.txt13
-rw-r--r--tests/auto/dbus/qdbusmetaobject/CMakeLists.txt14
-rw-r--r--tests/auto/dbus/qdbusmetatype/CMakeLists.txt12
-rw-r--r--tests/auto/dbus/qdbuspendingcall/CMakeLists.txt12
-rw-r--r--tests/auto/dbus/qdbuspendingreply/CMakeLists.txt12
-rw-r--r--tests/auto/dbus/qdbusreply/CMakeLists.txt12
-rw-r--r--tests/auto/dbus/qdbusservicewatcher/CMakeLists.txt12
-rw-r--r--tests/auto/dbus/qdbusthreading/CMakeLists.txt12
-rw-r--r--tests/auto/dbus/qdbustype/CMakeLists.txt30
-rw-r--r--tests/auto/dbus/qdbusxmlparser/CMakeLists.txt16
-rw-r--r--tests/auto/gui/.prev_CMakeLists.txt19
-rw-r--r--tests/auto/gui/CMakeLists.txt19
-rw-r--r--tests/auto/gui/image/CMakeLists.txt17
-rw-r--r--tests/auto/gui/image/qicoimageformat/CMakeLists.txt49
-rw-r--r--tests/auto/gui/image/qicon/CMakeLists.txt94
-rw-r--r--tests/auto/gui/image/qiconhighdpi/CMakeLists.txt37
-rw-r--r--tests/auto/gui/image/qimage/CMakeLists.txt67
-rw-r--r--tests/auto/gui/image/qimageiohandler/CMakeLists.txt12
-rw-r--r--tests/auto/gui/image/qimagereader/CMakeLists.txt66
-rw-r--r--tests/auto/gui/image/qimagewriter/CMakeLists.txt50
-rw-r--r--tests/auto/gui/image/qmovie/CMakeLists.txt56
-rw-r--r--tests/auto/gui/image/qpicture/CMakeLists.txt12
-rw-r--r--tests/auto/gui/image/qpixmap/CMakeLists.txt109
-rw-r--r--tests/auto/gui/image/qpixmapcache/CMakeLists.txt14
-rw-r--r--tests/auto/gui/itemmodels/CMakeLists.txt4
-rw-r--r--tests/auto/gui/itemmodels/qstandarditem/CMakeLists.txt12
-rw-r--r--tests/auto/gui/kernel/CMakeLists.txt38
-rw-r--r--tests/auto/gui/kernel/noqteventloop/CMakeLists.txt24
-rw-r--r--tests/auto/gui/kernel/qbackingstore/CMakeLists.txt15
-rw-r--r--tests/auto/gui/kernel/qclipboard/CMakeLists.txt7
-rw-r--r--tests/auto/gui/kernel/qclipboard/copier/CMakeLists.txt18
-rw-r--r--tests/auto/gui/kernel/qclipboard/paster/CMakeLists.txt18
-rw-r--r--tests/auto/gui/kernel/qclipboard/test/.prev_CMakeLists.txt24
-rw-r--r--tests/auto/gui/kernel/qclipboard/test/CMakeLists.txt24
-rw-r--r--tests/auto/gui/kernel/qcursor/CMakeLists.txt12
-rw-r--r--tests/auto/gui/kernel/qdrag/CMakeLists.txt12
-rw-r--r--tests/auto/gui/kernel/qevent/CMakeLists.txt10
-rw-r--r--tests/auto/gui/kernel/qfileopenevent/CMakeLists.txt4
-rw-r--r--tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/CMakeLists.txt16
-rw-r--r--tests/auto/gui/kernel/qfileopenevent/test/CMakeLists.txt12
-rw-r--r--tests/auto/gui/kernel/qguiapplication/.prev_CMakeLists.txt47
-rw-r--r--tests/auto/gui/kernel/qguiapplication/CMakeLists.txt48
-rw-r--r--tests/auto/gui/kernel/qguieventdispatcher/CMakeLists.txt12
-rw-r--r--tests/auto/gui/kernel/qguieventloop/.prev_CMakeLists.txt28
-rw-r--r--tests/auto/gui/kernel/qguieventloop/CMakeLists.txt28
-rw-r--r--tests/auto/gui/kernel/qguimetatype/CMakeLists.txt12
-rw-r--r--tests/auto/gui/kernel/qguitimer/.prev_CMakeLists.txt14
-rw-r--r--tests/auto/gui/kernel/qguitimer/CMakeLists.txt15
-rw-r--r--tests/auto/gui/kernel/qguivariant/CMakeLists.txt4
-rw-r--r--tests/auto/gui/kernel/qguivariant/no_application/CMakeLists.txt12
-rw-r--r--tests/auto/gui/kernel/qguivariant/test/CMakeLists.txt38
-rw-r--r--tests/auto/gui/kernel/qinputmethod/CMakeLists.txt15
-rw-r--r--tests/auto/gui/kernel/qkeyevent/CMakeLists.txt12
-rw-r--r--tests/auto/gui/kernel/qkeysequence/CMakeLists.txt29
-rw-r--r--tests/auto/gui/kernel/qmouseevent/CMakeLists.txt12
-rw-r--r--tests/auto/gui/kernel/qmouseevent_modal/CMakeLists.txt13
-rw-r--r--tests/auto/gui/kernel/qopenglwindow/CMakeLists.txt15
-rw-r--r--tests/auto/gui/kernel/qpalette/CMakeLists.txt12
-rw-r--r--tests/auto/gui/kernel/qpixelformat/CMakeLists.txt12
-rw-r--r--tests/auto/gui/kernel/qrasterwindow/CMakeLists.txt15
-rw-r--r--tests/auto/gui/kernel/qscreen/CMakeLists.txt15
-rw-r--r--tests/auto/gui/kernel/qsurfaceformat/CMakeLists.txt15
-rw-r--r--tests/auto/gui/kernel/qtouchevent/CMakeLists.txt15
-rw-r--r--tests/auto/gui/kernel/qwindow/CMakeLists.txt23
-rw-r--r--tests/auto/gui/math3d/CMakeLists.txt3
-rw-r--r--tests/auto/gui/math3d/qmatrixnxn/CMakeLists.txt14
-rw-r--r--tests/auto/gui/math3d/qquaternion/CMakeLists.txt12
-rw-r--r--tests/auto/gui/math3d/qvectornd/CMakeLists.txt12
-rw-r--r--tests/auto/gui/painting/CMakeLists.txt20
-rw-r--r--tests/auto/gui/painting/qpagesize/CMakeLists.txt14
-rw-r--r--tests/auto/gui/painting/qpaintengine/CMakeLists.txt12
-rw-r--r--tests/auto/gui/painting/qpainterpath/CMakeLists.txt12
-rw-r--r--tests/auto/gui/painting/qpainterpathstroker/CMakeLists.txt12
-rw-r--r--tests/auto/gui/painting/qpen/CMakeLists.txt12
-rw-r--r--tests/auto/gui/qopengl/CMakeLists.txt23
-rw-r--r--tests/auto/gui/qopenglconfig/CMakeLists.txt19
-rw-r--r--tests/auto/gui/qvulkan/CMakeLists.txt15
-rw-r--r--tests/auto/gui/rhi/CMakeLists.txt4
-rw-r--r--tests/auto/gui/rhi/qrhi/CMakeLists.txt27
-rw-r--r--tests/auto/gui/rhi/qshader/CMakeLists.txt27
-rw-r--r--tests/auto/gui/text/CMakeLists.txt41
-rw-r--r--tests/auto/gui/text/qabstracttextdocumentlayout/CMakeLists.txt12
-rw-r--r--tests/auto/gui/text/qcssparser/CMakeLists.txt58
-rw-r--r--tests/auto/gui/text/qfont/CMakeLists.txt36
-rw-r--r--tests/auto/gui/text/qfontcache/CMakeLists.txt15
-rw-r--r--tests/auto/gui/text/qfontdatabase/CMakeLists.txt44
-rw-r--r--tests/auto/gui/text/qfontmetrics/CMakeLists.txt32
-rw-r--r--tests/auto/gui/text/qglyphrun/CMakeLists.txt28
-rw-r--r--tests/auto/gui/text/qinputcontrol/CMakeLists.txt14
-rw-r--r--tests/auto/gui/text/qrawfont/CMakeLists.txt33
-rw-r--r--tests/auto/gui/text/qstatictext/CMakeLists.txt24
-rw-r--r--tests/auto/gui/text/qsyntaxhighlighter/CMakeLists.txt20
-rw-r--r--tests/auto/gui/text/qtextblock/CMakeLists.txt15
-rw-r--r--tests/auto/gui/text/qtextcursor/CMakeLists.txt15
-rw-r--r--tests/auto/gui/text/qtextdocument/CMakeLists.txt17
-rw-r--r--tests/auto/gui/text/qtextdocumentfragment/CMakeLists.txt15
-rw-r--r--tests/auto/gui/text/qtextdocumentlayout/CMakeLists.txt20
-rw-r--r--tests/auto/gui/text/qtextformat/CMakeLists.txt15
-rw-r--r--tests/auto/gui/text/qtextlayout/CMakeLists.txt15
-rw-r--r--tests/auto/gui/text/qtextlist/CMakeLists.txt16
-rw-r--r--tests/auto/gui/text/qtextmarkdownimporter/CMakeLists.txt22
-rw-r--r--tests/auto/gui/text/qtextmarkdownwriter/CMakeLists.txt22
-rw-r--r--tests/auto/gui/text/qtextobject/CMakeLists.txt20
-rw-r--r--tests/auto/gui/text/qtextodfwriter/CMakeLists.txt17
-rw-r--r--tests/auto/gui/text/qtextpiecetable/CMakeLists.txt26
-rw-r--r--tests/auto/gui/text/qtextscriptengine/CMakeLists.txt15
-rw-r--r--tests/auto/gui/text/qtextscriptengine/generate/CMakeLists.txt18
-rw-r--r--tests/auto/gui/text/qtexttable/CMakeLists.txt22
-rw-r--r--tests/auto/gui/text/qzip/CMakeLists.txt36
-rw-r--r--tests/auto/gui/util/CMakeLists.txt13
-rw-r--r--tests/auto/gui/util/qdesktopservices/.prev_CMakeLists.txt14
-rw-r--r--tests/auto/gui/util/qdesktopservices/CMakeLists.txt14
-rw-r--r--tests/auto/gui/util/qdoublevalidator/CMakeLists.txt12
-rw-r--r--tests/auto/gui/util/qintvalidator/CMakeLists.txt12
-rw-r--r--tests/auto/gui/util/qregexpvalidator/CMakeLists.txt12
-rw-r--r--tests/auto/gui/util/qregularexpressionvalidator/CMakeLists.txt12
-rw-r--r--tests/auto/gui/util/qshadergenerator/CMakeLists.txt14
-rw-r--r--tests/auto/gui/util/qshadergraph/CMakeLists.txt14
-rw-r--r--tests/auto/gui/util/qshadergraphloader/CMakeLists.txt14
-rw-r--r--tests/auto/gui/util/qshadernodes/CMakeLists.txt14
-rw-r--r--tests/auto/gui/util/qshadernodesloader/CMakeLists.txt14
-rw-r--r--tests/auto/gui/util/qtexturefilereader/CMakeLists.txt31
-rw-r--r--tests/auto/network/CMakeLists.txt21
-rw-r--r--tests/auto/network/access/CMakeLists.txt20
-rw-r--r--tests/auto/network/access/hpack/CMakeLists.txt18
-rw-r--r--tests/auto/network/access/hsts/CMakeLists.txt18
-rw-r--r--tests/auto/network/access/http2/CMakeLists.txt21
-rw-r--r--tests/auto/network/access/qabstractnetworkcache/CMakeLists.txt22
-rw-r--r--tests/auto/network/access/qftp/CMakeLists.txt22
-rw-r--r--tests/auto/network/access/qhttpnetworkconnection/CMakeLists.txt23
-rw-r--r--tests/auto/network/access/qhttpnetworkreply/CMakeLists.txt22
-rw-r--r--tests/auto/network/access/qnetworkaccessmanager/CMakeLists.txt12
-rw-r--r--tests/auto/network/access/qnetworkcachemetadata/CMakeLists.txt12
-rw-r--r--tests/auto/network/access/qnetworkcookie/CMakeLists.txt12
-rw-r--r--tests/auto/network/access/qnetworkcookiejar/CMakeLists.txt19
-rw-r--r--tests/auto/network/access/qnetworkdiskcache/CMakeLists.txt12
-rw-r--r--tests/auto/network/access/qnetworkreply/CMakeLists.txt7
-rw-r--r--tests/auto/network/access/qnetworkreply/echo/.prev_CMakeLists.txt10
-rw-r--r--tests/auto/network/access/qnetworkreply/echo/CMakeLists.txt11
-rw-r--r--tests/auto/network/access/qnetworkreply/test/CMakeLists.txt61
-rw-r--r--tests/auto/network/access/qnetworkreply/test/test.pro2
-rw-r--r--tests/auto/network/access/qnetworkrequest/CMakeLists.txt12
-rw-r--r--tests/auto/network/bearer/CMakeLists.txt6
-rw-r--r--tests/auto/network/bearer/qnetworkconfiguration/CMakeLists.txt13
-rw-r--r--tests/auto/network/bearer/qnetworkconfigurationmanager/CMakeLists.txt13
-rw-r--r--tests/auto/network/bearer/qnetworkconfigurationmanagerqappless/CMakeLists.txt13
-rw-r--r--tests/auto/network/bearer/qnetworksession/CMakeLists.txt7
-rw-r--r--tests/auto/network/bearer/qnetworksession/lackey/CMakeLists.txt13
-rw-r--r--tests/auto/network/bearer/qnetworksession/test/.prev_CMakeLists.txt30
-rw-r--r--tests/auto/network/bearer/qnetworksession/test/CMakeLists.txt31
-rw-r--r--tests/auto/network/kernel/CMakeLists.txt19
-rw-r--r--tests/auto/network/kernel/qauthenticator/CMakeLists.txt23
-rw-r--r--tests/auto/network/kernel/qdnslookup/CMakeLists.txt12
-rw-r--r--tests/auto/network/kernel/qdnslookup_appless/CMakeLists.txt12
-rw-r--r--tests/auto/network/kernel/qhostaddress/CMakeLists.txt22
-rw-r--r--tests/auto/network/kernel/qhostinfo/CMakeLists.txt33
-rw-r--r--tests/auto/network/kernel/qnetworkaddressentry/CMakeLists.txt12
-rw-r--r--tests/auto/network/kernel/qnetworkdatagram/CMakeLists.txt12
-rw-r--r--tests/auto/network/kernel/qnetworkinterface/CMakeLists.txt15
-rw-r--r--tests/auto/network/kernel/qnetworkproxy/CMakeLists.txt12
-rw-r--r--tests/auto/network/kernel/qnetworkproxyfactory/CMakeLists.txt14
-rw-r--r--tests/auto/network/socket/CMakeLists.txt20
-rw-r--r--tests/auto/network/socket/platformsocketengine/CMakeLists.txt40
-rw-r--r--tests/auto/network/socket/platformsocketengine/platformsocketengine.pri2
-rw-r--r--tests/auto/network/socket/qabstractsocket/CMakeLists.txt12
-rw-r--r--tests/auto/network/socket/qhttpsocketengine/CMakeLists.txt43
-rw-r--r--tests/auto/network/socket/qlocalsocket/CMakeLists.txt4
-rw-r--r--tests/auto/network/socket/qlocalsocket/socketprocess/CMakeLists.txt14
-rw-r--r--tests/auto/network/socket/qlocalsocket/test/CMakeLists.txt28
-rw-r--r--tests/auto/network/socket/qsctpsocket/CMakeLists.txt12
-rw-r--r--tests/auto/network/socket/qsocks5socketengine/CMakeLists.txt43
-rw-r--r--tests/auto/network/socket/qtcpserver/CMakeLists.txt4
-rw-r--r--tests/auto/network/socket/qtcpserver/crashingServer/CMakeLists.txt16
-rw-r--r--tests/auto/network/socket/qtcpserver/test/CMakeLists.txt26
-rw-r--r--tests/auto/network/socket/qtcpserver/test/test.pro6
-rw-r--r--tests/auto/network/socket/qtcpsocket/CMakeLists.txt7
-rw-r--r--tests/auto/network/socket/qtcpsocket/stressTest/CMakeLists.txt19
-rw-r--r--tests/auto/network/socket/qtcpsocket/test/.prev_CMakeLists.txt35
-rw-r--r--tests/auto/network/socket/qtcpsocket/test/CMakeLists.txt41
-rw-r--r--tests/auto/network/socket/qudpsocket/CMakeLists.txt4
-rw-r--r--tests/auto/network/socket/qudpsocket/clientserver/CMakeLists.txt13
-rw-r--r--tests/auto/network/socket/qudpsocket/test/CMakeLists.txt33
-rw-r--r--tests/auto/network/socket/qudpsocket/udpServer/.prev_CMakeLists.txt12
-rw-r--r--tests/auto/network/socket/qudpsocket/udpServer/CMakeLists.txt13
-rw-r--r--tests/auto/network/ssl/CMakeLists.txt36
-rw-r--r--tests/auto/network/ssl/qasn1element/CMakeLists.txt14
-rw-r--r--tests/auto/network/ssl/qdtls/CMakeLists.txt27
-rw-r--r--tests/auto/network/ssl/qdtlscookie/CMakeLists.txt23
-rw-r--r--tests/auto/network/ssl/qocsp/CMakeLists.txt23
-rw-r--r--tests/auto/network/ssl/qpassworddigestor/CMakeLists.txt12
-rw-r--r--tests/auto/network/ssl/qsslcertificate/CMakeLists.txt31
-rw-r--r--tests/auto/network/ssl/qsslcipher/CMakeLists.txt21
-rw-r--r--tests/auto/network/ssl/qssldiffiehellmanparameters/CMakeLists.txt12
-rw-r--r--tests/auto/network/ssl/qsslellipticcurve/CMakeLists.txt12
-rw-r--r--tests/auto/network/ssl/qsslerror/CMakeLists.txt21
-rw-r--r--tests/auto/network/ssl/qsslkey/CMakeLists.txt35
-rw-r--r--tests/auto/network/ssl/qsslsocket/CMakeLists.txt40
-rw-r--r--tests/auto/network/ssl/qsslsocket_onDemandCertificates_member/CMakeLists.txt37
-rw-r--r--tests/auto/network/ssl/qsslsocket_onDemandCertificates_static/CMakeLists.txt36
-rw-r--r--tests/auto/opengl/CMakeLists.txt6
-rw-r--r--tests/auto/opengl/qgl/CMakeLists.txt42
-rw-r--r--tests/auto/opengl/qglbuffer/CMakeLists.txt21
-rw-r--r--tests/auto/opengl/qglfunctions/CMakeLists.txt21
-rw-r--r--tests/auto/other/CMakeLists.txt49
-rw-r--r--tests/auto/other/android/CMakeLists.txt19
-rw-r--r--tests/auto/other/compiler/.prev_CMakeLists.txt16
-rw-r--r--tests/auto/other/compiler/CMakeLists.txt17
-rw-r--r--tests/auto/other/gestures/CMakeLists.txt13
-rw-r--r--tests/auto/other/lancelot/CMakeLists.txt80
-rw-r--r--tests/auto/other/languagechange/CMakeLists.txt22
-rw-r--r--tests/auto/other/macgui/.prev_CMakeLists.txt34
-rw-r--r--tests/auto/other/macgui/CMakeLists.txt34
-rw-r--r--tests/auto/other/macnativeevents/CMakeLists.txt27
-rw-r--r--tests/auto/other/macplist/CMakeLists.txt7
-rw-r--r--tests/auto/other/macplist/app/.prev_CMakeLists.txt14
-rw-r--r--tests/auto/other/macplist/app/CMakeLists.txt15
-rw-r--r--tests/auto/other/macplist/test/CMakeLists.txt16
-rw-r--r--tests/auto/other/networkselftest/CMakeLists.txt14
-rw-r--r--tests/auto/other/qaccessibility/.prev_CMakeLists.txt49
-rw-r--r--tests/auto/other/qaccessibility/CMakeLists.txt55
-rw-r--r--tests/auto/other/qaccessibilitylinux/.prev_CMakeLists.txt22
-rw-r--r--tests/auto/other/qaccessibilitylinux/CMakeLists.txt35
-rw-r--r--tests/auto/other/qaccessibilitymac/CMakeLists.txt33
-rw-r--r--tests/auto/other/qcomplextext/CMakeLists.txt42
-rw-r--r--tests/auto/other/qfocusevent/CMakeLists.txt15
-rw-r--r--tests/auto/other/qnetworkaccessmanager_and_qprogressdialog/CMakeLists.txt14
-rw-r--r--tests/auto/other/qobjectrace/CMakeLists.txt13
-rw-r--r--tests/auto/other/qprocess_and_guieventloop/CMakeLists.txt13
-rw-r--r--tests/auto/other/qprocess_and_guieventloop/write-read-write/CMakeLists.txt13
-rw-r--r--tests/auto/other/qsharedpointer_and_qwidget/CMakeLists.txt15
-rw-r--r--tests/auto/other/qtokenautomaton/CMakeLists.txt16
-rw-r--r--tests/auto/other/toolsupport/CMakeLists.txt12
-rw-r--r--tests/auto/other/xkbkeyboard/CMakeLists.txt15
-rw-r--r--tests/auto/printsupport/CMakeLists.txt4
-rw-r--r--tests/auto/printsupport/dialogs/CMakeLists.txt3
-rw-r--r--tests/auto/printsupport/dialogs/qabstractprintdialog/CMakeLists.txt14
-rw-r--r--tests/auto/printsupport/kernel/CMakeLists.txt5
-rw-r--r--tests/auto/printsupport/kernel/qprintdevice/CMakeLists.txt17
-rw-r--r--tests/auto/printsupport/kernel/qprinter/CMakeLists.txt14
-rw-r--r--tests/auto/printsupport/kernel/qprinterinfo/CMakeLists.txt15
-rw-r--r--tests/auto/sql/CMakeLists.txt4
-rw-r--r--tests/auto/sql/kernel/CMakeLists.txt9
-rw-r--r--tests/auto/sql/kernel/qsql/CMakeLists.txt15
-rw-r--r--tests/auto/sql/kernel/qsqldatabase/CMakeLists.txt15
-rw-r--r--tests/auto/sql/kernel/qsqldriver/CMakeLists.txt15
-rw-r--r--tests/auto/sql/kernel/qsqlerror/CMakeLists.txt12
-rw-r--r--tests/auto/sql/kernel/qsqlfield/CMakeLists.txt12
-rw-r--r--tests/auto/sql/kernel/qsqlquery/CMakeLists.txt15
-rw-r--r--tests/auto/sql/kernel/qsqlrecord/CMakeLists.txt12
-rw-r--r--tests/auto/sql/kernel/qsqlresult/CMakeLists.txt16
-rw-r--r--tests/auto/sql/kernel/qsqlthread/CMakeLists.txt15
-rw-r--r--tests/auto/sql/models/CMakeLists.txt6
-rw-r--r--tests/auto/sql/models/qsqlquerymodel/CMakeLists.txt17
-rw-r--r--tests/auto/sql/models/qsqlrelationaldelegate/CMakeLists.txt16
-rw-r--r--tests/auto/sql/models/qsqlrelationaltablemodel/CMakeLists.txt15
-rw-r--r--tests/auto/sql/models/qsqltablemodel/CMakeLists.txt15
-rw-r--r--tests/auto/testlib/.prev_CMakeLists.txt8
-rw-r--r--tests/auto/testlib/CMakeLists.txt8
-rw-r--r--tests/auto/testlib/qabstractitemmodeltester/CMakeLists.txt16
-rw-r--r--tests/auto/testlib/qsignalspy/CMakeLists.txt10
-rw-r--r--tests/auto/testlib/selftests/.prev_CMakeLists.txt9
-rw-r--r--tests/auto/testlib/selftests/CMakeLists.txt411
-rw-r--r--tests/auto/testlib/selftests/assert/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/assert/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/badxml/.prev_CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/badxml/CMakeLists.txt19
-rw-r--r--tests/auto/testlib/selftests/benchlibcallgrind/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/benchlibcallgrind/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/benchlibcounting/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/benchlibcounting/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/benchlibeventcounter/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/benchlibeventcounter/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/benchliboptions/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/benchliboptions/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/benchlibtickcounter/.prev_CMakeLists.txt18
-rw-r--r--tests/auto/testlib/selftests/benchlibtickcounter/CMakeLists.txt20
-rw-r--r--tests/auto/testlib/selftests/benchlibwalltime/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/benchlibwalltime/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/blacklisted/.prev_CMakeLists.txt18
-rw-r--r--tests/auto/testlib/selftests/blacklisted/CMakeLists.txt20
-rw-r--r--tests/auto/testlib/selftests/cmptest/.prev_CMakeLists.txt20
-rw-r--r--tests/auto/testlib/selftests/cmptest/CMakeLists.txt22
-rw-r--r--tests/auto/testlib/selftests/commandlinedata/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/commandlinedata/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/counting/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/counting/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/crashes/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/crashes/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/datatable/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/datatable/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/datetime/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/datetime/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/deleteLater/.prev_CMakeLists.txt12
-rw-r--r--tests/auto/testlib/selftests/deleteLater/CMakeLists.txt14
-rw-r--r--tests/auto/testlib/selftests/deleteLater_noApp/.prev_CMakeLists.txt12
-rw-r--r--tests/auto/testlib/selftests/deleteLater_noApp/CMakeLists.txt14
-rw-r--r--tests/auto/testlib/selftests/differentexec/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/differentexec/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/exceptionthrow/.prev_CMakeLists.txt16
-rw-r--r--tests/auto/testlib/selftests/exceptionthrow/CMakeLists.txt18
-rw-r--r--tests/auto/testlib/selftests/expectfail/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/expectfail/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/failcleanup/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/failcleanup/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/faildatatype/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/faildatatype/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/failfetchtype/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/failfetchtype/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/failinit/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/failinit/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/failinitdata/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/failinitdata/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/fetchbogus/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/fetchbogus/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/findtestdata/.prev_CMakeLists.txt28
-rw-r--r--tests/auto/testlib/selftests/findtestdata/CMakeLists.txt30
-rw-r--r--tests/auto/testlib/selftests/float/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/float/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/globaldata/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/globaldata/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/keyboard/.prev_CMakeLists.txt19
-rw-r--r--tests/auto/testlib/selftests/keyboard/CMakeLists.txt21
-rw-r--r--tests/auto/testlib/selftests/longstring/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/longstring/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/maxwarnings/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/maxwarnings/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/mouse/.prev_CMakeLists.txt19
-rw-r--r--tests/auto/testlib/selftests/mouse/CMakeLists.txt21
-rw-r--r--tests/auto/testlib/selftests/multiexec/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/multiexec/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/pairdiagnostics/.prev_CMakeLists.txt12
-rw-r--r--tests/auto/testlib/selftests/pairdiagnostics/CMakeLists.txt14
-rw-r--r--tests/auto/testlib/selftests/printdatatags/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/printdatatags/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/printdatatagswithglobaltags/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/printdatatagswithglobaltags/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/qexecstringlist/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/qexecstringlist/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/signaldumper/.prev_CMakeLists.txt18
-rw-r--r--tests/auto/testlib/selftests/signaldumper/CMakeLists.txt20
-rw-r--r--tests/auto/testlib/selftests/silent/.prev_CMakeLists.txt18
-rw-r--r--tests/auto/testlib/selftests/silent/CMakeLists.txt20
-rw-r--r--tests/auto/testlib/selftests/singleskip/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/singleskip/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/skip/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/skip/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/skipcleanup/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/skipcleanup/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/skipinit/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/skipinit/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/skipinitdata/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/skipinitdata/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/sleep/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/sleep/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/strcmp/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/strcmp/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/subtest/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/subtest/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/testlib/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/testlib/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/tuplediagnostics/.prev_CMakeLists.txt12
-rw-r--r--tests/auto/testlib/selftests/tuplediagnostics/CMakeLists.txt14
-rw-r--r--tests/auto/testlib/selftests/verbose1/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/verbose1/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/verbose2/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/verbose2/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/verifyexceptionthrown/.prev_CMakeLists.txt16
-rw-r--r--tests/auto/testlib/selftests/verifyexceptionthrown/CMakeLists.txt18
-rw-r--r--tests/auto/testlib/selftests/warnings/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/warnings/CMakeLists.txt17
-rw-r--r--tests/auto/testlib/selftests/watchdog/.prev_CMakeLists.txt20
-rw-r--r--tests/auto/testlib/selftests/watchdog/CMakeLists.txt22
-rw-r--r--tests/auto/testlib/selftests/xunit/.prev_CMakeLists.txt15
-rw-r--r--tests/auto/testlib/selftests/xunit/CMakeLists.txt17
-rw-r--r--tests/auto/tools/CMakeLists.txt17
-rw-r--r--tests/auto/tools/qdbuscpp2xml/CMakeLists.txt26
-rw-r--r--tests/auto/tools/qdbusxml2cpp/CMakeLists.txt10
-rw-r--r--tests/auto/tools/qmake/.prev_CMakeLists.txt39
-rw-r--r--tests/auto/tools/qmake/CMakeLists.txt42
-rw-r--r--tests/auto/tools/qmake/tst_qmake.cpp3
-rw-r--r--tests/auto/tools/qmakelib/CMakeLists.txt34
-rw-r--r--tests/auto/tools/uic/CMakeLists.txt10
-rw-r--r--tests/auto/widgets/CMakeLists.txt10
-rw-r--r--tests/auto/widgets/dialogs/CMakeLists.txt19
-rw-r--r--tests/auto/widgets/dialogs/qcolordialog/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/dialogs/qdialog/CMakeLists.txt16
-rw-r--r--tests/auto/widgets/dialogs/qerrormessage/CMakeLists.txt16
-rw-r--r--tests/auto/widgets/dialogs/qfiledialog/CMakeLists.txt19
-rw-r--r--tests/auto/widgets/dialogs/qfiledialog2/CMakeLists.txt19
-rw-r--r--tests/auto/widgets/dialogs/qfilesystemmodel/CMakeLists.txt28
-rw-r--r--tests/auto/widgets/dialogs/qfontdialog/CMakeLists.txt40
-rw-r--r--tests/auto/widgets/dialogs/qinputdialog/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/dialogs/qmessagebox/CMakeLists.txt19
-rw-r--r--tests/auto/widgets/dialogs/qprogressdialog/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/dialogs/qsidebar/CMakeLists.txt16
-rw-r--r--tests/auto/widgets/dialogs/qwizard/CMakeLists.txt30
-rw-r--r--tests/auto/widgets/effects/CMakeLists.txt2
-rw-r--r--tests/auto/widgets/effects/qgraphicseffect/CMakeLists.txt17
-rw-r--r--tests/auto/widgets/effects/qpixmapfilter/CMakeLists.txt16
-rw-r--r--tests/auto/widgets/graphicsview/CMakeLists.txt25
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt17
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsanchorlayout1/CMakeLists.txt17
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicseffectsource/CMakeLists.txt17
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsgridlayout/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsitem/CMakeLists.txt28
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsitemanimation/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicslayout/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicslayoutitem/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsobject/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicspixmapitem/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicspolygonitem/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsproxywidget/CMakeLists.txt19
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsscene/CMakeLists.txt78
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicssceneindex/CMakeLists.txt24
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicstransform/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsview/CMakeLists.txt24
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicswidget/CMakeLists.txt17
-rw-r--r--tests/auto/widgets/itemviews/CMakeLists.txt21
-rw-r--r--tests/auto/widgets/itemviews/qabstractitemview/CMakeLists.txt16
-rw-r--r--tests/auto/widgets/itemviews/qcolumnview/CMakeLists.txt19
-rw-r--r--tests/auto/widgets/itemviews/qdatawidgetmapper/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/itemviews/qdirmodel/CMakeLists.txt49
-rw-r--r--tests/auto/widgets/itemviews/qfileiconprovider/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/itemviews/qheaderview/CMakeLists.txt19
-rw-r--r--tests/auto/widgets/itemviews/qitemdelegate/CMakeLists.txt23
-rw-r--r--tests/auto/widgets/itemviews/qitemeditorfactory/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/itemviews/qitemview/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/itemviews/qlistview/CMakeLists.txt26
-rw-r--r--tests/auto/widgets/itemviews/qlistwidget/CMakeLists.txt17
-rw-r--r--tests/auto/widgets/itemviews/qtableview/CMakeLists.txt18
-rw-r--r--tests/auto/widgets/itemviews/qtablewidget/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/itemviews/qtreeview/CMakeLists.txt19
-rw-r--r--tests/auto/widgets/itemviews/qtreewidget/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/itemviews/qtreewidgetitemiterator/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/kernel/CMakeLists.txt23
-rw-r--r--tests/auto/widgets/kernel/kernel.pro2
-rw-r--r--tests/auto/widgets/kernel/qaction/CMakeLists.txt16
-rw-r--r--tests/auto/widgets/kernel/qactiongroup/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/kernel/qapplication/CMakeLists.txt7
-rw-r--r--tests/auto/widgets/kernel/qapplication/desktopsettingsaware/.prev_CMakeLists.txt16
-rw-r--r--tests/auto/widgets/kernel/qapplication/desktopsettingsaware/CMakeLists.txt18
-rw-r--r--tests/auto/widgets/kernel/qapplication/modal/.prev_CMakeLists.txt17
-rw-r--r--tests/auto/widgets/kernel/qapplication/modal/CMakeLists.txt19
-rw-r--r--tests/auto/widgets/kernel/qapplication/test/.prev_CMakeLists.txt43
-rw-r--r--tests/auto/widgets/kernel/qapplication/test/CMakeLists.txt44
-rw-r--r--tests/auto/widgets/kernel/qboxlayout/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/kernel/qdesktopwidget/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/kernel/qformlayout/CMakeLists.txt16
-rw-r--r--tests/auto/widgets/kernel/qgesturerecognizer/CMakeLists.txt16
-rw-r--r--tests/auto/widgets/kernel/qgridlayout/CMakeLists.txt21
-rw-r--r--tests/auto/widgets/kernel/qlayout/CMakeLists.txt40
-rw-r--r--tests/auto/widgets/kernel/qshortcut/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/kernel/qsizepolicy/CMakeLists.txt18
-rw-r--r--tests/auto/widgets/kernel/qstackedlayout/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/kernel/qtooltip/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/kernel/qwidget/CMakeLists.txt58
-rw-r--r--tests/auto/widgets/kernel/qwidget_window/CMakeLists.txt17
-rw-r--r--tests/auto/widgets/kernel/qwidgetaction/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/kernel/qwidgetmetatype/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/kernel/qwidgetsvariant/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/kernel/qwindowcontainer/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/styles/CMakeLists.txt12
-rw-r--r--tests/auto/widgets/styles/qmacstyle/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/styles/qstyle/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/styles/qstyleoption/CMakeLists.txt16
-rw-r--r--tests/auto/widgets/styles/qstylesheetstyle/CMakeLists.txt38
-rw-r--r--tests/auto/widgets/util/CMakeLists.txt7
-rw-r--r--tests/auto/widgets/util/qcompleter/CMakeLists.txt18
-rw-r--r--tests/auto/widgets/util/qscroller/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/util/qsystemtrayicon/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/util/qundogroup/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/util/qundostack/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/CMakeLists.txt55
-rw-r--r--tests/auto/widgets/widgets/qabstractbutton/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/widgets/qabstractscrollarea/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qabstractslider/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/widgets/qabstractspinbox/CMakeLists.txt17
-rw-r--r--tests/auto/widgets/widgets/qbuttongroup/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qcalendarwidget/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qcheckbox/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qcombobox/CMakeLists.txt25
-rw-r--r--tests/auto/widgets/widgets/qcommandlinkbutton/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qdatetimeedit/CMakeLists.txt16
-rw-r--r--tests/auto/widgets/widgets/qdial/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qdialogbuttonbox/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qdockwidget/CMakeLists.txt17
-rw-r--r--tests/auto/widgets/widgets/qdoublespinbox/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qfocusframe/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qfontcombobox/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qframe/CMakeLists.txt20
-rw-r--r--tests/auto/widgets/widgets/qgroupbox/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qkeysequenceedit/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qlabel/CMakeLists.txt28
-rw-r--r--tests/auto/widgets/widgets/qlcdnumber/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qlineedit/CMakeLists.txt26
-rw-r--r--tests/auto/widgets/widgets/qmainwindow/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/widgets/qmdiarea/CMakeLists.txt33
-rw-r--r--tests/auto/widgets/widgets/qmdisubwindow/CMakeLists.txt20
-rw-r--r--tests/auto/widgets/widgets/qmenu/CMakeLists.txt31
-rw-r--r--tests/auto/widgets/widgets/qmenubar/CMakeLists.txt25
-rw-r--r--tests/auto/widgets/widgets/qopenglwidget/CMakeLists.txt16
-rw-r--r--tests/auto/widgets/widgets/qplaintextedit/CMakeLists.txt26
-rw-r--r--tests/auto/widgets/widgets/qprogressbar/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qpushbutton/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qradiobutton/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qscrollarea/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qscrollbar/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/widgets/qsizegrip/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/widgets/qslider/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qspinbox/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qsplashscreen/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qsplitter/CMakeLists.txt18
-rw-r--r--tests/auto/widgets/widgets/qstackedwidget/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qstatusbar/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qtabbar/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qtabwidget/CMakeLists.txt25
-rw-r--r--tests/auto/widgets/widgets/qtextbrowser/CMakeLists.txt37
-rw-r--r--tests/auto/widgets/widgets/qtextedit/CMakeLists.txt29
-rw-r--r--tests/auto/widgets/widgets/qtoolbar/CMakeLists.txt16
-rw-r--r--tests/auto/widgets/widgets/qtoolbox/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qtoolbutton/CMakeLists.txt13
-rw-r--r--tests/auto/xml/CMakeLists.txt4
-rw-r--r--tests/auto/xml/dom/CMakeLists.txt3
-rw-r--r--tests/auto/xml/dom/qdom/CMakeLists.txt21
-rw-r--r--tests/auto/xml/sax/CMakeLists.txt7
-rw-r--r--tests/auto/xml/sax/qxml/CMakeLists.txt16
-rw-r--r--tests/auto/xml/sax/qxmlinputsource/CMakeLists.txt13
-rw-r--r--tests/auto/xml/sax/qxmlsimplereader/CMakeLists.txt27
-rw-r--r--tests/auto/xml/sax/qxmlsimplereader/parser/CMakeLists.txt19
-rw-r--r--tests/benchmarks/CMakeLists.txt19
-rw-r--r--tests/benchmarks/corelib/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/codecs/CMakeLists.txt3
-rw-r--r--tests/benchmarks/corelib/codecs/qtextcodec/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/io/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/io/qdir/10000/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/io/qdir/CMakeLists.txt3
-rw-r--r--tests/benchmarks/corelib/io/qdir/tree/CMakeLists.txt28
-rw-r--r--tests/benchmarks/corelib/io/qdiriterator/CMakeLists.txt16
-rw-r--r--tests/benchmarks/corelib/io/qfile/CMakeLists.txt25
-rw-r--r--tests/benchmarks/corelib/io/qfileinfo/CMakeLists.txt17
-rw-r--r--tests/benchmarks/corelib/io/qiodevice/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/io/qprocess/CMakeLists.txt4
-rw-r--r--tests/benchmarks/corelib/io/qprocess/test/CMakeLists.txt14
-rw-r--r--tests/benchmarks/corelib/io/qprocess/testProcessLoopback/CMakeLists.txt21
-rw-r--r--tests/benchmarks/corelib/io/qtemporaryfile/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/io/qtextstream/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/io/qurl/CMakeLists.txt23
-rw-r--r--tests/benchmarks/corelib/json/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/kernel/CMakeLists.txt11
-rw-r--r--tests/benchmarks/corelib/kernel/events/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/kernel/qcoreapplication/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/kernel/qmetaobject/CMakeLists.txt17
-rw-r--r--tests/benchmarks/corelib/kernel/qmetatype/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/kernel/qobject/CMakeLists.txt18
-rw-r--r--tests/benchmarks/corelib/kernel/qtimer_vs_qmetaobject/.prev_CMakeLists.txt17
-rw-r--r--tests/benchmarks/corelib/kernel/qtimer_vs_qmetaobject/CMakeLists.txt18
-rw-r--r--tests/benchmarks/corelib/kernel/qvariant/CMakeLists.txt21
-rw-r--r--tests/benchmarks/corelib/mimetypes/CMakeLists.txt3
-rw-r--r--tests/benchmarks/corelib/mimetypes/qmimedatabase/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/plugin/CMakeLists.txt3
-rw-r--r--tests/benchmarks/corelib/plugin/quuid/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/text/CMakeLists.txt10
-rw-r--r--tests/benchmarks/corelib/text/qbytearray/CMakeLists.txt16
-rw-r--r--tests/benchmarks/corelib/text/qchar/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/text/qlocale/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/text/qregexp/CMakeLists.txt46
-rw-r--r--tests/benchmarks/corelib/text/qstring/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/text/qstringbuilder/CMakeLists.txt18
-rw-r--r--tests/benchmarks/corelib/text/qstringlist/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/thread/CMakeLists.txt7
-rw-r--r--tests/benchmarks/corelib/thread/qmutex/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/thread/qreadwritelock/CMakeLists.txt17
-rw-r--r--tests/benchmarks/corelib/thread/qthreadpool/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/thread/qthreadstorage/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/thread/qwaitcondition/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/time/CMakeLists.txt5
-rw-r--r--tests/benchmarks/corelib/time/qdate/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/time/qdatetime/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/time/qtimezone/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/tools/CMakeLists.txt13
-rw-r--r--tests/benchmarks/corelib/tools/containers-associative/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/tools/containers-sequential/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/tools/qalgorithms/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/tools/qchar/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/tools/qcontiguouscache/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/tools/qcryptographichash/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/tools/qdatetime/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/tools/qhash/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/tools/qlist/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/tools/qlocale/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/tools/qmap/CMakeLists.txt14
-rw-r--r--tests/benchmarks/corelib/tools/qrect/CMakeLists.txt15
-rw-r--r--tests/benchmarks/corelib/tools/qringbuffer/CMakeLists.txt17
-rw-r--r--tests/benchmarks/corelib/tools/qset/CMakeLists.txt12
-rw-r--r--tests/benchmarks/corelib/tools/qstack/CMakeLists.txt14
-rw-r--r--tests/benchmarks/corelib/tools/qstring/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/tools/qtimezone/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/tools/qvector/CMakeLists.txt17
-rw-r--r--tests/benchmarks/dbus/CMakeLists.txt6
-rw-r--r--tests/benchmarks/dbus/qdbusperformance/CMakeLists.txt4
-rw-r--r--tests/benchmarks/dbus/qdbusperformance/server/CMakeLists.txt15
-rw-r--r--tests/benchmarks/dbus/qdbusperformance/test/CMakeLists.txt14
-rw-r--r--tests/benchmarks/dbus/qdbustype/CMakeLists.txt31
-rw-r--r--tests/benchmarks/gui/CMakeLists.txt8
-rw-r--r--tests/benchmarks/gui/animation/CMakeLists.txt5
-rw-r--r--tests/benchmarks/gui/animation/qanimation/CMakeLists.txt17
-rw-r--r--tests/benchmarks/gui/image/CMakeLists.txt8
-rw-r--r--tests/benchmarks/gui/image/blendbench/CMakeLists.txt16
-rw-r--r--tests/benchmarks/gui/image/qimageconversion/CMakeLists.txt30
-rw-r--r--tests/benchmarks/gui/image/qimagereader/CMakeLists.txt31
-rw-r--r--tests/benchmarks/gui/image/qimagescale/CMakeLists.txt16
-rw-r--r--tests/benchmarks/gui/image/qpixmap/CMakeLists.txt18
-rw-r--r--tests/benchmarks/gui/image/qpixmapcache/CMakeLists.txt16
-rw-r--r--tests/benchmarks/gui/kernel/CMakeLists.txt4
-rw-r--r--tests/benchmarks/gui/kernel/qguimetatype/CMakeLists.txt16
-rw-r--r--tests/benchmarks/gui/kernel/qguivariant/CMakeLists.txt16
-rw-r--r--tests/benchmarks/gui/math3d/CMakeLists.txt4
-rw-r--r--tests/benchmarks/gui/math3d/qmatrix4x4/CMakeLists.txt16
-rw-r--r--tests/benchmarks/gui/math3d/qquaternion/CMakeLists.txt16
-rw-r--r--tests/benchmarks/gui/painting/CMakeLists.txt11
-rw-r--r--tests/benchmarks/gui/painting/drawtexture/CMakeLists.txt18
-rw-r--r--tests/benchmarks/gui/painting/lancebench/CMakeLists.txt150
-rw-r--r--tests/benchmarks/gui/painting/qcolor/CMakeLists.txt18
-rw-r--r--tests/benchmarks/gui/painting/qpainter/CMakeLists.txt20
-rw-r--r--tests/benchmarks/gui/painting/qregion/CMakeLists.txt16
-rw-r--r--tests/benchmarks/gui/painting/qtbench/CMakeLists.txt17
-rw-r--r--tests/benchmarks/gui/painting/qtransform/CMakeLists.txt16
-rw-r--r--tests/benchmarks/gui/text/CMakeLists.txt5
-rw-r--r--tests/benchmarks/gui/text/qfontmetrics/CMakeLists.txt16
-rw-r--r--tests/benchmarks/gui/text/qtext/CMakeLists.txt19
-rw-r--r--tests/benchmarks/gui/text/qtextdocument/CMakeLists.txt18
-rw-r--r--tests/benchmarks/network/CMakeLists.txt8
-rw-r--r--tests/benchmarks/network/access/CMakeLists.txt6
-rw-r--r--tests/benchmarks/network/access/qfile_vs_qnetworkaccessmanager/CMakeLists.txt16
-rw-r--r--tests/benchmarks/network/access/qnetworkdiskcache/CMakeLists.txt16
-rw-r--r--tests/benchmarks/network/access/qnetworkreply/CMakeLists.txt19
-rw-r--r--tests/benchmarks/network/access/qnetworkreply_from_cache/CMakeLists.txt13
-rw-r--r--tests/benchmarks/network/kernel/CMakeLists.txt5
-rw-r--r--tests/benchmarks/network/kernel/qhostinfo/CMakeLists.txt19
-rw-r--r--tests/benchmarks/network/socket/CMakeLists.txt4
-rw-r--r--tests/benchmarks/network/socket/qtcpserver/CMakeLists.txt16
-rw-r--r--tests/benchmarks/network/socket/qudpsocket/CMakeLists.txt16
-rw-r--r--tests/benchmarks/network/ssl/CMakeLists.txt3
-rw-r--r--tests/benchmarks/network/ssl/qsslsocket/CMakeLists.txt16
-rw-r--r--tests/benchmarks/opengl/CMakeLists.txt23
-rw-r--r--tests/benchmarks/plugins/imageformats/jpeg/CMakeLists.txt17
-rw-r--r--tests/benchmarks/sql/CMakeLists.txt3
-rw-r--r--tests/benchmarks/sql/kernel/CMakeLists.txt4
-rw-r--r--tests/benchmarks/sql/kernel/qsqlquery/CMakeLists.txt16
-rw-r--r--tests/benchmarks/sql/kernel/qsqlrecord/CMakeLists.txt16
-rw-r--r--tests/benchmarks/testlib/CMakeLists.txt3
-rw-r--r--tests/benchmarks/testlib/tostring/CMakeLists.txt12
-rw-r--r--tests/benchmarks/widgets/CMakeLists.txt7
-rw-r--r--tests/benchmarks/widgets/graphicsview/CMakeLists.txt10
-rw-r--r--tests/benchmarks/widgets/graphicsview/functional/CMakeLists.txt2
-rw-r--r--tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/CMakeLists.txt367
-rw-r--r--tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt17
-rw-r--r--tests/benchmarks/widgets/graphicsview/qgraphicsitem/CMakeLists.txt17
-rw-r--r--tests/benchmarks/widgets/graphicsview/qgraphicslayout/CMakeLists.txt17
-rw-r--r--tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt17
-rw-r--r--tests/benchmarks/widgets/graphicsview/qgraphicsscene/CMakeLists.txt17
-rw-r--r--tests/benchmarks/widgets/graphicsview/qgraphicsview/CMakeLists.txt55
-rw-r--r--tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/CMakeLists.txt48
-rw-r--r--tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/CMakeLists.txt13
-rw-r--r--tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/CMakeLists.txt13
-rw-r--r--tests/benchmarks/widgets/graphicsview/qgraphicswidget/CMakeLists.txt17
-rw-r--r--tests/benchmarks/widgets/itemviews/CMakeLists.txt5
-rw-r--r--tests/benchmarks/widgets/itemviews/qheaderview/CMakeLists.txt17
-rw-r--r--tests/benchmarks/widgets/itemviews/qlistview/CMakeLists.txt17
-rw-r--r--tests/benchmarks/widgets/itemviews/qtableview/CMakeLists.txt17
-rw-r--r--tests/benchmarks/widgets/kernel/CMakeLists.txt4
-rw-r--r--tests/benchmarks/widgets/kernel/qapplication/CMakeLists.txt17
-rw-r--r--tests/benchmarks/widgets/kernel/qwidget/CMakeLists.txt14
-rw-r--r--tests/benchmarks/widgets/styles/CMakeLists.txt5
-rw-r--r--tests/benchmarks/widgets/styles/qstylesheetstyle/CMakeLists.txt17
-rw-r--r--tests/benchmarks/widgets/widgets/CMakeLists.txt3
-rw-r--r--tests/benchmarks/widgets/widgets/qtextbrowser/CMakeLists.txt17
-rw-r--r--tests/manual/CMakeLists.txt82
-rw-r--r--tests/manual/bearerex/CMakeLists.txt25
-rw-r--r--tests/manual/cocoa/appicon/CMakeLists.txt17
-rw-r--r--tests/manual/cocoa/menurama/CMakeLists.txt21
-rw-r--r--tests/manual/cocoa/menus/CMakeLists.txt16
-rw-r--r--tests/manual/cocoa/nativewidgets/CMakeLists.txt17
-rw-r--r--tests/manual/cocoa/popups/CMakeLists.txt13
-rw-r--r--tests/manual/cocoa/qmaccocoaviewcontainer/CMakeLists.txt21
-rw-r--r--tests/manual/cocoa/qsystemtrayicon/CMakeLists.txt38
-rw-r--r--tests/manual/cocoa/qt_on_cocoa/CMakeLists.txt22
-rw-r--r--tests/manual/cocoa/wheelevent/CMakeLists.txt21
-rw-r--r--tests/manual/diaglib/nativewindowdump_win.cpp2
-rw-r--r--tests/manual/dialogs/CMakeLists.txt38
-rw-r--r--tests/manual/embeddedintoforeignwindow/CMakeLists.txt60
-rw-r--r--tests/manual/filetest/CMakeLists.txt13
-rw-r--r--tests/manual/foreignwindows/CMakeLists.txt60
-rw-r--r--tests/manual/gestures/CMakeLists.txt4
-rw-r--r--tests/manual/gestures/graphicsview/CMakeLists.txt17
-rw-r--r--tests/manual/gestures/scrollarea/CMakeLists.txt15
-rw-r--r--tests/manual/highdpi/CMakeLists.txt41
-rw-r--r--tests/manual/inputmethodhints/CMakeLists.txt20
-rw-r--r--tests/manual/keypadnavigation/CMakeLists.txt17
-rw-r--r--tests/manual/lance/CMakeLists.txt175
-rw-r--r--tests/manual/markdown/CMakeLists.txt18
-rw-r--r--tests/manual/network_remote_stresstest/CMakeLists.txt29
-rw-r--r--tests/manual/network_stresstest/CMakeLists.txt35
-rw-r--r--tests/manual/qcursor/CMakeLists.txt8
-rw-r--r--tests/manual/qcursor/allcursors/CMakeLists.txt20
-rw-r--r--tests/manual/qcursor/childwidget/CMakeLists.txt19
-rw-r--r--tests/manual/qcursor/childwindow/CMakeLists.txt18
-rw-r--r--tests/manual/qcursor/childwindowcontainer/CMakeLists.txt19
-rw-r--r--tests/manual/qcursor/grab_override/CMakeLists.txt33
-rw-r--r--tests/manual/qcursor/qcursorhighdpi/CMakeLists.txt27
-rw-r--r--tests/manual/qdesktopservices/CMakeLists.txt19
-rw-r--r--tests/manual/qdesktopwidget/CMakeLists.txt17
-rw-r--r--tests/manual/qgraphicsitem/CMakeLists.txt14
-rw-r--r--tests/manual/qgraphicsitemgroup/CMakeLists.txt21
-rw-r--r--tests/manual/qgraphicslayout/flicker/CMakeLists.txt15
-rw-r--r--tests/manual/qhttpnetworkconnection/CMakeLists.txt16
-rw-r--r--tests/manual/qimagereader/CMakeLists.txt14
-rw-r--r--tests/manual/qlayout/CMakeLists.txt21
-rw-r--r--tests/manual/qlocale/CMakeLists.txt22
-rw-r--r--tests/manual/qmetatype/CMakeLists.txt12
-rw-r--r--tests/manual/qmimedatabase/CMakeLists.txt13
-rw-r--r--tests/manual/qnetconmonitor/.prev_CMakeLists.txt18
-rw-r--r--tests/manual/qnetconmonitor/CMakeLists.txt24
-rw-r--r--tests/manual/qnetworkaccessmanager/qget/CMakeLists.txt17
-rw-r--r--tests/manual/qnetworkconfiguration/CMakeLists.txt16
-rw-r--r--tests/manual/qnetworkconfigurationmanager/CMakeLists.txt16
-rw-r--r--tests/manual/qnetworkreply/.prev_CMakeLists.txt19
-rw-r--r--tests/manual/qnetworkreply/CMakeLists.txt25
-rw-r--r--tests/manual/qopenglcontext/CMakeLists.txt21
-rw-r--r--tests/manual/qopengltextureblitter/CMakeLists.txt21
-rw-r--r--tests/manual/qopenglwidget/openglwidget/CMakeLists.txt22
-rw-r--r--tests/manual/qopenglwindow/multiwindow/CMakeLists.txt16
-rw-r--r--tests/manual/qprintdevice_dump/CMakeLists.txt19
-rw-r--r--tests/manual/qscreen/CMakeLists.txt18
-rw-r--r--tests/manual/qssloptions/CMakeLists.txt13
-rw-r--r--tests/manual/qsslsocket/CMakeLists.txt12
-rw-r--r--tests/manual/qstorageinfo/CMakeLists.txt10
-rw-r--r--tests/manual/qsysinfo/CMakeLists.txt13
-rw-r--r--tests/manual/qt_poll/CMakeLists.txt17
-rw-r--r--tests/manual/qtabbar/CMakeLists.txt20
-rw-r--r--tests/manual/qtabletevent/CMakeLists.txt5
-rw-r--r--tests/manual/qtabletevent/device_information/CMakeLists.txt15
-rw-r--r--tests/manual/qtabletevent/event_compression/CMakeLists.txt15
-rw-r--r--tests/manual/qtabletevent/regular_widgets/CMakeLists.txt17
-rw-r--r--tests/manual/qtbug-52641/CMakeLists.txt17
-rw-r--r--tests/manual/qtbug-8933/CMakeLists.txt20
-rw-r--r--tests/manual/qtexteditlist/CMakeLists.txt20
-rw-r--r--tests/manual/qtexttableborders/CMakeLists.txt35
-rw-r--r--tests/manual/qtouchevent/CMakeLists.txt18
-rw-r--r--tests/manual/qvulkaninstance/CMakeLists.txt18
-rw-r--r--tests/manual/qwidget_zorder/CMakeLists.txt14
-rw-r--r--tests/manual/repaint/CMakeLists.txt9
-rw-r--r--tests/manual/repaint/mainwindow/CMakeLists.txt15
-rw-r--r--tests/manual/repaint/scrollarea/CMakeLists.txt15
-rw-r--r--tests/manual/repaint/splitter/CMakeLists.txt15
-rw-r--r--tests/manual/repaint/tableview/CMakeLists.txt15
-rw-r--r--tests/manual/repaint/task141091/CMakeLists.txt13
-rw-r--r--tests/manual/repaint/toplevel/CMakeLists.txt14
-rw-r--r--tests/manual/repaint/widget/CMakeLists.txt15
-rw-r--r--tests/manual/rhi/CMakeLists.txt23
-rw-r--r--tests/manual/rhi/compressedtexture_bc1/CMakeLists.txt42
-rw-r--r--tests/manual/rhi/compressedtexture_bc1_subupload/CMakeLists.txt46
-rw-r--r--tests/manual/rhi/computebuffer/CMakeLists.txt33
-rw-r--r--tests/manual/rhi/computeimage/CMakeLists.txt43
-rw-r--r--tests/manual/rhi/cubemap/CMakeLists.txt33
-rw-r--r--tests/manual/rhi/cubemap_scissor/CMakeLists.txt42
-rw-r--r--tests/manual/rhi/floattexture/CMakeLists.txt42
-rw-r--r--tests/manual/rhi/hellominimalcrossgfxtriangle/CMakeLists.txt38
-rw-r--r--tests/manual/rhi/instancing/CMakeLists.txt32
-rw-r--r--tests/manual/rhi/mrt/CMakeLists.txt40
-rw-r--r--tests/manual/rhi/msaarenderbuffer/CMakeLists.txt46
-rw-r--r--tests/manual/rhi/msaatexture/CMakeLists.txt50
-rw-r--r--tests/manual/rhi/multiwindow/CMakeLists.txt39
-rw-r--r--tests/manual/rhi/multiwindow_threaded/CMakeLists.txt44
-rw-r--r--tests/manual/rhi/offscreen/CMakeLists.txt37
-rw-r--r--tests/manual/rhi/qrhiprof/CMakeLists.txt20
-rw-r--r--tests/manual/rhi/shadowmap/CMakeLists.txt34
-rw-r--r--tests/manual/rhi/texuploads/CMakeLists.txt42
-rw-r--r--tests/manual/rhi/triquadcube/CMakeLists.txt54
-rw-r--r--tests/manual/shortcuts/CMakeLists.txt17
-rw-r--r--tests/manual/socketengine/.prev_CMakeLists.txt19
-rw-r--r--tests/manual/socketengine/CMakeLists.txt25
-rw-r--r--tests/manual/textrendering/CMakeLists.txt5
-rw-r--r--tests/manual/textrendering/glyphshaping/CMakeLists.txt19
-rw-r--r--tests/manual/textrendering/nativetext/CMakeLists.txt29
-rw-r--r--tests/manual/textrendering/textperformance/CMakeLists.txt14
-rw-r--r--tests/manual/touch/CMakeLists.txt16
-rw-r--r--tests/manual/touchGraphicsItem/CMakeLists.txt19
-rw-r--r--tests/manual/transientwindow/CMakeLists.txt18
-rw-r--r--tests/manual/triangulator/CMakeLists.txt20
-rw-r--r--tests/manual/unc/CMakeLists.txt17
-rw-r--r--tests/manual/widgetgrab/CMakeLists.txt17
-rw-r--r--tests/manual/widgets/CMakeLists.txt7
-rw-r--r--tests/manual/widgets/itemviews/CMakeLists.txt8
-rw-r--r--tests/manual/widgets/itemviews/autoResizePrecision/tablehorz/CMakeLists.txt14
-rw-r--r--tests/manual/widgets/itemviews/autoResizePrecision/tablevert/CMakeLists.txt14
-rw-r--r--tests/manual/widgets/itemviews/autoResizePrecision/treeview/CMakeLists.txt14
-rw-r--r--tests/manual/widgets/itemviews/delegate/CMakeLists.txt17
-rw-r--r--tests/manual/widgets/itemviews/qconcatenatetablesproxymodel/CMakeLists.txt19
-rw-r--r--tests/manual/widgets/itemviews/qheaderview/CMakeLists.txt17
-rw-r--r--tests/manual/widgets/itemviews/qtreeview/CMakeLists.txt17
-rw-r--r--tests/manual/widgets/itemviews/qtreewidget/CMakeLists.txt19
-rw-r--r--tests/manual/widgets/itemviews/tableview-span-navigation/CMakeLists.txt19
-rw-r--r--tests/manual/widgets/kernel/CMakeLists.txt5
-rw-r--r--tests/manual/widgets/kernel/layoutreplace/CMakeLists.txt14
-rw-r--r--tests/manual/widgets/kernel/qtooltip/CMakeLists.txt14
-rw-r--r--tests/manual/widgets/kernel/sizeonhide/CMakeLists.txt19
-rw-r--r--tests/manual/widgets/qgraphicsview/CMakeLists.txt3
-rw-r--r--tests/manual/widgets/qgraphicsview/rubberband/CMakeLists.txt17
-rw-r--r--tests/manual/widgets/styles/CMakeLists.txt15
-rw-r--r--tests/manual/widgets/widgets/CMakeLists.txt6
-rw-r--r--tests/manual/widgets/widgets/bigmenucreator/CMakeLists.txt22
-rw-r--r--tests/manual/widgets/widgets/defaultUpMenuBar/CMakeLists.txt17
-rw-r--r--tests/manual/widgets/widgets/multiscreen-menus/CMakeLists.txt20
-rw-r--r--tests/manual/widgets/widgets/qmainwindow/saveStateSize/CMakeLists.txt17
-rw-r--r--tests/manual/widgets/widgets/qtoolbutton/menuOnMultiScreens/CMakeLists.txt17
-rw-r--r--tests/manual/windowchildgeometry/CMakeLists.txt23
-rw-r--r--tests/manual/windowflags/CMakeLists.txt17
-rw-r--r--tests/manual/windowgeometry/CMakeLists.txt21
-rw-r--r--tests/manual/windowmodality/CMakeLists.txt19
-rw-r--r--tests/manual/windowtransparency/CMakeLists.txt13
-rw-r--r--tests/manual/xcb_gl_integration/CMakeLists.txt20
-rw-r--r--tests/manual/xembed-raster/CMakeLists.txt17
-rw-r--r--tests/manual/xembed-widgets/CMakeLists.txt18
-rw-r--r--util/cmake/Makefile20
-rw-r--r--util/cmake/Pipfile18
-rw-r--r--util/cmake/README.md54
-rwxr-xr-xutil/cmake/cmakeconversionrate.py141
-rw-r--r--util/cmake/condition_simplifier.py237
-rw-r--r--util/cmake/condition_simplifier_cache.py183
-rwxr-xr-xutil/cmake/configurejson2cmake.py1105
-rwxr-xr-xutil/cmake/generate_module_map.sh38
-rw-r--r--util/cmake/helper.py740
-rw-r--r--util/cmake/json_parser.py101
-rwxr-xr-xutil/cmake/pro2cmake.py3935
-rwxr-xr-xutil/cmake/pro_conversion_rate.py235
-rw-r--r--util/cmake/qmake_parser.py388
-rw-r--r--util/cmake/requirements.txt8
-rwxr-xr-xutil/cmake/run_pro2cmake.py246
-rw-r--r--util/cmake/special_case_helper.py415
-rw-r--r--util/cmake/tests/__init__.py0
-rw-r--r--util/cmake/tests/data/comment_scope.pro6
-rw-r--r--util/cmake/tests/data/complex_assign.pro2
-rw-r--r--util/cmake/tests/data/complex_condition.pro4
-rw-r--r--util/cmake/tests/data/complex_values.pro22
-rw-r--r--util/cmake/tests/data/condition_without_scope.pro2
-rw-r--r--util/cmake/tests/data/contains_scope.pro4
-rw-r--r--util/cmake/tests/data/definetest.pro6
-rw-r--r--util/cmake/tests/data/else.pro6
-rw-r--r--util/cmake/tests/data/else2.pro4
-rw-r--r--util/cmake/tests/data/else3.pro7
-rw-r--r--util/cmake/tests/data/else4.pro6
-rw-r--r--util/cmake/tests/data/else5.pro10
-rw-r--r--util/cmake/tests/data/else6.pro11
-rw-r--r--util/cmake/tests/data/else7.pro2
-rw-r--r--util/cmake/tests/data/else8.pro5
-rw-r--r--util/cmake/tests/data/escaped_value.pro2
-rw-r--r--util/cmake/tests/data/for.pro11
-rw-r--r--util/cmake/tests/data/function_if.pro4
-rw-r--r--util/cmake/tests/data/include.pro3
-rw-r--r--util/cmake/tests/data/lc.pro10
-rw-r--r--util/cmake/tests/data/lc_with_comment.pro22
-rw-r--r--util/cmake/tests/data/load.pro3
-rw-r--r--util/cmake/tests/data/multi_condition_divided_by_lc.pro3
-rw-r--r--util/cmake/tests/data/multiline_assign.pro4
-rw-r--r--util/cmake/tests/data/nested_function_calls.pro2
-rw-r--r--util/cmake/tests/data/quoted.pro5
-rw-r--r--util/cmake/tests/data/single_line_for.pro4
-rw-r--r--util/cmake/tests/data/sql.pro3
-rw-r--r--util/cmake/tests/data/standardpaths.pro17
-rw-r--r--util/cmake/tests/data/unset.pro2
-rw-r--r--util/cmake/tests/data/value_function.pro2
-rwxr-xr-xutil/cmake/tests/test_lc_fixup.py44
-rwxr-xr-xutil/cmake/tests/test_logic_mapping.py186
-rwxr-xr-xutil/cmake/tests/test_operations.py57
-rwxr-xr-xutil/cmake/tests/test_parsing.py354
-rwxr-xr-xutil/cmake/tests/test_scope_handling.py346
1825 files changed, 71372 insertions, 635 deletions
diff --git a/.gitignore b/.gitignore
index e4079c6b4d..95a6964dd7 100644
--- a/.gitignore
+++ b/.gitignore
@@ -36,6 +36,8 @@
qt*-config.h
qt*-config_p.h
qt*-config.pri
+*.pyc
+.mypy_cache
/include/
@@ -56,11 +58,12 @@ qt*-config.pri
/src/angle/src/QtANGLE/libANGLE/
/src/angle/src/libGLESv2/libANGLE/
-/examples/*/*/*
-!/examples/*/*/*[.]*
-!/examples/*/*/README
-!/examples/*/doc/*
-!/examples/*/doc/*/*
+# FIXME: Ignore these again?
+# /examples/*/*/*
+# !/examples/*/*/*[.]*
+# !/examples/*/*/README
+# !/examples/*/doc/*
+# !/examples/*/doc/*/*
/translations/*.qm
/translations/*_en.ts
@@ -321,3 +324,6 @@ wrapper.bat
# Generated by qt.prf
*_plugin_import.cpp
+
+# Typical cmake build directories
+/build*
diff --git a/CMakeLists.txt b/CMakeLists.txt
new file mode 100644
index 0000000000..d7874e891a
--- /dev/null
+++ b/CMakeLists.txt
@@ -0,0 +1,96 @@
+cmake_minimum_required(VERSION 3.15.0)
+
+# Run auto detection routines
+include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/QtAutoDetect.cmake)
+
+project(QtBase
+ VERSION 6.0.0
+ DESCRIPTION "Qt Base Libraries"
+ HOMEPAGE_URL "https://qt.io/"
+ LANGUAGES CXX C ASM
+)
+
+if(NOT QT_BUILD_STANDALONE_TESTS)
+ ## Add some paths to check for cmake modules:
+ list(PREPEND CMAKE_MODULE_PATH
+ "${CMAKE_CURRENT_SOURCE_DIR}/cmake"
+ "${CMAKE_CURRENT_SOURCE_DIR}/cmake/3rdparty/extra-cmake-modules/find-modules"
+ "${CMAKE_CURRENT_SOURCE_DIR}/cmake/3rdparty/kwin"
+ )
+
+ ## Find the build internals package.
+ set(QT_BUILD_INTERNALS_SKIP_CMAKE_MODULE_PATH_ADDITION TRUE)
+ list(PREPEND CMAKE_PREFIX_PATH
+ "${CMAKE_CURRENT_SOURCE_DIR}/cmake"
+ )
+ find_package(QtBuildInternals CMAKE_FIND_ROOT_PATH_BOTH)
+ unset(QT_BUILD_INTERNALS_SKIP_CMAKE_MODULE_PATH_ADDITION)
+else()
+ # When building standalone tests, an istalled BuildInternals package already exists.
+ find_package(Qt6 REQUIRED COMPONENTS BuildInternals CMAKE_FIND_ROOT_PATH_BOTH)
+endif()
+
+qt_build_repo_begin()
+
+if(NOT QT_BUILD_STANDALONE_TESTS)
+ ## Should this Qt be static or dynamically linked?
+ option(BUILD_SHARED_LIBS "Build Qt statically or dynamically" ON)
+ set(QT_BUILD_SHARED_LIBS ${BUILD_SHARED_LIBS})
+
+ ## Should this Qt be built with Werror?
+ option(WARNINGS_ARE_ERRORS "Build Qt with warnings as errors" ${FEATURE_developer_build})
+
+ ## Should Qt be built using PCH?
+ option(BUILD_WITH_PCH "Build Qt using precompiled headers?" ON)
+
+ ## QtBase specific configure tests:
+ include(QtBaseConfigureTests)
+
+ ## Build System tests:
+ include(QtBaseCMakeTesting)
+
+ ## Targets for global features, etc.:
+ include(QtBaseGlobalTargets)
+
+ ## Set language standards after QtBaseGlobalTargets, because that's when the relevant
+ ## feature variables are available.
+ qt_set_language_standards()
+
+ #include CoreMacros() for qt6_generate_meta_types()
+ include(src/corelib/Qt6CoreMacros.cmake)
+
+ ## Setup documentation
+ add_subdirectory(doc)
+
+ ## Visit all the directories:
+ add_subdirectory(src)
+endif()
+
+if(BUILD_TESTING)
+ add_subdirectory(tests)
+ if(QT_NO_MAKE_TESTS)
+ set_property(DIRECTORY tests PROPERTY EXCLUDE_FROM_ALL TRUE)
+ endif()
+endif()
+
+if(NOT QT_BUILD_STANDALONE_TESTS)
+ if(QT_WILL_BUILD_TOOLS)
+ add_subdirectory(qmake)
+ endif()
+ # As long as we use the mkspecs (for qplatformdefs.h), we need to always
+ # install it, especially when cross-compiling.
+ set(mkspecs_install_dir "${INSTALL_DATADIR}")
+ qt_path_join(mkspecs_install_dir ${QT_INSTALL_DIR} ${mkspecs_install_dir})
+
+ qt_copy_or_install(DIRECTORY "${PROJECT_SOURCE_DIR}/mkspecs"
+ DESTINATION ${mkspecs_install_dir})
+endif()
+
+qt_build_repo_end()
+
+if(NOT QT_BUILD_STANDALONE_TESTS AND BUILD_EXAMPLES)
+ add_subdirectory(examples)
+ if(QT_NO_MAKE_EXAMPLES)
+ set_property(DIRECTORY examples PROPERTY EXCLUDE_FROM_ALL TRUE)
+ endif()
+endif()
diff --git a/bin/qt-cmake.bat.in b/bin/qt-cmake.bat.in
new file mode 100644
index 0000000000..f27818a61b
--- /dev/null
+++ b/bin/qt-cmake.bat.in
@@ -0,0 +1 @@
+"@CMAKE_COMMAND@" -DCMAKE_TOOLCHAIN_FILE="@__GlobalConfig_install_dir_absolute@/qt.toolchain.cmake" %*
diff --git a/bin/qt-cmake.in b/bin/qt-cmake.in
new file mode 100755
index 0000000000..1797d2ded5
--- /dev/null
+++ b/bin/qt-cmake.in
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+exec @CMAKE_COMMAND@ -DCMAKE_TOOLCHAIN_FILE=@__GlobalConfig_install_dir_absolute@/qt.toolchain.cmake $*
diff --git a/cmake/3rdparty/extra-cmake-modules/COPYING-CMAKE-SCRIPTS b/cmake/3rdparty/extra-cmake-modules/COPYING-CMAKE-SCRIPTS
new file mode 100644
index 0000000000..4b417765f3
--- /dev/null
+++ b/cmake/3rdparty/extra-cmake-modules/COPYING-CMAKE-SCRIPTS
@@ -0,0 +1,22 @@
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions
+are met:
+
+1. Redistributions of source code must retain the copyright
+ notice, this list of conditions and the following disclaimer.
+2. Redistributions in binary form must reproduce the copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+3. The name of the author may not be used to endorse or promote products
+ derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/cmake/3rdparty/extra-cmake-modules/find-modules/ECMFindModuleHelpersStub.cmake b/cmake/3rdparty/extra-cmake-modules/find-modules/ECMFindModuleHelpersStub.cmake
new file mode 100644
index 0000000000..bb8c9a62fc
--- /dev/null
+++ b/cmake/3rdparty/extra-cmake-modules/find-modules/ECMFindModuleHelpersStub.cmake
@@ -0,0 +1 @@
+include(${CMAKE_CURRENT_LIST_DIR}/../modules/ECMFindModuleHelpers.cmake)
diff --git a/cmake/3rdparty/extra-cmake-modules/find-modules/FindEGL.cmake b/cmake/3rdparty/extra-cmake-modules/find-modules/FindEGL.cmake
new file mode 100644
index 0000000000..48e5172877
--- /dev/null
+++ b/cmake/3rdparty/extra-cmake-modules/find-modules/FindEGL.cmake
@@ -0,0 +1,172 @@
+#.rst:
+# FindEGL
+# -------
+#
+# Try to find EGL.
+#
+# This will define the following variables:
+#
+# ``EGL_FOUND``
+# True if (the requested version of) EGL is available
+# ``EGL_VERSION``
+# The version of EGL; note that this is the API version defined in the
+# headers, rather than the version of the implementation (eg: Mesa)
+# ``EGL_LIBRARIES``
+# This can be passed to target_link_libraries() instead of the ``EGL::EGL``
+# target
+# ``EGL_INCLUDE_DIRS``
+# This should be passed to target_include_directories() if the target is not
+# used for linking
+# ``EGL_DEFINITIONS``
+# This should be passed to target_compile_options() if the target is not
+# used for linking
+#
+# If ``EGL_FOUND`` is TRUE, it will also define the following imported target:
+#
+# ``EGL::EGL``
+# The EGL library
+#
+# In general we recommend using the imported target, as it is easier to use.
+# Bear in mind, however, that if the target is in the link interface of an
+# exported library, it must be made available by the package config file.
+#
+# Since pre-1.0.0.
+
+#=============================================================================
+# Copyright 2014 Alex Merry <alex.merry@kde.org>
+# Copyright 2014 Martin Gräßlin <mgraesslin@kde.org>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# 1. Redistributions of source code must retain the copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The name of the author may not be used to endorse or promote products
+# derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#=============================================================================
+
+include(${CMAKE_CURRENT_LIST_DIR}/ECMFindModuleHelpersStub.cmake)
+include(CheckCXXSourceCompiles)
+include(CMakePushCheckState)
+
+ecm_find_package_version_check(EGL)
+
+# Use pkg-config to get the directories and then use these values
+# in the FIND_PATH() and FIND_LIBRARY() calls
+find_package(PkgConfig)
+pkg_check_modules(PKG_EGL QUIET egl)
+
+set(EGL_DEFINITIONS ${PKG_EGL_CFLAGS_OTHER})
+
+find_path(EGL_INCLUDE_DIR
+ NAMES
+ EGL/egl.h
+ HINTS
+ ${PKG_EGL_INCLUDE_DIRS}
+)
+find_library(EGL_LIBRARY
+ NAMES
+ EGL
+ HINTS
+ ${PKG_EGL_LIBRARY_DIRS}
+)
+
+# NB: We do *not* use the version information from pkg-config, as that
+# is the implementation version (eg: the Mesa version)
+if(EGL_INCLUDE_DIR)
+ # egl.h has defines of the form EGL_VERSION_x_y for each supported
+ # version; so the header for EGL 1.1 will define EGL_VERSION_1_0 and
+ # EGL_VERSION_1_1. Finding the highest supported version involves
+ # finding all these defines and selecting the highest numbered.
+ file(READ "${EGL_INCLUDE_DIR}/EGL/egl.h" _EGL_header_contents)
+ string(REGEX MATCHALL
+ "[ \t]EGL_VERSION_[0-9_]+"
+ _EGL_version_lines
+ "${_EGL_header_contents}"
+ )
+ unset(_EGL_header_contents)
+ foreach(_EGL_version_line ${_EGL_version_lines})
+ string(REGEX REPLACE
+ "[ \t]EGL_VERSION_([0-9_]+)"
+ "\\1"
+ _version_candidate
+ "${_EGL_version_line}"
+ )
+ string(REPLACE "_" "." _version_candidate "${_version_candidate}")
+ if(NOT DEFINED EGL_VERSION OR EGL_VERSION VERSION_LESS _version_candidate)
+ set(EGL_VERSION "${_version_candidate}")
+ endif()
+ endforeach()
+ unset(_EGL_version_lines)
+endif()
+
+cmake_push_check_state(RESET)
+list(APPEND CMAKE_REQUIRED_LIBRARIES "${EGL_LIBRARY}")
+list(APPEND CMAKE_REQUIRED_INCLUDES "${EGL_INCLUDE_DIR}")
+
+check_cxx_source_compiles("
+#include <EGL/egl.h>
+
+int main(int argc, char *argv[]) {
+ EGLint x = 0; EGLDisplay dpy = 0; EGLContext ctx = 0;
+ eglDestroyContext(dpy, ctx);
+}" HAVE_EGL)
+
+cmake_pop_check_state()
+
+set(required_vars EGL_INCLUDE_DIR HAVE_EGL)
+if(NOT EMSCRIPTEN)
+ list(APPEND required_vars EGL_LIBRARY)
+endif()
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(EGL
+ FOUND_VAR
+ EGL_FOUND
+ REQUIRED_VARS
+ ${required_vars}
+ VERSION_VAR
+ EGL_VERSION
+)
+
+if(EGL_FOUND AND NOT TARGET EGL::EGL)
+ if (EMSCRIPTEN)
+ add_library(EGL::EGL INTERFACE IMPORTED)
+ # Nothing further to be done, system include paths have headers and linkage is implicit.
+ else()
+ add_library(EGL::EGL UNKNOWN IMPORTED)
+ set_target_properties(EGL::EGL PROPERTIES
+ IMPORTED_LOCATION "${EGL_LIBRARY}"
+ INTERFACE_COMPILE_OPTIONS "${EGL_DEFINITIONS}"
+ INTERFACE_INCLUDE_DIRECTORIES "${EGL_INCLUDE_DIR}"
+ )
+ endif()
+endif()
+
+mark_as_advanced(EGL_LIBRARY EGL_INCLUDE_DIR HAVE_EGL)
+
+# compatibility variables
+set(EGL_LIBRARIES ${EGL_LIBRARY})
+set(EGL_INCLUDE_DIRS ${EGL_INCLUDE_DIR})
+set(EGL_VERSION_STRING ${EGL_VERSION})
+
+include(FeatureSummary)
+set_package_properties(EGL PROPERTIES
+ URL "https://www.khronos.org/egl/"
+ DESCRIPTION "A platform-agnostic mechanism for creating rendering surfaces for use with other graphics libraries, such as OpenGL|ES and OpenVG."
+)
diff --git a/cmake/3rdparty/extra-cmake-modules/find-modules/FindGLIB2.cmake b/cmake/3rdparty/extra-cmake-modules/find-modules/FindGLIB2.cmake
new file mode 100644
index 0000000000..993535123a
--- /dev/null
+++ b/cmake/3rdparty/extra-cmake-modules/find-modules/FindGLIB2.cmake
@@ -0,0 +1,101 @@
+#.rst:
+# FindGLIB2
+# ---------
+#
+# Try to locate the GLib2 library.
+# If found, this will define the following variables:
+#
+# ``GLIB2_FOUND``
+# True if the GLib2 library is available
+# ``GLIB2_INCLUDE_DIRS``
+# The GLib2 include directories
+# ``GLIB2_LIBRARIES``
+# The GLib2 libraries for linking
+# ``GLIB2_INCLUDE_DIR``
+# Deprecated, use ``GLIB2_INCLUDE_DIRS``
+# ``GLIB2_LIBRARY``
+# Deprecated, use ``GLIB2_LIBRARIES``
+#
+# If ``GLIB2_FOUND`` is TRUE, it will also define the following
+# imported target:
+#
+# ``GLIB2::GLIB2``
+# The GLIB2 library
+#
+# Since 5.41.0.
+
+#=============================================================================
+# Copyright (c) 2008 Laurent Montel, <montel@kde.org>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# 1. Redistributions of source code must retain the copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The name of the author may not be used to endorse or promote products
+# derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#=============================================================================
+
+find_package(PkgConfig)
+pkg_check_modules(PC_GLIB2 QUIET glib-2.0)
+
+find_path(GLIB2_INCLUDE_DIRS
+ NAMES glib.h
+ HINTS ${PC_GLIB2_INCLUDEDIR}
+ PATH_SUFFIXES glib-2.0)
+
+find_library(GLIB2_LIBRARIES
+ NAMES glib-2.0
+ HINTS ${PC_GLIB2_LIBDIR}
+)
+
+# search the glibconfig.h include dir under the same root where the library is found
+get_filename_component(glib2LibDir "${GLIB2_LIBRARIES}" PATH)
+
+find_path(GLIB2_INTERNAL_INCLUDE_DIR glibconfig.h
+ PATH_SUFFIXES glib-2.0/include
+ HINTS ${PC_GLIB2_INCLUDEDIR} "${glib2LibDir}" ${CMAKE_SYSTEM_LIBRARY_PATH})
+
+# not sure if this include dir is optional or required
+# for now it is optional
+if(GLIB2_INTERNAL_INCLUDE_DIR)
+ list(APPEND GLIB2_INCLUDE_DIRS "${GLIB2_INTERNAL_INCLUDE_DIR}")
+endif()
+
+# Deprecated synonyms
+set(GLIB2_INCLUDE_DIR "${GLIB2_INCLUDE_DIRS}")
+set(GLIB2_LIBRARY "${GLIB2_LIBRARIES}")
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(GLIB2 DEFAULT_MSG GLIB2_LIBRARIES GLIB2_INCLUDE_DIRS)
+
+if(GLIB2_FOUND AND NOT TARGET GLIB2::GLIB2)
+ add_library(GLIB2::GLIB2 UNKNOWN IMPORTED)
+ set_target_properties(GLIB2::GLIB2 PROPERTIES
+ IMPORTED_LOCATION "${GLIB2_LIBRARIES}"
+ INTERFACE_INCLUDE_DIRECTORIES "${GLIB2_INCLUDE_DIRS}")
+endif()
+
+mark_as_advanced(GLIB2_INCLUDE_DIRS GLIB2_INCLUDE_DIR
+ GLIB2_LIBRARIES GLIB2_LIBRARY)
+
+include(FeatureSummary)
+set_package_properties(GLIB2 PROPERTIES
+ URL "https://wiki.gnome.org/Projects/GLib"
+ DESCRIPTION "Event loop and utility library")
+
diff --git a/cmake/3rdparty/extra-cmake-modules/find-modules/FindWayland.cmake b/cmake/3rdparty/extra-cmake-modules/find-modules/FindWayland.cmake
new file mode 100644
index 0000000000..233cc88d02
--- /dev/null
+++ b/cmake/3rdparty/extra-cmake-modules/find-modules/FindWayland.cmake
@@ -0,0 +1,143 @@
+#.rst:
+# FindWayland
+# -----------
+#
+# Try to find Wayland.
+#
+# This is a component-based find module, which makes use of the COMPONENTS
+# and OPTIONAL_COMPONENTS arguments to find_module. The following components
+# are available::
+#
+# Client Server Cursor Egl
+#
+# If no components are specified, this module will act as though all components
+# were passed to OPTIONAL_COMPONENTS.
+#
+# This module will define the following variables, independently of the
+# components searched for or found:
+#
+# ``Wayland_FOUND``
+# TRUE if (the requested version of) Wayland is available
+# ``Wayland_VERSION``
+# Found Wayland version
+# ``Wayland_TARGETS``
+# A list of all targets imported by this module (note that there may be more
+# than the components that were requested)
+# ``Wayland_LIBRARIES``
+# This can be passed to target_link_libraries() instead of the imported
+# targets
+# ``Wayland_INCLUDE_DIRS``
+# This should be passed to target_include_directories() if the targets are
+# not used for linking
+# ``Wayland_DEFINITIONS``
+# This should be passed to target_compile_options() if the targets are not
+# used for linking
+#
+# For each searched-for components, ``Wayland_<component>_FOUND`` will be set to
+# TRUE if the corresponding Wayland library was found, and FALSE otherwise. If
+# ``Wayland_<component>_FOUND`` is TRUE, the imported target
+# ``Wayland::<component>`` will be defined. This module will also attempt to
+# determine ``Wayland_*_VERSION`` variables for each imported target, although
+# ``Wayland_VERSION`` should normally be sufficient.
+#
+# In general we recommend using the imported targets, as they are easier to use
+# and provide more control. Bear in mind, however, that if any target is in the
+# link interface of an exported library, it must be made available by the
+# package config file.
+#
+# Since pre-1.0.0.
+
+#=============================================================================
+# Copyright 2014 Alex Merry <alex.merry@kde.org>
+# Copyright 2014 Martin Gräßlin <mgraesslin@kde.org>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# 1. Redistributions of source code must retain the copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The name of the author may not be used to endorse or promote products
+# derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#=============================================================================
+
+include(${CMAKE_CURRENT_LIST_DIR}/ECMFindModuleHelpersStub.cmake)
+
+ecm_find_package_version_check(Wayland)
+
+set(Wayland_known_components
+ Client
+ Server
+ Cursor
+ Egl
+)
+foreach(_comp ${Wayland_known_components})
+ string(TOLOWER "${_comp}" _lc_comp)
+ set(Wayland_${_comp}_component_deps)
+ set(Wayland_${_comp}_pkg_config "wayland-${_lc_comp}")
+ set(Wayland_${_comp}_lib "wayland-${_lc_comp}")
+ set(Wayland_${_comp}_header "wayland-${_lc_comp}.h")
+endforeach()
+set(Wayland_Egl_component_deps Client)
+
+ecm_find_package_parse_components(Wayland
+ RESULT_VAR Wayland_components
+ KNOWN_COMPONENTS ${Wayland_known_components}
+)
+ecm_find_package_handle_library_components(Wayland
+ COMPONENTS ${Wayland_components}
+)
+
+# If pkg-config didn't provide us with version information,
+# try to extract it from wayland-version.h
+# (Note that the version from wayland-egl.pc will probably be
+# the Mesa version, rather than the Wayland version, but that
+# version will be ignored as we always find wayland-client.pc
+# first).
+if(NOT Wayland_VERSION)
+ find_file(Wayland_VERSION_HEADER
+ NAMES wayland-version.h
+ HINTS ${Wayland_INCLUDE_DIRS}
+ )
+ mark_as_advanced(Wayland_VERSION_HEADER)
+ if(Wayland_VERSION_HEADER)
+ file(READ ${Wayland_VERSION_HEADER} _wayland_version_header_contents)
+ string(REGEX REPLACE
+ "^.*[ \t]+WAYLAND_VERSION[ \t]+\"([0-9.]*)\".*$"
+ "\\1"
+ Wayland_VERSION
+ "${_wayland_version_header_contents}"
+ )
+ unset(_wayland_version_header_contents)
+ endif()
+endif()
+
+find_package_handle_standard_args(Wayland
+ FOUND_VAR
+ Wayland_FOUND
+ REQUIRED_VARS
+ Wayland_LIBRARIES
+ VERSION_VAR
+ Wayland_VERSION
+ HANDLE_COMPONENTS
+)
+
+include(FeatureSummary)
+set_package_properties(Wayland PROPERTIES
+ URL "http://wayland.freedesktop.org"
+ DESCRIPTION "C library implementation of the Wayland protocol: a protocol for a compositor to talk to its clients"
+)
diff --git a/cmake/3rdparty/extra-cmake-modules/find-modules/FindWaylandScanner.cmake b/cmake/3rdparty/extra-cmake-modules/find-modules/FindWaylandScanner.cmake
new file mode 100644
index 0000000000..ed9c4c4c9a
--- /dev/null
+++ b/cmake/3rdparty/extra-cmake-modules/find-modules/FindWaylandScanner.cmake
@@ -0,0 +1,167 @@
+#.rst:
+# FindWaylandScanner
+# ------------------
+#
+# Try to find wayland-scanner.
+#
+# If the wayland-scanner executable is not in your PATH, you can provide
+# an alternative name or full path location with the ``WaylandScanner_EXECUTABLE``
+# variable.
+#
+# This will define the following variables:
+#
+# ``WaylandScanner_FOUND``
+# True if wayland-scanner is available.
+#
+# ``WaylandScanner_EXECUTABLE``
+# The wayland-scanner executable.
+#
+# If ``WaylandScanner_FOUND`` is TRUE, it will also define the following imported
+# target:
+#
+# ``Wayland::Scanner``
+# The wayland-scanner executable.
+#
+# This module provides the following functions to generate C protocol
+# implementations:
+#
+# - ``ecm_add_wayland_client_protocol``
+# - ``ecm_add_wayland_server_protocol``
+#
+# ::
+#
+# ecm_add_wayland_client_protocol(<source_files_var>
+# PROTOCOL <xmlfile>
+# BASENAME <basename>)
+#
+# Generate Wayland client protocol files from ``<xmlfile>`` XML
+# definition for the ``<basename>`` interface and append those files
+# to ``<source_files_var>``.
+#
+# ::
+#
+# ecm_add_wayland_server_protocol(<source_files_var>
+# PROTOCOL <xmlfile>
+# BASENAME <basename>)
+#
+# Generate Wayland server protocol files from ``<xmlfile>`` XML
+# definition for the ``<basename>`` interface and append those files
+# to ``<source_files_var>``.
+#
+# Since 1.4.0.
+
+#=============================================================================
+# Copyright 2012-2014 Pier Luigi Fiorini <pierluigi.fiorini@gmail.com>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# 1. Redistributions of source code must retain the copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The name of the author may not be used to endorse or promote products
+# derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#=============================================================================
+
+include(${CMAKE_CURRENT_LIST_DIR}/ECMFindModuleHelpersStub.cmake)
+
+ecm_find_package_version_check(WaylandScanner)
+
+# Find wayland-scanner
+find_program(WaylandScanner_EXECUTABLE NAMES wayland-scanner)
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(WaylandScanner
+ FOUND_VAR
+ WaylandScanner_FOUND
+ REQUIRED_VARS
+ WaylandScanner_EXECUTABLE
+)
+
+mark_as_advanced(WaylandScanner_EXECUTABLE)
+
+if(NOT TARGET Wayland::Scanner AND WaylandScanner_FOUND)
+ add_executable(Wayland::Scanner IMPORTED)
+ set_target_properties(Wayland::Scanner PROPERTIES
+ IMPORTED_LOCATION "${WaylandScanner_EXECUTABLE}"
+ )
+endif()
+
+include(FeatureSummary)
+set_package_properties(WaylandScanner PROPERTIES
+ URL "https://wayland.freedesktop.org/"
+ DESCRIPTION "Executable that converts XML protocol files to C code"
+)
+
+
+include(CMakeParseArguments)
+
+function(ecm_add_wayland_client_protocol out_var)
+ # Parse arguments
+ set(oneValueArgs PROTOCOL BASENAME)
+ cmake_parse_arguments(ARGS "" "${oneValueArgs}" "" ${ARGN})
+
+ if(ARGS_UNPARSED_ARGUMENTS)
+ message(FATAL_ERROR "Unknown keywords given to ecm_add_wayland_client_protocol(): \"${ARGS_UNPARSED_ARGUMENTS}\"")
+ endif()
+
+ get_filename_component(_infile ${ARGS_PROTOCOL} ABSOLUTE)
+ set(_client_header "${CMAKE_CURRENT_BINARY_DIR}/wayland-${ARGS_BASENAME}-client-protocol.h")
+ set(_code "${CMAKE_CURRENT_BINARY_DIR}/wayland-${ARGS_BASENAME}-protocol.c")
+
+ set_source_files_properties(${_client_header} GENERATED)
+ set_source_files_properties(${_code} GENERATED)
+ set_property(SOURCE ${_client_header} PROPERTY SKIP_AUTOMOC ON)
+
+ add_custom_command(OUTPUT "${_client_header}"
+ COMMAND ${WaylandScanner_EXECUTABLE} client-header ${_infile} ${_client_header}
+ DEPENDS ${_infile} VERBATIM)
+
+ add_custom_command(OUTPUT "${_code}"
+ COMMAND ${WaylandScanner_EXECUTABLE} code ${_infile} ${_code}
+ DEPENDS ${_infile} ${_client_header} VERBATIM)
+
+ list(APPEND ${out_var} "${_client_header}" "${_code}")
+ set(${out_var} ${${out_var}} PARENT_SCOPE)
+endfunction()
+
+
+function(ecm_add_wayland_server_protocol out_var)
+ # Parse arguments
+ set(oneValueArgs PROTOCOL BASENAME)
+ cmake_parse_arguments(ARGS "" "${oneValueArgs}" "" ${ARGN})
+
+ if(ARGS_UNPARSED_ARGUMENTS)
+ message(FATAL_ERROR "Unknown keywords given to ecm_add_wayland_server_protocol(): \"${ARGS_UNPARSED_ARGUMENTS}\"")
+ endif()
+
+ ecm_add_wayland_client_protocol(${out_var}
+ PROTOCOL ${ARGS_PROTOCOL}
+ BASENAME ${ARGS_BASENAME})
+
+ get_filename_component(_infile ${ARGS_PROTOCOL} ABSOLUTE)
+ set(_server_header "${CMAKE_CURRENT_BINARY_DIR}/wayland-${ARGS_BASENAME}-server-protocol.h")
+ set_property(SOURCE ${_server_header} PROPERTY SKIP_AUTOMOC ON)
+ set_source_files_properties(${_server_header} GENERATED)
+
+ add_custom_command(OUTPUT "${_server_header}"
+ COMMAND ${WaylandScanner_EXECUTABLE} server-header ${_infile} ${_server_header}
+ DEPENDS ${_infile} VERBATIM)
+
+ list(APPEND ${out_var} "${_server_header}")
+ set(${out_var} ${${out_var}} PARENT_SCOPE)
+endfunction()
diff --git a/cmake/3rdparty/extra-cmake-modules/find-modules/FindX11_XCB.cmake b/cmake/3rdparty/extra-cmake-modules/find-modules/FindX11_XCB.cmake
new file mode 100644
index 0000000000..dd55fd7b30
--- /dev/null
+++ b/cmake/3rdparty/extra-cmake-modules/find-modules/FindX11_XCB.cmake
@@ -0,0 +1,118 @@
+#.rst:
+# FindX11_XCB
+# -----------
+#
+# Try to find the X11 XCB compatibility library.
+#
+# This will define the following variables:
+#
+# ``X11_XCB_FOUND``
+# True if (the requested version of) libX11-xcb is available
+# ``X11_XCB_VERSION``
+# The version of libX11-xcb (this is not guaranteed to be set even when
+# X11_XCB_FOUND is true)
+# ``X11_XCB_LIBRARIES``
+# This can be passed to target_link_libraries() instead of the ``EGL::EGL``
+# target
+# ``X11_XCB_INCLUDE_DIR``
+# This should be passed to target_include_directories() if the target is not
+# used for linking
+# ``X11_XCB_DEFINITIONS``
+# This should be passed to target_compile_options() if the target is not
+# used for linking
+#
+# If ``X11_XCB_FOUND`` is TRUE, it will also define the following imported
+# target:
+#
+# ``X11::XCB``
+# The X11 XCB compatibility library
+#
+# In general we recommend using the imported target, as it is easier to use.
+# Bear in mind, however, that if the target is in the link interface of an
+# exported library, it must be made available by the package config file.
+#
+# Since pre-1.0.0.
+
+#=============================================================================
+# Copyright 2014 Alex Merry <alex.merry@kde.org>
+# Copyright 2011 Fredrik Höglund <fredrik@kde.org>
+# Copyright 2008 Helio Chissini de Castro <helio@kde.org>
+# Copyright 2007 Matthias Kretz <kretz@kde.org>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# 1. Redistributions of source code must retain the copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The name of the author may not be used to endorse or promote products
+# derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#=============================================================================
+
+include(${CMAKE_CURRENT_LIST_DIR}/ECMFindModuleHelpersStub.cmake)
+
+ecm_find_package_version_check(X11_XCB)
+
+# use pkg-config to get the directories and then use these values
+# in the FIND_PATH() and FIND_LIBRARY() calls
+find_package(PkgConfig)
+pkg_check_modules(PKG_X11_XCB QUIET x11-xcb)
+
+set(X11_XCB_DEFINITIONS ${PKG_X11_XCB_CFLAGS_OTHER})
+set(X11_XCB_VERSION ${PKG_X11_XCB_VERSION})
+
+find_path(X11_XCB_INCLUDE_DIR
+ NAMES X11/Xlib-xcb.h
+ HINTS ${PKG_X11_XCB_INCLUDE_DIRS}
+)
+find_library(X11_XCB_LIBRARY
+ NAMES X11-xcb
+ HINTS ${PKG_X11_XCB_LIBRARY_DIRS}
+)
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(X11_XCB
+ FOUND_VAR
+ X11_XCB_FOUND
+ REQUIRED_VARS
+ X11_XCB_LIBRARY
+ X11_XCB_INCLUDE_DIR
+ VERSION_VAR
+ X11_XCB_VERSION
+)
+
+if(X11_XCB_FOUND AND NOT TARGET X11::XCB)
+ add_library(X11::XCB UNKNOWN IMPORTED)
+ set_target_properties(X11::XCB PROPERTIES
+ IMPORTED_LOCATION "${X11_XCB_LIBRARY}"
+ INTERFACE_COMPILE_OPTIONS "${X11_XCB_DEFINITIONS}"
+ INTERFACE_INCLUDE_DIRECTORIES "${X11_XCB_INCLUDE_DIR}"
+ )
+endif()
+
+mark_as_advanced(X11_XCB_INCLUDE_DIR X11_XCB_LIBRARY)
+
+# compatibility variables
+set(X11_XCB_LIBRARIES ${X11_XCB_LIBRARY})
+set(X11_XCB_INCLUDE_DIRS ${X11_XCB_INCLUDE_DIR})
+set(X11_XCB_VERSION_STRING ${X11_XCB_VERSION})
+
+include(FeatureSummary)
+set_package_properties(X11_XCB PROPERTIES
+ URL "http://xorg.freedesktop.org/"
+ DESCRIPTION "A compatibility library for code that translates Xlib API calls into XCB calls"
+)
diff --git a/cmake/3rdparty/extra-cmake-modules/find-modules/FindXCB.cmake b/cmake/3rdparty/extra-cmake-modules/find-modules/FindXCB.cmake
new file mode 100644
index 0000000000..d530d2d7f4
--- /dev/null
+++ b/cmake/3rdparty/extra-cmake-modules/find-modules/FindXCB.cmake
@@ -0,0 +1,201 @@
+#.rst:
+# FindXCB
+# -------
+#
+# Try to find XCB.
+#
+# This is a component-based find module, which makes use of the COMPONENTS and
+# OPTIONAL_COMPONENTS arguments to find_module. The following components are
+# available::
+#
+# XCB
+# ATOM AUX COMPOSITE CURSOR DAMAGE
+# DPMS DRI2 DRI3 EVENT EWMH
+# GLX ICCCM IMAGE KEYSYMS PRESENT
+# RANDR RECORD RENDER RENDERUTIL RES
+# SCREENSAVER SHAPE SHM SYNC UTIL
+# XEVIE XF86DRI XFIXES XINERAMA XINPUT
+# XKB XPRINT XTEST XV XVMC
+#
+# If no components are specified, this module will act as though all components
+# except XINPUT (which is considered unstable) were passed to
+# OPTIONAL_COMPONENTS.
+#
+# This module will define the following variables, independently of the
+# components searched for or found:
+#
+# ``XCB_FOUND``
+# True if (the requestion version of) xcb is available
+# ``XCB_VERSION``
+# Found xcb version
+# ``XCB_TARGETS``
+# A list of all targets imported by this module (note that there may be more
+# than the components that were requested)
+# ``XCB_LIBRARIES``
+# This can be passed to target_link_libraries() instead of the imported
+# targets
+# ``XCB_INCLUDE_DIRS``
+# This should be passed to target_include_directories() if the targets are
+# not used for linking
+# ``XCB_DEFINITIONS``
+# This should be passed to target_compile_options() if the targets are not
+# used for linking
+#
+# For each searched-for components, ``XCB_<component>_FOUND`` will be set to
+# true if the corresponding xcb library was found, and false otherwise. If
+# ``XCB_<component>_FOUND`` is true, the imported target ``XCB::<component>``
+# will be defined. This module will also attempt to determine
+# ``XCB_*_VERSION`` variables for each imported target, although
+# ``XCB_VERSION`` should normally be sufficient.
+#
+# In general we recommend using the imported targets, as they are easier to use
+# and provide more control. Bear in mind, however, that if any target is in the
+# link interface of an exported library, it must be made available by the
+# package config file.
+#
+# Since pre-1.0.0.
+
+#=============================================================================
+# Copyright 2011 Fredrik Höglund <fredrik@kde.org>
+# Copyright 2013 Martin Gräßlin <mgraesslin@kde.org>
+# Copyright 2014-2015 Alex Merry <alex.merry@kde.org>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# 1. Redistributions of source code must retain the copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The name of the author may not be used to endorse or promote products
+# derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#=============================================================================
+
+include(${CMAKE_CURRENT_LIST_DIR}/ECMFindModuleHelpersStub.cmake)
+
+ecm_find_package_version_check(XCB)
+
+# Note that this list needs to be ordered such that any component
+# appears after its dependencies
+set(XCB_known_components
+ XCB
+ RENDER
+ SHAPE
+ XFIXES
+ SHM
+ ATOM
+ AUX
+ COMPOSITE
+ CURSOR
+ DAMAGE
+ DPMS
+ DRI2
+ DRI3
+ EVENT
+ EWMH
+ GLX
+ ICCCM
+ IMAGE
+ KEYSYMS
+ PRESENT
+ RANDR
+ RECORD
+ RENDERUTIL
+ RES
+ SCREENSAVER
+ SYNC
+ UTIL
+ XEVIE
+ XF86DRI
+ XINERAMA
+ XINPUT
+ XKB
+ XPRINT
+ XTEST
+ XV
+ XVMC
+)
+
+# XINPUT is unstable; do not include it by default
+set(XCB_default_components ${XCB_known_components})
+list(REMOVE_ITEM XCB_default_components "XINPUT")
+
+# default component info: xcb components have fairly predictable
+# header files, library names and pkg-config names
+foreach(_comp ${XCB_known_components})
+ string(TOLOWER "${_comp}" _lc_comp)
+ set(XCB_${_comp}_component_deps XCB)
+ set(XCB_${_comp}_pkg_config "xcb-${_lc_comp}")
+ set(XCB_${_comp}_lib "xcb-${_lc_comp}")
+ set(XCB_${_comp}_header "xcb/${_lc_comp}.h")
+endforeach()
+# exceptions
+set(XCB_XCB_component_deps)
+set(XCB_COMPOSITE_component_deps XCB XFIXES)
+set(XCB_DAMAGE_component_deps XCB XFIXES)
+set(XCB_IMAGE_component_deps XCB SHM)
+set(XCB_RENDERUTIL_component_deps XCB RENDER)
+set(XCB_XFIXES_component_deps XCB RENDER SHAPE)
+set(XCB_XVMC_component_deps XCB XV)
+set(XCB_XV_component_deps XCB SHM)
+set(XCB_XCB_pkg_config "xcb")
+set(XCB_XCB_lib "xcb")
+set(XCB_ATOM_header "xcb/xcb_atom.h")
+set(XCB_ATOM_lib "xcb-util")
+set(XCB_AUX_header "xcb/xcb_aux.h")
+set(XCB_AUX_lib "xcb-util")
+set(XCB_CURSOR_header "xcb/xcb_cursor.h")
+set(XCB_EVENT_header "xcb/xcb_event.h")
+set(XCB_EVENT_lib "xcb-util")
+set(XCB_EWMH_header "xcb/xcb_ewmh.h")
+set(XCB_ICCCM_header "xcb/xcb_icccm.h")
+set(XCB_IMAGE_header "xcb/xcb_image.h")
+set(XCB_KEYSYMS_header "xcb/xcb_keysyms.h")
+set(XCB_PIXEL_header "xcb/xcb_pixel.h")
+set(XCB_RENDERUTIL_header "xcb/xcb_renderutil.h")
+set(XCB_RENDERUTIL_lib "xcb-render-util")
+set(XCB_UTIL_header "xcb/xcb_util.h")
+
+ecm_find_package_parse_components(XCB
+ RESULT_VAR XCB_components
+ KNOWN_COMPONENTS ${XCB_known_components}
+ DEFAULT_COMPONENTS ${XCB_default_components}
+)
+
+list(FIND XCB_components "XINPUT" _XCB_XINPUT_index)
+if (NOT _XCB_XINPUT_index EQUAL -1)
+ message(AUTHOR_WARNING "XINPUT from XCB was requested: this is EXPERIMENTAL and is likely to unavailable on many systems!")
+endif()
+
+ecm_find_package_handle_library_components(XCB
+ COMPONENTS ${XCB_components}
+)
+
+find_package_handle_standard_args(XCB
+ FOUND_VAR
+ XCB_FOUND
+ REQUIRED_VARS
+ XCB_LIBRARIES
+ VERSION_VAR
+ XCB_VERSION
+ HANDLE_COMPONENTS
+)
+
+include(FeatureSummary)
+set_package_properties(XCB PROPERTIES
+ URL "http://xcb.freedesktop.org"
+ DESCRIPTION "X protocol C-language Binding"
+)
diff --git a/cmake/3rdparty/extra-cmake-modules/modules/ECMEnableSanitizers.cmake b/cmake/3rdparty/extra-cmake-modules/modules/ECMEnableSanitizers.cmake
new file mode 100644
index 0000000000..06cc0b66d8
--- /dev/null
+++ b/cmake/3rdparty/extra-cmake-modules/modules/ECMEnableSanitizers.cmake
@@ -0,0 +1,173 @@
+#.rst:
+# ECMEnableSanitizers
+# -------------------
+#
+# Enable compiler sanitizer flags.
+#
+# The following sanitizers are supported:
+#
+# - Address Sanitizer
+# - Memory Sanitizer
+# - Thread Sanitizer
+# - Leak Sanitizer
+# - Undefined Behaviour Sanitizer
+#
+# All of them are implemented in Clang, depending on your version, and
+# there is an work in progress in GCC, where some of them are currently
+# implemented.
+#
+# This module will check your current compiler version to see if it
+# supports the sanitizers that you want to enable
+#
+# Usage
+# =====
+#
+# Simply add::
+#
+# include(ECMEnableSanitizers)
+#
+# to your ``CMakeLists.txt``. Note that this module is included in
+# KDECompilerSettings, so projects using that module do not need to also
+# include this one.
+#
+# The sanitizers are not enabled by default. Instead, you must set
+# ``ECM_ENABLE_SANITIZERS`` (either in your ``CMakeLists.txt`` or on the
+# command line) to a semicolon-separated list of sanitizers you wish to enable.
+# The options are:
+#
+# - address
+# - memory
+# - thread
+# - leak
+# - undefined
+#
+# The sanitizers "address", "memory" and "thread" are mutually exclusive. You
+# cannot enable two of them in the same build.
+#
+# "leak" requires the "address" sanitizer.
+#
+# .. note::
+#
+# To reduce the overhead induced by the instrumentation of the sanitizers, it
+# is advised to enable compiler optimizations (``-O1`` or higher).
+#
+# Example
+# =======
+#
+# This is an example of usage::
+#
+# mkdir build
+# cd build
+# cmake -DECM_ENABLE_SANITIZERS='address;leak;undefined' ..
+#
+# .. note::
+#
+# Most of the sanitizers will require Clang. To enable it, use::
+#
+# -DCMAKE_CXX_COMPILER=clang++
+#
+# Since 1.3.0.
+
+#=============================================================================
+# Copyright 2014 Mathieu Tarral <mathieu.tarral@gmail.com>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# 1. Redistributions of source code must retain the copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The name of the author may not be used to endorse or promote products
+# derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+# MACRO check_compiler_version
+#-----------------------------
+macro (check_compiler_version gcc_required_version clang_required_version)
+ if (
+ (
+ CMAKE_CXX_COMPILER_ID MATCHES "GNU"
+ AND
+ CMAKE_CXX_COMPILER_VERSION VERSION_LESS ${gcc_required_version}
+ )
+ OR
+ (
+ CMAKE_CXX_COMPILER_ID MATCHES "Clang"
+ AND
+ CMAKE_CXX_COMPILER_VERSION VERSION_LESS ${clang_required_version}
+ )
+ )
+ # error !
+ message(FATAL_ERROR "You ask to enable the sanitizer ${CUR_SANITIZER},
+ but your compiler ${CMAKE_CXX_COMPILER_ID} version ${CMAKE_CXX_COMPILER_VERSION}
+ does not support it !
+ You should use at least GCC ${gcc_required_version} or Clang ${clang_required_version}
+ (99.99 means not implemented yet)")
+ endif ()
+endmacro ()
+
+# MACRO check_compiler_support
+#------------------------------
+macro (enable_sanitizer_flags sanitize_option)
+ if (${sanitize_option} MATCHES "address")
+ check_compiler_version("4.8" "3.1")
+ set(XSAN_COMPILE_FLAGS "-fsanitize=address -fno-omit-frame-pointer -fno-optimize-sibling-calls")
+ set(XSAN_LINKER_FLAGS "asan")
+ elseif (${sanitize_option} MATCHES "thread")
+ check_compiler_version("4.8" "3.1")
+ set(XSAN_COMPILE_FLAGS "-fsanitize=thread")
+ set(XSAN_LINKER_FLAGS "tsan")
+ elseif (${sanitize_option} MATCHES "memory")
+ check_compiler_version("99.99" "3.1")
+ set(XSAN_COMPILE_FLAGS "-fsanitize=memory")
+ elseif (${sanitize_option} MATCHES "leak")
+ check_compiler_version("4.9" "3.4")
+ set(XSAN_COMPILE_FLAGS "-fsanitize=leak")
+ set(XSAN_LINKER_FLAGS "lsan")
+ elseif (${sanitize_option} MATCHES "undefined")
+ check_compiler_version("4.9" "3.1")
+ set(XSAN_COMPILE_FLAGS "-fsanitize=undefined -fno-omit-frame-pointer -fno-optimize-sibling-calls")
+ else ()
+ message(FATAL_ERROR "Compiler sanitizer option \"${sanitize_option}\" not supported.")
+ endif ()
+endmacro ()
+
+if (ECM_ENABLE_SANITIZERS)
+ if (CMAKE_CXX_COMPILER_ID MATCHES "GNU" OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+ # for each element of the ECM_ENABLE_SANITIZERS list
+ foreach ( CUR_SANITIZER ${ECM_ENABLE_SANITIZERS} )
+ # lowercase filter
+ string(TOLOWER ${CUR_SANITIZER} CUR_SANITIZER)
+ # check option and enable appropriate flags
+ enable_sanitizer_flags ( ${CUR_SANITIZER} )
+ # TODO: GCC will not link pthread library if enabled ASan
+ if(CMAKE_C_COMPILER_ID MATCHES "Clang")
+ set( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${XSAN_COMPILE_FLAGS}" )
+ endif()
+ set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${XSAN_COMPILE_FLAGS}" )
+ if(CMAKE_CXX_COMPILER_ID MATCHES "GNU")
+ link_libraries(${XSAN_LINKER_FLAGS})
+ endif()
+ if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
+ string(REPLACE "-Wl,--no-undefined" "" CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS}")
+ string(REPLACE "-Wl,--no-undefined" "" CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS}")
+ endif ()
+ endforeach()
+ else()
+ message(STATUS "Tried to enable sanitizers (-DECM_ENABLE_SANITIZERS=${ECM_ENABLE_SANITIZERS}), \
+but compiler (${CMAKE_CXX_COMPILER_ID}) does not have sanitizer support")
+ endif()
+endif()
diff --git a/cmake/3rdparty/extra-cmake-modules/modules/ECMFindModuleHelpers.cmake b/cmake/3rdparty/extra-cmake-modules/modules/ECMFindModuleHelpers.cmake
new file mode 100644
index 0000000000..f2e32f959e
--- /dev/null
+++ b/cmake/3rdparty/extra-cmake-modules/modules/ECMFindModuleHelpers.cmake
@@ -0,0 +1,297 @@
+#.rst:
+# ECMFindModuleHelpers
+# --------------------
+#
+# Helper macros for find modules: ecm_find_package_version_check(),
+# ecm_find_package_parse_components() and
+# ecm_find_package_handle_library_components().
+#
+# ::
+#
+# ecm_find_package_version_check(<name>)
+#
+# Prints warnings if the CMake version or the project's required CMake version
+# is older than that required by extra-cmake-modules.
+#
+# ::
+#
+# ecm_find_package_parse_components(<name>
+# RESULT_VAR <variable>
+# KNOWN_COMPONENTS <component1> [<component2> [...]]
+# [SKIP_DEPENDENCY_HANDLING])
+#
+# This macro will populate <variable> with a list of components found in
+# <name>_FIND_COMPONENTS, after checking that all those components are in the
+# list of KNOWN_COMPONENTS; if there are any unknown components, it will print
+# an error or warning (depending on the value of <name>_FIND_REQUIRED) and call
+# return().
+#
+# The order of components in <variable> is guaranteed to match the order they
+# are listed in the KNOWN_COMPONENTS argument.
+#
+# If SKIP_DEPENDENCY_HANDLING is not set, for each component the variable
+# <name>_<component>_component_deps will be checked for dependent components.
+# If <component> is listed in <name>_FIND_COMPONENTS, then all its (transitive)
+# dependencies will also be added to <variable>.
+#
+# ::
+#
+# ecm_find_package_handle_library_components(<name>
+# COMPONENTS <component> [<component> [...]]
+# [SKIP_DEPENDENCY_HANDLING])
+# [SKIP_PKG_CONFIG])
+#
+# Creates an imported library target for each component. The operation of this
+# macro depends on the presence of a number of CMake variables.
+#
+# The <name>_<component>_lib variable should contain the name of this library,
+# and <name>_<component>_header variable should contain the name of a header
+# file associated with it (whatever relative path is normally passed to
+# '#include'). <name>_<component>_header_subdir variable can be used to specify
+# which subdirectory of the include path the headers will be found in.
+# ecm_find_package_components() will then search for the library
+# and include directory (creating appropriate cache variables) and create an
+# imported library target named <name>::<component>.
+#
+# Additional variables can be used to provide additional information:
+#
+# If SKIP_PKG_CONFIG, the <name>_<component>_pkg_config variable is set, and
+# pkg-config is found, the pkg-config module given by
+# <name>_<component>_pkg_config will be searched for and used to help locate the
+# library and header file. It will also be used to set
+# <name>_<component>_VERSION.
+#
+# Note that if version information is found via pkg-config,
+# <name>_<component>_FIND_VERSION can be set to require a particular version
+# for each component.
+#
+# If SKIP_DEPENDENCY_HANDLING is not set, the INTERFACE_LINK_LIBRARIES property
+# of the imported target for <component> will be set to contain the imported
+# targets for the components listed in <name>_<component>_component_deps.
+# <component>_FOUND will also be set to false if any of the compoments in
+# <name>_<component>_component_deps are not found. This requires the components
+# in <name>_<component>_component_deps to be listed before <component> in the
+# COMPONENTS argument.
+#
+# The following variables will be set:
+#
+# ``<name>_TARGETS``
+# the imported targets
+# ``<name>_LIBRARIES``
+# the found libraries
+# ``<name>_INCLUDE_DIRS``
+# the combined required include directories for the components
+# ``<name>_DEFINITIONS``
+# the "other" CFLAGS provided by pkg-config, if any
+# ``<name>_VERSION``
+# the value of ``<name>_<component>_VERSION`` for the first component that
+# has this variable set (note that components are searched for in the order
+# they are passed to the macro), although if it is already set, it will not
+# be altered
+#
+# Note that these variables are never cleared, so if
+# ecm_find_package_handle_library_components() is called multiple times with
+# different components (typically because of multiple find_package() calls) then
+# ``<name>_TARGETS``, for example, will contain all the targets found in any
+# call (although no duplicates).
+#
+# Since pre-1.0.0.
+
+#=============================================================================
+# Copyright 2014 Alex Merry <alex.merry@kde.org>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# 1. Redistributions of source code must retain the copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The name of the author may not be used to endorse or promote products
+# derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+include(CMakeParseArguments)
+
+macro(ecm_find_package_version_check module_name)
+ if(CMAKE_VERSION VERSION_LESS 2.8.12)
+ message(FATAL_ERROR "CMake 2.8.12 is required by Find${module_name}.cmake")
+ endif()
+ if(CMAKE_MINIMUM_REQUIRED_VERSION VERSION_LESS 2.8.12)
+ message(AUTHOR_WARNING "Your project should require at least CMake 2.8.12 to use Find${module_name}.cmake")
+ endif()
+endmacro()
+
+macro(ecm_find_package_parse_components module_name)
+ set(ecm_fppc_options SKIP_DEPENDENCY_HANDLING)
+ set(ecm_fppc_oneValueArgs RESULT_VAR)
+ set(ecm_fppc_multiValueArgs KNOWN_COMPONENTS DEFAULT_COMPONENTS)
+ cmake_parse_arguments(ECM_FPPC "${ecm_fppc_options}" "${ecm_fppc_oneValueArgs}" "${ecm_fppc_multiValueArgs}" ${ARGN})
+
+ if(ECM_FPPC_UNPARSED_ARGUMENTS)
+ message(FATAL_ERROR "Unexpected arguments to ecm_find_package_parse_components: ${ECM_FPPC_UNPARSED_ARGUMENTS}")
+ endif()
+ if(NOT ECM_FPPC_RESULT_VAR)
+ message(FATAL_ERROR "Missing RESULT_VAR argument to ecm_find_package_parse_components")
+ endif()
+ if(NOT ECM_FPPC_KNOWN_COMPONENTS)
+ message(FATAL_ERROR "Missing KNOWN_COMPONENTS argument to ecm_find_package_parse_components")
+ endif()
+ if(NOT ECM_FPPC_DEFAULT_COMPONENTS)
+ set(ECM_FPPC_DEFAULT_COMPONENTS ${ECM_FPPC_KNOWN_COMPONENTS})
+ endif()
+
+ if(${module_name}_FIND_COMPONENTS)
+ set(ecm_fppc_requestedComps ${${module_name}_FIND_COMPONENTS})
+
+ if(NOT ECM_FPPC_SKIP_DEPENDENCY_HANDLING)
+ # Make sure deps are included
+ foreach(ecm_fppc_comp ${ecm_fppc_requestedComps})
+ foreach(ecm_fppc_dep_comp ${${module_name}_${ecm_fppc_comp}_component_deps})
+ list(FIND ecm_fppc_requestedComps "${ecm_fppc_dep_comp}" ecm_fppc_index)
+ if("${ecm_fppc_index}" STREQUAL "-1")
+ if(NOT ${module_name}_FIND_QUIETLY)
+ message(STATUS "${module_name}: ${ecm_fppc_comp} requires ${${module_name}_${ecm_fppc_comp}_component_deps}")
+ endif()
+ list(APPEND ecm_fppc_requestedComps "${ecm_fppc_dep_comp}")
+ endif()
+ endforeach()
+ endforeach()
+ else()
+ message(STATUS "Skipping dependency handling for ${module_name}")
+ endif()
+ list(REMOVE_DUPLICATES ecm_fppc_requestedComps)
+
+ # This makes sure components are listed in the same order as
+ # KNOWN_COMPONENTS (potentially important for inter-dependencies)
+ set(${ECM_FPPC_RESULT_VAR})
+ foreach(ecm_fppc_comp ${ECM_FPPC_KNOWN_COMPONENTS})
+ list(FIND ecm_fppc_requestedComps "${ecm_fppc_comp}" ecm_fppc_index)
+ if(NOT "${ecm_fppc_index}" STREQUAL "-1")
+ list(APPEND ${ECM_FPPC_RESULT_VAR} "${ecm_fppc_comp}")
+ list(REMOVE_AT ecm_fppc_requestedComps ${ecm_fppc_index})
+ endif()
+ endforeach()
+ # if there are any left, they are unknown components
+ if(ecm_fppc_requestedComps)
+ set(ecm_fppc_msgType STATUS)
+ if(${module_name}_FIND_REQUIRED)
+ set(ecm_fppc_msgType FATAL_ERROR)
+ endif()
+ if(NOT ${module_name}_FIND_QUIETLY)
+ message(${ecm_fppc_msgType} "${module_name}: requested unknown components ${ecm_fppc_requestedComps}")
+ endif()
+ return()
+ endif()
+ else()
+ set(${ECM_FPPC_RESULT_VAR} ${ECM_FPPC_DEFAULT_COMPONENTS})
+ endif()
+endmacro()
+
+macro(ecm_find_package_handle_library_components module_name)
+ set(ecm_fpwc_options SKIP_PKG_CONFIG SKIP_DEPENDENCY_HANDLING)
+ set(ecm_fpwc_oneValueArgs)
+ set(ecm_fpwc_multiValueArgs COMPONENTS)
+ cmake_parse_arguments(ECM_FPWC "${ecm_fpwc_options}" "${ecm_fpwc_oneValueArgs}" "${ecm_fpwc_multiValueArgs}" ${ARGN})
+
+ if(ECM_FPWC_UNPARSED_ARGUMENTS)
+ message(FATAL_ERROR "Unexpected arguments to ecm_find_package_handle_components: ${ECM_FPWC_UNPARSED_ARGUMENTS}")
+ endif()
+ if(NOT ECM_FPWC_COMPONENTS)
+ message(FATAL_ERROR "Missing COMPONENTS argument to ecm_find_package_handle_components")
+ endif()
+
+ include(FindPackageHandleStandardArgs)
+ find_package(PkgConfig)
+ foreach(ecm_fpwc_comp ${ECM_FPWC_COMPONENTS})
+ set(ecm_fpwc_dep_vars)
+ set(ecm_fpwc_dep_targets)
+ if(NOT SKIP_DEPENDENCY_HANDLING)
+ foreach(ecm_fpwc_dep ${${module_name}_${ecm_fpwc_comp}_component_deps})
+ list(APPEND ecm_fpwc_dep_vars "${module_name}_${ecm_fpwc_dep}_FOUND")
+ list(APPEND ecm_fpwc_dep_targets "${module_name}::${ecm_fpwc_dep}")
+ endforeach()
+ endif()
+
+ if(NOT ECM_FPWC_SKIP_PKG_CONFIG AND ${module_name}_${ecm_fpwc_comp}_pkg_config)
+ pkg_check_modules(PKG_${module_name}_${ecm_fpwc_comp} QUIET
+ ${${module_name}_${ecm_fpwc_comp}_pkg_config})
+ endif()
+
+ find_path(${module_name}_${ecm_fpwc_comp}_INCLUDE_DIR
+ NAMES ${${module_name}_${ecm_fpwc_comp}_header}
+ HINTS ${PKG_${module_name}_${ecm_fpwc_comp}_INCLUDE_DIRS}
+ PATH_SUFFIXES ${${module_name}_${ecm_fpwc_comp}_header_subdir}
+ )
+ find_library(${module_name}_${ecm_fpwc_comp}_LIBRARY
+ NAMES ${${module_name}_${ecm_fpwc_comp}_lib}
+ HINTS ${PKG_${module_name}_${ecm_fpwc_comp}_LIBRARY_DIRS}
+ )
+
+ set(${module_name}_${ecm_fpwc_comp}_VERSION "${PKG_${module_name}_${ecm_fpwc_comp}_VERSION}")
+ if(NOT ${module_name}_VERSION)
+ set(${module_name}_VERSION ${${module_name}_${ecm_fpwc_comp}_VERSION})
+ endif()
+
+ find_package_handle_standard_args(${module_name}_${ecm_fpwc_comp}
+ FOUND_VAR
+ ${module_name}_${ecm_fpwc_comp}_FOUND
+ REQUIRED_VARS
+ ${module_name}_${ecm_fpwc_comp}_LIBRARY
+ ${module_name}_${ecm_fpwc_comp}_INCLUDE_DIR
+ ${ecm_fpwc_dep_vars}
+ VERSION_VAR
+ ${module_name}_${ecm_fpwc_comp}_VERSION
+ )
+
+ mark_as_advanced(
+ ${module_name}_${ecm_fpwc_comp}_LIBRARY
+ ${module_name}_${ecm_fpwc_comp}_INCLUDE_DIR
+ )
+
+ if(${module_name}_${ecm_fpwc_comp}_FOUND)
+ list(APPEND ${module_name}_LIBRARIES
+ "${${module_name}_${ecm_fpwc_comp}_LIBRARY}")
+ list(APPEND ${module_name}_INCLUDE_DIRS
+ "${${module_name}_${ecm_fpwc_comp}_INCLUDE_DIR}")
+ set(${module_name}_DEFINITIONS
+ ${${module_name}_DEFINITIONS}
+ ${PKG_${module_name}_${ecm_fpwc_comp}_DEFINITIONS})
+ if(NOT TARGET ${module_name}::${ecm_fpwc_comp})
+ add_library(${module_name}::${ecm_fpwc_comp} UNKNOWN IMPORTED)
+ set_target_properties(${module_name}::${ecm_fpwc_comp} PROPERTIES
+ IMPORTED_LOCATION "${${module_name}_${ecm_fpwc_comp}_LIBRARY}"
+ INTERFACE_COMPILE_OPTIONS "${PKG_${module_name}_${ecm_fpwc_comp}_DEFINITIONS}"
+ INTERFACE_INCLUDE_DIRECTORIES "${${module_name}_${ecm_fpwc_comp}_INCLUDE_DIR}"
+ INTERFACE_LINK_LIBRARIES "${ecm_fpwc_dep_targets}"
+ )
+ endif()
+ list(APPEND ${module_name}_TARGETS
+ "${module_name}::${ecm_fpwc_comp}")
+ endif()
+ endforeach()
+ if(${module_name}_LIBRARIES)
+ list(REMOVE_DUPLICATES ${module_name}_LIBRARIES)
+ endif()
+ if(${module_name}_INCLUDE_DIRS)
+ list(REMOVE_DUPLICATES ${module_name}_INCLUDE_DIRS)
+ endif()
+ if(${module_name}_DEFINITIONS)
+ list(REMOVE_DUPLICATES ${module_name}_DEFINITIONS)
+ endif()
+ if(${module_name}_TARGETS)
+ list(REMOVE_DUPLICATES ${module_name}_TARGETS)
+ endif()
+endmacro()
diff --git a/cmake/3rdparty/extra-cmake-modules/qt_attribution.json b/cmake/3rdparty/extra-cmake-modules/qt_attribution.json
new file mode 100644
index 0000000000..cebebf82eb
--- /dev/null
+++ b/cmake/3rdparty/extra-cmake-modules/qt_attribution.json
@@ -0,0 +1,15 @@
+{
+ "Id": "extra-cmake-modules",
+ "Name": "extra-cmake-modules",
+ "QDocModule": "qtcore",
+ "QtUsage": "Used as part of the build system.",
+
+ "Description": "Additional CMake modules.",
+ "Homepage": "https://api.kde.org/ecm/",
+ "Version": "5.50.0",
+
+ "License": "BSD-3-Clause",
+ "LicenseId": "BSD 3-Clause License",
+ "LicenseFile": "COPYING-CMAKE-SCRIPTS",
+ "Copyright": "Copyright © 2011-2018 The KDE community"
+}
diff --git a/cmake/3rdparty/kwin/COPYING-CMAKE-SCRIPTS b/cmake/3rdparty/kwin/COPYING-CMAKE-SCRIPTS
new file mode 100644
index 0000000000..4b417765f3
--- /dev/null
+++ b/cmake/3rdparty/kwin/COPYING-CMAKE-SCRIPTS
@@ -0,0 +1,22 @@
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions
+are met:
+
+1. Redistributions of source code must retain the copyright
+ notice, this list of conditions and the following disclaimer.
+2. Redistributions in binary form must reproduce the copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+3. The name of the author may not be used to endorse or promote products
+ derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/cmake/3rdparty/kwin/FindLibdrm.cmake b/cmake/3rdparty/kwin/FindLibdrm.cmake
new file mode 100644
index 0000000000..9936e07eee
--- /dev/null
+++ b/cmake/3rdparty/kwin/FindLibdrm.cmake
@@ -0,0 +1,126 @@
+#.rst:
+# FindLibdrm
+# -------
+#
+# Try to find libdrm on a Unix system.
+#
+# This will define the following variables:
+#
+# ``Libdrm_FOUND``
+# True if (the requested version of) libdrm is available
+# ``Libdrm_VERSION``
+# The version of libdrm
+# ``Libdrm_LIBRARIES``
+# This can be passed to target_link_libraries() instead of the ``Libdrm::Libdrm``
+# target
+# ``Libdrm_INCLUDE_DIRS``
+# This should be passed to target_include_directories() if the target is not
+# used for linking
+# ``Libdrm_DEFINITIONS``
+# This should be passed to target_compile_options() if the target is not
+# used for linking
+#
+# If ``Libdrm_FOUND`` is TRUE, it will also define the following imported target:
+#
+# ``Libdrm::Libdrm``
+# The libdrm library
+#
+# In general we recommend using the imported target, as it is easier to use.
+# Bear in mind, however, that if the target is in the link interface of an
+# exported library, it must be made available by the package config file.
+
+#=============================================================================
+# Copyright 2014 Alex Merry <alex.merry@kde.org>
+# Copyright 2014 Martin Gräßlin <mgraesslin@kde.org>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# 1. Redistributions of source code must retain the copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The name of the author may not be used to endorse or promote products
+# derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#=============================================================================
+
+if(CMAKE_VERSION VERSION_LESS 2.8.12)
+ message(FATAL_ERROR "CMake 2.8.12 is required by FindLibdrm.cmake")
+endif()
+if(CMAKE_MINIMUM_REQUIRED_VERSION VERSION_LESS 2.8.12)
+ message(AUTHOR_WARNING "Your project should require at least CMake 2.8.12 to use FindLibdrm.cmake")
+endif()
+
+if(NOT WIN32)
+ # Use pkg-config to get the directories and then use these values
+ # in the FIND_PATH() and FIND_LIBRARY() calls
+ find_package(PkgConfig)
+ pkg_check_modules(PKG_Libdrm QUIET libdrm)
+
+ set(Libdrm_DEFINITIONS ${PKG_Libdrm_CFLAGS_OTHER})
+ set(Libdrm_VERSION ${PKG_Libdrm_VERSION})
+
+ find_path(Libdrm_INCLUDE_DIR
+ NAMES
+ xf86drm.h
+ HINTS
+ ${PKG_Libdrm_INCLUDE_DIRS}
+ )
+ find_library(Libdrm_LIBRARY
+ NAMES
+ drm
+ HINTS
+ ${PKG_Libdrm_LIBRARY_DIRS}
+ )
+
+ include(FindPackageHandleStandardArgs)
+ find_package_handle_standard_args(Libdrm
+ FOUND_VAR
+ Libdrm_FOUND
+ REQUIRED_VARS
+ Libdrm_LIBRARY
+ Libdrm_INCLUDE_DIR
+ VERSION_VAR
+ Libdrm_VERSION
+ )
+
+ if(Libdrm_FOUND AND NOT TARGET Libdrm::Libdrm)
+ add_library(Libdrm::Libdrm UNKNOWN IMPORTED)
+ set_target_properties(Libdrm::Libdrm PROPERTIES
+ IMPORTED_LOCATION "${Libdrm_LIBRARY}"
+ INTERFACE_COMPILE_OPTIONS "${Libdrm_DEFINITIONS}"
+ INTERFACE_INCLUDE_DIRECTORIES "${Libdrm_INCLUDE_DIR}"
+ INTERFACE_INCLUDE_DIRECTORIES "${Libdrm_INCLUDE_DIR}/libdrm"
+ )
+ endif()
+
+ mark_as_advanced(Libdrm_LIBRARY Libdrm_INCLUDE_DIR)
+
+ # compatibility variables
+ set(Libdrm_LIBRARIES ${Libdrm_LIBRARY})
+ set(Libdrm_INCLUDE_DIRS ${Libdrm_INCLUDE_DIR} "${Libdrm_INCLUDE_DIR}/libdrm")
+ set(Libdrm_VERSION_STRING ${Libdrm_VERSION})
+
+else()
+ message(STATUS "FindLibdrm.cmake cannot find libdrm on Windows systems.")
+ set(Libdrm_FOUND FALSE)
+endif()
+
+include(FeatureSummary)
+set_package_properties(Libdrm PROPERTIES
+ URL "https://wiki.freedesktop.org/dri/"
+ DESCRIPTION "Userspace interface to kernel DRM services."
+)
diff --git a/cmake/3rdparty/kwin/FindLibinput.cmake b/cmake/3rdparty/kwin/FindLibinput.cmake
new file mode 100644
index 0000000000..b856e0bbcb
--- /dev/null
+++ b/cmake/3rdparty/kwin/FindLibinput.cmake
@@ -0,0 +1,125 @@
+#.rst:
+# FindLibinput
+# -------
+#
+# Try to find libinput on a Unix system.
+#
+# This will define the following variables:
+#
+# ``Libinput_FOUND``
+# True if (the requested version of) libinput is available
+# ``Libinput_VERSION``
+# The version of libinput
+# ``Libinput_LIBRARIES``
+# This can be passed to target_link_libraries() instead of the ``Libinput::Libinput``
+# target
+# ``Libinput_INCLUDE_DIRS``
+# This should be passed to target_include_directories() if the target is not
+# used for linking
+# ``Libinput_DEFINITIONS``
+# This should be passed to target_compile_options() if the target is not
+# used for linking
+#
+# If ``Libinput_FOUND`` is TRUE, it will also define the following imported target:
+#
+# ``Libinput::Libinput``
+# The libinput library
+#
+# In general we recommend using the imported target, as it is easier to use.
+# Bear in mind, however, that if the target is in the link interface of an
+# exported library, it must be made available by the package config file.
+
+#=============================================================================
+# Copyright 2014 Alex Merry <alex.merry@kde.org>
+# Copyright 2014 Martin Gräßlin <mgraesslin@kde.org>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# 1. Redistributions of source code must retain the copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The name of the author may not be used to endorse or promote products
+# derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#=============================================================================
+
+if(CMAKE_VERSION VERSION_LESS 2.8.12)
+ message(FATAL_ERROR "CMake 2.8.12 is required by FindLibinput.cmake")
+endif()
+if(CMAKE_MINIMUM_REQUIRED_VERSION VERSION_LESS 2.8.12)
+ message(AUTHOR_WARNING "Your project should require at least CMake 2.8.12 to use FindLibinput.cmake")
+endif()
+
+if(NOT WIN32)
+ # Use pkg-config to get the directories and then use these values
+ # in the FIND_PATH() and FIND_LIBRARY() calls
+ find_package(PkgConfig)
+ pkg_check_modules(PKG_Libinput QUIET libinput)
+
+ set(Libinput_DEFINITIONS ${PKG_Libinput_CFLAGS_OTHER})
+ set(Libinput_VERSION ${PKG_Libinput_VERSION})
+
+ find_path(Libinput_INCLUDE_DIR
+ NAMES
+ libinput.h
+ HINTS
+ ${PKG_Libinput_INCLUDE_DIRS}
+ )
+ find_library(Libinput_LIBRARY
+ NAMES
+ input
+ HINTS
+ ${PKG_Libinput_LIBRARY_DIRS}
+ )
+
+ include(FindPackageHandleStandardArgs)
+ find_package_handle_standard_args(Libinput
+ FOUND_VAR
+ Libinput_FOUND
+ REQUIRED_VARS
+ Libinput_LIBRARY
+ Libinput_INCLUDE_DIR
+ VERSION_VAR
+ Libinput_VERSION
+ )
+
+ if(Libinput_FOUND AND NOT TARGET Libinput::Libinput)
+ add_library(Libinput::Libinput UNKNOWN IMPORTED)
+ set_target_properties(Libinput::Libinput PROPERTIES
+ IMPORTED_LOCATION "${Libinput_LIBRARY}"
+ INTERFACE_COMPILE_OPTIONS "${Libinput_DEFINITIONS}"
+ INTERFACE_INCLUDE_DIRECTORIES "${Libinput_INCLUDE_DIR}"
+ )
+ endif()
+
+ mark_as_advanced(Libinput_LIBRARY Libinput_INCLUDE_DIR)
+
+ # compatibility variables
+ set(Libinput_LIBRARIES ${Libinput_LIBRARY})
+ set(Libinput_INCLUDE_DIRS ${Libinput_INCLUDE_DIR})
+ set(Libinput_VERSION_STRING ${Libinput_VERSION})
+
+else()
+ message(STATUS "FindLibinput.cmake cannot find libinput on Windows systems.")
+ set(Libinput_FOUND FALSE)
+endif()
+
+include(FeatureSummary)
+set_package_properties(Libinput PROPERTIES
+ URL "http://www.freedesktop.org/wiki/Software/libinput/"
+ DESCRIPTION "Library to handle input devices in Wayland compositors and to provide a generic X.Org input driver."
+)
diff --git a/cmake/3rdparty/kwin/FindXKB.cmake b/cmake/3rdparty/kwin/FindXKB.cmake
new file mode 100644
index 0000000000..0d599df0fd
--- /dev/null
+++ b/cmake/3rdparty/kwin/FindXKB.cmake
@@ -0,0 +1,101 @@
+# Try to find xkbcommon on a Unix system
+#
+# This will define:
+#
+# XKB_FOUND - True if XKB is available
+# XKB_LIBRARIES - Link these to use XKB
+# XKB_INCLUDE_DIRS - Include directory for XKB
+# XKB_DEFINITIONS - Compiler flags for using XKB
+#
+# Additionally, the following imported targets will be defined:
+#
+# XKB::XKB
+#
+# Copyright (c) 2014 Martin Gräßlin <mgraesslin@kde.org>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. Neither the name of the University nor the names of its contributors
+# may be used to endorse or promote products derived from this software
+# without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+# ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+# SUCH DAMAGE.
+
+if(CMAKE_VERSION VERSION_LESS 2.8.12)
+ message(FATAL_ERROR "CMake 2.8.12 is required by FindXKB.cmake")
+endif()
+if(CMAKE_MINIMUM_REQUIRED_VERSION VERSION_LESS 2.8.12)
+ message(AUTHOR_WARNING "Your project should require at least CMake 2.8.12 to use FindXKB.cmake")
+endif()
+
+if(NOT WIN32)
+ # Use pkg-config to get the directories and then use these values
+ # in the FIND_PATH() and FIND_LIBRARY() calls
+ find_package(PkgConfig)
+ pkg_check_modules(PKG_XKB QUIET xkbcommon)
+
+ set(XKB_DEFINITIONS ${PKG_XKB_CFLAGS_OTHER})
+
+ find_path(XKB_INCLUDE_DIR
+ NAMES
+ xkbcommon/xkbcommon.h
+ HINTS
+ ${PKG_XKB_INCLUDE_DIRS}
+ )
+ find_library(XKB_LIBRARY
+ NAMES
+ xkbcommon
+ HINTS
+ ${PKG_XKB_LIBRARY_DIRS}
+ )
+
+ set(XKB_LIBRARIES ${XKB_LIBRARY})
+ set(XKB_INCLUDE_DIRS ${XKB_INCLUDE_DIR})
+ set(XKB_VERSION ${PKG_XKB_VERSION})
+
+ include(FindPackageHandleStandardArgs)
+ find_package_handle_standard_args(XKB
+ FOUND_VAR
+ XKB_FOUND
+ REQUIRED_VARS
+ XKB_LIBRARY
+ XKB_INCLUDE_DIR
+ VERSION_VAR
+ XKB_VERSION
+ )
+
+ if(XKB_FOUND AND NOT TARGET XKB::XKB)
+ add_library(XKB::XKB UNKNOWN IMPORTED)
+ set_target_properties(XKB::XKB PROPERTIES
+ IMPORTED_LOCATION "${XKB_LIBRARY}"
+ INTERFACE_COMPILE_OPTIONS "${XKB_DEFINITIONS}"
+ INTERFACE_INCLUDE_DIRECTORIES "${XKB_INCLUDE_DIR}"
+ )
+ endif()
+
+else()
+ message(STATUS "FindXKB.cmake cannot find XKB on Windows systems.")
+ set(XKB_FOUND FALSE)
+endif()
+
+include(FeatureSummary)
+set_package_properties(XKB PROPERTIES
+ URL "http://xkbcommon.org"
+ DESCRIPTION "XKB API common to servers and clients."
+)
diff --git a/cmake/3rdparty/kwin/Findgbm.cmake b/cmake/3rdparty/kwin/Findgbm.cmake
new file mode 100644
index 0000000000..6dfc895daa
--- /dev/null
+++ b/cmake/3rdparty/kwin/Findgbm.cmake
@@ -0,0 +1,125 @@
+#.rst:
+# Findgbm
+# -------
+#
+# Try to find gbm on a Unix system.
+#
+# This will define the following variables:
+#
+# ``gbm_FOUND``
+# True if (the requested version of) gbm is available
+# ``gbm_VERSION``
+# The version of gbm
+# ``gbm_LIBRARIES``
+# This can be passed to target_link_libraries() instead of the ``gbm::gbm``
+# target
+# ``gbm_INCLUDE_DIRS``
+# This should be passed to target_include_directories() if the target is not
+# used for linking
+# ``gbm_DEFINITIONS``
+# This should be passed to target_compile_options() if the target is not
+# used for linking
+#
+# If ``gbm_FOUND`` is TRUE, it will also define the following imported target:
+#
+# ``gbm::gbm``
+# The gbm library
+#
+# In general we recommend using the imported target, as it is easier to use.
+# Bear in mind, however, that if the target is in the link interface of an
+# exported library, it must be made available by the package config file.
+
+#=============================================================================
+# Copyright 2014 Alex Merry <alex.merry@kde.org>
+# Copyright 2014 Martin Gräßlin <mgraesslin@kde.org>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# 1. Redistributions of source code must retain the copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The name of the author may not be used to endorse or promote products
+# derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#=============================================================================
+
+if(CMAKE_VERSION VERSION_LESS 2.8.12)
+ message(FATAL_ERROR "CMake 2.8.12 is required by Findgbm.cmake")
+endif()
+if(CMAKE_MINIMUM_REQUIRED_VERSION VERSION_LESS 2.8.12)
+ message(AUTHOR_WARNING "Your project should require at least CMake 2.8.12 to use Findgbm.cmake")
+endif()
+
+if(NOT WIN32)
+ # Use pkg-config to get the directories and then use these values
+ # in the FIND_PATH() and FIND_LIBRARY() calls
+ find_package(PkgConfig)
+ pkg_check_modules(PKG_gbm QUIET gbm)
+
+ set(gbm_DEFINITIONS ${PKG_gbm_CFLAGS_OTHER})
+ set(gbm_VERSION ${PKG_gbm_VERSION})
+
+ find_path(gbm_INCLUDE_DIR
+ NAMES
+ gbm.h
+ HINTS
+ ${PKG_gbm_INCLUDE_DIRS}
+ )
+ find_library(gbm_LIBRARY
+ NAMES
+ gbm
+ HINTS
+ ${PKG_gbm_LIBRARY_DIRS}
+ )
+
+ include(FindPackageHandleStandardArgs)
+ find_package_handle_standard_args(gbm
+ FOUND_VAR
+ gbm_FOUND
+ REQUIRED_VARS
+ gbm_LIBRARY
+ gbm_INCLUDE_DIR
+ VERSION_VAR
+ gbm_VERSION
+ )
+
+ if(gbm_FOUND AND NOT TARGET gbm::gbm)
+ add_library(gbm::gbm UNKNOWN IMPORTED)
+ set_target_properties(gbm::gbm PROPERTIES
+ IMPORTED_LOCATION "${gbm_LIBRARY}"
+ INTERFACE_COMPILE_OPTIONS "${gbm_DEFINITIONS}"
+ INTERFACE_INCLUDE_DIRECTORIES "${gbm_INCLUDE_DIR}"
+ )
+ endif()
+
+ mark_as_advanced(gbm_LIBRARY gbm_INCLUDE_DIR)
+
+ # compatibility variables
+ set(gbm_LIBRARIES ${gbm_LIBRARY})
+ set(gbm_INCLUDE_DIRS ${gbm_INCLUDE_DIR})
+ set(gbm_VERSION_STRING ${gbm_VERSION})
+
+else()
+ message(STATUS "Findgbm.cmake cannot find gbm on Windows systems.")
+ set(gbm_FOUND FALSE)
+endif()
+
+include(FeatureSummary)
+set_package_properties(gbm PROPERTIES
+ URL "http://www.mesa3d.org"
+ DESCRIPTION "Mesa gbm library."
+)
diff --git a/cmake/3rdparty/kwin/qt_attribution.json b/cmake/3rdparty/kwin/qt_attribution.json
new file mode 100644
index 0000000000..5c22641132
--- /dev/null
+++ b/cmake/3rdparty/kwin/qt_attribution.json
@@ -0,0 +1,17 @@
+{
+ "Id": "kwin",
+ "Name": "KWin",
+ "QDocModule": "qtcore",
+ "QtUsage": "Used as part of the build system.",
+
+ "Description": "Additional CMake modules for graphics system dependencies.",
+ "Homepage": "https://www.kde.org/",
+ "Version": "5.13.4",
+
+ "License": "BSD-3-Clause",
+ "LicenseId": "BSD 3-Clause License",
+ "LicenseFile": "COPYING-CMAKE-SCRIPTS",
+ "Copyright": "Copyright 2014 Alex Merry <alex.merry@kde.org>
+Copyright 2014 Martin Gräßlin <mgraesslin@kde.org>,
+Copyright (c) 2006,2007 Laurent Montel, <montel@kde.org>"
+}
diff --git a/cmake/3rdpartyConfig.cmake.in b/cmake/3rdpartyConfig.cmake.in
new file mode 100644
index 0000000000..6af3792333
--- /dev/null
+++ b/cmake/3rdpartyConfig.cmake.in
@@ -0,0 +1,15 @@
+@PACKAGE_INIT@
+
+get_filename_component(_import_prefix "${CMAKE_CURRENT_LIST_FILE}" PATH)
+get_filename_component(_import_prefix "${_import_prefix}" REALPATH)
+
+set(old_CMAKE_MODULE_PATH "${CMAKE_MODULE_PATH}")
+set(CMAKE_MODULE_PATH "${_import_prefix}" ${CMAKE_MODULE_PATH} )
+
+@3RDPARTY_ADDITIONAL_SETUP_CODE@
+
+set(CMAKE_MODULE_PATH "${old_CMAKE_MODULE_PATH}")
+
+if (NOT QT_NO_CREATE_TARGETS)
+ include("${CMAKE_CURRENT_LIST_DIR}/@target@Targets.cmake")
+endif()
diff --git a/cmake/FindATSPI2.cmake b/cmake/FindATSPI2.cmake
new file mode 100644
index 0000000000..ca0045635b
--- /dev/null
+++ b/cmake/FindATSPI2.cmake
@@ -0,0 +1,7 @@
+include(FindPkgConfig)
+
+pkg_check_modules(ATSPI2 atspi-2 IMPORTED_TARGET)
+
+if (NOT TARGET PkgConfig::ATSPI2)
+ set(ATSPI2_FOUND 0)
+endif()
diff --git a/cmake/FindAtomic.cmake b/cmake/FindAtomic.cmake
new file mode 100644
index 0000000000..91cee62046
--- /dev/null
+++ b/cmake/FindAtomic.cmake
@@ -0,0 +1,44 @@
+# We can't create the same interface imported target multiple times, CMake will complain if we do
+# that. This can happen if the find_package call is done in multiple different subdirectories.
+if(TARGET Atomic)
+ set(Atomic_FOUND ON)
+ return()
+endif()
+
+include(CheckCXXSourceCompiles)
+
+set (atomic_test_sources "#include <atomic>
+#include <cstdint>
+
+void test(volatile std::atomic<std::int64_t> &a)
+{
+ std::int64_t v = a.load(std::memory_order_acquire);
+ while (!a.compare_exchange_strong(v, v + 1,
+ std::memory_order_acq_rel,
+ std::memory_order_acquire)) {
+ v = a.exchange(v - 1);
+ }
+ a.store(v + 1, std::memory_order_release);
+}
+
+int main(int, char **)
+{
+ void *ptr = (void*)0xffffffc0; // any random pointer
+ test(*reinterpret_cast<std::atomic<std::int64_t> *>(ptr));
+ return 0;
+}")
+
+check_cxx_source_compiles("${atomic_test_sources}" HAVE_STDATOMIC)
+if(NOT HAVE_STDATOMIC)
+ set(_req_libraries "${CMAKE_REQUIRE_LIBRARIES}")
+ set(CMAKE_REQUIRE_LIBRARIES "atomic")
+ check_cxx_source_compiles("${atomic_test_sources}" HAVE_STDATOMIC_WITH_LIB)
+ set(CMAKE_REQUIRE_LIBRARIES "${_req_libraries}")
+endif()
+
+add_library(Atomic INTERFACE IMPORTED)
+if(HAVE_STDATOMIC_WITH_LIB)
+ target_link_libraries(Atomic INTERFACE atomic)
+endif()
+
+set(Atomic_FOUND 1)
diff --git a/cmake/FindCups.cmake b/cmake/FindCups.cmake
new file mode 100644
index 0000000000..7a78100aae
--- /dev/null
+++ b/cmake/FindCups.cmake
@@ -0,0 +1,98 @@
+# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
+# file Copyright.txt or https://cmake.org/licensing for details.
+
+#[=======================================================================[.rst:
+FindCups
+--------
+
+Find the CUPS printing system.
+
+Set CUPS_REQUIRE_IPP_DELETE_ATTRIBUTE to TRUE if you need a version which
+features this function (i.e. at least 1.1.19)
+
+Imported targets
+^^^^^^^^^^^^^^^^
+
+This module defines :prop_tgt:`IMPORTED` target ``Cups::Cups``, if Cups has
+been found.
+
+Result variables
+^^^^^^^^^^^^^^^^
+
+This module will set the following variables in your project:
+
+``CUPS_FOUND``
+ true if CUPS headers and libraries were found
+``CUPS_INCLUDE_DIRS``
+ the directory containing the Cups headers
+``CUPS_LIBRARIES``
+ the libraries to link against to use CUPS.
+``CUPS_VERSION_STRING``
+ the version of CUPS found (since CMake 2.8.8)
+
+Cache variables
+^^^^^^^^^^^^^^^
+
+The following cache variables may also be set:
+
+``CUPS_INCLUDE_DIR``
+ the directory containing the Cups headers
+#]=======================================================================]
+
+find_path(CUPS_INCLUDE_DIR cups/cups.h )
+
+find_library(CUPS_LIBRARIES NAMES cups )
+
+if (CUPS_INCLUDE_DIR AND CUPS_LIBRARIES AND CUPS_REQUIRE_IPP_DELETE_ATTRIBUTE)
+ include(${CMAKE_CURRENT_LIST_DIR}/CheckLibraryExists.cmake)
+ include(${CMAKE_CURRENT_LIST_DIR}/CMakePushCheckState.cmake)
+ cmake_push_check_state()
+ set(CMAKE_REQUIRED_QUIET ${Cups_FIND_QUIETLY})
+
+ # ippDeleteAttribute is new in cups-1.1.19 (and used by kdeprint)
+ CHECK_LIBRARY_EXISTS(cups ippDeleteAttribute "" CUPS_HAS_IPP_DELETE_ATTRIBUTE)
+ cmake_pop_check_state()
+endif ()
+
+if (CUPS_INCLUDE_DIR AND EXISTS "${CUPS_INCLUDE_DIR}/cups/cups.h")
+ file(STRINGS "${CUPS_INCLUDE_DIR}/cups/cups.h" cups_version_str
+ REGEX "^#[\t ]*define[\t ]+CUPS_VERSION_(MAJOR|MINOR|PATCH)[\t ]+[0-9]+$")
+
+ unset(CUPS_VERSION_STRING)
+ foreach(VPART MAJOR MINOR PATCH)
+ foreach(VLINE ${cups_version_str})
+ if(VLINE MATCHES "^#[\t ]*define[\t ]+CUPS_VERSION_${VPART}[\t ]+([0-9]+)$")
+ set(CUPS_VERSION_PART "${CMAKE_MATCH_1}")
+ if(CUPS_VERSION_STRING)
+ string(APPEND CUPS_VERSION_STRING ".${CUPS_VERSION_PART}")
+ else()
+ set(CUPS_VERSION_STRING "${CUPS_VERSION_PART}")
+ endif()
+ endif()
+ endforeach()
+ endforeach()
+endif ()
+
+include(FindPackageHandleStandardArgs)
+
+if (CUPS_REQUIRE_IPP_DELETE_ATTRIBUTE)
+ FIND_PACKAGE_HANDLE_STANDARD_ARGS(Cups
+ REQUIRED_VARS CUPS_LIBRARIES CUPS_INCLUDE_DIR CUPS_HAS_IPP_DELETE_ATTRIBUTE
+ VERSION_VAR CUPS_VERSION_STRING)
+else ()
+ FIND_PACKAGE_HANDLE_STANDARD_ARGS(Cups
+ REQUIRED_VARS CUPS_LIBRARIES CUPS_INCLUDE_DIR
+ VERSION_VAR CUPS_VERSION_STRING)
+endif ()
+
+mark_as_advanced(CUPS_INCLUDE_DIR CUPS_LIBRARIES)
+
+if (CUPS_FOUND)
+ set(CUPS_INCLUDE_DIRS "${CUPS_INCLUDE_DIR}")
+ if (NOT TARGET Cups::Cups)
+ add_library(Cups::Cups INTERFACE IMPORTED)
+ set_target_properties(Cups::Cups PROPERTIES
+ INTERFACE_LINK_LIBRARIES "${CUPS_LIBRARIES}"
+ INTERFACE_INCLUDE_DIRECTORIES "${CUPS_INCLUDE_DIR}")
+ endif ()
+endif ()
diff --git a/cmake/FindDB2.cmake b/cmake/FindDB2.cmake
new file mode 100644
index 0000000000..59eadab7d5
--- /dev/null
+++ b/cmake/FindDB2.cmake
@@ -0,0 +1,59 @@
+#.rst:
+# FindDB2
+# ---------
+#
+# Try to locate the db2 client library.
+# If found, this will define the following variables:
+#
+# ``DB2_FOUND``
+# True if the db2 library is available
+# ``DB2_INCLUDE_DIRS``
+# The db2 include directories
+# ``DB2_LIBRARIES``
+# The db2 libraries for linking
+#
+# If ``DB2_FOUND`` is TRUE, it will also define the following
+# imported target:
+#
+# ``DB2::DB2``
+# The db2 client library
+
+if (NOT DEFINED DB2_INCLUDE_DIR)
+ find_path(DB2_INCLUDE_DIRS
+ NAMES sqlcli1.h
+ HINTS ENV DB2_HOME
+ PATH_SUFFIXES include)
+else()
+ find_path(DB2_INCLUDE_DIRS
+ NAMES sqlcli1.h
+ HINTS ${DB2_INCLUDE_DIR})
+endif()
+
+if (NOT DEFINED DB2_LIBRARY_DIR)
+ find_library(DB2_LIBRARIES
+ NAMES db2
+ HINTS ENV DB2LIB)
+else()
+ find_library(DB2_LIBRARIES
+ NAMES db2
+ HINTS ${DB2_LIBRARY_DIR})
+endif()
+
+if (NOT DB2_INCLUDE_DIRS STREQUAL "DB2_INCLUDE_DIRS-NOTFOUND" AND NOT DB2_LIBRARIES STREQUAL "DB2_LIBRARIES-NOTFOUND")
+ set(DB2_FOUND ON)
+endif()
+
+if(DB2_FOUND AND NOT TARGET DB2::DB2)
+ add_library(DB2::DB2 UNKNOWN IMPORTED)
+ set_target_properties(DB2::DB2 PROPERTIES
+ IMPORTED_LOCATION "${DB2_LIBRARIES}"
+ INTERFACE_INCLUDE_DIRECTORIES "${DB2_INCLUDE_DIRS}")
+endif()
+
+mark_as_advanced(DB2_INCLUDE_DIRS DB2_LIBRARIES)
+
+include(FeatureSummary)
+set_package_properties(DB2 PROPERTIES
+ URL "https://www.ibm.com"
+ DESCRIPTION "IBM DB2 client library")
+
diff --git a/cmake/FindDirectFB.cmake b/cmake/FindDirectFB.cmake
new file mode 100644
index 0000000000..4446018587
--- /dev/null
+++ b/cmake/FindDirectFB.cmake
@@ -0,0 +1,7 @@
+find_package(PkgConfig)
+
+pkg_check_modules(DirectFB directfb IMPORTED_TARGET)
+
+if (NOT TARGET PkgConfig::DirectFB)
+ set(DirectFB_FOUND 0)
+endif()
diff --git a/cmake/FindGLESv2.cmake b/cmake/FindGLESv2.cmake
new file mode 100644
index 0000000000..49e757ef55
--- /dev/null
+++ b/cmake/FindGLESv2.cmake
@@ -0,0 +1,72 @@
+include(CheckCXXSourceCompiles)
+
+# No library linkage is necessary to use GLESv2 with Emscripten. The headers are also
+# system headers, so we don't need to search for them.
+if(EMSCRIPTEN)
+ set(HAVE_GLESv2 ON)
+else()
+ find_library(GLESv2_LIBRARY NAMES GLESv2 OpenGLES)
+ find_path(GLESv2_INCLUDE_DIR NAMES "GLES2/gl2.h" "OpenGLES/ES2/gl.h" DOC "The OpenGLES 2 include path")
+ set(_libraries "${CMAKE_REQUIRED_LIBRARIES}")
+ list(APPEND CMAKE_REQUIRED_LIBRARIES "${GLESv2_LIBRARY}")
+ set(_includes "${CMAKE_REQUIRED_INCLUDES}")
+ list(APPEND CMAKE_REQUIRED_INCLUDES "${GLESv2_INCLUDE_DIR}")
+
+ check_cxx_source_compiles("
+#ifdef __APPLE__
+# include <OpenGLES/ES2/gl.h>
+#else
+# define GL_GLEXT_PROTOTYPES
+# include <GLES2/gl2.h>
+#endif
+
+int main(int argc, char *argv[]) {
+ glUniform1f(1, GLfloat(1.0));
+ glClear(GL_COLOR_BUFFER_BIT);
+}" HAVE_GLESv2)
+
+ set(CMAKE_REQUIRED_LIBRARY "${_libraries}")
+ unset(_libraries)
+ set(CMAKE_REQUIRED_INCLUDES "${_includes}")
+ unset(_includes)
+ set(package_args GLESv2_INCLUDE_DIR GLESv2_LIBRARY HAVE_GLESv2)
+endif()
+
+# Framework handling partially inspired by FindGLUT.cmake.
+if(GLESv2_LIBRARY MATCHES "/([^/]+)\\.framework$")
+ # TODO: Might need to handle non .tbd suffixes, but didn't find an
+ # example like that.
+ # TODO: Might need to handle INTERFACE_INCLUDE_DIRECTORIES differently.
+ set(_library_imported_location "${GLESv2_LIBRARY}/${CMAKE_MATCH_1}.tbd")
+ if(NOT EXISTS "${_library_imported_location}")
+ set(_library_imported_location "")
+ endif()
+else()
+ set(_library_imported_location "${GLESv2_LIBRARY}")
+endif()
+set(GLESv2_LIBRARY "${_library_imported_location}")
+
+list(APPEND package_args HAVE_GLESv2)
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(GLESv2 DEFAULT_MSG ${package_args})
+
+mark_as_advanced(${package_args})
+
+if(GLESv2_FOUND AND NOT TARGET GLESv2::GLESv2)
+ if(EMSCRIPTEN OR APPLE_UIKIT)
+ add_library(GLESv2::GLESv2 INTERFACE IMPORTED)
+ if(APPLE_UIKIT)
+ # For simulator_and_device builds we can't specify the full library path, because
+ # it's specific to either the device or the simulator. Resort to passing a link
+ # flag instead.
+ set_target_properties(GLESv2::GLESv2 PROPERTIES
+ INTERFACE_LINK_LIBRARIES "-framework OpenGLES")
+ endif()
+ else()
+ add_library(GLESv2::GLESv2 UNKNOWN IMPORTED)
+ set_target_properties(GLESv2::GLESv2 PROPERTIES
+ IMPORTED_LOCATION "${GLESv2_LIBRARY}"
+ INTERFACE_INCLUDE_DIRECTORIES "${GLESv2_INCLUDE_DIR}")
+ endif()
+endif()
diff --git a/cmake/FindGSSAPI.cmake b/cmake/FindGSSAPI.cmake
new file mode 100644
index 0000000000..6f22929b6c
--- /dev/null
+++ b/cmake/FindGSSAPI.cmake
@@ -0,0 +1,39 @@
+find_package(PkgConfig)
+pkg_check_modules(PC_GSSAPI QUIET krb5-gssapi)
+
+find_path(GSSAPI_INCLUDE_DIRS
+ NAMES gssapi/gssapi.h
+ HINTS ${PC_GSSAPI_INCLUDEDIR}
+ PATH_SUFFIXES gssapi)
+
+find_library(GSSAPI_LIBRARIES
+ NAMES
+ GSS # framework
+ gssapi_krb5
+ HINTS ${PC_GSSAPILIBDIR}
+)
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(GSSAPI DEFAULT_MSG GSSAPI_LIBRARIES GSSAPI_INCLUDE_DIRS)
+
+if(GSSAPI_FOUND AND NOT TARGET GSSAPI::GSSAPI)
+ if(GSSAPI_LIBRARIES MATCHES "/([^/]+)\\.framework$")
+ add_library(GSSAPI::GSSAPI INTERFACE IMPORTED)
+ set_target_properties(GSSAPI::GSSAPI PROPERTIES
+ INTERFACE_LINK_LIBRARIES "${GSSAPI_LIBRARIES}")
+ else()
+ add_library(GSSAPI::GSSAPI UNKNOWN IMPORTED)
+ set_target_properties(GSSAPI::GSSAPI PROPERTIES
+ IMPORTED_LOCATION "${GSSAPI_LIBRARIES}")
+ endif()
+
+ set_target_properties(GSSAPI::GSSAPI PROPERTIES
+ INTERFACE_INCLUDE_DIRECTORIES "${GSSAPI_INCLUDE_DIRS}")
+endif()
+
+mark_as_advanced(GSSAPI_INCLUDE_DIRS GSSAPI_LIBRARIES)
+
+include(FeatureSummary)
+set_package_properties(GSSAPI PROPERTIES
+ DESCRIPTION "Generic Security Services Application Program Interface")
+
diff --git a/cmake/FindGTK3.cmake b/cmake/FindGTK3.cmake
new file mode 100644
index 0000000000..9423eb4b9b
--- /dev/null
+++ b/cmake/FindGTK3.cmake
@@ -0,0 +1,7 @@
+include(FindPkgConfig)
+
+pkg_check_modules(GTK3 "gtk+-3.0 >= 3.6" IMPORTED_TARGET)
+
+if (NOT TARGET PkgConfig::GTK3)
+ set(GTK3_FOUND 0)
+endif()
diff --git a/cmake/FindLibproxy.cmake b/cmake/FindLibproxy.cmake
new file mode 100644
index 0000000000..95d86d1617
--- /dev/null
+++ b/cmake/FindLibproxy.cmake
@@ -0,0 +1,7 @@
+find_package(PkgConfig)
+
+pkg_check_modules(Libproxy libproxy-1.0 IMPORTED_TARGET)
+
+if (NOT TARGET PkgConfig::Libproxy)
+ set(Libproxy_FOUND 0)
+endif()
diff --git a/cmake/FindLibsystemd.cmake b/cmake/FindLibsystemd.cmake
new file mode 100644
index 0000000000..9b480700f9
--- /dev/null
+++ b/cmake/FindLibsystemd.cmake
@@ -0,0 +1,7 @@
+find_package(PkgConfig)
+
+pkg_check_modules(Libsystemd libsystemd IMPORTED_TARGET)
+
+if (NOT TARGET PkgConfig::Libsystemd)
+ set(Libsystemd_FOUND 0)
+endif()
diff --git a/cmake/FindLibudev.cmake b/cmake/FindLibudev.cmake
new file mode 100644
index 0000000000..637c7c6d88
--- /dev/null
+++ b/cmake/FindLibudev.cmake
@@ -0,0 +1,7 @@
+find_package(PkgConfig)
+
+pkg_check_modules(Libudev libudev IMPORTED_TARGET)
+
+if (NOT TARGET PkgConfig::Libudev)
+ set(Libudev_FOUND 0)
+endif()
diff --git a/cmake/FindMtdev.cmake b/cmake/FindMtdev.cmake
new file mode 100644
index 0000000000..c852a77c1c
--- /dev/null
+++ b/cmake/FindMtdev.cmake
@@ -0,0 +1,7 @@
+find_package(PkgConfig)
+
+pkg_check_modules(Mtdev mtdev IMPORTED_TARGET)
+
+if (NOT TARGET PkgConfig::MtDev)
+ set(Mtdev_FOUND 0)
+endif()
diff --git a/cmake/FindMySQL.cmake b/cmake/FindMySQL.cmake
new file mode 100644
index 0000000000..0cc5cb6368
--- /dev/null
+++ b/cmake/FindMySQL.cmake
@@ -0,0 +1,50 @@
+#.rst:
+# FindMySQL
+# ---------
+#
+# Try to locate the mysql client library.
+# If found, this will define the following variables:
+#
+# ``MySQL_FOUND``
+# True if the mysql library is available
+# ``MySQL_INCLUDE_DIRS``
+# The mysql include directories
+# ``MySQL_LIBRARIES``
+# The mysql libraries for linking
+#
+# If ``MySQL_FOUND`` is TRUE, it will also define the following
+# imported target:
+#
+# ``MySQL::MySQL``
+# The mysql client library
+
+find_package(PkgConfig)
+pkg_check_modules(PC_MySQL QUIET mysqlclient)
+
+find_path(MySQL_INCLUDE_DIRS
+ NAMES mysql.h
+ HINTS ${PC_MySQL_INCLUDEDIR}
+ PATH_SUFFIXES mysql)
+
+find_library(MySQL_LIBRARIES
+ NAMES mysqlclient
+ HINTS ${PC_MySQL_LIBDIR}
+)
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(MySQL DEFAULT_MSG MySQL_LIBRARIES MySQL_INCLUDE_DIRS)
+
+if(MySQL_FOUND AND NOT TARGET MySQL::MySQL)
+ add_library(MySQL::MySQL UNKNOWN IMPORTED)
+ set_target_properties(MySQL::MySQL PROPERTIES
+ IMPORTED_LOCATION "${MySQL_LIBRARIES}"
+ INTERFACE_INCLUDE_DIRECTORIES "${MySQL_INCLUDE_DIRS}")
+endif()
+
+mark_as_advanced(MySQL_INCLUDE_DIRS MySQL_LIBRARIES)
+
+include(FeatureSummary)
+set_package_properties(MySQL PROPERTIES
+ URL "https://www.mysql.com"
+ DESCRIPTION "MySQL client library")
+
diff --git a/cmake/FindOracle.cmake b/cmake/FindOracle.cmake
new file mode 100644
index 0000000000..58e787e362
--- /dev/null
+++ b/cmake/FindOracle.cmake
@@ -0,0 +1,48 @@
+#.rst:
+# FindOracle
+# ---------
+#
+# Try to locate the oracle client library.
+# If found, this will define the following variables:
+#
+# ``Oracle_FOUND``
+# True if the oracle library is available
+# ``Oracle_INCLUDE_DIRS``
+# The oracle include directories
+# ``Oracle_LIBRARIES``
+# The oracle libraries for linking
+#
+# If ``Oracle_FOUND`` is TRUE, it will also define the following
+# imported target:
+#
+# ``Oracle::Oracle``
+# The oracle instant client library
+
+find_path(Oracle_INCLUDE_DIRS
+ NAMES oci.h
+ HINTS ${Oracle_INCLUDE_DIR})
+
+set(ORACLE_OCI_NAMES clntsh ociei oraociei12)
+
+find_library(Oracle_LIBRARIES
+ NAMES NAMES ${ORACLE_OCI_NAMES}
+ HINTS ${Oracle_LIBRARY_DIR})
+
+if (NOT Oracle_INCLUDE_DIRS STREQUAL "Oracle_INCLUDE_DIRS-NOTFOUND" AND NOT Oracle_LIBRARIES STREQUAL "Oracle_LIBRARIES-NOTFOUND")
+ set(Oracle_FOUND ON)
+endif()
+
+if(Oracle_FOUND AND NOT TARGET Oracle::OCI)
+ add_library(Oracle::OCI UNKNOWN IMPORTED)
+ set_target_properties(Oracle::OCI PROPERTIES
+ IMPORTED_LOCATION "${Oracle_LIBRARIES}"
+ INTERFACE_INCLUDE_DIRECTORIES "${Oracle_INCLUDE_DIRS}")
+endif()
+
+mark_as_advanced(Oracle_INCLUDE_DIRS Oracle_LIBRARIES)
+
+include(FeatureSummary)
+set_package_properties(Oracle PROPERTIES
+ URL "https://www.oracle.com"
+ DESCRIPTION "Oracle client library")
+
diff --git a/cmake/FindPPS.cmake b/cmake/FindPPS.cmake
new file mode 100644
index 0000000000..c3360fa82c
--- /dev/null
+++ b/cmake/FindPPS.cmake
@@ -0,0 +1,19 @@
+# Find the PPS library
+
+# Will make the target PPS::PPS available when found.
+
+find_library(PPS_LIBRARY NAMES "pps")
+find_path(PPS_INCLUDE_DIR NAMES "sys/pps.h" DOC "The PPS Include path")
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(PPS DEFAULT_MSG PPS_INCLUDE_DIR PPS_LIBRARY)
+
+mark_as_advanced(PPS_INCLUDE_DIR PPS_LIBRARY)
+
+if(PPS_FOUND)
+ add_library(__PPS INTERFACE IMPORTED)
+ target_link_libraries(__PPS INTERFACE ${PPS_LIBRARY})
+ target_include_directories(__PPS INTERFACE ${PPS_INCLUDE_DIR})
+
+ add_library(PPS::PPS ALIAS __PPS)
+endif()
diff --git a/cmake/FindSlog2.cmake b/cmake/FindSlog2.cmake
new file mode 100644
index 0000000000..dfb6635a39
--- /dev/null
+++ b/cmake/FindSlog2.cmake
@@ -0,0 +1,19 @@
+# Find the Slog2 library
+
+# Will make the target Slog2::Slog2 available when found.
+
+find_library(Slog2_LIBRARY NAMES "slog2")
+find_path(Slog2_INCLUDE_DIR NAMES "sys/slog2.h" DOC "The Slog2 Include path")
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(Slog2 DEFAULT_MSG Slog2_INCLUDE_DIR Slog2_LIBRARY)
+
+mark_as_advanced(Slog2_INCLUDE_DIR Slog2_LIBRARY)
+
+if(Slog2_FOUND)
+ add_library(__Slog2 INTERFACE IMPORTED)
+ target_link_libraries(__Slog2 INTERFACE ${Slog2_LIBRARY})
+ target_include_directories(__Slog2 INTERFACE ${Slog2_INCLUDE_DIR})
+
+ add_library(Slog2::Slog2 ALIAS __Slog2)
+endif()
diff --git a/cmake/FindTslib.cmake b/cmake/FindTslib.cmake
new file mode 100644
index 0000000000..3c50116d0a
--- /dev/null
+++ b/cmake/FindTslib.cmake
@@ -0,0 +1,7 @@
+find_package(PkgConfig)
+
+pkg_check_modules(Tslib tslib IMPORTED_TARGET)
+
+if (NOT TARGET PkgConfig::Tslib)
+ set(Tslib_FOUND 0)
+endif()
diff --git a/cmake/FindWrapDBus1.cmake b/cmake/FindWrapDBus1.cmake
new file mode 100644
index 0000000000..c2668d6cc8
--- /dev/null
+++ b/cmake/FindWrapDBus1.cmake
@@ -0,0 +1,35 @@
+# DBus1 is buggy and breaks PKG_CONFIG environment.
+# Work around that:-/
+# See https://gitlab.freedesktop.org/dbus/dbus/issues/267 for more information
+
+if(DEFINED ENV{PKG_CONFIG_DIR})
+ set(__qt_dbus_pcd "$ENV{PKG_CONFIG_DIR}")
+endif()
+if(DEFINED ENV{PKG_CONFIG_PATH})
+ set(__qt_dbus_pcp "$ENV{PKG_CONFIG_PATH}")
+endif()
+if(DEFINED ENV{PKG_CONFIG_LIBDIR})
+ set(__qt_dbus_pcl "$ENV{PKG_CONFIG_LIBDIR}")
+endif()
+
+find_package(DBus1)
+
+if(DEFINED __qt_dbus_pcd)
+ set(ENV{PKG_CONFIG_DIR} "${__qt_dbus_pcd}")
+else()
+ unset(ENV{PKG_CONFIG_DIR})
+endif()
+if(DEFINED __qt_dbus_pcp)
+ set(ENV{PKG_CONFIG_PATH} "${__qt_dbus_pcp}")
+else()
+ unset(ENV{PKG_CONFIG_PATH})
+endif()
+if(DEFINED __qt_dbus_pcl)
+ set(ENV{PKG_CONFIG_LIBDIR} "${__qt_dbus_pcl}")
+else()
+ unset(ENV{PKG_CONFIG_LIBDIR})
+endif()
+
+if(DBus1_FOUND)
+ set(WrapDBus1_FOUND 1)
+endif()
diff --git a/cmake/FindWrapDoubleConversion.cmake b/cmake/FindWrapDoubleConversion.cmake
new file mode 100644
index 0000000000..9c804a3eec
--- /dev/null
+++ b/cmake/FindWrapDoubleConversion.cmake
@@ -0,0 +1,61 @@
+# We can't create the same interface imported target multiple times, CMake will complain if we do
+# that. This can happen if the find_package call is done in multiple different subdirectories.
+if(TARGET WrapDoubleConversion::WrapDoubleConversion)
+ set(WrapDoubleConversion_FOUND ON)
+ return()
+endif()
+
+add_library(WrapDoubleConversion::WrapDoubleConversion INTERFACE IMPORTED)
+
+find_package(double-conversion)
+if (double-conversion_FOUND)
+ include(FeatureSummary)
+ set_package_properties(double-conversion PROPERTIES TYPE REQUIRED)
+ target_link_libraries(WrapDoubleConversion::WrapDoubleConversion
+ INTERFACE double-conversion::double-conversion)
+ set(WrapDoubleConversion_FOUND 1)
+ return()
+endif()
+
+include(CheckCXXSourceCompiles)
+
+check_cxx_source_compiles("
+#include <stdio.h>
+#include <locale.h>
+
+int main(int argc, char *argv[]) {
+ _locale_t invalidLocale = NULL;
+ double a = 3.14;
+ const char *format = \"invalid format\";
+ _sscanf_l(argv[0], invalidLocale, format, &a, &argc);
+ _snprintf_l(argv[0], 1, invalidLocale, format, a);
+}" HAVE__SPRINTF_L)
+
+check_cxx_source_compiles("
+#include <stdio.h>
+#include <xlocale.h>
+
+int main(int argc, char *argv[]) {
+ locale_t invalidLocale = NULL;
+ double a = 3.14;
+ const char *format = \"invalid format\";
+ snprintf_l(argv[0], 1, invalidLocale, format, a);
+ sscanf_l(argv[0], invalidLocale, format, &a, &argc);
+ return 0;
+}" HAVE_SPRINTF_L)
+
+# In a static build, we need to find the package to bring the target into scope.
+find_package(QtDoubleConversion QUIET)
+
+if (HAVE__SPRINTF_L OR HAVE_SPRINTF_L)
+ target_compile_definitions(WrapDoubleConversion::WrapDoubleConversion
+ INTERFACE QT_NO_DOUBLECONVERSION)
+ set(WrapDoubleConversion_FOUND 1)
+elseif(TARGET QtDoubleConversion)
+ # If a Config package wasn't found, and the C++ library doesn't contain the necessary functions,
+ # use the library bundled with Qt.
+ target_link_libraries(WrapDoubleConversion::WrapDoubleConversion INTERFACE QtDoubleConversion)
+ set(WrapDoubleConversion_FOUND 1)
+else()
+ set(WrapDoubleConversion_FOUND 0)
+endif()
diff --git a/cmake/FindWrapFreetype.cmake b/cmake/FindWrapFreetype.cmake
new file mode 100644
index 0000000000..ec7d2a8d24
--- /dev/null
+++ b/cmake/FindWrapFreetype.cmake
@@ -0,0 +1,33 @@
+# We can't create the same interface imported target multiple times, CMake will complain if we do
+# that. This can happen if the find_package call is done in multiple different subdirectories.
+if(TARGET WrapFreetype::WrapFreetype)
+ set(WrapFreetype_FOUND ON)
+ return()
+endif()
+
+set(WrapFreetype_FOUND OFF)
+
+# Hunter has the package named freetype, but exports the Freetype::Freetype target as upstream
+# First try the CONFIG package, and afterwards the MODULE if not found
+
+find_package(Freetype CONFIG NAMES Freetype freetype QUIET)
+if(NOT Freetype_FOUND)
+ find_package(Freetype MODULE)
+endif()
+
+if(Freetype_FOUND)
+ # vcpkg defines a lower case target name, while upstream Find module defines a prefixed
+ # upper case name.
+ set(potential_target_names Freetype::Freetype freetype)
+ foreach(target_name ${potential_target_names})
+ if(TARGET ${target_name})
+ set(WrapFreetype_FOUND ON)
+ set(final_target_name ${target_name})
+
+ add_library(WrapFreetype::WrapFreetype INTERFACE IMPORTED)
+ target_link_libraries(WrapFreetype::WrapFreetype INTERFACE ${final_target_name})
+
+ break()
+ endif()
+ endforeach()
+endif()
diff --git a/cmake/FindWrapHarfbuzz.cmake b/cmake/FindWrapHarfbuzz.cmake
new file mode 100644
index 0000000000..f7845b28bd
--- /dev/null
+++ b/cmake/FindWrapHarfbuzz.cmake
@@ -0,0 +1,45 @@
+# We can't create the same interface imported target multiple times, CMake will complain if we do
+# that. This can happen if the find_package call is done in multiple different subdirectories.
+if(TARGET WrapHarfbuzz::WrapHarfbuzz)
+ set(WrapHarfbuzz_FOUND ON)
+ return()
+endif()
+
+set(WrapHarfbuzz_FOUND OFF)
+
+find_package(harfbuzz)
+
+# Gentoo has some buggy version of a harfbuzz Config file. Check if include paths are valid.
+set(__harfbuzz_target_name "harfbuzz::harfbuzz")
+if(harfbuzz_FOUND AND TARGET "${__harfbuzz_target_name}")
+ get_property(__harfbuzz_include_paths TARGET "${__harfbuzz_target_name}"
+ PROPERTY INTERFACE_INCLUDE_DIRECTORIES)
+ foreach(__harfbuzz_include_dir ${__harfbuzz_include_paths})
+ if(NOT EXISTS "${__harfbuzz_include_dir}")
+ # Must be the broken Gentoo harfbuzzConfig.cmake file. Try to use pkg-config instead.
+ set(__harfbuzz_broken_config_file TRUE)
+ break()
+ endif()
+ endforeach()
+endif()
+
+if(__harfbuzz_broken_config_file)
+ find_package(PkgConfig)
+
+ pkg_check_modules(harfbuzz harfbuzz IMPORTED_TARGET)
+ set(__harfbuzz_target_name "PkgConfig::harfbuzz")
+
+ if (NOT TARGET "${__harfbuzz_target_name}")
+ set(harfbuzz_FOUND 0)
+ endif()
+endif()
+
+if(TARGET "${__harfbuzz_target_name}")
+ set(WrapHarfbuzz_FOUND ON)
+
+ add_library(WrapHarfbuzz::WrapHarfbuzz INTERFACE IMPORTED)
+ target_link_libraries(WrapHarfbuzz::WrapHarfbuzz INTERFACE ${__harfbuzz_target_name})
+endif()
+unset(__harfbuzz_target_name)
+unset(__harfbuzz_include_dir)
+unset(__harfbuzz_broken_config_file)
diff --git a/cmake/FindWrapPCRE2.cmake b/cmake/FindWrapPCRE2.cmake
new file mode 100644
index 0000000000..08f660bdfc
--- /dev/null
+++ b/cmake/FindWrapPCRE2.cmake
@@ -0,0 +1,23 @@
+if(TARGET WrapPCRE2::WrapPCRE2)
+ set(WrapPCRE2_FOUND TRUE)
+ return()
+endif()
+
+find_package(PCRE2 CONFIG QUIET)
+
+if(PCRE2_FOUND AND TARGET PCRE2::pcre2-16)
+ # Hunter case.
+ add_library(WrapPCRE2::WrapPCRE2 INTERFACE IMPORTED)
+ target_link_libraries(WrapPCRE2::WrapPCRE2 INTERFACE PCRE2::pcre2-16)
+ set(WrapPCRE2_FOUND TRUE)
+else()
+ find_library(PCRE2_LIBRARIES NAMES pcre2-16)
+ find_path(PCRE2_INCLUDE_DIRS pcre2.h)
+
+ if (PCRE2_LIBRARIES AND PCRE2_INCLUDE_DIRS)
+ add_library(WrapPCRE2::WrapPCRE2 INTERFACE IMPORTED)
+ target_link_libraries(WrapPCRE2::WrapPCRE2 INTERFACE ${PCRE2_LIBRARIES})
+ target_include_directories(WrapPCRE2::WrapPCRE2 INTERFACE ${PCRE2_INCLUDE_DIRS})
+ set(WrapPCRE2_FOUND TRUE)
+ endif()
+endif()
diff --git a/cmake/FindWrapRt.cmake b/cmake/FindWrapRt.cmake
new file mode 100644
index 0000000000..d14b922062
--- /dev/null
+++ b/cmake/FindWrapRt.cmake
@@ -0,0 +1,34 @@
+# We can't create the same interface imported target multiple times, CMake will complain if we do
+# that. This can happen if the find_package call is done in multiple different subdirectories.
+if(TARGET WrapRt)
+ set(WrapRt_FOUND ON)
+ return()
+endif()
+
+include(CheckCXXSourceCompiles)
+include(CMakePushCheckState)
+
+find_library(LIBRT rt)
+
+cmake_push_check_state()
+if(LIBRT_FOUND)
+ list(APPEND CMAKE_REQUIRED_LIBRARIES "${LIBRT}")
+endif()
+
+check_cxx_source_compiles("
+#include <unistd.h>
+#include <time.h>
+
+int main(int argc, char *argv[]) {
+ timespec ts; clock_gettime(CLOCK_REALTIME, &ts);
+}" HAVE_GETTIME)
+
+cmake_pop_check_state()
+
+add_library(WrapRt INTERFACE IMPORTED)
+if (LIBRT_FOUND)
+ target_link_libraries(WrapRt INTERFACE "${LIBRT}")
+endif()
+
+set(WrapRt_FOUND "${HAVE_GETTIME}")
+
diff --git a/cmake/FindXKB_COMMON_X11.cmake b/cmake/FindXKB_COMMON_X11.cmake
new file mode 100644
index 0000000000..61b4ba82e7
--- /dev/null
+++ b/cmake/FindXKB_COMMON_X11.cmake
@@ -0,0 +1,7 @@
+include(FindPkgConfig)
+
+pkg_check_modules(XKB_COMMON_X11 "xkbcommon-x11>=0.4.1" IMPORTED_TARGET)
+
+if (NOT TARGET PkgConfig::XKB_COMMON_X11)
+ set(XKB_COMMON_X11_FOUND 0)
+endif()
diff --git a/cmake/FindXRender.cmake b/cmake/FindXRender.cmake
new file mode 100644
index 0000000000..246a47e18c
--- /dev/null
+++ b/cmake/FindXRender.cmake
@@ -0,0 +1,11 @@
+include(FindPkgConfig)
+
+if(NOT TARGET PkgConfig::XRender)
+ pkg_check_modules(XRender xrender IMPORTED_TARGET)
+
+ if (NOT TARGET PkgConfig::XRender)
+ set(XRender_FOUND 0)
+ endif()
+else()
+ set(XRender_FOUND 1)
+endif()
diff --git a/cmake/FindZSTD.cmake b/cmake/FindZSTD.cmake
new file mode 100644
index 0000000000..90d667dc29
--- /dev/null
+++ b/cmake/FindZSTD.cmake
@@ -0,0 +1,50 @@
+#.rst:
+# FindZstd
+# ---------
+#
+# Try to locate the Zstd library.
+# If found, this will define the following variables:
+#
+# ``ZSTD_FOUND``
+# True if the zstd library is available
+# ``ZSTD_INCLUDE_DIRS``
+# The zstd include directories
+# ``ZSTD_LIBRARIES``
+# The zstd libraries for linking
+#
+# If ``ZSTD_FOUND`` is TRUE, it will also define the following
+# imported target:
+#
+# ``ZSTD::ZSTD``
+# The zstd library
+
+find_package(PkgConfig)
+pkg_check_modules(PC_ZSTD QUIET libzstd)
+
+find_path(ZSTD_INCLUDE_DIRS
+ NAMES zstd.h
+ HINTS ${PC_ZSTD_INCLUDEDIR}
+ PATH_SUFFIXES zstd)
+
+find_library(ZSTD_LIBRARIES
+ NAMES zstd zstd_static
+ HINTS ${PC_ZSTD_LIBDIR}
+)
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(ZSTD DEFAULT_MSG ZSTD_LIBRARIES ZSTD_INCLUDE_DIRS)
+
+if(ZSTD_FOUND AND NOT TARGET ZSTD::ZSTD)
+ add_library(ZSTD::ZSTD UNKNOWN IMPORTED)
+ set_target_properties(ZSTD::ZSTD PROPERTIES
+ IMPORTED_LOCATION "${ZSTD_LIBRARIES}"
+ INTERFACE_INCLUDE_DIRECTORIES "${ZSTD_INCLUDE_DIRS}")
+endif()
+
+mark_as_advanced(ZSTD_INCLUDE_DIRS ZSTD_LIBRARIES)
+
+include(FeatureSummary)
+set_package_properties(ZSTD PROPERTIES
+ URL "https://github.com/facebook/zstd"
+ DESCRIPTION "ZSTD compression library")
+
diff --git a/cmake/Finddouble-conversion.cmake b/cmake/Finddouble-conversion.cmake
new file mode 100644
index 0000000000..43d2076289
--- /dev/null
+++ b/cmake/Finddouble-conversion.cmake
@@ -0,0 +1,32 @@
+# Fallback find module for double-conversion
+# if double-conversion is built with CMake it'll install a config module, which we prefer
+# if it's built with Scons (their default), we search ourselves
+
+find_package(double-conversion CONFIG)
+if (double-conversion_FOUND)
+ if(TARGET double-conversion::double-conversion)
+ return()
+ endif()
+endif()
+
+find_path(DOUBLE_CONVERSION_INCLUDE_DIR
+ NAMES
+ double-conversion.h
+ PATH_SUFFIXES
+ double-conversion
+)
+find_library(DOUBLE_CONVERSION_LIBRARY NAMES double-conversion)
+
+include(FindPackageHandleStandardArgs)
+FIND_PACKAGE_HANDLE_STANDARD_ARGS(
+ double-conversion DEFAULT_MSG
+ DOUBLE_CONVERSION_LIBRARY DOUBLE_CONVERSION_INCLUDE_DIR)
+
+if(double-conversion_FOUND AND NOT TARGET double-conversion::double-conversion)
+ add_library(double-conversion::double-conversion UNKNOWN IMPORTED)
+ set_target_properties(double-conversion::double-conversion PROPERTIES
+ IMPORTED_LOCATION "${DOUBLE_CONVERSION_LIBRARY}"
+ INTERFACE_INCLUDE_DIRECTORIES "${DOUBLE_CONVERSION_INCLUDE_DIR}")
+endif()
+
+mark_as_advanced(DOUBLE_CONVERSION_INCLUDE_DIR DOUBLE_CONVERSION_LIBRARY)
diff --git a/cmake/ModuleDescription.json.in b/cmake/ModuleDescription.json.in
new file mode 100644
index 0000000000..e29f3f176d
--- /dev/null
+++ b/cmake/ModuleDescription.json.in
@@ -0,0 +1,11 @@
+{
+ "module_name": "${target}",
+ "version": "${CMAKE_PROJECT_VERSION}",
+ "built_with": {
+ "compiler_id": "${CMAKE_CXX_COMPILER_ID}",
+ "compiler_target": "${CMAKE_CXX_COMPILER_TARGET}",
+ "compiler_version": "${CMAKE_CXX_COMPILER_VERSION}",
+ "cross_compiled": ${cross_compilation},
+ "target_system": "${CMAKE_SYSTEM_NAME}"
+ }
+}
diff --git a/cmake/QtAutoDetect.cmake b/cmake/QtAutoDetect.cmake
new file mode 100644
index 0000000000..1823d1e572
--- /dev/null
+++ b/cmake/QtAutoDetect.cmake
@@ -0,0 +1,161 @@
+#
+# Collection of auto dection routines to improve the user eperience when
+# building Qt from source.
+#
+# Make sure to not run detection when building standalone tests, because the detection was already
+# done when initially configuring qtbase.
+
+function(qt_auto_detect_android)
+ if(DEFINED CMAKE_TOOLCHAIN_FILE AND NOT DEFINED QT_AUTODETECT_ANDROID
+ AND NOT QT_BUILD_STANDALONE_TESTS)
+
+ file(READ ${CMAKE_TOOLCHAIN_FILE} toolchain_file_content OFFSET 0 LIMIT 80)
+ string(FIND ${toolchain_file_content} "The Android Open Source Project" find_result REVERSE)
+ if (NOT ${find_result} EQUAL -1)
+ set(android_detected TRUE)
+ else()
+ set(android_detected FALSE)
+ endif()
+
+ if(android_detected)
+ message(STATUS "Android toolchain file detected, checking configuration defaults...")
+ if(NOT DEFINED ANDROID_NATIVE_API_LEVEL)
+ message(STATUS "ANDROID_NATIVE_API_LEVEL was not specified, using API level 21 as default")
+ set(ANDROID_NATIVE_API_LEVEL 21 CACHE STRING "")
+ endif()
+ if(NOT DEFINED ANDROID_STL)
+ set(ANDROID_STL "c++_shared" CACHE STRING "")
+ endif()
+ endif()
+ set(QT_AUTODETECT_ANDROID ${android_detected} CACHE STRING "")
+ elseif (QT_AUTODETECT_ANDROID)
+ message(STATUS "Android toolchain file detected")
+ endif()
+endfunction()
+
+function(qt_auto_detect_vpckg)
+ if(DEFINED ENV{VCPKG_ROOT} AND NOT QT_BUILD_STANDALONE_TESTS)
+ set(vcpkg_toolchain_file "$ENV{VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake")
+ get_filename_component(vcpkg_toolchain_file "${vcpkg_toolchain_file}" ABSOLUTE)
+
+ if(DEFINED CMAKE_TOOLCHAIN_FILE)
+ get_filename_component(supplied_toolchain_file "${CMAKE_TOOLCHAIN_FILE}" ABSOLUTE)
+ if(NOT supplied_toolchain_file STREQUAL vcpkg_toolchain_file)
+ set(VCPKG_CHAINLOAD_TOOLCHAIN_FILE "${CMAKE_TOOLCHAIN_FILE}" CACHE STRING "")
+ endif()
+ unset(supplied_toolchain_file)
+ endif()
+ set(CMAKE_TOOLCHAIN_FILE "${vcpkg_toolchain_file}" CACHE STRING "" FORCE)
+ message(STATUS "Using vcpkg from $ENV{VCPKG_ROOT}")
+ if(DEFINED ENV{VCPKG_DEFAULT_TRIPLET} AND NOT DEFINED VCPKG_TARGET_TRIPLET)
+ set(VCPKG_TARGET_TRIPLET "$ENV{VCPKG_DEFAULT_TRIPLET}" CACHE STRING "")
+ message(STATUS "Using vcpkg triplet ${VCPKG_TARGET_TRIPLET}")
+ endif()
+ unset(vcpkg_toolchain_file)
+ message(STATUS "CMAKE_TOOLCHAIN_FILE is: ${CMAKE_TOOLCHAIN_FILE}")
+ if(DEFINED VCPKG_CHAINLOAD_TOOLCHAIN_FILE)
+ message(STATUS "VCPKG_CHAINLOAD_TOOLCHAIN_FILE is: ${VCPKG_CHAINLOAD_TOOLCHAIN_FILE}")
+ endif()
+ endif()
+endfunction()
+
+function(qt_auto_detect_ios)
+ if(CMAKE_SYSTEM_NAME STREQUAL iOS
+ OR CMAKE_SYSTEM_NAME STREQUAL watchOS
+ OR CMAKE_SYSTEM_NAME STREQUAL tvOS)
+ message(STATUS "Using internal CMake ${CMAKE_SYSTEM_NAME} toolchain file.")
+
+ # The QT_UIKIT_SDK check simulates the input.sdk condition for simulator_and_device in
+ # configure.json.
+ # If the variable is explicitly provided, assume simulator_and_device to be off.
+ if(QT_UIKIT_SDK)
+ set(simulator_and_device OFF)
+ elseif(QT_FORCE_SIMULATOR_AND_DEVICE)
+ # TODO: Once we get simulator_and_device support in upstream CMake, only then allow
+ # usage of simulator_and_device without forcing.
+ set(simulator_and_device ON)
+ else()
+ # If QT_UIKIT_SDK is not provided, default to simulator.
+ set(simulator_and_device OFF)
+ set(QT_UIKIT_SDK "iphonesimulator" CACHE "STRING" "Chosen uikit SDK.")
+ endif()
+
+ message(STATUS "simulator_and_device set to: \"${simulator_and_device}\".")
+
+ # Choose relevant architectures.
+ # Using a non xcode generator requires explicit setting of the
+ # architectures, otherwise compilation fails with unknown defines.
+ if(CMAKE_SYSTEM_NAME STREQUAL iOS)
+ if(simulator_and_device)
+ set(osx_architectures "arm64;x86_64")
+ elseif(QT_UIKIT_SDK STREQUAL "iphoneos")
+ set(osx_architectures "arm64")
+ elseif(QT_UIKIT_SDK STREQUAL "iphonesimulator")
+ set(osx_architectures "x86_64")
+ else()
+ if(NOT DEFINED QT_UIKIT_SDK)
+ message(FATAL_ERROR "Please proviude a value for -DQT_UIKIT_SDK."
+ " Possible values: iphoneos, iphonesimulator.")
+ else()
+ message(FATAL_ERROR
+ "Unknown SDK argument given to QT_UIKIT_SDK: ${QT_UIKIT_SDK}.")
+ endif()
+ endif()
+ elseif(CMAKE_SYSTEM_NAME STREQUAL tvOS)
+ if(simulator_and_device)
+ set(osx_architectures "arm64;x86_64")
+ elseif(QT_UIKIT_SDK STREQUAL "appletvos")
+ set(osx_architectures "arm64")
+ elseif(QT_UIKIT_SDK STREQUAL "appletvsimulator")
+ set(osx_architectures "x86_64")
+ else()
+ if(NOT DEFINED QT_UIKIT_SDK)
+ message(FATAL_ERROR "Please proviude a value for -DQT_UIKIT_SDK."
+ " Possible values: appletvos, appletvsimulator.")
+ else()
+ message(FATAL_ERROR
+ "Unknown SDK argument given to QT_UIKIT_SDK: ${QT_UIKIT_SDK}.")
+ endif()
+ endif()
+ elseif(CMAKE_SYSTEM_NAME STREQUAL watchOS)
+ if(simulator_and_device)
+ set(osx_architectures "armv7k;i386")
+ elseif(QT_UIKIT_SDK STREQUAL "watchos")
+ set(osx_architectures "armv7k")
+ elseif(QT_UIKIT_SDK STREQUAL "watchsimulator")
+ set(osx_architectures "i386")
+ else()
+ if(NOT DEFINED QT_UIKIT_SDK)
+ message(FATAL_ERROR "Please proviude a value for -DQT_UIKIT_SDK."
+ " Possible values: watchos, watchsimulator.")
+ else()
+ message(FATAL_ERROR
+ "Unknown SDK argument given to QT_UIKIT_SDK: ${QT_UIKIT_SDK}.")
+ endif()
+ endif()
+ endif()
+
+ # For non simulator_and_device builds, we need to explicitly set the SYSROOT aka the sdk
+ # value.
+ if(QT_UIKIT_SDK)
+ set(CMAKE_OSX_SYSROOT "${QT_UIKIT_SDK}" CACHE STRING "")
+ endif()
+ message(STATUS "CMAKE_OSX_SYSROOT set to: \"${CMAKE_OSX_SYSROOT}\".")
+
+ message(STATUS "CMAKE_OSX_ARCHITECTURES set to: \"${osx_architectures}\".")
+ set(CMAKE_OSX_ARCHITECTURES "${osx_architectures}" CACHE STRING "")
+
+ if(NOT DEFINED BUILD_SHARED_LIBS)
+ set(BUILD_SHARED_LIBS OFF CACHE BOOL "Build Qt statically or dynamically" FORCE)
+ endif()
+
+ if(BUILD_SHARED_LIBS)
+ message(FATAL_ERROR
+ "Building Qt for ${CMAKE_SYSTEM_NAME} as shared libraries is not supported.")
+ endif()
+ endif()
+endfunction()
+
+qt_auto_detect_ios()
+qt_auto_detect_android()
+qt_auto_detect_vpckg()
diff --git a/cmake/QtBaseCMakeTesting.cmake b/cmake/QtBaseCMakeTesting.cmake
new file mode 100644
index 0000000000..662ac8f498
--- /dev/null
+++ b/cmake/QtBaseCMakeTesting.cmake
@@ -0,0 +1,9 @@
+## Test the cmake build system:
+option(BUILD_CMAKE_TESTING "Build tests for the Qt build system" OFF)
+mark_as_advanced(BUILD_CMAKE_TESTING)
+
+if(BUILD_CMAKE_TESTING)
+ add_subdirectory("${PROJECT_SOURCE_DIR}/cmake/tests")
+endif()
+
+
diff --git a/cmake/QtBaseConfigureTests.cmake b/cmake/QtBaseConfigureTests.cmake
new file mode 100644
index 0000000000..777adb7b5f
--- /dev/null
+++ b/cmake/QtBaseConfigureTests.cmake
@@ -0,0 +1,192 @@
+include(CheckCXXSourceCompiles)
+
+function(qt_run_config_test_architecture)
+ set(QT_BASE_CONFIGURE_TESTS_VARS_TO_EXPORT
+ "" CACHE INTERNAL "Test variables that should be exported" FORCE)
+
+ # Compile test to find the target architecture and sub-architectures.
+ set(flags "")
+ qt_get_platform_try_compile_vars(platform_try_compile_vars)
+ list(APPEND flags ${platform_try_compile_vars})
+
+ try_compile(
+ _arch_result
+ "${CMAKE_CURRENT_BINARY_DIR}/config.tests/arch"
+ "${CMAKE_CURRENT_SOURCE_DIR}/config.tests/arch"
+ arch
+ CMAKE_FLAGS ${flags}
+ )
+
+ if (NOT _arch_result)
+ message(FATAL_ERROR "Failed to compile architecture detection file.")
+ endif()
+
+ set(_arch_file_suffix "${CMAKE_EXECUTABLE_SUFFIX}")
+ # With emscripten the application entry point is a .js file (to be run with node for example),
+ # but the real "data" is in the .wasm file, so that's where we need to look for the ABI, etc.
+ # information.
+ if (EMSCRIPTEN)
+ set(_arch_file_suffix ".wasm")
+ endif()
+ set(_arch_file
+ "${CMAKE_CURRENT_BINARY_DIR}/config.tests/arch/architecture_test${_arch_file_suffix}")
+ if (NOT EXISTS "${_arch_file}")
+ message(FATAL_ERROR
+ "Failed to find compiled architecture detection executable at ${_arch_file}.")
+ endif()
+ message(STATUS "Extracting architecture info from ${_arch_file}.")
+
+ file(STRINGS "${_arch_file}" _arch_lines LENGTH_MINIMUM 16 LENGTH_MAXIMUM 1024 ENCODING UTF-8)
+
+ foreach (_line ${_arch_lines})
+ string(LENGTH "${_line}" lineLength)
+ string(FIND "${_line}" "==Qt=magic=Qt== Architecture:" _pos)
+ if (_pos GREATER -1)
+ math(EXPR _pos "${_pos}+29")
+ string(SUBSTRING "${_line}" ${_pos} -1 _architecture)
+ endif()
+ string(FIND "${_line}" "==Qt=magic=Qt== Sub-architecture:" _pos)
+ if (_pos GREATER -1 AND ${lineLength} GREATER 33)
+ math(EXPR _pos "${_pos}+34")
+ string(SUBSTRING "${_line}" ${_pos} -1 _sub_architecture)
+ string(REPLACE " " ";" _sub_architecture "${_sub_architecture}")
+ endif()
+ string(FIND "${_line}" "==Qt=magic=Qt== Build-ABI:" _pos)
+ if (_pos GREATER -1)
+ math(EXPR _pos "${_pos}+26")
+ string(SUBSTRING "${_line}" ${_pos} -1 _build_abi)
+ endif()
+ endforeach()
+
+ if (NOT _architecture OR NOT _build_abi)
+ message(FATAL_ERROR "Failed to extract architecture data from file.")
+ endif()
+
+ set(TEST_architecture 1 CACHE INTERNAL "Ran the architecture test")
+ set(TEST_architecture_arch "${_architecture}" CACHE INTERNAL "Target machine architecture")
+ list(APPEND QT_BASE_CONFIGURE_TESTS_VARS_TO_EXPORT TEST_architecture_arch)
+ set(TEST_subarch 1 CACHE INTERNAL "Ran machine subArchitecture test")
+ foreach(it ${_sub_architecture})
+ # Equivalent to qmake's QT_CPU_FEATURES.$arch.
+ set(TEST_arch_${TEST_architecture_arch}_subarch_${it} 1 CACHE INTERNAL "Target sub architecture result")
+ list(APPEND QT_BASE_CONFIGURE_TESTS_VARS_TO_EXPORT TEST_arch_${TEST_architecture_arch}_subarch_${it})
+ endforeach()
+ set(TEST_buildAbi "${_build_abi}" CACHE INTERNAL "Target machine buildAbi")
+ list(APPEND QT_BASE_CONFIGURE_TESTS_VARS_TO_EXPORT TEST_buildAbi)
+ set(QT_BASE_CONFIGURE_TESTS_VARS_TO_EXPORT ${QT_BASE_CONFIGURE_TESTS_VARS_TO_EXPORT} CACHE INTERNAL "Test variables that should be exported")
+
+ list(JOIN _sub_architecture " " subarch_summary)
+ message(STATUS "Building for: ${QT_QMAKE_TARGET_MKSPEC} (${TEST_architecture_arch}, CPU features: ${subarch_summary})")
+endfunction()
+
+
+function(qt_run_config_test_posix_iconv)
+ set(source "#include <iconv.h>
+
+int main(int, char **)
+{
+ iconv_t x = iconv_open(\"\", \"\");
+
+ char *inp;
+ char *outp;
+ size_t inbytes, outbytes;
+ iconv(x, &inp, &inbytes, &outp, &outbytes);
+
+ iconv_close(x);
+
+ return 0;
+}")
+ check_cxx_source_compiles("${source}" HAVE_POSIX_ICONV)
+
+ if(NOT HAVE_POSIX_ICONV)
+ set(_req_libraries "${CMAKE_REQUIRE_LIBRARIES}")
+ set(CMAKE_REQUIRE_LIBRARIES "iconv")
+ check_cxx_source_compiles("${source}" HAVE_POSIX_ICONV)
+ set(CMAKE_REQUIRE_LIBRARIES "${_req_libraries}")
+ if(HAVE_POSIX_ICONV)
+ set(TEST_iconv_needlib 1 CACHE INTERNAL "Need to link against libiconv")
+ endif()
+ endif()
+
+ set(TEST_posix_iconv "${HAVE_POSIX_ICONV}" CACHE INTERNAL "POSIX iconv")
+endfunction()
+
+
+function(qt_run_config_test_sun_iconv)
+ set(source "#include <iconv.h>
+
+int main(int, char **)
+{
+ iconv_t x = iconv_open(\"\", \"\");
+
+ const char *inp;
+ char *outp;
+ size_t inbytes, outbytes;
+ iconv(x, &inp, &inbytes, &outp, &outbytes);
+
+ iconv_close(x);
+
+ return 0;
+}")
+ if(DARWIN)
+ # as per !config.darwin in configure.json
+ set(HAVE_SUN_ICONV OFF)
+ else()
+ check_cxx_source_compiles("${source}" HAVE_SUN_ICONV)
+ endif()
+
+ set(TEST_sun_iconv "${HAVE_SUN_ICONV}" CACHE INTERNAL "SUN libiconv")
+endfunction()
+
+function(qt_run_linker_version_script_support)
+ file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/version_flag.map" "VERS_1 { global: sym; };
+VERS_2 { global: sym; }
+VERS_1;
+")
+ if(DEFINED CMAKE_REQUIRED_FLAGS)
+ set(CMAKE_REQUIRED_FLAGS_SAVE ${CMAKE_REQUIRED_FLAGS})
+ else()
+ set(CMAKE_REQUIRED_FLAGS "")
+ endif()
+ set(CMAKE_REQUIRED_FLAGS ${CMAKE_REQUIRED_FLAGS} "-Wl,--version-script=\"${CMAKE_CURRENT_BINARY_DIR}/version_flag.map\"")
+ check_cxx_source_compiles("int main(void){return 0;}" HAVE_LD_VERSION_SCRIPT)
+ if(DEFINED CMAKE_REQUIRED_FLAGS_SAVE)
+ set(CMAKE_REQUIRED_FLAGS ${CMAKE_REQUIRED_FLAGS_SAVE})
+ endif()
+ file(REMOVE "${CMAKE_CURRENT_BINARY_DIR}/conftest.map")
+
+ # For some reason the linker command line written by the XCode generator, which is
+ # subsequently executed by xcodebuild, ignores the linker flag, and thus the test
+ # seemingly succeeds. Explicitly disable the version script test on darwin platforms.
+ if(APPLE)
+ set(HAVE_LD_VERSION_SCRIPT OFF)
+ endif()
+
+ set(TEST_ld_version_script "${HAVE_LD_VERSION_SCRIPT}" CACHE INTERNAL "linker version script support")
+endfunction()
+
+function(qt_run_qtbase_config_tests)
+ qt_run_config_test_posix_iconv()
+
+ add_library(Iconv INTERFACE)
+ if(TEST_iconv_needlib)
+ target_link_libraries(Iconv PUBLIC iconv)
+ endif()
+
+ if(NOT TEST_posix_iconv)
+ qt_run_config_test_sun_iconv()
+ endif()
+ qt_run_config_test_architecture()
+ qt_run_linker_version_script_support()
+endfunction()
+
+# The qmake build of android does not perform the right architecture tests and
+# forcefully disables sse4 on android x86. We have to mimic this behavior
+# for now
+if (CMAKE_ANDROID_ARCH_ABI STREQUAL x86)
+ set(QT_FEATURE_sse4_1 OFF CACHE BOOL INTERNAL FORCE)
+ set(QT_FEATURE_sse4_2 OFF CACHE BOOL INTERNAL FORCE)
+ set(TEST_subarch_sse4_1 FALSE CACHE BOOL INTERNAL FORCE)
+ set(TEST_subarch_sse4_2 FALSE CACHE BOOL INTERNAL FORCE)
+endif()
+qt_run_qtbase_config_tests()
diff --git a/cmake/QtBaseGlobalTargets.cmake b/cmake/QtBaseGlobalTargets.cmake
new file mode 100644
index 0000000000..5f38f96681
--- /dev/null
+++ b/cmake/QtBaseGlobalTargets.cmake
@@ -0,0 +1,267 @@
+## QtPlatform Target:
+add_library(Platform INTERFACE)
+add_library(Qt::Platform ALIAS Platform)
+target_include_directories(Platform
+ INTERFACE
+ $<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/${QT_PLATFORM_DEFINITION_DIR}>
+ $<BUILD_INTERFACE:${PROJECT_BINARY_DIR}/include>
+ $<INSTALL_INTERFACE:${INSTALL_DATADIR}/${QT_PLATFORM_DEFINITION_DIR}>
+ $<INSTALL_INTERFACE:${INSTALL_INCLUDEDIR}>
+ )
+target_compile_definitions(Platform INTERFACE ${QT_PLATFORM_DEFINITIONS})
+
+# When building on android we need to link against the logging library
+# in order to satisfy linker dependencies. Both of these libraries are part of
+# the NDK.
+if (ANDROID)
+ target_link_libraries(Platform INTERFACE log)
+endif()
+
+set(__GlobalConfig_path_suffix "${INSTALL_CMAKE_NAMESPACE}")
+qt_path_join(__GlobalConfig_build_dir ${QT_CONFIG_BUILD_DIR} ${__GlobalConfig_path_suffix})
+qt_path_join(__GlobalConfig_install_dir ${QT_CONFIG_INSTALL_DIR} ${__GlobalConfig_path_suffix})
+set(__GlobalConfig_install_dir_absolute "${__GlobalConfig_install_dir}")
+if(QT_WILL_INSTALL)
+ # Need to prepend the install prefix when doing prefix builds, because the config install dir
+ # is relative then.
+ qt_path_join(__GlobalConfig_install_dir_absolute
+ ${CMAKE_INSTALL_PREFIX} ${__GlobalConfig_install_dir_absolute})
+endif()
+
+# Generate and install Qt6 config file.
+configure_package_config_file(
+ "${PROJECT_SOURCE_DIR}/cmake/QtConfig.cmake.in"
+ "${__GlobalConfig_build_dir}/${INSTALL_CMAKE_NAMESPACE}Config.cmake"
+ INSTALL_DESTINATION "${__GlobalConfig_install_dir}"
+)
+
+write_basic_package_version_file(
+ ${__GlobalConfig_build_dir}/${INSTALL_CMAKE_NAMESPACE}ConfigVersion.cmake
+ VERSION ${PROJECT_VERSION}
+ COMPATIBILITY AnyNewerVersion
+)
+
+# Generate and install Qt6Tools config file.
+configure_package_config_file(
+ "${PROJECT_SOURCE_DIR}/cmake/QtToolsConfig.cmake.in"
+ "${__GlobalConfig_build_dir}/${INSTALL_CMAKE_NAMESPACE}ToolsConfig.cmake"
+ INSTALL_DESTINATION "${__GlobalConfig_install_dir}"
+)
+write_basic_package_version_file(
+ ${__GlobalConfig_build_dir}/${INSTALL_CMAKE_NAMESPACE}ToolsConfigVersion.cmake
+ VERSION ${PROJECT_VERSION}
+ COMPATIBILITY AnyNewerVersion
+)
+
+qt_install(FILES
+ "${__GlobalConfig_build_dir}/${INSTALL_CMAKE_NAMESPACE}Config.cmake"
+ "${__GlobalConfig_build_dir}/${INSTALL_CMAKE_NAMESPACE}ConfigVersion.cmake"
+ DESTINATION "${__GlobalConfig_install_dir}"
+ COMPONENT Devel
+)
+
+qt_install(FILES
+ "${__GlobalConfig_build_dir}/${INSTALL_CMAKE_NAMESPACE}ToolsConfig.cmake"
+ "${__GlobalConfig_build_dir}/${INSTALL_CMAKE_NAMESPACE}ToolsConfigVersion.cmake"
+ DESTINATION "${__GlobalConfig_install_dir}Tools"
+ COMPONENT Devel
+)
+
+# Generate toolchain file for convenience
+if(QT_HOST_PATH)
+ get_filename_component(init_qt_host_path "${QT_HOST_PATH}" ABSOLUTE)
+ set(init_qt_host_path "set(QT_HOST_PATH \"${init_qt_host_path}\" CACHE PATH \"\" FORCE)")
+endif()
+
+if(CMAKE_TOOLCHAIN_FILE)
+ set(init_original_toolchain_file "set(qt_chainload_toolchain_file \"${CMAKE_TOOLCHAIN_FILE}\")")
+endif()
+
+if(VCPKG_CHAINLOAD_TOOLCHAIN_FILE)
+ list(APPEND init_vcpkg "set(VCPKG_CHAINLOAD_TOOLCHAIN_FILE \"${VCPKG_CHAINLOAD_TOOLCHAIN_FILE}\")")
+endif()
+
+if(VCPKG_TARGET_TRIPLET)
+ list(APPEND init_vcpkg "set(VCPKG_TARGET_TRIPLET \"${VCPKG_TARGET_TRIPLET}\" CACHE STRING \"\")")
+endif()
+
+# On Windows compilers aren't easily mixed. Avoid that qtbase is built using cl.exe for example and then for another
+# build gcc is picked up from %PATH%. The same goes when using a custom compiler on other platforms, such as ICC.
+list(APPEND init_platform "set(CMAKE_CXX_COMPILER \"${CMAKE_CXX_COMPILER}\" CACHE STRING \"\")")
+list(APPEND init_platform "set(CMAKE_C_COMPILER \"${CMAKE_C_COMPILER}\" CACHE STRING \"\")")
+
+if(APPLE)
+ # For simulator_and_device build, we should not explicitly set the sysroot.
+ list(LENGTH CMAKE_OSX_ARCHITECTURES _qt_osx_architectures_count)
+ if(CMAKE_OSX_SYSROOT AND NOT _qt_osx_architectures_count GREATER 1 AND APPLE_UIKIT)
+ list(APPEND init_platform "set(CMAKE_OSX_SYSROOT \"${CMAKE_OSX_SYSROOT}\" CACHE PATH \"\")")
+ endif()
+ unset(_qt_osx_architectures_count)
+
+ if(CMAKE_OSX_DEPLOYMENT_TARGET)
+ list(APPEND init_platform
+ "set(CMAKE_OSX_DEPLOYMENT_TARGET \"${CMAKE_OSX_DEPLOYMENT_TARGET}\" CACHE STRING \"\")")
+ endif()
+
+ if(APPLE_UIKIT)
+ list(APPEND init_platform
+ "set(CMAKE_SYSTEM_NAME \"${CMAKE_SYSTEM_NAME}\" CACHE STRING \"\")")
+ set(_qt_osx_architectures_escaped "${CMAKE_OSX_ARCHITECTURES}")
+ string(REPLACE ";" "LITERAL_SEMICOLON"
+ _qt_osx_architectures_escaped "${_qt_osx_architectures_escaped}")
+ list(APPEND init_platform
+ "set(CMAKE_OSX_ARCHITECTURES \"${_qt_osx_architectures_escaped}\" CACHE STRING \"\")")
+ unset(_qt_osx_architectures_escaped)
+ endif()
+elseif(ANDROID)
+ list(APPEND init_platform "set(ANDROID_NATIVE_API_LEVEL \"${ANDROID_NATIVE_API_LEVEL}\" CACHE STRING \"\")")
+ list(APPEND init_platform "set(ANDROID_STL \"${ANDROID_STL}\" CACHE STRING \"\")")
+ list(APPEND init_platform "set(ANDROID_ABI \"${ANDROID_ABI}\" CACHE STRING \"\")")
+ list(APPEND init_platform "if (NOT DEFINED ANDROID_SDK_ROOT)")
+ list(APPEND init_platform " set(ANDROID_SDK_ROOT \"${ANDROID_SDK_ROOT}\" CACHE STRING \"\")")
+ list(APPEND init_platform "endif()")
+endif()
+
+string(REPLACE ";" "\n" init_vcpkg "${init_vcpkg}")
+string(REPLACE ";" "\n" init_platform "${init_platform}")
+string(REPLACE "LITERAL_SEMICOLON" ";" init_platform "${init_platform}")
+configure_file("${CMAKE_CURRENT_SOURCE_DIR}/cmake/qt.toolchain.cmake.in" "${__GlobalConfig_build_dir}/qt.toolchain.cmake" @ONLY)
+qt_install(FILES "${__GlobalConfig_build_dir}/qt.toolchain.cmake" DESTINATION "${__GlobalConfig_install_dir}" COMPONENT Devel)
+
+# Also provide a convenience cmake wrapper
+if(UNIX)
+ configure_file("${CMAKE_CURRENT_SOURCE_DIR}/bin/qt-cmake.in" "${QT_BUILD_DIR}/${INSTALL_BINDIR}/qt-cmake" @ONLY)
+ qt_install(PROGRAMS "${QT_BUILD_DIR}/bin/qt-cmake" DESTINATION "${INSTALL_BINDIR}")
+else()
+ configure_file("${CMAKE_CURRENT_SOURCE_DIR}/bin/qt-cmake.bat.in" "${QT_BUILD_DIR}/${INSTALL_BINDIR}/qt-cmake.bat" @ONLY)
+ qt_install(PROGRAMS "${QT_BUILD_DIR}/bin/qt-cmake.bat" DESTINATION "${INSTALL_BINDIR}")
+endif()
+
+## Library to hold global features:
+## These features are stored and accessed via Qt::GlobalConfig, but the
+## files always lived in Qt::Core, so we keep it that way
+add_library(GlobalConfig INTERFACE)
+target_include_directories(GlobalConfig INTERFACE
+ $<BUILD_INTERFACE:${PROJECT_BINARY_DIR}/include>
+ $<BUILD_INTERFACE:${PROJECT_BINARY_DIR}/include/QtCore>
+ $<INSTALL_INTERFACE:include>
+ $<INSTALL_INTERFACE:include/QtCore>
+)
+qt_feature_module_begin(NO_MODULE
+ PUBLIC_FILE src/corelib/global/qconfig.h
+ PRIVATE_FILE src/corelib/global/qconfig_p.h
+)
+include("${CMAKE_CURRENT_SOURCE_DIR}/configure.cmake")
+
+# Do what mkspecs/features/uikit/default_pre.prf does, aka enable sse2 for
+# simulator_and_device_builds.
+if(APPLE_UIKIT AND NOT QT_UIKIT_SDK)
+ set(__QtFeature_custom_enabled_cache_variables
+ TEST_subarch_sse2
+ FEATURE_sse2
+ QT_FEATURE_sse2)
+endif()
+
+qt_feature_module_end(GlobalConfig OUT_VAR_PREFIX "__GlobalConfig_")
+
+qt_generate_global_config_pri_file()
+
+add_library(Qt::GlobalConfig ALIAS GlobalConfig)
+
+add_library(GlobalConfigPrivate INTERFACE)
+target_link_libraries(GlobalConfigPrivate INTERFACE GlobalConfig)
+target_include_directories(GlobalConfigPrivate INTERFACE
+ $<BUILD_INTERFACE:${PROJECT_BINARY_DIR}/include/QtCore/${PROJECT_VERSION}>
+ $<BUILD_INTERFACE:${PROJECT_BINARY_DIR}/include/QtCore/${PROJECT_VERSION}/QtCore>
+ $<INSTALL_INTERFACE:include/QtCore/${PROJECT_VERSION}>
+ $<INSTALL_INTERFACE:include/QtCore/${PROJECT_VERSION}/QtCore>
+)
+add_library(Qt::GlobalConfigPrivate ALIAS GlobalConfigPrivate)
+
+# defines PlatformCommonInternal PlatformModuleInternal PlatformPluginInternal PlatformToolInternal
+include(QtInternalTargets)
+
+set(__export_targets Platform
+ GlobalConfig
+ GlobalConfigPrivate
+ PlatformCommonInternal
+ PlatformModuleInternal
+ PlatformPluginInternal
+ PlatformToolInternal)
+set(__export_name "${INSTALL_CMAKE_NAMESPACE}Targets")
+qt_install(TARGETS ${__export_targets} EXPORT "${__export_name}")
+qt_install(EXPORT ${__export_name}
+ NAMESPACE ${QT_CMAKE_EXPORT_NAMESPACE}::
+ DESTINATION "${__GlobalConfig_install_dir}")
+
+qt_internal_export_modern_cmake_config_targets_file(TARGETS ${__export_targets}
+ EXPORT_NAME_PREFIX ${INSTALL_CMAKE_NAMESPACE}
+ CONFIG_INSTALL_DIR
+ ${__GlobalConfig_install_dir})
+
+## Install some QtBase specific CMake files:
+qt_copy_or_install(FILES
+ cmake/ModuleDescription.json.in
+ cmake/QtBuild.cmake
+ cmake/QtBuildInformation.cmake
+ cmake/QtCompilerFlags.cmake
+ cmake/QtCompilerOptimization.cmake
+ cmake/QtFeature.cmake
+ cmake/QtPlatformSupport.cmake
+ cmake/QtPlatformAndroid.cmake
+ cmake/QtPostProcess.cmake
+ cmake/QtSetup.cmake
+ cmake/QtModuleConfig.cmake.in
+ cmake/QtModuleDependencies.cmake.in
+ cmake/QtModuleToolsDependencies.cmake.in
+ cmake/QtModuleToolsConfig.cmake.in
+ cmake/QtModuleToolsVersionlessTargets.cmake.in
+ cmake/QtStandaloneTestsConfig.cmake.in
+ cmake/QtPlugins.cmake.in
+ cmake/QtPluginConfig.cmake.in
+ cmake/QtPluginDependencies.cmake.in
+ DESTINATION "${__GlobalConfig_install_dir}"
+)
+
+file(COPY cmake/QtFeature.cmake DESTINATION "${__GlobalConfig_build_dir}")
+
+# TODO: Check whether this is the right place to install these
+qt_copy_or_install(DIRECTORY cmake/3rdparty DESTINATION "${__GlobalConfig_install_dir}")
+
+# Install our custom Find modules, which will be used by the find_dependency() calls
+# inside the generated ModuleDependencies cmake files.
+qt_copy_or_install(DIRECTORY cmake/
+ DESTINATION "${__GlobalConfig_install_dir}"
+ FILES_MATCHING PATTERN "Find*.cmake"
+ PATTERN "tests" EXCLUDE
+ PATTERN "3rdparty" EXCLUDE
+)
+
+# Configure and install the QtBuildInternals package.
+set(__build_internals_path_suffix "${INSTALL_CMAKE_NAMESPACE}BuildInternals")
+qt_path_join(__build_internals_build_dir ${QT_CONFIG_BUILD_DIR} ${__build_internals_path_suffix})
+qt_path_join(__build_internals_install_dir ${QT_CONFIG_INSTALL_DIR}
+ ${__build_internals_path_suffix})
+configure_file(
+ "${CMAKE_CURRENT_SOURCE_DIR}/cmake/QtBuildInternals/QtBuildInternalsConfig.cmake"
+ "${__build_internals_build_dir}/${INSTALL_CMAKE_NAMESPACE}BuildInternalsConfig.cmake"
+ @ONLY
+ )
+
+qt_install(FILES
+ "${__build_internals_build_dir}/${INSTALL_CMAKE_NAMESPACE}BuildInternalsConfig.cmake"
+ "${__build_internals_build_dir}/QtBuildInternalsExtra.cmake"
+ "${CMAKE_CURRENT_SOURCE_DIR}/cmake/QtBuildInternals/QtBuildInternalsAndroid.cmake"
+ DESTINATION "${__build_internals_install_dir}"
+ COMPONENT Devel
+)
+
+# Generate the new resource API
+set(QT_CORE_RESOURCE_GENERATED_FILE_NAME "${INSTALL_CMAKE_NAMESPACE}CoreResource.cmake" CACHE INTERNAL "")
+set(QT_CORE_RESOURCE_GENERATED_FILE_PATH "${CMAKE_CURRENT_BINARY_DIR}/${QT_CORE_RESOURCE_GENERATED_FILE_NAME}" CACHE INTERNAL "")
+configure_file(
+ "${CMAKE_CURRENT_SOURCE_DIR}/cmake/QtResource.cmake.in"
+ "${QT_CORE_RESOURCE_GENERATED_FILE_PATH}"
+ @ONLY
+)
+include(${QT_CORE_RESOURCE_GENERATED_FILE_PATH})
diff --git a/cmake/QtBuild.cmake b/cmake/QtBuild.cmake
new file mode 100644
index 0000000000..f79352d725
--- /dev/null
+++ b/cmake/QtBuild.cmake
@@ -0,0 +1,4055 @@
+include(CMakePackageConfigHelpers)
+
+# Install locations:
+set(INSTALL_BINDIR "bin" CACHE STRING "Executables [PREFIX/bin]")
+set(INSTALL_INCLUDEDIR "include" CACHE STRING "Header files [PREFIX/include]")
+set(INSTALL_LIBDIR "lib" CACHE STRING "Libraries [PREFIX/lib]")
+set(INSTALL_ARCHDATADIR "." CACHE STRING "Arch-dependent data [PREFIX]")
+set(INSTALL_PLUGINSDIR "${INSTALL_ARCHDATADIR}/plugins" CACHE STRING
+ "Plugins [ARCHDATADIR/plugins]")
+
+set(INSTALL_TARGETS_DEFAULT_ARGS
+ RUNTIME DESTINATION "${INSTALL_BINDIR}"
+ LIBRARY DESTINATION "${INSTALL_LIBDIR}"
+ ARCHIVE DESTINATION "${INSTALL_LIBDIR}" COMPONENT Devel
+ INCLUDES DESTINATION "${INSTALL_INCLUDEDIR}"
+)
+
+if (WIN32)
+ set(_default_libexec "${INSTALL_ARCHDATADIR}/bin")
+else()
+ set(_default_libexec "${INSTALL_ARCHDATADIR}/libexec")
+endif()
+
+set(INSTALL_LIBEXECDIR "${_default_libexec}" CACHE STRING
+ "Helper programs [ARCHDATADIR/bin on Windows, ARCHDATADIR/libexec otherwise]")
+set(INSTALL_QMLDIR "${INSTALL_ARCHDATADIR}/qml" CACHE STRING
+ "QML2 imports [ARCHDATADIR/qml]")
+set(INSTALL_DATADIR "." CACHE STRING "Arch-independent data [PREFIX]")
+set(INSTALL_DOCDIR "${INSTALL_DATADIR}/doc" CACHE STRING "Documentation [DATADIR/doc]")
+set(INSTALL_TRANSLATIONSDIR "${INSTALL_DATADIR}/translations" CACHE STRING
+ "Translations [DATADIR/translations]")
+set(INSTALL_SYSCONFDIR "etc/xdg" CACHE STRING
+ "Settings used by Qt programs [PREFIX/etc/xdg]")
+set(INSTALL_EXAMPLESDIR "examples" CACHE STRING "Examples [PREFIX/examples]")
+set(INSTALL_TESTSDIR "tests" CACHE STRING "Tests [PREFIX/tests]")
+set(INSTALL_DESCRIPTIONSDIR "${INSTALL_DATADIR}/modules" CACHE STRING
+ "Module description files directory")
+
+# The variables might have already been set in QtBuildInternalsExtra.cmake if the file is included
+# while building a new module and not QtBase. In that case, stop overriding the value.
+if(NOT INSTALL_CMAKE_NAMESPACE)
+ set(INSTALL_CMAKE_NAMESPACE "Qt${PROJECT_VERSION_MAJOR}"
+ CACHE STRING "CMake namespace [Qt${PROJECT_VERSION_MAJOR}]")
+endif()
+if(NOT QT_CMAKE_EXPORT_NAMESPACE)
+ set(QT_CMAKE_EXPORT_NAMESPACE "Qt${PROJECT_VERSION_MAJOR}"
+ CACHE STRING "CMake namespace used when exporting targets [Qt${PROJECT_VERSION_MAJOR}]")
+endif()
+
+set(QT_CMAKE_DIR "${CMAKE_CURRENT_LIST_DIR}")
+
+# Find the path to mkspecs/, depending on whether we are building as part of a standard qtbuild,
+# or a module against an already installed version of qt.
+if(NOT QT_MKSPECS_DIR)
+ if("${QT_BUILD_INTERNALS_PATH}" STREQUAL "")
+ get_filename_component(QT_MKSPECS_DIR "${CMAKE_CURRENT_LIST_DIR}/../mkspecs" ABSOLUTE)
+ else()
+ # We can rely on CMAKE_INSTALL_PREFIX being set by QtBuildInternalsExtra.cmake
+ get_filename_component(QT_MKSPECS_DIR "${CMAKE_INSTALL_PREFIX}/mkspecs" ABSOLUTE)
+ endif()
+ set(QT_MKSPECS_DIR "${QT_MKSPECS_DIR}" CACHE INTERNAL "")
+endif()
+
+# the default RPATH to be used when installing, but only if it's not a system directory
+LIST(FIND CMAKE_PLATFORM_IMPLICIT_LINK_DIRECTORIES "${CMAKE_INSTALL_PREFIX}/lib" isSystemDir)
+IF("${isSystemDir}" STREQUAL "-1")
+ SET(_default_install_rpath "${CMAKE_INSTALL_PREFIX}/lib")
+ENDIF("${isSystemDir}" STREQUAL "-1")
+
+# Default rpath settings: Use rpath for build tree as well as a full path for the installed binaries.
+# For origin builds, one needs to override CMAKE_INSTALL_RPATH for example with $ORIGIN/../lib
+SET(CMAKE_INSTALL_RPATH "${_default_install_rpath}" CACHE PATH "RPATH for installed binaries")
+
+# add the automatically determined parts of the RPATH
+# which point to directories outside the build tree to the install RPATH
+SET(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE)
+
+# Generate a module description file based on the template in ModuleDescription.json.in
+function(qt_describe_module target)
+ set(path_suffix "${INSTALL_DESCRIPTIONSDIR}")
+ qt_path_join(build_dir ${QT_BUILD_DIR} ${path_suffix})
+ qt_path_join(install_dir ${QT_INSTALL_DIR} ${path_suffix})
+
+ set(descfile_in "${QT_CMAKE_DIR}/ModuleDescription.json.in")
+ set(descfile_out "${build_dir}/${target}.json")
+ set(cross_compilation "false")
+ if(CMAKE_CROSSCOMPILE)
+ set(cross_compilation "true")
+ endif()
+ configure_file("${descfile_in}" "${descfile_out}")
+
+ qt_install(FILES "${descfile_out}" DESTINATION "${install_dir}")
+endfunction()
+
+function(qt_setup_tool_path_command)
+ if(NOT WIN32)
+ return()
+ endif()
+ set(bindir "${CMAKE_INSTALL_PREFIX}/${INSTALL_BINDIR}")
+ file(TO_NATIVE_PATH "${bindir}" bindir)
+ list(APPEND command COMMAND)
+ list(APPEND command set PATH=${bindir}$<SEMICOLON>%PATH%)
+ set(QT_TOOL_PATH_SETUP_COMMAND "${command}" CACHE INTERNAL "internal command prefix for tool invocations" FORCE)
+endfunction()
+qt_setup_tool_path_command()
+
+# Platform define path, etc.
+set(QT_QMAKE_TARGET_MKSPEC "")
+if(WIN32)
+ set(QT_DEFAULT_PLATFORM_DEFINITIONS UNICODE _UNICODE WIN32 _ENABLE_EXTENDED_ALIGNED_STORAGE)
+ if(CMAKE_SIZEOF_VOID_P EQUAL 8)
+ list(APPEND QT_DEFAULT_PLATFORM_DEFINITIONS WIN64 _WIN64)
+ endif()
+ if(MSVC)
+ set(QT_QMAKE_TARGET_MKSPEC win32-msvc)
+ elseif(CLANG AND MINGW)
+ set(QT_QMAKE_TARGET_MKSPEC win32-clang-g++)
+ elseif(MINGW)
+ set(QT_QMAKE_TARGET_MKSPEC win32-g++)
+ endif()
+
+ if (MINGW)
+ list(APPEND QT_DEFAULT_PLATFORM_DEFINITIONS _WIN32_WINNT=0x0601)
+ endif()
+elseif(LINUX)
+ if(GCC)
+ set(QT_QMAKE_TARGET_MKSPEC linux-g++)
+ elseif(CLANG)
+ set(QT_QMAKE_TARGET_MKSPEC linux-clang)
+ elseif(ICC)
+ set(QT_QMAKE_TARGET_MKSPEC linux-icc-64)
+ endif()
+elseif(ANDROID)
+ if(GCC)
+ set(QT_QMAKE_TARGET_MKSPEC android-g++)
+ elseif(CLANG)
+ set(QT_QMAKE_TARGET_MKSPEC android-clang)
+ endif()
+elseif(APPLE)
+ set(QT_QMAKE_TARGET_MKSPEC macx-clang)
+elseif(EMSCRIPTEN)
+ set(QT_QMAKE_TARGET_MKSPEC wasm-emscripten)
+endif()
+
+# TODO: Fixme to be correct.
+set(QT_QMAKE_HOST_MKSPEC "${QT_QMAKE_TARGET_MKSPEC}")
+
+if(QT_QMAKE_TARGET_MKSPEC)
+ set(QT_DEFAULT_PLATFORM_DEFINITION_DIR mkspecs/${QT_QMAKE_TARGET_MKSPEC})
+endif()
+
+if(NOT DEFINED QT_DEFAULT_PLATFORM_DEFINITIONS)
+ set(QT_DEFAULT_PLATFORM_DEFINITIONS "")
+endif()
+
+set(QT_PLATFORM_DEFINITIONS ${QT_DEFAULT_PLATFORM_DEFINITIONS}
+ CACHE STRING "Qt platform specific pre-processor defines")
+set(QT_PLATFORM_DEFINITION_DIR ${QT_DEFAULT_PLATFORM_DEFINITION_DIR}
+ CACHE PATH "Path to directory that contains qplatformdefs.h")
+set(QT_NAMESPACE "" CACHE STRING "Qt Namespace")
+if(QT_NAMESPACE STREQUAL "")
+ set(QT_HAS_NAMESPACE OFF)
+else()
+ set(QT_HAS_NAMESPACE ON)
+endif()
+
+
+function(qt_internal_clear_qt_repo_known_modules)
+ set(QT_REPO_KNOWN_MODULES "" CACHE INTERNAL "Known current repo Qt modules" FORCE)
+endfunction()
+
+function(qt_internal_add_qt_repo_known_module)
+ set(QT_REPO_KNOWN_MODULES ${QT_REPO_KNOWN_MODULES} ${ARGN}
+ CACHE INTERNAL "Known current repo Qt modules" FORCE)
+endfunction()
+
+function(qt_internal_get_qt_repo_known_modules out_var)
+ set("${out_var}" "${QT_REPO_KNOWN_MODULES}" PARENT_SCOPE)
+endfunction()
+
+# Gets the list of all known Qt modules both found and that were built as part of the
+# current project.
+function(qt_internal_get_qt_all_known_modules out_var)
+ qt_internal_get_qt_repo_known_modules(repo_known_modules)
+ set(known_modules ${QT_ALL_MODULES_FOUND_VIA_FIND_PACKAGE} ${repo_known_modules})
+ list(REMOVE_DUPLICATES known_modules)
+ set("${out_var}" "${known_modules}" PARENT_SCOPE)
+endfunction()
+
+macro(qt_internal_set_qt_known_plugins)
+ set(QT_KNOWN_PLUGINS ${ARGN} CACHE INTERNAL "Known Qt plugins" FORCE)
+endmacro()
+
+### Global plug-in types handling ###
+# QT_REPO_KNOWN_PLUGIN_TYPES and QT_ALL_PLUGIN_TYPES_FOUND_VIA_FIND_PACKAGE
+# hold a list of plug-in types (e.G. "imageformats;bearer")
+function(qt_internal_clear_qt_repo_known_plugin_types)
+ set(QT_REPO_KNOWN_PLUGIN_TYPES "" CACHE INTERNAL "Known current repo Qt plug-in types" FORCE)
+endfunction()
+
+function(qt_internal_add_qt_repo_known_plugin_types)
+ set(QT_REPO_KNOWN_PLUGIN_TYPES ${QT_REPO_KNOWN_PLUGIN_TYPES} ${ARGN}
+ CACHE INTERNAL "Known current repo Qt plug-in types" FORCE)
+endfunction()
+
+function(qt_internal_get_qt_repo_known_plugin_types out_var)
+ set("${out_var}" "${QT_REPO_KNOWN_PLUGIN_TYPES}" PARENT_SCOPE)
+endfunction()
+
+function(qt_internal_get_qt_all_known_plugin_types out_var)
+ qt_internal_get_qt_repo_known_plugin_types(repo_known_plugin_types)
+ set(known ${QT_ALL_PLUGIN_TYPES_FOUND_VIA_FIND_PACKAGE} ${repo_known_plugin_types})
+ list(REMOVE_DUPLICATES known)
+ set("${out_var}" "${known}" PARENT_SCOPE)
+endfunction()
+
+# Reset:
+qt_internal_clear_qt_repo_known_modules()
+qt_internal_clear_qt_repo_known_plugin_types()
+qt_internal_set_qt_known_plugins("")
+
+set(QT_KNOWN_MODULES_WITH_TOOLS "" CACHE INTERNAL "Known Qt modules with tools" FORCE)
+macro(qt_internal_append_known_modules_with_tools module)
+ if(NOT ${module} IN_LIST QT_KNOWN_MODULES_WITH_TOOLS)
+ set(QT_KNOWN_MODULES_WITH_TOOLS "${QT_KNOWN_MODULES_WITH_TOOLS};${module}"
+ CACHE INTERNAL "Known Qt modules with tools" FORCE)
+ set(QT_KNOWN_MODULE_${module}_TOOLS ""
+ CACHE INTERNAL "Known Qt module ${module} tools" FORCE)
+ endif()
+endmacro()
+
+macro(qt_internal_append_known_module_tool module tool)
+ if(NOT ${tool} IN_LIST QT_KNOWN_MODULE_${module}_TOOLS)
+ list(APPEND QT_KNOWN_MODULE_${module}_TOOLS "${tool}")
+ set(QT_KNOWN_MODULE_${module}_TOOLS "${QT_KNOWN_MODULE_${module}_TOOLS}"
+ CACHE INTERNAL "Known Qt module ${module} tools" FORCE)
+ endif()
+endmacro()
+
+# Reset syncqt cache variable, to make sure it gets recomputed on reconfiguration, otherwise
+# it might not get installed.
+unset(QT_SYNCQT CACHE)
+
+# For adjusting variables when running tests, we need to know what
+# the correct variable is for separating entries in PATH-alike
+# variables.
+if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Windows")
+ set(QT_PATH_SEPARATOR "\\;")
+else()
+ set(QT_PATH_SEPARATOR ":")
+endif()
+
+# Compute the values of QT_BUILD_DIR, QT_INSTALL_DIR, QT_CONFIG_BUILD_DIR, QT_CONFIG_INSTALL_DIR
+# taking into account whether the current build is a prefix build or a non-prefix build,
+# and whether it is a superbuild or non-superbuild.
+#
+# These values should be prepended to file paths in commands or properties,
+# in order to correctly place generated Config files, generated Targets files,
+# excutables / libraries, when copying / installing files, etc.
+#
+# The build dir variables will always be absolute paths.
+# The QT_INSTALL_DIR variable will have a relative path in a prefix build,
+# which means that it can be empty, so use qt_join_path to prevent accidental absolute paths.
+if(QT_SUPERBUILD)
+ # In this case, we always copy all the build products in qtbase/{bin,lib,...}
+ if(QT_WILL_INSTALL)
+ set(QT_BUILD_DIR "${QtBase_BINARY_DIR}")
+ set(QT_INSTALL_DIR "")
+ else()
+ set(QT_BUILD_DIR "${QtBase_BINARY_DIR}")
+ set(QT_INSTALL_DIR "${QtBase_BINARY_DIR}")
+ endif()
+else()
+ if(QT_WILL_INSTALL)
+ # In the usual prefix build case, the build dir is the current module build dir,
+ # and the install dir is the prefix, so we don't set it.
+ set(QT_BUILD_DIR "${CMAKE_BINARY_DIR}")
+ set(QT_INSTALL_DIR "")
+ else()
+ # When doing a non-prefix build, both the build dir and install dir are the same,
+ # pointing to the qtbase build dir.
+ set(QT_BUILD_DIR "${CMAKE_INSTALL_PREFIX}")
+ set(QT_INSTALL_DIR "${QT_BUILD_DIR}")
+ endif()
+endif()
+
+set(__config_path_part "${INSTALL_LIBDIR}/cmake")
+set(QT_CONFIG_BUILD_DIR "${QT_BUILD_DIR}/${__config_path_part}")
+set(QT_CONFIG_INSTALL_DIR "${QT_INSTALL_DIR}")
+if(QT_CONFIG_INSTALL_DIR)
+ string(APPEND QT_CONFIG_INSTALL_DIR "/")
+endif()
+string(APPEND QT_CONFIG_INSTALL_DIR ${__config_path_part})
+unset(__config_path_part)
+
+# This is used to hold extra cmake code that should be put into QtBuildInternalsExtra.cmake file
+# at the QtPostProcess stage.
+set(QT_BUILD_INTERNALS_EXTRA_CMAKE_CODE "")
+
+# Save the value of the current first project source dir.
+# This will be /path/to/qtbase for qtbase both in a super-build and a non super-build.
+# This will be /path/to/qtbase/tests when building standalone tests.
+set(QT_TOP_LEVEL_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}")
+
+# Prevent warnings about object files without any symbols. This is a common
+# thing in Qt as we tend to build files unconditionally, and then use ifdefs
+# to compile out parts that are not relevant.
+if(CMAKE_HOST_APPLE AND APPLE)
+ foreach(lang ASM C CXX)
+ # We have to tell 'ar' to not run ranlib by itself, by passing the 'S' option
+ set(CMAKE_${lang}_ARCHIVE_CREATE "<CMAKE_AR> qcS <TARGET> <LINK_FLAGS> <OBJECTS>")
+ set(CMAKE_${lang}_ARCHIVE_APPEND "<CMAKE_AR> qS <TARGET> <LINK_FLAGS> <OBJECTS>")
+ set(CMAKE_${lang}_ARCHIVE_FINISH "<CMAKE_RANLIB> -no_warning_for_no_symbols <TARGET>")
+ endforeach()
+endif()
+
+# Functions and macros:
+
+# qt_remove_args can remove arguments from an existing list of function
+# arguments in order to pass a filtered list of arguments to a different function.
+# Parameters:
+# out_var: result of remove all arguments specified by ARGS_TO_REMOVE from ALL_ARGS
+# ARGS_TO_REMOVE: Arguments to remove.
+# ALL_ARGS: All arguments supplied to cmake_parse_arguments or
+# qt_parse_all_arguments
+# from which ARGS_TO_REMOVE should be removed from. We require all the
+# arguments or we can't properly identify the range of the arguments detailed
+# in ARGS_TO_REMOVE.
+# ARGS: Arguments passed into the function, usually ${ARGV}
+#
+# E.g.:
+# We want to forward all arguments from foo to bar, execpt ZZZ since it will
+# trigger an error in bar.
+#
+# foo(target BAR .... ZZZ .... WWW ...)
+# bar(target BAR.... WWW...)
+#
+# function(foo target)
+# qt_parse_all_arguments(arg "" "" "BAR;ZZZ;WWW ${ARGV})
+# qt_remove_args(forward_args
+# ARGS_TO_REMOVE ${target} ZZZ
+# ALL_ARGS ${target} BAR ZZZ WWW
+# ARGS ${ARGV}
+# )
+# bar(${target} ${forward_args})
+# endfunction()
+#
+function(qt_remove_args out_var)
+ cmake_parse_arguments(arg "" "" "ARGS_TO_REMOVE;ALL_ARGS;ARGS" ${ARGN})
+ set(result ${arg_ARGS})
+ foreach(arg IN LISTS arg_ARGS_TO_REMOVE)
+ # find arg
+ list(FIND result ${arg} find_result)
+ if (NOT find_result EQUAL -1)
+ # remove arg
+ list(REMOVE_AT result ${find_result})
+ list(LENGTH result result_len)
+ list(GET result ${find_result} arg_current)
+ # remove values until we hit another arg
+ while(NOT ${arg_current} IN_LIST arg_ALL_ARGS AND find_result LESS result_len)
+ list(REMOVE_AT result ${find_result})
+ list(GET result ${find_result} arg_current)
+ list(LENGTH result result_len)
+ endwhile()
+ endif()
+ endforeach()
+ set(${out_var} "${result}" PARENT_SCOPE)
+endfunction()
+# Wraps install() command. In a prefix build, simply passes along arguments to install().
+# In a non-prefix build, handles association of targets to export names, and also calls export().
+function(qt_install)
+ set(flags)
+ set(options EXPORT DESTINATION NAMESPACE)
+ set(multiopts TARGETS)
+ cmake_parse_arguments(arg "${flags}" "${options}" "${multiopts}" ${ARGN})
+
+ if(arg_TARGETS)
+ set(is_install_targets TRUE)
+ endif()
+
+ # In a prefix build, always invoke install() without modification.
+ # In a non-prefix build, pass install(TARGETS) commands to allow
+ # association of targets to export names, so we can later use the export names
+ # in export() commands.
+ if(QT_WILL_INSTALL OR is_install_targets)
+ install(${ARGV})
+ endif()
+
+ # Exit early if this is a prefix build.
+ if(QT_WILL_INSTALL)
+ return()
+ endif()
+
+ # In a non-prefix build, when install(EXPORT) is called,
+ # also call export(EXPORT) to generate build tree target files.
+ if(NOT is_install_targets AND arg_EXPORT)
+ set(namespace_option "")
+ if(arg_NAMESPACE)
+ set(namespace_option NAMESPACE ${arg_NAMESPACE})
+ endif()
+ export(EXPORT ${arg_EXPORT}
+ ${namespace_option}
+ FILE "${arg_DESTINATION}/${arg_EXPORT}.cmake")
+ endif()
+endfunction()
+
+# Copies files using file(COPY) signature in non-prefix builds.
+function(qt_non_prefix_copy)
+ if(NOT QT_WILL_INSTALL)
+ file(${ARGV})
+ endif()
+endfunction()
+
+# Use case is installing files in a prefix build, or copying them to the correct build dir
+# in a non-prefix build.
+# Pass along arguments as you would pass them to install().
+# Only supports FILES, PROGRAMS and DIRECTORY signature, and without fancy things
+# like OPTIONAL or RENAME or COMPONENT.
+function(qt_copy_or_install)
+ set(flags FILES PROGRAMS DIRECTORY)
+ set(options)
+ set(multiopts)
+ cmake_parse_arguments(arg "${flags}" "${options}" "${multiopts}" ${ARGN})
+
+ # Remember which option has to be passed to the install command.
+ set(argv_copy ${ARGV})
+ if(arg_FILES)
+ set(install_option "FILES")
+ elseif(arg_PROGRAMS)
+ set(install_option "PROGRAMS")
+ elseif(arg_DIRECTORY)
+ set(install_option "DIRECTORY")
+ endif()
+
+ list(REMOVE_AT argv_copy 0)
+ qt_install(${install_option} ${argv_copy})
+ qt_non_prefix_copy(COPY ${argv_copy})
+endfunction()
+
+# Hacky way to remove the install target in non-prefix builds.
+# We need to associate targets with export names, and that is only possible to do with the
+# install(TARGETS) command. But in a non-prefix build, we don't want to install anything.
+# To make sure that developers don't accidentally run make install, replace the generated
+# cmake_install.cmake file with an empty file. To do this, always create a new temporary file
+# at CMake configuration step, and use it as an input to a custom command that replaces the
+# cmake_install.cmake file with an empty one. This means we will always replace the file on
+# every reconfiguration, but not when doing null builds.
+function(qt_remove_install_target)
+ # On superbuilds we only do this for qtbase - it will correctly remove the
+ # cmake_install.cmake at the root of the repository.
+ if(QT_SUPERBUILD)
+ if(NOT (PROJECT_NAME STREQUAL "QtBase"))
+ return()
+ endif()
+ endif()
+
+ set(file_in "${CMAKE_BINARY_DIR}/.remove_cmake_install_in.txt")
+ set(file_generated "${CMAKE_BINARY_DIR}/.remove_cmake_install_generated.txt")
+ set(cmake_install_file "${CMAKE_BINARY_DIR}/cmake_install.cmake")
+ file(WRITE ${file_in} "")
+
+ add_custom_command(OUTPUT ${file_generated}
+ COMMAND ${CMAKE_COMMAND} -E copy ${file_in} ${file_generated}
+ COMMAND ${CMAKE_COMMAND} -E remove ${cmake_install_file}
+ COMMAND ${CMAKE_COMMAND} -E touch ${cmake_install_file}
+ COMMENT "Removing cmake_install.cmake"
+ MAIN_DEPENDENCY ${file_in})
+
+ add_custom_target(remove_cmake_install ALL DEPENDS ${file_generated})
+endfunction()
+
+function(qt_set_up_nonprefix_build)
+ if(NOT QT_WILL_INSTALL)
+ qt_remove_install_target()
+ endif()
+endfunction()
+
+function(qt_is_imported_target target out_var)
+ if(NOT TARGET "${target}")
+ set(target "${QT_CMAKE_EXPORT_NAMESPACE}::${target}")
+ endif()
+ if(NOT TARGET "${target}")
+ message(FATAL_ERROR "Invalid target given to qt_is_imported_target: ${target}")
+ endif()
+ get_target_property(is_imported "${target}" IMPORTED)
+ set(${out_var} "${is_imported}" PARENT_SCOPE)
+endfunction()
+
+# Generates module .pri files for consumption by qmake
+function(qt_generate_module_pri_file target target_path pri_files_var)
+ set(flags INTERNAL_MODULE HEADER_MODULE)
+ set(options)
+ set(multiopts QMAKE_MODULE_CONFIG)
+ cmake_parse_arguments(arg "${flags}" "${options}" "${multiopts}" ${ARGN})
+
+ qt_internal_module_info(module "${target}")
+ set(pri_files)
+
+ set(property_prefix)
+ if(arg_HEADER_MODULE)
+ set(property_prefix "interface_")
+ endif()
+
+ get_target_property(enabled_features "${target}"
+ "${property_prefix}QT_ENABLED_PUBLIC_FEATURES")
+ get_target_property(disabled_features "${target}"
+ "${property_prefix}QT_DISABLED_PUBLIC_FEATURES")
+ get_target_property(enabled_private_features "${target}"
+ "${property_prefix}QT_ENABLED_PRIVATE_FEATURES")
+ get_target_property(disabled_private_features "${target}"
+ "${property_prefix}QT_DISABLED_PRIVATE_FEATURES")
+
+ foreach(var enabled_features disabled_features enabled_private_features disabled_private_features)
+ if(${var} STREQUAL "${var}-NOTFOUND")
+ set(${var} "")
+ else()
+ string (REPLACE ";" " " ${var} "${${var}}")
+ endif()
+ endforeach()
+
+ if(arg_QMAKE_MODULE_CONFIG)
+ string(REPLACE ";" " " module_config "${arg_QMAKE_MODULE_CONFIG}")
+ set(module_config "\nQT.${module_lower}.CONFIG = ${module_config}")
+ else()
+ set(module_config "")
+ endif()
+
+ if (NOT ${arg_INTERNAL_MODULE})
+ qt_path_join(pri_file_name "${target_path}" "qt_lib_${module_lower}.pri")
+ list(APPEND pri_files "${pri_file_name}")
+
+ file(GENERATE
+ OUTPUT "${pri_file_name}"
+ CONTENT
+ "QT.${module_lower}.VERSION = ${PROJECT_VERSION}
+QT.${module_lower}.name = ${module}
+QT.${module_lower}.module = ${module_versioned}
+QT.${module_lower}.libs = $$QT_MODULE_LIB_BASE
+QT.${module_lower}.includes = $$QT_MODULE_INCLUDE_BASE $$QT_MODULE_INCLUDE_BASE/${module}
+QT.${module_lower}.frameworks =
+QT.${module_lower}.bins = $$QT_MODULE_BIN_BASE
+QT.${module_lower}.depends =
+QT.${module_lower}.uses =
+QT.${module_lower}.module_config = v2
+QT.${module_lower}.DEFINES = QT_${module_define}_LIB
+QT.${module_lower}.enabled_features = ${enabled_features}
+QT.${module_lower}.disabled_features = ${disabled_features}${module_config}
+QT_MODULES += ${module_lower}
+"
+ )
+ endif()
+
+ qt_path_join(private_pri_file "${target_path}" "qt_lib_${module_lower}_private.pri")
+ list(APPEND pri_files "${private_pri_file}")
+
+ file(GENERATE
+ OUTPUT "${private_pri_file}"
+ CONTENT
+ "QT.${module_lower}_private.VERSION = ${PROJECT_VERSION}
+QT.${module_lower}_private.name = ${module}
+QT.${module_lower}_private.module =
+QT.${module_lower}_private.libs = $$QT_MODULE_LIB_BASE
+QT.${module_lower}_private.includes = $$QT_MODULE_INCLUDE_BASE/${module}/${PROJECT_VERSION} $$QT_MODULE_INCLUDE_BASE/${module}/${PROJECT_VERSION}/${module}
+QT.${module_lower}_private.frameworks =
+QT.${module_lower}_private.depends = ${module_lower}
+QT.${module_lower}_private.uses =
+QT.${module_lower}_private.module_config = v2
+QT.${module_lower}_private.enabled_features = ${enabled_private_features}
+QT.${module_lower}_private.disabled_features = ${disabled_private_features}
+"
+ )
+
+ set("${pri_files_var}" "${pri_files}" PARENT_SCOPE)
+endfunction()
+
+function(qt_generate_global_config_pri_file)
+ qt_path_join(qconfig_pri_target_path ${PROJECT_BINARY_DIR} mkspecs)
+ qt_path_join(qconfig_pri_target_path "${qconfig_pri_target_path}" "qconfig.pri")
+
+ get_target_property(enabled_features GlobalConfig INTERFACE_QT_ENABLED_PUBLIC_FEATURES)
+ get_target_property(disabled_features GlobalConfig INTERFACE_QT_DISABLED_PUBLIC_FEATURES)
+
+ # configure2cmake skips the "static" feature, so emulate it here for qmake support:
+ if(QT_BUILD_SHARED_LIBS OR BUILD_SHARED_LIBS)
+ list(APPEND enabled_features shared)
+ list(APPEND disabled_features static)
+ set(qt_build_config_type "shared")
+ else()
+ list(APPEND enabled_features static)
+ list(APPEND disabled_features shared)
+ set(qt_build_config_type "static")
+ endif()
+
+ # configure2cmake skips the "rpath" feature, so emulate it here for qmake support:
+ if(CMAKE_SKIP_RPATH)
+ list(APPEND disabled_features rpath)
+ elseif(LINUX OR APPLE)
+ list(APPEND enabled_features rpath)
+ endif()
+
+ string (REPLACE ";" " " enabled_features "${enabled_features}")
+ string (REPLACE ";" " " disabled_features "${disabled_features}")
+
+ # Add some required CONFIG entries.
+ set(config_entries "")
+ if(CMAKE_BUILD_TYPE STREQUAL Debug)
+ list(APPEND config_entries "debug")
+ elseif(CMAKE_BUILD_TYPE STREQUAL Release)
+ list(APPEND config_entries "release")
+ endif()
+ list(APPEND config_entries "${qt_build_config_type}")
+ string (REPLACE ";" " " config_entries "${config_entries}")
+
+ file(GENERATE
+ OUTPUT "${qconfig_pri_target_path}"
+ CONTENT
+ "QT_ARCH = ${TEST_architecture_arch}
+QT_BUILDABI = ${TEST_buildAbi}
+QT.global.enabled_features = ${enabled_features}
+QT.global.disabled_features = ${disabled_features}
+QT_VERSION = ${PROJECT_VERSION}
+QT_MAJOR_VERSION = ${PROJECT_VERSION_MAJOR}
+QT_MINOR_VERSION = ${PROJECT_VERSION_MINOR}
+QT_PATCH_VERSION = ${PROJECT_VERSION_PATCH}
+CONFIG -= link_prl # we do not create prl files right now
+CONFIG += ${config_entries}
+"
+ )
+ qt_install(FILES "${qconfig_pri_target_path}" DESTINATION mkspecs)
+endfunction()
+
+# Takes a list of path components and joins them into one path separated by forward slashes "/",
+# and saves the path in out_var.
+function(qt_path_join out_var)
+ # Remove output variable.
+ set(argv ${ARGV})
+ list(REMOVE_AT argv 0)
+
+ # Join the path components.
+ string(JOIN "/" path ${argv})
+ set(${out_var} ${path} PARENT_SCOPE)
+endfunction()
+
+function(qt_internal_export_modern_cmake_config_targets_file)
+ cmake_parse_arguments(__arg "" "EXPORT_NAME_PREFIX;CONFIG_INSTALL_DIR" "TARGETS" ${ARGN})
+
+ set(export_name "${__arg_EXPORT_NAME_PREFIX}VersionlessTargets")
+ foreach(target ${__arg_TARGETS})
+ if (TARGET "${target}Versionless")
+ continue()
+ endif()
+
+ add_library("${target}Versionless" INTERFACE)
+ target_link_libraries("${target}Versionless" INTERFACE "${target}")
+ set_target_properties("${target}Versionless" PROPERTIES EXPORT_NAME "${target}")
+ qt_install(TARGETS "${target}Versionless" EXPORT ${export_name})
+ endforeach()
+ qt_install(EXPORT ${export_name} NAMESPACE Qt:: DESTINATION "${__arg_CONFIG_INSTALL_DIR}")
+endfunction()
+
+# Print all variables defined in the current scope.
+macro(qt_debug_print_variables)
+ cmake_parse_arguments(__arg "DEDUP" "" "MATCH;IGNORE" ${ARGN})
+ message("Known Variables:")
+ get_cmake_property(__variableNames VARIABLES)
+ list (SORT __variableNames)
+ if (__arg_DEDUP)
+ list(REMOVE_DUPLICATES __variableNames)
+ endif()
+
+ foreach(__var ${__variableNames})
+ set(__ignore OFF)
+ foreach(__i ${__arg_IGNORE})
+ if(__var MATCHES "${__i}")
+ set(__ignore ON)
+ break()
+ endif()
+ endforeach()
+
+ if (__ignore)
+ continue()
+ endif()
+
+ set(__show OFF)
+ foreach(__i ${__arg_MATCH})
+ if(__var MATCHES "${__i}")
+ set(__show ON)
+ break()
+ endif()
+ endforeach()
+
+ if (__show)
+ message(" ${__var}=${${__var}}.")
+ endif()
+ endforeach()
+endmacro()
+
+
+macro(assert)
+ if (${ARGN})
+ else()
+ message(FATAL_ERROR "ASSERT: ${ARGN}.")
+ endif()
+endmacro()
+
+
+function(qt_create_nolink_target target dependee_target)
+ if(NOT TARGET "${target}")
+ message(FATAL_ERROR "${target} does not exist when trying to build a nolink target.")
+ endif()
+ get_target_property(type "${target}" TYPE)
+ if(type STREQUAL EXECUTABLE)
+ message(FATAL_ERROR "${target} must be a library of some kind.")
+ endif()
+ if(type STREQUAL OBJECT_LIBRARY)
+ message(FATAL_ERROR "${target} must not be an object library.")
+ endif()
+
+ # Strip off the namespace prefix, so from Vulkan::Vulkan to Vulkan, and then append _nolink.
+ string(REGEX REPLACE "^.*::" "" non_prefixed_target ${target})
+ set(nolink_target "${non_prefixed_target}_nolink")
+
+ # Create the nolink interface target, assign the properties from the original target,
+ # associate the nolink target with the same export which contains
+ # the target that uses the _nolink target.
+ # Also create a namespaced alias of the form ${target}::${target}_nolink which is used by
+ # our modules.
+ # Also create a Qt namespaced alias target, because when exporting via install(EXPORT)
+ # Vulkan::Vulkan_nolink transforms into Qt6::Vulkan_nolink, and the latter needs to be an
+ # accessible alias for standalone tests.
+ if(NOT TARGET "${nolink_target}")
+ add_library("${nolink_target}" INTERFACE)
+ set(prefixed_nolink_target "${target}_nolink")
+ set_target_properties("${nolink_target}" PROPERTIES
+ INTERFACE_INCLUDE_DIRECTORIES
+ $<TARGET_PROPERTY:${target},INTERFACE_INCLUDE_DIRECTORIES>
+ INTERFACE_SYSTEM_INCLUDE_DIRECTORIES
+ $<TARGET_PROPERTY:${target},INTERFACE_SYSTEM_INCLUDE_DIRECTORIES>
+ INTERFACE_COMPILE_DEFINITIONS
+ $<TARGET_PROPERTY:${target},INTERFACE_COMPILE_DEFINITIONS>
+ INTERFACE_COMPILE_OPTIONS
+ $<TARGET_PROPERTY:${target},INTERFACE_COMPILE_OPTIONS>
+ INTERFACE_COMPILE_FEATURES
+ $<TARGET_PROPERTY:${target},INTERFACE_COMPILE_FEATURES>)
+
+ add_library(${prefixed_nolink_target} ALIAS ${nolink_target})
+ add_library("${INSTALL_CMAKE_NAMESPACE}::${nolink_target}" ALIAS ${nolink_target})
+
+ set(export_name "${INSTALL_CMAKE_NAMESPACE}${dependee_target}Targets")
+ qt_install(TARGETS ${nolink_target} EXPORT ${export_name})
+ endif()
+endfunction()
+
+function(qt_ensure_perl)
+ if(DEFINED HOST_PERL)
+ return()
+ endif()
+ find_program(HOST_PERL "perl" DOC "Perl binary")
+ if (NOT HOST_PERL)
+ message(FATAL_ERROR "Perl needs to be available to build Qt.")
+ endif()
+endfunction()
+
+
+function(qt_ensure_sync_qt)
+ qt_ensure_perl()
+ if(DEFINED QT_SYNCQT)
+ return()
+ endif()
+
+ # When building qtbase, use the source syncqt, otherwise use the installed one.
+ set(SYNCQT_FROM_SOURCE "${QtBase_SOURCE_DIR}/bin/syncqt.pl")
+ if(NOT ("${QtBase_SOURCE_DIR}" STREQUAL "") AND EXISTS "${SYNCQT_FROM_SOURCE}")
+ set(QT_SYNCQT "${SYNCQT_FROM_SOURCE}" CACHE FILEPATH "syncqt script")
+ message(STATUS "Using source syncqt found at: ${QT_SYNCQT}")
+
+ qt_path_join(syncqt_install_dir ${QT_INSTALL_DIR} ${INSTALL_LIBEXECDIR})
+ qt_copy_or_install(PROGRAMS "${SYNCQT_FROM_SOURCE}"
+ DESTINATION "${syncqt_install_dir}")
+ else()
+ get_filename_component(syncqt_absolute_path
+ "${CMAKE_INSTALL_PREFIX}/${INSTALL_LIBEXECDIR}/syncqt.pl"
+ ABSOLUTE)
+ set(QT_SYNCQT "${syncqt_absolute_path}" CACHE FILEPATH "syncqt script")
+ message(STATUS "Using installed syncqt found at: ${QT_SYNCQT}")
+ endif()
+endfunction()
+
+# A version of cmake_parse_arguments that makes sure all arguments are processed and errors out
+# with a message about ${type} having received unknown arguments.
+macro(qt_parse_all_arguments result type flags options multiopts)
+ cmake_parse_arguments(${result} "${flags}" "${options}" "${multiopts}" ${ARGN})
+ if(DEFINED ${result}_UNPARSED_ARGUMENTS)
+ message(FATAL_ERROR "Unknown arguments were passed to ${type} (${${result}_UNPARSED_ARGUMENTS}).")
+ endif()
+endmacro()
+
+include(CheckCXXSourceCompiles)
+
+function(qt_internal_add_link_flags_no_undefined target)
+ if (NOT QT_BUILD_SHARED_LIBS)
+ return()
+ endif()
+ if (GCC OR CLANG)
+ set(previous_CMAKE_REQUIRED_LINK_OPTIONS ${CMAKE_REQUIRED_LINK_OPTIONS})
+
+ set(CMAKE_REQUIRED_LINK_OPTIONS "-Wl,-undefined,error")
+ check_cxx_source_compiles("int main() {}" HAVE_DASH_UNDEFINED_ERROR)
+ if(HAVE_DASH_UNDEFINED_ERROR)
+ set(no_undefined_flag "-Wl,-undefined,error")
+ endif()
+
+ set(CMAKE_REQUIRED_LINK_OPTIONS "-Wl,--no-undefined")
+ check_cxx_source_compiles("int main() {}" HAVE_DASH_DASH_NO_UNDEFINED)
+ if(HAVE_DASH_DASH_NO_UNDEFINED)
+ set(no_undefined_flag "-Wl,--no-undefined")
+ endif()
+
+ set(CMAKE_REQUIRED_LINK_OPTIONS ${previous_CMAKE_REQUIRED_LINK_OPTIONS})
+
+ if (NOT HAVE_DASH_UNDEFINED_ERROR AND NOT HAVE_DASH_DASH_NO_UNDEFINED)
+ message(FATAL_ERROR "Platform linker doesn't support erroring upon encountering undefined symbols. Target:\"${target}\".")
+ endif()
+ target_link_options("${target}" PRIVATE "${no_undefined_flag}")
+ endif()
+endfunction()
+
+function(qt_internal_add_link_flags_gc_sections target visibility)
+ set(possible_visibilities PRIVATE INTERFACE PUBLIC)
+ list(FIND possible_visibilities "${visibility}" known_visibility)
+ if (known_visibility EQUAL "-1")
+ message(FATAL_ERROR "Visibitily setting must be one of PRIVATE, INTERFACE or PUBLIC.")
+ endif()
+
+ if ((GCC OR CLANG) AND NOT EMSCRIPTEN)
+ if(APPLE)
+ set(gc_sections_flag "-Wl,-dead_strip")
+ elseif(LINUX OR BSD OR SOLARIS OR WIN32 OR ANDROID)
+ set(gc_sections_flag "-Wl,--gc-sections")
+ else()
+ message(FATAL_ERROR "Platform linker doesn't support gc sections. Target:\"${target}\".")
+ endif()
+ target_link_options("${target}" ${visibility} "${gc_sections_flag}")
+ endif()
+endfunction()
+
+function(qt_internal_add_linker_version_script target)
+ qt_parse_all_arguments(arg "qt_internal_add_linker" "INTERNAL" "" "PRIVATE_HEADERS" ${ARGN})
+
+ if (TEST_ld_version_script)
+ if (arg_INTERNAL)
+ set(contents "Qt_${PROJECT_VERSION_MAJOR}_PRIVATE_API { *; };")
+ else()
+ set(contents "Qt_${PROJECT_VERSION_MAJOR}_PRIVATE_API {\n qt_private_api_tag*;\n")
+ foreach(ph ${arg_PRIVATE_HEADERS})
+ string(APPEND contents " @FILE:${ph}@\n")
+ endforeach()
+ string(APPEND contents "};\n")
+ set(current "Qt_${PROJECT_VERSION_MAJOR}")
+ if (QT_NAMESPACE STREQUAL "")
+ set(tag_symbol "qt_version_tag")
+ else()
+ set(tag_symbol "qt_version_tag_${QT_NAMESPACE}")
+ endif()
+ string(APPEND contents "${current} { *; };\n")
+
+ foreach(minor_version RANGE ${PROJECT_VERSION_MINOR})
+ set(previous "${current}")
+ set(current "Qt_${PROJECT_VERSION_MAJOR}.${minor_version}")
+ if (minor_version EQUAL ${PROJECT_VERSION_MINOR})
+ string(APPEND contents "${current} { ${tag_symbol}; } ${previous};\n")
+ else()
+ string(APPEND contents "${current} {} ${previous};\n")
+ endif()
+ endforeach()
+
+ set(infile "${CMAKE_CURRENT_BINARY_DIR}/${target}.version.in")
+ set(outfile "${CMAKE_CURRENT_BINARY_DIR}/${target}.version")
+
+ file(GENERATE OUTPUT "${infile}" CONTENT "${contents}")
+
+ qt_ensure_perl()
+
+ add_custom_command(TARGET "${target}" PRE_LINK
+ COMMAND "${HOST_PERL}" "${QT_MKSPECS_DIR}/features/data/unix/findclasslist.pl" < "${infile}" > "${outfile}"
+ BYPRODUCTS "${outfile}" DEPENDS "${infile}"
+ WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}"
+ COMMENT "Generating version linker script"
+ )
+ target_link_options("${target}" PRIVATE "-Wl,--version-script,${outfile}")
+ endif()
+ endif()
+endfunction()
+
+
+# Get a set of Qt module related values based on the target name.
+# When doing qt_internal_module_info(foo Core) this method will set
+# the following variables in the caller's scope:
+# * foo with the value "QtCore"
+# * foo_versioned with the value "Qt6Core" (based on major Qt version)
+# * foo_upper with the value "CORE"
+# * foo_lower with the value "core"
+# * foo_repo_include_dir with the module's include directory
+# e.g for QtQuick it would be qtdeclarative_build_dir/include for a prefix build or
+# qtbase_build_dir/include for a non-prefix build
+# * foo_include_dir with the module's include directory
+# e.g for QtQuick it would be qtdeclarative_build_dir/include/QtQuick for a prefix build or
+# qtbase_build_dir/include/QtQuick for a non-prefix build
+# * foo_define same as foo_uper but with - replaced as _
+function(qt_internal_module_info result target)
+ set(module "Qt${target}")
+ set("${result}" "${module}" PARENT_SCOPE)
+ set("${result}_versioned" "Qt${PROJECT_VERSION_MAJOR}${target}" PARENT_SCOPE)
+ string(TOUPPER "${target}" upper)
+ string(TOLOWER "${target}" lower)# * foo_upper with the value "CORE"
+ string(REPLACE "-" "_" define "${upper}")
+ string(REPLACE "." "_" define "${define}")
+ set("${result}_upper" "${upper}" PARENT_SCOPE)
+ set("${result}_lower" "${lower}" PARENT_SCOPE)
+ set("${result}_repo_include_dir" "${QT_BUILD_DIR}/include" PARENT_SCOPE)
+ set("${result}_include_dir" "${QT_BUILD_DIR}/include/${module}" PARENT_SCOPE)
+ set("${result}_define" "${define}" PARENT_SCOPE)
+endfunction()
+
+
+set(__default_private_args "SOURCES;LIBRARIES;INCLUDE_DIRECTORIES;DEFINES;DBUS_ADAPTOR_BASENAME;DBUS_ADAPTOR_FLAGS;DBUS_ADAPTOR_SOURCES;DBUS_INTERFACE_BASENAME;DBUS_INTERFACE_FLAGS;DBUS_INTERFACE_SOURCES;FEATURE_DEPENDENCIES;COMPILE_OPTIONS;LINK_OPTIONS;MOC_OPTIONS;DISABLE_AUTOGEN_TOOLS;ENABLE_AUTOGEN_TOOLS;PLUGIN_TYPES")
+
+set(__default_public_args "PUBLIC_LIBRARIES;PUBLIC_INCLUDE_DIRECTORIES;PUBLIC_DEFINES;PUBLIC_COMPILE_OPTIONS;PUBLIC_LINK_OPTIONS")
+
+
+option(QT_CMAKE_DEBUG_EXTEND_TARGET "Debug extend_target calls in Qt's build system" OFF)
+
+# Initial autogen setup for a target to specify certain CMake properties which are common
+# to all autogen tools. Also enable AUTOMOC by default.
+function(qt_autogen_tools_initial_setup target)
+ set_property(TARGET "${target}" PROPERTY INTERFACE_QT_MAJOR_VERSION ${PROJECT_VERSION_MAJOR})
+ set_property(TARGET "${target}" APPEND PROPERTY COMPATIBLE_INTERFACE_STRING QT_MAJOR_VERSION)
+
+ set_directory_properties(PROPERTIES
+ QT_VERSION_MAJOR ${PROJECT_VERSION_MAJOR}
+ QT_VERSION_MINOR ${PROJECT_VERSION_MINOR}
+ QT_VERSION_PATCH ${PROJECT_VERSION_PATCH}
+ )
+
+ qt_enable_autogen_tool(${target} "moc" ON)
+endfunction()
+
+# Enables or disables an autogen tool like moc, uic or rcc on ${target}.
+function(qt_enable_autogen_tool target tool enable)
+ string(TOUPPER "${tool}" captitalAutogenTool)
+
+ get_target_property(tool_enabled ${target} AUTO${captitalAutogenTool})
+ get_target_property(autogen_target_depends ${target} AUTOGEN_TARGET_DEPENDS)
+
+ if(NOT autogen_target_depends)
+ set(autogen_target_depends "")
+ endif()
+ set(tool_executable "$<TARGET_FILE:${QT_CMAKE_EXPORT_NAMESPACE}::${tool}>")
+ set(tool_target_name ${QT_CMAKE_EXPORT_NAMESPACE}::${tool})
+
+ if(enable)
+ list(APPEND autogen_target_depends ${tool_target_name})
+ else()
+ list(REMOVE_ITEM autogen_target_depends ${tool_target_name})
+ endif()
+
+ # f66c1db16c050c9d685a44a38ad7c5cf9f6fcc96 in qtbase introduced a new macro
+ # that the moc scanner has to look for. Inform the CMake moc scanner about it.
+ if(tool STREQUAL "moc" AND enable)
+ set_target_properties("${target}" PROPERTIES
+ AUTOMOC_MACRO_NAMES "Q_OBJECT;Q_GADGET;Q_NAMESPACE;Q_NAMESPACE_EXPORT;Q_ENUM_NS")
+ endif()
+
+ set_target_properties("${target}"
+ PROPERTIES
+ AUTO${captitalAutogenTool} "${enable}"
+ AUTO${captitalAutogenTool}_EXECUTABLE "${tool_executable}"
+ AUTOGEN_TARGET_DEPENDS "${autogen_target_depends}"
+ )
+endfunction()
+
+# This function adds or removes additional AUTOGEN tools to a target: AUTOMOC/UIC/RCC
+function(qt_autogen_tools target)
+ qt_parse_all_arguments(arg "qt_autogen_tools" "" "" "${__default_private_args}" ${ARGN})
+
+ if (arg_ENABLE_AUTOGEN_TOOLS)
+ foreach(tool ${arg_ENABLE_AUTOGEN_TOOLS})
+ qt_enable_autogen_tool(${target} ${tool} ON)
+ endforeach()
+ endif()
+
+ if (arg_DISABLE_AUTOGEN_TOOLS)
+ foreach(tool ${arg_DISABLE_AUTOGEN_TOOLS})
+ qt_enable_autogen_tool(${target} ${tool} OFF)
+ endforeach()
+ endif()
+endfunction()
+
+# This function stores the list of Qt modules a library depend on,
+# along with their version info, for usage in ${target}Depends.cmake file
+function(qt_register_target_dependencies target public_libs private_libs)
+ get_target_property(target_deps "${target}" _qt_target_deps)
+ if(NOT target_deps)
+ set(target_deps "")
+ endif()
+
+ foreach(lib IN LISTS public_libs private_libs)
+ if ("${lib}" MATCHES "^Qt::(.*)")
+ set(lib "${CMAKE_MATCH_1}")
+ if (lib STREQUAL Platform
+ OR lib STREQUAL GlobalConfig
+ OR lib STREQUAL GlobalConfigPrivate
+ OR lib STREQUAL PlatformModuleInternal
+ OR lib STREQUAL PlatformPluginInternal
+ OR lib STREQUAL PlatformToolInternal)
+ list(APPEND target_deps "Qt6\;${PROJECT_VERSION}")
+ elseif ("${lib}" MATCHES "(.*)Private")
+ list(APPEND target_deps "${INSTALL_CMAKE_NAMESPACE}${CMAKE_MATCH_1}\;${PROJECT_VERSION}")
+ else()
+ list(APPEND target_deps "${INSTALL_CMAKE_NAMESPACE}${lib}\;${PROJECT_VERSION}")
+ endif()
+ endif()
+ endforeach()
+
+ set_target_properties("${target}" PROPERTIES _qt_target_deps "${target_deps}")
+endfunction()
+
+function(qt_update_precompiled_header target precompiled_header)
+ if (precompiled_header AND BUILD_WITH_PCH)
+ set_property(TARGET "${target}" APPEND PROPERTY "PRECOMPILE_HEADERS" "$<$<COMPILE_LANGUAGE:CXX>:${precompiled_header}>")
+ endif()
+endfunction()
+
+function(qt_update_precompiled_header_with_library target library)
+ if (TARGET "${library}")
+ get_target_property(TARGET_TYPE "${library}" TYPE)
+ if (NOT TARGET_TYPE STREQUAL "INTERFACE_LIBRARY")
+ get_target_property(HEADER "${library}" MODULE_HEADER)
+ qt_update_precompiled_header("${target}" "${HEADER}")
+ endif()
+ endif()
+endfunction()
+
+function(qt_update_ignore_pch_source target sources)
+ if (sources)
+ set_source_files_properties(${sources} PROPERTIES SKIP_PRECOMPILE_HEADERS ON)
+ endif()
+endfunction()
+
+function(qt_ignore_pch_obj_c_sources target sources)
+ list(FILTER sources INCLUDE REGEX "\\.mm$")
+ qt_update_ignore_pch_source("${target}" "${sources}")
+endfunction()
+
+# This function can be used to add sources/libraries/etc. to the specified CMake target
+# if the provided CONDITION evaluates to true.
+function(qt_extend_target target)
+ # Don't try to extend_target when cross compiling an imported host target (like a tool).
+ qt_is_imported_target("${target}" is_imported)
+ if(is_imported)
+ return()
+ endif()
+
+ if (NOT TARGET "${target}")
+ message(FATAL_ERROR "Trying to extend non-existing target \"${target}\".")
+ endif()
+ qt_parse_all_arguments(arg "qt_extend_target" "HEADER_MODULE" "PRECOMPILED_HEADER"
+ "CONDITION;${__default_public_args};${__default_private_args};COMPILE_FLAGS;NO_PCH_SOURCES" ${ARGN})
+ if ("x${arg_CONDITION}" STREQUAL x)
+ set(arg_CONDITION ON)
+ endif()
+
+ qt_evaluate_config_expression(result ${arg_CONDITION})
+ if (${result})
+ if(QT_CMAKE_DEBUG_EXTEND_TARGET)
+ message("qt_extend_target(${target} CONDITION ${arg_CONDITION} ...): Evaluated")
+ endif()
+ set(dbus_sources "")
+ foreach(adaptor ${arg_DBUS_ADAPTOR_SOURCES})
+ qt_create_qdbusxml2cpp_command("${target}" "${adaptor}" ADAPTOR BASENAME "${arg_DBUS_ADAPTOR_BASENAME}" FLAGS "${arg_DBUS_ADAPTOR_FLAGS}")
+ list(APPEND dbus_sources "${sources}")
+ endforeach()
+
+ foreach(interface ${arg_DBUS_INTERFACE_SOURCES})
+ qt_create_qdbusxml2cpp_command("${target}" "${interface}" INTERFACE BASENAME "${arg_DBUS_INTERFACE_BASENAME}" FLAGS "${arg_DBUS_INTERFACE_FLAGS}")
+ list(APPEND dbus_sources "${sources}")
+ endforeach()
+
+ get_target_property(target_type ${target} TYPE)
+ set(is_library FALSE)
+ if (${target_type} STREQUAL "STATIC_LIBRARY" OR ${target_type} STREQUAL "SHARED_LIBRARY")
+ set(is_library TRUE)
+ endif()
+ foreach(lib ${arg_PUBLIC_LIBRARIES} ${arg_LIBRARIES})
+ # Automatically generate PCH for 'target' using dependencies
+ # if 'target' is a library/module!
+ if (${is_library})
+ qt_update_precompiled_header_with_library("${target}" "${lib}")
+ endif()
+
+ string(REGEX REPLACE "_nolink$" "" base_lib "${lib}")
+ if(NOT base_lib STREQUAL lib)
+ qt_create_nolink_target("${base_lib}" ${target})
+ endif()
+ endforeach()
+
+ # Find dependencies to internal libraries
+ get_target_property(target_deps "${target}" _qt_target_deps)
+ if(NOT target_deps)
+ set(target_deps "")
+ endif()
+
+ foreach(lib ${arg_LIBRARIES})
+ if (TARGET "${lib}")
+ get_target_property(_is_exported "${lib}" INTERFACE_QT_EXPORTED_LIBRARY)
+ if("${_is_exported}")
+ list(APPEND target_deps "${lib}\;${PROJECT_VERSION}")
+ endif()
+ endif()
+ endforeach()
+ # Set-up the target
+ target_sources("${target}" PRIVATE ${arg_SOURCES} ${dbus_sources})
+ if (arg_COMPILE_FLAGS)
+ set_source_files_properties(${arg_SOURCES} PROPERTIES COMPILE_FLAGS "${arg_COMPILE_FLAGS}")
+ endif()
+
+ set(public_visibility_option "PUBLIC")
+ set(private_visibility_option "PRIVATE")
+ if(arg_HEADER_MODULE)
+ set(public_visibility_option "INTERFACE")
+ set(private_visibility_option "INTERFACE")
+ endif()
+ target_include_directories("${target}"
+ ${public_visibility_option} ${arg_PUBLIC_INCLUDE_DIRECTORIES}
+ ${private_visibility_option} ${arg_INCLUDE_DIRECTORIES})
+ target_compile_definitions("${target}"
+ ${public_visibility_option} ${arg_PUBLIC_DEFINES}
+ ${private_visibility_option} ${arg_DEFINES})
+ target_link_libraries("${target}"
+ ${public_visibility_option} ${arg_PUBLIC_LIBRARIES}
+ ${private_visibility_option} ${arg_LIBRARIES})
+ target_compile_options("${target}"
+ ${public_visibility_option} ${arg_PUBLIC_COMPILE_OPTIONS}
+ ${private_visibility_option} ${arg_COMPILE_OPTIONS})
+ target_link_options("${target}"
+ ${public_visibility_option} ${arg_PUBLIC_LINK_OPTIONS}
+ ${private_visibility_option} ${arg_LINK_OPTIONS})
+
+ if(NOT arg_HEADER_MODULE)
+ list(APPEND arg_MOC_OPTIONS "--output-json")
+ set_target_properties("${target}" PROPERTIES
+ AUTOMOC_MOC_OPTIONS "${arg_MOC_OPTIONS}"
+ _qt_target_deps "${target_deps}"
+ )
+ endif()
+
+ # When computing the private library dependencies, we need to check not only the known
+ # modules added by this repo's qt_build_repo(), but also all module dependencies that
+ # were found via find_package().
+ qt_internal_get_qt_all_known_modules(known_modules)
+
+ # When a public module depends on a private module (Gui on CorePrivate)
+ # make its private module depend on the other private module (GuiPrivate will depend on
+ # CorePrivate).
+ set(qt_libs_private "")
+ foreach(it ${known_modules})
+ list(FIND arg_LIBRARIES "Qt::${it}Private" pos)
+ if(pos GREATER -1)
+ list(APPEND qt_libs_private "Qt::${it}Private")
+ endif()
+ endforeach()
+
+ set(target_private "${target}Private")
+ if(TARGET "${target_private}")
+ target_link_libraries("${target_private}" INTERFACE "${target}" "${qt_libs_private}")
+ endif()
+ qt_register_target_dependencies("${target}"
+ "${arg_PUBLIC_LIBRARIES}"
+ "${qt_libs_private};${arg_LIBRARIES}")
+
+
+ qt_autogen_tools(${target}
+ ENABLE_AUTOGEN_TOOLS ${arg_ENABLE_AUTOGEN_TOOLS}
+ DISABLE_AUTOGEN_TOOLS ${arg_DISABLE_AUTOGEN_TOOLS})
+
+ qt_update_precompiled_header("${target}" "${arg_PRECOMPILED_HEADER}")
+ qt_update_ignore_pch_source("${target}" "${arg_NO_PCH_SOURCES}")
+ ## Ignore objective-c files for PCH (not supported atm)
+ qt_ignore_pch_obj_c_sources("${target}" "${arg_SOURCES}")
+
+ else()
+ if(QT_CMAKE_DEBUG_EXTEND_TARGET)
+ message("qt_extend_target(${target} CONDITION ${arg_CONDITION} ...): Skipped")
+ endif()
+ endif()
+endfunction()
+
+
+function(qt_internal_library_deprecation_level result)
+ if(WIN32)
+ # On Windows, due to the way DLLs work, we need to export all functions,
+ # including the inlines
+ list(APPEND deprecations "QT_DISABLE_DEPRECATED_BEFORE=0x040800")
+ else()
+ # On other platforms, Qt's own compilation goes needs to compile the Qt 5.0 API
+ list(APPEND deprecations "QT_DISABLE_DEPRECATED_BEFORE=0x050000")
+ endif()
+ list(APPEND deprecations "QT_DEPRECATED_WARNINGS_SINCE=0x060000")
+ set("${result}" deprecations PARENT_SCOPE)
+endfunction()
+
+
+function(qt_install_injections target build_dir install_dir)
+ set(injections ${ARGN})
+ set(module "Qt${target}")
+ get_target_property(target_type ${target} TYPE)
+ if (target_type STREQUAL "INTERFACE_LIBRARY")
+ set(is_framework FALSE)
+ else()
+ get_target_property(is_framework ${target} FRAMEWORK)
+ endif()
+ # examples:
+ # SYNCQT.INJECTIONS = src/corelib/global/qconfig.h:qconfig.h:QtConfig src/corelib/global/qconfig_p.h:5.12.0/QtCore/private/qconfig_p.h
+ # SYNCQT.INJECTIONS = src/gui/vulkan/qvulkanfunctions.h:^qvulkanfunctions.h:QVulkanFunctions:QVulkanDeviceFunctions src/gui/vulkan/qvulkanfunctions_p.h:^5.12.0/QtGui/private/qvulkanfunctions_p.h
+ # The are 3 parts to the assignment, divded by colons ':'.
+ # The first part contains a path to a generated file in a build folder.
+ # The second part contains the file name that the forwarding header should have, which points
+ # to the file in the first part.
+ # The third part contains multiple UpperCaseFileNames that should be forwarding headers to the
+ # header specified in the second part.
+ separate_arguments(injections UNIX_COMMAND "${injections}")
+ foreach(injection ${injections})
+ string(REPLACE ":" ";" injection ${injection})
+ # Part 1.
+ list(GET injection 0 file)
+ # Part 2.
+ list(GET injection 1 destination)
+ string(REGEX REPLACE "^\\^" "" destination "${destination}")
+ list(REMOVE_AT injection 0 1)
+ # Part 3.
+ set(fwd_hdrs ${injection})
+ get_filename_component(destinationdir ${destination} DIRECTORY)
+ get_filename_component(destinationname ${destination} NAME)
+ get_filename_component(original_file_name ${file} NAME)
+
+ # This describes a concrete example for easier comprehension:
+ # A file 'qtqml-config.h' is generated by qt_internal_feature_write_file into
+ # ${qtdeclarative_build_dir}/src/{module}/qtqml-config.h (part 1).
+ #
+ # Generate a lower case forwarding header (part 2) 'qtqml-config.h' at the following
+ # location:
+ # ${some_prefix}/include/${module}/qtqml-config.h.
+ #
+ # Inside this file, we #include the originally generated file,
+ # ${qtdeclarative_build_dir}/src/{module}/qtqml-config.h.
+ #
+ # ${some_prefix}'s value depends on the build type.
+ # If doing a prefix build, it should point to
+ # ${current_repo_build_dir} which is ${qtdeclarative_build_dir}.
+ # If doing a non-prefix build, it should point to
+ # ${qtbase_build_dir}.
+ #
+ # In the code below, ${some_prefix} == ${build_dir}.
+ set(lower_case_forwarding_header_path "${build_dir}/${INSTALL_INCLUDEDIR}/${module}")
+ if(destinationdir)
+ string(APPEND lower_case_forwarding_header_path "/${destinationdir}")
+ endif()
+ set(current_repo_build_dir "${PROJECT_BINARY_DIR}")
+
+ file(RELATIVE_PATH relpath
+ "${lower_case_forwarding_header_path}"
+ "${current_repo_build_dir}/${file}")
+ set(main_contents "#include \"${relpath}\"")
+ file(GENERATE OUTPUT "${lower_case_forwarding_header_path}/${original_file_name}"
+ CONTENT "${main_contents}")
+
+ if(is_framework)
+ if(file MATCHES "_p\\.h$")
+ set(header_type PRIVATE)
+ else()
+ set(header_type PUBLIC)
+ endif()
+ qt_copy_framework_headers(${target} ${header_type}
+ ${current_repo_build_dir}/${file})
+ else()
+ # Copy the actual injected (generated) header file (not the just created forwarding one)
+ # to its install location when doing a prefix build. In an non-prefix build, the qt_install
+ # will be a no-op.
+ qt_path_join(install_destination
+ ${install_dir} ${INSTALL_INCLUDEDIR} ${module} ${destinationdir})
+ qt_install(FILES ${current_repo_build_dir}/${file}
+ DESTINATION ${install_destination}
+ RENAME ${destinationname} OPTIONAL)
+ endif()
+
+ # Generate UpperCaseNamed forwarding headers (part 3).
+ foreach(fwd_hdr ${fwd_hdrs})
+ set(upper_case_forwarding_header_path "${INSTALL_INCLUDEDIR}/${module}")
+ if(destinationdir)
+ string(APPEND upper_case_forwarding_header_path "/${destinationdir}")
+ endif()
+
+ # Generate upper case forwarding header like QVulkanFunctions or QtConfig.
+ file(GENERATE OUTPUT "${build_dir}/${upper_case_forwarding_header_path}/${fwd_hdr}"
+ CONTENT "#include \"${destinationname}\"\n")
+
+ if(is_framework)
+ # Copy the forwarding header to the framework's Headers directory.
+ qt_copy_framework_headers(${target} PUBLIC
+ "${build_dir}/${upper_case_forwarding_header_path}/${fwd_hdr}")
+ else()
+ # Install the forwarding header.
+ qt_path_join(install_destination
+ ${install_dir} ${upper_case_forwarding_header_path})
+ qt_install(FILES "${build_dir}/${upper_case_forwarding_header_path}/${fwd_hdr}"
+ DESTINATION ${install_destination} OPTIONAL)
+ endif()
+ endforeach()
+ endforeach()
+endfunction()
+
+
+function(qt_read_headers_pri target resultVarPrefix)
+ qt_internal_module_info(module "${target}")
+ file(STRINGS "${module_include_dir}/headers.pri" headers_pri_contents)
+ foreach(line ${headers_pri_contents})
+ if("${line}" MATCHES "SYNCQT.HEADER_FILES = (.*)")
+ set(public_module_headers "${CMAKE_MATCH_1}")
+ separate_arguments(public_module_headers UNIX_COMMAND "${public_module_headers}")
+ elseif("${line}" MATCHES "SYNCQT.PRIVATE_HEADER_FILES = (.*)")
+ set(private_module_headers "${CMAKE_MATCH_1}")
+ separate_arguments(private_module_headers UNIX_COMMAND "${private_module_headers}")
+ elseif("${line}" MATCHES "SYNCQT.GENERATED_HEADER_FILES = (.*)")
+ set(generated_module_headers "${CMAKE_MATCH_1}")
+ separate_arguments(generated_module_headers UNIX_COMMAND "${generated_module_headers}")
+ foreach(generated_header ${generated_module_headers})
+ list(APPEND public_module_headers "${module_include_dir}/${generated_header}")
+ endforeach()
+ elseif("${line}" MATCHES "SYNCQT.INJECTIONS = (.*)")
+ set(injections "${CMAKE_MATCH_1}")
+ elseif("${line}" MATCHES "SYNCQT.([A-Z_]+)_HEADER_FILES = (.+)")
+ set(prefix "${CMAKE_MATCH_1}")
+ string(TOLOWER "${prefix}" prefix)
+ set(entries "${CMAKE_MATCH_2}")
+ separate_arguments(entries UNIX_COMMAND "${entries}")
+ set("${resultVarPrefix}_${prefix}" "${entries}" PARENT_SCOPE)
+ endif()
+ endforeach()
+ set(${resultVarPrefix}_public "${public_module_headers}" PARENT_SCOPE)
+ set(${resultVarPrefix}_private "${private_module_headers}" PARENT_SCOPE)
+ set(${resultVarPrefix}_injections "${injections}" PARENT_SCOPE)
+endfunction()
+
+
+# Add Qt::target and Qt6::target as aliases for the target
+function(qt_internal_add_target_aliases target)
+ get_target_property(type "${target}" TYPE)
+ if (type STREQUAL EXECUTABLE)
+ add_executable("Qt::${target}" ALIAS "${target}")
+ add_executable("Qt${PROJECT_VERSION_MAJOR}::${target}" ALIAS "${target}")
+ else()
+ add_library("Qt::${target}" ALIAS "${target}")
+ add_library("Qt${PROJECT_VERSION_MAJOR}::${target}" ALIAS "${target}")
+ endif()
+endfunction()
+
+# Sets the exceptions flags for the given target
+function(qt_internal_set_no_exceptions_flags target)
+ target_compile_definitions("${target}" PRIVATE "QT_NO_EXCEPTIONS")
+ if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "MSVC")
+ target_compile_options("${target}" PRIVATE "/wd4530" "/wd4577")
+ elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
+ target_compile_options("${target}" PRIVATE "-fno-exceptions")
+ elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "AppleClang")
+ target_compile_options("${target}" PRIVATE "-fno-exceptions")
+ elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
+ target_compile_options("${target}" PRIVATE "-fno-exceptions")
+ elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Intel")
+ target_compile_options("${target}" PRIVATE "-fno-exceptions")
+ endif()
+endfunction()
+
+function(qt_skip_warnings_are_errors target)
+ get_target_property(target_type "${target}" TYPE)
+ if(target_type STREQUAL "INTERFACE_LIBRARY")
+ return()
+ endif()
+ set_target_properties("${target}" PROPERTIES QT_SKIP_WARNINGS_ARE_ERRORS ON)
+endfunction()
+
+function(qt_skip_warnings_are_errors_when_repo_unclean target)
+ if(QT_REPO_NOT_WARNINGS_CLEAN)
+ qt_skip_warnings_are_errors("${target}")
+ endif()
+endfunction()
+
+function(qt_get_sanitized_plugin_type plugin_type out_var)
+ # Used to handle some edge cases such as platforms/darwin
+ string(REGEX REPLACE "[-/]" "_" plugin_type "${plugin_type}")
+ set("${out_var}" "${plugin_type}" PARENT_SCOPE)
+endfunction()
+
+# Copy header files to QtXYZ.framework/Versions/6/Headers/
+# Use this function for header files that
+# - are not added as source files to the target
+# - are not marked as PUBLIC_HEADER
+# - or are private and supposed to end up in the 6.7.8/QtXYZ/private subdir.
+function(qt_copy_framework_headers target)
+ get_target_property(is_fw ${target} FRAMEWORK)
+ if(NOT "${is_fw}")
+ return()
+ endif()
+
+ set(options PUBLIC PRIVATE QPA)
+ set(oneValueArgs)
+ set(multiValueArgs)
+ cmake_parse_arguments(ARG "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN})
+
+ get_target_property(fw_version ${target} FRAMEWORK_VERSION)
+ get_target_property(fw_bundle_version ${target} MACOSX_FRAMEWORK_BUNDLE_VERSION)
+ get_target_property(fw_dir ${target} LIBRARY_OUTPUT_DIRECTORY)
+ get_target_property(fw_name ${target} OUTPUT_NAME)
+ set(fw_headers_dir ${fw_dir}/${fw_name}.framework/Versions/${fw_version}/Headers/)
+ if(ARG_PRIVATE)
+ string(APPEND fw_headers_dir "${fw_bundle_version}/Qt${target}/private/")
+ elseif(ARG_QPA)
+ string(APPEND fw_headers_dir "${fw_bundle_version}/Qt${target}/qpa/")
+ endif()
+
+ set(out_files)
+ foreach(hdr IN LISTS ARG_UNPARSED_ARGUMENTS)
+ get_filename_component(in_file_path ${hdr} ABSOLUTE)
+ get_filename_component(in_file_name ${hdr} NAME)
+ set(out_file_path ${fw_headers_dir}${in_file_name})
+ add_custom_command(
+ OUTPUT ${out_file_path}
+ DEPENDS ${in_file_path}
+ COMMAND ${CMAKE_COMMAND} -E make_directory "${fw_headers_dir}"
+ COMMAND ${CMAKE_COMMAND} -E copy "${in_file_path}" "${fw_headers_dir}")
+ list(APPEND out_files ${out_file_path})
+ endforeach()
+
+ get_target_property(fw_copied_headers ${target} QT_COPIED_FRAMEWORK_HEADERS)
+ if(NOT fw_copied_headers)
+ set(fw_copied_headers "")
+ endif()
+ list(APPEND fw_copied_headers ${out_files})
+ set_target_properties(${target} PROPERTIES QT_COPIED_FRAMEWORK_HEADERS "${fw_copied_headers}")
+endfunction()
+
+function(qt_finalize_framework_headers_copy target)
+ get_target_property(target_type ${target} TYPE)
+ if(${target_type} STREQUAL "INTERFACE_LIBRARY")
+ return()
+ endif()
+ get_target_property(is_fw ${target} FRAMEWORK)
+ if(NOT "${is_fw}")
+ return()
+ endif()
+ get_target_property(headers ${target} QT_COPIED_FRAMEWORK_HEADERS)
+ if(headers)
+ # Hack to create the "Headers" symlink in the framework:
+ # Create a fake header file and copy it into the framework by marking it as PUBLIC_HEADER.
+ # CMake now takes care of creating the symlink.
+ set(fake_header ${target}_fake_header.h)
+ file(GENERATE OUTPUT ${fake_header} CONTENT "// ignore this file\n")
+ string(PREPEND fake_header "${CMAKE_CURRENT_BINARY_DIR}/")
+ target_sources(${target} PRIVATE ${fake_header})
+ set_source_files_properties(${fake_header} PROPERTIES GENERATED ON)
+ set_property(TARGET ${target} APPEND PROPERTY PUBLIC_HEADER ${fake_header})
+
+ # Add a target, e.g. Core_framework_headers, that triggers the header copy.
+ add_custom_target(${target}_framework_headers DEPENDS ${headers})
+ add_dependencies(${target} ${target}_framework_headers)
+ endif()
+endfunction()
+
+# This is the main entry function for creating a Qt module, that typically
+# consists of a library, public header files, private header files and configurable
+# features.
+#
+# A CMake target with the specified target parameter is created. If the current source
+# directory has a configure.cmake file, then that is also processed for feature definition
+# and testing. Any features defined as well as any features coming from dependencies to
+# this module are imported into the scope of the calling feature.
+#
+# Target is without leading "Qt". So e.g. the "QtCore" module has the target "Core".
+function(qt_add_module target)
+ qt_internal_module_info(module "${target}")
+
+ # Process arguments:
+ qt_parse_all_arguments(arg "qt_add_module"
+ "NO_MODULE_HEADERS;STATIC;DISABLE_TOOLS_EXPORT;EXCEPTIONS;INTERNAL_MODULE;NO_SYNC_QT;NO_PRIVATE_MODULE;HEADER_MODULE;GENERATE_METATYPES"
+ "CONFIG_MODULE_NAME;PRECOMPILED_HEADER"
+ "${__default_private_args};${__default_public_args};QMAKE_MODULE_CONFIG;EXTRA_CMAKE_FILES;EXTRA_CMAKE_INCLUDES;NO_PCH_SOURCES" ${ARGN})
+
+ if(NOT DEFINED arg_CONFIG_MODULE_NAME)
+ set(arg_CONFIG_MODULE_NAME "${module_lower}")
+ endif()
+
+ qt_internal_add_qt_repo_known_module("${target}")
+
+ ### Define Targets:
+ set(is_interface_lib 0)
+ if(${arg_HEADER_MODULE})
+ add_library("${target}" INTERFACE)
+ set(is_interface_lib 1)
+ elseif(${arg_STATIC})
+ add_library("${target}" STATIC)
+ elseif(${QT_BUILD_SHARED_LIBS})
+ add_library("${target}" SHARED)
+ else()
+ add_library("${target}" STATIC)
+ endif()
+
+ set(is_framework 0)
+ if(QT_FEATURE_framework AND NOT ${arg_HEADER_MODULE} AND NOT ${arg_STATIC})
+ set(is_framework 1)
+ set_target_properties(${target} PROPERTIES
+ FRAMEWORK TRUE
+ FRAMEWORK_VERSION ${PROJECT_VERSION_MAJOR}
+ MACOSX_FRAMEWORK_IDENTIFIER org.qt-project.Qt${target}
+ MACOSX_FRAMEWORK_BUNDLE_VERSION ${PROJECT_VERSION}
+ MACOSX_FRAMEWORK_SHORT_VERSION_STRING ${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}
+ )
+ endif()
+
+ if (ANDROID)
+ qt_android_apply_arch_suffix("${target}")
+ endif()
+ qt_internal_add_target_aliases("${target}")
+ qt_skip_warnings_are_errors_when_repo_unclean("${target}")
+
+ # Add _private target to link against the private headers:
+ if(NOT ${arg_NO_PRIVATE_MODULE})
+ set(target_private "${target}Private")
+ add_library("${target_private}" INTERFACE)
+ qt_internal_add_target_aliases("${target_private}")
+ endif()
+
+ if(NOT arg_HEADER_MODULE)
+ set_target_properties(${target} PROPERTIES
+ LIBRARY_OUTPUT_DIRECTORY "${QT_BUILD_DIR}/${INSTALL_LIBDIR}"
+ RUNTIME_OUTPUT_DIRECTORY "${QT_BUILD_DIR}/${INSTALL_BINDIR}"
+ RUNTIME_OUTPUT_DIRECTORY_RELEASE "${QT_BUILD_DIR}/${INSTALL_BINDIR}"
+ RUNTIME_OUTPUT_DIRECTORY_DEBUG "${QT_BUILD_DIR}/${INSTALL_BINDIR}"
+ ARCHIVE_OUTPUT_DIRECTORY "${QT_BUILD_DIR}/${INSTALL_LIBDIR}"
+ VERSION ${PROJECT_VERSION}
+ SOVERSION ${PROJECT_VERSION_MAJOR}
+ )
+
+ if(is_framework)
+ set_target_properties(${target} PROPERTIES
+ OUTPUT_NAME Qt${target}
+ )
+ else()
+ set_target_properties(${target} PROPERTIES
+ OUTPUT_NAME "${INSTALL_CMAKE_NAMESPACE}${target}"
+ )
+ endif()
+ endif()
+
+ # Module headers:
+ if(${arg_NO_MODULE_HEADERS} OR ${arg_NO_SYNC_QT})
+ set_target_properties("${target}" PROPERTIES INTERFACE_MODULE_HAS_HEADERS OFF)
+ else()
+ # Use QT_BUILD_DIR for the syncqt call.
+ # So we either write the generated files into the qtbase non-prefix build root, or the
+ # module specific build root.
+ qt_ensure_sync_qt()
+ set(syncqt_full_command "${HOST_PERL}" -w "${QT_SYNCQT}"
+ -quiet
+ -check-includes
+ -module "${module}"
+ -version "${PROJECT_VERSION}"
+ -outdir "${QT_BUILD_DIR}"
+ -builddir "${PROJECT_BINARY_DIR}"
+ "${PROJECT_SOURCE_DIR}")
+ execute_process(COMMAND ${syncqt_full_command})
+
+ set_target_properties("${target}" PROPERTIES INTERFACE_MODULE_HAS_HEADERS ON)
+
+ ### FIXME: Can we replace headers.pri?
+ qt_read_headers_pri("${target}" "module_headers")
+ set(module_depends_header "${module_include_dir}/${module}Depends")
+ if(is_framework)
+ if(NOT is_interface_lib)
+ set(public_headers_to_copy "${module_headers_public}" "${module_depends_header}")
+ qt_copy_framework_headers(${target} PUBLIC "${public_headers_to_copy}")
+ qt_copy_framework_headers(${target} PRIVATE "${module_headers_private}")
+ endif()
+ else()
+ set_property(TARGET ${target} APPEND PROPERTY PUBLIC_HEADER "${module_headers_public}")
+ set_property(TARGET ${target} APPEND PROPERTY PUBLIC_HEADER ${module_depends_header})
+ set_property(TARGET ${target} APPEND PROPERTY PRIVATE_HEADER "${module_headers_private}")
+ endif()
+ if (NOT ${arg_HEADER_MODULE})
+ set_property(TARGET "${target}" PROPERTY MODULE_HEADER "${module_include_dir}/${module}")
+ endif()
+
+ if(module_headers_qpa)
+ if(is_framework)
+ qt_copy_framework_headers(${target} QPA "${module_headers_qpa}")
+ else()
+ qt_install(
+ FILES ${module_headers_qpa}
+ DESTINATION ${INSTALL_INCLUDEDIR}/${module}/${PROJECT_VERSION}/${module}/qpa)
+ endif()
+ endif()
+ endif()
+
+ if(NOT arg_HEADER_MODULE)
+ # This property is used for super builds with static libraries. We use
+ # it in QtPlugins.cmake.in to avoid "polluting" the dependency chain
+ # for the target in it's project directory.
+ # E.g: When we process find_package(Qt6 ... Gui) in QtDeclarative, the
+ # rules in QtPugins.cmake add all the known Gui plugins as interface
+ # dependencies. This in turn causes circular dependencies on every
+ # plugin which links against Gui. Plugin A -> GUI -> Plugin A ....
+
+ set_target_properties(${target} PROPERTIES QT_BUILD_PROJECT_NAME ${PROJECT_NAME})
+ # Plugin types associated to a module
+ if(NOT "x${arg_PLUGIN_TYPES}" STREQUAL "x")
+ # Reset the variable containing the list of plugins for the given plugin type
+ foreach(plugin_type ${arg_PLUGIN_TYPES})
+ qt_get_sanitized_plugin_type("${plugin_type}" plugin_type)
+ set_property(TARGET "${target}" APPEND PROPERTY MODULE_PLUGIN_TYPES "${plugin_type}")
+ qt_internal_add_qt_repo_known_plugin_types("${plugin_type}")
+ endforeach()
+ endif()
+ endif()
+
+ qt_internal_library_deprecation_level(deprecation_define)
+
+ if(NOT arg_HEADER_MODULE)
+ qt_autogen_tools_initial_setup(${target})
+ endif()
+
+ set(private_includes
+ "$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>"
+ "$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>"
+ ${arg_INCLUDE_DIRECTORIES}
+ )
+
+ set(public_includes "")
+ set(public_headers_list "public_includes")
+ if(is_framework)
+ set(public_headers_list "private_includes")
+ set(fw_bundle_subdir "${INSTALL_LIBDIR}/Qt${target}.framework")
+ set(fw_headers_subdir "Versions/${PROJECT_VERSION_MAJOR}/Headers")
+ list(APPEND public_includes
+ # Add the lib/Foo.framework dir as include path to let CMake generate
+ # the -F compiler flag.
+ "$<BUILD_INTERFACE:${QT_BUILD_DIR}/${fw_bundle_subdir}>"
+ "$<INSTALL_INTERFACE:${fw_bundle_subdir}>"
+
+ # Add the fully resolved Headers subdir, because the Headers symlink might
+ # not be there yet.
+ "$<BUILD_INTERFACE:${QT_BUILD_DIR}/${fw_bundle_subdir}/${fw_headers_subdir}>"
+
+ # After installing, the Headers symlink is guaranteed to exist.
+ "$<INSTALL_INTERFACE:${fw_bundle_subdir}/Headers>"
+ )
+ endif()
+
+ # Handle cases like QmlDevTools which do not have their own headers, but rather borrow them
+ # from another module.
+ if(NOT arg_NO_SYNC_QT AND NOT arg_NO_MODULE_HEADERS)
+ # Don't include private headers unless they exist, aka syncqt created them.
+ if(module_headers_private)
+ list(APPEND private_includes
+ "$<BUILD_INTERFACE:${module_include_dir}/${PROJECT_VERSION}>"
+ "$<BUILD_INTERFACE:${module_include_dir}/${PROJECT_VERSION}/${module}>")
+ endif()
+
+ list(APPEND ${public_headers_list}
+ # For the syncqt headers
+ "$<BUILD_INTERFACE:${module_repo_include_dir}>"
+ "$<BUILD_INTERFACE:${module_include_dir}>")
+ endif()
+
+ if(NOT arg_NO_MODULE_HEADERS AND NOT arg_NO_SYNC_QT)
+ # For the syncqt headers
+ list(APPEND ${public_headers_list} "$<INSTALL_INTERFACE:include/${module}>")
+ endif()
+ list(APPEND ${public_headers_list} ${arg_PUBLIC_INCLUDE_DIRECTORIES})
+
+ set(header_module)
+ if(arg_HEADER_MODULE)
+ set(header_module "HEADER_MODULE")
+ endif()
+
+ qt_extend_target("${target}"
+ ${header_module}
+ SOURCES ${arg_SOURCES}
+ INCLUDE_DIRECTORIES
+ ${private_includes}
+ PUBLIC_INCLUDE_DIRECTORIES
+ ${public_includes}
+ PUBLIC_DEFINES
+ ${arg_PUBLIC_DEFINES}
+ QT_${module_define}_LIB
+ DEFINES
+ ${arg_DEFINES}
+ QT_NO_CAST_TO_ASCII QT_ASCII_CAST_WARNINGS
+ QT_MOC_COMPAT #we don't need warnings from calling moc code in our generated code
+ QT_USE_QSTRINGBUILDER
+ QT_DEPRECATED_WARNINGS
+ QT_BUILDING_QT
+ QT_BUILD_${module_define}_LIB ### FIXME: use QT_BUILD_ADDON for Add-ons or remove if we don't have add-ons anymore
+ "${deprecation_define}"
+ PUBLIC_LIBRARIES ${arg_PUBLIC_LIBRARIES}
+ LIBRARIES ${arg_LIBRARIES} Qt::PlatformModuleInternal
+ FEATURE_DEPENDENCIES ${arg_FEATURE_DEPENDENCIES}
+ DBUS_ADAPTOR_SOURCES ${arg_DBUS_ADAPTOR_SOURCES}
+ DBUS_ADAPTOR_FLAGS ${arg_DBUS_ADAPTOR_FLAGS}
+ DBUS_INTERFACE_SOURCES ${arg_DBUS_INTERFACE_SOURCES}
+ DBUS_INTERFACE_FLAGS ${arg_DBUS_INTERFACE_FLAGS}
+ COMPILE_OPTIONS ${arg_COMPILE_OPTIONS}
+ PUBLIC_COMPILE_OPTIONS ${arg_PUBLIC_COMPILE_OPTIONS}
+ LINK_OPTIONS ${arg_LINK_OPTIONS}
+ PUBLIC_LINK_OPTIONS ${arg_PUBLIC_LINK_OPTIONS}
+ MOC_OPTIONS ${arg_MOC_OPTIONS}
+ ENABLE_AUTOGEN_TOOLS ${arg_ENABLE_AUTOGEN_TOOLS}
+ DISABLE_AUTOGEN_TOOLS ${arg_DISABLE_AUTOGEN_TOOLS}
+ PRECOMPILED_HEADER ${arg_PRECOMPILED_HEADER}
+ NO_PCH_SOURCES ${arg_NO_PCH_SOURCES}
+ )
+
+ if(NOT ${arg_EXCEPTIONS} AND NOT ${arg_HEADER_MODULE})
+ qt_internal_set_no_exceptions_flags("${target}")
+ endif()
+
+ set(configureFile "${CMAKE_CURRENT_SOURCE_DIR}/configure.cmake")
+ if(EXISTS "${configureFile}")
+ qt_feature_module_begin(
+ LIBRARY "${target}"
+ PUBLIC_FILE "qt${arg_CONFIG_MODULE_NAME}-config.h"
+ PRIVATE_FILE "qt${arg_CONFIG_MODULE_NAME}-config_p.h"
+ PUBLIC_DEPENDENCIES ${arg_FEATURE_DEPENDENCIES}
+ PRIVATE_DEPENDENCIES ${arg_FEATURE_DEPENDENCIES}
+ )
+ include(${configureFile})
+ qt_feature_module_end("${target}")
+
+ set_property(TARGET "${target}" APPEND PROPERTY PUBLIC_HEADER "${CMAKE_CURRENT_BINARY_DIR}/qt${arg_CONFIG_MODULE_NAME}-config.h")
+ set_property(TARGET "${target}" APPEND PROPERTY PRIVATE_HEADER "${CMAKE_CURRENT_BINARY_DIR}/qt${arg_CONFIG_MODULE_NAME}-config_p.h")
+ endif()
+
+ if(NOT arg_HEADER_MODULE)
+ if(DEFINED module_headers_private)
+ qt_internal_add_linker_version_script("${target}" PRIVATE_HEADERS ${module_headers_private} ${module_headers_qpa})
+ else()
+ qt_internal_add_linker_version_script("${target}")
+ endif()
+ endif()
+
+ # Handle injections. Aka create forwarding headers for certain headers that have been
+ # automatically generated in the build dir (for example qconfig.h, qtcore-config.h,
+ # qvulkanfunctions.h, etc)
+ # module_headers_injections come from the qt_read_headers_pri() call.
+ # extra_library_injections come from the qt_feature_module_end() call.
+ set(final_injections "")
+ if(module_headers_injections)
+ string(APPEND final_injections "${module_headers_injections} ")
+ endif()
+ if(extra_library_injections)
+ string(APPEND final_injections "${extra_library_injections} ")
+ endif()
+
+ if(final_injections)
+ qt_install_injections(${target} "${QT_BUILD_DIR}" "${QT_INSTALL_DIR}" ${final_injections})
+ endif()
+
+ # Handle creation of cmake files for consumers of find_package().
+ set(path_suffix "${INSTALL_CMAKE_NAMESPACE}${target}")
+ qt_path_join(config_build_dir ${QT_CONFIG_BUILD_DIR} ${path_suffix})
+ qt_path_join(config_install_dir ${QT_CONFIG_INSTALL_DIR} ${path_suffix})
+
+ set(extra_cmake_files)
+ set(extra_cmake_includes)
+ if (EXISTS "${CMAKE_CURRENT_LIST_DIR}/${INSTALL_CMAKE_NAMESPACE}${target}Macros.cmake")
+ list(APPEND extra_cmake_files "${CMAKE_CURRENT_LIST_DIR}/${INSTALL_CMAKE_NAMESPACE}${target}Macros.cmake")
+ list(APPEND extra_cmake_includes "${INSTALL_CMAKE_NAMESPACE}${target}Macros.cmake")
+ endif()
+ if (EXISTS "${CMAKE_CURRENT_LIST_DIR}/${INSTALL_CMAKE_NAMESPACE}${target}ConfigExtras.cmake.in")
+ configure_file("${CMAKE_CURRENT_LIST_DIR}/${INSTALL_CMAKE_NAMESPACE}${target}ConfigExtras.cmake.in"
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}ConfigExtras.cmake"
+ @ONLY)
+ list(APPEND extra_cmake_files "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}ConfigExtras.cmake")
+ list(APPEND extra_cmake_includes "${INSTALL_CMAKE_NAMESPACE}${target}ConfigExtras.cmake")
+ endif()
+
+ foreach(cmake_file IN LISTS arg_EXTRA_CMAKE_FILES)
+ get_filename_component(basename ${cmake_file} NAME)
+ file(COPY ${cmake_file} DESTINATION ${config_build_dir})
+ list(APPEND extra_cmake_files "${config_build_dir}/${basename}")
+ endforeach()
+ list(APPEND extra_cmake_includes ${arg_EXTRA_CMAKE_INCLUDES})
+
+ set(extra_cmake_code "")
+
+ if(target STREQUAL Core)
+ # Propagate non-build related variables that are needed for consuming Qt packages.
+ # Do this in CoreConfig instead of Qt6Config, so that consumers can also use
+ # find_package(Qt6Core) instead of find_package(Qt6 COMPONENTS Core)
+ string(APPEND extra_cmake_code "
+set(QT_CMAKE_EXPORT_NAMESPACE ${QT_CMAKE_EXPORT_NAMESPACE})")
+ endif()
+
+ configure_package_config_file(
+ "${QT_CMAKE_DIR}/QtModuleConfig.cmake.in"
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}Config.cmake"
+ INSTALL_DESTINATION "${config_install_dir}"
+ )
+ write_basic_package_version_file(
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}ConfigVersion.cmake"
+ VERSION ${PROJECT_VERSION}
+ COMPATIBILITY AnyNewerVersion
+ )
+ qt_install(FILES
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}Config.cmake"
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}ConfigVersion.cmake"
+ ${extra_cmake_files}
+ DESTINATION "${config_install_dir}"
+ COMPONENT Devel
+ )
+
+ file(COPY ${extra_cmake_files} DESTINATION "${config_build_dir}")
+ set(exported_targets ${target})
+ if(NOT ${arg_NO_PRIVATE_MODULE})
+ list(APPEND exported_targets ${target_private})
+ endif()
+ set(export_name "${INSTALL_CMAKE_NAMESPACE}${target}Targets")
+ qt_install(TARGETS ${exported_targets}
+ EXPORT ${export_name}
+ RUNTIME DESTINATION ${INSTALL_BINDIR}
+ LIBRARY DESTINATION ${INSTALL_LIBDIR}
+ ARCHIVE DESTINATION ${INSTALL_LIBDIR}
+ FRAMEWORK DESTINATION ${INSTALL_LIBDIR}
+ PUBLIC_HEADER DESTINATION ${INSTALL_INCLUDEDIR}/${module}
+ PRIVATE_HEADER DESTINATION ${INSTALL_INCLUDEDIR}/${module}/${PROJECT_VERSION}/${module}/private
+ )
+
+ if (ANDROID AND NOT arg_HEADER_MODULE)
+ # Record install library location so it can be accessed by
+ # qt_android_dependencies without having to specify it again.
+ set_target_properties(${target} PROPERTIES
+ QT_ANDROID_MODULE_INSTALL_DIR ${INSTALL_LIBDIR})
+ endif()
+
+ qt_install(EXPORT ${export_name}
+ NAMESPACE ${QT_CMAKE_EXPORT_NAMESPACE}::
+ DESTINATION ${config_install_dir})
+
+ qt_internal_export_modern_cmake_config_targets_file(
+ TARGETS ${exported_targets}
+ EXPORT_NAME_PREFIX ${INSTALL_CMAKE_NAMESPACE}${target}
+ CONFIG_INSTALL_DIR "${config_install_dir}")
+
+ if (${arg_INTERNAL_MODULE})
+ set(arg_INTERNAL_MODULE "INTERNAL_MODULE")
+ else()
+ unset(arg_INTERNAL_MODULE)
+ endif()
+
+ qt_path_join(pri_target_path ${PROJECT_BINARY_DIR} mkspecs/modules)
+ qt_generate_module_pri_file("${target}" "${pri_target_path}" module_pri_files
+ ${arg_INTERNAL_MODULE}
+ ${header_module}
+ QMAKE_MODULE_CONFIG
+ ${arg_QMAKE_MODULE_CONFIG}
+ )
+ qt_install(FILES "${module_pri_files}" DESTINATION mkspecs/modules)
+
+ ### fixme: cmake is missing a built-in variable for this. We want to apply it only to modules and plugins
+ # that belong to Qt.
+ if(NOT arg_HEADER_MODULE)
+ qt_internal_add_link_flags_no_undefined("${target}")
+ endif()
+
+ set(interface_includes "")
+
+ # Handle cases like QmlDevTools which do not have their own headers, but rather borrow them
+ # from another module.
+ if(NOT arg_NO_SYNC_QT)
+ list(APPEND interface_includes
+ "$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>"
+ "$<BUILD_INTERFACE:${module_include_dir}/${PROJECT_VERSION}>"
+ "$<BUILD_INTERFACE:${module_include_dir}/${PROJECT_VERSION}/${module}>")
+
+ if(NOT arg_NO_MODULE_HEADERS)
+ if(is_framework)
+ set(fw_headers_dir
+ "${INSTALL_LIBDIR}/${module}.framework/Headers/")
+ list(APPEND interface_includes
+ "$<INSTALL_INTERFACE:${fw_headers_dir}${PROJECT_VERSION}>"
+ "$<INSTALL_INTERFACE:${fw_headers_dir}${PROJECT_VERSION}/${module}>")
+ else()
+ list(APPEND interface_includes
+ "$<INSTALL_INTERFACE:include/${module}/${PROJECT_VERSION}>"
+ "$<INSTALL_INTERFACE:include/${module}/${PROJECT_VERSION}/${module}>")
+ endif()
+ endif()
+ endif()
+
+ if(NOT ${arg_NO_PRIVATE_MODULE})
+ target_include_directories("${target_private}" INTERFACE ${interface_includes})
+ endif()
+
+ if(is_framework AND NOT is_interface_lib)
+ qt_finalize_framework_headers_copy(${target})
+ endif()
+
+ qt_describe_module(${target})
+
+ # Generate metatypes
+ if (${arg_GENERATE_METATYPES})
+ qt6_generate_meta_types_json_file(${target})
+ get_target_property(target_metatypes_file ${target} QT_MODULE_META_TYPES_FILE)
+ if (target_metatypes_file)
+ set(metatypes_install_dir ${INSTALL_LIBDIR}/metatypes)
+ qt_install(FILES ${target_metatypes_file}
+ DESTINATION ${metatypes_install_dir}
+ )
+ # For non prefix builds
+ if(NOT QT_WILL_INSTALL)
+ get_filename_component(file_name ${target_metatypes_file} NAME)
+ set(copy_destination ${QT_BUILD_DIR}/${metatypes_install_dir}/${file_name})
+ add_custom_command(TARGET ${target} POST_BUILD
+ COMMAND ${CMAKE_COMMAND}
+ -E copy_if_different ${target_metatypes_file} ${copy_destination}
+ )
+ endif()
+ endif()
+ endif()
+endfunction()
+
+function(qt_export_tools module_name)
+ # If no tools were defined belonging to this module, don't create a config and targets file.
+ # Guards against the case when doing a cross-build.
+
+ if(NOT "${module_name}" IN_LIST QT_KNOWN_MODULES_WITH_TOOLS OR CMAKE_CROSSCOMPILING)
+ return()
+ endif()
+
+ # The tools target name. For example: CoreTools
+ set(target "${module_name}Tools")
+
+ set(path_suffix "${INSTALL_CMAKE_NAMESPACE}${target}")
+ qt_path_join(config_build_dir ${QT_CONFIG_BUILD_DIR} ${path_suffix})
+ qt_path_join(config_install_dir ${QT_CONFIG_INSTALL_DIR} ${path_suffix})
+
+ # Add the extra cmake statements to make the tool targets global, so it doesn't matter where
+ # find_package is called.
+ # Also assemble a list of tool targets to expose in the config file for informational purposes.
+ set(extra_cmake_statements "")
+ set(tool_targets "")
+ set(tool_targets_non_prefixed "")
+
+ # List of package dependencies that need be find_package'd when using the Tools package.
+ set(package_deps "")
+
+ foreach(tool_name ${QT_KNOWN_MODULE_${module_name}_TOOLS})
+ # Specific tools can have package dependencies.
+ # e.g. qtwaylandscanner depends on WaylandScanner (non-qt package).
+ get_target_property(extra_packages "${tool_name}" QT_EXTRA_PACKAGE_DEPENDENCIES)
+ if(extra_packages)
+ list(APPEND package_deps "${extra_packages}")
+ endif()
+
+ set(extra_cmake_statements "${extra_cmake_statements}
+if (NOT QT_NO_CREATE_TARGETS)
+ get_property(is_global TARGET ${INSTALL_CMAKE_NAMESPACE}::${tool_name} PROPERTY IMPORTED_GLOBAL)
+ if(NOT is_global)
+ set_property(TARGET ${INSTALL_CMAKE_NAMESPACE}::${tool_name} PROPERTY IMPORTED_GLOBAL TRUE)
+ endif()
+endif()
+")
+ list(APPEND tool_targets "${QT_CMAKE_EXPORT_NAMESPACE}::${tool_name}")
+ list(APPEND tool_targets_non_prefixed "${tool_name}")
+ endforeach()
+
+ string(APPEND extra_cmake_statements
+"set(${QT_CMAKE_EXPORT_NAMESPACE}${module_name}Tools_TARGETS \"${tool_targets}\")")
+
+ # Extract package dependencies that were determined in QtPostProcess, but only if ${module_name}
+ # is an actual target.
+ # module_name can be a non-existent target, if the tool doesn't have an existing associated
+ # module, e.g. qtwaylandscanner.
+ if(TARGET "${module_name}")
+ get_target_property(module_package_deps "${module_name}" _qt_tools_package_deps)
+ if(module_package_deps)
+ list(APPEND package_deps "${module_package_deps}")
+ endif()
+ endif()
+
+ # Configure and install dependencies file for the ${module_name}Tools package.
+ configure_file(
+ "${QT_CMAKE_DIR}/QtModuleToolsDependencies.cmake.in"
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}Dependencies.cmake"
+ @ONLY
+ )
+
+ qt_install(FILES
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}Dependencies.cmake"
+ DESTINATION "${config_install_dir}"
+ COMPONENT Devel
+ )
+
+ # Configure and install the ${module_name}Tools package Config file.
+ configure_package_config_file(
+ "${QT_CMAKE_DIR}/QtModuleToolsConfig.cmake.in"
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}Config.cmake"
+ INSTALL_DESTINATION "${config_install_dir}"
+ )
+ write_basic_package_version_file(
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}ConfigVersion.cmake"
+ VERSION ${PROJECT_VERSION}
+ COMPATIBILITY AnyNewerVersion
+ )
+
+ qt_install(FILES
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}Config.cmake"
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}ConfigVersion.cmake"
+ DESTINATION "${config_install_dir}"
+ COMPONENT Devel
+ )
+
+ set(export_name "${INSTALL_CMAKE_NAMESPACE}${target}Targets")
+ qt_install(EXPORT "${export_name}"
+ NAMESPACE "${QT_CMAKE_EXPORT_NAMESPACE}::"
+ DESTINATION "${config_install_dir}")
+
+
+ # Create versionless targets file.
+ configure_file(
+ "${QT_CMAKE_DIR}/QtModuleToolsVersionlessTargets.cmake.in"
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}VersionlessTargets.cmake"
+ @ONLY
+ )
+
+ qt_install(FILES
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}VersionlessTargets.cmake"
+ DESTINATION "${config_install_dir}"
+ COMPONENT Devel
+ )
+endfunction()
+
+# This function records a dependency between ${target_name} and ${dep_package_name}.
+# at the CMake package level.
+# E.g. The Tools package that provides the qtwaylandscanner target
+# needs to call find_package(WaylandScanner) (non-qt-package).
+# main_target_name = qtwaylandscanner
+# dep_package_name = WaylandScanner
+function(qt_record_extra_package_dependency main_target_name dep_package_name dep_package_version)
+ get_target_property(extra_packages "${main_target_name}" QT_EXTRA_PACKAGE_DEPENDENCIES)
+ if(NOT extra_packages)
+ set(extra_packages "")
+ endif()
+
+ list(APPEND extra_packages "${dep_package_name}\;${dep_package_version}")
+ set_target_properties("${main_target_name}" PROPERTIES QT_EXTRA_PACKAGE_DEPENDENCIES
+ "${extra_packages}")
+endfunction()
+
+# This function records a dependency between ${main_target_name} and ${dep_target_name}
+# at the CMake package level.
+# E.g. Qt6CoreConfig.cmake needs to find_package(Qt6WinMain).
+# main_target_name = Core
+# dep_target_name = WinMain
+# This is just a convenience function that deals with Qt targets and their associated packages
+# instead of raw package names.
+function(qt_record_extra_qt_package_dependency main_target_name dep_target_name
+ dep_package_version)
+ # WinMain -> Qt6WinMain.
+ qt_internal_module_info(qtfied_target_name "${dep_target_name}")
+ qt_record_extra_package_dependency("${main_target_name}" "${qtfied_target_name_versioned}"
+ "${dep_package_version}")
+endfunction()
+
+function(qt_internal_check_directory_or_type name dir type default result_var)
+ if ("x${dir}" STREQUAL x)
+ if("x${type}" STREQUAL x)
+ message(FATAL_ERROR "qt_add_plugin called without setting either TYPE or ${name}.")
+ endif()
+ set(${result_var} "${default}" PARENT_SCOPE)
+ else()
+ set(${result_var} "${dir}" PARENT_SCOPE)
+ endif()
+endfunction()
+
+# Utility function to find the module to which a plug-in belongs.
+# This will set the QT_MODULE target property on the plug-in - e.g. "Gui", "Sql"...
+function(qt_get_module_for_plugin target target_type)
+ qt_internal_get_qt_all_known_modules(known_modules)
+
+ qt_get_sanitized_plugin_type("${target_type}" target_type)
+ foreach(qt_module ${known_modules})
+ get_target_property(module_type "${QT_CMAKE_EXPORT_NAMESPACE}::${qt_module}" TYPE)
+ # Assuming interface libraries can't have plugins. Otherwise we'll need to fix the property
+ # name, because the current one would be invalid for interface libraries.
+ if(module_type STREQUAL "INTERFACE_LIBRARY")
+ continue()
+ endif()
+
+ get_target_property(plugin_types
+ "${QT_CMAKE_EXPORT_NAMESPACE}::${qt_module}"
+ MODULE_PLUGIN_TYPES)
+ if(plugin_types)
+ foreach(plugin_type ${plugin_types})
+ if("${target_type}" STREQUAL "${plugin_type}")
+ set_target_properties("${target}" PROPERTIES QT_MODULE "${qt_module}")
+ return()
+ endif()
+ endforeach()
+ endif()
+ endforeach()
+ message(AUTHOR_WARNING "The plug-in '${target}' does not belong to any Qt module.")
+endfunction()
+
+
+# Collection of qt_add_plugin arguments so they can be shared across different
+# plugin type wrappers
+set(__qt_add_plugin_optional_args
+ "STATIC;EXCEPTIONS;ALLOW_UNDEFINED_SYMBOLS"
+)
+set(__qt_add_plugin_single_args
+ "TYPE;CLASS_NAME;OUTPUT_DIRECTORY;INSTALL_DIRECTORY;ARCHIVE_INSTALL_DIRECTORY;QML_TARGET_PATH"
+)
+set(__qt_add_plugin_multi_args
+ "${__default_private_args};${__default_public_args};DEFAULT_IF"
+)
+# This is the main entry point for defining Qt plugins.
+# A CMake target is created with the given target. The TYPE parameter is needed to place the
+# plugin into the correct plugins/ sub-directory.
+function(qt_add_plugin target)
+ qt_internal_module_info(module "${target}")
+
+ qt_internal_set_qt_known_plugins("${QT_KNOWN_PLUGINS}" "${target}")
+
+ qt_parse_all_arguments(arg "qt_add_plugin"
+ "${__qt_add_plugin_optional_args};SKIP_INSTALL"
+ "${__qt_add_plugin_single_args}"
+ "${__qt_add_plugin_multi_args}"
+ "${ARGN}"
+ )
+
+ qt_get_sanitized_plugin_type("${arg_TYPE}" arg_TYPE)
+
+ set(output_directory_default "${QT_BUILD_DIR}/${INSTALL_PLUGINSDIR}/${arg_TYPE}")
+ set(install_directory_default "${INSTALL_PLUGINSDIR}/${arg_TYPE}")
+ set(archive_install_directory_default "${INSTALL_LIBDIR}/${arg_TYPE}")
+
+ if (arg_QML_TARGET_PATH)
+ set(target_path "${arg_QML_TARGET_PATH}")
+ set(output_directory_default "${QT_BUILD_DIR}/${INSTALL_QMLDIR}/${target_path}")
+ set(install_directory_default "${INSTALL_QMLDIR}/${target_path}")
+ set(archive_install_directory_default "${INSTALL_QMLDIR}/${target_path}")
+ endif()
+
+ if ("x${arg_CLASS_NAME}" STREQUAL "x" AND NOT "${arg_TYPE}" STREQUAL "qml_plugin")
+ message(AUTHOR_WARNING "qt_add_plugin called without setting CLASS_NAME.")
+ endif()
+
+ qt_internal_check_directory_or_type(OUTPUT_DIRECTORY "${arg_OUTPUT_DIRECTORY}" "${arg_TYPE}"
+ "${output_directory_default}" output_directory)
+ if (NOT arg_SKIP_INSTALL)
+ qt_internal_check_directory_or_type(INSTALL_DIRECTORY "${arg_INSTALL_DIRECTORY}" "${arg_TYPE}"
+ "${install_directory_default}" install_directory)
+ if (NOT arg_ARCHIVE_INSTALL_DIRECTORY AND arg_INSTALL_DIRECTORY)
+ set(arg_ARCHIVE_INSTALL_DIRECTORY "${arg_INSTALL_DIRECTORY}")
+ endif()
+ endif()
+
+ if(arg_STATIC OR NOT BUILD_SHARED_LIBS)
+ add_library("${target}" STATIC)
+ else()
+ add_library("${target}" MODULE)
+ if(APPLE)
+ # CMake defaults to using .so extensions for loadable modules, aka plugins,
+ # but Qt plugins are actually suffixed with .dylib.
+ set_property(TARGET "${target}" PROPERTY SUFFIX ".dylib")
+ endif()
+ endif()
+
+ if (ANDROID)
+ qt_android_apply_arch_suffix("${target}")
+ set_target_properties(${target}
+ PROPERTIES
+ LIBRARY_OUTPUT_NAME "plugins_${arg_TYPE}_${target}"
+ )
+ endif()
+ qt_internal_add_target_aliases("${target}")
+ qt_skip_warnings_are_errors_when_repo_unclean("${target}")
+
+ # Disable linking of plugins against other plugins during static regular and
+ # super builds. The latter causes cyclic dependencies otherwise.
+ set_target_properties(${target} PROPERTIES QT_DEFAULT_PLUGINS 0)
+
+ set_target_properties("${target}" PROPERTIES
+ LIBRARY_OUTPUT_DIRECTORY "${output_directory}"
+ RUNTIME_OUTPUT_DIRECTORY "${output_directory}"
+ ARCHIVE_OUTPUT_DIRECTORY "${output_directory}"
+ QT_PLUGIN_CLASS_NAME "${arg_CLASS_NAME}")
+
+ qt_internal_library_deprecation_level(deprecation_define)
+
+ qt_autogen_tools_initial_setup(${target})
+
+ set(static_plugin_define "")
+ if (arg_STATIC OR NOT QT_BUILD_SHARED_LIBS)
+ set(static_plugin_define "QT_STATICPLUGIN")
+ endif()
+
+ # Save the Qt module in the plug-in's properties
+ if(NOT arg_TYPE STREQUAL "qml_plugin")
+ qt_get_module_for_plugin("${target}" "${arg_TYPE}")
+ get_target_property(qt_module "${target}" QT_MODULE)
+ endif()
+
+ # Add the plug-in to the list of plug-ins of this module
+ if(TARGET "${qt_module}")
+ set_property(TARGET "${qt_module}" APPEND PROPERTY QT_PLUGINS "${target}")
+ endif()
+
+ set(_default_plugin 1)
+ if (DEFINED arg_DEFAULT_IF)
+ if (NOT ${arg_DEFAULT_IF})
+ set(_default_plugin 0)
+ endif()
+ endif()
+
+ set_property(TARGET "${target}" PROPERTY QT_DEFAULT_PLUGIN "${_default_plugin}")
+ set_property(TARGET "${target}" APPEND PROPERTY EXPORT_PROPERTIES "QT_PLUGIN_CLASS_NAME;QT_PLUGIN_TYPE;QT_MODULE;QT_DEFAULT_PLUGIN")
+
+ set(private_includes
+ "${CMAKE_CURRENT_SOURCE_DIR}"
+ "${CMAKE_CURRENT_BINARY_DIR}"
+ # For the syncqt headers
+ "$<BUILD_INTERFACE:${module_repo_include_dir}>"
+ ${arg_INCLUDE_DIRECTORIES}
+ )
+
+ set(public_includes
+ ${arg_PUBLIC_INCLUDE_DIRECTORIES}
+ )
+
+ qt_extend_target("${target}"
+ SOURCES ${arg_SOURCES}
+ INCLUDE_DIRECTORIES
+ ${private_includes}
+ PUBLIC_INCLUDE_DIRECTORIES
+ ${public_includes}
+ LIBRARIES ${arg_LIBRARIES} Qt::PlatformPluginInternal
+ PUBLIC_LIBRARIES ${arg_PUBLIC_LIBRARIES}
+ DEFINES
+ ${arg_DEFINES}
+ QT_DEPRECATED_WARNINGS
+ "${deprecation_define}"
+ "${static_plugin_define}"
+ QT_PLUGIN
+ PUBLIC_DEFINES
+ QT_${module_define}_LIB
+ ${arg_PUBLIC_DEFINES}
+ FEATURE_DEPENDENCIES ${arg_FEATURE_DEPENDENCIES}
+ DBUS_ADAPTOR_SOURCES "${arg_DBUS_ADAPTOR_SOURCES}"
+ DBUS_ADAPTOR_FLAGS "${arg_DBUS_ADAPTOR_FLAGS}"
+ DBUS_INTERFACE_SOURCES "${arg_DBUS_INTERFACE_SOURCES}"
+ DBUS_INTERFACE_FLAGS "${arg_DBUS_INTERFACE_FLAGS}"
+ COMPILE_OPTIONS ${arg_COMPILE_OPTIONS}
+ PUBLIC_COMPILE_OPTIONS ${arg_PUBLIC_COMPILE_OPTIONS}
+ LINK_OPTIONS ${arg_LINK_OPTIONS}
+ PUBLIC_LINK_OPTIONS ${arg_PUBLIC_LINK_OPTIONS}
+ MOC_OPTIONS ${arg_MOC_OPTIONS}
+ ENABLE_AUTOGEN_TOOLS ${arg_ENABLE_AUTOGEN_TOOLS}
+ DISABLE_AUTOGEN_TOOLS ${arg_DISABLE_AUTOGEN_TOOLS}
+ )
+ if(NOT ${arg_EXCEPTIONS})
+ qt_internal_set_no_exceptions_flags("${target}")
+ endif()
+
+
+ set(qt_libs_private "")
+ qt_internal_get_qt_all_known_modules(known_modules)
+ foreach(it ${known_modules})
+ list(FIND arg_LIBRARIES "Qt::${it}Private" pos)
+ if(pos GREATER -1)
+ list(APPEND qt_libs_private "Qt::${it}Private")
+ endif()
+ endforeach()
+
+ qt_register_target_dependencies("${target}" "${arg_PUBLIC_LIBRARIES}" "${qt_libs_private}")
+
+ if (NOT arg_SKIP_INSTALL)
+ # Handle creation of cmake files for consumers of find_package().
+ # If we are part of a Qt module, the plugin cmake files are installed as part of that module.
+ if(qt_module)
+ set(path_suffix "${INSTALL_CMAKE_NAMESPACE}${qt_module}")
+ else()
+ set(path_suffix "${INSTALL_CMAKE_NAMESPACE}${target}")
+ endif()
+
+ qt_path_join(config_build_dir ${QT_CONFIG_BUILD_DIR} ${path_suffix})
+ qt_path_join(config_install_dir ${QT_CONFIG_INSTALL_DIR} ${path_suffix})
+
+ configure_package_config_file(
+ "${QT_CMAKE_DIR}/QtPluginConfig.cmake.in"
+ "${config_build_dir}/${target}Config.cmake"
+ INSTALL_DESTINATION "${config_install_dir}"
+ )
+ write_basic_package_version_file(
+ "${config_build_dir}/${target}ConfigVersion.cmake"
+ VERSION ${PROJECT_VERSION}
+ COMPATIBILITY AnyNewerVersion
+ )
+
+ qt_install(FILES
+ "${config_build_dir}/${target}Config.cmake"
+ "${config_build_dir}/${target}ConfigVersion.cmake"
+ DESTINATION "${config_install_dir}"
+ COMPONENT Devel
+ )
+
+ # Make the export name of plugins be consistent with modules, so that
+ # qt_add_resource adds its additional targets to the same export set in a static Qt build.
+ set(export_name "${INSTALL_CMAKE_NAMESPACE}${target}Targets")
+ qt_install(TARGETS "${target}"
+ EXPORT ${export_name}
+ RUNTIME DESTINATION "${install_directory}"
+ LIBRARY DESTINATION "${install_directory}"
+ ARCHIVE DESTINATION "${archive_install_directory}"
+ )
+ qt_install(EXPORT ${export_name}
+ NAMESPACE ${QT_CMAKE_EXPORT_NAMESPACE}::
+ DESTINATION "${config_install_dir}"
+ )
+ endif()
+
+ # Store the plug-in type in the target property
+ set_property(TARGET "${target}" PROPERTY QT_PLUGIN_TYPE "${arg_TYPE}")
+
+ if (NOT arg_ALLOW_UNDEFINED_SYMBOLS)
+ ### fixme: cmake is missing a built-in variable for this. We want to apply it only to
+ # modules and plugins that belong to Qt.
+ qt_internal_add_link_flags_no_undefined("${target}")
+ endif()
+
+ qt_internal_add_linker_version_script(${target})
+endfunction()
+
+# Generate custom ${target}_qmltypes target for Qml Plugins
+function(qt_add_qmltypes_target target)
+
+ # Do nothing when cross compiling
+ if (CMAKE_CROSSCOMPILING)
+ return()
+ endif()
+
+ # Do nothing during a Qt static build (because the tool isn't built in that case).
+ if (NOT QT_BUILD_SHARED_LIBS)
+ return()
+ endif()
+
+ qt_parse_all_arguments(arg "qt_generate_qmltypes"
+ ""
+ "TARGET_PATH;IMPORT_VERSION;IMPORT_NAME;QML_PLUGINDUMP_DEPENDENCIES"
+ ""
+ ${ARGN})
+
+ # scan repos for qml repositories
+ foreach(repo IN LISTS QT_REPOS)
+ if (IS_DIRECTORY "${repo}/qml")
+ list(APPEND import_paths "${repo}/qml")
+ endif()
+ endforeach()
+ list(REMOVE_DUPLICATES import_paths)
+ if (UNIX)
+ list(JOIN import_paths ":" import_paths_env)
+ else()
+ list(JOIN import_paths "\;" import_paths_env)
+ endif()
+
+ if(NOT arg_IMPORT_NAME)
+ string(REGEX REPLACE "\\.\\d+$" "" import_name ${arg_TARGET_PATH})
+ else()
+ set(import_name ${arg_IMPORT_NAME})
+ endif()
+
+ if(NOT arg_IMPORT_VERSION)
+ message(FATAL_ERROR "Import version parameter was not specified. Specify the import version using the IMPORT_VERSION.")
+ endif()
+
+ get_target_property(source_dir ${target} SOURCE_DIR)
+
+ # qml1_target check is no longer required
+ set(qmltypes_command_args "-nonrelocatable")
+ if (NOT arg_QML_PLUGINDUMP_DEPENDENCIES AND EXISTS "${source_dir}/dependencies.json")
+ list(APPEND qmltypes_command_args "-dependencies" "${source_dir}/dependencies.json")
+ elseif(arg_QML_PLUGINDUMP_DEPENDENCIES)
+ list(APPEND qmltypes_command_args "-dependencies" "${arg_QML_PLUGINDUMP_DEPENDENCIES}")
+ endif()
+
+ string(REPLACE "/" "." import_name_arg ${import_name})
+
+ list(APPEND qmltypes_command_args "${import_name_arg}" "${arg_IMPORT_VERSION}")
+
+ set(qml_plugindump_target ${QT_CMAKE_EXPORT_NAMESPACE}::qmlplugindump)
+
+ # Manually set dependency on plugindump target since CMake will not add
+ # this rule because it's not the main executable argument to the COMMAND
+ # parameter.
+ add_custom_target(
+ "${target}_qmltypes"
+ DEPENDS ${qml_plugindump_target}
+ COMMAND ${CMAKE_COMMAND} -E env "QML2_IMPORTPATH=${import_paths_env}"
+ $<TARGET_FILE:${qml_plugindump_target}> ${qmltypes_command_args} > "${source_dir}/plugins.qmltypes"
+ )
+endfunction()
+
+function(qt_install_qml_files target)
+
+ qt_parse_all_arguments(arg "qt_install_qml_files"
+ "" "" "FILES" ${ARGN}
+ )
+
+ if (NOT arg_FILES)
+ message(FATAL_ERROR "No files specified for qt_install_qml_files. Please specify them using the FILES parameter.")
+ endif()
+
+ get_target_property(target_path ${target} QT_QML_MODULE_TARGET_PATH)
+ if (NOT target_path)
+ message(FATAL_ERROR "Target ${target} is not a qml module.")
+ endif()
+
+ qt_path_join(qml_module_install_dir ${QT_INSTALL_DIR} "${INSTALL_QMLDIR}/${target_path}")
+ qt_copy_or_install(FILES ${arg_FILES}
+ DESTINATION ${qml_module_install_dir}
+ )
+
+endfunction()
+
+
+function(qt_add_resource target resourceName)
+ # Don't try to add resources when cross compiling, and the target is actually a host target
+ # (like a tool).
+ qt_is_imported_target("${target}" is_imported)
+ if(is_imported)
+ return()
+ endif()
+
+ qt_parse_all_arguments(arg "qt_add_resource" "" "PREFIX;LANG;BASE" "FILES" ${ARGN})
+
+ QT6_PROCESS_RESOURCE(${target} ${resourceName}
+ PREFIX "${arg_PREFIX}"
+ LANG "${arg_LANG}"
+ BASE "${arg_BASE}"
+ FILES ${arg_FILES}
+ OUTPUT_TARGETS out_targets
+ )
+
+ if (out_targets)
+ qt_install(TARGETS ${out_targets}
+ EXPORT "${INSTALL_CMAKE_NAMESPACE}${target}Targets"
+ DESTINATION ${INSTALL_LIBDIR}
+ )
+ endif()
+
+endfunction()
+
+
+# This function creates a CMake target for qml modules. It will also make
+# sure that if no C++ source are present, that qml files show up in the project
+# in an IDE. Finally, it will also create a custom ${target}_qmltypes which
+# can be used to generate the respective plugin.qmltypes file.
+#
+# CPP_PLUGIN: Whether this qml module has any c++ source files.
+# URI: Module's uri.
+# TARGET_PATH: Expected installation path for the Qml Module. Equivalent
+# to the module's URI where '.' is replaced with '/'. Use this to override the
+# default substitution pattern.
+# VERSION: Version of the qml module
+# QML_PLUGINDUMP_DEPENDENCIES: Path to a dependencies.json file to be consumed
+# with the ${target}_qmltypes target (optional)
+# SKIP_TYPE_REGISTRATION: All qml files are expected to be registered by the
+# c++ plugin code.
+#
+function(qt_add_qml_module target)
+
+ set(qml_module_optional_args
+ DESIGNER_SUPPORTED
+ DO_NOT_INSTALL
+ SKIP_TYPE_REGISTRATION
+ )
+
+ set(qml_module_single_args
+ URI
+ TARGET_PATH
+ VERSION
+ QML_PLUGINDUMP_DEPENDENCIES
+ CLASSNAME
+ )
+
+ set(qml_module_multi_args
+ IMPORTS
+ TYPEINFO
+ DEPENDENCIES
+ )
+
+ qt_parse_all_arguments(arg "qt_add_qml_module"
+ "${__qt_add_plugin_optional_args};${qml_module_optional_args}"
+ "${__qt_add_plugin_single_args};${qml_module_single_args}"
+ "${__qt_add_plugin_multi_args};${qml_module_multi_args}" ${ARGN})
+
+ if (NOT arg_URI)
+ message(FATAL_ERROR "qt_add_qml_module called without specifying the module's uri. Please specify one using the URI parameter.")
+ endif()
+
+ set(target_path ${arg_TARGET_PATH})
+
+ if (NOT arg_VERSION)
+ message(FATAL_ERROR "qt_add_qml_module called without specifying the module's import version. Please specify one using the VERSION parameter.")
+ endif()
+
+ if (NOT arg_TARGET_PATH)
+ string(REPLACE "." "/" arg_TARGET_PATH ${arg_URI})
+ endif()
+
+ qt_remove_args(plugin_args
+ ARGS_TO_REMOVE
+ ${target}
+ ${qml_module_multi_args}
+ ${qml_module_single_args}
+ ALL_ARGS
+ ${__qt_add_plugin_optional_args}
+ ${__qt_add_plugin_single_args}
+ ${qml_module_single_args}
+ ${__qt_add_plugin_multi_args}
+ ${qml_module_multi_args}
+ ARGS
+ ${ARGV}
+ )
+
+ # If we have no sources, but qml files, create a custom target so the
+ # qml file will be visibile in an IDE.
+ if (arg_SOURCES)
+ qt_add_plugin(${target}
+ TYPE
+ qml_plugin
+ QML_TARGET_PATH
+ "${arg_TARGET_PATH}"
+ ${plugin_args}
+ )
+ endif()
+
+
+ if (arg_CPP_PLUGIN)
+ set(no_create_option DO_NOT_CREATE_TARGET)
+ endif()
+
+ if (arg_CLASSNAME)
+ set(classname_arg CLASSNAME ${arg_CLASSNAME})
+ endif()
+
+ if (arg_DESIGNER_SUPPORTED)
+ set(designer_supported_arg DESIGNER_SUPPORTED)
+ endif()
+
+ if (arg_SKIP_TYPE_REGISTRATION)
+ set(skip_registration_arg SKIP_TYPE_REGISTRATION)
+ endif()
+
+ qt6_add_qml_module(${target}
+ ${designer_supported_arg}
+ ${no_create_option}
+ ${skip_registration_arg}
+ ${classname_arg}
+ RESOURCE_PREFIX "/qt-project.org/imports"
+ TARGET_PATH ${arg_TARGET_PATH}
+ URI ${arg_URI}
+ VERSION ${arg_VERSION}
+ QML_FILES ${arg_QML_FILES}
+ IMPORTS "${arg_IMPORTS}"
+ TYPEINFO "${arg_TYPEINFO}"
+ DO_NOT_INSTALL_METADATA
+ DO_NOT_CREATE_TARGET
+ INSTALL_QML_FILES
+ DEPENDENCIES ${arg_DEPENDENCIES}
+ RESOURCE_EXPORT "${INSTALL_CMAKE_NAMESPACE}${target}Targets"
+ )
+
+ get_target_property(qmldir_file ${target} QT_QML_MODULE_QMLDIR_FILE)
+ qt_path_join(qml_module_install_dir ${QT_INSTALL_DIR} "${INSTALL_QMLDIR}/${arg_TARGET_PATH}")
+ set(plugin_types "${CMAKE_CURRENT_SOURCE_DIR}/plugins.qmltypes")
+ if (EXISTS ${plugin_types})
+ qt_copy_or_install(FILES ${plugin_types}
+ DESTINATION "${qml_module_install_dir}"
+ )
+
+ if(QT_WILL_INSTALL)
+ # plugin.qmltypes when present should also be copied to the
+ # cmake binary dir when doing prefix builds
+ file(COPY ${plugin_types}
+ DESTINATION "${QT_BUILD_DIR}/${INSTALL_QMLDIR}/${arg_TARGET_PATH}"
+ )
+ endif()
+ endif()
+
+
+ qt_copy_or_install(
+ FILES
+ "${qmldir_file}"
+ DESTINATION
+ "${qml_module_install_dir}"
+ )
+
+ if(QT_WILL_INSTALL)
+ # qmldir should also be copied to the cmake binary dir when doing
+ # prefix builds
+ file(COPY "${qmldir_file}"
+ DESTINATION "${QT_BUILD_DIR}/${INSTALL_QMLDIR}/${arg_TARGET_PATH}"
+ )
+ endif()
+
+endfunction()
+
+# Collection of qt_add_executable arguments so they can be shared across qt_add_executable
+# and qt_add_test_helper.
+set(__qt_add_executable_optional_args
+ "GUI;BOOTSTRAP;NO_QT;NO_INSTALL;EXCEPTIONS"
+)
+set(__qt_add_executable_single_args
+ "OUTPUT_DIRECTORY;INSTALL_DIRECTORY"
+)
+set(__qt_add_executable_multi_args
+ "EXE_FLAGS;${__default_private_args};${__default_public_args}"
+)
+
+# This function creates a CMake target for a generic console or GUI binary.
+# Please consider to use a more specific version target like the one created
+# by qt_add_test or qt_add_tool below.
+function(qt_add_executable name)
+ qt_parse_all_arguments(arg "qt_add_executable"
+ "${__qt_add_executable_optional_args}"
+ "${__qt_add_executable_single_args}"
+ "${__qt_add_executable_multi_args}"
+ ${ARGN})
+
+ if ("x${arg_OUTPUT_DIRECTORY}" STREQUAL "x")
+ set(arg_OUTPUT_DIRECTORY "${QT_BUILD_DIR}/${INSTALL_BINDIR}")
+ endif()
+
+ get_filename_component(arg_OUTPUT_DIRECTORY "${arg_OUTPUT_DIRECTORY}"
+ ABSOLUTE BASE_DIR "${QT_BUILD_DIR}")
+
+ if ("x${arg_INSTALL_DIRECTORY}" STREQUAL "x")
+ set(arg_INSTALL_DIRECTORY "${INSTALL_BINDIR}")
+ endif()
+
+ if (ANDROID)
+ add_library("${name}" MODULE)
+ qt_android_apply_arch_suffix("${name}")
+ qt_android_generate_deployment_settings("${name}")
+ qt_android_add_apk_target("${name}")
+ # On our qmake builds we don't compile the executables with
+ # visibility=hidden. Not having this flag set will cause the
+ # executable to have main() hidden and can then no longer be loaded
+ # through dlopen()
+ set_property(TARGET ${name} PROPERTY C_VISIBILITY_PRESET default)
+ set_property(TARGET ${name} PROPERTY CXX_VISIBILITY_PRESET default)
+ else()
+ add_executable("${name}" ${arg_EXE_FLAGS})
+ endif()
+
+ qt_autogen_tools_initial_setup(${name})
+ qt_skip_warnings_are_errors_when_repo_unclean("${name}")
+
+ set(extra_libraries "")
+ if(NOT arg_BOOTSTRAP AND NOT arg_NO_QT)
+ set(extra_libraries "Qt::Core")
+ endif()
+
+ set(private_includes
+ "${CMAKE_CURRENT_SOURCE_DIR}"
+ "${CMAKE_CURRENT_BINARY_DIR}"
+ ${arg_INCLUDE_DIRECTORIES}
+ )
+
+ qt_extend_target("${name}"
+ SOURCES ${arg_SOURCES}
+ INCLUDE_DIRECTORIES ${private_includes}
+ DEFINES ${arg_DEFINES}
+ LIBRARIES ${arg_LIBRARIES}
+ PUBLIC_LIBRARIES ${extra_libraries} ${arg_PUBLIC_LIBRARIES}
+ DBUS_ADAPTOR_SOURCES "${arg_DBUS_ADAPTOR_SOURCES}"
+ DBUS_ADAPTOR_FLAGS "${arg_DBUS_ADAPTOR_FLAGS}"
+ DBUS_INTERFACE_SOURCES "${arg_DBUS_INTERFACE_SOURCES}"
+ DBUS_INTERFACE_FLAGS "${arg_DBUS_INTERFACE_FLAGS}"
+ COMPILE_OPTIONS ${arg_COMPILE_OPTIONS}
+ LINK_OPTIONS ${arg_LINK_OPTIONS}
+ MOC_OPTIONS ${arg_MOC_OPTIONS}
+ ENABLE_AUTOGEN_TOOLS ${arg_ENABLE_AUTOGEN_TOOLS}
+ DISABLE_AUTOGEN_TOOLS ${arg_DISABLE_AUTOGEN_TOOLS}
+ )
+ set_target_properties("${name}" PROPERTIES
+ RUNTIME_OUTPUT_DIRECTORY "${arg_OUTPUT_DIRECTORY}"
+ LIBRARY_OUTPUT_DIRECTORY "${arg_OUTPUT_DIRECTORY}"
+ WIN32_EXECUTABLE "${arg_GUI}"
+ MACOSX_BUNDLE "${arg_GUI}"
+ )
+ if(NOT ${arg_EXCEPTIONS})
+ qt_internal_set_no_exceptions_flags("${name}")
+ endif()
+
+
+ if(NOT arg_NO_INSTALL)
+ qt_install(TARGETS "${name}"
+ RUNTIME DESTINATION "${arg_INSTALL_DIRECTORY}"
+ LIBRARY DESTINATION "${arg_INSTALL_DIRECTORY}"
+ BUNDLE DESTINATION "${arg_INSTALL_DIRECTORY}")
+ endif()
+endfunction()
+
+# Simple wrapper around qt_add_executable for benchmarks which insure that
+# the binary is built under ${CMAKE_CURRENT_BINARY_DIR} and never installed.
+# See qt_add_executable() for more details.
+function(qt_add_benchmark target)
+
+ qt_parse_all_arguments(arg "qt_add_benchmark"
+ "${__qt_add_executable_optional_args}"
+ "${__qt_add_executable_single_args}"
+ "${__qt_add_executable_multi_args}"
+ ${ARGN}
+ )
+
+ qt_remove_args(exec_args
+ ARGS_TO_REMOVE
+ ${target}
+ OUTPUT_DIRECTORY
+ INSTALL_DIRECTORY
+ ALL_ARGS
+ "${__qt_add_executable_optional_args}"
+ "${__qt_add_executable_single_args}"
+ "${__qt_add_executable_multi_args}"
+ ARGS
+ ${ARGV}
+ )
+
+ qt_add_executable(${target}
+ NO_INSTALL # we don't install benchmarks
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}" # avoid polluting bin directory
+ ${exec_args}
+ )
+
+endfunction()
+
+# Simple wrapper around qt_add_executable for manual tests which insure that
+# the binary is built under ${CMAKE_CURRENT_BINARY_DIR} and never installed.
+# See qt_add_executable() for more details.
+function(qt_add_manual_test target)
+
+ qt_parse_all_arguments(arg "qt_add_manual_test"
+ "${__qt_add_executable_optional_args}"
+ "${__qt_add_executable_single_args}"
+ "${__qt_add_executable_multi_args}"
+ ${ARGN}
+ )
+
+ qt_remove_args(exec_args
+ ARGS_TO_REMOVE
+ ${target}
+ OUTPUT_DIRECTORY
+ INSTALL_DIRECTORY
+ ALL_ARGS
+ "${__qt_add_executable_optional_args}"
+ "${__qt_add_executable_single_args}"
+ "${__qt_add_executable_multi_args}"
+ ARGS
+ ${ARGV}
+ )
+
+ qt_add_executable(${target}
+ NO_INSTALL # we don't install benchmarks
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}" # avoid polluting bin directory
+ ${exec_args}
+ )
+
+endfunction()
+
+
+# This function creates a CMake test target with the specified name for use with CTest.
+function(qt_add_test name)
+ qt_parse_all_arguments(arg "qt_add_test"
+ "RUN_SERIAL;EXCEPTIONS;GUI;QMLTEST"
+ "OUTPUT_DIRECTORY;WORKING_DIRECTORY;TIMEOUT"
+ "QML_IMPORTPATH;TESTDATA;${__default_private_args};${__default_public_args}" ${ARGN}
+ )
+
+ if (NOT arg_OUTPUT_DIRECTORY)
+ set(arg_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}")
+ endif()
+
+ if (${arg_EXCEPTIONS})
+ set(exceptions_text "EXCEPTIONS")
+ endif()
+
+ if (${arg_GUI})
+ set(gui_text "GUI")
+ endif()
+
+ # Handle cases where we have a qml test without source files
+ if (arg_SOURCES)
+ set(private_includes
+ "${CMAKE_CURRENT_SOURCE_DIR}"
+ "${CMAKE_CURRENT_BINARY_DIR}"
+ "$<BUILD_INTERFACE:${QT_BUILD_DIR}/include>"
+ ${arg_INCLUDE_DIRECTORIES}
+ )
+
+ qt_add_executable("${name}"
+ ${exceptions_text}
+ ${gui_text}
+ NO_INSTALL
+ OUTPUT_DIRECTORY "${arg_OUTPUT_DIRECTORY}"
+ SOURCES "${arg_SOURCES}"
+ INCLUDE_DIRECTORIES
+ ${private_includes}
+ DEFINES
+ QT_TESTCASE_BUILDDIR="${CMAKE_CURRENT_BINARY_DIR}"
+ QT_TESTCASE_SOURCEDIR="${CMAKE_CURRENT_SOURCE_DIR}"
+ ${arg_DEFINES}
+ PUBLIC_LIBRARIES ${QT_CMAKE_EXPORT_NAMESPACE}::Core ${QT_CMAKE_EXPORT_NAMESPACE}::Test ${arg_PUBLIC_LIBRARIES}
+ LIBRARIES ${arg_LIBRARIES}
+ COMPILE_OPTIONS ${arg_COMPILE_OPTIONS}
+ LINK_OPTIONS ${arg_LINK_OPTIONS}
+ MOC_OPTIONS ${arg_MOC_OPTIONS}
+ ENABLE_AUTOGEN_TOOLS ${arg_ENABLE_AUTOGEN_TOOLS}
+ DISABLE_AUTOGEN_TOOLS ${arg_DISABLE_AUTOGEN_TOOLS}
+ )
+
+ # Tests should not be bundles on macOS even if arg_GUI is true, because some tests make
+ # assumptions about the location of helper processes, and those paths would be different
+ # if a test is built as a bundle.
+ set_property(TARGET "${name}" PROPERTY MACOSX_BUNDLE FALSE)
+ # The same goes for WIN32_EXECUTABLE, but because it will detach from the console window
+ # and not print anything.
+ set_property(TARGET "${name}" PROPERTY WIN32_EXECUTABLE FALSE)
+
+ # QMLTest specifics
+
+ qt_extend_target("${name}" CONDITION arg_QMLTEST
+ PUBLIC_LIBRARIES ${QT_CMAKE_EXPORT_NAMESPACE}::QuickTest
+ )
+
+ qt_extend_target("${name}" CONDITION arg_QMLTEST AND NOT ANDROID
+ DEFINES
+ QUICK_TEST_SOURCE_DIR="${CMAKE_CURRENT_SOURCE_DIR}"
+ )
+
+ qt_extend_target("${name}" CONDITION arg_QMLTEST AND ANDROID
+ DEFINES
+ QUICK_TEST_SOURCE_DIR=":/"
+ )
+ endif()
+
+ foreach(path IN LISTS arg_QML_IMPORTPATH)
+ list(APPEND extra_test_args "-import" "${path}")
+ endforeach()
+
+ # Generate a label in the form tests/auto/foo/bar/tst_baz
+ # and use it also for XML output
+ file(RELATIVE_PATH label "${PROJECT_SOURCE_DIR}" "${CMAKE_CURRENT_SOURCE_DIR}/${name}")
+
+ if (ANDROID)
+ qt_android_add_test("${name}")
+ else()
+ if(arg_QMLTEST AND NOT arg_SOURCES)
+ set(test_working_dir "${CMAKE_CURRENT_SOURCE_DIR}")
+ set(test_executable ${QT_CMAKE_EXPORT_NAMESPACE}::qmltestrunner)
+ else()
+ if (arg_WORKING_DIRECTORY)
+ set(test_working_dir "${arg_WORKING_DIRECTORY}")
+ else()
+ set(test_working_dir "${CMAKE_CURRENT_BINARY_DIR}")
+ endif()
+ set(test_executable "${name}")
+ endif()
+
+ add_test(NAME "${name}" COMMAND ${test_executable} ${extra_test_args} -o ${name}.xml,xml -o -,txt WORKING_DIRECTORY "${test_working_dir}")
+ endif()
+ set_tests_properties("${name}" PROPERTIES RUN_SERIAL "${arg_RUN_SERIAL}" LABELS "${label}")
+ if (arg_TIMEOUT)
+ set_tests_properties(${name} PROPERTIES TIMEOUT ${arg_TIMEOUT})
+ endif()
+ # Get path to qtbase/bin, then prepend this path containing the shared libraries to PATH
+ set(INSTALL_PREFIX_BIN "${CMAKE_INSTALL_PREFIX}/bin")
+ set_property(TEST "${name}" APPEND PROPERTY ENVIRONMENT "PATH=${CMAKE_CURRENT_BINARY_DIR}${QT_PATH_SEPARATOR}${INSTALL_PREFIX_BIN}${QT_PATH_SEPARATOR}$ENV{PATH}")
+ set_property(TEST "${name}" APPEND PROPERTY ENVIRONMENT "QT_TEST_RUNNING_IN_CTEST=1")
+
+ # Add the install prefix to list of plugin paths when doing a prefix build
+ if(NOT QT_INSTALL_DIR)
+ list(APPEND plugin_paths "${CMAKE_INSTALL_PREFIX}/${INSTALL_PLUGINSDIR}")
+ endif()
+ #TODO: Collect all paths from known repositories when performing a super
+ # build.
+ list(APPEND plugin_paths "${PROJECT_BINARY_DIR}/${INSTALL_PLUGINSDIR}")
+ list(JOIN plugin_paths "${QT_PATH_SEPARATOR}" plugin_paths_joined)
+ set_property(TEST "${name}" APPEND PROPERTY ENVIRONMENT "QT_PLUGIN_PATH=${plugin_paths_joined}")
+
+ if(ANDROID OR IOS OR WINRT)
+ set(builtin_testdata TRUE)
+ endif()
+
+ if(builtin_testdata)
+ # Safe guard against qml only tests, no source files == no target
+ if (TARGET "${name}")
+ target_compile_definitions("${name}" PRIVATE BUILTIN_TESTDATA)
+
+ foreach(testdata IN LISTS arg_TESTDATA)
+ list(APPEND builtin_files ${testdata})
+ endforeach()
+
+ set(blacklist_path "BLACKLIST")
+ if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/${blacklist_path}")
+ list(APPEND builtin_files ${blacklist_path})
+ endif()
+
+ list(REMOVE_DUPLICATES builtin_files)
+
+ # Skip Qt quick compiler when embedding test resources
+ foreach(file IN LISTS builtin_files)
+ set_source_files_properties(${file}
+ PROPERTIES QT_SKIP_QUICKCOMPILER TRUE
+ )
+ endforeach()
+
+ if (builtin_files)
+ qt_add_resource(${name} "${name}_testdata_builtin"
+ PREFIX "/"
+ FILES ${builtin_files}
+ BASE ${CMAKE_CURRENT_SOURCE_DIR})
+ endif()
+ endif()
+ else()
+ # Install test data
+ file(RELATIVE_PATH relative_path_to_test_project
+ "${QT_TOP_LEVEL_SOURCE_DIR}"
+ "${CMAKE_CURRENT_SOURCE_DIR}")
+ qt_path_join(testdata_install_dir ${QT_INSTALL_DIR}
+ "${relative_path_to_test_project}")
+ foreach(testdata IN LISTS arg_TESTDATA)
+ set(testdata "${CMAKE_CURRENT_SOURCE_DIR}/${testdata}")
+ if (IS_DIRECTORY "${testdata}")
+ qt_copy_or_install(
+ DIRECTORY "${testdata}"
+ DESTINATION "${testdata_install_dir}")
+ else()
+ qt_copy_or_install(
+ FILES "${testdata}"
+ DESTINATION "${testdata_install_dir}")
+ endif()
+ endforeach()
+ endif()
+
+endfunction()
+
+
+# This function creates an executable for use as a helper program with tests. Some
+# tests launch separate programs to test certain input/output behavior.
+# Specify OVERRIDE_OUTPUT_DIRECTORY if you dont' want to place the helper in the parent directory,
+# in which case you should specify OUTPUT_DIRECTORY "/foo/bar" manually.
+function(qt_add_test_helper name)
+
+ set(qt_add_test_helper_optional_args
+ "OVERRIDE_OUTPUT_DIRECTORY"
+ )
+
+ qt_parse_all_arguments(arg "qt_add_test_helper"
+ "${qt_add_test_helper_optional_args};${__qt_add_executable_optional_args}"
+ "${__qt_add_executable_single_args}"
+ "${__qt_add_executable_multi_args}"
+ ${ARGN})
+
+ qt_remove_args(forward_args
+ ARGS_TO_REMOVE
+ "${name}"
+ ${qt_add_test_helper_optional_args}
+ ALL_ARGS
+ ${qt_add_test_helper_optional_args}
+ ${__qt_add_executable_optional_args}
+ ${__qt_add_executable_single_args}
+ ${__qt_add_executable_multi_args}
+ ARGS
+ ${ARGV}
+ )
+
+ set(extra_args_to_pass)
+ if(NOT arg_OVERRIDE_OUTPUT_DIRECTORY)
+ set(extra_args_to_pass OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/..")
+ endif()
+
+ qt_add_executable("${name}" NO_INSTALL ${extra_args_to_pass} ${forward_args})
+endfunction()
+
+# Sets QT_WILL_BUILD_TOOLS if tools will be built.
+function(qt_check_if_tools_will_be_built)
+ if(NOT CMAKE_CROSSCOMPILING AND NOT QT_FORCE_FIND_TOOLS)
+ set(will_build_tools TRUE)
+ else()
+ set(will_build_tools FALSE)
+ endif()
+ set(QT_WILL_BUILD_TOOLS ${will_build_tools} CACHE INTERNAL "Are tools going to be built" FORCE)
+endfunction()
+
+# Wrapper function to create a regular cmake target and forward all the
+# arguments collected by the conversion script. This is only meant for tests!
+function(qt_add_cmake_library target)
+ # Process arguments:
+ qt_parse_all_arguments(arg "qt_add_cmake_library"
+ "SHARED;MODULE;STATIC;INTERFACE"
+ "OUTPUT_DIRECTORY;ARCHIVE_INSTALL_DIRECTORY;INSTALL_DIRECTORY"
+ "${__default_private_args};${__default_public_args}"
+ ${ARGN}
+ )
+
+ ### Define Targets:
+ if(${arg_INTERFACE})
+ add_library("${target}" INTERFACE)
+ elseif(${arg_STATIC} OR (${arg_MODULE} AND NOT BUILD_SHARED_LIBS))
+ add_library("${target}" STATIC)
+ elseif(${arg_SHARED})
+ add_library("${target}" SHARED)
+ elseif(${arg_MODULE})
+ add_library("${target}" MODULE)
+ set_property(TARGET ${name} PROPERTY C_VISIBILITY_PRESET default)
+ set_property(TARGET ${name} PROPERTY CXX_VISIBILITY_PRESET default)
+
+ if(APPLE)
+ # CMake defaults to using .so extensions for loadable modules, aka plugins,
+ # but Qt plugins are actually suffixed with .dylib.
+ set_property(TARGET "${target}" PROPERTY SUFFIX ".dylib")
+ endif()
+ else()
+ add_library("${target}")
+ endif()
+
+ if (NOT arg_ARCHIVE_INSTALL_DIRECTORY AND arg_INSTALL_DIRECTORY)
+ set(arg_ARCHIVE_INSTALL_DIRECTORY "${arg_INSTALL_DIRECTORY}")
+ endif()
+
+ if (ANDROID)
+ qt_android_apply_arch_suffix("${target}")
+ endif()
+ qt_skip_warnings_are_errors_when_repo_unclean("${target}")
+
+ if (arg_INSTALL_DIRECTORY)
+ set(install_arguments
+ ARCHIVE_INSTALL_DIRECTORY ${arg_ARCHIVE_INSTALL_DIRECTORY}
+ INSTALL_DIRECTORY ${arg_INSTALL_DIRECTORY}
+ )
+ endif()
+
+ if (arg_OUTPUT_DIRECTORY)
+ set_target_properties(${target} PROPERTIES
+ ARCHIVE_OUTPUT_DIRECTORY ${arg_OUTPUT_DIRECTORY}
+ RUNTIME_OUTPUT_DIRECTORY ${arg_OUTPUT_DIRECTORY}
+ LIBRARY_OUTPUT_DIRECTORY ${arg_OUTPUT_DIRECTORY}
+ )
+ endif()
+
+ qt_extend_target("${target}"
+ SOURCES ${arg_SOURCES}
+ INCLUDE_DIRECTORIES
+ ${arg_INCLUDE_DIRECTORIES}
+ PUBLIC_INCLUDE_DIRECTORIES
+ ${arg_PUBLIC_INCLUDE_DIRECTORIES}
+ PUBLIC_DEFINES
+ ${arg_PUBLIC_DEFINES}
+ DEFINES
+ ${arg_DEFINES}
+ PUBLIC_LIBRARIES ${arg_PUBLIC_LIBRARIES}
+ LIBRARIES ${arg_LIBRARIES} Qt::PlatformModuleInternal
+ COMPILE_OPTIONS ${arg_COMPILE_OPTIONS}
+ PUBLIC_COMPILE_OPTIONS ${arg_PUBLIC_COMPILE_OPTIONS}
+ LINK_OPTIONS ${arg_LINK_OPTIONS}
+ PUBLIC_LINK_OPTIONS ${arg_PUBLIC_LINK_OPTIONS}
+ MOC_OPTIONS ${arg_MOC_OPTIONS}
+ ENABLE_AUTOGEN_TOOLS ${arg_ENABLE_AUTOGEN_TOOLS}
+ DISABLE_AUTOGEN_TOOLS ${arg_DISABLE_AUTOGEN_TOOLS}
+ ${install_arguments}
+ )
+
+endfunction()
+
+# This function is used to define a "Qt tool", such as moc, uic or rcc.
+# The BOOTSTRAP option allows building it as standalone program, otherwise
+# it will be linked against QtCore.
+function(qt_add_tool name)
+ qt_parse_all_arguments(arg "qt_add_tool" "BOOTSTRAP;NO_QT;NO_INSTALL" "TOOLS_TARGET"
+ "${__default_private_args}" ${ARGN})
+
+ # Handle case when a tool does not belong to a module and it can't be built either (like
+ # during a cross-compile).
+ if(NOT arg_TOOLS_TARGET AND NOT QT_WILL_BUILD_TOOLS)
+ message(FATAL_ERROR "The tool \"${name}\" has not been assigned to a module via"
+ " TOOLS_TARGET (so it can't be found) and it can't be built"
+ " (QT_WILL_BUILD_TOOLS is ${QT_WILL_BUILD_TOOLS}).")
+ endif()
+
+ set(full_name "${QT_CMAKE_EXPORT_NAMESPACE}::${name}")
+ if(TARGET ${full_name})
+ get_property(path TARGET ${full_name} PROPERTY LOCATION)
+ message(STATUS "Tool '${full_name}' was found at ${path}.")
+ return()
+ endif()
+
+ if(arg_TOOLS_TARGET AND NOT QT_WILL_BUILD_TOOLS)
+ set(tools_package_name "Qt6${arg_TOOLS_TARGET}Tools")
+ message(STATUS "Searching for tool '${full_name}' in package ${tools_package_name}.")
+
+ # Only search in path provided by QT_HOST_PATH. We need to do it with CMAKE_PREFIX_PATH
+ # instead of PATHS option, because any find_dependency call inside a Tools package would
+ # not get the proper prefix when using PATHS.
+ set(BACKUP_CMAKE_PREFIX_PATH ${CMAKE_PREFIX_PATH})
+ set(CMAKE_PREFIX_PATH "${QT_HOST_PATH}")
+
+ # Search both with sysroots prepended as well as in the host system. When cross compiling
+ # the mode_package might be set to ONLY only, and the Qt6 tools packages are actually
+ # in the host system.
+ set(BACKUP_CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ${CMAKE_FIND_ROOT_PATH_MODE_PACKAGE})
+ set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE "BOTH")
+ set(BACKUP_CMAKE_SIZEOF_VOID_P "${CMAKE_SIZEOF_VOID_P}")
+ set(CMAKE_SIZEOF_VOID_P "")
+ find_package(
+ ${tools_package_name}
+ ${PROJECT_VERSION}
+ NO_PACKAGE_ROOT_PATH
+ NO_CMAKE_ENVIRONMENT_PATH
+ NO_SYSTEM_ENVIRONMENT_PATH
+ NO_CMAKE_PACKAGE_REGISTRY
+ NO_CMAKE_SYSTEM_PATH
+ NO_CMAKE_SYSTEM_PACKAGE_REGISTRY)
+ set(CMAKE_SIZEOF_VOID_P "${BACKUP_CMAKE_SIZEOF_VOID_P}")
+ set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE "${BACKUP_CMAKE_FIND_ROOT_PATH_MODE_PACKAGE}")
+ set(CMAKE_PREFIX_PATH "${BACKUP_CMAKE_PREFIX_PATH}")
+
+ if(${${tools_package_name}_FOUND} AND TARGET ${full_name})
+ # Even if the tool is already visible, make sure that our modules remain associated
+ # with the tools.
+ qt_internal_append_known_modules_with_tools("${arg_TOOLS_TARGET}")
+ get_property(path TARGET ${full_name} PROPERTY LOCATION)
+ message(STATUS "${full_name} was found at ${path} using package ${tools_package_name}.")
+ return()
+ endif()
+ endif()
+
+ if(NOT QT_WILL_BUILD_TOOLS)
+ message(FATAL_ERROR "The tool \"${full_name}\" was not found in the "
+ "${tools_package_name} package. "
+ "Package found: ${${tools_package_name}_FOUND}")
+ else()
+ message(STATUS "Tool '${full_name}' will be built from source.")
+ endif()
+
+ set(disable_autogen_tools "${arg_DISABLE_AUTOGEN_TOOLS}")
+ if (arg_NO_QT)
+ # FIXME: Remove NO_QT again once qmake can use a "normal" Qt!
+ if (arg_BOOTSTRAP)
+ message(FATAL_ERROR "Tool can not be NO_QT and BOOTSTRAP at the same time!")
+ endif()
+ set(corelib "")
+ else()
+ if (arg_BOOTSTRAP)
+ set(corelib ${QT_CMAKE_EXPORT_NAMESPACE}::Bootstrap)
+ list(APPEND disable_autogen_tools "uic" "moc" "rcc")
+ else()
+ set(corelib ${QT_CMAKE_EXPORT_NAMESPACE}::Core)
+ endif()
+ endif()
+
+ set(bootstrap "")
+ if(arg_BOOTSTRAP)
+ set(bootstrap BOOTSTRAP)
+ endif()
+
+ set(no_qt "")
+ if(arg_NO_QT)
+ set(no_qt NO_QT)
+ endif()
+
+ set(no_install "")
+ if(arg_NO_INSTALL)
+ set(no_install NO_INSTALL)
+ endif()
+
+ qt_add_executable("${name}" OUTPUT_DIRECTORY "${QT_BUILD_DIR}/${INSTALL_BINDIR}"
+ ${bootstrap}
+ ${no_qt}
+ ${no_install}
+ SOURCES ${arg_SOURCES}
+ INCLUDE_DIRECTORIES
+ ${arg_INCLUDE_DIRECTORIES}
+ DEFINES ${arg_DEFINES}
+ PUBLIC_LIBRARIES ${corelib}
+ LIBRARIES ${arg_LIBRARIES} Qt::PlatformToolInternal
+ COMPILE_OPTIONS ${arg_COMPILE_OPTIONS}
+ LINK_OPTIONS ${arg_LINK_OPTIONS}
+ MOC_OPTIONS ${arg_MOC_OPTIONS}
+ DISABLE_AUTOGEN_TOOLS ${disable_autogen_tools}
+ )
+ qt_internal_add_target_aliases("${name}")
+
+ set_target_properties("${name}" PROPERTIES
+ RUNTIME_OUTPUT_DIRECTORY_RELEASE "${QT_BUILD_DIR}/${INSTALL_BINDIR}"
+ )
+
+ if(NOT arg_NO_INSTALL AND arg_TOOLS_TARGET)
+ # Assign a tool to an export set, and mark the module to which the tool belongs.
+ qt_internal_append_known_modules_with_tools("${arg_TOOLS_TARGET}")
+
+ # Also append the tool to the module list.
+ qt_internal_append_known_module_tool("${arg_TOOLS_TARGET}" "${name}")
+
+ qt_install(TARGETS "${name}"
+ EXPORT "${INSTALL_CMAKE_NAMESPACE}${arg_TOOLS_TARGET}ToolsTargets"
+ DESTINATION ${INSTALL_TARGETS_DEFAULT_ARGS})
+ endif()
+endfunction()
+
+function(qt_create_tracepoints name tracePointsFile)
+ #### TODO
+ string(TOLOWER "${name}" name)
+
+ file(GENERATE OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/qt${name}_tracepoints_p.h" CONTENT
+ "#include <private/qtrace_p.h>")
+endfunction()
+
+# Handle files that need special SIMD-related flags.
+# This creates an object library and makes target link
+# to it (privately).
+function(qt_add_simd_part target)
+ qt_parse_all_arguments(arg "qt_add_simd_part" "" ""
+ "NAME;SIMD;${__default_private_args};COMPILE_FLAGS" ${ARGN})
+ if ("x${arg_SIMD}" STREQUAL x)
+ message(FATAL_ERROR "qt_add_simd_part needs a SIMD type to be set.")
+ endif()
+
+ set(condition "QT_FEATURE_${arg_SIMD}")
+ if("${arg_SIMD}" STREQUAL arch_haswell)
+ set(condition "TEST_subarch_avx2 AND TEST_subarch_bmi AND TEST_subarch_bmi2 AND TEST_subarch_f16c AND TEST_subarch_fma AND TEST_subarch_lzcnt AND TEST_subarch_popcnt")
+ elseif("${arg_SIMD}" STREQUAL avx512common)
+ set(condition "TEST_subarch_avx512cd")
+ elseif("${arg_SIMD}" STREQUAL avx512core)
+ set(condition "TEST_subarch_avx512cd AND TEST_subarch_avx512bw AND TEST_subarch_avx512dq AND TEST_subarch_avx512vl")
+ endif()
+
+ set(name "${arg_NAME}")
+ if("x${name}" STREQUAL x)
+ set(name "${target}_simd_${arg_SIMD}")
+ endif()
+
+ qt_evaluate_config_expression(result ${condition})
+ if(${result})
+ if(QT_CMAKE_DEBUG_EXTEND_TARGET)
+ message("qt_add_simd_part(${target} SIMD ${arg_SIMD} ...): Evaluated")
+ endif()
+ string(TOUPPER "QT_CFLAGS_${arg_SIMD}" simd_flags)
+
+ if (NOT TARGET "${name}")
+ add_library("${name}" OBJECT)
+ endif()
+ target_sources("${name}" PRIVATE ${arg_SOURCES})
+ target_include_directories("${name}" PRIVATE
+ ${arg_INCLUDE_DIRECTORIES}
+ $<TARGET_PROPERTY:${target},INCLUDE_DIRECTORIES>)
+ target_compile_options("${name}" PRIVATE
+ ${${simd_flags}}
+ ${arg_COMPILE_FLAGS}
+ $<TARGET_PROPERTY:${target},COMPILE_OPTIONS>)
+ target_compile_definitions("${name}" PRIVATE
+ $<TARGET_PROPERTY:${target},COMPILE_DEFINITIONS>)
+
+ target_link_libraries("${target}" PRIVATE "${name}")
+
+ # Add a link-only dependency on the parent library, to force copying of framework headers
+ # before trying to compile a source file.
+ target_link_libraries("${name}" PRIVATE
+ $<FILTER:$<TARGET_PROPERTY:${target},LINK_LIBRARIES>,EXCLUDE,^${target}_simd_>)
+
+ if(NOT BUILD_SHARED_LIBS)
+ qt_install(
+ TARGETS ${name}
+ EXPORT "${INSTALL_CMAKE_NAMESPACE}Targets"
+ )
+ endif()
+ else()
+ if(QT_CMAKE_DEBUG_EXTEND_TARGET)
+ message("qt_add_simd_part(${target} SIMD ${arg_SIMD} ...): Skipped")
+ endif()
+ endif()
+endfunction()
+
+# From Qt6CoreMacros
+# Function used to create the names of output files preserving relative dirs
+function(qt_make_output_file infile prefix suffix source_dir binary_dir result)
+ get_filename_component(outfilename "${infile}" NAME_WE)
+
+ set(base_dir "${source_dir}")
+ string(FIND "${infile}" "${binary_dir}/" in_binary)
+ if (in_binary EQUAL 0)
+ set(base_dir "${binary_dir}")
+ endif()
+
+ get_filename_component(abs_infile "${infile}" ABSOLUTE BASE_DIR "${base_dir}")
+ file(RELATIVE_PATH rel_infile "${base_dir}" "${abs_infile}")
+ string(REPLACE "../" "__/" mapped_infile "${rel_infile}")
+
+ get_filename_component(abs_mapped_infile "${mapped_infile}" ABSOLUTE BASE_DIR "${binary_dir}")
+ get_filename_component(outpath "${abs_mapped_infile}" PATH)
+
+ file(MAKE_DIRECTORY "${outpath}")
+ set("${result}" "${outpath}/${prefix}${outfilename}${suffix}" PARENT_SCOPE)
+endfunction()
+
+
+# Complete manual moc invocation with full control.
+# Use AUTOMOC whenever possible.
+function(qt_manual_moc result)
+ cmake_parse_arguments(arg "" "" "FLAGS" ${ARGN})
+ set(moc_files)
+ foreach(infile ${arg_UNPARSED_ARGUMENTS})
+ qt_make_output_file("${infile}" "moc_" ".cpp"
+ "${CMAKE_CURRENT_SOURCE_DIR}" "${CMAKE_CURRENT_BINARY_DIR}" outfile)
+ list(APPEND moc_files "${outfile}")
+
+ set(moc_parameters_file "${outfile}_parameters$<$<BOOL:$<CONFIGURATION>>:_$<CONFIGURATION>>")
+ set(moc_parameters ${arg_FLAGS} -o "${outfile}" "${infile}")
+ string (REPLACE ";" "\n" moc_parameters "${moc_parameters}")
+
+ file(GENERATE OUTPUT "${moc_parameters_file}" CONTENT "${moc_parameters}\n")
+
+ add_custom_command(OUTPUT "${outfile}"
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::moc "@${moc_parameters_file}"
+ DEPENDS "${infile}" ${moc_depends} ${QT_CMAKE_EXPORT_NAMESPACE}::moc
+ WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}" VERBATIM)
+ endforeach()
+ set("${result}" ${moc_files} PARENT_SCOPE)
+endfunction()
+
+
+# helper to set up a qdbusxml2cpp rule
+function(qt_create_qdbusxml2cpp_command target infile)
+ qt_parse_all_arguments(arg "qt_create_qdbusxml2cpp_command" "ADAPTOR;INTERFACE" "BASENAME" "FLAGS" ${ARGN})
+ if((arg_ADAPTOR AND arg_INTERFACE) OR (NOT arg_ADAPTOR AND NOT arg_INTERFACE))
+ message(FATAL_ERROR "qt_create_dbusxml2cpp_command needs either ADAPTOR or INTERFACE.")
+ endif()
+
+ set(option "-a")
+ set(type "adaptor")
+ if (arg_INTERFACE)
+ set(option "-p")
+ set(type "interface")
+ endif()
+
+ if ("${arg_BASENAME}" STREQUAL "")
+ get_filename_component(file_dir "${infile}" DIRECTORY)
+ get_filename_component(file_name "${infile}" NAME_WLE)
+ get_filename_component(file_ext "${infile}" LAST_EXT)
+
+ if("${file_ext}" STREQUAL ".xml")
+ else()
+ message(FATAL_ERROR "DBUS ${type} input file is not xml.")
+ endif()
+
+ # use last part of io.qt.something.xml!
+ get_filename_component(file_ext "${file_name}" LAST_EXT)
+ if("x${file_ext}" STREQUAL "x")
+ else()
+ string(SUBSTRING "${file_ext}" 1 -1 file_name) # cut of leading '.'
+ endif()
+
+ string(TOLOWER "${file_name}" file_name)
+ set(file_name "${file_name}_${type}")
+ else()
+ set(file_name ${arg_BASENAME})
+ endif()
+
+ # Use absolute file path for the source file and set the current working directory to the
+ # current binary directory, because setting an absolute path for the header:source combo option
+ # does not work. Splitting on ":" breaks inside the dbus tool when running on Windows
+ # due to ":" being contained in the drive path (e.g C:\foo.h:C:\foo.cpp).
+ get_filename_component(absolute_in_file_path "${infile}" ABSOLUTE)
+
+ set(header_file "${file_name}.h")
+ set(source_file "${file_name}.cpp")
+
+ add_custom_command(OUTPUT "${header_file}" "${source_file}"
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::qdbusxml2cpp ${arg_FLAGS} "${option}"
+ "${header_file}:${source_file}" "${absolute_in_file_path}"
+ DEPENDS "${absolute_in_file_path}"
+ WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"
+ VERBATIM)
+
+ target_sources("${target}" PRIVATE "${header_file}" "${source_file}")
+endfunction()
+
+function(qt_compute_injection_forwarding_header target)
+ qt_parse_all_arguments(arg "qt_compute_injection_forwarding_header"
+ "PRIVATE" "SOURCE;OUT_VAR" "" ${ARGN})
+ qt_internal_module_info(module "${target}")
+ get_filename_component(file_name "${arg_SOURCE}" NAME)
+
+ set(source_absolute_path "${CMAKE_CURRENT_BINARY_DIR}/${arg_SOURCE}")
+ file(RELATIVE_PATH relpath "${PROJECT_BINARY_DIR}" "${source_absolute_path}")
+
+ if (arg_PRIVATE)
+ set(fwd "${PROJECT_VERSION}/${module}/private/${file_name}")
+ else()
+ set(fwd "${file_name}")
+ endif()
+
+ string(APPEND ${arg_OUT_VAR} " ${relpath}:${fwd}")
+ set(${arg_OUT_VAR} ${${arg_OUT_VAR}} PARENT_SCOPE)
+endfunction()
+
+
+function(qt_add_docs)
+ if(${ARGC} EQUAL 1)
+ # Function called from old generated CMakeLists.txt that was missing the target parameter
+ return()
+ endif()
+ if(NOT ${ARGC} EQUAL 2)
+ message(FATAL_ERROR "qt_add_docs called with the wrong number of arguments. Should be qt_add_docs(target path_to_project.qdocconf).")
+ return()
+ endif()
+ set(target ${ARGV0})
+ set(doc_project ${ARGV1})
+
+ if (NOT QT_SUPERBUILD OR QT_WILL_INSTALL)
+ set(qdoc_bin "${CMAKE_INSTALL_PREFIX}/bin/qdoc")
+ set(qtattributionsscanner_bin "${CMAKE_INSTALL_PREFIX}/bin/qtattributionsscanner")
+ set(qhelpgenerator_bin "${CMAKE_INSTALL_PREFIX}/bin/qhelpgenerator")
+ else()
+ set(qdoc_bin "${CMAKE_INSTALL_PREFIX}/qtbase/bin/qdoc")
+ set(qtattributionsscanner_bin "${CMAKE_INSTALL_PREFIX}/qtbase/bin/qtattributionsscanner")
+ set(qhelpgenerator_bin "${CMAKE_INSTALL_PREFIX}/qtbase/bin/qhelpgenerator")
+ endif()
+
+ get_target_property(target_type ${target} TYPE)
+ if (NOT target_type STREQUAL "INTERFACE_LIBRARY")
+ get_target_property(target_bin_dir ${target} BINARY_DIR)
+ get_target_property(target_source_dir ${target} SOURCE_DIR)
+ else()
+ set(target_bin_dir ${CMAKE_CURRENT_BINARY_DIR})
+ set(target_source_dir ${CMAKE_CURRENT_SOURCE_DIR})
+ endif()
+ set(doc_ouput_dir "${target_bin_dir}/.doc")
+
+
+ # Generate include dir list
+ set(target_include_dirs_file "${doc_ouput_dir}/includes.txt")
+
+ set(include_paths_property "$<TARGET_PROPERTY:${target},INCLUDE_DIRECTORIES>")
+ if (NOT target_type STREQUAL "INTERFACE_LIBRARY")
+ file(GENERATE
+ OUTPUT ${target_include_dirs_file}
+ CONTENT "-I$<JOIN:${include_paths_property},\n-I>"
+ )
+ set(include_path_args "@${target_include_dirs_file}")
+ else()
+ set(include_path_args "")
+ endif()
+
+ get_filename_component(doc_target "${doc_project}" NAME_WLE)
+ if (QT_WILL_INSTALL)
+ set(qdoc_output_dir "${CMAKE_BINARY_DIR}/doc/${doc_target}")
+ set(index_dir "${CMAKE_BINARY_DIR}/doc")
+ elseif (QT_SUPERBUILD)
+ set(qdoc_output_dir "${CMAKE_INSTALL_PREFIX}/qtbase/doc/${doc_target}")
+ set(index_dir "${CMAKE_INSTALL_PREFIX}/qtbase/doc")
+ else()
+ set(qdoc_output_dir "${CMAKE_INSTALL_PREFIX}/doc/${doc_target}")
+ set(index_dir "${CMAKE_INSTALL_PREFIX}/doc")
+ endif()
+
+ # qtattributionsscanner
+ add_custom_target(qattributionsscanner_${target}
+ COMMAND ${qtattributionsscanner_bin}
+ ${PROJECT_SOURCE_DIR}
+ --filter "QDocModule=${qdoc_target}"
+ -o "${target_bin_dir}/codeattributions.qdoc"
+ )
+
+ # prepare docs target
+ set(prepare_qdoc_args
+ -outputdir "${qdoc_output_dir}"
+ -installdir "${QT_INSTALL_DIR}/doc"
+ "${target_source_dir}/${doc_project}"
+ -prepare
+ -indexdir "${index_dir}"
+ -no-link-errors
+ "${include_path_args}"
+ )
+
+ if (QT_SUPERBUILD AND NOT QT_WILL_INSTALL)
+ set(qt_install_docs_env "${CMAKE_INSTALL_PREFIX}/qtbase/doc")
+ else()
+ set(qt_install_docs_env "${CMAKE_INSTALL_PREFIX}/doc")
+ endif()
+
+ set(qdoc_env_args
+ "QT_INSTALL_DOCS=\"${qt_install_docs_env}\""
+ "QT_VERSION=${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH}"
+ "QT_VER=${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}"
+ "QT_VERSION_TAG=${PROJECT_VERSION_MAJOR}${PROJECT_VERSION_MINOR}${PROJECT_VERSION_PATCH}"
+ "BUILDDIR=${target_bin_dir}"
+ )
+
+ add_custom_target(prepare_docs_${target}
+ COMMAND ${CMAKE_COMMAND} -E env ${qdoc_env_args}
+ ${qdoc_bin}
+ ${prepare_qdoc_args}
+ )
+
+ add_dependencies(prepare_docs_${target} qattributionsscanner_${target})
+
+ # generate docs target
+ set(generate_qdocs_args
+ -outputdir "${qdoc_output_dir}"
+ -installdir "${INSTALL_DOCDIR}"
+ "${target_source_dir}/${doc_project}"
+ -generate
+ -indexdir "${index_dir}"
+ "${include_path_args}"
+ )
+
+ add_custom_target(generate_docs_${target}
+ COMMAND ${CMAKE_COMMAND} -E env ${qdoc_env_args}
+ ${qdoc_bin}
+ ${generate_qdocs_args}
+ )
+
+ add_dependencies(generate_docs_${target} prepare_docs_${target})
+
+ # generate html
+ set(html_qdocs_args
+ -outputdir "${qdoc_output_dir}"
+ -installdir "${INSTALL_DOCDIR}"
+ "${target_source_dir}/${doc_project}"
+ -indexdir "${index_dir}"
+ "${include_path_args}"
+ )
+
+ add_custom_target(html_docs_${target}
+ COMMAND ${CMAKE_COMMAND} -E env ${qdoc_env_args}
+ ${qdoc_bin}
+ ${html_qdocs_args}
+ )
+
+ add_dependencies(html_docs_${target} generate_docs_${target})
+
+ # generate .qch
+ set(qch_file_name ${doc_target}.qch)
+ set(qch_file_path ${qdoc_output_dir}/${qch_file_name})
+
+ add_custom_target(qch_docs_${target}
+ COMMAND ${qhelpgenerator_bin}
+ "${qdoc_output_dir}/${doc_target}.qhp"
+ -o "${qch_file_path}"
+ )
+ add_dependencies(qch_docs_${target} generate_docs_${target})
+
+ if (QT_WILL_INSTALL)
+ add_custom_target(install_html_docs_${target}
+ COMMAND ${CMAKE_COMMAND} -E copy_directory
+ "${qdoc_output_dir}"
+ "${CMAKE_INSTALL_PREFIX}/${INSTALL_DOCDIR}/${doc_target}"
+ COMMENT "Installing html docs for target {$target}"
+ )
+
+ add_custom_target(install_qch_docs_${target}
+ COMMAND ${CMAKE_COMMAND} -E copy_if_different
+ "${qch_file_path}"
+ "${CMAKE_INSTALL_PREFIX}/${INSTALL_DOCDIR}/${qch_file_name}"
+ COMMENT "Installing qch docs for target ${target}"
+ )
+ else()
+ # Don't need to do anything when not installing
+ add_custom_target(install_html_docs_${target})
+ add_custom_target(install_qch_docs_${target})
+ endif()
+
+ add_dependencies(install_html_docs_${target} html_docs_${target})
+ add_dependencies(install_qch_docs_${target} qch_docs_${target})
+
+ add_custom_target(install_docs_${target})
+ add_dependencies(install_docs_${target} install_html_docs_${target} install_qch_docs_${target})
+
+ add_dependencies(${qt_docs_prepare_target_name} prepare_docs_${target})
+ add_dependencies(${qt_docs_generate_target_name} generate_docs_${target})
+ add_dependencies(${qt_docs_html_target_name} html_docs_${target})
+ add_dependencies(${qt_docs_qch_target_name} qch_docs_${target})
+ add_dependencies(${qt_docs_install_html_target_name} install_html_docs_${target})
+ add_dependencies(${qt_docs_install_qch_target_name} install_qch_docs_${target})
+ add_dependencies(${qt_docs_install_target_name} install_docs_${target})
+
+endfunction()
+
+macro(qt_find_package)
+ # Get the target names we expect to be provided by the package.
+ set(options CONFIG NO_MODULE MODULE REQUIRED)
+ set(oneValueArgs)
+ set(multiValueArgs PROVIDED_TARGETS COMPONENTS)
+ cmake_parse_arguments(arg "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN})
+
+ # If some Qt internal project calls qt_find_package(WrapFreeType), but WrapFreeType was already
+ # found as part of a find_dependency() call from a ModuleDependencies.cmake file (or similar),
+ # and the provided target is also found, that means this might have been an unnecessary
+ # qt_find_package() call, because the dependency was already found via some other transitive
+ # dependency. Return early, so that CMake doesn't fail wiht an error with trying to promote the
+ # targets to be global. This behavior is not enabled by default, because there are cases
+ # when a regular find_package() (non qt_) can find a package (Freetype -> PNG), and a subsequent
+ # qt_find_package(PNG PROVIDED_TARGET PNG::PNG) still needs to succeed and register the provided
+ # targets. To enable the debugging behavior, set QT_DEBUG_QT_FIND_PACKAGE to 1.
+ set(_qt_find_package_skip_find_package FALSE)
+ if(QT_DEBUG_QT_FIND_PACKAGE AND ${ARGV0}_FOUND AND arg_PROVIDED_TARGETS)
+ set(_qt_find_package_skip_find_package TRUE)
+ foreach(qt_find_package_target_name ${arg_PROVIDED_TARGETS})
+ if(NOT TARGET ${qt_find_package_target_name})
+ set(_qt_find_package_skip_find_package FALSE)
+ endif()
+ endforeach()
+
+ if(_qt_find_package_skip_find_package)
+ message(AUTHOR_WARNING "qt_find_package(${ARGV0}) called even though the package "
+ "was already found. Consider removing the call.")
+ endif()
+ endif()
+
+ # Get the version if specified.
+ set(package_version "")
+ if(${ARGC} GREATER_EQUAL 2)
+ if(${ARGV1} MATCHES "^[0-9\.]+$")
+ set(package_version "${ARGV1}")
+ endif()
+ endif()
+
+ if(arg_COMPONENTS)
+ # Re-append components to forward them.
+ list(APPEND arg_UNPARSED_ARGUMENTS "COMPONENTS;${arg_COMPONENTS}")
+ endif()
+
+ if(NOT (arg_CONFIG OR arg_NO_MODULE OR arg_MODULE) AND NOT _qt_find_package_skip_find_package)
+ # Try to find a config package first in quiet mode
+ set(config_package_arg ${arg_UNPARSED_ARGUMENTS})
+ list(APPEND config_package_arg "CONFIG;QUIET")
+ find_package(${config_package_arg})
+
+ # Double check that in config mode the targets become visible. Sometimes
+ # only the module mode creates the targets. For example with vcpkg, the sqlite
+ # package provides sqlite3-config.cmake, which offers multi-config targets but
+ # in their own way. CMake has FindSQLite3.cmake and with the original
+ # qt_find_package(SQLite3) call it is our intention to use the cmake package
+ # in module mode.
+ if (${ARGV0}_FOUND AND arg_PROVIDED_TARGETS)
+ unset(any_target_found)
+ foreach(expected_target ${arg_PROVIDED_TARGETS})
+ if (TARGET ${expected_target})
+ set(any_target_found TRUE)
+ break()
+ endif()
+ endforeach()
+ if(NOT any_target_found)
+ unset(${ARGV0}_FOUND)
+ endif()
+ endif()
+ endif()
+
+ # Ensure the options are back in the original unparsed arguments
+ foreach(opt IN LISTS options)
+ if(arg_${opt})
+ list(APPEND arg_UNPARSED_ARGUMENTS ${opt})
+ endif()
+ endforeach()
+
+ if (NOT ${ARGV0}_FOUND AND NOT _qt_find_package_skip_find_package)
+ # Unset the NOTFOUND ${package}_DIR var that might have been set by the previous
+ # find_package call, to get rid of "not found" messagees in the feature summary
+ # if the package is found by the next find_package call.
+ if(DEFINED CACHE{${ARGV0}_DIR} AND NOT ${ARGV0}_DIR)
+ unset(${ARGV0}_DIR CACHE)
+ endif()
+
+ # Call original function without our custom arguments.
+ find_package(${arg_UNPARSED_ARGUMENTS})
+ endif()
+
+ if(${ARGV0}_FOUND AND arg_PROVIDED_TARGETS AND NOT _qt_find_package_skip_find_package)
+ # If package was found, associate each target with its package name. This will be used
+ # later when creating Config files for Qt libraries, to generate correct find_dependency()
+ # calls. Also make the provided targets global, so that the properties can be read in
+ # all scopes.
+ foreach(qt_find_package_target_name ${arg_PROVIDED_TARGETS})
+ if(TARGET ${qt_find_package_target_name})
+ # Allow usage of aliased targets by setting properties on the actual target
+ get_target_property(aliased_target ${qt_find_package_target_name} ALIASED_TARGET)
+ if(aliased_target)
+ set(qt_find_package_target_name ${aliased_target})
+ endif()
+
+ set_target_properties(${qt_find_package_target_name}
+ PROPERTIES INTERFACE_QT_PACKAGE_NAME ${ARGV0})
+ if(package_version)
+ set_target_properties(${qt_find_package_target_name}
+ PROPERTIES INTERFACE_QT_PACKAGE_VERSION ${ARGV1})
+ endif()
+
+ if(arg_COMPONENTS)
+ string(REPLACE ";" " " components_as_string "${arg_COMPONENTS}")
+ set_property(TARGET ${qt_find_package_target_name}
+ PROPERTY INTERFACE_QT_PACKAGE_COMPONENTS ${components_as_string})
+ endif()
+
+ get_property(is_global TARGET ${qt_find_package_target_name} PROPERTY
+ IMPORTED_GLOBAL)
+ if(NOT is_global)
+ set_property(TARGET ${qt_find_package_target_name} PROPERTY
+ IMPORTED_GLOBAL TRUE)
+ endif()
+ endif()
+
+ endforeach()
+ endif()
+endmacro()
+
+# Creates a simple export set for the various Find* dependencies
+# which are needed when creating a static build of Qt.
+# This introduces a custom target property: INTERFACE_QT_EXPORTED_LIBRARY
+# This target property indicates that Qt modules / plugins using this 3rd party library
+# must add it to their list of dependencies when creating their own ${qtmodule}Config.cmake
+function(qt_install_static_target_export target)
+ if(BUILD_SHARED_LIBS)
+ return()
+ endif()
+
+ qt_parse_all_arguments(arg "qt_install_3rdparty_config_files" "" "EXPORT" "" ${ARGN})
+ # TODO mark EXPORT as required
+
+ set_target_properties(${target}
+ PROPERTIES
+ INTERFACE_QT_EXPORTED_LIBRARY 1)
+
+ qt_path_join(config_install_dir ${QT_CONFIG_INSTALL_DIR} ${arg_EXPORT})
+
+ set(export_name "${arg_EXPORT}Targets")
+ qt_install(
+ TARGETS ${target}
+ EXPORT ${export_name}
+ LIBRARY DESTINATION ${INSTALL_LIBDIR}
+ ARCHIVE DESTINATION ${INSTALL_LIBDIR})
+
+ qt_install(
+ EXPORT ${export_name}
+ DESTINATION "${config_install_dir}"
+ )
+endfunction()
+
+# Create a set of ${target}Config.cmake and ${target}Version.cmake for a
+# third-party library so that it can be found by client code linking statically.
+function(qt_install_3rdparty_config_files target)
+ if(BUILD_SHARED_LIBS)
+ return()
+ endif()
+
+ qt_parse_all_arguments(arg "qt_install_3rdparty_config_files" "" "EXPORT" "PACKAGES;ADDITIONAL_FILES" ${ARGN})
+ # TODO mark EXPORT as required
+
+ set(3RDPARTY_ADDITIONAL_SETUP_CODE)
+ foreach(package ${arg_PACKAGES})
+ list(APPEND 3RDPARTY_ADDITIONAL_SETUP_CODE "find_package(${package})\n")
+ endforeach()
+
+ set(path_suffix "${arg_EXPORT}")
+ qt_path_join(config_build_dir ${QT_CONFIG_BUILD_DIR} ${path_suffix})
+ qt_path_join(config_install_dir ${QT_CONFIG_INSTALL_DIR} ${path_suffix})
+
+ configure_package_config_file(
+ "${PROJECT_SOURCE_DIR}/cmake/3rdpartyConfig.cmake.in"
+ "${config_build_dir}/${target}Config.cmake"
+ INSTALL_DESTINATION "${config_install_dir}"
+ )
+
+ write_basic_package_version_file(
+ "${config_build_dir}/${target}ConfigVersion.cmake"
+ VERSION ${PROJECT_VERSION}
+ COMPATIBILITY AnyNewerVersion
+ )
+
+ qt_install(FILES
+ "${config_build_dir}/${target}Config.cmake"
+ "${config_build_dir}/${target}ConfigVersion.cmake"
+ ${arg_ADDITIONAL_FILES}
+ DESTINATION "${config_install_dir}"
+ COMPONENT Devel
+ )
+endfunction()
+
+# Call this function in 3rdparty find modules that ought to be installed alongside
+# Qt modules and must be found when linking statically.
+function(qt_install_3rdparty_library target)
+ qt_install_static_target_export(${target} EXPORT ${target})
+ qt_install_3rdparty_config_files(${target} EXPORT ${target} ${ARGN})
+endfunction()
+
+macro(qt_find_apple_system_frameworks)
+ if(APPLE)
+ find_library(FWAppKit AppKit)
+ find_library(FWAssetsLibrary AssetsLibrary)
+ find_library(FWAudioToolbox AudioToolbox)
+ find_library(FWApplicationServices ApplicationServices)
+ find_library(FWCarbon Carbon)
+ find_library(FWCoreFoundation CoreFoundation)
+ find_library(FWCoreServices CoreServices)
+ find_library(FWCoreGraphics CoreGraphics)
+ find_library(FWCoreText CoreText)
+ find_library(FWCoreVideo CoreVideo)
+ find_library(FWcups cups)
+ find_library(FWDiskArbitration DiskArbitration)
+ find_library(FWFoundation Foundation)
+ find_library(FWIOBluetooth IOBluetooth)
+ find_library(FWIOKit IOKit)
+ find_library(FWIOSurface IOSurface)
+ find_library(FWImageIO ImageIO)
+ find_library(FWMetal Metal)
+ find_library(FWMobileCoreServices MobileCoreServices)
+ find_library(FWQuartzCore QuartzCore)
+ find_library(FWSecurity Security)
+ find_library(FWSystemConfiguration SystemConfiguration)
+ find_library(FWUIKit UIKit)
+ find_library(FWWatchKit WatchKit)
+ find_library(FWGameController GameController)
+ endif()
+endmacro()
+
+# Match the pattern 'regex' in 'input_line', replace the match with 'replacement'
+# and set that result in 'out_var' in the parent scope.
+function(qt_regex_match_and_get input_line regex replacement out_var)
+ string(REGEX MATCH "${regex}" match "${input_line}")
+ if(match)
+ string(REGEX REPLACE "${regex}" "${replacement}" match "${input_line}")
+ string(STRIP ${match} match)
+ set(${out_var} "${match}" PARENT_SCOPE)
+ endif()
+endfunction()
+
+# Match 'regex' in a list of lines. When found, set the value to 'out_var' and break early.
+function(qt_qlalr_find_option_in_list input_list regex out_var)
+ foreach(line ${input_list})
+ qt_regex_match_and_get("${line}" "${regex}" "\\1" option)
+ if(option)
+ string(TOLOWER ${option} option)
+ set(${out_var} "${option}" PARENT_SCOPE)
+ return()
+ endif()
+ endforeach()
+ message(FATAL_ERROR "qt_qlalr_find_option_in_list: Could not extract ${out_var}")
+endfunction()
+
+# Generate a few output files using qlalr, and assign those to 'consuming_target'.
+# 'input_file_list' is a list of 'foo.g' file paths.
+# 'flags' are extra flags to be passed to qlalr.
+function(qt_process_qlalr consuming_target input_file_list flags)
+ foreach(input_file ${input_file_list})
+ file(STRINGS ${input_file} input_file_lines)
+ qt_qlalr_find_option_in_list("${input_file_lines}" "^%parser(.+)" "parser")
+ qt_qlalr_find_option_in_list("${input_file_lines}" "^%decl(.+)" "decl")
+ qt_qlalr_find_option_in_list("${input_file_lines}" "^%impl(.+)" "impl")
+ get_filename_component(base_file_name ${input_file} NAME_WE)
+
+ set(cpp_file "${parser}.cpp")
+ set(private_file "${parser}_p.h")
+ set(decl_file "${decl}")
+ set(impl_file "${impl}")
+ add_custom_command(
+ OUTPUT ${cpp_file} ${private_file} ${decl_file} ${impl_file}
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::qlalr ${flags} ${input_file}
+ MAIN_DEPENDENCY ${input_file}
+ )
+ target_sources(${consuming_target} PRIVATE ${cpp_file} ${impl_file})
+ endforeach()
+endfunction()
+
+macro(qt_add_string_to_qconfig_cpp str)
+ string(LENGTH "${str}" length)
+ string(APPEND QT_CONFIG_STRS " \"${str}\\0\"\n")
+ string(APPEND QT_CONFIG_STR_OFFSETS " ${QT_CONFIG_STR_OFFSET},\n")
+ math(EXPR QT_CONFIG_STR_OFFSET "${QT_CONFIG_STR_OFFSET}+${length}+1")
+endmacro()
+
+function(qt_generate_qconfig_cpp)
+ set(QT_CONFIG_STR_OFFSET "0")
+ set(QT_CONFIG_STR_OFFSETS "")
+ set(QT_CONFIG_STRS "")
+
+ # Start first part.
+ qt_add_string_to_qconfig_cpp("doc")
+ qt_add_string_to_qconfig_cpp("include")
+ qt_add_string_to_qconfig_cpp("lib")
+ qt_add_string_to_qconfig_cpp("libexec")
+ qt_add_string_to_qconfig_cpp("bin")
+ qt_add_string_to_qconfig_cpp("plugins")
+ qt_add_string_to_qconfig_cpp("qml")
+ qt_add_string_to_qconfig_cpp(".")
+ qt_add_string_to_qconfig_cpp(".")
+ qt_add_string_to_qconfig_cpp("translations")
+ qt_add_string_to_qconfig_cpp("examples")
+ qt_add_string_to_qconfig_cpp("tests")
+
+ # Save first part.
+ set(QT_CONFIG_STR_OFFSETS_FIRST "${QT_CONFIG_STR_OFFSETS}")
+ set(QT_CONFIG_STRS_FIRST "${QT_CONFIG_STRS}")
+
+ # Start second part.
+ set(QT_CONFIG_STR_OFFSETS "")
+ set(QT_CONFIG_STRS "")
+
+ qt_add_string_to_qconfig_cpp("")
+ qt_add_string_to_qconfig_cpp("false")
+ qt_add_string_to_qconfig_cpp("bin")
+ qt_add_string_to_qconfig_cpp("lib")
+ qt_add_string_to_qconfig_cpp(".")
+ qt_add_string_to_qconfig_cpp("${QT_QMAKE_TARGET_MKSPEC}")
+ qt_add_string_to_qconfig_cpp("${QT_QMAKE_HOST_MKSPEC}")
+
+ # Save second part.
+ set(QT_CONFIG_STR_OFFSETS_SECOND "${QT_CONFIG_STR_OFFSETS}")
+ set(QT_CONFIG_STRS_SECOND "${QT_CONFIG_STRS}")
+
+ # Settings path / sysconf dir.
+ if(APPLE)
+ set(QT_DEFAULT_SYS_CONF_DIR "/Library/Preferences/Qt")
+ else()
+ set(QT_DEFAULT_SYS_CONF_DIR "etc/xdg")
+ endif()
+
+ # Compute and set relocation prefixes.
+ # TODO: Clean this up, there's a bunch of unrealistic assumptions here.
+ # See qtConfOutput_preparePaths in qtbase/configure.pri.
+ if(WIN32)
+ set(lib_location_absolute_path "${CMAKE_INSTALL_PREFIX}/bin")
+ else()
+ set(lib_location_absolute_path "${CMAKE_INSTALL_PREFIX}/lib")
+ endif()
+ file(RELATIVE_PATH from_lib_location_to_prefix
+ "${lib_location_absolute_path}" "${CMAKE_INSTALL_PREFIX}")
+
+ if(QT_HOST_PATH)
+ set(host_prefix "${QT_HOST_PATH}")
+ set(host_bin_dir_absolute_path "${QT_HOST_PATH}/bin")
+ else()
+ set(host_prefix "${CMAKE_INSTALL_PREFIX}")
+ set(host_bin_dir_absolute_path "${CMAKE_INSTALL_PREFIX}/bin")
+ endif()
+
+ file(RELATIVE_PATH from_host_bin_dir_to_host_prefix
+ "${host_bin_dir_absolute_path}" "${host_prefix}")
+
+ # TODO: Fix this to use the equivalent of extprefix on CMake (CMAKE_STAGING_PREFIX?)
+ # For now just assume ext prefix is same as regular prefix.
+ file(RELATIVE_PATH from_host_bin_dir_to_ext_prefix
+ "${host_bin_dir_absolute_path}" "${CMAKE_INSTALL_PREFIX}")
+
+
+ set(QT_CONFIGURE_LIBLOCATION_TO_PREFIX_PATH "${from_lib_location_to_prefix}")
+ set(QT_CONFIGURE_HOSTBINDIR_TO_HOSTPREFIX_PATH "${from_host_bin_dir_to_host_prefix}")
+ set(QT_CONFIGURE_HOSTBINDIR_TO_EXTPREFIX_PATH "${from_host_bin_dir_to_ext_prefix}")
+
+ configure_file(global/qconfig.cpp.in global/qconfig.cpp @ONLY)
+endfunction()
+
+function(qt_set_language_standards)
+ ## Use the latest standard the compiler supports (same as qt_common.prf)
+ if (QT_FEATURE_cxx2a)
+ set(CMAKE_CXX_STANDARD 20 PARENT_SCOPE)
+ elseif (QT_FEATURE_cxx17)
+ set(CMAKE_CXX_STANDARD 17 PARENT_SCOPE)
+ elseif (QT_FEATURE_cxx14)
+ set(CMAKE_CXX_STANDARD 14 PARENT_SCOPE)
+ elseif (QT_FEATURE_cxx11)
+ set(CMAKE_CXX_STANDARD 11 PARENT_SCOPE)
+ endif()
+
+ if (c_std_11 IN_LIST CMAKE_C_COMPILE_FEATURES)
+ set(CMAKE_C_STANDARD 11 PARENT_SCOPE)
+ elseif (c_std_99 IN_LIST CMAKE_C_COMPILE_FEATURES)
+ set(CMAKE_C_STANDARD 99 PARENT_SCOPE)
+ endif()
+endfunction()
+
+# Compatibility macros that should be removed once all their usages are removed.
+function(extend_target)
+ qt_extend_target(${ARGV})
+endfunction()
+
+function(add_qt_module)
+ qt_add_module(${ARGV})
+endfunction()
+
+function(add_qt_plugin)
+ qt_add_plugin(${ARGV})
+endfunction()
+
+function(add_qt_tool)
+ qt_add_tool(${ARGV})
+endfunction()
+
+function(add_qt_test)
+ qt_add_test(${ARGV})
+endfunction()
+
+function(add_qt_test_helper)
+ qt_add_test_helper(${ARGV})
+endfunction()
+
+function(add_qt_manual_test)
+ qt_add_manual_test(${ARGV})
+endfunction()
+
+function(add_qt_benchmark)
+ qt_add_benchmark(${ARGV})
+endfunction()
+
+function(add_qt_executable)
+ qt_add_executable(${ARGV})
+endfunction()
+
+function(add_qt_simd_part)
+ qt_add_simd_part(${ARGV})
+endfunction()
+
+function(add_qt_docs)
+ qt_add_docs(${ARGV})
+endfunction()
+
+function(add_qt_resource)
+ qt_add_resource(${ARGV})
+endfunction()
+
+function(add_qml_module)
+ qt_add_qml_module(${ARGV})
+endfunction()
+
+function(add_cmake_library)
+ qt_add_cmake_library(${ARGV})
+endfunction()
diff --git a/cmake/QtBuildInformation.cmake b/cmake/QtBuildInformation.cmake
new file mode 100644
index 0000000000..097192b2ab
--- /dev/null
+++ b/cmake/QtBuildInformation.cmake
@@ -0,0 +1,35 @@
+function(qt_print_feature_summary)
+ include(FeatureSummary)
+ feature_summary(WHAT PACKAGES_FOUND
+ REQUIRED_PACKAGES_NOT_FOUND
+ RECOMMENDED_PACKAGES_NOT_FOUND
+ OPTIONAL_PACKAGES_NOT_FOUND
+ RUNTIME_PACKAGES_NOT_FOUND
+ FATAL_ON_MISSING_REQUIRED_PACKAGES)
+endfunction()
+
+function(qt_print_build_instructions)
+ if((NOT PROJECT_NAME STREQUAL "QtBase" AND
+ NOT PROJECT_NAME STREQUAL "Qt") OR
+ QT_BUILD_STANDALONE_TESTS)
+
+ return()
+ endif()
+
+ set(build_command "cmake --build . --parallel")
+ set(install_command "cmake --install .")
+
+ message("Qt is now configured for building. Just run '${build_command}'.")
+ if(QT_WILL_INSTALL)
+ message("Once everything is built, you must run '${install_command}'.")
+ message("Qt will be installed into '${CMAKE_INSTALL_PREFIX}'")
+ else()
+ message("Once everything is built, Qt is installed.")
+ message("You should NOT run '${install_command}'")
+ message("Note that this build cannot be deployed to other machines or devices.")
+ endif()
+ message("To configure and build other modules, you can use the following convenience script:
+ ${CMAKE_INSTALL_PREFIX}/${INSTALL_BINDIR}/qt-cmake")
+ message("\nIf reconfiguration fails for some reason, try to remove 'CMakeCache.txt' \
+from the build directory \n")
+endfunction()
diff --git a/cmake/QtBuildInternals/QtBuildInternalsAndroid.cmake b/cmake/QtBuildInternals/QtBuildInternalsAndroid.cmake
new file mode 100644
index 0000000000..51645f48d5
--- /dev/null
+++ b/cmake/QtBuildInternals/QtBuildInternalsAndroid.cmake
@@ -0,0 +1,217 @@
+#
+# Android specific functions/macros/properties required for building Qt Modules
+#
+
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_MODULE_INSTALL_DIR
+ BRIEF_DOCS
+ "Recorded install location for a Qt Module."
+ FULL_DOCS
+ "Recorded install location for a Qt Module. Used by qt_android_dependencies()."
+)
+
+
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_JAR_DEPENDENCIES
+ BRIEF_DOCS
+ "Qt Module Jar dependencies list."
+ FULL_DOCS
+ "Qt Module Jar dependencies list."
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_BUNDLED_JAR_DEPENDENCIES
+ BRIEF_DOCS
+ "Qt Module Jars that should be bundled with it during packing."
+ FULL_DOCS
+ "Qt Module Jars that should be bundled with it during packing."
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_LIB_DEPENDENCIES
+ BRIEF_DOCS
+ "Qt Module C++ libraries that should be bundled with it during packing."
+ FULL_DOCS
+ "Qt Module C++ libraries that should be bundled with it during packing."
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_LIB_DEPENDENCY_REPLACEMENTS
+ BRIEF_DOCS
+ "Qt Module C++ libraries that can replace libraries declared with the QT_ANDROID_LIB_DEPENDENCIES property."
+ FULL_DOCS
+ "Qt Module C++ libraries that can replace libraries declared with the QT_ANDROID_LIB_DEPENDENCIES property."
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_BUNDLED_FILES
+ BRIEF_DOCS
+ "Qt Module files that need to be bundled during packing."
+ FULL_DOCS
+ "Qt Module files that need to be bundled during packing."
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_PERMISSIONS
+ BRIEF_DOCS
+ "Qt Module android permission list."
+ FULL_DOCS
+ "Qt Module android permission list."
+)
+# Generate Qt Module -android-dependencies.xml required by the
+# androiddeploytoolqt to successfully copy all the plugins and other dependent
+# items into tha APK
+function(qt_android_dependencies target)
+ get_target_property(target_type "${target}" TYPE)
+ if(target_type STREQUAL "INTERFACE_LIBRARY")
+ return()
+ endif()
+
+ get_target_property(arg_JAR_DEPENDENCIES ${target} QT_ANDROID_JAR_DEPENDENCIES)
+ get_target_property(arg_BUNDLED_JAR_DEPENDENCIES ${target} QT_ANDROID_BUNDLED_JAR_DEPENDENCIES)
+ get_target_property(arg_LIB_DEPENDENCIES ${target} QT_ANDROID_LIB_DEPENDENCIES)
+ get_target_property(arg_LIB_DEPENDENCY_REPLACEMENTS ${target} QT_ANDROID_LIB_DEPENDENCY_REPLACEMENTS)
+ get_target_property(arg_BUNDLED_FILES ${target} QT_ANDROID_BUNDLED_FILES)
+ get_target_property(arg_PERMISSIONS ${target} QT_ANDROID_PERMISSIONS)
+ get_target_property(module_plugins ${target} MODULE_PLUGIN_TYPES)
+
+ if ((NOT module_plugins)
+ AND (NOT arg_JAR_DEPENDENCIES)
+ AND (NOT arg_LIB_DEPENDENCY_REPLACEMENTS)
+ AND (NOT arg_LIB_DEPENDENCIES)
+ AND (NOT arg_BUNDLED_JAR_DEPENDENCIES)
+ AND (NOT arg_PERMISSIONS)
+ AND (NOT arg_BUNDLED_FILES))
+ # None of the values were set, so there's nothing to do
+ return()
+ endif()
+
+
+ get_target_property(target_output_name ${target} OUTPUT_NAME)
+ if (NOT target_output_name)
+ set(target_name ${target})
+ else()
+ set(target_name ${target_output_name})
+ endif()
+
+ # mimic qmake's section and string splitting from
+ # mkspecs/feature/qt_android_deps.prf
+ macro(section string delimiter first second)
+ string(FIND ${string} ${delimiter} delimiter_location)
+ if (NOT ${delimiter_location} EQUAL -1)
+ string(SUBSTRING ${string} 0 ${delimiter_location} ${first})
+ math(EXPR delimiter_location "${delimiter_location} + 1")
+ string(SUBSTRING ${string} ${delimiter_location} -1 ${second})
+ else()
+ set(${first} ${string})
+ set(${second} "")
+ endif()
+ endmacro()
+
+ get_target_property(target_bin_dir ${target} BINARY_DIR)
+ set(dependency_file "${target_bin_dir}/${target_name}_${CMAKE_ANDROID_ARCH_ABI}-android-dependencies.xml")
+
+ set(file_contents "<rules><dependencies>\n")
+ string(APPEND file_contents "<lib name=\"${target_name}_${CMAKE_ANDROID_ARCH_ABI}\"><depends>\n")
+
+ # Jar Dependencies
+ if(arg_JAR_DEPENDENCIES)
+ foreach(jar_dependency IN LISTS arg_JAR_DEPENDENCIES)
+ section(${jar_dependency} ":" jar_file init_class)
+ if (init_class)
+ set(init_class "initClass=\"${init_class}\"")
+ endif()
+ file(TO_NATIVE_PATH ${jar_file} jar_file_native)
+ string(APPEND file_contents "<jar file=\"${jar_file_native}\" ${init_class} />\n")
+ endforeach()
+ endif()
+
+ # Bundled Jar Dependencies
+ if(arg_BUNDLED_JAR_DEPENDENCIES)
+ foreach(jar_bundle IN LISTS arg_BUNDLED_JAR_DEPENDENCIES)
+ section(${jar_bundle} ":" bundle_file init_calss)
+ if (init_class)
+ set(init_class "initClass=\"${init_class}\"")
+ endif()
+ file(TO_NATIVE_PATH ${jar_bundle} jar_bundle_native)
+ string(APPEND file_contents "<jar bundling=\"1\" file=\"${jar_bundle_native}\" ${init_class} />\n")
+ endforeach()
+ endif()
+
+ # Lib Dependencies
+ if(arg_LIB_DEPENDENCIES)
+ foreach(lib IN LISTS arg_LIB_DEPENDENCIES)
+ string(REPLACE ".so" "_${CMAKE_ANDROID_ARCH_ABI}.so" lib ${lib})
+ section(${lib} ":" lib_file lib_extends)
+ if (lib_extends)
+ set(lib_extends "extends=\"${lib_extends}\"")
+ endif()
+ file(TO_NATIVE_PATH ${lib_file} lib_file_native)
+ string(APPEND file_contents "<lib file=\"${lib_file_native}\" ${lib_extends} />\n")
+ endforeach()
+ endif()
+
+ # Lib Dependencies Replacements
+ if(arg_LIB_DEPENDENCY_REPLACEMENTS)
+ foreach(lib IN LISTS arg_LIB_DEPENDENCY_REPLACEMENTS)
+ string(REPLACE ".so" "_${CMAKE_ANDROID_ARCH_ABI}.so" lib ${lib})
+ section(${lib} ":" lib_file lib_replacement)
+ if (lib_replacement)
+ file(TO_NATIVE_PATH ${lib_replacement} lib_replacement_native)
+ set(lib_replacement "replaces=\"${lib_replacement_native}\"")
+ endif()
+ file(TO_NATIVE_PATH ${lib_file} lib_file_native)
+ string(APPEND file_contents "<lib file=\"${lib_file_native}\" ${lib_replacement} />\n")
+ endforeach()
+ endif()
+
+
+ # Bundled files
+ if(arg_BUNDLED_FILES)
+ foreach(file IN LISTS arg_BUNDLED_FILES)
+ file(TO_NATIVE_PATH ${lib_file} file_native)
+ string(APPEND file_contents "<bundled file=\"${file_native}\" />\n")
+ endforeach()
+ endif()
+
+ # Module plugins
+ if(module_plugins)
+ foreach(plugin IN LISTS module_plugins)
+ string(APPEND file_contents "<bundled file=\"plugins/${plugin}\" />\n")
+ endforeach()
+ endif()
+
+ # Android Permissions
+ if(arg_PERMISSIONS)
+ foreach(permission IN LISTS arg_PERMISSIONS)
+ string(APPEND file_contents "<permission name=\"${permission}\" />\n")
+ endforeach()
+ endif()
+
+ string(APPEND file_contents "</depends></lib>")
+ string(APPEND file_contents "</dependencies></rules>\n")
+ file(WRITE ${dependency_file} ${file_contents})
+
+ get_target_property(target_install_dir ${target} QT_ANDROID_MODULE_INSTALL_DIR)
+ if (NOT target_install_dir)
+ message(SEND_ERROR "qt_android_dependencies: Target ${target} is either not a Qt Module or has no recorded install location")
+ return()
+ endif()
+
+ # Copy file into install directory, required by the androiddeployqt tool.
+ qt_install(FILES
+ ${dependency_file}
+ DESTINATION
+ ${target_install_dir}
+ COMPONENT
+ Devel)
+endfunction()
+
+
diff --git a/cmake/QtBuildInternals/QtBuildInternalsConfig.cmake b/cmake/QtBuildInternals/QtBuildInternalsConfig.cmake
new file mode 100644
index 0000000000..2703e06fe5
--- /dev/null
+++ b/cmake/QtBuildInternals/QtBuildInternalsConfig.cmake
@@ -0,0 +1,237 @@
+if (CMAKE_VERSION VERSION_LESS 3.1.0)
+ message(FATAL_ERROR "Qt requires at least CMake version 3.1.0")
+endif()
+
+######################################
+#
+# Macros for building Qt modules
+#
+######################################
+
+if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/QtBuildInternalsExtra.cmake")
+ include(${CMAKE_CURRENT_LIST_DIR}/QtBuildInternalsExtra.cmake)
+endif()
+
+macro(qt_set_up_build_internals_paths)
+ # Set up the paths for the cmake modules located in the prefix dir. Prepend, so the paths are
+ # least important compared to the source dir ones, but more important than command line
+ # provided ones.
+ set(QT_CMAKE_MODULE_PATH "${QT_BUILD_INTERNALS_PATH}/../${QT_CMAKE_EXPORT_NAMESPACE}")
+ list(PREPEND CMAKE_MODULE_PATH "${QT_CMAKE_MODULE_PATH}")
+
+ # Prepend the qtbase source cmake directory to CMAKE_MODULE_PATH,
+ # so that if a change is done in cmake/QtBuild.cmake, it gets automatically picked up when
+ # building qtdeclarative, rather than having to build qtbase first (which will copy
+ # QtBuild.cmake to the build dir). This is similar to qmake non-prefix builds, where the
+ # source qtbase/mkspecs directory is used.
+ if(EXISTS "${QT_SOURCE_TREE}/cmake")
+ list(PREPEND CMAKE_MODULE_PATH "${QT_SOURCE_TREE}/cmake")
+ endif()
+
+ # If the repo has its own cmake modules, include those in the module path.
+ if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
+ list(PREPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
+ endif()
+
+ # Find the cmake files when doing a standalone tests build.
+ if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/../cmake")
+ list(PREPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/../cmake")
+ endif()
+endmacro()
+
+# Set up the build internal paths unless explicitly requested not to.
+if(NOT QT_BUILD_INTERNALS_SKIP_CMAKE_MODULE_PATH_ADDITION)
+ qt_set_up_build_internals_paths()
+endif()
+
+# Define some constants to check for certain platforms, etc.
+# Needs to be loaded before qt_repo_build() to handle require() clauses before even starting a repo
+# build.
+include(QtPlatformSupport)
+
+macro(qt_build_repo_begin)
+ # Qt specific setup common for all modules:
+ include(QtSetup)
+ include(FeatureSummary)
+
+ # Optionally include a repo specific Setup module.
+ include(${PROJECT_NAME}Setup OPTIONAL)
+ include(QtRepoSetup OPTIONAL)
+
+ # Find Apple frameworks if needed.
+ qt_find_apple_system_frameworks()
+
+ # Decide whether tools will be built.
+ qt_check_if_tools_will_be_built()
+
+
+ string(TOLOWER ${PROJECT_NAME} project_name_lower)
+
+ set(qt_docs_target_name docs_${project_name_lower})
+ set(qt_docs_prepare_target_name prepare_docs_${project_name_lower})
+ set(qt_docs_generate_target_name generate_docs_${project_name_lower})
+ set(qt_docs_html_target_name html_docs_${project_name_lower})
+ set(qt_docs_qch_target_name qch_docs_${project_name_lower})
+ set(qt_docs_install_html_target_name install_html_docs_${project_name_lower})
+ set(qt_docs_install_qch_target_name install_qch_docs_${project_name_lower})
+ set(qt_docs_install_target_name install_docs_${project_name_lower})
+
+ add_custom_target(${qt_docs_target_name})
+ add_custom_target(${qt_docs_prepare_target_name})
+ add_custom_target(${qt_docs_generate_target_name})
+ add_custom_target(${qt_docs_qch_target_name})
+ add_custom_target(${qt_docs_html_target_name})
+ add_custom_target(${qt_docs_install_html_target_name})
+ add_custom_target(${qt_docs_install_qch_target_name})
+ add_custom_target(${qt_docs_install_target_name})
+
+ add_dependencies(${qt_docs_generate_target_name} ${qt_docs_prepare_target_name})
+ add_dependencies(${qt_docs_html_target_name} ${qt_docs_generate_target_name})
+ add_dependencies(${qt_docs_target_name} ${qt_docs_html_target_name} ${qt_docs_qch_target_name})
+ add_dependencies(${qt_docs_install_html_target_name} ${qt_docs_html_target_name})
+ add_dependencies(${qt_docs_install_qch_target_name} ${qt_docs_qch_target_name})
+ add_dependencies(${qt_docs_install_target_name} ${qt_docs_install_html_target_name} ${qt_docs_install_qch_target_name})
+endmacro()
+
+macro(qt_build_repo_end)
+ include(QtBuildInformation)
+
+ if(NOT QT_BUILD_STANDALONE_TESTS)
+ # Delayed actions on some of the Qt targets:
+ include(QtPostProcess)
+
+ # Install the repo-specific cmake find modules.
+ qt_path_join(__qt_repo_install_dir ${QT_CONFIG_INSTALL_DIR} ${INSTALL_CMAKE_NAMESPACE})
+
+ if(NOT PROJECT_NAME STREQUAL "QtBase")
+ if (EXISTS cmake)
+ qt_copy_or_install(DIRECTORY cmake/
+ DESTINATION "${__qt_repo_install_dir}"
+ FILES_MATCHING PATTERN "Find*.cmake"
+ )
+ endif()
+ endif()
+
+ if(NOT QT_SUPERBUILD)
+ qt_print_feature_summary()
+ endif()
+ endif()
+
+ if(NOT QT_SUPERBUILD)
+ qt_print_build_instructions()
+ endif()
+endmacro()
+
+macro(qt_build_repo)
+ qt_build_repo_begin(${ARGN})
+
+ # If testing is enabled, try to find the qtbase Test package.
+ # Do this before adding src, because there might be test related conditions
+ # in source.
+ if (BUILD_TESTING AND NOT QT_BUILD_STANDALONE_TESTS)
+ find_package(Qt6 ${PROJECT_VERSION} CONFIG REQUIRED COMPONENTS Test)
+ endif()
+
+ if(NOT QT_BUILD_STANDALONE_TESTS)
+ if (EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/src/CMakeLists.txt")
+ add_subdirectory(src)
+ endif()
+
+ if (EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/tools/CMakeLists.txt")
+ add_subdirectory(tools)
+ endif()
+ endif()
+
+ if (BUILD_TESTING AND EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/tests/CMakeLists.txt")
+ add_subdirectory(tests)
+ if(QT_NO_MAKE_TESTS)
+ set_property(DIRECTORY tests PROPERTY EXCLUDE_FROM_ALL TRUE)
+ endif()
+ endif()
+
+ qt_build_repo_end()
+
+ if (BUILD_EXAMPLES AND BUILD_SHARED_LIBS
+ AND EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/examples/CMakeLists.txt"
+ AND NOT QT_BUILD_STANDALONE_TESTS)
+ add_subdirectory(examples)
+ if(QT_NO_MAKE_EXAMPLES)
+ set_property(DIRECTORY examples PROPERTY EXCLUDE_FROM_ALL TRUE)
+ endif()
+ endif()
+endmacro()
+
+macro(qt_set_up_standalone_tests_build)
+ # Remove this macro once all usages of it have been removed.
+ # Standalone tests are not handled via the main repo project and qt_build_tests.
+endmacro()
+
+macro(qt_build_tests)
+ if(QT_BUILD_STANDALONE_TESTS)
+ # Find location of TestsConfig.cmake. These contain the modules that need to be
+ # find_package'd when testing.
+ set(_qt_build_tests_install_prefix
+ "${QT_CONFIG_INSTALL_DIR}/${INSTALL_CMAKE_NAMESPACE}BuildInternals/StandaloneTests")
+ if(QT_WILL_INSTALL)
+ qt_path_join(_qt_build_tests_install_prefix
+ ${CMAKE_INSTALL_PREFIX} ${_qt_build_tests_install_prefix})
+ endif()
+ include("${_qt_build_tests_install_prefix}/${PROJECT_NAME}TestsConfig.cmake" OPTIONAL)
+
+ # Of course we always need the test module as well.
+ find_package(Qt6 ${PROJECT_VERSION} CONFIG REQUIRED COMPONENTS Test)
+ endif()
+
+ if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/auto/CMakeLists.txt")
+ add_subdirectory(auto)
+ endif()
+ if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/benchmarks/CMakeLists.txt" AND QT_BUILD_BENCHMARKS)
+ add_subdirectory(benchmarks)
+ endif()
+ if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/manual/CMakeLists.txt")
+ add_subdirectory(manual)
+ endif()
+endmacro()
+
+macro(qt_examples_build_begin)
+ # Examples that are built as part of the Qt build need to use the CMake config files from the
+ # build dir, because they are not installed yet in a prefix build.
+ # Appending to CMAKE_PREFIX_PATH helps find the initial Qt6Config.cmake.
+ # Appending to QT_EXAMPLES_CMAKE_PREFIX_PATH helps find components of Qt6, because those
+ # find_package calls use NO_DEFAULT_PATH, and thus CMAKE_PREFIX_PATH is ignored.
+ list(APPEND CMAKE_PREFIX_PATH "${QT_BUILD_DIR}")
+ list(APPEND QT_EXAMPLES_CMAKE_PREFIX_PATH "${QT_BUILD_DIR}")
+ # Also make sure the CMake config files do not recreate the already-existing targets
+ set(QT_NO_CREATE_TARGETS TRUE)
+ set(BACKUP_CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ${CMAKE_FIND_ROOT_PATH_MODE_PACKAGE})
+ set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE "BOTH")
+endmacro()
+
+macro(qt_examples_build_end)
+ # We use AUTOMOC/UIC/RCC in the examples. Make sure to not fail on a fresh Qt build, that e.g. the moc binary does not exist yet.
+
+ # This function gets all targets below this directory
+ function(get_all_targets _result _dir)
+ get_property(_subdirs DIRECTORY "${_dir}" PROPERTY SUBDIRECTORIES)
+ foreach(_subdir IN LISTS _subdirs)
+ get_all_targets(${_result} "${_subdir}")
+ endforeach()
+ get_property(_sub_targets DIRECTORY "${_dir}" PROPERTY BUILDSYSTEM_TARGETS)
+ set(${_result} ${${_result}} ${_sub_targets} PARENT_SCOPE)
+ endfunction()
+
+ get_all_targets(targets "${CMAKE_CURRENT_SOURCE_DIR}")
+
+ foreach(target ${targets})
+ qt_autogen_tools(${target} ENABLE_AUTOGEN_TOOLS "moc" "rcc")
+ if(TARGET Qt::Widgets)
+ qt_autogen_tools(${target} ENABLE_AUTOGEN_TOOLS "uic")
+ endif()
+ endforeach()
+
+ set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ${BACKUP_CMAKE_FIND_ROOT_PATH_MODE_PACKAGE})
+endmacro()
+
+if (ANDROID)
+ include(${CMAKE_CURRENT_LIST_DIR}/QtBuildInternalsAndroid.cmake)
+endif()
diff --git a/cmake/QtBuildInternalsExtra.cmake.in b/cmake/QtBuildInternalsExtra.cmake.in
new file mode 100644
index 0000000000..68e1271781
--- /dev/null
+++ b/cmake/QtBuildInternalsExtra.cmake.in
@@ -0,0 +1,35 @@
+# Propagate common variables via BuildInternals package.
+set(QT_BUILD_SHARED_LIBS @BUILD_SHARED_LIBS@)
+option(BUILD_SHARED_LIBS "Build Qt statically or dynamically" @BUILD_SHARED_LIBS@)
+set(QT_CMAKE_EXPORT_NAMESPACE @QT_CMAKE_EXPORT_NAMESPACE@)
+set(INSTALL_CMAKE_NAMESPACE @INSTALL_CMAKE_NAMESPACE@)
+set(CMAKE_BUILD_TYPE @CMAKE_BUILD_TYPE@)
+set(QT_BUILD_INTERNALS_PATH "${CMAKE_CURRENT_LIST_DIR}")
+
+# Propagate the original install prefix, so that a developer building a child module can
+# specify CMAKE_PREFIX_PATH for finding the Qt modules instead of CMAKE_INSTALL_PREFIX.
+set(CMAKE_INSTALL_PREFIX @CMAKE_INSTALL_PREFIX@ CACHE PATH
+ "Install path prefix, prepended onto install directories." FORCE)
+
+# Propagate developer builds to other modules via BuildInternals package.
+if(@FEATURE_developer_build@)
+ set(FEATURE_developer_build ON CACHE BOOL "Developer build." FORCE)
+endif()
+
+# Propagate non-prefix builds.
+set(QT_WILL_INSTALL @QT_WILL_INSTALL@ CACHE BOOL
+ "Boolean indicating if doing a Qt prefix build (vs non-prefix build)." FORCE)
+
+set(QT_SOURCE_TREE "@QT_SOURCE_TREE@" CACHE PATH
+"A path to the source tree of the previously configured QtBase project." FORCE)
+
+# Propagate decision of building tests and examples to other repositories.
+set(BUILD_TESTING @BUILD_TESTING@ CACHE BOOL "Build the testing tree.")
+set(BUILD_EXAMPLES @BUILD_EXAMPLES@ CACHE BOOL "Build Qt examples")
+set(QT_NO_MAKE_TESTS @QT_NO_MAKE_TESTS@ CACHE BOOL
+ "Should tests be built as part of the default 'all' target.")
+set(QT_NO_MAKE_EXAMPLES @QT_NO_MAKE_EXAMPLES@ CACHE BOOL
+ "Should examples be built as part of the default 'all' target.")
+
+# Extra set of exported variables
+@QT_EXTRA_BUILD_INTERNALS_VARS@
diff --git a/cmake/QtCompilerFlags.cmake b/cmake/QtCompilerFlags.cmake
new file mode 100644
index 0000000000..35733027f5
--- /dev/null
+++ b/cmake/QtCompilerFlags.cmake
@@ -0,0 +1,6 @@
+# Set warnings. All compilers except MSVC support -Wall -Wextra
+if (MSVC)
+ add_compile_options(/W3)
+else()
+ add_compile_options(-Wall -Wextra)
+endif()
diff --git a/cmake/QtCompilerOptimization.cmake b/cmake/QtCompilerOptimization.cmake
new file mode 100644
index 0000000000..f1ebafc009
--- /dev/null
+++ b/cmake/QtCompilerOptimization.cmake
@@ -0,0 +1,123 @@
+if (QCC)
+ set(QT_CFLAGS_SSE2 "-msse2")
+ set(QT_CFLAGS_SSE3 "-msse3")
+ set(QT_CFLAGS_SSSE3 "-mssse3")
+ set(QT_CFLAGS_SSE4_1 "-msse4.1")
+ set(QT_CFLAGS_SSE4_2 "-msse4.2")
+ set(QT_CFLAGS_AVX "-mavx")
+ set(QT_CFLAGS_AVX2 "-mavx2")
+ set(QT_CFLAGS_AESNI "-maes")
+ set(QT_CFLAGS_SHANI "-msha")
+endif()
+
+if (MSVC)
+ if (QT_64BIT)
+ # SSE2 is mandatory on 64-bit mode, so skip the option. It triggers:
+ # cl : Command line warning D9002 : ignoring unknown option '-arch:SSE2'
+ set(QT_CFLAGS_SSE2 "")
+ else()
+ set(QT_CFLAGS_SSE2 "-arch:SSE2")
+ endif()
+ set(QT_CFLAGS_SSE3 "${QT_CFLAGS_SSE2}")
+ set(QT_CFLAGS_SSSE3 "${QT_CFLAGS_SSE2}")
+ set(QT_CFLAGS_SSE4_1 "${QT_CFLAGS_SSE2}")
+ set(QT_CFLAGS_SSE4_2 "${QT_CFLAGS_SSE2}")
+ set(QT_CFLAGS_AESNI "${QT_CFLAGS_SSE2}")
+ set(QT_CFLAGS_SHANI "${QT_CFLAGS_SSE2}")
+
+ # FIXME to be Visual Studio version specific, like in mkspecs/common/msvc-version.conf
+ set(QT_CFLAGS_AVX "-arch:AVX")
+ set(QT_CFLAGS_AVX2 "-arch:AVX2")
+ set(QT_CFLAGS_F16C "-arch:AVX")
+ set(QT_CFLAGS_RDRND "")
+ set(QT_CFLAGS_AVX512F "-arch:AVX512")
+ set(QT_CFLAGS_AVX512ER "-arch:AVX512")
+ set(QT_CFLAGS_AVX512CD "-arch:AVX512")
+ set(QT_CFLAGS_AVX512PF "-arch:AVX512")
+ set(QT_CFLAGS_AVX512DQ "-arch:AVX512")
+ set(QT_CFLAGS_AVX512BW "-arch:AVX512")
+ set(QT_CFLAGS_AVX512VL "-arch:AVX512")
+ set(QT_CFLAGS_AVX512IFMA "-arch:AVX512")
+ set(QT_CFLAGS_AVX512VBMI "-arch:AVX512")
+endif()
+
+if(GCC OR CLANG)
+ set(QT_CFLAGS_SSE2 "-msse2")
+ set(QT_CFLAGS_SSE3 "-msse3")
+ set(QT_CFLAGS_SSSE3 "-mssse3")
+ set(QT_CFLAGS_SSE4_1 "-msse4.1")
+ set(QT_CFLAGS_SSE4_2 "-msse4.2")
+ set(QT_CFLAGS_F16C "-mf16c")
+ set(QT_CFLAGS_RDRND "-mrdrnd")
+ set(QT_CFLAGS_AVX "-mavx")
+ set(QT_CFLAGS_AVX2 "-mavx2")
+ set(QT_CFLAGS_AVX512F "-mavx512f")
+ set(QT_CFLAGS_AVX512ER "-mavx512er")
+ set(QT_CFLAGS_AVX512CD "-mavx512cd")
+ set(QT_CFLAGS_AVX512PF "-mavx512pf")
+ set(QT_CFLAGS_AVX512DQ "-mavx512dq")
+ set(QT_CFLAGS_AVX512BW "-mavx512bw")
+ set(QT_CFLAGS_AVX512VL "-mavx512vl")
+ set(QT_CFLAGS_AVX512IFMA "-mavx512ifma")
+ set(QT_CFLAGS_AVX512VBMI "-mavx512vbmi")
+ set(QT_CFLAGS_AESNI "-maes")
+ set(QT_CFLAGS_SHANI "-msha")
+ if(NOT APPLE_UIKIT)
+ set(QT_CFLAGS_NEON "-mfpu=neon")
+ endif()
+ set(QT_CFLAGS_MIPS_DSP "-mdsp")
+ set(QT_CFLAGS_MIPS_DSPR2 "-mdspr2")
+endif()
+
+if (winrt) # FIXME: Correct variable
+ set(QT_CFLAGS_SSE2 "-arch:SSE2")
+ set(QT_CFLAGS_SSE3 "-arch:SSE2")
+ set(QT_CFLAGS_SSSE3 "-arch:SSE2")
+ set(QT_CFLAGS_SSE4_1 "-arch:SSE2")
+ set(QT_CFLAGS_SSE4_2 "-arch:SSE2")
+ set(QT_CFLAGS_AVX "-arch:AVX")
+ set(QT_CFLAGS_AVX2 "-arch:AVX")
+ set(QT_CFLAGS_AESNI "-arch:SSE2")
+ set(QT_CFLAGS_SHANI "-arch:SSE2")
+endif()
+
+if (ICC)
+ if (MSVC)
+ set(QT_CFLAGS_SSE2 "-QxSSE2")
+ set(QT_CFLAGS_SSE3 "-QxSSE3")
+ set(QT_CFLAGS_SSSE3 "-QxSSSE3")
+ set(QT_CFLAGS_SSE4_1 "-QxSSE4.1")
+ set(QT_CFLAGS_SSE4_2 "-QxSSE4.2")
+ set(QT_CFLAGS_AVX "-QxAVX")
+ set(QT_CFLAGS_AVX2 "-QxCORE-AVX2")
+ set(QT_CFLAGS_AVX512F "-QxCOMMON-AVX512")
+ set(QT_CFLAGS_AVX512CD "-QxCOMMON-AVX512")
+ set(QT_CFLAGS_AVX512ER "-QxMIC-AVX512")
+ set(QT_CFLAGS_AVX512PF "-QxMIC-AVX512")
+ set(QT_CFLAGS_AVX512DQ "-QxCORE-AVX512")
+ set(QT_CFLAGS_AVX512BW "-QxCORE-AVX512")
+ set(QT_CFLAGS_AVX512VL "-QxCORE-AVX512")
+ set(QT_CFLAGS_F16C "${QT_CFLAGS_AVX2}")
+ set(QT_CFLAGS_AESNI "-QxSSE2")
+ set(QT_CFLAGS_SHANI "-QxSSE4.2")
+ else()
+ set(QT_CFLAGS_SSE2 "-msse2")
+ set(QT_CFLAGS_SSE3 "-msse3")
+ set(QT_CFLAGS_SSSE3 "-mssse3")
+ set(QT_CFLAGS_SSE4_1 "-msse4.1")
+ set(QT_CFLAGS_SSE4_2 "-msse4.2")
+ set(QT_CFLAGS_AVX "-march=core-avx")
+ set(QT_CFLAGS_AVX2 "-march=core-avx2")
+ set(QT_CFLAGS_AVX512F "-march=broadwell -xCOMMON-AVX512")
+ set(QT_CFLAGS_AVX512CD "-march=broadwell -xCOMMON-AVX512")
+ set(QT_CFLAGS_AVX512ER "-march=knl")
+ set(QT_CFLAGS_AVX512PF "-march=knl")
+ set(QT_CFLAGS_AVX512DQ "-march=skylake-avx512")
+ set(QT_CFLAGS_AVX512BW "-march=skylake-avx512")
+ set(QT_CFLAGS_AVX512VL "-march=skylake-avx512")
+ set(QT_CFLAGS_AESNI "-maes")
+ set(QT_CFLAGS_F16C "${QT_CFLAGS_AVX2}")
+ set(QT_CFLAGS_RDRND "-mrdrnd")
+ set(QT_CFLAGS_SHANI "-msha")
+ endif()
+endif()
diff --git a/cmake/QtConfig.cmake.in b/cmake/QtConfig.cmake.in
new file mode 100644
index 0000000000..6d69c1f90e
--- /dev/null
+++ b/cmake/QtConfig.cmake.in
@@ -0,0 +1,59 @@
+@PACKAGE_INIT@
+
+# Slightly amended version of ./src/corelib/Qt6Config.cmake.in
+if (CMAKE_VERSION VERSION_LESS 3.1.0)
+ message(FATAL_ERROR "Qt requires at least CMake version 3.1.0")
+endif()
+
+get_filename_component(_qt_cmake_dir "${CMAKE_CURRENT_LIST_DIR}/.." ABSOLUTE)
+set(_qt_@PROJECT_VERSION_MAJOR@_config_cmake_dir "${CMAKE_CURRENT_LIST_DIR}")
+
+if (NOT QT_NO_CREATE_TARGETS)
+ include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@Targets.cmake")
+ if(NOT QT_NO_CREATE_VERSIONLESS_TARGETS)
+ include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@VersionlessTargets.cmake")
+ endif()
+else()
+ # For examples using `find_package(...)` inside their CMakeLists.txt files:
+ # Make CMake's AUTOGEN detect this Qt version properly
+ set_directory_properties(PROPERTIES
+ QT_VERSION_MAJOR @PROJECT_VERSION_MAJOR@
+ QT_VERSION_MINOR @PROJECT_VERSION_MINOR@
+ QT_VERSION_PATCH @PROJECT_VERSION_PATCH@)
+endif()
+
+# if (NOT @INSTALL_CMAKE_NAMESPACE@_FIND_COMPONENTS)
+# set(@INSTALL_CMAKE_NAMESPACE@_NOT_FOUND_MESSAGE "The Qt package requires at least one component")
+# set(@INSTALL_CMAKE_NAMESPACE@_FOUND False)
+# return()
+# endif()
+
+get_filename_component(_qt_import_prefix "${CMAKE_CURRENT_LIST_FILE}" PATH)
+get_filename_component(_qt_import_prefix "${_qt_import_prefix}" REALPATH)
+list(APPEND CMAKE_MODULE_PATH "${_qt_import_prefix}")
+list(APPEND CMAKE_MODULE_PATH "${_qt_import_prefix}/3rdparty/extra-cmake-modules/find-modules")
+list(APPEND CMAKE_MODULE_PATH "${_qt_import_prefix}/3rdparty/kwin")
+
+foreach(module ${@INSTALL_CMAKE_NAMESPACE@_FIND_COMPONENTS})
+ find_package(@INSTALL_CMAKE_NAMESPACE@${module}
+ ${_@INSTALL_CMAKE_NAMESPACE@_FIND_PARTS_QUIET}
+ ${_@INSTALL_CMAKE_NAMESPACE@_FIND_PARTS_REQUIRED}
+ PATHS ${_qt_cmake_dir} ${QT_EXAMPLES_CMAKE_PREFIX_PATH} NO_DEFAULT_PATH
+ )
+ if (NOT @INSTALL_CMAKE_NAMESPACE@${module}_FOUND)
+ string(CONFIGURE ${_qt5_module_location_template} _expected_module_location @ONLY)
+
+ if (@INSTALL_CMAKE_NAMESPACE@_FIND_REQUIRED_${module})
+ set(_Qt_NOTFOUND_MESSAGE "${_Qt_NOTFOUND_MESSAGE}Failed to find Qt component \"${module}\" config file at \"${_expected_module_location}\"\n")
+ elseif(NOT @INSTALL_CMAKE_NAMESPACE@_FIND_QUIETLY)
+ message(WARNING "Failed to find Qt component \"${module}\" config file at \"${_expected_module_location}\"")
+ endif()
+
+ unset(_expected_module_location)
+ endif()
+endforeach()
+
+if (_Qt_NOTFOUND_MESSAGE)
+ set(@INSTALL_CMAKE_NAMESPACE@_NOT_FOUND_MESSAGE "${_Qt_NOTFOUND_MESSAGE}")
+ set(@INSTALL_CMAKE_NAMESPACE@_FOUND False)
+endif()
diff --git a/cmake/QtFeature.cmake b/cmake/QtFeature.cmake
new file mode 100644
index 0000000000..faca42635c
--- /dev/null
+++ b/cmake/QtFeature.cmake
@@ -0,0 +1,760 @@
+function(qt_feature_module_begin)
+ qt_parse_all_arguments(arg "qt_feature_module_begin"
+ "NO_MODULE" "LIBRARY;PRIVATE_FILE;PUBLIC_FILE" "PUBLIC_DEPENDENCIES;PRIVATE_DEPENDENCIES" ${ARGN})
+
+ if ("${arg_LIBRARY}" STREQUAL "" AND (NOT ${arg_NO_MODULE}))
+ message(FATAL_ERROR "qt_feature_begin_module needs a LIBRARY name! (or specify NO_MODULE)")
+ endif()
+ if ("${arg_PUBLIC_FILE}" STREQUAL "")
+ message(FATAL_ERROR "qt_feature_begin_module needs a PUBLIC_FILE name!")
+ endif()
+ if ("${arg_PRIVATE_FILE}" STREQUAL "")
+ message(FATAL_ERROR "qt_feature_begin_module needs a PRIVATE_FILE name!")
+ endif()
+
+ set(__QtFeature_library "${arg_LIBRARY}" PARENT_SCOPE)
+ set(__QtFeature_public_features "" PARENT_SCOPE)
+ set(__QtFeature_private_features "" PARENT_SCOPE)
+ set(__QtFeature_internal_features "" PARENT_SCOPE)
+
+ set(__QtFeature_private_file "${arg_PRIVATE_FILE}" PARENT_SCOPE)
+ set(__QtFeature_public_file "${arg_PUBLIC_FILE}" PARENT_SCOPE)
+
+ set(__QtFeature_private_extra "" PARENT_SCOPE)
+ set(__QtFeature_public_extra "" PARENT_SCOPE)
+
+ set(__QtFeature_config_definitions "" PARENT_SCOPE)
+
+ set(__QtFeature_define_definitions "" PARENT_SCOPE)
+endfunction()
+
+function(qt_feature_normalize_name name out_var)
+ # Normalize the feature name to something CMake can deal with.
+ if(name MATCHES "c\\+\\+")
+ string(REGEX REPLACE "[^a-zA-Z0-9_]" "x" name "${name}")
+ else()
+ string(REGEX REPLACE "[^a-zA-Z0-9_]" "_" name "${name}")
+ endif()
+ set(${out_var} "${name}" PARENT_SCOPE)
+endfunction()
+
+function(qt_feature feature)
+ set(original_name "${feature}")
+ qt_feature_normalize_name("${feature}" feature)
+ set_property(GLOBAL PROPERTY QT_FEATURE_ORIGINAL_NAME_${feature} "${original_name}")
+
+ qt_parse_all_arguments(arg "qt_feature"
+ "PRIVATE;PUBLIC"
+ "LABEL;PURPOSE;SECTION;" "AUTODETECT;CONDITION;ENABLE;DISABLE;EMIT_IF" ${ARGN})
+
+ set(_QT_FEATURE_DEFINITION_${feature} ${ARGN} PARENT_SCOPE)
+
+ # Register feature for future use:
+ if (arg_PUBLIC)
+ list(APPEND __QtFeature_public_features "${feature}")
+ endif()
+ if (arg_PRIVATE)
+ list(APPEND __QtFeature_private_features "${feature}")
+ endif()
+ if (NOT arg_PUBLIC AND NOT arg_PRIVATE)
+ list(APPEND __QtFeature_internal_features "${feature}")
+ endif()
+
+
+ set(__QtFeature_public_features ${__QtFeature_public_features} PARENT_SCOPE)
+ set(__QtFeature_private_features ${__QtFeature_private_features} PARENT_SCOPE)
+ set(__QtFeature_internal_features ${__QtFeature_internal_features} PARENT_SCOPE)
+endfunction()
+
+function(qt_evaluate_to_boolean expressionVar)
+ if(${${expressionVar}})
+ set(${expressionVar} ON PARENT_SCOPE)
+ else()
+ set(${expressionVar} OFF PARENT_SCOPE)
+ endif()
+endfunction()
+
+function(qt_evaluate_config_expression resultVar)
+ set(result "")
+ set(nestingLevel 0)
+ set(skipNext OFF)
+ set(expression "${ARGN}")
+ list(LENGTH expression length)
+
+ math(EXPR length "${length}-1")
+ foreach(memberIdx RANGE ${length})
+ if(${skipNext})
+ set(skipNext OFF)
+ continue()
+ endif()
+
+ list(GET expression ${memberIdx} member)
+
+ if("${member}" STREQUAL "(")
+ if(${nestingLevel} GREATER 0)
+ list(APPEND result ${member})
+ endif()
+ math(EXPR nestingLevel "${nestingLevel} + 1")
+ continue()
+ elseif("${member}" STREQUAL ")")
+ math(EXPR nestingLevel "${nestingLevel} - 1")
+ if(nestingLevel LESS 0)
+ break()
+ endif()
+ if(${nestingLevel} EQUAL 0)
+ qt_evaluate_config_expression(result ${result})
+ else()
+ list(APPEND result ${member})
+ endif()
+ continue()
+ elseif(${nestingLevel} GREATER 0)
+ list(APPEND result ${member})
+ continue()
+ elseif("${member}" STREQUAL "NOT")
+ list(APPEND result ${member})
+ continue()
+ elseif("${member}" STREQUAL "AND")
+ qt_evaluate_to_boolean(result)
+ if(NOT ${result})
+ break()
+ endif()
+ set(result "")
+ elseif("${member}" STREQUAL "OR")
+ qt_evaluate_to_boolean(result)
+ if(${result})
+ break()
+ endif()
+ set(result "")
+ elseif("${member}" STREQUAL "STREQUAL" AND memberIdx LESS ${length})
+ # Unfortunately the semantics for STREQUAL in if() are broken when the
+ # RHS is an empty string and the parameters to if are coming through a variable.
+ # So we expect people to write the empty string with single quotes and then we
+ # do the comparison manually here.
+ list(LENGTH result lhsIndex)
+ math(EXPR lhsIndex "${lhsIndex}-1")
+ list(GET result ${lhsIndex} lhs)
+ list(REMOVE_AT result ${lhsIndex})
+ set(lhs "${${lhs}}")
+
+ math(EXPR rhsIndex "${memberIdx}+1")
+ set(skipNext ON)
+
+ list(GET expression ${rhsIndex} rhs)
+ # We can't pass through an empty string with double quotes through various
+ # stages of substitution, so instead it is represented using single quotes
+ # and resolve here.
+ string(REGEX REPLACE "'(.*)'" "\\1" rhs "${rhs}")
+
+ string(COMPARE EQUAL "${lhs}" "${rhs}" stringCompareResult)
+ list(APPEND result ${stringCompareResult})
+ else()
+ string(FIND "${member}" "QT_FEATURE_" idx)
+ if(idx EQUAL 0)
+ # Remove the QT_FEATURE_ prefix
+ string(SUBSTRING "${member}" 11 -1 feature)
+ qt_evaluate_feature(${feature})
+ endif()
+
+ list(APPEND result ${member})
+ endif()
+ endforeach()
+ # The 'TARGET Gui' case is handled by qt_evaluate_to_boolean, by passing those tokens verbatim
+ # to if().
+
+ if("${result}" STREQUAL "")
+ set(result ON)
+ else()
+ qt_evaluate_to_boolean(result)
+ endif()
+
+ set(${resultVar} ${result} PARENT_SCOPE)
+endfunction()
+
+function(qt_feature_set_cache_value resultVar feature emit_if calculated label)
+ if (DEFINED "FEATURE_${feature}")
+ # Must set up the cache
+ if (NOT (emit_if))
+ message(FATAL_ERROR "Sanity check failed: FEATURE_${feature} that was not emitted was found in the CMakeCache.")
+ endif()
+
+ # Revisit value:
+ set(cache "${FEATURE_${feature}}")
+ set(booly_values OFF NO FALSE N ON YES TRUE Y)
+ if ((cache IN_LIST booly_values) OR (cache GREATER_EQUAL 0))
+ set(result "${cache}")
+ else()
+ message(FATAL_ERROR "Sanity check failed: FEATURE_${feature} has invalid value \"${cache}\"!")
+ endif()
+ # Fix-up user-provided values
+ set("FEATURE_${feature}" "${cache}" CACHE BOOL "${label}")
+ else()
+ # Initial setup:
+ if (emit_if)
+ set("FEATURE_${feature}" "${calculated}" CACHE BOOL "${label}")
+ set(result "${calculated}")
+ else()
+ set(result OFF)
+ endif()
+ endif()
+
+ set("${resultVar}" "${result}" PARENT_SCOPE)
+endfunction()
+
+macro(qt_feature_set_value feature cache emit_if condition label)
+ set(result "${cache}")
+
+ if (NOT (condition) AND (cache))
+ message(SEND_ERROR "Feature \"${feature}\": Forcing to \"${cache}\" breaks its condition.")
+ endif()
+
+ if (DEFINED "QT_FEATURE_${feature}")
+ message(FATAL_ERROR "Feature ${feature} is already defined when evaluating configure.cmake features for ${target}.")
+ endif()
+ set(QT_FEATURE_${feature} "${result}" CACHE INTERNAL "Qt feature: ${feature}")
+endmacro()
+
+function(qt_evaluate_feature feature)
+ # If the feature was set explicitly by the user to be on or off, in the cache, then
+ # there's nothing for us to do.
+ if(DEFINED "QT_FEATURE_${feature}")
+ return()
+ endif()
+
+ if(NOT DEFINED _QT_FEATURE_DEFINITION_${feature})
+ qt_debug_print_variables(DEDUP MATCH "^QT_FEATURE")
+ message(FATAL_ERROR "Attempting to evaluate feature ${feature} but its definition is missing. Either the feature does not exist or a dependency to the module that defines it is missing")
+ endif()
+
+ cmake_parse_arguments(arg
+ "PRIVATE;PUBLIC"
+ "LABEL;PURPOSE;SECTION;" "AUTODETECT;CONDITION;ENABLE;DISABLE;EMIT_IF" ${_QT_FEATURE_DEFINITION_${feature}})
+
+ if(DEFINED QT_FEATURE_${feature})
+ return()
+ endif()
+
+ if("${arg_ENABLE}" STREQUAL "")
+ set(arg_ENABLE OFF)
+ endif()
+
+ if("${arg_DISABLE}" STREQUAL "")
+ set(arg_DISABLE OFF)
+ endif()
+
+ if("${arg_AUTODETECT}" STREQUAL "")
+ set(arg_AUTODETECT ON)
+ endif()
+
+ if("${arg_CONDITION}" STREQUAL "")
+ set(condition ON)
+ else()
+ qt_evaluate_config_expression(condition ${arg_CONDITION})
+ endif()
+
+ qt_evaluate_config_expression(disable_result ${arg_DISABLE})
+ qt_evaluate_config_expression(enable_result ${arg_ENABLE})
+ if(${disable_result})
+ set(result OFF)
+ elseif((${enable_result}) OR (${arg_AUTODETECT}))
+ set(result ${condition})
+ else()
+ # feature not auto-detected and not explicitly enabled
+ set(result OFF)
+ endif()
+
+ if("${arg_EMIT_IF}" STREQUAL "")
+ set(emit_if ON)
+ else()
+ qt_evaluate_config_expression(emit_if ${arg_EMIT_IF})
+ endif()
+
+ if (NOT (condition) AND (calculated))
+ message(FATAL_ERROR "Sanity check failed: Feature ${feature} is enabled but condition does not hold true.")
+ endif()
+
+ qt_feature_set_cache_value(cache "${feature}" "${emit_if}" "${result}" "${arg_LABEL}")
+ qt_feature_set_value("${feature}" "${cache}" "${emit_if}" "${condition}" "${arg_LABEL}")
+endfunction()
+
+function(qt_feature_config feature config_var_name)
+ qt_feature_normalize_name("${feature}" feature)
+ qt_parse_all_arguments(arg "qt_feature_config" "NEGATE" "NAME" "" ${ARGN})
+
+ # Store all the config related info in a unique variable key.
+ set(key_name "_QT_FEATURE_CONFIG_DEFINITION_${feature}_${config_var_name}")
+ set(${key_name} "FEATURE;${feature};CONFIG_VAR_NAME;${config_var_name};${ARGN}" PARENT_SCOPE)
+
+ # Store the key for later evaluation.
+ list(APPEND __QtFeature_config_definitions "${key_name}")
+
+ set(__QtFeature_config_definitions ${__QtFeature_config_definitions} PARENT_SCOPE)
+endfunction()
+
+function(qt_evaluate_qmake_config_values key)
+ if(NOT DEFINED ${key})
+ qt_debug_print_variables(DEDUP MATCH "^_QT_FEATURE_CONFIG_DEFINITION")
+ message(FATAL_ERROR
+ "Attempting to evaluate feature config ${key} but its definition is missing. ")
+ endif()
+
+ cmake_parse_arguments(arg
+ "NEGATE"
+ "FEATURE;NAME;CONFIG_VAR_NAME"
+ "" ${${key}})
+
+ set(expected "NOT")
+ if (arg_NEGATE)
+ set(expected "")
+ endif()
+
+ # If no custom name is specified, then the config value is the same as the feature name.
+ if(NOT arg_NAME)
+ set(arg_NAME "${arg_FEATURE}")
+ endif()
+
+ # The feature condition is false, there is no need to export any config values.
+ if(${expected} ${QT_FEATURE_${arg_FEATURE}})
+ return()
+ endif()
+
+ if(arg_CONFIG_VAR_NAME STREQUAL "QMAKE_PUBLIC_CONFIG")
+ list(APPEND __QtFeature_qmake_public_config "${arg_NAME}")
+ set(__QtFeature_qmake_public_config "${__QtFeature_qmake_public_config}" PARENT_SCOPE)
+ endif()
+ if(arg_CONFIG_VAR_NAME STREQUAL "QMAKE_PRIVATE_CONFIG")
+ list(APPEND __QtFeature_qmake_private_config "${arg_NAME}")
+ set(__QtFeature_qmake_private_config "${__QtFeature_qmake_private_config}" PARENT_SCOPE)
+ endif()
+ if(arg_CONFIG_VAR_NAME STREQUAL "QMAKE_PUBLIC_QT_CONFIG")
+ list(APPEND __QtFeature_qmake_public_qt_config "${arg_NAME}")
+ set(__QtFeature_qmake_public_qt_config "${__QtFeature_qmake_public_qt_config}" PARENT_SCOPE)
+ endif()
+endfunction()
+
+function(qt_feature_definition feature name)
+ qt_feature_normalize_name("${feature}" feature)
+ qt_parse_all_arguments(arg "qt_feature_definition" "NEGATE" "VALUE" "" ${ARGN})
+
+ # Store all the define related info in a unique variable key.
+ set(key_name "_QT_FEATURE_DEFINE_DEFINITION_${feature}_${name}")
+ set(${key_name} "FEATURE;${feature};NAME;${name};${ARGN}" PARENT_SCOPE)
+
+ # Store the key for later evaluation and subsequent define generation:
+ list(APPEND __QtFeature_define_definitions "${key_name}")
+
+ set(__QtFeature_define_definitions ${__QtFeature_define_definitions} PARENT_SCOPE)
+endfunction()
+
+function(qt_evaluate_feature_definition key)
+ if(NOT DEFINED ${key})
+ qt_debug_print_variables(DEDUP MATCH "^_QT_FEATURE_DEFINE_DEFINITION")
+ message(FATAL_ERROR "Attempting to evaluate feature define ${key} but its definition is missing. ")
+ endif()
+
+ cmake_parse_arguments(arg
+ "NEGATE;"
+ "FEATURE;NAME;VALUE;" "" ${${key}})
+
+ set(expected ON)
+ if (arg_NEGATE)
+ set(expected OFF)
+ endif()
+
+ set(msg "")
+
+ if(QT_FEATURE_${arg_FEATURE} STREQUAL expected)
+ if (arg_VALUE)
+ string(APPEND msg "#define ${arg_NAME} ${arg_VALUE}\n")
+ else()
+ string(APPEND msg "#define ${arg_NAME}\n")
+ endif()
+
+ string(APPEND __QtFeature_public_extra "${msg}")
+ endif()
+
+ set(__QtFeature_public_extra ${__QtFeature_public_extra} PARENT_SCOPE)
+endfunction()
+
+function(qt_extra_definition name value)
+ qt_parse_all_arguments(arg "qt_extra_definition" "PUBLIC;PRIVATE" "" "" ${ARGN})
+
+ if (arg_PUBLIC)
+ string(APPEND __QtFeature_public_extra "\n#define ${name} ${value}\n")
+ elseif(arg_PRIVATE)
+ string(APPEND __QtFeature_private_extra "\n#define ${name} ${value}\n")
+ endif()
+
+ set(__QtFeature_public_extra ${__QtFeature_public_extra} PARENT_SCOPE)
+ set(__QtFeature_private_extra ${__QtFeature_private_extra} PARENT_SCOPE)
+endfunction()
+
+function(qt_internal_generate_feature_line line feature)
+ if (QT_FEATURE_${feature} STREQUAL "ON")
+ set(line "#define QT_FEATURE_${feature} 1\n\n" PARENT_SCOPE)
+ elseif(QT_FEATURE_${feature} STREQUAL "OFF")
+ set(line "#define QT_FEATURE_${feature} -1\n\n" PARENT_SCOPE)
+ elseif(QT_FEATURE_${feature} STREQUAL "UNSET")
+ set(line "#define QT_FEATURE_${feature} 0\n\n" PARENT_SCOPE)
+ else()
+ message(FATAL_ERROR "${feature} has unexpected value \"${QT_FEATURE_${feature}}\"!")
+ endif()
+endfunction()
+
+function(qt_internal_feature_write_file file features extra)
+ message("Generating file ${file}.")
+ set(contents "")
+ foreach(it ${features})
+ qt_internal_generate_feature_line(line "${it}")
+ string(APPEND contents "${line}")
+ endforeach()
+ string(APPEND contents "${extra}")
+
+ file(GENERATE OUTPUT "${file}" CONTENT "${contents}")
+endfunction()
+
+function(qt_feature_module_end)
+ set(flags)
+ set(options OUT_VAR_PREFIX)
+ set(multiopts)
+ cmake_parse_arguments(arg "${flags}" "${options}" "${multiopts}" ${ARGN})
+ set(target ${arg_UNPARSED_ARGUMENTS})
+
+ # The value of OUT_VAR_PREFIX is used as a prefix for output variables that should be
+ # set in the parent scope.
+ if(NOT arg_OUT_VAR_PREFIX)
+ set(arg_OUT_VAR_PREFIX "")
+ endif()
+
+ set(all_features ${__QtFeature_public_features} ${__QtFeature_private_features} ${__QtFeature_internal_features})
+ list(REMOVE_DUPLICATES all_features)
+
+ foreach(feature ${all_features})
+ qt_evaluate_feature(${feature})
+ endforeach()
+
+ # Evaluate custom cache assignments.
+ foreach(cache_var_name ${__QtFeature_custom_enabled_cache_variables})
+ set(${cache_var_name} ON CACHE BOOL "Force enabled by platform." FORCE)
+ endforeach()
+ foreach(cache_var_name ${__QtFeature_custom_disabled_cache_variables})
+ set(${cache_var_name} OFF CACHE BOOL "Force disabled by platform." FORCE)
+ endforeach()
+
+ set(enabled_public_features "")
+ set(disabled_public_features "")
+ set(enabled_private_features "")
+ set(disabled_private_features "")
+
+ foreach(feature ${__QtFeature_public_features})
+ if(QT_FEATURE_${feature})
+ list(APPEND enabled_public_features ${feature})
+ else()
+ list(APPEND disabled_public_features ${feature})
+ endif()
+ endforeach()
+
+ foreach(feature ${__QtFeature_private_features})
+ if(QT_FEATURE_${feature})
+ list(APPEND enabled_private_features ${feature})
+ else()
+ list(APPEND disabled_private_features ${feature})
+ endif()
+ endforeach()
+
+ foreach(key ${__QtFeature_config_definitions})
+ qt_evaluate_qmake_config_values(${key})
+ unset(${key} PARENT_SCOPE)
+ endforeach()
+
+ foreach(key ${__QtFeature_define_definitions})
+ qt_evaluate_feature_definition(${key})
+ unset(${key} PARENT_SCOPE)
+ endforeach()
+
+ foreach(feature ${all_features})
+ unset(_QT_FEATURE_DEFINITION_${feature} PARENT_SCOPE)
+ endforeach()
+
+ qt_internal_feature_write_file("${CMAKE_CURRENT_BINARY_DIR}/${__QtFeature_private_file}"
+ "${__QtFeature_private_features}" "${__QtFeature_private_extra}"
+ )
+
+ qt_internal_feature_write_file("${CMAKE_CURRENT_BINARY_DIR}/${__QtFeature_public_file}"
+ "${__QtFeature_public_features}" "${__QtFeature_public_extra}"
+ )
+
+ # Extra header injections which have to have forwarding headers created by
+ # qt_install_injections.
+ # Skip creating forwarding headers if qt_feature_module_begin was called with NO_MODULE, aka
+ # there is no include/<module_name> so there's no place to put the forwarding headers.
+ if(__QtFeature_library)
+ set(injections "")
+ qt_compute_injection_forwarding_header("${__QtFeature_library}"
+ SOURCE "${__QtFeature_public_file}"
+ OUT_VAR injections)
+ qt_compute_injection_forwarding_header("${__QtFeature_library}"
+ SOURCE "${__QtFeature_private_file}" PRIVATE
+ OUT_VAR injections)
+
+ set(${arg_OUT_VAR_PREFIX}extra_library_injections ${injections} PARENT_SCOPE)
+ endif()
+
+ if (NOT ("${target}" STREQUAL "NO_MODULE"))
+ get_target_property(targetType "${target}" TYPE)
+ if("${targetType}" STREQUAL "INTERFACE_LIBRARY")
+ set(propertyPrefix "INTERFACE_")
+ else()
+ set(propertyPrefix "")
+ set_target_properties("${target}" PROPERTIES EXPORT_PROPERTIES "QT_ENABLED_PUBLIC_FEATURES;QT_DISABLED_PUBLIC_FEATURES;QT_ENABLED_PRIVATE_FEATURES;QT_DISABLED_PRIVATE_FEATURES;MODULE_PLUGIN_TYPES;QT_PLUGINS;QT_QMAKE_PUBLIC_CONFIG;QT_QMAKE_PRIVATE_CONFIG;QT_QMAKE_PUBLIC_QT_CONFIG")
+ endif()
+ foreach(visibility public private)
+ string(TOUPPER "${visibility}" capitalVisibility)
+ foreach(state enabled disabled)
+ string(TOUPPER "${state}" capitalState)
+
+ set_property(TARGET "${target}" PROPERTY ${propertyPrefix}QT_${capitalState}_${capitalVisibility}_FEATURES "${${state}_${visibility}_features}")
+ endforeach()
+ endforeach()
+
+ set_property(TARGET "${target}"
+ PROPERTY ${propertyPrefix}QT_QMAKE_PUBLIC_CONFIG
+ "${__QtFeature_qmake_public_config}")
+ set_property(TARGET "${target}"
+ PROPERTY ${propertyPrefix}QT_QMAKE_PRIVATE_CONFIG
+ "${__QtFeature_qmake_private_config}")
+ set_property(TARGET "${target}"
+ PROPERTY ${propertyPrefix}QT_QMAKE_PUBLIC_QT_CONFIG
+ "${__QtFeature_qmake_public_qt_config}")
+
+ # Config values were the old-school features before actual configure.json features were
+ # implemented. Therefore "CONFIG+=foo" values should be considered features as well,
+ # so that CMake can find them when building qtmultimedia for example.
+ if(__QtFeature_qmake_public_config)
+ set_property(TARGET "${target}"
+ APPEND PROPERTY ${propertyPrefix}QT_ENABLED_PUBLIC_FEATURES
+ ${__QtFeature_qmake_public_config})
+ endif()
+ if(__QtFeature_qmake_private_config)
+ set_property(TARGET "${target}"
+ APPEND PROPERTY ${propertyPrefix}QT_ENABLED_PRIVATE_FEATURES
+ ${__QtFeature_qmake_private_config})
+ endif()
+ if(__QtFeature_qmake_public_qt_config)
+ set_property(TARGET "${target}"
+ APPEND PROPERTY ${propertyPrefix}QT_ENABLED_PUBLIC_FEATURES
+ ${__QtFeature_qmake_public_qt_config})
+ endif()
+
+ qt_feature_copy_global_config_features_to_core(${target})
+ endif()
+
+ unset(__QtFeature_library PARENT_SCOPE)
+ unset(__QtFeature_public_features PARENT_SCOPE)
+ unset(__QtFeature_private_features PARENT_SCOPE)
+ unset(__QtFeature_internal_features PARENT_SCOPE)
+
+ unset(__QtFeature_private_file PARENT_SCOPE)
+ unset(__QtFeature_public_file PARENT_SCOPE)
+
+ unset(__QtFeature_private_extra PARENT_SCOPE)
+ unset(__QtFeature_public_extra PARENT_SCOPE)
+
+ unset(__QtFeature_define_definitions PARENT_SCOPE)
+ unset(__QtFeature_custom_enabled_features PARENT_SCOPE)
+ unset(__QtFeature_custom_disabled_features PARENT_SCOPE)
+endfunction()
+
+function(qt_feature_copy_global_config_features_to_core target)
+ # CMake doesn't support setting custom properties on exported INTERFACE libraries
+ # See https://gitlab.kitware.com/cmake/cmake/issues/19261.
+ # To circumvent that, copy the properties from GlobalConfig to Core target.
+ # This way the global features actually get set in the generated CoreTargets.cmake file.
+ if(target STREQUAL Core)
+ foreach(visibility public private)
+ string(TOUPPER "${visibility}" capitalVisibility)
+ foreach(state enabled disabled)
+ string(TOUPPER "${state}" capitalState)
+
+ set(core_property_name "QT_${capitalState}_${capitalVisibility}_FEATURES")
+ set(global_property_name "INTERFACE_${core_property_name}")
+
+ get_property(core_values TARGET Core PROPERTY ${core_property_name})
+ get_property(global_values TARGET GlobalConfig PROPERTY ${global_property_name})
+
+ set(total_values ${core_values} ${global_values})
+ set_property(TARGET Core PROPERTY ${core_property_name} ${total_values})
+ endforeach()
+ endforeach()
+
+ set(config_property_names
+ QT_QMAKE_PUBLIC_CONFIG QT_QMAKE_PRIVATE_CONFIG QT_QMAKE_PUBLIC_QT_CONFIG )
+ foreach(property_name ${config_property_names})
+ set(core_property_name "${property_name}")
+ set(global_property_name "INTERFACE_${core_property_name}")
+
+ get_property(core_values TARGET Core PROPERTY ${core_property_name})
+ get_property(global_values TARGET GlobalConfig PROPERTY ${global_property_name})
+
+ set(total_values ${core_values} ${global_values})
+ set_property(TARGET Core PROPERTY ${core_property_name} ${total_values})
+ endforeach()
+ endif()
+endfunction()
+
+function(qt_config_compile_test name)
+ if(DEFINED "TEST_${name}")
+ return()
+ endif()
+
+ cmake_parse_arguments(arg "" "LABEL;PROJECT_PATH;C_STANDARD;CXX_STANDARD" "LIBRARIES;CODE" ${ARGN})
+
+ if(arg_PROJECT_PATH)
+ message(STATUS "Performing Test ${arg_LABEL}")
+ try_compile(HAVE_${name} "${CMAKE_BINARY_DIR}/config.tests/${name}" "${arg_PROJECT_PATH}"
+ "${name}")
+
+ if(${HAVE_${name}})
+ set(status_label "Success")
+ else()
+ set(status_label "Failed")
+ endif()
+ message(STATUS "Performing Test ${arg_LABEL} - ${status_label}")
+ else()
+ foreach(library IN ITEMS ${arg_LIBRARIES})
+ if(NOT TARGET "${library}")
+ # If the dependency looks like a cmake target, then make this compile test
+ # fail instead of cmake abort later via CMAKE_REQUIRED_LIBRARIES.
+ string(FIND "${library}" "::" cmake_target_namespace_separator)
+ if(NOT cmake_target_namespace_separator EQUAL -1)
+ set(HAVE_${name} FALSE)
+ break()
+ endif()
+ endif()
+ endforeach()
+
+ if(NOT DEFINED HAVE_${name})
+ set(_save_CMAKE_C_STANDARD "${CMAKE_C_STANDARD}")
+ set(_save_CMAKE_CXX_STANDARD "${CMAKE_CXX_STANDARD}")
+
+ if(arg_C_STANDARD)
+ set(CMAKE_C_STANDARD "${arg_C_STANDARD}")
+ endif()
+
+ if(arg_CXX_STANDARD)
+ set(CMAKE_CXX_STANDARD "${arg_CXX_STANDARD}")
+ endif()
+
+ set(_save_CMAKE_REQUIRED_LIBRARIES "${CMAKE_REQUIRED_LIBRARIES}")
+ set(CMAKE_REQUIRED_LIBRARIES "${arg_LIBRARIES}")
+ check_cxx_source_compiles("${arg_UNPARSED_ARGUMENTS} ${arg_CODE}" HAVE_${name})
+ set(CMAKE_REQUIRED_LIBRARIES "${_save_CMAKE_REQUIRED_LIBRARIES}")
+
+ set(CMAKE_C_STANDARD "${_save_CMAKE_C_STANDARD}")
+ set(CMAKE_CXX_STANDARD "${_save_CMAKE_CXX_STANDARD}")
+ endif()
+ endif()
+
+ set(TEST_${name} "${HAVE_${name}}" CACHE INTERNAL "${arg_LABEL}")
+endfunction()
+
+# This function should be used for passing required try compile platform variables to the
+# project-based try_compile() call.
+# out_var will be a list of -Dfoo=bar strings, suitable to pass to CMAKE_FLAGS.
+function(qt_get_platform_try_compile_vars out_var)
+ # Use the regular variables that are used for source-based try_compile() calls.
+ set(flags "${CMAKE_TRY_COMPILE_PLATFORM_VARIABLES}")
+
+ # Pass toolchain files.
+ if(CMAKE_TOOLCHAIN_FILE)
+ list(APPEND flags "CMAKE_TOOLCHAIN_FILE")
+ endif()
+ if(VCPKG_CHAINLOAD_TOOLCHAIN_FILE)
+ list(APPEND flags "VCPKG_CHAINLOAD_TOOLCHAIN_FILE")
+ endif()
+
+ # Assemble the list with regular options.
+ set(flags_cmd_line "")
+ foreach(flag ${flags})
+ if(${flag})
+ list(APPEND flags_cmd_line "-D${flag}=${${flag}}")
+ endif()
+ endforeach()
+
+ # Pass darwin specific options.
+ if(APPLE_UIKIT)
+ if(CMAKE_OSX_ARCHITECTURES)
+ list(GET CMAKE_OSX_ARCHITECTURES 0 osx_first_arch)
+
+ # Do what qmake does, aka when doing a simulator_and_device build, build the
+ # target architecture test only with the first given architecture, which should be the
+ # device architecture, aka some variation of "arm" (armv7, arm64).
+ list(APPEND flags_cmd_line "-DCMAKE_OSX_ARCHITECTURES:STRING=${osx_first_arch}")
+ endif()
+ # Also specify the sysroot, but only if not doing a simulator_and_device build.
+ # So keep the sysroot empty for simulator_and_device builds.
+ if(QT_UIKIT_SDK)
+ list(APPEND flags_cmd_line "-DCMAKE_OSX_SYSROOT:STRING=${QT_UIKIT_SDK}")
+ endif()
+ endif()
+
+ set("${out_var}" "${flags_cmd_line}" PARENT_SCOPE)
+endfunction()
+
+function(qt_config_compile_test_x86simd extension label)
+ if (DEFINED TEST_X86SIMD_${extension})
+ return()
+ endif()
+
+ set(flags "-DSIMD:string=${extension}")
+
+ qt_get_platform_try_compile_vars(platform_try_compile_vars)
+ list(APPEND flags ${platform_try_compile_vars})
+
+ message(STATUS "Performing SIMD Test ${label}")
+ try_compile("TEST_X86SIMD_${extension}"
+ "${CMAKE_CURRENT_BINARY_DIR}/config.tests/x86_simd_${extension}"
+ "${CMAKE_CURRENT_SOURCE_DIR}/config.tests/x86_simd"
+ x86_simd
+ CMAKE_FLAGS ${flags})
+ if(${TEST_X86SIMD_${extension}})
+ set(status_label "Success")
+ else()
+ set(status_label "Failed")
+ endif()
+ message(STATUS "Performing SIMD Test ${label} - ${status_label}")
+ set(TEST_subarch_${extension} "${TEST_X86SIMD_${extension}}" CACHE INTERNAL "${label}")
+endfunction()
+
+function(qt_make_features_available target)
+ if(NOT "${target}" MATCHES "^${QT_CMAKE_EXPORT_NAMESPACE}::[a-zA-Z][a-zA-Z0-9_-]*$")
+ message(FATAL_ERROR "${target} does not match ${QT_CMAKE_EXPORT_NAMESPACE}::[a-zA-Z][a-zA-Z0-9_-]*. INVALID NAME.")
+ endif()
+ if(NOT TARGET ${target})
+ message(FATAL_ERROR "${target} not found.")
+ endif()
+
+ get_target_property(target_type "${target}" TYPE)
+ if("${target_type}" STREQUAL "INTERFACE_LIBRARY")
+ set(property_prefix "INTERFACE_")
+ else()
+ set(property_prefix "")
+ endif()
+ foreach(visibility IN ITEMS PUBLIC PRIVATE)
+ set(value ON)
+ foreach(state IN ITEMS ENABLED DISABLED)
+ get_target_property(features "${target}" ${property_prefix}QT_${state}_${visibility}_FEATURES)
+ if("${features}" STREQUAL "features-NOTFOUND")
+ continue()
+ endif()
+ foreach(feature IN ITEMS ${features})
+ if (DEFINED "QT_FEATURE_${feature}" AND NOT "${QT_FEATURE_${feature}}" STREQUAL "${value}")
+ message(FATAL_ERROR "Feature ${feature} is already defined and has a different value when importing features from ${target}.")
+ endif()
+ set(QT_FEATURE_${feature} "${value}" CACHE INTERNAL "Qt feature: ${feature} (from target ${target})")
+ endforeach()
+ set(value OFF)
+ endforeach()
+ endforeach()
+endfunction()
+
+
diff --git a/cmake/QtInternalTargets.cmake b/cmake/QtInternalTargets.cmake
new file mode 100644
index 0000000000..54e7f4f50e
--- /dev/null
+++ b/cmake/QtInternalTargets.cmake
@@ -0,0 +1,114 @@
+
+function(qt_internal_set_warnings_are_errors_flags target)
+ set(flags "")
+ if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
+ # Regular clang 3.0+
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL "3.0.0")
+ list(APPEND flags -Werror -Wno-error=\#warnings -Wno-error=deprecated-declarations)
+ endif()
+ elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "AppleClang")
+ # using AppleClang
+ # Apple clang 4.0+
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL "4.0.0" AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS_EQUAL "9.2")
+ list(APPEND flags -Werror -Wno-error=\#warnings -Wno-error=deprecated-declarations)
+ endif()
+ elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
+ # using GCC
+ list(APPEND flags -Werror -Wno-error=cpp -Wno-error=deprecated-declarations)
+
+ # GCC prints this bogus warning, after it has inlined a lot of code
+ # error: assuming signed overflow does not occur when assuming that (X + c) < X is always false
+ list(APPEND flags -Wno-error=strict-overflow)
+
+ # GCC 7 includes -Wimplicit-fallthrough in -Wextra, but Qt is not yet free of implicit fallthroughs.
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL "7.0.0")
+ list(APPEND flags -Wno-error=implicit-fallthrough)
+ endif()
+
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL "9.0.0")
+ # GCC 9 introduced these but we are not clean for it.
+ list(APPEND flags -Wno-error=deprecated-copy -Wno-error=redundant-move -Wno-error=init-list-lifetime)
+ endif()
+
+ # Work-around for bug https://code.google.com/p/android/issues/detail?id=58135
+ if (ANDROID)
+ list(APPEND flags -Wno-error=literal-suffix)
+ endif()
+ elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Intel")
+ # Intel CC 13.0 +, on Linux only
+ if (LINUX)
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL "13.0.0")
+ # 177: function "entity" was declared but never referenced
+ # (too aggressive; ICC reports even for functions created due to template instantiation)
+ # 1224: #warning directive
+ # 1478: function "entity" (declared at line N) was declared deprecated
+ # 1786: function "entity" (declared at line N of "file") was declared deprecated ("message")
+ # 1881: argument must be a constant null pointer value
+ # (NULL in C++ is usually a literal 0)
+ list(APPEND flags -Werror -ww177,1224,1478,1786,1881)
+ endif()
+ endif()
+ elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "MSVC")
+ # In qmake land, currently warnings as errors are only enabled for
+ # MSVC 2012, 2013, 2015.
+ # Respectively MSVC_VERRSIONs are: 1700-1799, 1800-1899, 1900-1909.
+ if(MSVC_VERSION GREATER_EQUAL 1700 AND MSVC_VERSION LESS_EQUAL 1909)
+ list(APPEND flags /WX)
+ endif()
+ endif()
+ set(add_flags "$<NOT:$<BOOL:$<TARGET_PROPERTY:QT_SKIP_WARNINGS_ARE_ERRORS>>>")
+ set(flags_generator_expression "$<${add_flags}:${flags}>")
+ target_compile_options("${target}" INTERFACE "${flags_generator_expression}")
+endfunction()
+
+add_library(PlatformCommonInternal INTERFACE)
+add_library(Qt::PlatformCommonInternal ALIAS PlatformCommonInternal)
+
+add_library(PlatformModuleInternal INTERFACE)
+add_library(Qt::PlatformModuleInternal ALIAS PlatformModuleInternal)
+target_link_libraries(PlatformModuleInternal INTERFACE PlatformCommonInternal)
+
+add_library(PlatformPluginInternal INTERFACE)
+add_library(Qt::PlatformPluginInternal ALIAS PlatformPluginInternal)
+target_link_libraries(PlatformPluginInternal INTERFACE PlatformCommonInternal)
+
+add_library(PlatformToolInternal INTERFACE)
+add_library(Qt::PlatformToolInternal ALIAS PlatformToolInternal)
+target_link_libraries(PlatformToolInternal INTERFACE PlatformCommonInternal)
+
+if(WARNINGS_ARE_ERRORS)
+ qt_internal_set_warnings_are_errors_flags(PlatformModuleInternal)
+ qt_internal_set_warnings_are_errors_flags(PlatformPluginInternal)
+ qt_internal_set_warnings_are_errors_flags(PlatformToolInternal)
+endif()
+if(WIN32)
+ # Needed for M_PI define. Same as mkspecs/features/qt_module.prf.
+ # It's set for every module being built, but it's not propagated to user apps.
+ target_compile_definitions(PlatformModuleInternal INTERFACE _USE_MATH_DEFINES)
+endif()
+if(FEATURE_largefile AND UNIX)
+ target_compile_definitions(PlatformModuleInternal
+ INTERFACE "_LARGEFILE64_SOURCE;_LARGEFILE_SOURCE")
+endif()
+
+# We can't use the gold linker on android with the NDK, which is the default
+# linker. To build our own target we will use the lld linker.
+if (ANDROID)
+ target_link_options(PlatformModuleInternal INTERFACE -fuse-ld=lld)
+endif()
+
+if(NOT CMAKE_BUILD_TYPE STREQUAL Debug)
+ target_compile_definitions(PlatformCommonInternal INTERFACE QT_NO_DEBUG)
+endif()
+
+if(APPLE_UIKIT)
+ # Do what mkspecs/features/uikit/default_pre.prf does, aka enable sse2 for
+ # simulator_and_device_builds.
+ if(FEATURE_simulator_and_device)
+ # Setting the definition on PlatformCommonInternal behaves slightly differently from what
+ # is done in qmake land. This way the define is not propagated to tests, examples, or
+ # user projects built with qmake, but only modules, plugins and tools.
+ # TODO: Figure out if this ok or not (sounds ok to me).
+ target_compile_definitions(PlatformCommonInternal INTERFACE QT_COMPILER_SUPPORTS_SSE2)
+ endif()
+endif()
diff --git a/cmake/QtModuleConfig.cmake.in b/cmake/QtModuleConfig.cmake.in
new file mode 100644
index 0000000000..8e24362502
--- /dev/null
+++ b/cmake/QtModuleConfig.cmake.in
@@ -0,0 +1,46 @@
+@PACKAGE_INIT@
+
+include(CMakeFindDependencyMacro)
+
+get_filename_component(_import_prefix "${CMAKE_CURRENT_LIST_FILE}" PATH)
+get_filename_component(_import_prefix "${_import_prefix}" REALPATH)
+
+# Extra cmake code begin
+@extra_cmake_code@
+# Extra cmake code end
+
+# Find required dependencies, if any.
+if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@Dependencies.cmake")
+ include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@Dependencies.cmake")
+endif()
+
+if (NOT QT_NO_CREATE_TARGETS)
+ include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@Targets.cmake")
+ if(NOT QT_NO_CREATE_VERSIONLESS_TARGETS)
+ include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@VersionlessTargets.cmake")
+ endif()
+endif()
+
+foreach(extra_cmake_include @extra_cmake_includes@)
+ include("${CMAKE_CURRENT_LIST_DIR}/${extra_cmake_include}")
+endforeach()
+
+include(${_qt_@PROJECT_VERSION_MAJOR@_config_cmake_dir}/QtFeature.cmake)
+
+qt_make_features_available(@QT_CMAKE_EXPORT_NAMESPACE@::@target@)
+
+set("@INSTALL_CMAKE_NAMESPACE@@target@_FOUND" TRUE)
+if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@Plugins.cmake")
+ include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@Plugins.cmake")
+endif()
+
+list(APPEND QT_ALL_MODULES_FOUND_VIA_FIND_PACKAGE "@target@")
+
+get_target_property(_qt_module_target_type "@INSTALL_CMAKE_NAMESPACE@::@target@" TYPE)
+if(NOT _qt_module_target_type STREQUAL "INTERFACE_LIBRARY")
+ get_target_property(_qt_module_plugin_types
+ @INSTALL_CMAKE_NAMESPACE@::@target@ MODULE_PLUGIN_TYPES)
+ if(_qt_module_plugin_types)
+ list(APPEND QT_ALL_PLUGIN_TYPES_FOUND_VIA_FIND_PACKAGE "${_qt_module_plugin_types}")
+ endif()
+endif()
diff --git a/cmake/QtModuleDependencies.cmake.in b/cmake/QtModuleDependencies.cmake.in
new file mode 100644
index 0000000000..ffb9e8a5d3
--- /dev/null
+++ b/cmake/QtModuleDependencies.cmake.in
@@ -0,0 +1,66 @@
+# note: _third_party_deps example: "ICU\\;1.0\\;i18n uc data;ZLIB\\;\\;"
+set(_third_party_deps "@third_party_deps@")
+
+foreach(_target_dep ${_third_party_deps})
+ list(GET _target_dep 0 pkg)
+ list(GET _target_dep 1 version)
+ list(GET _target_dep 2 components)
+ set(find_package_args "${pkg}")
+ if(version)
+ list(APPEND find_package_args "${version}")
+ endif()
+
+ if(components)
+ string(REPLACE " " ";" components "${components}")
+ find_dependency(${find_package_args} COMPONENTS ${components})
+ else()
+ find_dependency(${find_package_args})
+ endif()
+
+ if (NOT ${pkg}_FOUND)
+ set(@INSTALL_CMAKE_NAMESPACE@@target@_FOUND FALSE)
+ return()
+ endif()
+endforeach()
+
+# Find Qt tool package.
+set(_tool_deps "@main_module_tool_deps@")
+
+# The tools do not provide linkage targets but executables, where a mismatch
+# between 32-bit target and 64-bit host does not matter.
+set(BACKUP_CMAKE_SIZEOF_VOID_P "${CMAKE_SIZEOF_VOID_P}")
+set(CMAKE_SIZEOF_VOID_P "")
+
+foreach(_target_dep ${_tool_deps})
+ list(GET _target_dep 0 pkg)
+ list(GET _target_dep 1 version)
+
+ find_dependency(${pkg} ${version})
+
+ if (NOT ${pkg}_FOUND)
+ set(@INSTALL_CMAKE_NAMESPACE@@target@_FOUND FALSE)
+ set(CMAKE_SIZEOF_VOID_P "${BACKUP_CMAKE_SIZEOF_VOID_P}")
+ return()
+ endif()
+endforeach()
+set(CMAKE_SIZEOF_VOID_P "${BACKUP_CMAKE_SIZEOF_VOID_P}")
+
+# note: target_deps example: "Qt6Core\;5.12.0;Qt6Gui\;5.12.0"
+set(_target_deps "@target_deps@")
+foreach(_target_dep ${_target_deps})
+ list(GET _target_dep 0 pkg)
+ list(GET _target_dep 1 version)
+
+ if (NOT ${pkg}_FOUND)
+ find_dependency(${pkg} ${version}
+ PATHS "${CMAKE_CURRENT_LIST_DIR}/.." ${QT_EXAMPLES_CMAKE_PREFIX_PATH} NO_DEFAULT_PATH
+ )
+ endif()
+
+ if (NOT ${pkg}_FOUND)
+ set(@INSTALL_CMAKE_NAMESPACE@@target@_FOUND FALSE)
+ return()
+ endif()
+endforeach()
+
+
diff --git a/cmake/QtModuleToolsConfig.cmake.in b/cmake/QtModuleToolsConfig.cmake.in
new file mode 100644
index 0000000000..79ca620c13
--- /dev/null
+++ b/cmake/QtModuleToolsConfig.cmake.in
@@ -0,0 +1,17 @@
+@PACKAGE_INIT@
+
+include(CMakeFindDependencyMacro)
+
+if (NOT QT_NO_CREATE_TARGETS)
+ # Find required dependencies, if any.
+ if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@Dependencies.cmake")
+ include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@Dependencies.cmake")
+ endif()
+
+ include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@Targets.cmake")
+ if(NOT QT_NO_CREATE_VERSIONLESS_TARGETS)
+ include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@VersionlessTargets.cmake")
+ endif()
+endif()
+
+@extra_cmake_statements@
diff --git a/cmake/QtModuleToolsDependencies.cmake.in b/cmake/QtModuleToolsDependencies.cmake.in
new file mode 100644
index 0000000000..46c60b8484
--- /dev/null
+++ b/cmake/QtModuleToolsDependencies.cmake.in
@@ -0,0 +1,16 @@
+# Find "ModuleTools" dependencies, which are other ModuleTools packages.
+set(_tool_deps "@package_deps@")
+foreach(_target_dep ${_tool_deps})
+ list(GET _target_dep 0 pkg)
+ list(GET _target_dep 1 version)
+
+ if (NOT ${pkg}_FOUND)
+ find_dependency(${pkg} ${version})
+ endif()
+
+ if (NOT ${pkg}_FOUND)
+ set(@INSTALL_CMAKE_NAMESPACE@@target@_FOUND FALSE)
+ return()
+ endif()
+endforeach()
+
diff --git a/cmake/QtModuleToolsVersionlessTargets.cmake.in b/cmake/QtModuleToolsVersionlessTargets.cmake.in
new file mode 100644
index 0000000000..6d0f57e039
--- /dev/null
+++ b/cmake/QtModuleToolsVersionlessTargets.cmake.in
@@ -0,0 +1,23 @@
+foreach(__qt_tool @tool_targets_non_prefixed@)
+ if(NOT TARGET Qt::${__qt_tool} AND TARGET Qt6::${__qt_tool})
+ add_executable(Qt::${__qt_tool} IMPORTED)
+
+ # Check all the usual imported location properties to find one that contains a path.
+ foreach(__qt_imported_location_config
+ IMPORTED_LOCATION
+ IMPORTED_LOCATION_RELEASE
+ IMPORTED_LOCATION_RELWITHDEBINFO
+ IMPORTED_LOCATION_MINSIZEREL
+ IMPORTED_LOCATION_DEBUG)
+
+ get_target_property(__qt_imported_location
+ Qt6::${__qt_tool} ${__qt_imported_location_config})
+ if(__qt_imported_location AND EXISTS "${__qt_imported_location}")
+ break()
+ endif()
+ endforeach()
+
+ set_target_properties(Qt::${__qt_tool}
+ PROPERTIES IMPORTED_LOCATION "${__qt_imported_location}")
+ endif()
+endforeach()
diff --git a/cmake/QtPlatformAndroid.cmake b/cmake/QtPlatformAndroid.cmake
new file mode 100644
index 0000000000..4b5bf6ff13
--- /dev/null
+++ b/cmake/QtPlatformAndroid.cmake
@@ -0,0 +1,378 @@
+#
+# Self contained Platform Settings for Android
+#
+# Note: This file is used both by the internal and public builds.
+#
+
+#
+# Public variables:
+# QT_ANDROID_JAR
+# Location of the adroid sdk jar for java code
+# QT_ANDROID_APIVERSION
+# Android API version
+# QT_ANDROID_SDK_BUILD_TOOLS_VERSION
+# Detected Android sdk build tools version
+#
+# Public functions:
+#
+# qt_android_generate_deployment_settings()
+# Generate the deployment settings json file for a cmake target.
+#
+
+if (NOT DEFINED ANDROID_SDK_ROOT)
+ message(FATAL_ERROR "Please provide the location of the Android SDK directory via -DANDROID_SDK_ROOT=<path to Adndroid SDK>")
+endif()
+
+if (NOT IS_DIRECTORY "${ANDROID_SDK_ROOT}")
+ message(FATAL_ERROR "Could not find ANDROID_SDK_ROOT or path is not a directory: ${ANDROID_SDK_ROOT}")
+endif()
+
+# Get the Android SDK jar for an API version other than the one specified with
+# QT_ANDROID_API_VERSION.
+function(qt_get_android_sdk_jar_for_api api out_jar_location)
+ set(jar_location "${ANDROID_SDK_ROOT}/platforms/${api}/android.jar")
+ if (NOT EXISTS "${jar_location}")
+ message(WARNING "Could not locate Android SDK jar for api '${api}', defaulting to ${QT_ANDROID_API_VERSION}")
+ set(${out_jar_location} ${QT_ANDROID_JAR} PARENT_SCOPE)
+ else()
+ set(${out_jar_location} ${jar_location} PARENT_SCOPE)
+ endif()
+endfunction()
+
+# Minimum recommend android SDK api version
+set(QT_ANDROID_API_VERSION "android-21")
+
+# Locate android.jar
+set(QT_ANDROID_JAR "${ANDROID_SDK_ROOT}/platforms/${QT_ANDROID_API_VERSION}/android.jar")
+if(NOT EXISTS "${QT_ANDROID_JAR}")
+ # Locate the highest available platform
+ file(GLOB android_platforms
+ LIST_DIRECTORIES true
+ RELATIVE "${ANDROID_SDK_ROOT}/platforms"
+ "${ANDROID_SDK_ROOT}/platforms/*")
+ # If list is not empty
+ if(android_platforms)
+ list(SORT android_platforms)
+ list(REVERSE android_platforms)
+ list(GET android_platforms 0 android_platform_latest)
+ set(QT_ANDROID_API_VERSION ${android_platform_latest})
+ set(QT_ANDROID_JAR "${ANDROID_SDK_ROOT}/platforms/${QT_ANDROID_API_VERSION}/android.jar")
+ endif()
+endif()
+
+if(NOT EXISTS "${QT_ANDROID_JAR}")
+ message(FATAL_ERROR "No suitable Android SDK platform found. Minimum version is ${QT_ANDROID_API_VERSION}")
+endif()
+
+message(STATUS "Using Android SDK API ${QT_ANDROID_API_VERSION} from ${ANDROID_SDK_ROOT}/platforms")
+
+# Locate Java
+include(UseJava)
+
+# Find JDK 8.0
+find_package(Java 1.8 COMPONENTS Development REQUIRED)
+
+# Locate newest android sdk build tools
+if (NOT QT_ANDROID_SDK_BUILD_TOOLS_VERSION)
+ file(GLOB android_build_tools
+ LIST_DIRECTORIES true
+ RELATIVE "${ANDROID_SDK_ROOT}/build-tools"
+ "${ANDROID_SDK_ROOT}/build-tools/*")
+ if (NOT android_build_tools)
+ message(FATAL_ERROR "Could not locate Android SDK build tools under \"${ANDROID_SDK}/build-tools\"")
+ endif()
+ list(SORT android_build_tools)
+ list(REVERSE android_build_tools)
+ list(GET android_build_tools 0 android_build_tools_latest)
+ set(QT_ANDROID_SDK_BUILD_TOOLS_VERSION ${android_build_tools_latest})
+endif()
+
+# Ensure we are using the shared version of libc++
+if(NOT ANDROID_STL STREQUAL c++_shared)
+ message(FATAL_ERROR "The Qt libraries on Android only supports the shared library configuration of stl. Please use -DANDROID_STL=\"c++_shared\" as configuration argument.")
+endif()
+
+# Target properties required for android deploy tool
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_DEPLOYMENT_DEPENDENCIES
+ BRIEF_DOCS
+ "Specify additional plugins that need to be deployed with the current android application"
+ FULL_DOCS
+ "By default, androiddeployqt will detect the dependencies of your application. But since run-time usage of plugins cannot be detected, there could be false positives, as your application will depend on any plugins that are potential dependencies. If you want to minimize the size of your APK, it's possible to override the automatic detection using the ANDROID_DEPLOYMENT_DEPENDENCIES variable. This should contain a list of all Qt files which need to be included, with paths relative to the Qt install root. Note that only the Qt files specified here will be included. Failing to include the correct files can result in crashes. It's also important to make sure the files are listed in the correct loading order. This variable provides a way to override the automatic detection entirely, so if a library is listed before its dependencies, it will fail to load on some devices."
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_EXTRA_LIBS
+ BRIEF_DOCS
+ "A list of external libraries that will be copied into your application's library folder and loaded on start-up."
+ FULL_DOCS
+ "A list of external libraries that will be copied into your application's library folder and loaded on start-up. This can be used, for instance, to enable OpenSSL in your application. Simply set the paths to the required libssl.so and libcrypto.so libraries here and OpenSSL should be enabled automatically."
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_EXTRA_PLUGINS
+ BRIEF_DOCS
+ "This variable can be used to specify different resources that your project has to bundle but cannot be delivered through the assets system, such as qml plugins."
+ FULL_DOCS
+ "This variable can be used to specify different resources that your project has to bundle but cannot be delivered through the assets system, such as qml plugins. When using this variable, androiddeployqt will make sure everything is packaged and deployed properly."
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_PACKAGE_SOURCE_DIR
+ BRIEF_DOCS
+ "This variable can be used to specify a directory where additions and modifications can be made to the default Android package template."
+ FULL_DOCS
+ "This variable can be used to specify a directory where additions and modifications can be made to the default Android package template. The androiddeployqt tool will copy the application template from Qt into the build directory, and then it will copy the contents of the ANDROID_PACKAGE_SOURCE_DIR on top of this, overwriting any existing files. The update step where parts of the source files are modified automatically to reflect your other settings is then run on the resulting merged package. If you, for instance, want to make a custom AndroidManifest.xml for your application, then place this directly into the folder specified in this variable. You can also add custom Java files in ANDROID_PACKAGE_SOURCE_DIR/src."
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_DEPLOYMENT_SETTINGS_FILE
+ BRIEF_DOCS
+ " "
+ FULL_DOCS
+ " "
+)
+
+# Generate deployment tool json
+function(qt_android_generate_deployment_settings target)
+ # Information extracted from mkspecs/features/android/android_deployment_settings.prf
+ if (NOT TARGET ${target})
+ message(SEND_ERROR "${target} is not a cmake target")
+ return()
+ endif()
+
+ get_target_property(target_type ${target} TYPE)
+
+ if (NOT "${target_type}" STREQUAL "MODULE_LIBRARY")
+ message(SEND_ERROR "QT_ANDROID_GENERATE_DEPLOYMENT_SETTINGS only works on Module targets")
+ return()
+ endif()
+
+ get_target_property(target_source_dir ${target} SOURCE_DIR)
+ get_target_property(target_binary_dir ${target} BINARY_DIR)
+ get_target_property(target_output_name ${target} OUTPUT_NAME)
+ if (NOT target_output_name)
+ set(target_output_name ${target})
+ endif()
+ set(deploy_file "${target_binary_dir}/android-lib${target_output_name}.so-deployment-settings.json")
+
+ set(file_contents "{\n")
+ # content begin
+ string(APPEND file_contents
+ " \"description\": \"This file is generated by cmake to be read by androiddeployqt and should not be modified by hand.\",\n")
+
+ # Host Qt Android install path
+ if (NOT QT_BUILDING_QT)
+ set(file_check "${Qt6_DIR}/plugins/platforms/android/libqtforandroid_${CMAKE_ANDROID_ARCH_ABI}.so")
+ if (NOT EXISTS ${file_check})
+ message(SEND_ERROR "Detected Qt installation does not contain libqtforandroid.so. This is most likely due to the installation not being a build of Qt for Android. Please update your settings.")
+ return()
+ endif()
+ set(qt_android_install_dir ${Qt6_Dir})
+ else()
+ # Building from source, use the same install prefix
+ set(qt_android_install_dir ${CMAKE_INSTALL_PREFIX})
+ endif()
+
+ file(TO_NATIVE_PATH "${qt_android_install_dir}" qt_android_install_dir_native)
+ string(APPEND file_contents
+ " \"qt\": \"${qt_android_install_dir_native}\",\n")
+
+ # Android SDK path
+ file(TO_NATIVE_PATH "${ANDROID_SDK_ROOT}" android_sdk_root_native)
+ string(APPEND file_contents
+ " \"sdk\": \"${android_sdk_root_native}\",\n")
+
+ # Android SDK Build Tools Revision
+ string(APPEND file_contents
+ " \"sdkBuildToolsRevision\": \"${QT_ANDROID_SDK_BUILD_TOOLS_VERSION}\",\n")
+
+ # Android NDK
+ file(TO_NATIVE_PATH "${ANDROID_NDK}" android_ndk_root_native)
+ string(APPEND file_contents
+ " \"ndk\": \"${android_ndk_root_native}\",\n")
+
+ # Setup LLVM toolchain
+ string(APPEND file_contents
+ " \"toolchain-prefix\": \"llvm\",\n")
+ string(APPEND file_contents
+ " \"tool-prefix\": \"llvm\",\n")
+ string(APPEND file_contents
+ " \"useLLVM\": true,\n")
+
+ # NDK Toolchain Version
+ string(APPEND file_contents
+ " \"toolchain-version\": \"${CMAKE_ANDROID_NDK_TOOLCHAIN_VERSION}\",\n")
+
+ # NDK Host
+ string(APPEND file_contents
+ " \"ndk-host\": \"${ANDROID_NDK_HOST_SYSTEM_NAME}\",\n")
+
+ if (CMAKE_ANDROID_ARCH_ABI STREQUAL "x86")
+ set(arch_value "i686-linux-android")
+ elseif (CMAKE_ANDROID_ARCH_ABI STREQUAL "x86_64")
+ set(arch_value "x86_64-linux-android")
+ elseif (CMAKE_ANDROID_ARCH_ABI STREQUAL "armv64-v8a")
+ set(arch_value "aarch64-linux-android")
+ else()
+ set(arch_value "arm-linux-androideabi")
+ endif()
+
+ # Architecture
+ string(APPEND file_contents
+ " \"architectures\": { \"${CMAKE_ANDROID_ARCH_ABI}\" : \"${arch_value}\" },\n")
+
+ # deployment dependencies
+ get_target_property(android_deployment_dependencies
+ ${target} QT_ANDROID_DEPLOYMENT_DEPENDENCIES)
+ if (android_deployment_dependencies)
+ list(JOIN android_deployment_dependencies "," android_deployment_dependencies)
+ string(APPEND file_contents
+ " \"deployment-dependencies\": \"${android_deployment_dependencies}\",\n")
+ endif()
+
+ # Extra plugins
+ get_target_property(android_extra_plugins
+ ${target} QT_ANDROID_EXTRA_PLUGINS)
+ if (android_extra_plugins)
+ list(JOIN android_extra_plugins "," android_extra_plugins)
+ string(APPEND file_contents
+ " \"android-extra-plugins\": \"${android_extra_plugins}\",\n")
+ endif()
+
+ # Extra libs
+ get_target_property(android_extra_libs
+ ${target} QT_ANDROID_EXTRA_LIBS)
+ if (android_extra_libs)
+ list(JOIN android_extra_libs "," android_extra_libs)
+ string(APPEND file_contents
+ " \"android-extra-libs\": \"${android_extra_libs}\",\n")
+ endif()
+
+ # package source dir
+ get_target_property(android_package_source_dir
+ ${target} QT_ANDROID_PACKAGE_SOURCE_DIR)
+ if (android_package_source_dir)
+ file(TO_NATIVE_PATH "${android_package_source_dir}" android_package_source_dir_native)
+ string(APPEND file_contents
+ " \"android-package-source-directory\": \"${android_package_source_dir_native}\",\n")
+endif()
+
+ #TODO: ANDROID_VERSION_NAME, doesn't seem to be used?
+
+ #TODO: ANDROID_VERSION_CODE, doesn't seem to be used?
+
+ get_target_property(qml_import_path ${target} QT_QML_IMPORT_PATH)
+ if (qml_import_path)
+ file(TO_NATIVE_PATH "${qml_import_path}" qml_import_path_native)
+ string(APPEND file_contents
+ " \"qml-import-path\": \"${qml_import_path_native}\",\n")
+ endif()
+
+ get_target_property(qml_root_path ${target} QT_QML_ROOT_PATH)
+ if(NOT qml_root_path)
+ set(qml_root_path "${target_source_dir}")
+ endif()
+ file(TO_NATIVE_PATH "${qml_root_path}" qml_root_path_native)
+ string(APPEND file_contents
+ " \"qml-root-path\": \"${qml_root_path_native}\",\n")
+
+ # App binary
+ string(APPEND file_contents
+ " \"application-binary\": \"${target_output_name}\",\n")
+
+ # Override qmlimportscanner binary path
+ set(qml_importscanner_binary_path "${QT_HOST_PATH}/bin/qmlimportscanner")
+ if (WIN32)
+ string(APPEND qml_importscanner_binary_path ".exe")
+ endif()
+ file(TO_NATIVE_PATH "${qml_importscanner_binary_path}" qml_importscanner_binary_path_native)
+ string(APPEND file_contents
+ " \"qml-importscanner-binary\" : \"${qml_importscanner_binary_path_native}\",\n")
+
+ # Last item in json file
+
+ # base location of stdlibc++, will be suffixed by androiddeploy qt
+ set(android_ndk_stdlib_base_path
+ "${ANDROID_NDK}/toolchains/llvm/prebuilt/linux-x86_64/sysroot/usr/lib/"
+ )
+ string(APPEND file_contents
+ " \"stdcpp-path\": \"${android_ndk_stdlib_base_path}\"\n")
+
+ # content end
+ string(APPEND file_contents "}\n")
+
+ file(WRITE ${deploy_file} ${file_contents})
+
+ set_target_properties(${target}
+ PROPERTIES
+ QT_ANDROID_DEPLOYMENT_SETTINGS_FILE ${deploy_file}
+ )
+endfunction()
+
+function(qt_android_apply_arch_suffix target)
+ get_target_property(target_type ${target} TYPE)
+ if (target_type STREQUAL "SHARED_LIBRARY" OR target_type STREQUAL "MODULE_LIBRARY")
+ set_property(TARGET "${target}" PROPERTY SUFFIX "_${CMAKE_ANDROID_ARCH_ABI}.so")
+ elseif (target_type STREQUAL "STATIC_LIBRARY")
+ set_property(TARGET "${target}" PROPERTY SUFFIX "_${CMAKE_ANDROID_ARCH_ABI}.a")
+ endif()
+endfunction()
+
+# Add custom target to package the APK
+function(qt_android_add_apk_target target)
+ get_target_property(deployment_file ${target} QT_ANDROID_DEPLOYMENT_SETTINGS_FILE)
+ if (NOT deployment_file)
+ message(FATAL_ERROR "Target ${target} is not a valid android executable target\n")
+ endif()
+
+ set(deployment_tool "${QT_HOST_PATH}/bin/androiddeployqt")
+ set(apk_dir "$<TARGET_PROPERTY:${target},BINARY_DIR>/android-build")
+ add_custom_target(${target}_prepare_apk_dir
+ DEPENDS ${target}
+ COMMAND ${CMAKE_COMMAND}
+ -E copy $<TARGET_FILE:${target}>
+ "${apk_dir}/libs/${CMAKE_ANDROID_ARCH_ABI}/$<TARGET_FILE_NAME:${target}>"
+ COMMENT "Copying ${target} binarty to apk folder"
+ )
+
+ add_custom_target(${target}_make_apk
+ DEPENDS ${target}_prepare_apk_dir
+ COMMAND ${deployment_tool}
+ --input ${deployment_file}
+ --output ${apk_dir}
+ COMMENT "Creating APK for ${target}"
+ )
+endfunction()
+
+
+# Add a test for Android which will be run by the android test runner tool
+function(qt_android_add_test target)
+
+ set(deployment_tool "${QT_HOST_PATH}/bin/androiddeployqt")
+ set(test_runner "${QT_HOST_PATH}/bin/androidtestrunner")
+
+ get_target_property(deployment_file ${target} QT_ANDROID_DEPLOYMENT_SETTINGS_FILE)
+ if (NOT deployment_file)
+ message(FATAL_ERROR "Target ${target} is not a valid android executable target\n")
+ endif()
+
+ set(target_binary_dir "$<TARGET_PROPERTY:${target},BINARY_DIR>")
+ set(apk_dir "${target_binary_dir}/android-build")
+
+ add_test(NAME "${target}"
+ COMMAND "${test_runner}"
+ --androiddeployqt "${deployment_tool} --input ${deployment_file}"
+ --adb "${ANDROID_SDK_ROOT}/platform-tools/adb"
+ --path "${apk_dir}"
+ --skip-install-root
+ --make "${CMAKE_COMMAND} --build ${CMAKE_BINARY_DIR} --target ${target}_make_apk"
+ --apk "${apk_dir}/${target}.apk"
+ --verbose
+ )
+endfunction()
diff --git a/cmake/QtPlatformSupport.cmake b/cmake/QtPlatformSupport.cmake
new file mode 100644
index 0000000000..b54d52eba4
--- /dev/null
+++ b/cmake/QtPlatformSupport.cmake
@@ -0,0 +1,81 @@
+function(qt_set01 result)
+ if (${ARGN})
+ set("${result}" 1 PARENT_SCOPE)
+ else()
+ set("${result}" 0 PARENT_SCOPE)
+ endif()
+endfunction()
+
+qt_set01(LINUX CMAKE_SYSTEM_NAME STREQUAL "Linux")
+qt_set01(HPUX CMAKE_SYSTEM_NAME STREQUAL "HPUX")
+qt_set01(ANDROID CMAKE_SYSTEM_NAME STREQUAL "Android") # FIXME: How to identify this?
+qt_set01(NACL CMAKE_SYSTEM_NAME STREQUAL "NaCl") # FIXME: How to identify this?
+qt_set01(INTEGRITY CMAKE_SYSTEM_NAME STREQUAL "Integrity") # FIXME: How to identify this?
+qt_set01(VXWORKS CMAKE_SYSTEM_NAME STREQUAL "VxWorks") # FIXME: How to identify this?
+qt_set01(QNX CMAKE_SYSTEM_NAME STREQUAL "QNX") # FIXME: How to identify this?
+qt_set01(OPENBSD CMAKE_SYSTEM_NAME STREQUAL "OpenBSD") # FIXME: How to identify this?
+qt_set01(FREEBSD CMAKE_SYSTEM_NAME STREQUAL "FreeBSD") # FIXME: How to identify this?
+qt_set01(NETBSD CMAKE_SYSTEM_NAME STREQUAL "NetBSD") # FIXME: How to identify this?
+qt_set01(WASM CMAKE_SYSTEM_NAME STREQUAL "Emscripten")
+
+qt_set01(BSD APPLE OR OPENBSD OR FREEBSD OR NETBSD)
+
+qt_set01(WINRT WIN32 AND CMAKE_VS_PLATFORM_TOOSLET STREQUAL "winrt") # FIXME: How to identify this?
+
+qt_set01(APPLE_IOS APPLE AND CMAKE_SYSTEM_NAME STREQUAL "iOS")
+qt_set01(APPLE_TVOS APPLE AND CMAKE_SYSTEM_NAME STREQUAL "tvOS")
+qt_set01(APPLE_WATCHOS APPLE AND CMAKE_SYSTEM_NAME STREQUAL "watchOS")
+qt_set01(APPLE_UIKIT APPLE AND (APPLE_IOS OR APPLE_TVOS OR APPLE_WATCHOS))
+qt_set01(APPLE_OSX APPLE AND NOT APPLE_UIKIT)
+
+qt_set01(GCC CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
+qt_set01(CLANG CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+qt_set01(ICC CMAKE_C_COMPILER MATCHES "icc|icl")
+qt_set01(QCC CMAKE_C_COMPILER MATCHES "qcc") # FIXME: How to identify this?
+
+if(CMAKE_SIZEOF_VOID_P EQUAL 8)
+ set(QT_64BIT TRUE)
+elseif(CMAKE_SIZEOF_VOID_P EQUAL 4)
+ set(QT_32BIT TRUE)
+endif()
+
+# Parses a version string like "xx.yy.zz" and sets the major, minor and patch variables.
+function(qt_parse_version_string version_string out_var_prefix)
+ string(REPLACE "." ";" version_list ${version_string})
+ list(LENGTH version_list length)
+
+ set(out_var "${out_var_prefix}_MAJOR")
+ set(value "")
+ if(length GREATER 0)
+ list(GET version_list 0 value)
+ list(REMOVE_AT version_list 0)
+ math(EXPR length "${length}-1")
+ endif()
+ set(${out_var} "${value}" PARENT_SCOPE)
+
+ set(out_var "${out_var_prefix}_MINOR")
+ set(value "")
+ if(length GREATER 0)
+ list(GET version_list 0 value)
+ set(${out_var} "${value}" PARENT_SCOPE)
+ list(REMOVE_AT version_list 0)
+ math(EXPR length "${length}-1")
+ endif()
+ set(${out_var} "${value}" PARENT_SCOPE)
+
+ set(out_var "${out_var_prefix}_PATCH")
+ set(value "")
+ if(length GREATER 0)
+ list(GET version_list 0 value)
+ set(${out_var} "${value}" PARENT_SCOPE)
+ list(REMOVE_AT version_list 0)
+ math(EXPR length "${length}-1")
+ endif()
+ set(${out_var} "${value}" PARENT_SCOPE)
+endfunction()
+
+# Set up the separate version components for the compiler version, to allow mapping of qmake
+# conditions like 'equals(QT_GCC_MAJOR_VERSION,5)'.
+if(CMAKE_CXX_COMPILER_VERSION)
+ qt_parse_version_string("${CMAKE_CXX_COMPILER_VERSION}" "QT_COMPILER_VERSION")
+endif()
diff --git a/cmake/QtPluginConfig.cmake.in b/cmake/QtPluginConfig.cmake.in
new file mode 100644
index 0000000000..5fde0bc511
--- /dev/null
+++ b/cmake/QtPluginConfig.cmake.in
@@ -0,0 +1,17 @@
+include_guard(DIRECTORY)
+
+@PACKAGE_INIT@
+
+include(CMakeFindDependencyMacro)
+
+get_filename_component(_import_prefix "${CMAKE_CURRENT_LIST_FILE}" PATH)
+get_filename_component(_import_prefix "${_import_prefix}" REALPATH)
+
+if (NOT QT_NO_CREATE_TARGETS)
+ # Find required dependencies, if any.
+ if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/@target@Dependencies.cmake")
+ include("${CMAKE_CURRENT_LIST_DIR}/@target@Dependencies.cmake")
+ endif()
+
+ include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@Targets.cmake")
+endif()
diff --git a/cmake/QtPluginDependencies.cmake.in b/cmake/QtPluginDependencies.cmake.in
new file mode 100644
index 0000000000..f25d0bed43
--- /dev/null
+++ b/cmake/QtPluginDependencies.cmake.in
@@ -0,0 +1,42 @@
+# note: _third_party_deps example: "ICU\\;1.0\\;i18n uc data;ZLIB\\;\\;"
+set(_third_party_deps "@third_party_deps@")
+
+foreach(_target_dep ${_third_party_deps})
+ list(GET _target_dep 0 pkg)
+ list(GET _target_dep 1 version)
+ list(GET _target_dep 2 components)
+ set(find_package_args "${pkg}")
+ if(version)
+ list(APPEND find_package_args "${version}")
+ endif()
+
+ if(components)
+ string(REPLACE " " ";" components "${components}")
+ find_dependency(${find_package_args} COMPONENTS ${components})
+ else()
+ find_dependency(${find_package_args})
+ endif()
+
+ if (NOT ${pkg}_FOUND)
+ set(@target@_FOUND FALSE)
+ return()
+ endif()
+endforeach()
+
+# note: target_deps example: "Qt6Core\;5.12.0;Qt6Gui\;5.12.0"
+set(_target_deps "@target_deps@")
+foreach(_target_dep ${_target_deps})
+ list(GET _target_dep 0 pkg)
+ list(GET _target_dep 1 version)
+
+ if (NOT ${pkg}_FOUND)
+ find_dependency(${pkg} ${version}
+ PATHS "${CMAKE_CURRENT_LIST_DIR}/.." ${QT_EXAMPLES_CMAKE_PREFIX_PATH} NO_DEFAULT_PATH
+ )
+ endif()
+
+ if (NOT ${pkg}_FOUND)
+ set(@target@_FOUND FALSE)
+ return()
+ endif()
+endforeach()
diff --git a/cmake/QtPlugins.cmake.in b/cmake/QtPlugins.cmake.in
new file mode 100644
index 0000000000..5e2352d6c1
--- /dev/null
+++ b/cmake/QtPlugins.cmake.in
@@ -0,0 +1,114 @@
+include_guard(DIRECTORY)
+
+@QT_MODULE_PLUGIN_INCLUDES@
+
+if(NOT @BUILD_SHARED_LIBS@)
+ set(_module_target "@INSTALL_CMAKE_NAMESPACE@::@QT_MODULE@")
+ # Properties can't be set on aliased targets, so make sure to unalias the target. This is needed
+ # when Qt examples are built as part of the Qt build itself.
+ get_target_property(_aliased_target ${_module_target} ALIASED_TARGET)
+ if(_aliased_target)
+ set(_module_target ${_aliased_target})
+ endif()
+ unset(_aliased_target)
+
+ set(_default_plugins_are_enabled "$<NOT:$<STREQUAL:$<GENEX_EVAL:$<TARGET_PROPERTY:QT_DEFAULT_PLUGINS>>,0>>")
+ # Make sure to boolify the result of the expression, in case if the returned property value
+ # is empty.
+ set(_default_plugins_are_enabled_wrapped "$<BOOL:${_default_plugins_are_enabled}>")
+ set(_manual_plugins_genex "$<GENEX_EVAL:$<TARGET_PROPERTY:QT_PLUGINS>>")
+ set(_no_plugins_genex "$<GENEX_EVAL:$<TARGET_PROPERTY:QT_NO_PLUGINS>>")
+
+ # In super builds the rules below pollute the dependency rule for the
+ # plugin target when it's being build, causing cyclic dependencies.
+ # to overcome this, we check if the current target where this rule evaluates
+ # has a QT_BUILD_PROJECT_NAME equal to the current PROJECT_NAME.
+ # If so we disable the injection of plugin link rules to avoid cyclic
+ # dependencies.
+ if (@QT_SUPERBUILD@)
+ set(_build_allow_plugin_link_rules_genex "$<NOT:$<STREQUAL:$<TARGET_PROPERTY:QT_BUILD_PROJECT_NAME>,@PROJECT_NAME@>>")
+ else()
+ set(_build_allow_plugin_link_rules_genex 1)
+ endif()
+
+ # The code in here uses the properties defined in qt_import_plugins (Qt6CoreMacros.cmake)
+ foreach(target @qt_plugins@)
+ set(_plugin_target "@INSTALL_CMAKE_NAMESPACE@::${target}")
+ get_target_property(_classname "${_plugin_target}" QT_PLUGIN_CLASS_NAME)
+ if(NOT _classname)
+ message("Warning: plugin ${_plugin_target} has no class name, skipping.")
+ continue()
+ endif()
+
+ get_target_property(_plugin_type "${_plugin_target}" QT_PLUGIN_TYPE)
+ if(NOT _plugin_type)
+ message("Warning: plugin ${_plugin_target} has no type ('${_plugin_type}'), skipping.")
+ continue()
+ endif()
+
+ list(APPEND "QT_ALL_PLUGINS_FOUND_BY_FIND_PACKAGE_${_plugin_type}" "${target}")
+
+ set(_plugin_is_default "$<TARGET_PROPERTY:${_plugin_target},QT_DEFAULT_PLUGIN>")
+
+ # INCLUDE
+ set(_plugin_is_whitelisted "$<IN_LIST:${_plugin_target},${_manual_plugins_genex}>")
+
+ # Note: qt_import_plugins sets the QT_PLUGINS_${_plugin_type} to "-"
+ # when excluding it with EXCLUDE_BY_TYPE,
+ # which ensures that no plug-in will be supported unless explicitly re-added afterwards.
+ string(CONCAT _plugin_is_not_blacklisted
+ "$<AND:"
+ "$<NOT:" # EXCLUDE
+ "$<IN_LIST:${_plugin_target},${_no_plugins_genex}>"
+ ">,"
+ # excludes both plugins targeted by EXCLUDE_BY_TYPE and not included in INCLUDE_BY_TYPE
+ "$<STREQUAL:,$<GENEX_EVAL:$<TARGET_PROPERTY:QT_PLUGINS_${_plugin_type}>>>"
+ ">"
+ )
+
+ # Support INCLUDE_BY_TYPE
+ string(CONCAT _plugin_is_in_type_whitelist
+ "$<IN_LIST:"
+ "${_plugin_target},"
+ "$<GENEX_EVAL:"
+ "$<TARGET_PROPERTY:QT_PLUGINS_${_plugin_type}>"
+ ">"
+ ">"
+ )
+
+ # Complete condition that defines whether a static plugin is linked
+ string(CONCAT _plugin_condition
+ "$<BOOL:$<AND:"
+ "${_build_allow_plugin_link_rules_genex},"
+ "$<OR:"
+ "${_plugin_is_whitelisted},"
+ "${_plugin_is_in_type_whitelist},"
+ "$<AND:"
+ "${_default_plugins_are_enabled_wrapped},"
+ "${_plugin_is_default},"
+ "${_plugin_is_not_blacklisted}"
+ ">"
+ ">"
+ ">>"
+ )
+
+ # If this condition is true, we link against the plug-in
+ set(_plugin_genex "$<${_plugin_condition}:${_plugin_target}>")
+ target_link_libraries(${_module_target} INTERFACE "${_plugin_genex}")
+
+ set(_generated_qt_plugin_file_name
+ "${CMAKE_CURRENT_BINARY_DIR}/qt_@QT_MODULE@_${target}.cpp")
+ set(_generated_qt_plugin_file_name_template "${_generated_qt_plugin_file_name}.in")
+ set(_generated_qt_plugin_file_content "#include <QtPlugin>\nQ_IMPORT_PLUGIN(${_classname})")
+
+ # Generate a source file to import that plug-in. Has to be done with configure_file,
+ # because file(GENERATE) and target_sources has issues with scopes.
+ file(WRITE "${_generated_qt_plugin_file_name_template}"
+ "${_generated_qt_plugin_file_content}")
+ configure_file("${_generated_qt_plugin_file_name_template}"
+ "${_generated_qt_plugin_file_name}")
+
+ target_sources(${_module_target} INTERFACE
+ "$<${_plugin_condition}:${_generated_qt_plugin_file_name}>")
+ endforeach()
+endif()
diff --git a/cmake/QtPostProcess.cmake b/cmake/QtPostProcess.cmake
new file mode 100644
index 0000000000..b20b85bef9
--- /dev/null
+++ b/cmake/QtPostProcess.cmake
@@ -0,0 +1,376 @@
+function(qt_internal_write_depends_file target)
+ set(module Qt${target})
+ set(outfile "${QT_BUILD_DIR}/include/${module}/${module}Depends")
+ message("Generate ${outfile}...")
+ set(contents "/* This file was generated by cmake with the info from ${module} target. */\n")
+ string(APPEND contents "#ifdef __cplusplus /* create empty PCH in C mode */\n")
+ foreach (m ${ARGN})
+ string(APPEND contents "# include <Qt${m}/Qt${m}>\n")
+ endforeach()
+ string(APPEND contents "#endif\n")
+
+ file(GENERATE OUTPUT "${outfile}" CONTENT "${contents}")
+endfunction()
+
+macro(qt_collect_third_party_deps target)
+ set(_target_is_static OFF)
+ get_target_property(_target_type ${target} TYPE)
+ if (${_target_type} STREQUAL "STATIC_LIBRARY")
+ set(_target_is_static ON)
+ endif()
+ unset(_target_type)
+ # If we are doing a non-static Qt build, we only want to propagate public dependencies.
+ # If we are doing a static Qt build, we need to propagate all dependencies.
+ set(depends_var "public_depends")
+ if(_target_is_static)
+ set(depends_var "depends")
+ endif()
+ unset(_target_is_static)
+
+ foreach(dep ${${depends_var}})
+ # Gather third party packages that should be found when using the Qt module.
+ # Also handle nolink target dependencies.
+ string(REGEX REPLACE "_nolink$" "" base_dep "${dep}")
+ if(NOT base_dep STREQUAL dep)
+ # Resets target name like Vulkan_nolink to Vulkan, because we need to call
+ # find_package(Vulkan).
+ set(dep ${base_dep})
+ endif()
+
+ if(TARGET ${dep})
+ list(FIND third_party_deps_seen ${dep} dep_seen)
+
+ get_target_property(package_name ${dep} INTERFACE_QT_PACKAGE_NAME)
+ if(dep_seen EQUAL -1 AND package_name)
+ list(APPEND third_party_deps_seen ${dep})
+ get_target_property(package_version ${dep} INTERFACE_QT_PACKAGE_VERSION)
+ if(NOT package_version)
+ set(package_version "")
+ endif()
+
+ get_target_property(package_components ${dep} INTERFACE_QT_PACKAGE_COMPONENTS)
+ if(NOT package_components)
+ set(package_components "")
+ endif()
+
+ list(APPEND third_party_deps
+ "${package_name}\;${package_version}\;${package_components}")
+ endif()
+ endif()
+ endforeach()
+endmacro()
+
+function(qt_internal_create_module_depends_file target)
+ get_target_property(target_type "${target}" TYPE)
+ if(target_type STREQUAL "INTERFACE_LIBRARY")
+ set(arg_HEADER_MODULE ON)
+ else()
+ set(arg_HEADER_MODULE OFF)
+ endif()
+
+ if(NOT arg_HEADER_MODULE)
+ get_target_property(depends "${target}" LINK_LIBRARIES)
+ endif()
+ get_target_property(public_depends "${target}" INTERFACE_LINK_LIBRARIES)
+
+ # Used for collecting Qt module dependencies that should be find_package()'d in
+ # ModuleDependencies.cmake.
+ get_target_property(target_deps "${target}" _qt_target_deps)
+ set(target_deps_seen "")
+
+ if(NOT arg_HEADER_MODULE)
+ get_target_property(extra_depends "${target}" QT_EXTRA_PACKAGE_DEPENDENCIES)
+ endif()
+ if(NOT extra_depends STREQUAL "${extra_depends}-NOTFOUND")
+ list(APPEND target_deps "${extra_depends}")
+ endif()
+
+ # Used for assembling the content of an include/Module/ModuleDepends.h header.
+ set(qtdeps "")
+
+ # Used for collecting third party dependencies that should be find_package()'d in
+ # ModuleDependencies.cmake.
+ set(third_party_deps "")
+ set(third_party_deps_seen "")
+
+ # Used for collecting Qt tool dependencies that should be find_package()'d in
+ # ModuleToolsDependencies.cmake.
+ set(tool_deps "")
+ set(tool_deps_seen "")
+
+ # Used for collecting Qt tool dependencies that should be find_package()'d in
+ # ModuleDependencies.cmake.
+ set(main_module_tool_deps "")
+
+ qt_internal_get_qt_all_known_modules(known_modules)
+
+ set(all_depends ${depends} ${public_depends})
+ foreach (dep ${all_depends})
+ # Normalize module by stripping leading "Qt::" and trailing "Private"
+ if (dep MATCHES "Qt::(.*)")
+ set(dep "${CMAKE_MATCH_1}")
+ endif()
+ if (dep MATCHES "(.*)Private")
+ set(dep "${CMAKE_MATCH_1}")
+ endif()
+
+ list(FIND known_modules "${dep}" _pos)
+ if (_pos GREATER -1)
+ list(APPEND qtdeps "${dep}")
+
+ # Make the ModuleTool package depend on dep's ModuleTool package.
+ list(FIND tool_deps_seen ${dep} dep_seen)
+ if(dep_seen EQUAL -1 AND ${dep} IN_LIST QT_KNOWN_MODULES_WITH_TOOLS)
+ list(APPEND tool_deps_seen ${dep})
+ list(APPEND tool_deps
+ "${INSTALL_CMAKE_NAMESPACE}${dep}Tools\;${PROJECT_VERSION}")
+ endif()
+ endif()
+ endforeach()
+
+ qt_collect_third_party_deps(${target})
+
+ # Add dependency to the main ModuleTool package to ModuleDependencies file.
+ if(${target} IN_LIST QT_KNOWN_MODULES_WITH_TOOLS)
+ set(main_module_tool_deps
+ "${INSTALL_CMAKE_NAMESPACE}${target}Tools\;${PROJECT_VERSION}")
+ endif()
+
+ # Dirty hack because https://gitlab.kitware.com/cmake/cmake/issues/19200
+ foreach(dep ${target_deps})
+ if(dep)
+ list(FIND target_deps_seen "${dep}" dep_seen)
+ if(dep_seen EQUAL -1)
+ list(LENGTH dep len)
+ if(NOT (len EQUAL 2))
+ message(FATAL_ERROR "List '${dep}' should look like QtFoo;version")
+ endif()
+ list(GET dep 0 dep_name)
+ list(GET dep 1 dep_ver)
+
+ list(APPEND target_deps_seen "${dep_name}\;${dep_ver}")
+ endif()
+ endif()
+ endforeach()
+ set(target_deps "${target_deps_seen}")
+
+ if (DEFINED qtdeps)
+ list(REMOVE_DUPLICATES qtdeps)
+ endif()
+
+ get_target_property(hasModuleHeaders "${target}" INTERFACE_MODULE_HAS_HEADERS)
+ if (${hasModuleHeaders})
+ qt_internal_write_depends_file("${target}" ${qtdeps})
+ endif()
+
+ if(third_party_deps OR main_module_tool_deps OR target_deps)
+ set(path_suffix "${INSTALL_CMAKE_NAMESPACE}${target}")
+ qt_path_join(config_build_dir ${QT_CONFIG_BUILD_DIR} ${path_suffix})
+ qt_path_join(config_install_dir ${QT_CONFIG_INSTALL_DIR} ${path_suffix})
+
+ # Configure and install ModuleDependencies file.
+ configure_file(
+ "${QT_CMAKE_DIR}/QtModuleDependencies.cmake.in"
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}Dependencies.cmake"
+ @ONLY
+ )
+
+ qt_install(FILES
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${target}Dependencies.cmake"
+ DESTINATION "${config_install_dir}"
+ COMPONENT Devel
+ )
+
+ endif()
+ if(tool_deps)
+ # The value of the property will be used by qt_export_tools.
+ set_property(TARGET "${target}" PROPERTY _qt_tools_package_deps "${tool_deps}")
+ endif()
+endfunction()
+
+function(qt_internal_create_plugin_depends_file target)
+ get_target_property(qt_module "${target}" QT_MODULE)
+ get_target_property(depends "${target}" LINK_LIBRARIES)
+ get_target_property(public_depends "${target}" INTERFACE_LINK_LIBRARIES)
+ get_target_property(target_deps "${target}" _qt_target_deps)
+ set(target_deps_seen "")
+
+ qt_collect_third_party_deps(${target})
+
+ # Dirty hack because https://gitlab.kitware.com/cmake/cmake/issues/19200
+ foreach(dep ${target_deps})
+ if(dep)
+ list(FIND target_deps_seen "${dep}" dep_seen)
+ if(dep_seen EQUAL -1)
+ list(LENGTH dep len)
+ if(NOT (len EQUAL 2))
+ message(FATAL_ERROR "List '${dep}' should look like QtFoo;version")
+ endif()
+ list(GET dep 0 dep_name)
+ list(GET dep 1 dep_ver)
+
+ list(APPEND target_deps_seen "${dep_name}\;${dep_ver}")
+ endif()
+ endif()
+ endforeach()
+ set(target_deps "${target_deps_seen}")
+
+ if(third_party_deps OR target_deps)
+ # Setup build and install paths
+ if(qt_module)
+ set(path_suffix "${INSTALL_CMAKE_NAMESPACE}${qt_module}")
+ else()
+ set(path_suffix "${INSTALL_CMAKE_NAMESPACE}${target}")
+ endif()
+
+ qt_path_join(config_build_dir ${QT_CONFIG_BUILD_DIR} ${path_suffix})
+ qt_path_join(config_install_dir ${QT_CONFIG_INSTALL_DIR} ${path_suffix})
+
+ # Configure and install ModuleDependencies file.
+ configure_file(
+ "${QT_CMAKE_DIR}/QtPluginDependencies.cmake.in"
+ "${config_build_dir}/${target}Dependencies.cmake"
+ @ONLY
+ )
+
+ qt_install(FILES
+ "${config_build_dir}/${target}Dependencies.cmake"
+ DESTINATION "${config_install_dir}"
+ COMPONENT Devel
+ )
+ endif()
+endfunction()
+
+# Create Depends.cmake & Depends.h files for all modules and plug-ins.
+function(qt_internal_create_depends_files)
+ qt_internal_get_qt_repo_known_modules(repo_known_modules)
+
+ message("Generating ModuleDepends files and CMake ModuleDependencies files for ${repo_known_modules}...")
+ foreach (target ${repo_known_modules})
+ qt_internal_create_module_depends_file(${target})
+ endforeach()
+
+ message("Generating CMake PluginDependencies files for ${QT_KNOWN_PLUGINS}...")
+ foreach (target ${QT_KNOWN_PLUGINS})
+ qt_internal_create_plugin_depends_file(${target})
+ endforeach()
+endfunction()
+
+# This function creates the Qt<Module>Plugins.cmake used to list all
+# the plug-in target files.
+function(qt_internal_create_plugins_files)
+ # The plugins cmake configuration is only needed for static builds. Dynamic builds don't need
+ # the application to link against plugins at build time.
+ if(QT_BUILD_SHARED_LIBS)
+ return()
+ endif()
+ qt_internal_get_qt_repo_known_modules(repo_known_modules)
+
+ message("Generating Plugins files for ${repo_known_modules}...")
+ foreach (QT_MODULE ${repo_known_modules})
+ get_target_property(target_type "${QT_MODULE}" TYPE)
+ if(target_type STREQUAL "INTERFACE_LIBRARY")
+ # No plugins are provided by a header only module.
+ continue()
+ endif()
+ qt_path_join(config_build_dir ${QT_CONFIG_BUILD_DIR} ${INSTALL_CMAKE_NAMESPACE}${QT_MODULE})
+ qt_path_join(config_install_dir ${QT_CONFIG_INSTALL_DIR} ${INSTALL_CMAKE_NAMESPACE}${QT_MODULE})
+ set(QT_MODULE_PLUGIN_INCLUDES "")
+
+ get_target_property(qt_plugins "${QT_MODULE}" QT_PLUGINS)
+ if(qt_plugins)
+ foreach (pluginTarget ${qt_plugins})
+ set(QT_MODULE_PLUGIN_INCLUDES "${QT_MODULE_PLUGIN_INCLUDES}include(\"\${CMAKE_CURRENT_LIST_DIR}/${pluginTarget}Config.cmake\")\n")
+ endforeach()
+ configure_file(
+ "${QT_CMAKE_DIR}/QtPlugins.cmake.in"
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${QT_MODULE}Plugins.cmake"
+ @ONLY
+ )
+ qt_install(FILES
+ "${config_build_dir}/${INSTALL_CMAKE_NAMESPACE}${QT_MODULE}Plugins.cmake"
+ DESTINATION "${config_install_dir}"
+ COMPONENT Devel
+ )
+ endif()
+ endforeach()
+endfunction()
+
+function(qt_generate_build_internals_extra_cmake_code)
+ if(PROJECT_NAME STREQUAL "QtBase")
+ set(QT_EXTRA_BUILD_INTERNALS_VARS)
+ foreach(var IN LISTS QT_BASE_CONFIGURE_TESTS_VARS_TO_EXPORT)
+ string(APPEND QT_EXTRA_BUILD_INTERNALS_VARS "set(${var} \"${${var}}\" CACHE INTERNAL \"\")\n")
+ endforeach()
+
+ set(QT_SOURCE_TREE "${QtBase_SOURCE_DIR}")
+ qt_path_join(extra_file_path
+ ${QT_CONFIG_BUILD_DIR}
+ ${INSTALL_CMAKE_NAMESPACE}BuildInternals/QtBuildInternalsExtra.cmake)
+ configure_file(
+ "${CMAKE_CURRENT_LIST_DIR}/QtBuildInternalsExtra.cmake.in"
+ "${extra_file_path}"
+ @ONLY
+ )
+ endif()
+endfunction()
+
+# For every Qt module check if there any android dependencies that require
+# processing.
+function(qt_modules_process_android_dependencies)
+ qt_internal_get_qt_repo_known_modules(repo_known_modules)
+ foreach (target ${repo_known_modules})
+ qt_android_dependencies(${target})
+ endforeach()
+endfunction()
+
+function(qt_create_tools_config_files)
+ # Create packages like Qt6CoreTools/Qt6CoreToolsConfig.cmake.
+ foreach(module_name ${QT_KNOWN_MODULES_WITH_TOOLS})
+ qt_export_tools("${module_name}")
+ endforeach()
+endfunction()
+
+function(qt_internal_create_config_file_for_standalone_tests)
+ set(standalone_tests_config_dir "StandaloneTests")
+ qt_path_join(config_build_dir
+ ${QT_CONFIG_BUILD_DIR}
+ "${INSTALL_CMAKE_NAMESPACE}BuildInternals" "${standalone_tests_config_dir}")
+ qt_path_join(config_install_dir
+ ${QT_CONFIG_INSTALL_DIR}
+ "${INSTALL_CMAKE_NAMESPACE}BuildInternals" "${standalone_tests_config_dir}")
+
+ list(JOIN QT_REPO_KNOWN_MODULES " " QT_REPO_KNOWN_MODULES_STRING)
+ string(STRIP "${QT_REPO_KNOWN_MODULES_STRING}" QT_REPO_KNOWN_MODULES_STRING)
+
+ # Skip generating and installing file if no modules were built. This make sure not to install
+ # anything when build qtx11extras on macOS for example.
+ if(NOT QT_REPO_KNOWN_MODULES_STRING)
+ return()
+ endif()
+
+ # Ceate a Config file that calls find_package on the modules that were built as part
+ # of the current repo. This is used for standalone tests.
+ configure_file(
+ "${QT_CMAKE_DIR}/QtStandaloneTestsConfig.cmake.in"
+ "${config_build_dir}/${PROJECT_NAME}TestsConfig.cmake"
+ @ONLY
+ )
+ qt_install(FILES
+ "${config_build_dir}/${PROJECT_NAME}TestsConfig.cmake"
+ DESTINATION "${config_install_dir}"
+ COMPONENT Devel
+ )
+endfunction()
+
+qt_internal_create_depends_files()
+qt_generate_build_internals_extra_cmake_code()
+qt_internal_create_plugins_files()
+qt_internal_create_config_file_for_standalone_tests()
+
+# Needs to run after qt_internal_create_depends_files.
+qt_create_tools_config_files()
+
+if (ANDROID)
+ qt_modules_process_android_dependencies()
+endif()
diff --git a/cmake/QtProperties.cmake b/cmake/QtProperties.cmake
new file mode 100644
index 0000000000..a12fa53252
--- /dev/null
+++ b/cmake/QtProperties.cmake
@@ -0,0 +1,107 @@
+define_property(TARGET
+ PROPERTY
+ QT_PLUGINS
+ BRIEF_DOCS
+ "List of Qt plug-ins associated with a given Qt module."
+ FULL_DOCS
+ "This is a property on Qt modules.
+ For instance, sqlite;odbc for Sql"
+)
+
+define_property(TARGET
+ PROPERTY
+ MODULE_PLUGIN_TYPES
+ BRIEF_DOCS
+ "List of plugin categories associated to the Qt module"
+ FULL_DOCS
+ "This is a property on Qt modules.
+ For instance, sqldrivers for Sql."
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_PLUGIN_CLASS_NAME
+ BRIEF_DOCS
+ "Class name of the Qt plug-in"
+ FULL_DOCS
+ "This is a property on Qt plug-ins.
+ For instance, QICOPlugin for the qico plug-in"
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_PLUGIN_TYPE
+ BRIEF_DOCS
+ "Type of the Qt plug-in"
+ FULL_DOCS
+ "This is a property on Qt plug-ins.
+ For example, the value of the QT_PLUGIN_TYPE property on the qico plugin is \"imageformats\""
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_MODULE
+ BRIEF_DOCS
+ "Qt module associated with a plug-in."
+ FULL_DOCS
+ "This is a property on Qt plug-ins.
+ For instance, Sql for qsqlite"
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_DEFAULT_PLUGIN
+ BRIEF_DOCS
+ "Indicates whether a plug-in is added by default."
+ FULL_DOCS
+ "This is a property on Qt plug-ins.
+ It is mainly used to indicate if a plug-in should be added
+ to the default set of plug-ins when building a static app -
+ for instance, which QPA should be linked."
+)
+
+define_property(GLOBAL
+ PROPERTY
+ QT_KNOWN_PLUGINS
+ BRIEF_DOCS
+ ""
+ FULL_DOCS
+ ""
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_QML_MODULE_TARGET_PATH
+ BRIEF_DOCS
+ "Specifies the target path for a qml module"
+ FULL_DOCS
+ "Specifies the target path for a qml module"
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_QML_MODULE_URI
+ BRIEF_DOCS
+ "Specifies the URI for a qml module"
+ FULL_DOCS
+ "Specifies the URI for a qml module"
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_RESOURCE_PREFIX
+ BRIEF_DOCS
+ "Specifies the default Qt resource prefix."
+ FULL_DOCS
+ "When using qt_add_resource() without a PREFIX, then prefix of this target property
+ will be used."
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_QML_MODULE_VERSION
+ BRIEF_DOCS
+ "Specifies the qml module's version."
+ FULL_DOCS
+ "Specifies the qml module's version."
+)
diff --git a/cmake/QtResource.cmake.in b/cmake/QtResource.cmake.in
new file mode 100644
index 0000000000..2f8f77eb79
--- /dev/null
+++ b/cmake/QtResource.cmake.in
@@ -0,0 +1,313 @@
+#
+# All things resource related
+#
+
+function(__qt_get_relative_resource_path_for_file output_alias file)
+ get_property(alias SOURCE ${file} PROPERTY QT_RESOURCE_ALIAS)
+ if (NOT alias)
+ set(alias "${file}")
+ endif()
+ set(${output_alias} ${alias} PARENT_SCOPE)
+endfunction()
+
+function(__qt_propagate_generated_resource target resource_name generated_source_code output_generated_target)
+ get_target_property(type ${target} TYPE)
+ if(type STREQUAL STATIC_LIBRARY)
+ set(resource_target "${target}_resources_${resourceName}")
+ add_library("${resource_target}" OBJECT "${generated_source_code}")
+
+ # Use TARGET_NAME genex to map to the correct prefixed target name when it is exported
+ # via qt_install(EXPORT), so that the consumers of the target can find the object library
+ # as well.
+ target_link_libraries(${target} INTERFACE
+ "$<TARGET_OBJECTS:$<TARGET_NAME:${resource_target}>>")
+ set(${output_generated_target} "${resource_target}" PARENT_SCOPE)
+ else()
+ set(${output_generated_target} "" PARENT_SCOPE)
+ target_sources(${target} PRIVATE ${generated_source_code})
+ endif()
+endfunction()
+
+# Inspect all files passed to a call to qt_add_resource. If there are any
+# files present, invoke the quick compiler and return the remaining resource
+# files that have not been processed in OUTPUT_REMAINING_RESOURCES as well as the new
+# name for the resource in OUTPUT_RESOURCE_NAME.
+function(__qt_quick_compiler_process_resources target resource_name)
+
+ cmake_parse_arguments(arg
+ "" "PREFIX;OUTPUT_REMAINING_RESOURCES;OUTPUT_RESOURCE_NAME;OUTPUT_GENERATED_TARGET" "FILES" ${ARGN}
+ )
+
+ set(qml_files)
+ set(resource_files)
+ set(retained_files)
+ # scan for qml files
+ foreach(file IN LISTS arg_FILES)
+ # check whether this resource should not be processed by the qt quick
+ # compiler
+ get_source_file_property(skip_compiler_check ${file} QT_SKIP_QUICKCOMPILER)
+ get_source_file_property(retain_compiler_check ${file} QT_RETAIN_QUICKCOMPILER)
+ if (skip_compiler_check)
+ list(APPEND resource_files ${file})
+ continue()
+ endif()
+
+ if (${file} MATCHES "\.js$"
+ OR ${file} MATCHES "\.mjs$"
+ OR ${file} MATCHES "\.qml$")
+ list(APPEND qml_files ${file})
+ if (retain_compiler_check)
+ list(APPEND retained_files ${file})
+ list(APPEND resource_files ${file})
+ endif()
+ else()
+ list(APPEND resource_files ${file})
+ endif()
+ endforeach()
+ if (NOT TARGET @QT_CMAKE_EXPORT_NAMESPACE@::qmlcachegen AND qml_files)
+ message(WARNING "QT@PROJECT_VERSION_MAJOR@_PROCESS_RESOURCE: Qml files were detected but the qmlcachgen target is not defined. Consider adding QmlTools to your find_package command.")
+ endif()
+
+ set(retained_resource_paths)
+ if (TARGET @QT_CMAKE_EXPORT_NAMESPACE@::qmlcachegen AND qml_files)
+ # Enable qt quick compiler support
+ set(qml_resource_file "${CMAKE_CURRENT_BINARY_DIR}/.rcc/${resource_name}.qrc")
+ if (resource_files)
+ set(chained_resource_name "${resource_name}_qmlcache")
+ endif()
+
+ foreach(file IN LISTS qml_files)
+ get_filename_component(file_absolute ${file} ABSOLUTE)
+ file(RELATIVE_PATH file_relative ${CMAKE_CURRENT_SOURCE_DIR} ${file_absolute})
+ __qt_get_relative_resource_path_for_file(file_resource_path ${file})
+ if (arg_PREFIX STREQUAL "/")
+ # TO_CMAKE_PATH does not clean up cases such as //Foo
+ set(file_resource_path "/${file_resource_path}")
+ else()
+ set(file_resource_path "${arg_PREFIX}/${file_resource_path}")
+ endif()
+ if (file IN_LIST retained_files)
+ list(APPEND retained_resource_paths ${file_resource_path})
+ endif()
+ file(TO_CMAKE_PATH ${file_resource_path} file_resource_path)
+ list(APPEND file_resource_paths ${file_resource_path})
+ string(REGEX REPLACE "\.js$" "_js" compiled_file ${file_relative})
+ string(REGEX REPLACE "\.mjs$" "_mjs" compiled_file ${compiled_file})
+ string(REGEX REPLACE "\.qml$" "_qml" compiled_file ${compiled_file})
+ string(REGEX REPLACE "[\$#\?]+" "_" compiled_file ${compiled_file})
+ set(compiled_file "${CMAKE_CURRENT_BINARY_DIR}/.rcc/qmlcache/${resource_name}/${compiled_file}.cpp")
+ get_filename_component(out_dir ${compiled_file} DIRECTORY)
+ if(NOT EXISTS ${out_dir})
+ file(MAKE_DIRECTORY ${out_dir})
+ endif()
+ add_custom_command(
+ OUTPUT ${compiled_file}
+ DEPENDS ${file_absolute}
+ ${QT_TOOL_PATH_SETUP_COMMAND}
+ COMMAND
+ @QT_CMAKE_EXPORT_NAMESPACE@::qmlcachegen
+ --resource-path ${file_resource_path}
+ -o ${compiled_file}
+ ${file_absolute}
+ )
+ target_sources(${target} PRIVATE ${compiled_file})
+ endforeach()
+
+ set(qmlcache_loader_list "${CMAKE_CURRENT_BINARY_DIR}/.rcc/qmlcache/${resource_name}/qml_loader_file_list.rsp")
+ file(GENERATE
+ OUTPUT ${qmlcache_loader_list}
+ CONTENT "$<JOIN:${file_resource_paths},\n>"
+ )
+
+ set(qmlcache_loader_file "${CMAKE_CURRENT_BINARY_DIR}/.rcc/qmlcache/${resource_name}/qmlcache_loader.cpp")
+ set(resource_name_arg "${resource_name}.qrc")
+ if (chained_resource_name)
+ set(resource_name_arg "${resource_name_arg}=${chained_resource_name}")
+ endif()
+
+ if (retained_resource_paths)
+ set(retained_loader_list "${CMAKE_CURRENT_BINARY_DIR}/.rcc/qmlcache/${resource_name}/retained_file_list.rsp")
+ file(GENERATE
+ OUTPUT ${retained_loader_list}
+ CONTENT "$<JOIN:${retained_resource_paths},\n>"
+ )
+ set(retained_args "--retain" "@${retained_loader_list}")
+ endif()
+
+ add_custom_command(
+ OUTPUT ${qmlcache_loader_file}
+ DEPENDS ${qmlcache_loader_list}
+ ${QT_TOOL_PATH_SETUP_COMMAND}
+ COMMAND
+ @QT_CMAKE_EXPORT_NAMESPACE@::qmlcachegen
+ ${retained_args}
+ --resource-name "${resource_name_arg}"
+ -o ${qmlcache_loader_file}
+ "@${qmlcache_loader_list}"
+ )
+
+ __qt_propagate_generated_resource(${target}
+ ${resource_name}
+ ${qmlcache_loader_file}
+ output_target)
+
+ set(${arg_OUTPUT_GENERATED_TARGET} "${output_target}" PARENT_SCOPE)
+
+ if (resource_files)
+ set(resource_name ${chained_resource_name})
+ endif()
+
+ # The generated qmlcache_loader source file uses private headers of Qml, so make sure
+ # if the object library was created, it depends on the Qml target. If there's no target,
+ # that means the target is a shared library and the sources are directly added to the target
+ # via target_sources, so add dependency in that case as well.
+ set(chosen_target "target") # shared library case
+ if(output_target)
+ set(chosen_target "output_target") # static library case.
+ endif()
+ target_link_libraries(${${chosen_target}} PRIVATE @QT_CMAKE_EXPORT_NAMESPACE@::Qml)
+ else()
+ set(resource_files ${arg_FILES})
+ endif()
+
+ set(${arg_OUTPUT_REMAINING_RESOURCES} ${resource_files} PARENT_SCOPE)
+ set(${arg_OUTPUT_RESOURCE_NAME} ${resource_name} PARENT_SCOPE)
+endfunction()
+
+#
+# Process resources via file path instead of QRC files. Behind the
+# scnenes, it will generate a qrc file and apply post processing steps
+# when applicable. (e.g.: QtQuickCompiler)
+#
+# The QRC Prefix is set via the PREFIX parameter.
+#
+# Alias settings for files need to be set via the QT_RESOURCE_ALIAS property
+# via the set_soure_files_properties() command.
+#
+# When using this command with static libraries, one or more special targets
+# will be generated. Should you wish to perform additional processing on these
+# targets pass a value to the OUTPUT_TARGETS parameter.
+#
+function(QT@PROJECT_VERSION_MAJOR@_PROCESS_RESOURCE target resourceName)
+
+ cmake_parse_arguments(rcc "" "PREFIX;LANG;BASE;OUTPUT_TARGETS" "FILES;OPTIONS" ${ARGN})
+
+ string(REPLACE "/" "_" resourceName ${resourceName})
+ string(REPLACE "." "_" resourceName ${resourceName})
+
+ set(output_targets "")
+ # Apply base to all files
+ if (rcc_BASE)
+ foreach(file IN LISTS rcc_FILES)
+ set(resource_file "${rcc_BASE}/${file}")
+ __qt_get_relative_resource_path_for_file(alias ${resource_file})
+ # Handle case where resources were generated from a directory
+ # different than the one where the main .pro file resides.
+ # Unless otherwise specified, we should use the original file path
+ # as alias.
+ if (alias STREQUAL resource_file)
+ set_source_files_properties(${resource_file} PROPERTIES QT_RESOURCE_ALIAS ${file})
+ endif()
+ file(TO_CMAKE_PATH ${resource_file} resource_file)
+ list(APPEND resource_files ${resource_file})
+ endforeach()
+ else()
+ set(resource_files ${rcc_FILES})
+ endif()
+
+ if(NOT rcc_PREFIX)
+ get_target_property(rcc_PREFIX ${target} QT_RESOURCE_PREFIX)
+ if (NOT rcc_PREFIX)
+ message(FATAL_ERROR "QT@PROJECT_VERSION_MAJOR@_PROCESS_RESOURCE() was called without a PREFIX and the target does not provide QT_RESOURCE_PREFIX. Please either add a PREFIX or make the target ${target} provide a default.")
+ endif()
+ endif()
+
+ # Apply quick compiler pass
+ __qt_quick_compiler_process_resources(${target} ${resourceName}
+ FILES ${resource_files}
+ PREFIX ${rcc_PREFIX}
+ OUTPUT_REMAINING_RESOURCES resources
+ OUTPUT_RESOURCE_NAME newResourceName
+ OUTPUT_GENERATED_TARGET output_target_quick
+ )
+
+ if (NOT resources)
+ if (rcc_OUTPUT_TARGETS)
+ set(${rcc_OUTPUT_TARGETS} "${output_target_quick}" PARENT_SCOPE)
+ endif()
+ return()
+ endif()
+ list(APPEND output_targets ${output_target_quick})
+ set(generatedResourceFile "${CMAKE_CURRENT_BINARY_DIR}/.rcc/generated_${newResourceName}.qrc")
+ set(generatedSourceCode "${CMAKE_CURRENT_BINARY_DIR}/.rcc/qrc_${newResourceName}.cpp")
+
+ # Generate .qrc file:
+
+ # <RCC><qresource ...>
+ set(qrcContents "<RCC>\n <qresource")
+ if (rcc_PREFIX)
+ string(APPEND qrcContents " prefix=\"${rcc_PREFIX}\"")
+ endif()
+ if (rcc_LANG)
+ string(APPEND qrcContents " lang=\"${rcc_LANG}\"")
+ endif()
+ string(APPEND qrcContents ">\n")
+
+ set(resource_dependencies)
+ foreach(file IN LISTS resources)
+ __qt_get_relative_resource_path_for_file(file_resource_path ${file})
+
+ if (NOT IS_ABSOLUTE ${file})
+ set(file "${CMAKE_CURRENT_SOURCE_DIR}/${file}")
+ endif()
+
+ ### FIXME: escape file paths to be XML conform
+ # <file ...>...</file>
+ string(APPEND qrcContents " <file alias=\"${file_resource_path}\">")
+ string(APPEND qrcContents "${file}</file>\n")
+ list(APPEND files "${file}")
+
+ get_source_file_property(target_dependency ${file} QT_RESOURCE_TARGET_DEPENDENCY)
+ if (NOT target_dependency)
+ list(APPEND resource_dependencies ${file})
+ else()
+ if (NOT TARGET ${target_dependency})
+ message(FATAL_ERROR "Target dependency on resource file ${file} is not a cmake target.")
+ endif()
+ list(APPEND resource_dependencies ${target_dependency})
+ endif()
+ endforeach()
+
+ # </qresource></RCC>
+ string(APPEND qrcContents " </qresource>\n</RCC>\n")
+
+ file(GENERATE OUTPUT "${generatedResourceFile}" CONTENT "${qrcContents}")
+
+ set(rccArgs --name "${newResourceName}"
+ --output "${generatedSourceCode}" "${generatedResourceFile}")
+ if(rcc_OPTIONS)
+ list(APPEND rccArgs ${rcc_OPTIONS})
+ endif()
+
+ # Process .qrc file:
+ add_custom_command(OUTPUT "${generatedSourceCode}"
+ COMMAND "@QT_CMAKE_EXPORT_NAMESPACE@::rcc"
+ ARGS ${rccArgs}
+ DEPENDS ${resource_dependencies} ${generatedResourceFile}
+ COMMENT "RCC ${newResourceName}"
+ VERBATIM)
+
+ get_target_property(type "${target}" TYPE)
+ # Only do this if newResourceName is the same as resourceName, since
+ # the resource will be chainloaded by the qt quickcompiler
+ # qml cache loader
+ if(newResourceName STREQUAL resourceName)
+ __qt_propagate_generated_resource(${target} ${resourceName} "${generatedSourceCode}" output_target)
+ list(APPEND output_targets ${output_target})
+ else()
+ target_sources(${target} PRIVATE "${generatedSourceCode}")
+ endif()
+ if (rcc_OUTPUT_TARGETS)
+ set(${rcc_OUTPUT_TARGETS} "${output_targets}" PARENT_SCOPE)
+ endif()
+endfunction()
diff --git a/cmake/QtSetup.cmake b/cmake/QtSetup.cmake
new file mode 100644
index 0000000000..65bd5b9a21
--- /dev/null
+++ b/cmake/QtSetup.cmake
@@ -0,0 +1,164 @@
+## Set a default build type if none was specified
+
+# Set the QT_IS_BUILDING_QT variable so we can verify whether we are building
+# Qt from source
+set(QT_BUILDING_QT TRUE CACHE
+ TYPE STRING "When this is present and set to true, it signals that we are building Qt from source.")
+
+set(_default_build_type "Release")
+if(EXISTS "${CMAKE_SOURCE_DIR}/.git")
+ set(_default_build_type "Debug")
+endif()
+
+if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
+ message(STATUS "Setting build type to '${_default_build_type}' as none was specified.")
+ set(CMAKE_BUILD_TYPE "${_default_build_type}" CACHE STRING "Choose the type of build." FORCE)
+ set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug" "Release" "MinSizeRel" "RelWithDebInfo") # Set the possible values of build type for cmake-gui
+endif()
+
+# Appends a 'debug postfix' to library targets (not executables)
+# e.g. lib/libQt6DBus_debug.5.12.0.dylib
+if(WIN32)
+ set(CMAKE_DEBUG_POSTFIX "d")
+elseif(APPLE)
+ set(CMAKE_DEBUG_POSTFIX "_debug")
+endif()
+
+## Position independent code:
+set(CMAKE_POSITION_INDEPENDENT_CODE ON)
+
+# Do not relink dependent libraries when no header has changed:
+set(CMAKE_LINK_DEPENDS_NO_SHARED ON)
+
+# Default to hidden visibility for symbols:
+set(CMAKE_C_VISIBILITY_PRESET hidden)
+set(CMAKE_CXX_VISIBILITY_PRESET hidden)
+set(CMAKE_VISIBILITY_INLINES_HIDDEN 1)
+
+# Detect non-prefix builds, either when the install prefix is set to the binary dir
+# or when enabling developer builds and no prefix is specified.
+# This detection only happens when building qtbase, and later is propagated via the generated
+# QtBuildInternalsExtra.cmake file.
+if (PROJECT_NAME STREQUAL "QtBase" AND NOT QT_BUILD_STANDALONE_TESTS)
+ if((CMAKE_INSTALL_PREFIX STREQUAL CMAKE_BINARY_DIR) OR
+ (CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT AND FEATURE_developer_build))
+
+ set(__qt_will_install_value OFF)
+ # Handle non-prefix builds by setting the CMake install prefix to point to qtbase's build
+ # dir.
+ # While building another repo (like qtsvg), the CMAKE_INSTALL_PREFIX or CMAKE_PREFIX_PATH
+ # (either work) should be set on the command line to point to the qtbase build dir.
+ set(CMAKE_INSTALL_PREFIX ${CMAKE_BINARY_DIR} CACHE PATH
+ "Install path prefix, prepended onto install directories." FORCE)
+ else()
+ set(__qt_will_install_value ON)
+ endif()
+ set(QT_WILL_INSTALL ${__qt_will_install_value} CACHE BOOL
+ "Boolean indicating if doing a Qt prefix build (vs non-prefix build)." FORCE)
+ unset(__qt_will_install_value)
+endif()
+
+# Specify the QT_SOURCE_TREE only when building qtbase. Needed by some tests when the tests are
+# built as part of the project, and not standalone. For standalone tests, the value is set in
+# QtBuildInternalsExtra.cmake.
+if(PROJECT_NAME STREQUAL "QtBase")
+ set(QT_SOURCE_TREE "${QtBase_SOURCE_DIR}" CACHE PATH
+ "A path to the source tree of the previously configured QtBase project." FORCE)
+endif()
+
+if(FEATURE_developer_build)
+ if(DEFINED QT_CMAKE_EXPORT_COMPILE_COMMANDS)
+ set(CMAKE_EXPORT_COMPILE_COMMANDS ${QT_CMAKE_EXPORT_COMPILE_COMMANDS})
+ else()
+ set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
+ endif()
+ set(QT_BUILD_TESTING ON)
+ set(__build_benchmarks ON)
+
+ # Tests are not built by default with qmake for iOS and friends, and thus the overall build
+ # tends to fail. Disable them by default when targeting uikit.
+ if(APPLE_UIKIT)
+ set(QT_BUILD_TESTING OFF)
+ endif()
+
+ # Disable benchmarks for single configuration generators which do not build
+ # with release configuration.
+ if (CMAKE_BUILD_TYPE AND NOT CMAKE_BUILD_TYPE STREQUAL Release)
+ set(__build_benchmarks OFF)
+ endif()
+else()
+ set(QT_BUILD_TESTING OFF)
+ set(__build_benchmarks OFF)
+endif()
+
+## Set up testing
+option(BUILD_TESTING "Build the testing tree." ${QT_BUILD_TESTING})
+if(QT_BUILD_STANDALONE_TESTS)
+ set(QT_BUILD_TESTING ON)
+
+ # BuildInternals might have set it to OFF on initial configuration. So force it to ON when
+ # building standalone tests.
+ set(BUILD_TESTING ON CACHE BOOL "Build the testing tree." FORCE)
+
+ # Also force the tests to be built as part of the default build target.
+ set(QT_NO_MAKE_TESTS OFF CACHE BOOL
+ "Should examples be built as part of the default 'all' target." FORCE)
+endif()
+option(QT_NO_MAKE_TESTS "Should tests be built as part of the default 'all' target." OFF)
+
+include(CTest)
+enable_testing()
+
+# Set up building of examples.
+set(QT_BUILD_EXAMPLES ON)
+# Examples are not built by default with qmake for iOS and friends, and thus the overall build
+# tends to fail. Disable them by default when targeting uikit.
+if(APPLE_UIKIT)
+ set(QT_BUILD_EXAMPLES OFF)
+endif()
+
+option(BUILD_EXAMPLES "Build Qt examples" ${QT_BUILD_EXAMPLES})
+option(QT_NO_MAKE_EXAMPLES "Should examples be built as part of the default 'all' target." OFF)
+
+# Build Benchmarks
+option(QT_BUILD_BENCHMARKS "Build Qt Benchmarks" ${__build_benchmarks})
+
+## Android platform settings
+if(ANDROID)
+ include(QtPlatformAndroid)
+endif()
+
+## qt_add_module and co.:
+include(QtBuild)
+
+## Qt Feature support:
+include(QtFeature)
+
+## Compiler optimization flags:
+include(QtCompilerOptimization)
+
+## Compiler flags:
+include(QtCompilerFlags)
+
+## Set up non-prefix build:
+qt_set_up_nonprefix_build()
+
+qt_set_language_standards()
+
+## Find host tools (if non native):
+set(QT_HOST_PATH "" CACHE PATH "Installed Qt host directory path, used for cross compiling.")
+
+if (CMAKE_CROSSCOMPILING AND NOT IS_DIRECTORY ${QT_HOST_PATH})
+ message(FATAL_ERROR "You need to set QT_HOST_PATH to cross compile Qt.")
+endif()
+
+## Enable support for sanitizers:
+include(${CMAKE_CURRENT_LIST_DIR}/3rdparty/extra-cmake-modules/modules/ECMEnableSanitizers.cmake)
+
+option(QT_USE_CCACHE "Enable the use of ccache")
+if(QT_USE_CCACHE)
+ find_program(CCACHE_PROGRAM ccache)
+ set(CMAKE_C_COMPILER_LAUNCHER "${CCACHE_PROGRAM}")
+ set(CMAKE_CXX_COMPILER_LAUNCHER "${CCACHE_PROGRAM}")
+ set(CMAKE_OBJC_COMPILER_LAUNCHER "${CCACHE_PROGRAM}")
+endif()
diff --git a/cmake/QtStandaloneTestsConfig.cmake.in b/cmake/QtStandaloneTestsConfig.cmake.in
new file mode 100644
index 0000000000..3d08ae0c12
--- /dev/null
+++ b/cmake/QtStandaloneTestsConfig.cmake.in
@@ -0,0 +1,2 @@
+find_package(@INSTALL_CMAKE_NAMESPACE@ @PROJECT_VERSION@
+ REQUIRED COMPONENTS @QT_REPO_KNOWN_MODULES_STRING@)
diff --git a/cmake/QtToolsConfig.cmake.in b/cmake/QtToolsConfig.cmake.in
new file mode 100644
index 0000000000..7b2fa1de74
--- /dev/null
+++ b/cmake/QtToolsConfig.cmake.in
@@ -0,0 +1,35 @@
+@PACKAGE_INIT@
+
+get_filename_component(_qt_tools_cmake_dir "${CMAKE_CURRENT_LIST_DIR}/.." ABSOLUTE)
+
+ if (NOT @INSTALL_CMAKE_NAMESPACE@Tools_FIND_COMPONENTS)
+ set(@INSTALL_CMAKE_NAMESPACE@Tools_NOT_FOUND_MESSAGE
+ "The Qt tools package requires at least one component.")
+ set(@INSTALL_CMAKE_NAMESPACE@Tools_FOUND False)
+ return()
+ endif()
+
+foreach(module ${@INSTALL_CMAKE_NAMESPACE@Tools_FIND_COMPONENTS})
+ find_package(@INSTALL_CMAKE_NAMESPACE@${module}Tools
+ ${_@INSTALL_CMAKE_NAMESPACE@Tools_FIND_PARTS_QUIET}
+ ${_@INSTALL_CMAKE_NAMESPACE@Tools_FIND_PARTS_REQUIRED}
+ PATHS ${_qt_tools_cmake_dir} NO_DEFAULT_PATH
+ )
+ if (NOT @INSTALL_CMAKE_NAMESPACE@${module}Tools_FOUND)
+ string(CONFIGURE ${_qt5_module_location_template} _expected_module_location @ONLY)
+
+ if (@INSTALL_CMAKE_NAMESPACE@_FIND_REQUIRED_${module})
+ set(_Qt_NOTFOUND_MESSAGE
+ "${_Qt_NOTFOUND_MESSAGE}Failed to find Qt component \"${module}\" config file.")
+ elseif(NOT Qt_FIND_QUIETLY)
+ message(WARNING "Failed to find Qt component \"${module}\" config file.")
+ endif()
+
+ unset(_expected_module_location)
+ endif()
+endforeach()
+
+if (_Qt_NOTFOUND_MESSAGE)
+ set(@INSTALL_CMAKE_NAMESPACE@Tools_NOT_FOUND_MESSAGE "${_Qt_NOTFOUND_MESSAGE}")
+ set(@INSTALL_CMAKE_NAMESPACE@Tools_FOUND False)
+endif()
diff --git a/cmake/README.md b/cmake/README.md
new file mode 100644
index 0000000000..6b65f0e69a
--- /dev/null
+++ b/cmake/README.md
@@ -0,0 +1,308 @@
+# Status
+
+Initial port is on-going. Some modules of QtBase are ported, incl. some of the platform modules.
+Many libraries, tests and examples are still missing.
+
+Basic functionality is there (moc, uic, etc.), but documentation, translations, etc. are missing.
+
+NOTE: YOU NEED CMAKE 3.15 or later.
+
+# Intro
+
+The CMake update offers an opportunity to revisit some topics that came up during the last few
+years.
+
+* The Qt build system does not support building host tools during a cross-compilation run. You need
+ to build a Qt for your host machine first and then use the platform tools from that version. The
+ decision to do this was reached independent of cmake: This does save resources on build machines
+ as the host tools will only get built once.
+
+* 3rd-party dependencies are no longer built as part of Qt. zlib, libpng, etc. from src/3rdparty
+ need to be supplied from the outside to the build now. You may find apt-get/brew/etc. useful for
+ this. Otherwise you may consider using vcpkg as in the next section. The decision to remove 3rd
+ party dependencies from Qt repositories was reached independent of the decision to use cmake, we
+ just use the opportunity to implement this decision.
+
+* There is less need for bootstrapping. Only moc and rcc (plus the lesser known tracegen and
+ qfloat16-tables) are linking against the bootstrap Qt library. Everything else can link against
+ the full QtCore. This will include qmake, which is currently missing from a cmake build. This will
+ change: Qmake is supported as a build system for applications *using* Qt going forward and will
+ not go away anytime soon.
+
+* For the time being we try to keep qmake working so that we do not interfere too much with ongoing
+ development.
+
+
+# Building against VCPKG on Windows
+
+You may use vcpkg to install dependencies needed to build QtBase.
+
+ * ```git clone -b qt https://github.com/tronical/vcpkg```
+ * Run ```bootstrap-vcpkg.bat``` or ```bootstrap-vcpkg.sh```
+ * Set the ``VCPKG_DEFAULT_TRIPLET`` environment variable to ``qt-x64-windows-static`` or
+ ``qt-x86-windows-static``
+ * Set the ``VCPKG_ROOT`` environment variable to the path where you cloned vcpkg
+ * Build Qt dependencies: ``vcpkg install @qt-packages-windows.txt``
+ * When running cmake in qtbase, support for vcpkg will be picked up automatically when the
+ VCPKG_ROOT/VCPKG_DEFAULT_TRIPLET environment variable is set.
+
+# Building against homebrew on macOS
+
+You may use brew to install dependencies needed to build QtBase.
+
+ * Install homebrew:
+ ```/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"```
+ * Build Qt dependencies: ``brew install pcre2 harfbuzz freetype``
+ * Install cmake: ``brew install cmake``
+ * When running cmake in qtbase, pass ``-DCMAKE_PREFIX_PATH=/usr/local``
+
+# Building
+
+The basic way of building with cmake is as follows:
+
+```
+ cd {build directory}
+ cmake -DCMAKE_INSTALL_PREFIX=/path/where/to/install {path to source directory}
+ cmake --build .
+ cmake --install .
+```
+
+You need one build directory per Qt module. The build directory can be a sub-directory inside the
+module ``qtbase/build`` or an independent directory ``qtbase_build``. The installation prefix is
+chosen when running cmake by passing ``-DCMAKE_INSTALL_PREFIX``. To build more than one Qt module,
+make sure to pass the same install prefix.
+
+``cmake --build`` and ``cmake --install`` are simple wrappers around the basic build tool that CMake
+generated a build system for. It works with any supported build backend supported by cmake, but you
+can also use the backend build tool directly, e.g. by running ``make``.
+
+CMake has a ninja backend that works quite well and is noticeably faster than make, so you may want
+to use that:
+
+```
+ cd {build directory}
+ cmake -GNinja -DCMAKE_INSTALL_PREFIX=/path/where/to/install {path to source directory}
+ cmake --build .
+ cmake --install .
+```
+
+You can look into the generated ``build.ninja`` file if you're curious and you can also build
+targets directory such as ``ninja lib/libQt6Core.so``.
+
+Make sure to remove CMakeCache.txt if you forgot to set the CMAKE_INSTALL_PREFIX on the first
+configuration, otherwise a second re-configuration will not pick up the new install prefix.
+
+You can use ``cmake-gui {path to build directory}`` or ``ccmake {path to build directory}`` to
+configure the values of individual cmake variables or Qt features. After changing a value, you need
+to choose the *configure* step (usually several times:-/), followed by the *generate* step (to
+generate makefiles/ninja files).
+
+## Developer Build
+
+When working on Qt itself, it can be tedious to wait for the install step. In that case you want to
+use the developer build option, to get as many auto tests enabled and no longer be required to make
+install:
+
+```
+ cd {build directory}
+ cmake -GNinja -DCMAKE_INSTALL_PREFIX=/path/to/qtbase_build -DFEATURE_developer_build=ON {path to source directory}
+ cmake --build .
+ # do NOT make install
+```
+
+## Specifying configure.json features on the command line
+
+QMake defines most features in configure.json files, like -developer-build or -no-opengl.
+
+In CMake land, we currently generate configure.cmake files from the configure.json files into
+the source directory next to them using the helper script
+``path_to_qtbase_source/util/cmake/configurejson2cmake.py``. They are checked into the repository.
+If the feature in configure.json has the name "dlopen", you can specify whether to enable or disable that
+feature in CMake with a -D flag on the CMake command line. So for example -DFEATURE_dlopen=ON or
+-DFEATURE_sql_mysql=OFF. At the moment, if you change a FEATURE flag's value, you have to remove the
+CMakeCache.txt file and reconfigure with CMake. And even then you might stumble on some issues when
+reusing an existing build, because of an automoc bug in upstream CMake.
+
+## Ninja reconfiguration bug
+
+If you use the Ninja generator, there's a bug that after the first CMake configuration, if you run
+ninja, it will do the reconfiguration step again. This is quite annoying and time consuming.
+
+There is an open pull request that fixes the issue at
+https://github.com/ninja-build/ninja/pull/1527. You can build your own Ninja executable until the
+request is merged.
+
+```
+ cd {some directory}
+ git clone https://github.com/ninja-build/ninja.git
+ cd ninja && mkdir build && cd build
+ git remote add fix git@github.com:mathstuf/ninja.git && git fetch --all
+ git cherry-pick 29a565f18e01ce83ca14801f4684cd2acaf00d4c
+ ../configure.py --bootstrap
+ cp ninja /usr/local/bin/ninja
+```
+
+## Building with CCache
+
+You can pass ``-DQT_USE_CCACHE=ON`` to make the build system look for ``ccache`` in your ``PATH``
+and prepend it to all C/C++/Objective-C compiler calls. At the moment this is only supported for the
+Ninja and the Makefile generators.
+
+## Cross Compiling
+
+Compiling for a target architecture that's different than the host requires one build of Qt for the
+host. This "host build" is needed because the process of building Qt involves the compilation of
+intermediate code generator tools, that in turn are called to produce source code that needs to be
+compiled into the final libraries. These tools are built using Qt itself and they need to run on the
+machine you're building on, regardless of the architecure you are targeting.
+
+Build Qt regularly for your host system and install it into a directory of your choice using the
+``CMAKE_INSTALL_PREFIX`` variable. You are free to disable the build of tests and examples by
+passing ``-DBUILD_EXAMPLES=OFF`` and ``-DBUILD_TESTING=OFF``.
+
+With this installation of Qt in place, which contains all tools needed, we can proceed to create a
+new build of Qt that is cross-compiled to the target architecture of choice. You may proceed by
+setting up your environment. The CMake wiki has further information how to do that at
+
+<https://gitlab.kitware.com/cmake/community/wikis/doc/cmake/CrossCompiling>
+
+Yocto based device SDKs come with an environment setup script that needs to be sourced in your shell
+and takes care of setting up environment variables and a cmake alias with a toolchain file, so that
+you can call cmake as you always do.
+
+In order to make sure that Qt picks up the code generator tools from the host build, you need to
+pass an extra parameter to cmake:
+
+```
+ -DQT_HOST_PATH=/path/to/your/host_build
+```
+
+The specified path needs to point to a directory that contains an installed host build of Qt.
+
+### Cross Compiling for Android
+
+In order to cross-compile Qt to Android, you need a host build (see instructions above) and an
+Android build. In addition, it is necessary to install the Android NDK as well as vcpkg. Vcpkg is
+needed to supply third-party libraries that Qt requires but that are not part of the Android NDK.
+
+Vcpkg for Android can be set up using the following steps:
+
+ * ```git clone -b qt https://github.com/tronical/vcpkg```
+ * Run ```bootstrap-vcpkg.bat``` or ```bootstrap-vcpkg.sh```
+ * Set the ``VCPKG_DEFAULT_TRIPLET`` environment variable to one of the following values:
+ * ``arm-android`` (armeabi-v7a)
+ * ``arm64-android`` (arm64v8)
+ * ``x86-android`` (x86)
+ * ``x64-android`` (x86_64)
+ * Set the ``VCPKG_ROOT`` environment variable to the path where you cloned vcpkg
+ * Set the ``ANDROID_NDK_HOME`` environment variable to the path where you have installed the Android NDK.
+ * Set the ``ANDROID_SDK_HOME`` environment variable to the path where you have installed the Android SDK.
+ * Build Qt dependencies: ``vcpkg install @qt-packages-android.txt``
+
+When running cmake in qtbase, pass
+``-DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK_HOME/build/cmake/android.toolchain.cmake -DQT_HOST_PATH=/path/to/your/host/build -DANDROID_SDK_ROOT=$ANDROID_SDK_HOME -DCMAKE_INSTALL_PREFIX=$INSTALL_PATH``
+
+If you don't supply the configuration argument ``-DANDROID_ABI=...``, it will default to
+``armeabi-v7a``. To target other architectures, use one of the following values:
+ * arm64: ``-DANDROID_ABI=arm64-v8``
+ * x86: ``-DANDROID_ABI=x86``
+ * x86_64: ``-DANDROID_ABI=x86_64``
+
+By default we set the android API level to 21. Should you need to change this supply the following
+configuration argument to the above CMake call: ``-DANDROID_NATIVE_API_LEVEL=${API_LEVEL}``
+
+### Cross compiling for iOS
+
+In order to cross-compile Qt to iOS, you need a host macOS build.
+In addition, it is necessary to install a custom version of vcpkg. Vcpkg is
+needed to supply third-party libraries that Qt requires, but that are not part of the iOS SDK.
+
+Vcpkg for iOS can be set up using the following steps:
+
+ * ```git clone -b qt https://github.com/alcroito/vcpkg```
+ * Run ```bootstrap-vcpkg.sh```
+ * Set the ``VCPKG_DEFAULT_TRIPLET`` environment variable to one of the following values:
+ * ``x64-ios`` (simulator x86_64)
+ * ``x86-ios`` (simulator i386)
+ * ``arm64-ios`` (device arm64)
+ * ``arm-ios`` (device armv7)
+ * ``fat-ios`` (simulator_and_device x86_64 and arm64* - special considedrations)
+ * Set the ``VCPKG_ROOT`` environment variable to the path where you cloned vcpkg
+ * Build Qt dependencies: ``vcpkg install @qt-packages-ios.txt``
+
+When running cmake in qtbase, pass
+``-DCMAKE_SYSTEM_NAME=iOS -DQT_HOST_PATH=/path/to/your/host/build -DCMAKE_INSTALL_PREFIX=$INSTALL_PATH``
+
+If you don't supply the configuration argument ``-DQT_UIKIT_SDK=...``, it will default to
+``iphonesimulator``. To target another SDK / device type, use one of the following values:
+ * iphonesimulator: ``-DQT_UIKIT_SDK=iphonesimulator``
+ * iphoneos: ``-DQT_UIKIT_SDK=iphoneos``
+ * simulator_and_device: ``-DQT_FORCE_SIMULATOR_AND_DEVICE=ON -DQT_UIKIT_SDK=``
+
+Depending on what value you pass to ``-DQT_UIKIT_SDK=`` a list of target architectures is chosen
+by default:
+ * iphonesimulator: ``x86_64``
+ * iphoneos: ``arm64``
+ * simulator_and_device: ``arm64;x86_64``
+
+You can try choosing a different list of architectures by passing
+``-DCMAKE_OSX_ARCHITECTURES=x86_64;i386``.
+Note that if you choose different architectures compared to the default ones, the build might fail.
+Only do it if you know what you are doing.
+
+#### simulator_and_device special considerations
+To do a simulator_and_device build, a custom version of CMake is required in addition to the vcpkg
+fork. The merge request can be found here:
+https://gitlab.kitware.com/cmake/cmake/merge_requests/3617
+
+After you build your own copy of CMake using this merge request, you need to use it for both
+vcpkg and Qt.
+
+Note that vcpkg prefers its own version of CMake when building packages.
+Make sure to put your custom built CMake in PATH, and force vcpkg to use this CMake by running
+``export VCPKG_FORCE_SYSTEM_BINARIES=1`` in your shell.
+
+# Debugging CMake files
+
+CMake allows specifying the ``--trace`` and ``--trace-expand`` options, which work like
+``qmake -d -d``: As the cmake code is evaluated, the values of parameters and variables is shown.
+This can be a lot of output, so you may want to redirect it to a file.
+
+# Porting Help
+
+We have some python scripts to help with the conversion from qmake to cmake. These scripts can be
+found in ``utils/cmake``.
+
+## configurejson2cmake.py
+
+This script converts all ``configure.json`` in the Qt repository to ``configure.cmake`` files for
+use with CMake. We want to generate configure.cmake files for the foreseeable future, so if you need
+to tweak the generated configure.cmake files, please tweak the generation script instead.
+
+``configurejson2cmake.py`` is run like this: ``util/cmake/configurejson2cmake.py .`` in the
+top-level source directory of a Qt repository.
+
+
+## pro2cmake.py
+
+``pro2cmake.py`` generates a skeleton CMakeLists.txt file from a .pro-file. You will need to polish
+the resulting CMakeLists.txt file, but e.g. the list of files, etc. should be extracted for you.
+
+``pro2cmake.py`` is run like this: ``path_to_qtbase_source/util/cmake/pro2cmake.py some.pro``.
+
+
+## run_pro2cmake.py
+
+`` A small helper script to run pro2cmake.py on all .pro-files in a directory. Very useful to e.g.
+convert all the unit tests for a Qt module over to cmake;-)
+
+``run_pro2cmake.py`` is run like this: ``path_to_qtbase_source/util/cmake/run_pro2cmake.py some_dir``.
+
+
+## How to convert certain constructs
+
+| qmake | CMake |
+| ------ | ------ |
+| ``qtHaveModule(foo)`` | ``if(TARGET Qt::foo)`` |
+| ``qtConfig(foo)`` | ``if (QT_FEATURE_foo)`` |
+
diff --git a/cmake/qt.toolchain.cmake.in b/cmake/qt.toolchain.cmake.in
new file mode 100644
index 0000000000..22bfe6baec
--- /dev/null
+++ b/cmake/qt.toolchain.cmake.in
@@ -0,0 +1,20 @@
+list(APPEND CMAKE_PREFIX_PATH "@CMAKE_INSTALL_PREFIX@")
+list(APPEND CMAKE_FIND_ROOT_PATH "@CMAKE_INSTALL_PREFIX@")
+
+@init_platform@
+
+@init_qt_host_path@
+
+@init_original_toolchain_file@
+
+@init_vcpkg@
+
+if(qt_chainload_toolchain_file)
+ include("${qt_chainload_toolchain_file}")
+ unset(qt_chainload_toolchain_file)
+endif()
+
+if(QT_HOST_PATH)
+ list(APPEND CMAKE_PREFIX_PATH "${QT_HOST_PATH}")
+ list(APPEND CMAKE_FIND_ROOT_PATH "${QT_HOST_PATH}")
+endif()
diff --git a/cmake/tests/CMakeLists.txt b/cmake/tests/CMakeLists.txt
new file mode 100644
index 0000000000..6b53c9703d
--- /dev/null
+++ b/cmake/tests/CMakeLists.txt
@@ -0,0 +1,48 @@
+# These macros are inspired by ECM:
+
+# a macro for tests that have a simple format where the name matches the
+# directory and project
+
+# The following macros will produce tests that generate the build
+# system for the test project, build it and then run its tests.
+macro(add_cmake_test_generate_build_run_variant name base command)
+ string(REPLACE "." "/" src_dir "${base}")
+ string(REPLACE "." "/" build_dir "${name}")
+ string(REGEX REPLACE "[^.]*\\." "" proj "${name}")
+ add_test(NAME "cmake_${name}"
+ COMMAND ${CMAKE_CTEST_COMMAND}
+ --build-and-test
+ "${CMAKE_CURRENT_SOURCE_DIR}/${src_dir}"
+ "${CMAKE_CURRENT_BINARY_DIR}/${build_dir}"
+ --build-two-config
+ --build-generator ${CMAKE_GENERATOR}
+ --build-makeprogram ${CMAKE_MAKE_PROGRAM}
+ --build-project ${proj}
+ ${${name}_EXTRA_OPTIONS}
+ --test-command ${command} ${ARGN})
+endmacro()
+
+macro(add_cmake_test_generate_build_run name)
+ add_cmake_test_generate_build_run_variant("${name}" "${name}" ${ARGN})
+endmacro()
+
+# The following macros will produce tests that just run cmake
+# to generate the build system for the test project.
+macro(add_cmake_test_generate_variant name base)
+ string(REPLACE "." "/" src_dir "${base}")
+ string(REPLACE "." "/" build_dir "${name}")
+ file(MAKE_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/${build_dir}")
+ add_test(NAME "cmake_${name}"
+ COMMAND "${CMAKE_COMMAND}" "-G${CMAKE_GENERATOR}"
+ "-DCMAKE_MAKE_PROGRAM=${CMAKE_MAKE_PROGRAM}"
+ ${${name}_EXTRA_OPTIONS}
+ "${CMAKE_CURRENT_SOURCE_DIR}/${src_dir}"
+ WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/${build_dir}")
+endmacro()
+
+macro(add_cmake_test_generate name)
+ add_cmake_test_generate_variant("${name}" "${name}")
+endmacro()
+
+add_cmake_test_generate(features)
+add_cmake_test_generate(qt_make_output_file)
diff --git a/cmake/tests/empty.cpp b/cmake/tests/empty.cpp
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/cmake/tests/empty.cpp
diff --git a/cmake/tests/features/CMakeLists.txt b/cmake/tests/features/CMakeLists.txt
new file mode 100644
index 0000000000..0fff2b8be9
--- /dev/null
+++ b/cmake/tests/features/CMakeLists.txt
@@ -0,0 +1,42 @@
+cmake_minimum_required(VERSION 3.12.0)
+
+project(FeaturesTest
+ VERSION 1.0.0
+ DESCRIPTION "QtFeature test"
+ HOMEPAGE_URL "https://qt.io/"
+ LANGUAGES CXX C
+)
+
+## Add some paths to check for cmake modules:
+list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/../../;${CMAKE_CURRENT_SOURCE_DIR}/../../3rdparty/extra-cmake-modules/find-modules;${CMAKE_CURRENT_SOURCE_DIR}/../../3rdparty/kwin")
+
+## Qt specific setup common for all modules:
+include(QtSetup)
+
+## Library to hold global features:
+add_library(GlobalConfig INTERFACE)
+
+qt_feature_module_begin(LIBRARY GlobalConfig
+ PUBLIC_FILE src/corelib/global/qconfig.h
+ PRIVATE_FILE src/corelib/global/qconfig_p.h
+)
+include("${CMAKE_CURRENT_SOURCE_DIR}/configure.cmake")
+qt_feature_module_end(GlobalConfig)
+
+assert(QT_FEATURE_top_a STREQUAL "ON")
+assert(QT_FEATURE_top_b STREQUAL "OFF")
+assert(QT_FEATURE_top_enabled STREQUAL "ON")
+assert(QT_FEATURE_top_disabled STREQUAL "OFF")
+assert(QT_FEATURE_top_disabled_enabled STREQUAL "OFF")
+assert(QT_FEATURE_top_not_emitted STREQUAL "OFF")
+
+## Enable feature summary at the end of the configure run:
+include(FeatureSummary)
+
+add_subdirectory(src)
+
+## Delayed actions on some of the Qt targets:
+include(QtPostProcess)
+
+## Print a feature summary:
+feature_summary(WHAT PACKAGES_FOUND PACKAGES_NOT_FOUND FATAL_ON_MISSING_REQUIRED_PACKAGES)
diff --git a/cmake/tests/features/configure.cmake b/cmake/tests/features/configure.cmake
new file mode 100644
index 0000000000..ace2b62450
--- /dev/null
+++ b/cmake/tests/features/configure.cmake
@@ -0,0 +1,35 @@
+#### Features
+
+# This belongs into gui, but the license check needs it here already.
+qt_feature("top_a" PRIVATE
+ LABEL "top_a"
+ CONDITION ON
+)
+qt_feature("top_b" PUBLIC PRIVATE
+ LABEL "top_b"
+ AUTODETECT OFF
+)
+qt_feature_definition("top_a" "top_defa")
+
+qt_feature("top_enabled" PRIVATE
+ LABEL "top_enabled"
+ ENABLE ON
+)
+
+qt_feature("top_disabled" PRIVATE
+ LABEL "top_enabled"
+ DISABLE ON
+)
+
+qt_feature("top_disabled_enabled" PRIVATE
+ LABEL "top_enabled_enabled"
+ DISABLE ON
+ ENABLE ON
+)
+
+qt_feature("top_not_emitted" PRIVATE
+ LABEL "top_not_emitted"
+ EMIT_IF OFF
+)
+
+qt_extra_definition("top_extra" "PUBLIC_FOO" PUBLIC)
diff --git a/cmake/tests/features/src/CMakeLists.txt b/cmake/tests/features/src/CMakeLists.txt
new file mode 100644
index 0000000000..bfb02be07d
--- /dev/null
+++ b/cmake/tests/features/src/CMakeLists.txt
@@ -0,0 +1,7 @@
+## Features from parent scope were inherited:
+assert(QT_FEATURE_top_a STREQUAL "ON")
+assert(QT_FEATURE_top_b STREQUAL "OFF")
+assert(QT_FEATURE_top_enabled STREQUAL "ON")
+assert(QT_FEATURE_top_disabled STREQUAL "OFF")
+assert(QT_FEATURE_top_disabled_enabled STREQUAL "OFF")
+assert(QT_FEATURE_top_not_emitted STREQUAL "OFF")
diff --git a/cmake/tests/main.cpp b/cmake/tests/main.cpp
new file mode 100644
index 0000000000..a9b8738990
--- /dev/null
+++ b/cmake/tests/main.cpp
@@ -0,0 +1 @@
+int main(int argc, char** argv) { return 0; }
diff --git a/cmake/tests/qt_make_output_file/CMakeLists.txt b/cmake/tests/qt_make_output_file/CMakeLists.txt
new file mode 100644
index 0000000000..3620909494
--- /dev/null
+++ b/cmake/tests/qt_make_output_file/CMakeLists.txt
@@ -0,0 +1,22 @@
+cmake_minimum_required(VERSION 3.12.0)
+
+project(QtMakeOutputFileTest
+ VERSION 1.0.0
+ DESCRIPTION "qt_make_output_file test"
+ HOMEPAGE_URL "https://qt.io/"
+ LANGUAGES CXX C
+)
+
+## Add some paths to check for cmake modules:
+list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/../../;${CMAKE_CURRENT_SOURCE_DIR}/../../3rdparty/extra-cmake-modules/find-modules;${CMAKE_CURRENT_SOURCE_DIR}/../../3rdparty/kwin")
+
+include(QtBuild)
+
+qt_make_output_file("foo.cpp" "" ".mapped" "/tmp/foo" "/tmp/bar" outfile)
+assert(outfile STREQUAL "/tmp/bar/foo.mapped")
+
+qt_make_output_file("../foo.cpp" "prefix_" ".cpp" "/tmp/foo" "/tmp/bar" outfile)
+assert(outfile STREQUAL "/tmp/bar/__/prefix_foo.cpp")
+
+qt_make_output_file("/tmp/bar/foo.cpp" "prefix_" ".cpp" "/tmp/foo" "/tmp/bar" outfile)
+assert(outfile STREQUAL "/tmp/bar/prefix_foo.cpp")
diff --git a/cmake/tests/test.cmake b/cmake/tests/test.cmake
new file mode 100644
index 0000000000..099f490c94
--- /dev/null
+++ b/cmake/tests/test.cmake
@@ -0,0 +1,54 @@
+# FAKE moc-ing:
+set(QT_MOCSCANNER /usr/bin/true)
+
+# Fake mocscanner run.
+# The files passed in after MOC will be reported to be in need of moc-ing,
+# but will not be built.
+# The files passed in after MOC_AND_BUILD will be reported to be in need
+# of moc-ing and should also be built by the target.
+function(fake_moc_results)
+ cmake_parse_arguments(arg "" "" "MOC;MOC_AND_BUILD" ${ARGN})
+
+ string(REPLACE ";" "\n" arg_MOC "${arg_MOC}")
+ string(REPLACE ";" "\n" arg_MOC_AND_BUILD "${arg_MOC_AND_BUILD}")
+
+ file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/moc_files_included.txt" "${arg_MOC}")
+ file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/moc_files_to_build.txt" "${arg_MOC_AND_BUILD}")
+endfunction()
+
+# Test whether a target has a file listed in its sources.
+# Tests with the BUILD flag set will require this file to be built,
+# while those without will require the file to not be built by
+# the target.
+function(test_source_file target file)
+ cmake_parse_arguments(arg "BUILD" "" "" ${ARGN})
+
+ get_target_property(sources "${target}" SOURCES)
+ list(FIND sources "${file}" source_pos)
+ assert(NOT source_pos STREQUAL "-1")
+
+ get_source_file_property(prop "${file}" HEADER_FILE_ONLY)
+ if (arg_BUILD)
+ assert(NOT prop)
+ else()
+ assert(prop)
+ endif()
+endfunction()
+
+# Test whether or not a target uses a header path
+# The test passes when the path is in the list of include directories.
+# Passing 'UNKNOWN' to this function reverses the test result.
+function(test_include_directory target path)
+ cmake_parse_arguments(arg "UNKNOWN" "" "" ${ARGN})
+ get_target_property(includes "${target}" INCLUDE_DIRECTORIES)
+ list(FIND includes "${path}" include_pos)
+ if(arg_UNKNOWN)
+ assert(include_pos STREQUAL "-1")
+ else()
+ assert(NOT include_pos STREQUAL "-1")
+ endif()
+endfunction()
+
+# Add Core and Qt::Core libraries:
+add_library(Core SHARED "${CMAKE_CURRENT_LIST_DIR}/empty.cpp")
+add_library(Qt::Core ALIAS Core)
diff --git a/coin/instructions/call_cmake.yaml b/coin/instructions/call_cmake.yaml
new file mode 100644
index 0000000000..06a8980099
--- /dev/null
+++ b/coin/instructions/call_cmake.yaml
@@ -0,0 +1,23 @@
+type: Group
+instructions:
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} {{.InstallDir}}\\bin\\qt-cmake {{.Env.COIN_CMAKE_ARGS}}"
+ executeCommandArgumentSplitingBehavior: SplitAfterVariableSubstitution
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to call cmake. Contact Liang then.
+ enable_if:
+ condition: property
+ property: host.os
+ equals_value: Windows
+ - type: ExecuteCommand
+ command: "{{.InstallDir}}/bin/qt-cmake {{.Env.COIN_CMAKE_ARGS}}"
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to call cmake. Contact Liang then.
+ disable_if:
+ condition: property
+ property: host.os
+ equals_value: Windows
diff --git a/coin/instructions/cmake_build_and_upload_test_artifacts.yaml b/coin/instructions/cmake_build_and_upload_test_artifacts.yaml
new file mode 100644
index 0000000000..59a2f09f0d
--- /dev/null
+++ b/coin/instructions/cmake_build_and_upload_test_artifacts.yaml
@@ -0,0 +1,29 @@
+type: Group
+instructions:
+ - type: ChangeDirectory
+ directory: "{{.SourceDir}}"
+ - type: MakeDirectory
+ directory: "standalone_tests"
+ - type: SetBuildDirectory
+ directory: "{{.SourceDir}}/standalone_tests"
+ - type: ChangeDirectory
+ directory: "{{.BuildDir}}"
+ - type: EnvironmentVariable
+ variableName: COIN_CMAKE_ARGS
+ variableValue: "-DQT_BUILD_STANDALONE_TESTS=ON -S {{.SourceDir}} -B ."
+ - !include "{{qt/qtbase}}/call_cmake.yaml"
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake --build . --parallel"
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to build sources. In the current state bug can be everywhere. Contact Liang first.
+ - type: UploadTestArtifact
+ transferType: UploadModuleTestsArtifact
+ archiveDirectory: "{{.BuildDir}}"
+ maxTimeInSeconds: 1200
+ maxTimeBetweenOutput: 1200
+disable_if:
+ condition: property
+ property: configureArgs
+ contains_value: "-DBUILD_SHARED_LIBS=OFF"
diff --git a/coin/instructions/cmake_cross_compilation.yaml b/coin/instructions/cmake_cross_compilation.yaml
new file mode 100644
index 0000000000..2037a4d331
--- /dev/null
+++ b/coin/instructions/cmake_cross_compilation.yaml
@@ -0,0 +1,58 @@
+type: Group
+instructions:
+ - type: MakeDirectory
+ directory: .git
+ - type: MakeDirectory
+ directory: build
+ - type: ChangeDirectory
+ directory: "{{.BuildDir}}/build"
+ - type: MakeDirectory
+ directory: host
+ - type: MakeDirectory
+ directory: target
+ - type: SetBuildDirectory
+ directory: "{{.SourceDir}}/build/host"
+ - type: ChangeDirectory
+ directory: "{{.BuildDir}}"
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake {{.Env.CONFIGURE_ARGS}} -DCMAKE_INSTALL_PREFIX:PATH={{.InstallDir}}/host -DBUILD_TESTING=OFF {{.SourceDir}}"
+ executeCommandArgumentSplitingBehavior: SplitAfterVariableSubstitution
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to call cmake. Contact Liang then.
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake --build . --parallel"
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to build sources. In the current state bug can be everywhere. Contact Liang first.
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake --install ."
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to install package.
+ - type: SetBuildDirectory
+ directory: "{{.SourceDir}}/build/target"
+ - type: ChangeDirectory
+ directory: "{{.BuildDir}}"
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake {{.Env.TARGET_CONFIGURE_ARGS}} -DQT_HOST_PATH={{.InstallDir}}/host -DCMAKE_INSTALL_PREFIX:PATH={{.InstallDir}}/target -DBUILD_TESTING=OFF {{.SourceDir}}"
+ executeCommandArgumentSplitingBehavior: SplitAfterVariableSubstitution
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to call cmake. Contact Liang then.
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake --build . --parallel"
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to build sources. In the current state bug can be everywhere. Contact Liang first.
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake --install ."
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to install package.
diff --git a/coin/instructions/cmake_module_build_instructions.yaml b/coin/instructions/cmake_module_build_instructions.yaml
new file mode 100644
index 0000000000..8a9798a148
--- /dev/null
+++ b/coin/instructions/cmake_module_build_instructions.yaml
@@ -0,0 +1,46 @@
+type: Group
+instructions:
+ - type: MakeDirectory
+ directory: .git
+ - type: SetBuildDirectory
+ directory: "{{.SourceDir}}"
+ - type: ChangeDirectory
+ directory: "{{.BuildDir}}"
+ - type: EnvironmentVariable
+ variableName: COIN_CMAKE_ARGS
+ variableValue: "-DBUILD_TESTING=OFF {{.SourceDir}}"
+ - !include "{{qt/qtbase}}/call_cmake.yaml"
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake --build . --parallel"
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to build sources. In the current state bug can be everywhere. Contact Liang first.
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake --install ."
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to install package.
+ - type: EnvironmentVariable
+ variableName: DESTDIR
+ variableValue: "{{.InstallRoot}}"
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake --install ."
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to install package for archiving.
+ - type: SignPackage
+ enable_if:
+ condition: property
+ property: host.os
+ equals_value: Windows
+ directory: "{{.InstallRoot}}/{{.AgentWorkingDir}}"
+ maxTimeInSeconds: 1200
+ maxTimeBetweenOutput: 1200
+ - type: UploadArtifact
+ archiveDirectory: "{{.InstallRoot}}/{{.AgentWorkingDir}}"
+ transferType: UploadModuleBuildArtifact
+ maxTimeInSeconds: 1200
+ maxTimeBetweenOutput: 1200
diff --git a/coin/instructions/cmake_qtbase_build_instructions.yaml b/coin/instructions/cmake_qtbase_build_instructions.yaml
new file mode 100644
index 0000000000..5e6e6e9a5c
--- /dev/null
+++ b/coin/instructions/cmake_qtbase_build_instructions.yaml
@@ -0,0 +1,49 @@
+type: Group
+instructions:
+ - type: MakeDirectory
+ directory: .git
+ - type: SetBuildDirectory
+ directory: "{{.SourceDir}}"
+ - type: ChangeDirectory
+ directory: "{{.BuildDir}}"
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake {{.Env.CONFIGURE_ARGS}} -DCMAKE_INSTALL_PREFIX:PATH={{.InstallDir}} -DBUILD_TESTING=OFF {{.SourceDir}}"
+ executeCommandArgumentSplitingBehavior: SplitAfterVariableSubstitution
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to call cmake. Contact Liang then.
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake --build . --parallel"
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to build sources. In the current state bug can be everywhere. Contact Liang first.
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake --install ."
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to install package.
+ - type: EnvironmentVariable
+ variableName: DESTDIR
+ variableValue: "{{.InstallRoot}}"
+ - type: ExecuteCommand
+ command: "{{.Env.ENV_PREFIX}} cmake --install ."
+ maxTimeInSeconds: 6000
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to install package for archiving.
+ - type: SignPackage
+ enable_if:
+ condition: property
+ property: host.os
+ equals_value: Windows
+ directory: "{{.InstallRoot}}/{{.AgentWorkingDir}}"
+ maxTimeInSeconds: 1200
+ maxTimeBetweenOutput: 1200
+ - type: UploadArtifact
+ archiveDirectory: "{{.InstallRoot}}/{{.AgentWorkingDir}}"
+ transferType: UploadModuleBuildArtifact
+ maxTimeInSeconds: 1200
+ maxTimeBetweenOutput: 1200
diff --git a/coin/instructions/cmake_regular_test_instructions.yaml b/coin/instructions/cmake_regular_test_instructions.yaml
new file mode 100644
index 0000000000..6974b293dd
--- /dev/null
+++ b/coin/instructions/cmake_regular_test_instructions.yaml
@@ -0,0 +1,26 @@
+type: Group
+instructions:
+ - type: ChangeDirectory
+ directory: "{{.SourceDir}}"
+ - type: MakeDirectory
+ directory: "standalone_tests"
+ - type: InstallTestBinaryArchive
+ relativeStoragePath: "{{.Env.MODULE_ARTIFACTS_RELATIVE_STORAGE_PATH}}/tests.tar.gz"
+ directory: "{{.SourceDir}}/standalone_tests"
+ maxTimeInSeconds: 1200
+ maxTimeBetweenOutput: 1200
+ userMessageOnFailure: >
+ Failed to install tests archive.
+ - type: ChangeDirectory
+ directory: "{{.SourceDir}}/standalone_tests"
+ - type: ExecuteCommand
+ command: "ctest -V --rerun-failed"
+ ignoreExitCode: true
+ maxTimeInSeconds: 7200
+ maxTimeBetweenOutput: 900
+ userMessageOnFailure: >
+ Failed to run tests.
+disable_if:
+ condition: property
+ property: configureArgs
+ contains_value: "-DBUILD_SHARED_LIBS=OFF"
diff --git a/coin/instructions/prepare_building_env.yaml b/coin/instructions/prepare_building_env.yaml
new file mode 100644
index 0000000000..f862459ba3
--- /dev/null
+++ b/coin/instructions/prepare_building_env.yaml
@@ -0,0 +1,202 @@
+# Prepares environment for building Qt module. It sets all important environment variables in particular
+# configures the right compiler and cmake generator
+type: Group
+instructions:
+
+ # Set default cmake generator, it may be overwritten later
+ - type: EnvironmentVariable
+ variableName: CMAKE_GENERATOR
+ variableValue: Ninja
+
+
+ # Export ICC specific env. variables
+ - type: Group
+ instructions:
+ - type: EnvironmentVariable
+ variableName: LD_LIBRARY_PATH
+ variableValue: "{{.Env.ICC64_18_LDLP}}"
+ - type: PrependToEnvironmentVariable
+ variableName: PATH
+ variableValue: "{{.Env.ICC64_18_PATH}}"
+ enable_if:
+ condition: property
+ property: host.compiler
+ equals_value: ICC_18
+
+
+ # Set CMAKE_C[XX]_COMPILER otherwise cmake may prioritize a wrong compiler
+ - type: Group
+ instructions:
+ - type: PrependToEnvironmentVariable
+ variableName: CONFIGURE_ARGS
+ variableValue: "-DCMAKE_C_COMPILER=icc -DCMAKE_CXX_COMPILER=icpc "
+ enable_if:
+ condition: property
+ property: host.compiler
+ contains_value: ICC
+ - type: PrependToEnvironmentVariable
+ variableName: CONFIGURE_ARGS
+ variableValue: "-DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ "
+ enable_if:
+ condition: property
+ property: host.compiler
+ contains_value: GCC
+ - type: PrependToEnvironmentVariable
+ variableName: CONFIGURE_ARGS
+ variableValue: "-DCMAKE_C_COMPILER=cl.exe -DCMAKE_CXX_COMPILER=cl.exe "
+ enable_if:
+ condition: property
+ property: host.compiler
+ contains_value: MSVC
+ - type: PrependToEnvironmentVariable
+ variableName: CONFIGURE_ARGS
+ variableValue: "-DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ "
+ enable_if:
+ condition: property
+ property: host.compiler
+ contains_value: Clang
+
+
+ # Export TARGET_ARCHITECTURE and WINDOWS_SDK_VERSION for MSVC cross compilation
+ - type: Group
+ enable_if:
+ condition: property
+ property: host.os
+ equals_value: Windows
+ instructions:
+ - type: EnvironmentVariable
+ variableName: TARGET_ARCHITECTURE
+ variableValue: amd64 # TODO add something like "{{toLower .Config host.arch}}"
+ disable_if:
+ condition: property
+ property: host.arch
+ not_equals_property: target.arch
+ - type: EnvironmentVariable
+ variableName: TARGET_ARCHITECTURE
+ variableValue: amd64_x86
+ enable_if:
+ condition: and
+ conditions:
+ - condition: property
+ property: target.arch
+ equals_property: X86
+ - condition: property
+ property: host.arch
+ equals_property: X86_64
+ - type: EnvironmentVariable
+ # HACK. Overwrite TARGET_ARCHITECTURE as we do not use standard MSVC cross
+ # compilation targets here. The target architecture will be detected by Qt.
+ variableName: TARGET_ARCHITECTURE
+ variableValue: x86
+ enable_if:
+ condition: property
+ property: target.os
+ in_values: ["WINRT", "WINPHONE", "WINCE"]
+ - type: EnvironmentVariable
+ variableName: WINDOWS_SDK_VERSION
+ variableValue: "10.0.14393.0"
+ enable_if:
+ condition: property
+ property: target.os
+ equals_value: WINRT
+ - type: EnvironmentVariable
+ variableName: WINDOWS_SDK_VERSION
+ variableValue: ""
+ disable_if:
+ condition: property
+ property: host.os
+ equals_value: WINRT # TODO set windows sdk version for desktop windows as well
+
+
+ # MSVC is installed in somehow arbitrary places. To reduce amount of combinations we need to make a variable.
+ # This seems inverted, but on 64 bit hosts VS is installed into the x86 path, otherwise the regular one
+ # TODO cleanup, that step could be removed if we have same installation paths or we read the path from registry
+ # or we use compiler specific generator (probably superior solution as it allows to get rid of ENV_PREFIX).
+ - type: Group
+ enable_if:
+ condition: property
+ property: host.os
+ equals_value: Windows
+ instructions:
+ # Try to pick one of many coexistent MSVC installation to use
+ # TODO cleanup, that could be much simpler if all tools are installed to similar paths, so it would
+ # be enough to substitute compiler name.
+ - type: EnvironmentVariable
+ variableName: VC_SCRIPT
+ variableValue: "%VS90COMNTOOLS%\\vsvars32.bat"
+ enable_if:
+ condition: property
+ property: host.compiler
+ equals_value: MSVC2008
+ - type: EnvironmentVariable
+ variableName: VC_SCRIPT
+ variableValue: "%VS100COMNTOOLS%\\vsvars32.bat"
+ enable_if:
+ condition: property
+ property: host.compiler
+ equals_value: MSVC2010
+ - type: EnvironmentVariable
+ variableName: VC_SCRIPT
+ variableValue: "%ProgramFiles(x86)%\\Microsoft Visual Studio 11.0\\VC\\vcvarsall.bat"
+ enable_if:
+ condition: property
+ property: host.compiler
+ equals_value: MSVC2012
+ - type: EnvironmentVariable
+ variableName: VC_SCRIPT
+ variableValue: "%ProgramFiles(x86)%\\Microsoft Visual Studio 12.0\\VC\\vcvarsall.bat"
+ enable_if:
+ condition: property
+ property: host.compiler
+ equals_value: MSVC2013
+ - type: EnvironmentVariable
+ variableName: VC_SCRIPT
+ variableValue: "%ProgramFiles(x86)%\\Microsoft Visual Studio 14.0\\VC\\vcvarsall.bat"
+ enable_if:
+ condition: property
+ property: host.compiler
+ equals_value: MSVC2015
+ - type: EnvironmentVariable
+ variableName: VC_SCRIPT
+ variableValue: "%ProgramFiles(x86)%\\Microsoft Visual Studio\\2017\\Professional\\VC\\Auxiliary\\Build\\vcvarsall.bat"
+ enable_if:
+ condition: property
+ property: host.compiler
+ equals_value: MSVC2017
+ - type: EnvironmentVariable
+ variableName: VC_SCRIPT
+ variableValue: "%ProgramFiles(x86)%\\Microsoft Visual Studio\\2019\\Professional\\VC\\Auxiliary\\Build\\vcvarsall.bat"
+ enable_if:
+ condition: property
+ property: host.compiler
+ equals_value: MSVC2019
+
+
+ # With MSVC we need setup the environment before every subprocess call, the group below creates a script that
+ # does it. It is enough to prepand it to every call (it is safe to add it even on other OSes)
+ - type: Group
+ instructions:
+ - type: WriteFile
+ fileContents: "call \"{{.Env.VC_SCRIPT}}\" {{.Env.TARGET_ARCHITECTURE}} {{.Env.WINDOWS_SDK_VERSION}}\r\ncmd /c %*"
+ filename: c:\\users\\qt\\prefix.bat
+ fileMode: 420
+ maxTimeInSeconds: 20
+ maxTimeBetweenOutput: 20
+ enable_if:
+ condition: property
+ property: host.os
+ equals_value: Windows
+ - type: EnvironmentVariable
+ variableName: ENV_PREFIX
+ variableValue: "c:\\users\\qt\\prefix.bat"
+ enable_if:
+ condition: property
+ property: host.os
+ equals_value: Windows
+ - type: EnvironmentVariable
+ variableName: ENV_PREFIX
+ variableValue: ""
+ disable_if:
+ condition: property
+ property: host.os
+ equals_value: Windows
diff --git a/coin/module_config.yaml b/coin/module_config.yaml
new file mode 100644
index 0000000000..ab615583a5
--- /dev/null
+++ b/coin/module_config.yaml
@@ -0,0 +1,40 @@
+version: 2
+accept_configuration:
+ condition: property
+ property: features
+ not_contains_value: Disable
+
+instructions:
+ Build:
+ - !include "{{qt/qtbase}}/prepare_building_env.yaml"
+ - type: Group
+ instructions:
+ - !include "{{qt/qtbase}}/cmake_qtbase_build_instructions.yaml"
+ - !include "{{qt/qtbase}}/cmake_build_and_upload_test_artifacts.yaml"
+ enable_if:
+ condition: property
+ property: host.os
+ equals_property: target.os
+ - type: Group
+ instructions:
+ - !include "{{qt/qtbase}}/cmake_cross_compilation.yaml"
+ disable_if:
+ condition: property
+ property: host.os
+ equals_property: target.os
+
+ Test:
+ - type: Group
+ instructions:
+ - !include "{{qt/qtbase}}/cmake_regular_test_instructions.yaml"
+ enable_if:
+ condition: property
+ property: host.os
+ equals_property: target.os
+ - type: EnvironmentVariable
+ variableName: Dummy
+ variableValue: dummy
+ disable_if:
+ condition: property
+ property: host.os
+ equals_property: target.os
diff --git a/config.tests/arch/CMakeLists.txt b/config.tests/arch/CMakeLists.txt
new file mode 100644
index 0000000000..c0873a984f
--- /dev/null
+++ b/config.tests/arch/CMakeLists.txt
@@ -0,0 +1,6 @@
+cmake_minimum_required(VERSION 3.15.0)
+project(arch LANGUAGES CXX)
+
+add_executable(architecture_test)
+set_property(TARGET architecture_test PROPERTY MACOSX_BUNDLE FALSE)
+target_sources(architecture_test PRIVATE arch.cpp)
diff --git a/config.tests/x86_simd/CMakeLists.txt b/config.tests/x86_simd/CMakeLists.txt
new file mode 100644
index 0000000000..b624b7bc95
--- /dev/null
+++ b/config.tests/x86_simd/CMakeLists.txt
@@ -0,0 +1,23 @@
+cmake_minimum_required(VERSION 3.14.0)
+project(x86_simd LANGUAGES CXX)
+
+include(../../cmake/QtPlatformSupport.cmake)
+include(../../cmake/QtCompilerOptimization.cmake)
+
+# FIXME: Make the this project handle a list of SIMD entries.
+# FIXME: Make this project handle appending of the cflags (similar to the qmake project).
+# This is needed for the x86SimdAlways configure test (
+# aka we test to see if setting no SIMD (-msse2) cflags at all, will result in their implicit
+# addition by the compiler).
+string(TOUPPER "${SIMD}" upper_simd)
+
+if(NOT DEFINED "QT_CFLAGS_${upper_simd}")
+ # Don't use CMake error() because a configure error also fails the try_compile() call.
+ # Instead use a compile flag that doesn't exist to force a compiler error.
+ set(QT_CFLAGS_${upper_simd} "--qt-cflags-not-found")
+endif()
+
+add_executable("SimdTest${SIMD}")
+target_sources("SimdTest${SIMD}" PRIVATE main.cpp)
+target_compile_options("SimdTest${SIMD}" PRIVATE ${QT_CFLAGS_${upper_simd}})
+target_compile_definitions("SimdTest${SIMD}" PRIVATE QT_COMPILER_SUPPORTS_${upper_simd})
diff --git a/configure b/configure
index c0c0227b63..e6c84b9143 100755
--- a/configure
+++ b/configure
@@ -42,18 +42,27 @@ outpath=`/bin/pwd`
WHICH="which"
+PERL=
+findPerl()
+{
PERL=`$WHICH perl 2>/dev/null`
+}
# find out which awk we want to use, prefer gawk, then nawk, then regular awk
AWK=
+findAwk()
+{
for e in gawk nawk awk; do
if "$WHICH" $e >/dev/null 2>&1 && ( $e -f /dev/null /dev/null ) >/dev/null 2>&1; then
AWK=$e
break
fi
done
+}
# find a make command
+findMake()
+{
if [ -z "$MAKE" ]; then
MAKE=
for mk in gmake make; do
@@ -70,39 +79,102 @@ if [ -z "$MAKE" ]; then
# export MAKE, we need it later in the config.tests
export MAKE
fi
+}
# make sure qmake is not confused by these. recursion via Makefiles would
# be still affected, so just unsetting them here is not an option.
+checkQMakeEnv()
+{
if [ -n "$QMAKESPEC" ] || [ -n "$XQMAKESPEC" ] || \
[ -n "$QMAKEPATH" ] || [ -n "$QMAKEFEATURES" ]; then
echo >&2 "Please make sure to unset the QMAKESPEC, XQMAKESPEC, QMAKEPATH,"
echo >&2 "and QMAKEFEATURES environment variables prior to building Qt."
exit 1
fi
+}
# do this early so we don't store it in config.status
CFG_TOPLEVEL=
-relpathMangled=$relpath
outpathPrefix=
-if [ x"$1" = x"-top-level" ]; then
- CFG_TOPLEVEL=yes
- relpathMangled=`dirname "$relpath"`
- outpathPrefix=../
- shift
-else
- if [ -f ../.qmake.super ]; then
- echo >&2 "ERROR: You cannot configure qtbase separately within a top-level build."
- exit 1
+
+checkTopLevelBuild()
+{
+ relpathMangled=$relpath
+ if [ x"$1" = x"-top-level" ]; then
+ CFG_TOPLEVEL=yes
+ relpathMangled=`dirname "$relpath"`
+ outpathPrefix=../
+ else
+ if [ -f ../.qmake.super ]; then
+ echo >&2 "ERROR: You cannot configure qtbase separately within a top-level build."
+ exit 1
+ fi
fi
+}
+
+CMAKE_CMDLINE=
+getCMakeCmdLine()
+{
+PASSTHRU=
+set -f # suppress globbing in for loop
+SAVED_IFS=$IFS
+IFS='
+'
+
+if [ "$CFG_DEV" = "yes" ]; then
+ CMAKE_CMDLINE="$CMAKE_CMDLINE
+-DFEATURE_developer_build=ON"
+ CMAKE_CMDLINE="$CMAKE_CMDLINE
+-DBUILD_TESTING=ON"
+ CMAKE_CMDLINE="$CMAKE_CMDLINE
+-DBUILD_EXAMPLES=ON"
+fi
+
+if [ "$CMAKE_MAKEFILES" = "no" ]; then
+ CMAKE_CMDLINE="$CMAKE_CMDLINE
+-G Ninja"
fi
+for i in "$@"; do
+ if [ "$PASSTHRU" = "yes" ]; then
+ CMAKE_CMDLINE="$CMAKE_CMDLINE
+$i"
+ else
+ case $i in
+ --no-*)
+ VAR=`echo $i | sed 's,^--no-\(.*\),\1,'`
+ CMAKE_CMDLINE="$CMAKE_CMDLINE
+-DFEATURE_${VAR}=OFF"
+ ;;
+ -no-*)
+ VAR=`echo $i | sed 's,^-no-\(.*\),\1,'`
+ CMAKE_CMDLINE="$CMAKE_CMDLINE
+-DFEATURE_${VAR}=OFF"
+ ;;
+ --)
+ PASSTHRU=yes
+ ;;
+ *)
+ ;;
+ esac
+ fi
+done
+set +f
+IFS=$SAVED_IFS
+}
+
OPT_CMDLINE= # expanded version for the script
QMAKE_CMDLINE= # verbatim version for qmake call
+getOptAndQMakeCmdLines()
+{
set -f # suppress globbing in for loop
SAVED_IFS=$IFS
IFS='
'
for i in "$@"; do
+ if [ x"$i" = x"-top-level" ]; then
+ continue
+ fi
case $i in
-redo|--redo)
optfile=${outpathPrefix}config.opt
@@ -132,6 +204,7 @@ for i in $OPT_CMDLINE; do
done
set +f
IFS=$SAVED_IFS
+}
#-------------------------------------------------------------------------------
# utility functions
@@ -298,7 +371,8 @@ getQMakeConf()
#-------------------------------------------------------------------------------
# operating system detection
#-------------------------------------------------------------------------------
-
+detectOperatingSystem()
+{
# need that throughout the script
UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown
UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
@@ -312,11 +386,12 @@ if [ "$OSTYPE" = "msys" ]; then
relpath=`(cd "$relpath"; pwd -W)`
outpath=`pwd -W`
fi
-
+}
#-------------------------------------------------------------------------------
# Verify Xcode installation on Mac OS
#-------------------------------------------------------------------------------
-
+maybeVerifyXcode()
+{
if [ "$BUILD_ON_MAC" = "yes" ]; then
if ! /usr/bin/xcode-select --print-path >/dev/null 2>&1; then
echo >&2
@@ -339,7 +414,7 @@ if [ "$BUILD_ON_MAC" = "yes" ]; then
fi
fi
fi
-
+}
#-----------------------------------------------------------------------------
# Qt version detection
#-----------------------------------------------------------------------------
@@ -347,6 +422,8 @@ QT_VERSION=
QT_MAJOR_VERSION=
QT_MINOR_VERSION=0
QT_PATCH_VERSION=0
+detectQtVersion()
+{
eval `sed -n -e 's/^MODULE_VERSION = \(\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\).*\)$/QT_VERSION=\1\
QT_MAJOR_VERSION=\2\
QT_MINOR_VERSION=\3\
@@ -356,7 +433,7 @@ if [ -z "$QT_MAJOR_VERSION" ]; then
echo "Cannot proceed."
exit 1
fi
-
+}
#-------------------------------------------------------------------------------
# initialize variables
#-------------------------------------------------------------------------------
@@ -372,11 +449,14 @@ OPT_VERBOSE=no
OPT_HELP=
CFG_SILENT=no
CFG_DEV=no
+BUILD_WITH_CMAKE=no
+CMAKE_MAKEFILES=no
#-------------------------------------------------------------------------------
# parse command line arguments
#-------------------------------------------------------------------------------
-
+parseCommandline()
+{
# parse the arguments, setting things to "yes" or "no"
while [ "$#" -gt 0 ]; do
CURRENT_OPT="$1"
@@ -521,6 +601,13 @@ while [ "$#" -gt 0 ]; do
# need to keep this here, to ensure qmake is built silently
CFG_SILENT="$VAL"
;;
+ cmake)
+ BUILD_WITH_CMAKE=yes
+ ;;
+ cmake-makefiles)
+ BUILD_WITH_CMAKE=yes
+ CMAKE_MAKEFILES=yes
+ ;;
*)
;;
esac
@@ -530,11 +617,12 @@ while [ "$#" -gt 0 ]; do
fi
done
[ "x$ERROR" = "xyes" ] && exit 1
-
+}
#-------------------------------------------------------------------------------
# help - interactive parts of the script _after_ this section please
#-------------------------------------------------------------------------------
-
+handleHelp()
+{
if [ "$OPT_HELP" = "yes" ]; then
cat $relpath/config_help.txt
if [ -n "$CFG_TOPLEVEL" ]; then
@@ -549,12 +637,13 @@ if [ "$OPT_HELP" = "yes" ]; then
fi
exit 0
fi
-
+}
#-------------------------------------------------------------------------------
# platform detection
#-------------------------------------------------------------------------------
-
PLATFORM_NOTES=
+detectPlatform()
+{
if [ -z "$PLATFORM" ]; then
case "$UNAME_SYSTEM:$UNAME_RELEASE" in
Darwin:*)
@@ -620,11 +709,13 @@ if [ -z "$PLATFORM" ]; then
esac
fi
echo "$PLATFORM_NOTES" > "${outpathPrefix}.config.notes"
+}
#-------------------------------------------------------------------------------
# command line and environment validation
#-------------------------------------------------------------------------------
-
+validateEnv()
+{
if [ -d "$PLATFORM" ]; then
QMAKESPEC="$PLATFORM"
else
@@ -654,11 +745,12 @@ if [ '!' -d "$QMAKESPEC" ]; then
echo
exit 2
fi
-
+}
#-------------------------------------------------------------------------------
# build tree initialization
#-------------------------------------------------------------------------------
-
+initBuildTree()
+{
# is this a shadow build?
if [ "$OPT_SHADOW" = "maybe" ]; then
OPT_SHADOW=no
@@ -686,11 +778,24 @@ if [ "$OPT_SHADOW" = "yes" ]; then
mkdir -p "$outpath/mkspecs"
fi
+}
+
+# $1: input variable name (awk regexp)
+# $2: optional output variable name
+# $3: optional value transformation (sed command)
+# relies on $QMAKESPEC, $COMPILER_CONF and $mkfile being set correctly, as the latter
+# is where the resulting variable is written to
+setBootstrapVariable()
+{
+ getQMakeConf "$1" | echo ${2-$1} = `if [ -n "$3" ]; then sed "$3"; else cat; fi` >> "$mkfile"
+}
# -----------------------------------------------------------------------------
# build qmake
# -----------------------------------------------------------------------------
+buildQMake()
+{
# symlink includes
if [ -e "$relpath/.git" ]; then
if [ -z "$PERL" ]; then
@@ -702,17 +807,6 @@ if [ -e "$relpath/.git" ]; then
"$relpath/bin/syncqt.pl" -version $QT_VERSION -minimal -module QtCore "$relpath" || exit 1
fi
-
-# $1: input variable name (awk regexp)
-# $2: optional output variable name
-# $3: optional value transformation (sed command)
-# relies on $QMAKESPEC, $COMPILER_CONF and $mkfile being set correctly, as the latter
-# is where the resulting variable is written to
-setBootstrapVariable()
-{
- getQMakeConf "$1" | echo ${2-$1} = `if [ -n "$3" ]; then sed "$3"; else cat; fi` >> "$mkfile"
-}
-
# build qmake
echo "Creating qmake..."
mkdir -p "$outpath/qmake" || exit
@@ -811,11 +905,14 @@ setBootstrapVariable()
fi
echo "Done."
fi
+}
#-------------------------------------------------------------------------------
# create a qt.conf for the Qt build tree itself
#-------------------------------------------------------------------------------
+createQtConf()
+{
# Note that this file is just sufficient to boot configure, by which it is
# replaced in-place with a version which is suitable for building all of Qt.
QTCONFFILE="$outpath/bin/qt.conf"
@@ -832,11 +929,13 @@ if [ x"$relpath" != x"$outpath" ]; then
Prefix=$relpath
EOF
fi
+}
#-------------------------------------------------------------------------------
# configure and build top-level makefile
#-------------------------------------------------------------------------------
-
+createToplevelMakefile()
+{
# recreate command line for qmake
set -f
SAVED_IFS=$IFS
@@ -857,3 +956,42 @@ if [ -n "$CFG_HOST_QT_TOOLS_PATH" ]; then
else
"$outpath/bin/qmake" "$relpathMangled" -- "$@"
fi
+}
+
+runCMake()
+{
+# recreate command line for cmake
+set -f
+SAVED_IFS=$IFS
+IFS='
+'
+for i in $CMAKE_CMDLINE; do
+ set -- $* "$i"
+done
+set +f
+IFS=$SAVED_IFS
+cmake $* "$relpath"
+}
+
+parseCommandline "$@"
+handleHelp
+if [ "$BUILD_WITH_CMAKE" = "yes" ]; then
+ getCMakeCmdLine $@
+ runCMake
+else
+ findPerl
+ findAwk
+ findMake
+ checkQMakeEnv
+ checkTopLevelBuild "$@"
+ getOptAndQMakeCmdLines "$@"
+ detectOperatingSystem
+ maybeVerifyXcode
+ detectQtVersion
+ detectPlatform
+ validateEnv
+ initBuildTree
+ buildQMake
+ createQtConf
+ createToplevelMakefile
+fi
diff --git a/configure.cmake b/configure.cmake
new file mode 100644
index 0000000000..b2bdfd620a
--- /dev/null
+++ b/configure.cmake
@@ -0,0 +1,695 @@
+
+
+#### Inputs
+
+
+
+#### Libraries
+
+qt_find_package(ZLIB PROVIDED_TARGETS ZLIB::ZLIB)
+set_package_properties(ZLIB PROPERTIES TYPE REQUIRED)
+qt_find_package(ZSTD PROVIDED_TARGETS ZSTD::ZSTD)
+qt_find_package(WrapDBus1 PROVIDED_TARGETS dbus-1)
+qt_find_package(Libudev PROVIDED_TARGETS PkgConfig::Libudev)
+
+
+#### Tests
+
+# c++14
+qt_config_compile_test(cxx14
+ LABEL "C++14 support"
+ CODE
+"#if __cplusplus > 201103L
+// Compiler claims to support C++14, trust it
+#else
+# error __cplusplus must be > 201103L (the value of C++11)
+#endif
+
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+
+ /* END TEST: */
+ return 0;
+}
+"
+ CXX_STANDARD 14
+)
+
+# c++17
+qt_config_compile_test(cxx17
+ LABEL "C++17 support"
+ CODE
+"#if __cplusplus > 201402L
+// Compiler claims to support C++17, trust it
+#else
+# error __cplusplus must be > 201402L (the value for C++14)
+#endif
+#include <map> // https://bugs.llvm.org//show_bug.cgi?id=33117
+#include <variant>
+
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+std::variant<int> v(42);
+int i = std::get<int>(v);
+std::visit([](const auto &) { return 1; }, v);
+ /* END TEST: */
+ return 0;
+}
+"
+ CXX_STANDARD 17
+)
+
+# c++2a
+qt_config_compile_test(cxx2a
+ LABEL "C++2a support"
+ CODE
+"#if __cplusplus > 201703L
+// Compiler claims to support experimental C++2a, trust it
+#else
+# error __cplusplus must be > 201703L (the value for C++17)
+#endif
+
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+
+ /* END TEST: */
+ return 0;
+}
+"
+ CXX_STANDARD 20
+)
+
+# precompile_header
+qt_config_compile_test(precompile_header
+ LABEL "precompiled header support"
+ CODE
+"
+
+#ifndef HEADER_H
+#error no go
+#endif
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: qmake: ['CONFIG += precompile_header', 'PRECOMPILED_DIR = .pch', 'PRECOMPILED_HEADER = header.h']
+)
+
+# reduce_relocations
+qt_config_compile_test(reduce_relocations
+ LABEL "-Bsymbolic-functions support"
+ CODE
+"#if !(defined(__i386) || defined(__i386__) || defined(__x86_64) || defined(__x86_64__) || defined(__amd64))
+# error Symbolic function binding on this architecture may be broken, disabling it (see QTBUG-36129).
+#endif
+
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: qmake: ['TEMPLATE = lib', 'CONFIG += dll bsymbolic_functions', 'isEmpty(QMAKE_LFLAGS_BSYMBOLIC_FUNC): error("Nope")']
+)
+
+# signaling_nan
+qt_config_compile_test(signaling_nan
+ LABEL "Signaling NaN for doubles"
+ CODE
+"#include <limits>
+
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+using B = std::numeric_limits<double>;
+static_assert(B::has_signaling_NaN, \"System lacks signaling NaN\");
+ /* END TEST: */
+ return 0;
+}
+")
+
+# sse2
+qt_config_compile_test_x86simd(sse2 "SSE2 instructions")
+
+# sse3
+qt_config_compile_test_x86simd(sse3 "SSE3 instructions")
+
+# ssse3
+qt_config_compile_test_x86simd(ssse3 "SSSE3 instructions")
+
+# sse4_1
+qt_config_compile_test_x86simd(sse4_1 "SSE4.1 instructions")
+
+# sse4_2
+qt_config_compile_test_x86simd(sse4_2 "SSE4.2 instructions")
+
+# aesni
+qt_config_compile_test_x86simd(aesni "AES new instructions")
+
+# f16c
+qt_config_compile_test_x86simd(f16c "F16C instructions")
+
+# rdrnd
+qt_config_compile_test_x86simd(rdrnd "RDRAND instruction")
+
+# rdseed
+qt_config_compile_test_x86simd(rdseed "RDSEED instruction")
+
+# shani
+qt_config_compile_test_x86simd(shani "SHA new instructions")
+
+# avx
+qt_config_compile_test_x86simd(avx "AVX instructions")
+
+# avx2
+qt_config_compile_test_x86simd(avx2 "AVX2 instructions")
+
+# avx512f
+qt_config_compile_test_x86simd(avx512f "AVX512 F instructions")
+
+# avx512er
+qt_config_compile_test_x86simd(avx512er "AVX512 ER instructions")
+
+# avx512cd
+qt_config_compile_test_x86simd(avx512cd "AVX512 CD instructions")
+
+# avx512pf
+qt_config_compile_test_x86simd(avx512pf "AVX512 PF instructions")
+
+# avx512dq
+qt_config_compile_test_x86simd(avx512dq "AVX512 DQ instructions")
+
+# avx512bw
+qt_config_compile_test_x86simd(avx512bw "AVX512 BW instructions")
+
+# avx512vl
+qt_config_compile_test_x86simd(avx512vl "AVX512 VL instructions")
+
+# avx512ifma
+qt_config_compile_test_x86simd(avx512ifma "AVX512 IFMA instructions")
+
+# avx512vbmi
+qt_config_compile_test_x86simd(avx512vbmi "AVX512 VBMI instructions")
+
+# posix_fallocate
+qt_config_compile_test(posix_fallocate
+ LABEL "POSIX fallocate()"
+ CODE
+"
+#include <fcntl.h>
+#include <unistd.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+(void) posix_fallocate(0, 0, 0);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# alloca_stdlib_h
+qt_config_compile_test(alloca_stdlib_h
+ LABEL "alloca() in stdlib.h"
+ CODE
+"
+#include <stdlib.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+alloca(1);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# alloca_h
+qt_config_compile_test(alloca_h
+ LABEL "alloca() in alloca.h"
+ CODE
+"
+#include <alloca.h>
+#ifdef __QNXNTO__
+// extra include needed in QNX7 to define NULL for the alloca() macro
+# include <stddef.h>
+#endif
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+alloca(1);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# alloca_malloc_h
+qt_config_compile_test(alloca_malloc_h
+ LABEL "alloca() in malloc.h"
+ CODE
+"
+#include <malloc.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+alloca(1);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# stack_protector
+qt_config_compile_test(stack_protector
+ LABEL "stack protection"
+ CODE
+"#ifdef __QNXNTO__
+# include <sys/neutrino.h>
+# if _NTO_VERSION < 700
+# error stack-protector not used (by default) before QNX 7.0.0.
+# endif
+#endif
+
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: qmake: QMAKE_CXXFLAGS += -fstack-protector-strong
+)
+
+
+
+#### Features
+
+# This belongs into gui, but the license check needs it here already.
+qt_feature("android-style-assets" PRIVATE
+ LABEL "Android Style Assets"
+ CONDITION ANDROID
+)
+qt_feature("use_bfd_linker"
+ LABEL "bfd"
+ AUTODETECT false
+ CONDITION NOT WIN32 AND NOT INTEGRITY AND NOT WASM AND tests.use_bfd_linker OR FIXME
+ ENABLE INPUT_linker STREQUAL 'bfd'
+ DISABLE INPUT_linker STREQUAL 'gold' OR INPUT_linker STREQUAL 'lld'
+)
+qt_feature_config("use_bfd_linker" QMAKE_PRIVATE_CONFIG)
+qt_feature("use_gold_linker_alias"
+ AUTODETECT false
+ CONDITION NOT WIN32 AND NOT INTEGRITY AND NOT WASM AND tests.use_gold_linker OR FIXME
+)
+qt_feature("use_lld_linker"
+ LABEL "lld"
+ AUTODETECT false
+ CONDITION NOT WIN32 AND NOT INTEGRITY AND NOT WASM AND tests.use_lld_linker OR FIXME
+ ENABLE INPUT_linker STREQUAL 'lld'
+ DISABLE INPUT_linker STREQUAL 'bfd' OR INPUT_linker STREQUAL 'gold'
+)
+qt_feature_config("use_lld_linker" QMAKE_PRIVATE_CONFIG)
+qt_feature("developer-build"
+ LABEL "Developer build"
+ AUTODETECT OFF
+)
+qt_feature("private_tests" PRIVATE
+ LABEL "Developer build: private_tests"
+ CONDITION QT_FEATURE_developer_build
+)
+qt_feature_definition("developer-build" "QT_BUILD_INTERNAL")
+qt_feature_config("developer-build" QMAKE_PUBLIC_QT_CONFIG
+ NAME "private_tests"
+)
+qt_feature("appstore-compliant" PUBLIC
+ LABEL "App store compliance"
+ PURPOSE "Disables code that is not allowed in platform app stores"
+ AUTODETECT APPLE_UIKIT OR ANDROID OR WINRT
+)
+qt_feature("simulator_and_device" PUBLIC
+ LABEL "Build for both simulator and device"
+ CONDITION APPLE_UIKIT AND NOT QT_UIKIT_SDK
+)
+qt_feature_config("simulator_and_device" QMAKE_PUBLIC_QT_CONFIG)
+qt_feature("force_asserts" PUBLIC
+ LABEL "Force assertions"
+ AUTODETECT OFF
+)
+qt_feature("headersclean"
+ LABEL "Check for clean headers"
+ AUTODETECT QT_FEATURE_developer_build
+ CONDITION NOT WASM
+)
+qt_feature_config("headersclean" QMAKE_PRIVATE_CONFIG)
+qt_feature("framework" PUBLIC
+ LABEL "Build Apple Frameworks"
+ CONDITION APPLE AND BUILD_SHARED_LIBS
+)
+qt_feature_definition("framework" "QT_MAC_FRAMEWORK_BUILD")
+qt_feature_config("framework" QMAKE_PUBLIC_QT_CONFIG
+ NAME "qt_framework"
+)
+qt_feature_config("framework" QMAKE_PUBLIC_CONFIG
+ NAME "qt_framework"
+)
+qt_feature("largefile"
+ LABEL "Large file support"
+ CONDITION NOT ANDROID AND NOT INTEGRITY AND NOT WINRT AND NOT rtems
+)
+qt_feature_definition("largefile" "QT_LARGEFILE_SUPPORT" VALUE "64")
+qt_feature_config("largefile" QMAKE_PRIVATE_CONFIG)
+qt_feature("testcocoon"
+ LABEL "Testcocoon support"
+ AUTODETECT OFF
+)
+qt_feature_config("testcocoon" QMAKE_PUBLIC_CONFIG)
+qt_feature("coverage_trace_pc_guard"
+ LABEL "trace-pc-guard"
+ AUTODETECT OFF
+)
+qt_feature_config("coverage_trace_pc_guard" QMAKE_PUBLIC_CONFIG)
+qt_feature("coverage"
+ LABEL "Code Coverage Instrumentation"
+ CONDITION QT_FEATURE_coverage_trace_pc_guard
+)
+qt_feature_config("coverage" QMAKE_PUBLIC_CONFIG)
+qt_feature("plugin-manifests"
+ LABEL "Embed manifests in plugins"
+ AUTODETECT OFF
+ EMIT_IF WIN32
+)
+qt_feature_config("plugin-manifests" QMAKE_PUBLIC_CONFIG
+ NEGATE
+ NAME "no_plugin_manifest"
+)
+qt_feature("c++11" PUBLIC
+ LABEL "C++11"
+)
+qt_feature_config("c++11" QMAKE_PUBLIC_QT_CONFIG)
+qt_feature("c++14" PUBLIC
+ LABEL "C++14"
+ CONDITION QT_FEATURE_cxx11 AND TEST_cxx14
+)
+qt_feature_config("c++14" QMAKE_PUBLIC_QT_CONFIG)
+qt_feature("c++17" PUBLIC
+ LABEL "C++17"
+ CONDITION QT_FEATURE_cxx14 AND TEST_cxx17
+)
+qt_feature_config("c++17" QMAKE_PUBLIC_QT_CONFIG)
+qt_feature("c++1z" PUBLIC
+ LABEL "C++17"
+ CONDITION QT_FEATURE_cxx17
+)
+qt_feature_config("c++1z" QMAKE_PUBLIC_QT_CONFIG)
+qt_feature("c++2a" PUBLIC
+ LABEL "C++2a"
+ AUTODETECT OFF
+ CONDITION QT_FEATURE_cxx17 AND TEST_cxx2a
+)
+qt_feature_config("c++2a" QMAKE_PUBLIC_QT_CONFIG)
+qt_feature("reduce_exports" PRIVATE
+ LABEL "Reduce amount of exported symbols"
+ CONDITION NOT WIN32 AND CMAKE_CXX_COMPILE_OPTIONS_VISIBILITY
+)
+qt_feature_definition("reduce_exports" "QT_VISIBILITY_AVAILABLE")
+qt_feature_config("reduce_exports" QMAKE_PUBLIC_QT_CONFIG)
+qt_feature("signaling_nan" PUBLIC
+ LABEL "Signaling NaN"
+ CONDITION TEST_signaling_nan
+)
+qt_feature("sse2" PRIVATE
+ LABEL "SSE2"
+ CONDITION ( ( TEST_architecture_arch STREQUAL i386 ) OR ( TEST_architecture_arch STREQUAL x86_64 ) ) AND TEST_subarch_sse2
+)
+qt_feature_definition("sse2" "QT_COMPILER_SUPPORTS_SSE2" VALUE "1")
+qt_feature_config("sse2" QMAKE_PRIVATE_CONFIG)
+qt_feature("sse3"
+ LABEL "SSE3"
+ CONDITION QT_FEATURE_sse2 AND TEST_subarch_sse3
+)
+qt_feature_definition("sse3" "QT_COMPILER_SUPPORTS_SSE3" VALUE "1")
+qt_feature_config("sse3" QMAKE_PRIVATE_CONFIG)
+qt_feature("ssse3"
+ LABEL "SSSE3"
+ CONDITION QT_FEATURE_sse3 AND TEST_subarch_ssse3
+)
+qt_feature_definition("ssse3" "QT_COMPILER_SUPPORTS_SSSE3" VALUE "1")
+qt_feature_config("ssse3" QMAKE_PRIVATE_CONFIG)
+qt_feature("sse4_1"
+ LABEL "SSE4.1"
+ CONDITION QT_FEATURE_ssse3 AND TEST_subarch_sse4_1
+)
+qt_feature_definition("sse4_1" "QT_COMPILER_SUPPORTS_SSE4_1" VALUE "1")
+qt_feature_config("sse4_1" QMAKE_PRIVATE_CONFIG)
+qt_feature("sse4_2"
+ LABEL "SSE4.2"
+ CONDITION QT_FEATURE_sse4_1 AND TEST_subarch_sse4_2
+)
+qt_feature_definition("sse4_2" "QT_COMPILER_SUPPORTS_SSE4_2" VALUE "1")
+qt_feature_config("sse4_2" QMAKE_PRIVATE_CONFIG)
+qt_feature("avx"
+ LABEL "AVX"
+ CONDITION QT_FEATURE_sse4_2 AND TEST_subarch_avx
+)
+qt_feature_definition("avx" "QT_COMPILER_SUPPORTS_AVX" VALUE "1")
+qt_feature_config("avx" QMAKE_PRIVATE_CONFIG)
+qt_feature("f16c"
+ LABEL "F16C"
+ CONDITION QT_FEATURE_avx AND TEST_subarch_f16c
+)
+qt_feature_definition("f16c" "QT_COMPILER_SUPPORTS_F16C" VALUE "1")
+qt_feature_config("f16c" QMAKE_PRIVATE_CONFIG)
+qt_feature("avx2" PRIVATE
+ LABEL "AVX2"
+ CONDITION QT_FEATURE_avx AND TEST_subarch_avx2
+)
+qt_feature_definition("avx2" "QT_COMPILER_SUPPORTS_AVX2" VALUE "1")
+qt_feature_config("avx2" QMAKE_PRIVATE_CONFIG)
+qt_feature("avx512f"
+ LABEL "F"
+ CONDITION QT_FEATURE_avx2 AND TEST_subarch_avx512f
+)
+qt_feature_definition("avx512f" "QT_COMPILER_SUPPORTS_AVX512F" VALUE "1")
+qt_feature_config("avx512f" QMAKE_PRIVATE_CONFIG)
+qt_feature("avx512er"
+ LABEL "ER"
+ CONDITION QT_FEATURE_avx512f AND TEST_subarch_avx512er
+)
+qt_feature_definition("avx512er" "QT_COMPILER_SUPPORTS_AVX512ER" VALUE "1")
+qt_feature_config("avx512er" QMAKE_PRIVATE_CONFIG)
+qt_feature("avx512cd"
+ LABEL "CD"
+ CONDITION QT_FEATURE_avx512f AND TEST_subarch_avx512cd
+)
+qt_feature_definition("avx512cd" "QT_COMPILER_SUPPORTS_AVX512CD" VALUE "1")
+qt_feature_config("avx512cd" QMAKE_PRIVATE_CONFIG)
+qt_feature("avx512pf"
+ LABEL "PF"
+ CONDITION QT_FEATURE_avx512f AND TEST_subarch_avx512pf
+)
+qt_feature_definition("avx512pf" "QT_COMPILER_SUPPORTS_AVX512PF" VALUE "1")
+qt_feature_config("avx512pf" QMAKE_PRIVATE_CONFIG)
+qt_feature("avx512dq"
+ LABEL "DQ"
+ CONDITION QT_FEATURE_avx512f AND TEST_subarch_avx512dq
+)
+qt_feature_definition("avx512dq" "QT_COMPILER_SUPPORTS_AVX512DQ" VALUE "1")
+qt_feature_config("avx512dq" QMAKE_PRIVATE_CONFIG)
+qt_feature("avx512bw"
+ LABEL "BW"
+ CONDITION QT_FEATURE_avx512f AND TEST_subarch_avx512bw
+)
+qt_feature_definition("avx512bw" "QT_COMPILER_SUPPORTS_AVX512BW" VALUE "1")
+qt_feature_config("avx512bw" QMAKE_PRIVATE_CONFIG)
+qt_feature("avx512vl"
+ LABEL "VL"
+ CONDITION QT_FEATURE_avx512f AND TEST_subarch_avx512vl
+)
+qt_feature_definition("avx512vl" "QT_COMPILER_SUPPORTS_AVX512VL" VALUE "1")
+qt_feature_config("avx512vl" QMAKE_PRIVATE_CONFIG)
+qt_feature("avx512ifma"
+ LABEL "IFMA"
+ CONDITION QT_FEATURE_avx512f AND TEST_subarch_avx512ifma
+)
+qt_feature_definition("avx512ifma" "QT_COMPILER_SUPPORTS_AVX512IFMA" VALUE "1")
+qt_feature_config("avx512ifma" QMAKE_PRIVATE_CONFIG)
+qt_feature("avx512vbmi"
+ LABEL "VBMI"
+ CONDITION QT_FEATURE_avx512f AND TEST_subarch_avx512vbmi
+)
+qt_feature_definition("avx512vbmi" "QT_COMPILER_SUPPORTS_AVX512VBMI" VALUE "1")
+qt_feature_config("avx512vbmi" QMAKE_PRIVATE_CONFIG)
+qt_feature("aesni"
+ LABEL "AES"
+ CONDITION QT_FEATURE_sse2 AND TEST_subarch_aes
+)
+qt_feature_definition("aesni" "QT_COMPILER_SUPPORTS_AES" VALUE "1")
+qt_feature_config("aesni" QMAKE_PRIVATE_CONFIG)
+qt_feature("rdrnd"
+ LABEL "RDRAND"
+ CONDITION TEST_subarch_rdseed
+)
+qt_feature_definition("rdrnd" "QT_COMPILER_SUPPORTS_RDRND" VALUE "1")
+qt_feature_config("rdrnd" QMAKE_PRIVATE_CONFIG)
+qt_feature("rdseed"
+ LABEL "RDSEED"
+ CONDITION TEST_subarch_rdseed
+)
+qt_feature_definition("rdseed" "QT_COMPILER_SUPPORTS_RDSEED" VALUE "1")
+qt_feature_config("rdseed" QMAKE_PRIVATE_CONFIG)
+qt_feature("shani"
+ LABEL "SHA"
+ CONDITION QT_FEATURE_sse2 AND TEST_subarch_sha
+)
+qt_feature_definition("shani" "QT_COMPILER_SUPPORTS_SHA" VALUE "1")
+qt_feature_config("shani" QMAKE_PRIVATE_CONFIG)
+qt_feature("x86SimdAlways"
+ LABEL "Intrinsics without -mXXX option"
+ CONDITION ( ( TEST_architecture_arch STREQUAL i386 ) OR ( TEST_architecture_arch STREQUAL x86_64 ) ) AND ON
+)
+qt_feature_definition("x86SimdAlways" "QT_COMPILER_SUPPORTS_SIMD_ALWAYS" VALUE "1")
+qt_feature_config("x86SimdAlways" QMAKE_PRIVATE_CONFIG)
+qt_feature("mips_dsp"
+ LABEL "DSP"
+ CONDITION ( TEST_architecture_arch STREQUAL mips ) AND TEST_arch_${TEST_architecture_arch}_subarch_dsp
+)
+qt_feature_definition("mips_dsp" "QT_COMPILER_SUPPORTS_MIPS_DSP" VALUE "1")
+qt_feature_config("mips_dsp" QMAKE_PRIVATE_CONFIG)
+qt_feature("mips_dspr2"
+ LABEL "DSPr2"
+ CONDITION ( TEST_architecture_arch STREQUAL mips ) AND TEST_arch_${TEST_architecture_arch}_subarch_dspr2
+)
+qt_feature_definition("mips_dspr2" "QT_COMPILER_SUPPORTS_MIPS_DSPR2" VALUE "1")
+qt_feature_config("mips_dspr2" QMAKE_PRIVATE_CONFIG)
+qt_feature("neon"
+ LABEL "NEON"
+ CONDITION ( ( TEST_architecture_arch STREQUAL arm ) OR ( TEST_architecture_arch STREQUAL arm64 ) ) AND TEST_arch_${TEST_architecture_arch}_subarch_neon
+)
+qt_feature_definition("neon" "QT_COMPILER_SUPPORTS_NEON" VALUE "1")
+qt_feature_config("neon" QMAKE_PRIVATE_CONFIG)
+qt_feature("alloca_h" PRIVATE
+ LABEL "alloca.h"
+ CONDITION TEST_alloca_h
+)
+qt_feature("alloca_malloc_h" PRIVATE
+ LABEL "alloca() in malloc.h"
+ CONDITION NOT QT_FEATURE_alloca_h AND TEST_alloca_malloc_h
+)
+qt_feature("alloca" PRIVATE
+ LABEL "alloca()"
+ CONDITION QT_FEATURE_alloca_h OR QT_FEATURE_alloca_malloc_h OR TEST_alloca_stdlib_h
+)
+qt_feature("zstd" PRIVATE
+ LABEL "Zstandard support"
+ CONDITION ZSTD_FOUND
+)
+qt_feature("thread" PUBLIC
+ SECTION "Kernel"
+ LABEL "Thread support"
+ PURPOSE "Provides QThread and related classes."
+ AUTODETECT NOT WASM
+)
+qt_feature("future" PUBLIC
+ SECTION "Kernel"
+ LABEL "QFuture"
+ PURPOSE "Provides QFuture and related classes."
+ CONDITION QT_FEATURE_thread
+)
+qt_feature("concurrent" PUBLIC
+ SECTION "Kernel"
+ LABEL "Qt Concurrent"
+ PURPOSE "Provides a high-level multi-threading API."
+ CONDITION QT_FEATURE_future
+)
+qt_feature_definition("concurrent" "QT_NO_CONCURRENT" NEGATE VALUE "1")
+qt_feature("dbus" PUBLIC PRIVATE
+ LABEL "Qt D-Bus"
+ AUTODETECT NOT APPLE_UIKIT AND NOT ANDROID AND NOT WINRT
+ CONDITION QT_FEATURE_thread
+)
+qt_feature_definition("dbus" "QT_NO_DBUS" NEGATE VALUE "1")
+qt_feature("dbus-linked" PRIVATE
+ LABEL "Qt D-Bus directly linked to libdbus"
+ CONDITION QT_FEATURE_dbus AND DBus1_FOUND
+ ENABLE INPUT_dbus STREQUAL 'linked'
+ DISABLE INPUT_dbus STREQUAL 'runtime'
+)
+qt_feature("gui" PRIVATE
+ LABEL "Qt Gui"
+)
+qt_feature_config("gui" QMAKE_PUBLIC_QT_CONFIG
+ NEGATE)
+qt_feature("network" PRIVATE
+ LABEL "Qt Network"
+)
+qt_feature("sql" PRIVATE
+ LABEL "Qt Sql"
+ CONDITION QT_FEATURE_thread
+)
+qt_feature("testlib" PRIVATE
+ LABEL "Qt Testlib"
+)
+qt_feature("widgets" PRIVATE
+ LABEL "Qt Widgets"
+ AUTODETECT NOT APPLE_TVOS AND NOT APPLE_WATCHOS
+ CONDITION QT_FEATURE_gui
+)
+qt_feature_definition("widgets" "QT_NO_WIDGETS" NEGATE)
+qt_feature_config("widgets" QMAKE_PUBLIC_QT_CONFIG
+ NEGATE)
+qt_feature("xml" PRIVATE
+ LABEL "Qt Xml"
+)
+qt_feature("libudev" PRIVATE
+ LABEL "udev"
+ CONDITION Libudev_FOUND
+)
+qt_feature("qt_libinfix_plugins"
+ LABEL "Use QT_LIBINFIX for Plugins"
+ AUTODETECT OFF
+ ENABLE ( NOT INPUT_qt_libinfix STREQUAL '' AND INPUT_qt_libinfix_plugins STREQUAL 'yes' )
+)
+qt_feature_config("qt_libinfix_plugins" QMAKE_PRIVATE_CONFIG)
+qt_feature("compile_examples"
+ LABEL "Compile examples"
+ AUTODETECT NOT WASM
+)
+qt_feature_config("compile_examples" QMAKE_PRIVATE_CONFIG)
+qt_feature("dlopen" PRIVATE
+ LABEL "dlopen()"
+ CONDITION UNIX
+)
+qt_feature("relocatable" PRIVATE
+ LABEL "Relocatable"
+ AUTODETECT QT_FEATURE_shared
+ CONDITION QT_FEATURE_dlopen OR WIN32 OR NOT QT_FEATURE_shared
+)
+
+qt_extra_definition("QT_VERSION_STR" "\"${PROJECT_VERSION}\"" PUBLIC)
+qt_extra_definition("QT_VERSION_MAJOR" ${PROJECT_VERSION_MAJOR} PUBLIC)
+qt_extra_definition("QT_VERSION_MINOR" ${PROJECT_VERSION_MINOR} PUBLIC)
+qt_extra_definition("QT_VERSION_PATCH" ${PROJECT_VERSION_PATCH} PUBLIC)
diff --git a/configure.json b/configure.json
index 8bf9cd5c9f..762bb01623 100644
--- a/configure.json
+++ b/configure.json
@@ -1426,9 +1426,7 @@
{
"type": "warning",
"condition": "input.debug_and_release == 'yes' && !config.darwin && !config.win32",
- "message": "-debug-and-release is only supported on Darwin and Windows platforms.
-Qt can be built in release mode with separate debug information, so
--debug-and-release is no longer necessary."
+ "message": "-debug-and-release is only supported on Darwin and Windows platforms. Qt can be built in release mode with separate debug information, so -debug-and-release is no longer necessary."
},
{
"type": "error",
@@ -1461,9 +1459,7 @@ Qt can be built in release mode with separate debug information, so
{
"type": "note",
"condition": "!features.shared",
- "message": "Using static linking will disable the use of dynamically
-loaded plugins. Make sure to import all needed static plugins,
-or compile needed modules into the library."
+ "message": "Using static linking will disable the use of dynamically loaded plugins. Make sure to import all needed static plugins, or compile needed modules into the library."
},
{
"type": "note",
@@ -1473,8 +1469,7 @@ or compile needed modules into the library."
{
"type": "note",
"condition": "input.qreal == 'double' && arch.arm",
- "message": "Qt is using double for qreal on this system. This is binary-incompatible against Qt 5.1.
-Configure with '-qreal float' to create a build that is binary-compatible with 5.1."
+ "message": "Qt is using double for qreal on this system. This is binary-incompatible against Qt 5.1. Configure with '-qreal float' to create a build that is binary-compatible with 5.1."
},
{
"type": "error",
diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt
new file mode 100644
index 0000000000..f81cca7a33
--- /dev/null
+++ b/doc/CMakeLists.txt
@@ -0,0 +1,7 @@
+#
+# Copy/Install doc configuration files to the build/install directory
+#
+qt_path_join(doc_install_dir ${QT_INSTALL_DIR} ${INSTALL_DOCDIR})
+qt_copy_or_install(DIRECTORY global DESTINATION ${doc_install_dir})
+qt_copy_or_install(DIRECTORY config DESTINATION ${doc_install_dir})
+
diff --git a/doc/global/macros.qdocconf b/doc/global/macros.qdocconf
index f553cd8e14..3a525224c1 100644
--- a/doc/global/macros.qdocconf
+++ b/doc/global/macros.qdocconf
@@ -18,6 +18,7 @@ macro.nullptr = "\\c{nullptr}"
macro.QA = "\\e{Qt Assistant}"
macro.QD = "\\e{Qt Designer}"
macro.QL = "\\e{Qt Linguist}"
+macro.Q_OBJECT = "Q_OBJECT"
macro.QQV = "\\e{Qt QML Viewer}"
macro.QtVersion = "$QT_VERSION"
macro.QtVer = "$QT_VER"
diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt
new file mode 100644
index 0000000000..b473828415
--- /dev/null
+++ b/examples/CMakeLists.txt
@@ -0,0 +1,54 @@
+# special case begin
+qt_examples_build_begin()
+
+# special case end
+
+# Generated from examples.pro.
+
+add_subdirectory(corelib)
+add_subdirectory(embedded)
+add_subdirectory(qpa)
+
+if(TARGET Qt::DBus)
+ add_subdirectory(dbus)
+endif()
+
+if(TARGET Qt::Network)
+ add_subdirectory(network)
+endif()
+
+if(TARGET Qt::Test)
+ add_subdirectory(qtestlib)
+endif()
+
+if(TARGET Qt::Concurrent)
+ add_subdirectory(qtconcurrent)
+endif()
+
+if(TARGET Qt::Sql)
+ add_subdirectory(sql)
+endif()
+
+if(TARGET Qt::Widgets)
+ add_subdirectory(widgets)
+endif()
+
+if(TARGET Qt::Xml)
+ add_subdirectory(xml)
+endif()
+
+if(TARGET Qt::Gui)
+ add_subdirectory(gui)
+
+ if(QT_FEATURE_opengl)
+ add_subdirectory(opengl)
+ endif()
+
+ if(QT_FEATURE_vulkan)
+ add_subdirectory(vulkan)
+ endif()
+endif()
+
+# special case begin
+qt_examples_build_end()
+# special case end
diff --git a/examples/corelib/CMakeLists.txt b/examples/corelib/CMakeLists.txt
new file mode 100644
index 0000000000..5e24def251
--- /dev/null
+++ b/examples/corelib/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from corelib.pro.
+
+add_subdirectory(ipc)
+add_subdirectory(mimetypes)
+add_subdirectory(serialization)
+add_subdirectory(tools)
+
+if(QT_FEATURE_thread)
+ add_subdirectory(threads)
+endif()
diff --git a/examples/corelib/ipc/CMakeLists.txt b/examples/corelib/ipc/CMakeLists.txt
new file mode 100644
index 0000000000..b134a3aa17
--- /dev/null
+++ b/examples/corelib/ipc/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from ipc.pro.
+
+
+if(QT_FEATURE_sharedmemory)
+ add_subdirectory(sharedmemory)
+endif()
+
+if(TARGET Qt::Network)
+
+ if(QT_FEATURE_localserver)
+ add_subdirectory(localfortuneserver)
+ add_subdirectory(localfortuneclient)
+ endif()
+endif()
diff --git a/examples/corelib/ipc/localfortuneclient/CMakeLists.txt b/examples/corelib/ipc/localfortuneclient/CMakeLists.txt
new file mode 100644
index 0000000000..b664e5795c
--- /dev/null
+++ b/examples/corelib/ipc/localfortuneclient/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from localfortuneclient.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(localfortuneclient LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(localfortuneclient
+ client.cpp client.h
+ main.cpp
+)
+target_link_libraries(localfortuneclient PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+install(TARGETS localfortuneclient
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/corelib/ipc/localfortuneserver/CMakeLists.txt b/examples/corelib/ipc/localfortuneserver/CMakeLists.txt
new file mode 100644
index 0000000000..4d75ad437f
--- /dev/null
+++ b/examples/corelib/ipc/localfortuneserver/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from localfortuneserver.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(localfortuneserver LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(localfortuneserver
+ main.cpp
+ server.cpp server.h
+)
+target_link_libraries(localfortuneserver PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+install(TARGETS localfortuneserver
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/corelib/ipc/sharedmemory/CMakeLists.txt b/examples/corelib/ipc/sharedmemory/CMakeLists.txt
new file mode 100644
index 0000000000..514a49914f
--- /dev/null
+++ b/examples/corelib/ipc/sharedmemory/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from sharedmemory.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(sharedmemory LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(sharedmemory
+ dialog.cpp dialog.h dialog.ui
+ main.cpp
+)
+target_link_libraries(sharedmemory PUBLIC
+ Qt::Widgets
+)
+install(TARGETS sharedmemory
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/corelib/mimetypes/CMakeLists.txt b/examples/corelib/mimetypes/CMakeLists.txt
new file mode 100644
index 0000000000..0b31e0db69
--- /dev/null
+++ b/examples/corelib/mimetypes/CMakeLists.txt
@@ -0,0 +1,6 @@
+# Generated from mimetypes.pro.
+
+
+if(TARGET Qt::Widgets)
+ add_subdirectory(mimetypebrowser)
+endif()
diff --git a/examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt b/examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt
new file mode 100644
index 0000000000..e3ae3b7bb2
--- /dev/null
+++ b/examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from mimetypebrowser.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mimetypebrowser LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(mimetypebrowser
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ mimetypemodel.cpp mimetypemodel.h
+)
+target_link_libraries(mimetypebrowser PUBLIC
+ Qt::Widgets
+)
+install(TARGETS mimetypebrowser
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/corelib/serialization/CMakeLists.txt b/examples/corelib/serialization/CMakeLists.txt
new file mode 100644
index 0000000000..a64b5130d2
--- /dev/null
+++ b/examples/corelib/serialization/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from serialization.pro.
+
+add_subdirectory(cbordump)
+add_subdirectory(convert)
+add_subdirectory(savegame)
diff --git a/examples/corelib/serialization/cbordump/CMakeLists.txt b/examples/corelib/serialization/cbordump/CMakeLists.txt
new file mode 100644
index 0000000000..cedf7712d4
--- /dev/null
+++ b/examples/corelib/serialization/cbordump/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from cbordump.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(cbordump LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+
+add_executable(cbordump
+ main.cpp
+)
+target_link_libraries(cbordump PUBLIC
+ # Remove: gui
+ Qt::Core
+)
+install(TARGETS cbordump
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/corelib/serialization/convert/CMakeLists.txt b/examples/corelib/serialization/convert/CMakeLists.txt
new file mode 100644
index 0000000000..04b57bbd3d
--- /dev/null
+++ b/examples/corelib/serialization/convert/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from convert.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(convert LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+
+add_executable(convert
+ cborconverter.cpp cborconverter.h
+ converter.h
+ datastreamconverter.cpp datastreamconverter.h
+ jsonconverter.cpp jsonconverter.h
+ main.cpp
+ nullconverter.cpp nullconverter.h
+ textconverter.cpp textconverter.h
+ xmlconverter.cpp xmlconverter.h
+)
+target_link_libraries(convert PUBLIC
+ # Remove: gui
+ Qt::Core
+)
+install(TARGETS convert
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/corelib/serialization/savegame/CMakeLists.txt b/examples/corelib/serialization/savegame/CMakeLists.txt
new file mode 100644
index 0000000000..97d866da43
--- /dev/null
+++ b/examples/corelib/serialization/savegame/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from savegame.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(savegame LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+
+add_executable(savegame
+ character.cpp character.h
+ game.cpp game.h
+ level.cpp level.h
+ main.cpp
+)
+target_link_libraries(savegame PUBLIC
+ # Remove: gui
+ Qt::Core
+)
+install(TARGETS savegame
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/corelib/threads/CMakeLists.txt b/examples/corelib/threads/CMakeLists.txt
new file mode 100644
index 0000000000..b13dd16d93
--- /dev/null
+++ b/examples/corelib/threads/CMakeLists.txt
@@ -0,0 +1,9 @@
+# Generated from threads.pro.
+
+add_subdirectory(semaphores)
+add_subdirectory(waitconditions)
+
+if(TARGET Qt::Widgets)
+ add_subdirectory(mandelbrot)
+ add_subdirectory(queuedcustomtype)
+endif()
diff --git a/examples/corelib/threads/mandelbrot/CMakeLists.txt b/examples/corelib/threads/mandelbrot/CMakeLists.txt
new file mode 100644
index 0000000000..6905429559
--- /dev/null
+++ b/examples/corelib/threads/mandelbrot/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from mandelbrot.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mandelbrot LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(mandelbrot
+ main.cpp
+ mandelbrotwidget.cpp mandelbrotwidget.h
+ renderthread.cpp renderthread.h
+)
+target_link_libraries(mandelbrot PUBLIC
+ Qt::Widgets
+)
+install(TARGETS mandelbrot
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/corelib/threads/queuedcustomtype/CMakeLists.txt b/examples/corelib/threads/queuedcustomtype/CMakeLists.txt
new file mode 100644
index 0000000000..78a59ac2dc
--- /dev/null
+++ b/examples/corelib/threads/queuedcustomtype/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from queuedcustomtype.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(queuedcustomtype LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(queuedcustomtype
+ block.cpp block.h
+ main.cpp
+ renderthread.cpp renderthread.h
+ window.cpp window.h
+)
+target_link_libraries(queuedcustomtype PUBLIC
+ Qt::Widgets
+)
+install(TARGETS queuedcustomtype
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/corelib/threads/semaphores/CMakeLists.txt b/examples/corelib/threads/semaphores/CMakeLists.txt
new file mode 100644
index 0000000000..ed36acde55
--- /dev/null
+++ b/examples/corelib/threads/semaphores/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from semaphores.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(semaphores LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+
+add_executable(semaphores
+ semaphores.cpp
+)
+target_link_libraries(semaphores PUBLIC
+ Qt::Core
+)
+install(TARGETS semaphores
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/corelib/threads/waitconditions/CMakeLists.txt b/examples/corelib/threads/waitconditions/CMakeLists.txt
new file mode 100644
index 0000000000..235cb91cdb
--- /dev/null
+++ b/examples/corelib/threads/waitconditions/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from waitconditions.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(waitconditions LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+
+add_executable(waitconditions
+ waitconditions.cpp
+)
+target_link_libraries(waitconditions PUBLIC
+ Qt::Core
+)
+install(TARGETS waitconditions
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/corelib/tools/CMakeLists.txt b/examples/corelib/tools/CMakeLists.txt
new file mode 100644
index 0000000000..d25014ee3c
--- /dev/null
+++ b/examples/corelib/tools/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from tools.pro.
+
+add_subdirectory(contiguouscache)
+add_subdirectory(customtype)
+add_subdirectory(customtypesending)
diff --git a/examples/corelib/tools/contiguouscache/CMakeLists.txt b/examples/corelib/tools/contiguouscache/CMakeLists.txt
new file mode 100644
index 0000000000..3adb033c49
--- /dev/null
+++ b/examples/corelib/tools/contiguouscache/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from contiguouscache.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(contiguouscache LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(contiguouscache
+ main.cpp
+ randomlistmodel.cpp randomlistmodel.h
+)
+target_link_libraries(contiguouscache PUBLIC
+ Qt::Widgets
+)
+install(TARGETS contiguouscache
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/corelib/tools/customtype/CMakeLists.txt b/examples/corelib/tools/customtype/CMakeLists.txt
new file mode 100644
index 0000000000..11958e1c1b
--- /dev/null
+++ b/examples/corelib/tools/customtype/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from customtype.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(customtype LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(customtype
+ main.cpp
+ message.cpp message.h
+)
+target_link_libraries(customtype PUBLIC
+ Qt::Widgets
+)
+install(TARGETS customtype
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/corelib/tools/customtypesending/CMakeLists.txt b/examples/corelib/tools/customtypesending/CMakeLists.txt
new file mode 100644
index 0000000000..f22894d919
--- /dev/null
+++ b/examples/corelib/tools/customtypesending/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from customtypesending.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(customtypesending LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(customtypesending
+ main.cpp
+ message.cpp message.h
+ window.cpp window.h
+)
+target_link_libraries(customtypesending PUBLIC
+ Qt::Widgets
+)
+install(TARGETS customtypesending
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/dbus/CMakeLists.txt b/examples/dbus/CMakeLists.txt
new file mode 100644
index 0000000000..42a3df658a
--- /dev/null
+++ b/examples/dbus/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from dbus.pro.
+
+add_subdirectory(listnames)
+add_subdirectory(pingpong)
+
+if(QT_FEATURE_process)
+ add_subdirectory(complexpingpong)
+endif()
+
+if(TARGET Qt::Widgets)
+ add_subdirectory(chat)
+ add_subdirectory(remotecontrolledcar)
+endif()
diff --git a/examples/dbus/chat/CMakeLists.txt b/examples/dbus/chat/CMakeLists.txt
new file mode 100644
index 0000000000..064ce26833
--- /dev/null
+++ b/examples/dbus/chat/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from chat.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(chat LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS DBus)
+find_package(Qt6 COMPONENTS Widgets)
+
+# special case begin
+set(chat_SRCS)
+qt6_add_dbus_interface(chat_SRCS
+ org.example.chat.xml
+ chat_interface
+)
+qt6_add_dbus_adaptor(chat_SRCS
+ org.example.chat.xml
+ qobject.h
+ QObject
+ chat_adaptor
+)
+# special case end
+add_qt_gui_executable(chat
+ chat.cpp chat.h
+ chatmainwindow.ui
+ chatsetnickname.ui
+ ${chat_SRCS} # special case
+)
+target_link_libraries(chat PUBLIC
+ Qt::DBus
+ Qt::Widgets
+)
+install(TARGETS chat
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/dbus/complexpingpong/CMakeLists.txt b/examples/dbus/complexpingpong/CMakeLists.txt
new file mode 100644
index 0000000000..01a824e5e7
--- /dev/null
+++ b/examples/dbus/complexpingpong/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from complexpong.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(complexpong LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS DBus)
+
+add_qt_gui_executable(complexpong
+ complexpong.cpp complexpong.h
+)
+target_link_libraries(complexpong PUBLIC
+ # Remove: gui
+ Qt::DBus
+)
+install(TARGETS complexpong
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/dbus/listnames/CMakeLists.txt b/examples/dbus/listnames/CMakeLists.txt
new file mode 100644
index 0000000000..60c91ba8b4
--- /dev/null
+++ b/examples/dbus/listnames/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from listnames.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(listnames LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS DBus)
+
+add_qt_gui_executable(listnames
+ listnames.cpp
+)
+target_link_libraries(listnames PUBLIC
+ # Remove: gui
+ Qt::DBus
+)
+install(TARGETS listnames
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/dbus/pingpong/CMakeLists.txt b/examples/dbus/pingpong/CMakeLists.txt
new file mode 100644
index 0000000000..6a2a84e974
--- /dev/null
+++ b/examples/dbus/pingpong/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from pong.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(pong LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS DBus)
+
+add_qt_gui_executable(pong
+ ping-common.h
+ pong.cpp pong.h
+)
+target_link_libraries(pong PUBLIC
+ # Remove: gui
+ Qt::DBus
+)
+install(TARGETS pong
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/dbus/remotecontrolledcar/CMakeLists.txt b/examples/dbus/remotecontrolledcar/CMakeLists.txt
new file mode 100644
index 0000000000..4d41919962
--- /dev/null
+++ b/examples/dbus/remotecontrolledcar/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from remotecontrolledcar.pro.
+
+add_subdirectory(car)
+add_subdirectory(controller)
diff --git a/examples/dbus/remotecontrolledcar/car/CMakeLists.txt b/examples/dbus/remotecontrolledcar/car/CMakeLists.txt
new file mode 100644
index 0000000000..10abdd8f70
--- /dev/null
+++ b/examples/dbus/remotecontrolledcar/car/CMakeLists.txt
@@ -0,0 +1,39 @@
+# Generated from car.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(car LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS DBus)
+find_package(Qt6 COMPONENTS Widgets)
+
+# special case begin
+set(car_SRCS)
+qt6_add_dbus_adaptor(car_SRCS
+ car.xml
+ car.h
+ Car
+ car_adaptor
+)
+# special case end
+add_qt_gui_executable(car
+ car.cpp car.h
+ main.cpp
+ ${car_SRCS} # special case
+)
+target_link_libraries(car PUBLIC
+ Qt::DBus
+ Qt::Widgets
+)
+install(TARGETS car
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/dbus/remotecontrolledcar/controller/CMakeLists.txt b/examples/dbus/remotecontrolledcar/controller/CMakeLists.txt
new file mode 100644
index 0000000000..2075261d18
--- /dev/null
+++ b/examples/dbus/remotecontrolledcar/controller/CMakeLists.txt
@@ -0,0 +1,37 @@
+# Generated from controller.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(controller LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS DBus)
+find_package(Qt6 COMPONENTS Widgets)
+
+# special case begin
+set(controller_SRCS)
+qt6_add_dbus_interface(controller_SRCS
+ car.xml
+ car_interface
+)
+# special case end
+add_qt_gui_executable(controller
+ controller.cpp controller.h controller.ui
+ main.cpp
+ ${controller_SRCS} # special case
+)
+target_link_libraries(controller PUBLIC
+ Qt::DBus
+ Qt::Widgets
+)
+install(TARGETS controller
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/embedded/CMakeLists.txt b/examples/embedded/CMakeLists.txt
new file mode 100644
index 0000000000..bd7720809a
--- /dev/null
+++ b/examples/embedded/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from embedded.pro.
+
+add_subdirectory(styleexample)
+add_subdirectory(raycasting)
+add_subdirectory(flickable)
+add_subdirectory(digiflip)
+add_subdirectory(lightmaps)
+add_subdirectory(flightinfo)
diff --git a/examples/embedded/digiflip/CMakeLists.txt b/examples/embedded/digiflip/CMakeLists.txt
new file mode 100644
index 0000000000..f5557766ad
--- /dev/null
+++ b/examples/embedded/digiflip/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from digiflip.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(digiflip LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(digiflip
+ digiflip.cpp
+)
+target_link_libraries(digiflip PUBLIC
+ Qt::Widgets
+)
+install(TARGETS digiflip
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/embedded/flickable/CMakeLists.txt b/examples/embedded/flickable/CMakeLists.txt
new file mode 100644
index 0000000000..bd435d1352
--- /dev/null
+++ b/examples/embedded/flickable/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from flickable.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(flickable LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(flickable
+ flickable.cpp flickable.h
+ main.cpp
+)
+target_link_libraries(flickable PUBLIC
+ Qt::Widgets
+)
+install(TARGETS flickable
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/embedded/flightinfo/CMakeLists.txt b/examples/embedded/flightinfo/CMakeLists.txt
new file mode 100644
index 0000000000..b2d7695c37
--- /dev/null
+++ b/examples/embedded/flightinfo/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from flightinfo.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(flightinfo LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(flightinfo
+ flightinfo.cpp
+ form.ui
+ flightinfo.qrc # special case: add
+)
+target_link_libraries(flightinfo PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+install(TARGETS flightinfo
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/embedded/lightmaps/CMakeLists.txt b/examples/embedded/lightmaps/CMakeLists.txt
new file mode 100644
index 0000000000..775c12be66
--- /dev/null
+++ b/examples/embedded/lightmaps/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from lightmaps.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(lightmaps LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(lightmaps
+ lightmaps.cpp lightmaps.h
+ main.cpp
+ mapzoom.cpp mapzoom.h
+ slippymap.cpp slippymap.h
+)
+target_link_libraries(lightmaps PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+install(TARGETS lightmaps
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/embedded/raycasting/CMakeLists.txt b/examples/embedded/raycasting/CMakeLists.txt
new file mode 100644
index 0000000000..0b48de26a5
--- /dev/null
+++ b/examples/embedded/raycasting/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from raycasting.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(raycasting LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(raycasting
+ raycasting.cpp raycasting.qrc
+)
+target_link_libraries(raycasting PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS raycasting
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/embedded/styleexample/CMakeLists.txt b/examples/embedded/styleexample/CMakeLists.txt
new file mode 100644
index 0000000000..a0ec3d738a
--- /dev/null
+++ b/examples/embedded/styleexample/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from styleexample.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(styleexample LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(styleexample
+ main.cpp
+ stylewidget.cpp stylewidget.h stylewidget.ui
+ styleexample.qrc # special case: add
+)
+target_link_libraries(styleexample PUBLIC
+ Qt::Widgets
+)
+install(TARGETS styleexample
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/gui/CMakeLists.txt b/examples/gui/CMakeLists.txt
new file mode 100644
index 0000000000..7ae4c6bc6a
--- /dev/null
+++ b/examples/gui/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from gui.pro.
+
+add_subdirectory(analogclock)
+add_subdirectory(rasterwindow)
+
+if(TARGET Qt::Gui AND QT_FEATURE_opengl)
+ add_subdirectory(openglwindow)
+endif()
diff --git a/examples/gui/analogclock/CMakeLists.txt b/examples/gui/analogclock/CMakeLists.txt
new file mode 100644
index 0000000000..2b727a48db
--- /dev/null
+++ b/examples/gui/analogclock/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from analogclock.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(analogclock LANGUAGES CXX)
+
+find_package(Qt6 COMPONENTS Widgets) # special case: add
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+add_qt_gui_executable(gui_analogclock # special case: renamed target
+ ../rasterwindow/rasterwindow.cpp ../rasterwindow/rasterwindow.h
+ main.cpp
+)
+target_include_directories(gui_analogclock PUBLIC
+ ../rasterwindow
+)
+# special case begin
+target_link_libraries(gui_analogclock PUBLIC
+ Qt::Gui
+)
+# special case end
+
+install(TARGETS gui_analogclock
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/gui/openglwindow/CMakeLists.txt b/examples/gui/openglwindow/CMakeLists.txt
new file mode 100644
index 0000000000..98fc40fd9a
--- /dev/null
+++ b/examples/gui/openglwindow/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from openglwindow.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(openglwindow LANGUAGES CXX)
+
+find_package(Qt6 COMPONENTS Widgets) # special case: add
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+add_qt_gui_executable(openglwindow
+ main.cpp
+ openglwindow.cpp openglwindow.h
+)
+target_include_directories(openglwindow PUBLIC
+ ${CMAKE_CURRENT_SOURCE_DIR}
+)
+# special case begin
+target_link_libraries(openglwindow PUBLIC
+ Qt::Gui
+)
+# special case end
+install(TARGETS openglwindow
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/gui/rasterwindow/CMakeLists.txt b/examples/gui/rasterwindow/CMakeLists.txt
new file mode 100644
index 0000000000..dd1bcf4f3b
--- /dev/null
+++ b/examples/gui/rasterwindow/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from rasterwindow.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(rasterwindow LANGUAGES CXX)
+
+find_package(Qt6 COMPONENTS Widgets) # special case: add
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+add_qt_gui_executable(rasterwindow
+ main.cpp
+ rasterwindow.cpp rasterwindow.h
+)
+target_include_directories(rasterwindow PUBLIC
+ ${CMAKE_CURRENT_SOURCE_DIR}
+)
+# special case begin
+target_link_libraries(rasterwindow PUBLIC
+ Qt::Gui
+)
+# special case end
+install(TARGETS rasterwindow
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/CMakeLists.txt b/examples/network/CMakeLists.txt
new file mode 100644
index 0000000000..af1f923dc6
--- /dev/null
+++ b/examples/network/CMakeLists.txt
@@ -0,0 +1,45 @@
+# Generated from network.pro.
+
+add_subdirectory(download)
+add_subdirectory(downloadmanager)
+
+if(NOT INTEGRITY)
+ add_subdirectory(dnslookup)
+endif()
+
+if(TARGET Qt::Widgets)
+ add_subdirectory(blockingfortuneclient)
+ add_subdirectory(broadcastreceiver)
+ add_subdirectory(broadcastsender)
+ add_subdirectory(http)
+ add_subdirectory(loopback)
+ add_subdirectory(threadedfortuneserver)
+ add_subdirectory(googlesuggest)
+ # add_subdirectory(torrent) FIXME: This does not find its ui file:-/
+ add_subdirectory(multicastreceiver)
+ add_subdirectory(multicastsender)
+
+ if(QT_FEATURE_bearermanagement)
+ add_subdirectory(bearermonitor)
+ add_subdirectory(fortuneclient)
+ add_subdirectory(fortuneserver)
+
+ if(QT_FEATURE_processenvironment)
+ add_subdirectory(network-chat)
+ endif()
+ endif()
+
+ if(QT_FEATURE_openssl)
+ add_subdirectory(securesocketclient)
+ endif()
+
+ if(QT_FEATURE_dtls)
+ add_subdirectory(secureudpserver)
+ add_subdirectory(secureudpclient)
+ endif()
+
+ if(QT_FEATURE_sctp)
+ add_subdirectory(multistreamserver)
+ add_subdirectory(multistreamclient)
+ endif()
+endif()
diff --git a/examples/network/bearermonitor/CMakeLists.txt b/examples/network/bearermonitor/CMakeLists.txt
new file mode 100644
index 0000000000..eb992a0c58
--- /dev/null
+++ b/examples/network/bearermonitor/CMakeLists.txt
@@ -0,0 +1,37 @@
+# Generated from bearermonitor.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(bearermonitor LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_executable(bearermonitor
+ bearermonitor.cpp bearermonitor.h
+ bearermonitor_240_320.ui
+ bearermonitor_640_480.ui
+ main.cpp
+ sessionwidget.cpp sessionwidget.h sessionwidget.ui
+)
+target_link_libraries(bearermonitor PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS bearermonitor
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/blockingfortuneclient/CMakeLists.txt b/examples/network/blockingfortuneclient/CMakeLists.txt
new file mode 100644
index 0000000000..14e15f9e13
--- /dev/null
+++ b/examples/network/blockingfortuneclient/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from blockingfortuneclient.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(blockingfortuneclient LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(blockingfortuneclient
+ blockingclient.cpp blockingclient.h
+ fortunethread.cpp fortunethread.h
+ main.cpp
+)
+target_link_libraries(blockingfortuneclient PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS blockingfortuneclient
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/broadcastreceiver/CMakeLists.txt b/examples/network/broadcastreceiver/CMakeLists.txt
new file mode 100644
index 0000000000..ad1f9823d4
--- /dev/null
+++ b/examples/network/broadcastreceiver/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from broadcastreceiver.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(broadcastreceiver LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(broadcastreceiver
+ main.cpp
+ receiver.cpp receiver.h
+)
+target_link_libraries(broadcastreceiver PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS broadcastreceiver
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/broadcastsender/CMakeLists.txt b/examples/network/broadcastsender/CMakeLists.txt
new file mode 100644
index 0000000000..b823046396
--- /dev/null
+++ b/examples/network/broadcastsender/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from broadcastsender.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(broadcastsender LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(broadcastsender
+ main.cpp
+ sender.cpp sender.h
+)
+target_link_libraries(broadcastsender PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS broadcastsender
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/dnslookup/CMakeLists.txt b/examples/network/dnslookup/CMakeLists.txt
new file mode 100644
index 0000000000..bc0bb4d1eb
--- /dev/null
+++ b/examples/network/dnslookup/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from dnslookup.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(dnslookup LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Network)
+
+add_executable(dnslookup
+ dnslookup.cpp dnslookup.h
+)
+target_link_libraries(dnslookup PUBLIC
+ Qt::Core
+ Qt::Network
+)
+
+install(TARGETS dnslookup
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/download/CMakeLists.txt b/examples/network/download/CMakeLists.txt
new file mode 100644
index 0000000000..462bf30554
--- /dev/null
+++ b/examples/network/download/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from download.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(download LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Network)
+
+add_executable(download
+ main.cpp
+)
+target_link_libraries(download PUBLIC
+ Qt::Core
+ Qt::Network
+)
+
+install(TARGETS download
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/downloadmanager/CMakeLists.txt b/examples/network/downloadmanager/CMakeLists.txt
new file mode 100644
index 0000000000..09d1db51d0
--- /dev/null
+++ b/examples/network/downloadmanager/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from downloadmanager.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(downloadmanager LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Network)
+
+add_executable(downloadmanager
+ downloadmanager.cpp downloadmanager.h
+ main.cpp
+ textprogressbar.cpp textprogressbar.h
+)
+target_link_libraries(downloadmanager PUBLIC
+ Qt::Core
+ Qt::Network
+)
+
+install(TARGETS downloadmanager
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/fortuneclient/CMakeLists.txt b/examples/network/fortuneclient/CMakeLists.txt
new file mode 100644
index 0000000000..7af88e9626
--- /dev/null
+++ b/examples/network/fortuneclient/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from fortuneclient.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(fortuneclient LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(fortuneclient
+ client.cpp client.h
+ main.cpp
+)
+target_link_libraries(fortuneclient PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS fortuneclient
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/fortuneserver/CMakeLists.txt b/examples/network/fortuneserver/CMakeLists.txt
new file mode 100644
index 0000000000..19897104e0
--- /dev/null
+++ b/examples/network/fortuneserver/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from fortuneserver.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(fortuneserver LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(fortuneserver
+ main.cpp
+ server.cpp server.h
+)
+target_link_libraries(fortuneserver PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS fortuneserver
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/googlesuggest/CMakeLists.txt b/examples/network/googlesuggest/CMakeLists.txt
new file mode 100644
index 0000000000..5a6a52ce33
--- /dev/null
+++ b/examples/network/googlesuggest/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from googlesuggest.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(googlesuggest LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(googlesuggest
+ googlesuggest.cpp googlesuggest.h
+ main.cpp
+ searchbox.cpp searchbox.h
+)
+target_link_libraries(googlesuggest PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS googlesuggest
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/http/CMakeLists.txt b/examples/network/http/CMakeLists.txt
new file mode 100644
index 0000000000..2e00f20635
--- /dev/null
+++ b/examples/network/http/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from http.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(http LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(http
+ authenticationdialog.ui
+ httpwindow.cpp httpwindow.h
+ main.cpp
+)
+target_link_libraries(http PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS http
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/loopback/CMakeLists.txt b/examples/network/loopback/CMakeLists.txt
new file mode 100644
index 0000000000..233ff460e3
--- /dev/null
+++ b/examples/network/loopback/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from loopback.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(loopback LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(loopback
+ dialog.cpp dialog.h
+ main.cpp
+)
+target_link_libraries(loopback PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS loopback
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/multicastreceiver/CMakeLists.txt b/examples/network/multicastreceiver/CMakeLists.txt
new file mode 100644
index 0000000000..8073c9fb7e
--- /dev/null
+++ b/examples/network/multicastreceiver/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from multicastreceiver.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(multicastreceiver LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(multicastreceiver
+ main.cpp
+ receiver.cpp receiver.h
+)
+target_link_libraries(multicastreceiver PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS multicastreceiver
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/multicastsender/CMakeLists.txt b/examples/network/multicastsender/CMakeLists.txt
new file mode 100644
index 0000000000..062c942b35
--- /dev/null
+++ b/examples/network/multicastsender/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from multicastsender.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(multicastsender LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(multicastsender
+ main.cpp
+ sender.cpp sender.h
+)
+target_link_libraries(multicastsender PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS multicastsender
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/multistreamclient/CMakeLists.txt b/examples/network/multistreamclient/CMakeLists.txt
new file mode 100644
index 0000000000..617e556cff
--- /dev/null
+++ b/examples/network/multistreamclient/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from multistreamclient.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(multistreamclient LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(multistreamclient
+ chatconsumer.cpp chatconsumer.h
+ client.cpp client.h
+ consumer.h
+ main.cpp
+ movieconsumer.cpp movieconsumer.h
+ timeconsumer.cpp timeconsumer.h
+)
+target_link_libraries(multistreamclient PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS multistreamclient
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/multistreamserver/CMakeLists.txt b/examples/network/multistreamserver/CMakeLists.txt
new file mode 100644
index 0000000000..3564e370d7
--- /dev/null
+++ b/examples/network/multistreamserver/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from multistreamserver.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(multistreamserver LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(multistreamserver
+ chatprovider.cpp chatprovider.h
+ main.cpp
+ movieprovider.cpp movieprovider.h
+ provider.h
+ server.cpp server.h
+ timeprovider.cpp timeprovider.h
+)
+target_link_libraries(multistreamserver PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS multistreamserver
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/network-chat/CMakeLists.txt b/examples/network/network-chat/CMakeLists.txt
new file mode 100644
index 0000000000..eb836df8c9
--- /dev/null
+++ b/examples/network/network-chat/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from network-chat.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(network-chat LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(network-chat
+ chatdialog.cpp chatdialog.h chatdialog.ui
+ client.cpp client.h
+ connection.cpp connection.h
+ main.cpp
+ peermanager.cpp peermanager.h
+ server.cpp server.h
+)
+target_link_libraries(network-chat PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS network-chat
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/securesocketclient/CMakeLists.txt b/examples/network/securesocketclient/CMakeLists.txt
new file mode 100644
index 0000000000..d83bd5f284
--- /dev/null
+++ b/examples/network/securesocketclient/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from securesocketclient.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(securesocketclient LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(securesocketclient
+ certificateinfo.cpp certificateinfo.h certificateinfo.ui
+ main.cpp
+ securesocketclient.qrc
+ sslclient.cpp sslclient.h sslclient.ui
+ sslerrors.ui
+)
+target_link_libraries(securesocketclient PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS securesocketclient
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/secureudpclient/CMakeLists.txt b/examples/network/secureudpclient/CMakeLists.txt
new file mode 100644
index 0000000000..385918a61b
--- /dev/null
+++ b/examples/network/secureudpclient/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from secureudpclient.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(secureudpclient LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS Network)
+
+add_qt_gui_executable(secureudpclient
+ addressdialog.cpp addressdialog.h addressdialog.ui
+ association.cpp association.h
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+)
+target_link_libraries(secureudpclient PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS secureudpclient
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/secureudpserver/CMakeLists.txt b/examples/network/secureudpserver/CMakeLists.txt
new file mode 100644
index 0000000000..28d01df849
--- /dev/null
+++ b/examples/network/secureudpserver/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from secureudpserver.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(secureudpserver LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS Network)
+
+add_qt_gui_executable(secureudpserver
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ nicselector.cpp nicselector.h nicselector.ui
+ server.cpp server.h
+)
+target_link_libraries(secureudpserver PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS secureudpserver
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/threadedfortuneserver/CMakeLists.txt b/examples/network/threadedfortuneserver/CMakeLists.txt
new file mode 100644
index 0000000000..35372da369
--- /dev/null
+++ b/examples/network/threadedfortuneserver/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from threadedfortuneserver.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(threadedfortuneserver LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(threadedfortuneserver
+ dialog.cpp dialog.h
+ fortuneserver.cpp fortuneserver.h
+ fortunethread.cpp fortunethread.h
+ main.cpp
+)
+target_link_libraries(threadedfortuneserver PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS threadedfortuneserver
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/torrent/.prev_CMakeLists.txt b/examples/network/torrent/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..8c294427f7
--- /dev/null
+++ b/examples/network/torrent/.prev_CMakeLists.txt
@@ -0,0 +1,41 @@
+# Generated from torrent.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(torrent LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(torrent
+ addtorrentdialog.cpp addtorrentdialog.h
+ bencodeparser.cpp bencodeparser.h
+ connectionmanager.cpp connectionmanager.h
+ filemanager.cpp filemanager.h
+ forms/addtorrentform.ui
+ icons.qrc
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ metainfo.cpp metainfo.h
+ peerwireclient.cpp peerwireclient.h
+ ratecontroller.cpp ratecontroller.h
+ torrentclient.cpp torrentclient.h
+ torrentserver.cpp torrentserver.h
+ trackerclient.cpp trackerclient.h
+)
+target_link_libraries(torrent PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS torrent
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/network/torrent/CMakeLists.txt b/examples/network/torrent/CMakeLists.txt
new file mode 100644
index 0000000000..9398369064
--- /dev/null
+++ b/examples/network/torrent/CMakeLists.txt
@@ -0,0 +1,43 @@
+# Generated from torrent.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(torrent LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(torrent
+ addtorrentdialog.cpp addtorrentdialog.h
+ bencodeparser.cpp bencodeparser.h
+ connectionmanager.cpp connectionmanager.h
+ filemanager.cpp filemanager.h
+ forms/addtorrentform.ui
+ icons.qrc
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ metainfo.cpp metainfo.h
+ peerwireclient.cpp peerwireclient.h
+ ratecontroller.cpp ratecontroller.h
+ torrentclient.cpp torrentclient.h
+ torrentserver.cpp torrentserver.h
+ trackerclient.cpp trackerclient.h
+)
+target_include_directories(torrent PUBLIC forms) # special case
+target_link_libraries(torrent PUBLIC
+ Qt::Network
+ Qt::Widgets
+)
+
+install(TARGETS torrent
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/2dpainting/CMakeLists.txt b/examples/opengl/2dpainting/CMakeLists.txt
new file mode 100644
index 0000000000..ccc26d5cff
--- /dev/null
+++ b/examples/opengl/2dpainting/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from 2dpainting.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(2dpainting LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(2dpainting
+ glwidget.cpp glwidget.h
+ helper.cpp helper.h
+ main.cpp
+ widget.cpp widget.h
+ window.cpp window.h
+)
+target_link_libraries(2dpainting PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+install(TARGETS 2dpainting
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/CMakeLists.txt b/examples/opengl/CMakeLists.txt
new file mode 100644
index 0000000000..53f6329463
--- /dev/null
+++ b/examples/opengl/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from opengl.pro.
+
+add_subdirectory(hellowindow)
+add_subdirectory(paintedwindow)
+add_subdirectory(qopenglwindow)
+if(TARGET Qt::Widgets)
+ add_subdirectory(contextinfo)
+ add_subdirectory(threadedqopenglwidget)
+ add_subdirectory(2dpainting)
+ add_subdirectory(hellogl2)
+ add_subdirectory(qopenglwidget)
+ add_subdirectory(cube)
+ add_subdirectory(textures)
+ add_subdirectory(hellogles3)
+ add_subdirectory(computegles31)
+endif()
diff --git a/examples/opengl/computegles31/CMakeLists.txt b/examples/opengl/computegles31/CMakeLists.txt
new file mode 100644
index 0000000000..306fe8638e
--- /dev/null
+++ b/examples/opengl/computegles31/CMakeLists.txt
@@ -0,0 +1,43 @@
+# Generated from computegles31.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(computegles31 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+
+add_qt_gui_executable(computegles31
+ glwindow.cpp glwindow.h
+ main.cpp
+)
+target_link_libraries(computegles31 PUBLIC
+ Qt::Core
+ Qt::Gui
+)
+
+# Resources:
+set(computegles31_resource_files
+ "Qt-logo-medium.png"
+)
+
+qt6_add_resources(computegles31 "computegles31"
+ PREFIX
+ "/"
+ FILES
+ ${computegles31_resource_files}
+)
+
+
+install(TARGETS computegles31
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/contextinfo/CMakeLists.txt b/examples/opengl/contextinfo/CMakeLists.txt
new file mode 100644
index 0000000000..dca5b9bab4
--- /dev/null
+++ b/examples/opengl/contextinfo/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from contextinfo.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(contextinfo LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(contextinfo
+ main.cpp
+ renderwindow.cpp renderwindow.h
+ widget.cpp widget.h
+)
+target_link_libraries(contextinfo PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+install(TARGETS contextinfo
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/cube/CMakeLists.txt b/examples/opengl/cube/CMakeLists.txt
new file mode 100644
index 0000000000..8527a966ae
--- /dev/null
+++ b/examples/opengl/cube/CMakeLists.txt
@@ -0,0 +1,57 @@
+# Generated from cube.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(cube LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(cube
+ geometryengine.cpp geometryengine.h
+ main.cpp
+ mainwidget.cpp mainwidget.h
+)
+target_link_libraries(cube PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set(shaders_resource_files
+ "fshader.glsl"
+ "vshader.glsl"
+)
+
+qt6_add_resources(cube "shaders"
+ PREFIX
+ "/"
+ FILES
+ ${shaders_resource_files}
+)
+set(textures_resource_files
+ "cube.png"
+)
+
+qt6_add_resources(cube "textures"
+ PREFIX
+ "/"
+ FILES
+ ${textures_resource_files}
+)
+
+
+install(TARGETS cube
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/hellogl2/CMakeLists.txt b/examples/opengl/hellogl2/CMakeLists.txt
new file mode 100644
index 0000000000..06ea78d959
--- /dev/null
+++ b/examples/opengl/hellogl2/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from hellogl2.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(hellogl2 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(hellogl2
+ glwidget.cpp glwidget.h
+ logo.cpp logo.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ window.cpp window.h
+)
+target_link_libraries(hellogl2 PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+install(TARGETS hellogl2
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/hellogles3/CMakeLists.txt b/examples/opengl/hellogles3/CMakeLists.txt
new file mode 100644
index 0000000000..d642b214c8
--- /dev/null
+++ b/examples/opengl/hellogles3/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from hellogles3.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(hellogles3 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+
+add_qt_gui_executable(hellogles3
+ ../hellogl2/logo.cpp ../hellogl2/logo.h
+ glwindow.cpp glwindow.h
+ main.cpp
+)
+target_link_libraries(hellogles3 PUBLIC
+ Qt::Core
+ Qt::Gui
+)
+
+# Resources:
+set(hellogles3_resource_files
+ "qtlogo.png"
+)
+
+qt6_add_resources(hellogles3 "hellogles3"
+ PREFIX
+ "/"
+ FILES
+ ${hellogles3_resource_files}
+)
+
+
+install(TARGETS hellogles3
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/hellowindow/CMakeLists.txt b/examples/opengl/hellowindow/CMakeLists.txt
new file mode 100644
index 0000000000..341b52b2cb
--- /dev/null
+++ b/examples/opengl/hellowindow/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from hellowindow.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(hellowindow LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+
+add_qt_gui_executable(hellowindow
+ hellowindow.cpp hellowindow.h
+ main.cpp
+)
+target_link_libraries(hellowindow PRIVATE
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+target_link_libraries(hellowindow PUBLIC
+ Qt::Core
+ Qt::Gui
+)
+
+install(TARGETS hellowindow
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/legacy/CMakeLists.txt b/examples/opengl/legacy/CMakeLists.txt
new file mode 100644
index 0000000000..5f98186a0e
--- /dev/null
+++ b/examples/opengl/legacy/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from legacy.pro.
+
+if(NOT TARGET Qt::OpenGL)
+ return()
+endif()
+if(NOT QT_FEATURE_dynamicgl AND NOT QT_FEATURE_opengles2)
+ add_subdirectory(grabber)
+ add_subdirectory(hellogl)
+ add_subdirectory(overpainting)
+ add_subdirectory(pbuffers)
+ add_subdirectory(framebufferobject2)
+ add_subdirectory(samplebuffers)
+endif()
diff --git a/examples/opengl/legacy/framebufferobject2/CMakeLists.txt b/examples/opengl/legacy/framebufferobject2/CMakeLists.txt
new file mode 100644
index 0000000000..74b00e8359
--- /dev/null
+++ b/examples/opengl/legacy/framebufferobject2/CMakeLists.txt
@@ -0,0 +1,47 @@
+# Generated from framebufferobject2.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(framebufferobject2 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS OpenGL)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(framebufferobject2
+ glwidget.cpp glwidget.h
+ main.cpp
+)
+target_link_libraries(framebufferobject2 PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::OpenGL
+ Qt::Widgets
+)
+
+# Resources:
+set(framebufferobject2_resource_files
+ "cubelogo.png"
+)
+
+qt6_add_resources(framebufferobject2 "framebufferobject2"
+ PREFIX
+ "/res"
+ FILES
+ ${framebufferobject2_resource_files}
+)
+
+
+install(TARGETS framebufferobject2
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/legacy/grabber/CMakeLists.txt b/examples/opengl/legacy/grabber/CMakeLists.txt
new file mode 100644
index 0000000000..13ffd6fc31
--- /dev/null
+++ b/examples/opengl/legacy/grabber/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from grabber.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(grabber LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS OpenGL)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(grabber
+ glwidget.cpp glwidget.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(grabber PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::OpenGL
+ Qt::Widgets
+)
+
+install(TARGETS grabber
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/legacy/hellogl/CMakeLists.txt b/examples/opengl/legacy/hellogl/CMakeLists.txt
new file mode 100644
index 0000000000..5e61d52964
--- /dev/null
+++ b/examples/opengl/legacy/hellogl/CMakeLists.txt
@@ -0,0 +1,39 @@
+# Generated from hellogl.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(hellogl LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS OpenGL)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(hellogl
+ ../shared/qtlogo.cpp ../shared/qtlogo.h
+ glwidget.cpp glwidget.h
+ main.cpp
+ window.cpp window.h
+)
+target_include_directories(hellogl PUBLIC
+ ../shared
+)
+target_link_libraries(hellogl PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::OpenGL
+ Qt::Widgets
+)
+
+install(TARGETS hellogl
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/legacy/overpainting/CMakeLists.txt b/examples/opengl/legacy/overpainting/CMakeLists.txt
new file mode 100644
index 0000000000..4addb8a3c6
--- /dev/null
+++ b/examples/opengl/legacy/overpainting/CMakeLists.txt
@@ -0,0 +1,39 @@
+# Generated from overpainting.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(overpainting LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS OpenGL)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(overpainting
+ ../shared/qtlogo.cpp ../shared/qtlogo.h
+ bubble.cpp bubble.h
+ glwidget.cpp glwidget.h
+ main.cpp
+)
+target_include_directories(overpainting PUBLIC
+ ../shared
+)
+target_link_libraries(overpainting PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::OpenGL
+ Qt::Widgets
+)
+
+install(TARGETS overpainting
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/legacy/pbuffers/CMakeLists.txt b/examples/opengl/legacy/pbuffers/CMakeLists.txt
new file mode 100644
index 0000000000..eb3de5535a
--- /dev/null
+++ b/examples/opengl/legacy/pbuffers/CMakeLists.txt
@@ -0,0 +1,48 @@
+# Generated from pbuffers.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(pbuffers LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS OpenGL)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(pbuffers
+ cube.cpp cube.h
+ glwidget.cpp glwidget.h
+ main.cpp
+)
+target_link_libraries(pbuffers PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::OpenGL
+ Qt::Widgets
+)
+
+# Resources:
+set(pbuffers_resource_files
+ "cubelogo.png"
+)
+
+qt6_add_resources(pbuffers "pbuffers"
+ PREFIX
+ "/res"
+ FILES
+ ${pbuffers_resource_files}
+)
+
+
+install(TARGETS pbuffers
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/legacy/pbuffers2/CMakeLists.txt b/examples/opengl/legacy/pbuffers2/CMakeLists.txt
new file mode 100644
index 0000000000..b82e2f35c6
--- /dev/null
+++ b/examples/opengl/legacy/pbuffers2/CMakeLists.txt
@@ -0,0 +1,50 @@
+# Generated from pbuffers2.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(pbuffers2 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS OpenGL)
+find_package(Qt6 COMPONENTS Svg)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(pbuffers2
+ glwidget.cpp glwidget.h
+ main.cpp
+)
+target_link_libraries(pbuffers2 PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::OpenGL
+ Qt::Svg
+ Qt::Widgets
+)
+
+# Resources:
+set(pbuffers2_resource_files
+ "bubbles.svg"
+ "designer.png"
+)
+
+qt6_add_resources(pbuffers2 "pbuffers2"
+ PREFIX
+ "/res"
+ FILES
+ ${pbuffers2_resource_files}
+)
+
+
+install(TARGETS pbuffers2
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/legacy/samplebuffers/CMakeLists.txt b/examples/opengl/legacy/samplebuffers/CMakeLists.txt
new file mode 100644
index 0000000000..3d500fa55e
--- /dev/null
+++ b/examples/opengl/legacy/samplebuffers/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from samplebuffers.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(samplebuffers LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS OpenGL)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(samplebuffers
+ glwidget.cpp glwidget.h
+ main.cpp
+)
+target_link_libraries(samplebuffers PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::OpenGL
+ Qt::Widgets
+)
+
+install(TARGETS samplebuffers
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/paintedwindow/CMakeLists.txt b/examples/opengl/paintedwindow/CMakeLists.txt
new file mode 100644
index 0000000000..7333b0697c
--- /dev/null
+++ b/examples/opengl/paintedwindow/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from paintedwindow.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(paintedwindow LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+
+add_qt_gui_executable(paintedwindow
+ main.cpp
+ paintedwindow.cpp paintedwindow.h
+)
+target_link_libraries(paintedwindow PUBLIC
+ Qt::Core
+ Qt::Gui
+)
+
+install(TARGETS paintedwindow
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/qopenglwidget/CMakeLists.txt b/examples/opengl/qopenglwidget/CMakeLists.txt
new file mode 100644
index 0000000000..1531343a28
--- /dev/null
+++ b/examples/opengl/qopenglwidget/CMakeLists.txt
@@ -0,0 +1,47 @@
+# Generated from qopenglwidget.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(qopenglwidget LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(qopenglwidget
+ bubble.cpp bubble.h
+ glwidget.cpp glwidget.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(qopenglwidget PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set(texture_resource_files
+ "qt.png"
+)
+
+qt6_add_resources(qopenglwidget "texture"
+ PREFIX
+ "/"
+ FILES
+ ${texture_resource_files}
+)
+
+
+install(TARGETS qopenglwidget
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/qopenglwindow/CMakeLists.txt b/examples/opengl/qopenglwindow/CMakeLists.txt
new file mode 100644
index 0000000000..182262791e
--- /dev/null
+++ b/examples/opengl/qopenglwindow/CMakeLists.txt
@@ -0,0 +1,46 @@
+# Generated from qopenglwindow.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(qopenglwindow LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+
+add_qt_gui_executable(qopenglwindow
+ background_renderer.cpp background_renderer.h
+ main.cpp
+)
+target_include_directories(qopenglwindow PUBLIC
+ .
+)
+target_link_libraries(qopenglwindow PUBLIC
+ Qt::Core
+ Qt::Gui
+)
+
+# Resources:
+set(shaders_resource_files
+ "background.frag"
+)
+
+qt6_add_resources(qopenglwindow "shaders"
+ PREFIX
+ "/"
+ FILES
+ ${shaders_resource_files}
+)
+
+
+install(TARGETS qopenglwindow
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/textures/CMakeLists.txt b/examples/opengl/textures/CMakeLists.txt
new file mode 100644
index 0000000000..69ae694f74
--- /dev/null
+++ b/examples/opengl/textures/CMakeLists.txt
@@ -0,0 +1,51 @@
+# Generated from textures.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(textures LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(textures
+ glwidget.cpp glwidget.h
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(textures PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set(textures_resource_files
+ "images/side1.png"
+ "images/side2.png"
+ "images/side3.png"
+ "images/side4.png"
+ "images/side5.png"
+ "images/side6.png"
+)
+
+qt6_add_resources(textures "textures"
+ PREFIX
+ "/"
+ FILES
+ ${textures_resource_files}
+)
+
+
+install(TARGETS textures
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/opengl/threadedqopenglwidget/CMakeLists.txt b/examples/opengl/threadedqopenglwidget/CMakeLists.txt
new file mode 100644
index 0000000000..20bee78283
--- /dev/null
+++ b/examples/opengl/threadedqopenglwidget/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from threadedqopenglwidget.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(threadedqopenglwidget LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(threadedqopenglwidget
+ glwidget.cpp glwidget.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(threadedqopenglwidget PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+install(TARGETS threadedqopenglwidget
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/qpa/CMakeLists.txt b/examples/qpa/CMakeLists.txt
new file mode 100644
index 0000000000..0ae7f61e57
--- /dev/null
+++ b/examples/qpa/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from qpa.pro.
+
+add_subdirectory(windows)
+add_subdirectory(qrasterwindow)
diff --git a/examples/qpa/qrasterwindow/CMakeLists.txt b/examples/qpa/qrasterwindow/CMakeLists.txt
new file mode 100644
index 0000000000..1567d38285
--- /dev/null
+++ b/examples/qpa/qrasterwindow/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from qrasterwindow.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(qrasterwindow LANGUAGES CXX)
+
+find_package(Qt6 COMPONENTS Gui) # special case
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+add_qt_gui_executable(qrasterwindow
+ main.cpp
+)
+target_link_libraries(qrasterwindow PUBLIC Qt::Gui) # special case: add
+
+install(TARGETS qrasterwindow
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/qpa/windows/CMakeLists.txt b/examples/qpa/windows/CMakeLists.txt
new file mode 100644
index 0000000000..22f98c28f3
--- /dev/null
+++ b/examples/qpa/windows/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from windows.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(windows LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Core)
+
+add_executable(windows
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(windows PRIVATE
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+target_link_libraries(windows PUBLIC
+ Qt::Core
+ Qt::Gui
+)
+
+install(TARGETS windows
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/qtconcurrent/CMakeLists.txt b/examples/qtconcurrent/CMakeLists.txt
new file mode 100644
index 0000000000..13cfed8773
--- /dev/null
+++ b/examples/qtconcurrent/CMakeLists.txt
@@ -0,0 +1,9 @@
+if(TARGET Qt::Gui)
+ add_subdirectory(map)
+endif()
+if(TARGET Qt::Widgets)
+ add_subdirectory(imagescaling)
+ add_subdirectory(progressdialog)
+ add_subdirectory(runfunction)
+ add_subdirectory(wordcount)
+endif()
diff --git a/examples/qtconcurrent/imagescaling/CMakeLists.txt b/examples/qtconcurrent/imagescaling/CMakeLists.txt
new file mode 100644
index 0000000000..5d487ab409
--- /dev/null
+++ b/examples/qtconcurrent/imagescaling/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from imagescaling.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(imagescaling LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Concurrent)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(imagescaling
+ imagescaling.cpp imagescaling.h
+ main.cpp
+)
+target_link_libraries(imagescaling PUBLIC
+ Qt::Concurrent
+ Qt::Widgets
+)
+
+install(TARGETS imagescaling
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/qtconcurrent/map/.prev_CMakeLists.txt b/examples/qtconcurrent/map/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..cd53409ec8
--- /dev/null
+++ b/examples/qtconcurrent/map/.prev_CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from map.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mapdemo LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Concurrent)
+
+add_executable(mapdemo
+ main.cpp
+)
+target_link_libraries(mapdemo PUBLIC
+ Qt::Concurrent
+)
+
+install(TARGETS mapdemo
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/qtconcurrent/map/CMakeLists.txt b/examples/qtconcurrent/map/CMakeLists.txt
new file mode 100644
index 0000000000..1707825b8f
--- /dev/null
+++ b/examples/qtconcurrent/map/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from map.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mapdemo LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Concurrent)
+find_package(Qt6 COMPONENTS Gui) # special case
+
+add_executable(mapdemo
+ main.cpp
+)
+target_link_libraries(mapdemo PUBLIC
+ Qt::Concurrent
+ Qt::Gui # special case
+)
+install(TARGETS mapdemo
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/qtconcurrent/progressdialog/CMakeLists.txt b/examples/qtconcurrent/progressdialog/CMakeLists.txt
new file mode 100644
index 0000000000..f9e7980b63
--- /dev/null
+++ b/examples/qtconcurrent/progressdialog/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from progressdialog.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(progressdialog LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Concurrent)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_executable(progressdialog
+ main.cpp
+)
+target_link_libraries(progressdialog PUBLIC
+ Qt::Concurrent
+ Qt::Widgets
+)
+
+install(TARGETS progressdialog
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/qtconcurrent/runfunction/CMakeLists.txt b/examples/qtconcurrent/runfunction/CMakeLists.txt
new file mode 100644
index 0000000000..de20553212
--- /dev/null
+++ b/examples/qtconcurrent/runfunction/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from runfunction.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(runfunction LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Concurrent)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_executable(runfunction
+ main.cpp
+)
+target_link_libraries(runfunction PUBLIC
+ Qt::Concurrent
+ Qt::Widgets
+)
+
+install(TARGETS runfunction
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/qtconcurrent/wordcount/CMakeLists.txt b/examples/qtconcurrent/wordcount/CMakeLists.txt
new file mode 100644
index 0000000000..e4afbaa4c5
--- /dev/null
+++ b/examples/qtconcurrent/wordcount/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from wordcount.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(wordcount LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Concurrent)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_executable(wordcount
+ main.cpp
+)
+target_link_libraries(wordcount PUBLIC
+ Qt::Concurrent
+ Qt::Widgets
+)
+
+install(TARGETS wordcount
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/qtestlib/CMakeLists.txt b/examples/qtestlib/CMakeLists.txt
new file mode 100644
index 0000000000..83e7df5768
--- /dev/null
+++ b/examples/qtestlib/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from qtestlib.pro.
+
+add_subdirectory(tutorial1)
+add_subdirectory(tutorial2)
+add_subdirectory(tutorial3)
+add_subdirectory(tutorial4)
+add_subdirectory(tutorial5)
diff --git a/examples/qtestlib/tutorial1/CMakeLists.txt b/examples/qtestlib/tutorial1/CMakeLists.txt
new file mode 100644
index 0000000000..fabe54bf1a
--- /dev/null
+++ b/examples/qtestlib/tutorial1/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from tutorial1.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(tutorial1 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS Test)
+
+add_qt_gui_executable(tutorial1
+ testqstring.cpp
+)
+target_link_libraries(tutorial1 PUBLIC
+ Qt::Test
+ Qt::Widgets
+)
+install(TARGETS tutorial1
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/qtestlib/tutorial2/CMakeLists.txt b/examples/qtestlib/tutorial2/CMakeLists.txt
new file mode 100644
index 0000000000..52ad642cca
--- /dev/null
+++ b/examples/qtestlib/tutorial2/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from tutorial2.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(tutorial2 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS Test)
+
+add_qt_gui_executable(tutorial2
+ testqstring.cpp
+)
+target_link_libraries(tutorial2 PUBLIC
+ Qt::Test
+ Qt::Widgets
+)
+install(TARGETS tutorial2
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/qtestlib/tutorial3/CMakeLists.txt b/examples/qtestlib/tutorial3/CMakeLists.txt
new file mode 100644
index 0000000000..8dfba0bbe1
--- /dev/null
+++ b/examples/qtestlib/tutorial3/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from tutorial3.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(tutorial3 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS Test)
+
+add_qt_gui_executable(tutorial3
+ testgui.cpp
+)
+target_link_libraries(tutorial3 PUBLIC
+ Qt::Test
+ Qt::Widgets
+)
+install(TARGETS tutorial3
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/qtestlib/tutorial4/CMakeLists.txt b/examples/qtestlib/tutorial4/CMakeLists.txt
new file mode 100644
index 0000000000..e5af801801
--- /dev/null
+++ b/examples/qtestlib/tutorial4/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from tutorial4.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(tutorial4 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS Test)
+
+add_qt_gui_executable(tutorial4
+ testgui.cpp
+)
+target_link_libraries(tutorial4 PUBLIC
+ Qt::Test
+ Qt::Widgets
+)
+install(TARGETS tutorial4
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/qtestlib/tutorial5/CMakeLists.txt b/examples/qtestlib/tutorial5/CMakeLists.txt
new file mode 100644
index 0000000000..3b6f4db4d0
--- /dev/null
+++ b/examples/qtestlib/tutorial5/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from tutorial5.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(tutorial5 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS Test)
+
+add_qt_gui_executable(tutorial5
+ benchmarking.cpp
+)
+target_link_libraries(tutorial5 PUBLIC
+ Qt::Test
+ Qt::Widgets
+)
+install(TARGETS tutorial5
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/sql/CMakeLists.txt b/examples/sql/CMakeLists.txt
new file mode 100644
index 0000000000..ca15f22baf
--- /dev/null
+++ b/examples/sql/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from sql.pro.
+
+add_subdirectory(books)
+add_subdirectory(drilldown)
+add_subdirectory(cachedtable)
+add_subdirectory(querymodel)
+add_subdirectory(relationaltablemodel)
+add_subdirectory(sqlwidgetmapper)
+add_subdirectory(tablemodel)
+
+if(TARGET Qt::Xml)
+ add_subdirectory(masterdetail)
+endif()
+
+if(NOT CMAKE_CROSSCOMPILING) # special case
+ add_subdirectory(sqlbrowser)
+endif()
diff --git a/examples/sql/books/CMakeLists.txt b/examples/sql/books/CMakeLists.txt
new file mode 100644
index 0000000000..5890c6c85f
--- /dev/null
+++ b/examples/sql/books/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from books.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(books LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Sql)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(books
+ bookdelegate.cpp bookdelegate.h
+ books.qrc
+ bookwindow.cpp bookwindow.h bookwindow.ui
+ initdb.h
+ main.cpp
+)
+target_include_directories(books PUBLIC
+ .
+)
+target_link_libraries(books PUBLIC
+ Qt::Sql
+ Qt::Widgets
+)
+
+install(TARGETS books
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/sql/cachedtable/CMakeLists.txt b/examples/sql/cachedtable/CMakeLists.txt
new file mode 100644
index 0000000000..512c7c4891
--- /dev/null
+++ b/examples/sql/cachedtable/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from cachedtable.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(cachedtable LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Sql)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(cachedtable
+ ../connection.h
+ main.cpp
+ tableeditor.cpp tableeditor.h
+)
+target_link_libraries(cachedtable PUBLIC
+ Qt::Sql
+ Qt::Widgets
+)
+
+install(TARGETS cachedtable
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/sql/drilldown/CMakeLists.txt b/examples/sql/drilldown/CMakeLists.txt
new file mode 100644
index 0000000000..128ebc107f
--- /dev/null
+++ b/examples/sql/drilldown/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from drilldown.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(drilldown LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Sql)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(drilldown
+ ../connection.h
+ drilldown.qrc
+ imageitem.cpp imageitem.h
+ informationwindow.cpp informationwindow.h
+ main.cpp
+ view.cpp view.h
+)
+target_link_libraries(drilldown PUBLIC
+ Qt::Sql
+ Qt::Widgets
+)
+
+install(TARGETS drilldown
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/sql/masterdetail/CMakeLists.txt b/examples/sql/masterdetail/CMakeLists.txt
new file mode 100644
index 0000000000..a142d41d5f
--- /dev/null
+++ b/examples/sql/masterdetail/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from masterdetail.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(masterdetail LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Sql)
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS Xml)
+
+add_qt_gui_executable(masterdetail
+ database.h
+ dialog.cpp dialog.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ masterdetail.qrc
+)
+target_link_libraries(masterdetail PUBLIC
+ Qt::Sql
+ Qt::Widgets
+ Qt::Xml
+)
+
+install(TARGETS masterdetail
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/sql/querymodel/CMakeLists.txt b/examples/sql/querymodel/CMakeLists.txt
new file mode 100644
index 0000000000..a31abc40fc
--- /dev/null
+++ b/examples/sql/querymodel/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from querymodel.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(querymodel LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Sql)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(querymodel
+ ../connection.h
+ customsqlmodel.cpp customsqlmodel.h
+ editablesqlmodel.cpp editablesqlmodel.h
+ main.cpp
+)
+target_link_libraries(querymodel PUBLIC
+ Qt::Sql
+ Qt::Widgets
+)
+
+install(TARGETS querymodel
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/sql/relationaltablemodel/CMakeLists.txt b/examples/sql/relationaltablemodel/CMakeLists.txt
new file mode 100644
index 0000000000..fbdab96aff
--- /dev/null
+++ b/examples/sql/relationaltablemodel/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from relationaltablemodel.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(relationaltablemodel LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Sql)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(relationaltablemodel
+ ../connection.h
+ relationaltablemodel.cpp
+)
+target_link_libraries(relationaltablemodel PUBLIC
+ Qt::Sql
+ Qt::Widgets
+)
+
+install(TARGETS relationaltablemodel
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/sql/sqlbrowser/CMakeLists.txt b/examples/sql/sqlbrowser/CMakeLists.txt
new file mode 100644
index 0000000000..b9aae1c7eb
--- /dev/null
+++ b/examples/sql/sqlbrowser/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from sqlbrowser.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(sqlbrowser LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Sql)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(sqlbrowser
+ browser.cpp browser.h
+ browserwidget.ui
+ connectionwidget.cpp connectionwidget.h
+ main.cpp
+ qsqlconnectiondialog.cpp qsqlconnectiondialog.h qsqlconnectiondialog.ui
+)
+target_link_libraries(sqlbrowser PUBLIC
+ Qt::Sql
+ Qt::Widgets
+)
+
+install(TARGETS sqlbrowser
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/sql/sqlwidgetmapper/CMakeLists.txt b/examples/sql/sqlwidgetmapper/CMakeLists.txt
new file mode 100644
index 0000000000..ad0d5cfce9
--- /dev/null
+++ b/examples/sql/sqlwidgetmapper/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from sqlwidgetmapper.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(sqlwidgetmapper LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Sql)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(sqlwidgetmapper
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(sqlwidgetmapper PUBLIC
+ Qt::Sql
+ Qt::Widgets
+)
+
+install(TARGETS sqlwidgetmapper
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/sql/tablemodel/CMakeLists.txt b/examples/sql/tablemodel/CMakeLists.txt
new file mode 100644
index 0000000000..9e90e56b7f
--- /dev/null
+++ b/examples/sql/tablemodel/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from tablemodel.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(tablemodel LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Sql)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(tablemodel
+ ../connection.h
+ tablemodel.cpp
+)
+target_link_libraries(tablemodel PUBLIC
+ Qt::Sql
+ Qt::Widgets
+)
+
+install(TARGETS tablemodel
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/vulkan/CMakeLists.txt b/examples/vulkan/CMakeLists.txt
new file mode 100644
index 0000000000..b00a40447a
--- /dev/null
+++ b/examples/vulkan/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from vulkan.pro.
+
+add_subdirectory(hellovulkanwindow)
+add_subdirectory(hellovulkantriangle)
+add_subdirectory(hellovulkantexture)
+if(TARGET Qt::Widgets)
+ add_subdirectory(hellovulkanwidget)
+endif()
+if(TARGET Qt::Concurrent AND TARGET Qt::Widgets)
+ add_subdirectory(hellovulkancubes)
+endif()
diff --git a/examples/vulkan/hellovulkancubes/CMakeLists.txt b/examples/vulkan/hellovulkancubes/CMakeLists.txt
new file mode 100644
index 0000000000..c77cd59d8c
--- /dev/null
+++ b/examples/vulkan/hellovulkancubes/CMakeLists.txt
@@ -0,0 +1,63 @@
+# Generated from hellovulkancubes.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(hellovulkancubes LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS Concurrent)
+
+add_qt_gui_executable(hellovulkancubes
+ camera.cpp camera.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ mesh.cpp mesh.h
+ renderer.cpp renderer.h
+ shader.cpp shader.h
+ vulkanwindow.cpp vulkanwindow.h
+)
+target_link_libraries(hellovulkancubes PUBLIC
+ Qt::Concurrent
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set_source_files_properties("../shared/block.buf"
+ PROPERTIES QT_RESOURCE_ALIAS "block.buf"
+)
+set_source_files_properties("../shared/qt_logo.buf"
+ PROPERTIES QT_RESOURCE_ALIAS "qt_logo.buf"
+)
+set(hellovulkancubes_resource_files
+ "../shared/block.buf"
+ "../shared/qt_logo.buf"
+ "color_frag.spv"
+ "color_phong_frag.spv"
+ "color_phong_vert.spv"
+ "color_vert.spv"
+)
+
+qt6_add_resources(hellovulkancubes "hellovulkancubes"
+ PREFIX
+ "/"
+ FILES
+ ${hellovulkancubes_resource_files}
+)
+
+
+install(TARGETS hellovulkancubes
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/vulkan/hellovulkantexture/CMakeLists.txt b/examples/vulkan/hellovulkantexture/CMakeLists.txt
new file mode 100644
index 0000000000..b9cbd179f0
--- /dev/null
+++ b/examples/vulkan/hellovulkantexture/CMakeLists.txt
@@ -0,0 +1,45 @@
+# Generated from hellovulkantexture.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(hellovulkantexture LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+
+add_qt_gui_executable(hellovulkantexture
+ hellovulkantexture.cpp hellovulkantexture.h
+ main.cpp
+)
+target_link_libraries(hellovulkantexture PUBLIC
+ Qt::Core
+ Qt::Gui
+)
+
+# Resources:
+set(hellovulkantexture_resource_files
+ "qt256.png"
+ "texture_frag.spv"
+ "texture_vert.spv"
+)
+
+qt6_add_resources(hellovulkantexture "hellovulkantexture"
+ PREFIX
+ "/"
+ FILES
+ ${hellovulkantexture_resource_files}
+)
+
+
+install(TARGETS hellovulkantexture
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/vulkan/hellovulkantriangle/CMakeLists.txt b/examples/vulkan/hellovulkantriangle/CMakeLists.txt
new file mode 100644
index 0000000000..73ca042881
--- /dev/null
+++ b/examples/vulkan/hellovulkantriangle/CMakeLists.txt
@@ -0,0 +1,50 @@
+# Generated from hellovulkantriangle.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(hellovulkantriangle LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+
+add_qt_gui_executable(hellovulkantriangle
+ ../shared/trianglerenderer.cpp ../shared/trianglerenderer.h
+ main.cpp
+)
+target_link_libraries(hellovulkantriangle PUBLIC
+ Qt::Core
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../shared/color_frag.spv"
+ PROPERTIES QT_RESOURCE_ALIAS "color_frag.spv"
+)
+set_source_files_properties("../shared/color_vert.spv"
+ PROPERTIES QT_RESOURCE_ALIAS "color_vert.spv"
+)
+set(hellovulkantriangle_resource_files
+ "../shared/color_frag.spv"
+ "../shared/color_vert.spv"
+)
+
+qt6_add_resources(hellovulkantriangle "hellovulkantriangle"
+ PREFIX
+ "/"
+ FILES
+ ${hellovulkantriangle_resource_files}
+)
+
+
+install(TARGETS hellovulkantriangle
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/vulkan/hellovulkanwidget/CMakeLists.txt b/examples/vulkan/hellovulkanwidget/CMakeLists.txt
new file mode 100644
index 0000000000..281c49e77d
--- /dev/null
+++ b/examples/vulkan/hellovulkanwidget/CMakeLists.txt
@@ -0,0 +1,53 @@
+# Generated from hellovulkanwidget.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(hellovulkanwidget LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(hellovulkanwidget
+ ../shared/trianglerenderer.cpp ../shared/trianglerenderer.h
+ hellovulkanwidget.cpp hellovulkanwidget.h
+ main.cpp
+)
+target_link_libraries(hellovulkanwidget PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set_source_files_properties("../shared/color_frag.spv"
+ PROPERTIES QT_RESOURCE_ALIAS "color_frag.spv"
+)
+set_source_files_properties("../shared/color_vert.spv"
+ PROPERTIES QT_RESOURCE_ALIAS "color_vert.spv"
+)
+set(hellovulkanwidget_resource_files
+ "../shared/color_frag.spv"
+ "../shared/color_vert.spv"
+)
+
+qt6_add_resources(hellovulkanwidget "hellovulkanwidget"
+ PREFIX
+ "/"
+ FILES
+ ${hellovulkanwidget_resource_files}
+)
+
+
+install(TARGETS hellovulkanwidget
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/vulkan/hellovulkanwindow/CMakeLists.txt b/examples/vulkan/hellovulkanwindow/CMakeLists.txt
new file mode 100644
index 0000000000..6e79b959a8
--- /dev/null
+++ b/examples/vulkan/hellovulkanwindow/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from hellovulkanwindow.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(hellovulkanwindow LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+
+add_qt_gui_executable(hellovulkanwindow
+ hellovulkanwindow.cpp hellovulkanwindow.h
+ main.cpp
+)
+target_link_libraries(hellovulkanwindow PUBLIC
+ Qt::Core
+ Qt::Gui
+)
+
+install(TARGETS hellovulkanwindow
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/CMakeLists.txt b/examples/widgets/CMakeLists.txt
new file mode 100644
index 0000000000..1b18fc8622
--- /dev/null
+++ b/examples/widgets/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from widgets.pro.
+
+add_subdirectory(animation)
+add_subdirectory(desktop)
+add_subdirectory(dialogs)
+if(QT_FEATURE_draganddrop) # special case
+ add_subdirectory(draganddrop)
+endif()
+add_subdirectory(effects)
+add_subdirectory(gestures)
+add_subdirectory(graphicsview)
+add_subdirectory(itemviews)
+add_subdirectory(layouts)
+add_subdirectory(painting)
+add_subdirectory(richtext)
+add_subdirectory(scroller)
+add_subdirectory(statemachine)
+add_subdirectory(tools)
+add_subdirectory(touch)
+add_subdirectory(tutorials)
+add_subdirectory(widgets)
+
+if(TARGET Qt::Gui AND QT_FEATURE_opengl)
+ add_subdirectory(windowcontainer)
+endif()
+
+if(QT_FEATURE_cursor) # special case
+ add_subdirectory(mainwindows)
+endif()
+
+if(APPLE_OSX)
+ add_subdirectory(mac)
+endif()
diff --git a/examples/widgets/animation/CMakeLists.txt b/examples/widgets/animation/CMakeLists.txt
new file mode 100644
index 0000000000..15f62728da
--- /dev/null
+++ b/examples/widgets/animation/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from animation.pro.
+
+add_subdirectory(animatedtiles)
+add_subdirectory(easing)
+add_subdirectory(moveblocks)
+add_subdirectory(states)
+add_subdirectory(stickman)
+add_subdirectory(sub-attaq)
diff --git a/examples/widgets/animation/animatedtiles/CMakeLists.txt b/examples/widgets/animation/animatedtiles/CMakeLists.txt
new file mode 100644
index 0000000000..d35fd9cf92
--- /dev/null
+++ b/examples/widgets/animation/animatedtiles/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from animatedtiles.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(animatedtiles LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(animatedtiles
+ animatedtiles.qrc
+ main.cpp
+)
+target_link_libraries(animatedtiles PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS animatedtiles
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/animation/easing/CMakeLists.txt b/examples/widgets/animation/easing/CMakeLists.txt
new file mode 100644
index 0000000000..76750aac54
--- /dev/null
+++ b/examples/widgets/animation/easing/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from easing.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(easing LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(easing
+ animation.h
+ easing.qrc
+ form.ui
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(easing PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS easing
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/animation/moveblocks/CMakeLists.txt b/examples/widgets/animation/moveblocks/CMakeLists.txt
new file mode 100644
index 0000000000..e522d72477
--- /dev/null
+++ b/examples/widgets/animation/moveblocks/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from moveblocks.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(moveblocks LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(moveblocks
+ main.cpp
+)
+target_link_libraries(moveblocks PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS moveblocks
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/animation/states/CMakeLists.txt b/examples/widgets/animation/states/CMakeLists.txt
new file mode 100644
index 0000000000..e8d1d42f03
--- /dev/null
+++ b/examples/widgets/animation/states/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from states.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(states LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(states
+ main.cpp
+ states.qrc
+)
+target_link_libraries(states PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS states
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/animation/stickman/CMakeLists.txt b/examples/widgets/animation/stickman/CMakeLists.txt
new file mode 100644
index 0000000000..4c76380f51
--- /dev/null
+++ b/examples/widgets/animation/stickman/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from stickman.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(stickman LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(stickman
+ animation.cpp animation.h
+ graphicsview.cpp graphicsview.h
+ lifecycle.cpp lifecycle.h
+ main.cpp
+ node.cpp node.h
+ rectbutton.cpp rectbutton.h
+ stickman.cpp stickman.h stickman.qrc
+)
+target_link_libraries(stickman PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS stickman
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/animation/sub-attaq/CMakeLists.txt b/examples/widgets/animation/sub-attaq/CMakeLists.txt
new file mode 100644
index 0000000000..52bed5c278
--- /dev/null
+++ b/examples/widgets/animation/sub-attaq/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from sub-attaq.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(sub-attaq LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS OpenGL) # special case
+
+add_qt_gui_executable(sub-attaq
+ animationmanager.cpp animationmanager.h
+ boat.cpp boat.h boat_p.h
+ bomb.cpp bomb.h
+ graphicsscene.cpp graphicsscene.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ pixmapitem.cpp pixmapitem.h
+ progressitem.cpp progressitem.h
+ qanimationstate.cpp qanimationstate.h
+ states.cpp states.h
+ subattaq.qrc
+ submarine.cpp submarine.h submarine_p.h
+ textinformationitem.cpp textinformationitem.h
+ torpedo.cpp torpedo.h
+)
+target_link_libraries(sub-attaq PUBLIC
+ Qt::Widgets
+)
+if (TARGET Qt::OpenGL)
+ target_link_libraries(sub-attaq PUBLIC Qt::OpenGL)
+endif()
+
+install(TARGETS sub-attaq
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/desktop/CMakeLists.txt b/examples/widgets/desktop/CMakeLists.txt
new file mode 100644
index 0000000000..a50d3c2f0a
--- /dev/null
+++ b/examples/widgets/desktop/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from desktop.pro.
+
+add_subdirectory(screenshot)
+add_subdirectory(systray)
diff --git a/examples/widgets/desktop/screenshot/CMakeLists.txt b/examples/widgets/desktop/screenshot/CMakeLists.txt
new file mode 100644
index 0000000000..9b85cc591e
--- /dev/null
+++ b/examples/widgets/desktop/screenshot/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from screenshot.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(screenshot LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(screenshot
+ main.cpp
+ screenshot.cpp screenshot.h
+)
+target_link_libraries(screenshot PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS screenshot
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/desktop/systray/CMakeLists.txt b/examples/widgets/desktop/systray/CMakeLists.txt
new file mode 100644
index 0000000000..0086b79229
--- /dev/null
+++ b/examples/widgets/desktop/systray/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from systray.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(systray LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(systray
+ main.cpp
+ systray.qrc
+ window.cpp window.h
+)
+target_link_libraries(systray PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS systray
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/dialogs/CMakeLists.txt b/examples/widgets/dialogs/CMakeLists.txt
new file mode 100644
index 0000000000..c9d6823adc
--- /dev/null
+++ b/examples/widgets/dialogs/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from dialogs.pro.
+
+add_subdirectory(extension)
+add_subdirectory(findfiles)
+if(TARGET Qt::PrintSupport AND QT_FEATURE_wizard) # special case
+ add_subdirectory(licensewizard)
+endif()
+add_subdirectory(standarddialogs)
+add_subdirectory(tabdialog)
+
+if(QT_FEATURE_wizard) # special case
+ add_subdirectory(classwizard)
+ add_subdirectory(trivialwizard)
+endif()
diff --git a/examples/widgets/dialogs/classwizard/CMakeLists.txt b/examples/widgets/dialogs/classwizard/CMakeLists.txt
new file mode 100644
index 0000000000..51c4c9e351
--- /dev/null
+++ b/examples/widgets/dialogs/classwizard/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from classwizard.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(classwizard LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(classwizard
+ classwizard.cpp classwizard.h classwizard.qrc
+ main.cpp
+)
+target_link_libraries(classwizard PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS classwizard
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/dialogs/extension/CMakeLists.txt b/examples/widgets/dialogs/extension/CMakeLists.txt
new file mode 100644
index 0000000000..108858868c
--- /dev/null
+++ b/examples/widgets/dialogs/extension/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from extension.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(extension LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(extension
+ finddialog.cpp finddialog.h
+ main.cpp
+)
+target_link_libraries(extension PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS extension
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/dialogs/findfiles/CMakeLists.txt b/examples/widgets/dialogs/findfiles/CMakeLists.txt
new file mode 100644
index 0000000000..27e2265e70
--- /dev/null
+++ b/examples/widgets/dialogs/findfiles/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from findfiles.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(findfiles LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(findfiles
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(findfiles PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS findfiles
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/dialogs/licensewizard/CMakeLists.txt b/examples/widgets/dialogs/licensewizard/CMakeLists.txt
new file mode 100644
index 0000000000..9684cd8171
--- /dev/null
+++ b/examples/widgets/dialogs/licensewizard/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from licensewizard.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(licensewizard LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS PrintSupport)
+
+add_qt_gui_executable(licensewizard
+ licensewizard.cpp licensewizard.h licensewizard.qrc
+ main.cpp
+)
+target_link_libraries(licensewizard PUBLIC
+ Qt::PrintSupport
+ Qt::Widgets
+)
+
+install(TARGETS licensewizard
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/dialogs/standarddialogs/CMakeLists.txt b/examples/widgets/dialogs/standarddialogs/CMakeLists.txt
new file mode 100644
index 0000000000..2e1a84a4f0
--- /dev/null
+++ b/examples/widgets/dialogs/standarddialogs/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from standarddialogs.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(standarddialogs LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(standarddialogs
+ dialog.cpp dialog.h
+ main.cpp
+)
+target_link_libraries(standarddialogs PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS standarddialogs
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/dialogs/tabdialog/CMakeLists.txt b/examples/widgets/dialogs/tabdialog/CMakeLists.txt
new file mode 100644
index 0000000000..980f3cb222
--- /dev/null
+++ b/examples/widgets/dialogs/tabdialog/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from tabdialog.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(tabdialog LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(tabdialog
+ main.cpp
+ tabdialog.cpp tabdialog.h
+)
+target_link_libraries(tabdialog PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS tabdialog
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/dialogs/trivialwizard/CMakeLists.txt b/examples/widgets/dialogs/trivialwizard/CMakeLists.txt
new file mode 100644
index 0000000000..1c194017a4
--- /dev/null
+++ b/examples/widgets/dialogs/trivialwizard/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from trivialwizard.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(trivialwizard LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(trivialwizard
+ trivialwizard.cpp
+)
+target_link_libraries(trivialwizard PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS trivialwizard
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/draganddrop/CMakeLists.txt b/examples/widgets/draganddrop/CMakeLists.txt
new file mode 100644
index 0000000000..fbad523a73
--- /dev/null
+++ b/examples/widgets/draganddrop/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from draganddrop.pro.
+
+add_subdirectory(draggableicons)
+add_subdirectory(draggabletext)
+add_subdirectory(dropsite)
+add_subdirectory(fridgemagnets)
+add_subdirectory(puzzle)
diff --git a/examples/widgets/draganddrop/draggableicons/CMakeLists.txt b/examples/widgets/draganddrop/draggableicons/CMakeLists.txt
new file mode 100644
index 0000000000..5126b41d27
--- /dev/null
+++ b/examples/widgets/draganddrop/draggableicons/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from draggableicons.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(draggableicons LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(draggableicons
+ draggableicons.qrc
+ dragwidget.cpp dragwidget.h
+ main.cpp
+)
+target_link_libraries(draggableicons PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS draggableicons
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/draganddrop/draggabletext/CMakeLists.txt b/examples/widgets/draganddrop/draggabletext/CMakeLists.txt
new file mode 100644
index 0000000000..c542a7b585
--- /dev/null
+++ b/examples/widgets/draganddrop/draggabletext/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from draggabletext.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(draggabletext LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(draggabletext
+ draggabletext.qrc
+ dragwidget.cpp dragwidget.h
+ main.cpp
+)
+target_link_libraries(draggabletext PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS draggabletext
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/draganddrop/dropsite/CMakeLists.txt b/examples/widgets/draganddrop/dropsite/CMakeLists.txt
new file mode 100644
index 0000000000..591edfac3d
--- /dev/null
+++ b/examples/widgets/draganddrop/dropsite/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from dropsite.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(dropsite LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(dropsite
+ droparea.cpp droparea.h
+ dropsitewindow.cpp dropsitewindow.h
+ main.cpp
+)
+target_link_libraries(dropsite PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS dropsite
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt b/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt
new file mode 100644
index 0000000000..84c097f326
--- /dev/null
+++ b/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from fridgemagnets.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(fridgemagnets LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(fridgemagnets
+ draglabel.cpp draglabel.h
+ dragwidget.cpp dragwidget.h
+ fridgemagnets.qrc
+ main.cpp
+)
+target_link_libraries(fridgemagnets PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS fridgemagnets
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/draganddrop/puzzle/CMakeLists.txt b/examples/widgets/draganddrop/puzzle/CMakeLists.txt
new file mode 100644
index 0000000000..99db9b4e0d
--- /dev/null
+++ b/examples/widgets/draganddrop/puzzle/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from puzzle.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(puzzle LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(draganddrop_puzzle # special case: renamed puzzle
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ pieceslist.cpp pieceslist.h
+ puzzle.qrc
+ puzzlewidget.cpp puzzlewidget.h
+)
+target_link_libraries(draganddrop_puzzle PUBLIC # special case: renamed puzzle
+ Qt::Widgets
+)
+
+install(TARGETS draganddrop_puzzle # special case: renamed puzzle
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/effects/CMakeLists.txt b/examples/widgets/effects/CMakeLists.txt
new file mode 100644
index 0000000000..6e8a892de1
--- /dev/null
+++ b/examples/widgets/effects/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from effects.pro.
+
+add_subdirectory(blurpicker)
+add_subdirectory(fademessage)
diff --git a/examples/widgets/effects/blurpicker/CMakeLists.txt b/examples/widgets/effects/blurpicker/CMakeLists.txt
new file mode 100644
index 0000000000..030de7fe93
--- /dev/null
+++ b/examples/widgets/effects/blurpicker/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from blurpicker.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(blurpicker LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(blurpicker
+ blureffect.cpp blureffect.h
+ blurpicker.cpp blurpicker.h blurpicker.qrc
+ main.cpp
+)
+target_link_libraries(blurpicker PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS blurpicker
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/effects/fademessage/CMakeLists.txt b/examples/widgets/effects/fademessage/CMakeLists.txt
new file mode 100644
index 0000000000..d38ebd2d62
--- /dev/null
+++ b/examples/widgets/effects/fademessage/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from fademessage.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(fademessage LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(fademessage
+ fademessage.cpp fademessage.h fademessage.qrc
+ main.cpp
+)
+target_link_libraries(fademessage PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS fademessage
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/gestures/CMakeLists.txt b/examples/widgets/gestures/CMakeLists.txt
new file mode 100644
index 0000000000..0f9f95b72f
--- /dev/null
+++ b/examples/widgets/gestures/CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from gestures.pro.
+
+add_subdirectory(imagegestures)
diff --git a/examples/widgets/gestures/imagegestures/CMakeLists.txt b/examples/widgets/gestures/imagegestures/CMakeLists.txt
new file mode 100644
index 0000000000..62e4854d33
--- /dev/null
+++ b/examples/widgets/gestures/imagegestures/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from imagegestures.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(imagegestures LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(imagegestures
+ imagewidget.cpp imagewidget.h
+ main.cpp
+ mainwidget.cpp mainwidget.h
+)
+target_link_libraries(imagegestures PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS imagegestures
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/graphicsview/CMakeLists.txt b/examples/widgets/graphicsview/CMakeLists.txt
new file mode 100644
index 0000000000..19f60011e5
--- /dev/null
+++ b/examples/widgets/graphicsview/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from graphicsview.pro.
+
+add_subdirectory(chip)
+add_subdirectory(elasticnodes)
+add_subdirectory(embeddeddialogs)
+add_subdirectory(collidingmice)
+add_subdirectory(padnavigator)
+add_subdirectory(basicgraphicslayouts)
+add_subdirectory(diagramscene)
+if(QT_FEATURE_cursor AND QT_FEATURE_draganddrop)
+ add_subdirectory(dragdroprobot)
+endif()
+add_subdirectory(flowlayout)
+add_subdirectory(anchorlayout)
+add_subdirectory(simpleanchorlayout)
+add_subdirectory(weatheranchorlayout)
+
+if(TARGET Qt::OpenGL AND NOT QT_FEATURE_opengles2 AND NOT QT_FEATURE_dynamicgl)
+ add_subdirectory(boxes)
+endif()
diff --git a/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt b/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt
new file mode 100644
index 0000000000..021628a7ff
--- /dev/null
+++ b/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from anchorlayout.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(anchorlayout LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(anchorlayout
+ main.cpp
+)
+target_link_libraries(anchorlayout PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS anchorlayout
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt b/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt
new file mode 100644
index 0000000000..527e33b826
--- /dev/null
+++ b/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from basicgraphicslayouts.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(basicgraphicslayouts LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(basicgraphicslayouts
+ basicgraphicslayouts.qrc
+ layoutitem.cpp layoutitem.h
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(basicgraphicslayouts PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS basicgraphicslayouts
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/graphicsview/boxes/CMakeLists.txt b/examples/widgets/graphicsview/boxes/CMakeLists.txt
new file mode 100644
index 0000000000..0be040f90e
--- /dev/null
+++ b/examples/widgets/graphicsview/boxes/CMakeLists.txt
@@ -0,0 +1,39 @@
+# Generated from boxes.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(boxes LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS OpenGL)
+find_package(Qt6 COMPONENTS Widgets)
+
+
+add_qt_gui_executable(boxes
+ 3rdparty/fbm.c 3rdparty/fbm.h
+ boxes.qrc
+ glbuffers.cpp glbuffers.h
+ glextensions.cpp glextensions.h
+ gltrianglemesh.h
+ main.cpp
+ qtbox.cpp qtbox.h
+ roundedbox.cpp roundedbox.h
+ scene.cpp scene.h
+ trackball.cpp trackball.h
+)
+target_link_libraries(boxes PUBLIC
+ Qt::OpenGL
+ Qt::Widgets
+)
+
+install(TARGETS boxes
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/graphicsview/chip/CMakeLists.txt b/examples/widgets/graphicsview/chip/CMakeLists.txt
new file mode 100644
index 0000000000..302a8a56ca
--- /dev/null
+++ b/examples/widgets/graphicsview/chip/CMakeLists.txt
@@ -0,0 +1,39 @@
+# Generated from chip.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(chip LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS OpenGL) # special case
+find_package(Qt6 COMPONENTS PrintSupport) # special case
+
+add_qt_gui_executable(chip
+ chip.cpp chip.h
+ images.qrc
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ view.cpp view.h
+)
+target_link_libraries(chip PUBLIC
+ Qt::Widgets
+)
+if (TARGET Qt::OpenGL)
+ target_link_libraries(chip PUBLIC Qt::OpenGL)
+endif()
+if (TARGET Qt::PrintSupport)
+ target_link_libraries(chip PUBLIC Qt::PrintSupport)
+endif()
+
+install(TARGETS chip
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/graphicsview/collidingmice/CMakeLists.txt b/examples/widgets/graphicsview/collidingmice/CMakeLists.txt
new file mode 100644
index 0000000000..aeda9367a3
--- /dev/null
+++ b/examples/widgets/graphicsview/collidingmice/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from collidingmice.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(collidingmice LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(collidingmice
+ main.cpp
+ mice.qrc
+ mouse.cpp mouse.h
+)
+target_link_libraries(collidingmice PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS collidingmice
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/graphicsview/diagramscene/CMakeLists.txt b/examples/widgets/graphicsview/diagramscene/CMakeLists.txt
new file mode 100644
index 0000000000..5c7de9c7cd
--- /dev/null
+++ b/examples/widgets/graphicsview/diagramscene/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from diagramscene.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(diagramscene LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(diagramscene
+ arrow.cpp arrow.h
+ diagramitem.cpp diagramitem.h
+ diagramscene.cpp diagramscene.h diagramscene.qrc
+ diagramtextitem.cpp diagramtextitem.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(diagramscene PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS diagramscene
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt b/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt
new file mode 100644
index 0000000000..ef367d461f
--- /dev/null
+++ b/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from dragdroprobot.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(dragdroprobot LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(dragdroprobot
+ coloritem.cpp coloritem.h
+ main.cpp
+ robot.cpp robot.h robot.qrc
+)
+target_link_libraries(dragdroprobot PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS dragdroprobot
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt b/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt
new file mode 100644
index 0000000000..a5d367e2d2
--- /dev/null
+++ b/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from elasticnodes.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(elasticnodes LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(elasticnodes
+ edge.cpp edge.h
+ graphwidget.cpp graphwidget.h
+ main.cpp
+ node.cpp node.h
+)
+target_link_libraries(elasticnodes PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS elasticnodes
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt b/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt
new file mode 100644
index 0000000000..9e3059176b
--- /dev/null
+++ b/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from embeddeddialogs.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(embeddeddialogs LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(embeddeddialogs
+ customproxy.cpp customproxy.h
+ embeddeddialog.cpp embeddeddialog.h embeddeddialog.ui
+ embeddeddialogs.qrc
+ main.cpp
+)
+target_link_libraries(embeddeddialogs PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS embeddeddialogs
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/graphicsview/flowlayout/CMakeLists.txt b/examples/widgets/graphicsview/flowlayout/CMakeLists.txt
new file mode 100644
index 0000000000..45851ca107
--- /dev/null
+++ b/examples/widgets/graphicsview/flowlayout/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from flowlayout.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(flowlayout LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(graphicsview_flowlayout # special case: renamed flowlayout
+ flowlayout.cpp flowlayout.h
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(graphicsview_flowlayout PUBLIC # special case: renamed flowlayout
+ Qt::Widgets
+)
+
+install(TARGETS graphicsview_flowlayout # special case: renamed flowlayout
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/graphicsview/padnavigator/.prev_CMakeLists.txt b/examples/widgets/graphicsview/padnavigator/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..9c4282391e
--- /dev/null
+++ b/examples/widgets/graphicsview/padnavigator/.prev_CMakeLists.txt
@@ -0,0 +1,45 @@
+# Generated from padnavigator.pro.
+
+#####################################################################
+## padnavigator Binary:
+#####################################################################
+
+add_qt_executable(padnavigator
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/padnavigator"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/padnavigator"
+ SOURCES
+ flippablepad.cpp flippablepad.h
+ form.ui
+ main.cpp
+ padnavigator.cpp padnavigator.h
+ roundrectitem.cpp roundrectitem.h
+ splashitem.cpp splashitem.h
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+# Resources:
+add_qt_resource(padnavigator "padnavigator" FILES
+ images/artsfftscope.png
+ images/blue_angle_swirl.jpg
+ images/kontact_contacts.png
+ images/kontact_journal.png
+ images/kontact_mail.png
+ images/kontact_notes.png
+ images/kopeteavailable.png
+ images/metacontact_online.png
+ images/minitools.png)
+
+
+#### Keys ignored in scope 1:.:.:padnavigator.pro:<TRUE>:
+# CONFIG = "console"
+
+## Scopes:
+#####################################################################
+
+extend_target(padnavigator CONDITION TARGET Qt::OpenGL
+ PUBLIC_LIBRARIES
+ Qt::OpenGL
+)
diff --git a/examples/widgets/graphicsview/padnavigator/CMakeLists.txt b/examples/widgets/graphicsview/padnavigator/CMakeLists.txt
new file mode 100644
index 0000000000..7fc6ec1459
--- /dev/null
+++ b/examples/widgets/graphicsview/padnavigator/CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from padnavigator.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(padnavigator LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS OpenGL) # special case
+
+add_executable(padnavigator
+ flippablepad.cpp flippablepad.h
+ form.ui
+ main.cpp
+ padnavigator.cpp padnavigator.h padnavigator.qrc
+ roundrectitem.cpp roundrectitem.h
+ splashitem.cpp splashitem.h
+)
+target_link_libraries(padnavigator PUBLIC
+ Qt::Widgets
+)
+# special case begin
+if (TARGET Qt::OpenGL)
+ target_link_libraries(padnavigator PUBLIC Qt::OpenGL)
+endif()
+# special case end
+
+install(TARGETS padnavigator
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt b/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt
new file mode 100644
index 0000000000..56e3199cc9
--- /dev/null
+++ b/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from simpleanchorlayout.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(simpleanchorlayout LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(simpleanchorlayout
+ main.cpp
+)
+target_link_libraries(simpleanchorlayout PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS simpleanchorlayout
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt b/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt
new file mode 100644
index 0000000000..a9745c54e1
--- /dev/null
+++ b/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from weatheranchorlayout.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(weatheranchorlayout LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(weatheranchorlayout
+ main.cpp
+ weatheranchorlayout.qrc
+)
+target_link_libraries(weatheranchorlayout PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS weatheranchorlayout
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/CMakeLists.txt b/examples/widgets/itemviews/CMakeLists.txt
new file mode 100644
index 0000000000..a1bd0c4dca
--- /dev/null
+++ b/examples/widgets/itemviews/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from itemviews.pro.
+
+add_subdirectory(addressbook)
+add_subdirectory(basicsortfiltermodel)
+add_subdirectory(chart)
+add_subdirectory(coloreditorfactory)
+add_subdirectory(combowidgetmapper)
+add_subdirectory(customsortfiltermodel)
+add_subdirectory(dirview)
+add_subdirectory(editabletreemodel)
+add_subdirectory(fetchmore)
+add_subdirectory(flattreeview)
+add_subdirectory(frozencolumn)
+add_subdirectory(interview)
+add_subdirectory(pixelator)
+if(QT_FEATURE_draganddrop) # special case
+ add_subdirectory(puzzle)
+endif()
+if(TARGET Qt::Xml) # special case
+ add_subdirectory(simpledommodel)
+endif()
+add_subdirectory(simpletreemodel)
+add_subdirectory(simplewidgetmapper)
+add_subdirectory(spinboxdelegate)
+add_subdirectory(spreadsheet)
+add_subdirectory(stardelegate)
+add_subdirectory(storageview)
diff --git a/examples/widgets/itemviews/addressbook/CMakeLists.txt b/examples/widgets/itemviews/addressbook/CMakeLists.txt
new file mode 100644
index 0000000000..eeb4ad23d7
--- /dev/null
+++ b/examples/widgets/itemviews/addressbook/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from addressbook.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(addressbook LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(addressbook
+ adddialog.cpp adddialog.h
+ addresswidget.cpp addresswidget.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ newaddresstab.cpp newaddresstab.h
+ tablemodel.cpp tablemodel.h
+)
+target_link_libraries(addressbook PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS addressbook
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt b/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt
new file mode 100644
index 0000000000..ee084edab6
--- /dev/null
+++ b/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from basicsortfiltermodel.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(basicsortfiltermodel LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(basicsortfiltermodel
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(basicsortfiltermodel PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS basicsortfiltermodel
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/chart/CMakeLists.txt b/examples/widgets/itemviews/chart/CMakeLists.txt
new file mode 100644
index 0000000000..89cac1f515
--- /dev/null
+++ b/examples/widgets/itemviews/chart/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from chart.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(chart LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(chart
+ chart.qrc
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ pieview.cpp pieview.h
+)
+target_link_libraries(chart PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS chart
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt b/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt
new file mode 100644
index 0000000000..b665171ddb
--- /dev/null
+++ b/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from coloreditorfactory.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(coloreditorfactory LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(coloreditorfactory
+ colorlisteditor.cpp colorlisteditor.h
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(coloreditorfactory PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS coloreditorfactory
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt b/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt
new file mode 100644
index 0000000000..af806ceb64
--- /dev/null
+++ b/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from combowidgetmapper.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(combowidgetmapper LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(combowidgetmapper
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(combowidgetmapper PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS combowidgetmapper
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt b/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt
new file mode 100644
index 0000000000..c5110ba8b3
--- /dev/null
+++ b/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from customsortfiltermodel.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(customsortfiltermodel LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(customsortfiltermodel
+ customsortfiltermodel.qrc
+ filterwidget.cpp filterwidget.h
+ main.cpp
+ mysortfilterproxymodel.cpp mysortfilterproxymodel.h
+ window.cpp window.h
+)
+target_link_libraries(customsortfiltermodel PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS customsortfiltermodel
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/dirview/CMakeLists.txt b/examples/widgets/itemviews/dirview/CMakeLists.txt
new file mode 100644
index 0000000000..3875436371
--- /dev/null
+++ b/examples/widgets/itemviews/dirview/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from dirview.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(dirview LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(dirview
+ main.cpp
+)
+target_link_libraries(dirview PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS dirview
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt b/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt
new file mode 100644
index 0000000000..c9f46d9e6a
--- /dev/null
+++ b/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from editabletreemodel.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(editabletreemodel LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(editabletreemodel
+ editabletreemodel.qrc
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ treeitem.cpp treeitem.h
+ treemodel.cpp treemodel.h
+)
+target_link_libraries(editabletreemodel PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS editabletreemodel
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/fetchmore/CMakeLists.txt b/examples/widgets/itemviews/fetchmore/CMakeLists.txt
new file mode 100644
index 0000000000..dded651b57
--- /dev/null
+++ b/examples/widgets/itemviews/fetchmore/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from fetchmore.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(fetchmore LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(fetchmore
+ filelistmodel.cpp filelistmodel.h
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(fetchmore PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS fetchmore
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/flattreeview/CMakeLists.txt b/examples/widgets/itemviews/flattreeview/CMakeLists.txt
new file mode 100644
index 0000000000..5f9cd9d77c
--- /dev/null
+++ b/examples/widgets/itemviews/flattreeview/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from flattreeview.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(flattreeview LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(flattreeview
+ main.cpp
+)
+target_link_libraries(flattreeview PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS flattreeview
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/frozencolumn/CMakeLists.txt b/examples/widgets/itemviews/frozencolumn/CMakeLists.txt
new file mode 100644
index 0000000000..8e2db43944
--- /dev/null
+++ b/examples/widgets/itemviews/frozencolumn/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from frozencolumn.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(frozencolumn LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(frozencolumn
+ freezetablewidget.cpp freezetablewidget.h
+ grades.qrc
+ main.cpp
+)
+target_link_libraries(frozencolumn PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS frozencolumn
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/interview/CMakeLists.txt b/examples/widgets/itemviews/interview/CMakeLists.txt
new file mode 100644
index 0000000000..d37ee8fe18
--- /dev/null
+++ b/examples/widgets/itemviews/interview/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from interview.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(interview LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(interview
+ interview.qrc
+ main.cpp
+ model.cpp model.h
+)
+target_link_libraries(interview PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS interview
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/pixelator/CMakeLists.txt b/examples/widgets/itemviews/pixelator/CMakeLists.txt
new file mode 100644
index 0000000000..dbb888a1b2
--- /dev/null
+++ b/examples/widgets/itemviews/pixelator/CMakeLists.txt
@@ -0,0 +1,37 @@
+# Generated from pixelator.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(pixelator LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS PrintSupport) # special case
+
+add_qt_gui_executable(pixelator
+ imagemodel.cpp imagemodel.h
+ images.qrc
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ pixeldelegate.cpp pixeldelegate.h
+)
+target_link_libraries(pixelator PUBLIC
+ Qt::Widgets
+)
+if (TARGET Qt::PrintSupport)
+ target_link_libraries(pixelator PUBLIC
+ Qt::PrintSupport
+ )
+endif()
+
+install(TARGETS pixelator
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/puzzle/CMakeLists.txt b/examples/widgets/itemviews/puzzle/CMakeLists.txt
new file mode 100644
index 0000000000..ed0b4f3f7c
--- /dev/null
+++ b/examples/widgets/itemviews/puzzle/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from puzzle.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(puzzle LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(itemviews_puzzle # special case: renamed puzzle
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ piecesmodel.cpp piecesmodel.h
+ puzzle.qrc
+ puzzlewidget.cpp puzzlewidget.h
+)
+target_link_libraries(itemviews_puzzle PUBLIC # special case: renamed puzzle
+ Qt::Widgets
+)
+
+install(TARGETS itemviews_puzzle # special case: renamed puzzle
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/simpledommodel/CMakeLists.txt b/examples/widgets/itemviews/simpledommodel/CMakeLists.txt
new file mode 100644
index 0000000000..610b7e2ff2
--- /dev/null
+++ b/examples/widgets/itemviews/simpledommodel/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from simpledommodel.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(simpledommodel LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Xml)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(simpledommodel
+ domitem.cpp domitem.h
+ dommodel.cpp dommodel.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(simpledommodel PUBLIC
+ Qt::Widgets
+ Qt::Xml
+)
+
+install(TARGETS simpledommodel
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt b/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt
new file mode 100644
index 0000000000..7a1cafc26e
--- /dev/null
+++ b/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from simpletreemodel.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(simpletreemodel LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(simpletreemodel
+ main.cpp
+ simpletreemodel.qrc
+ treeitem.cpp treeitem.h
+ treemodel.cpp treemodel.h
+)
+target_link_libraries(simpletreemodel PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS simpletreemodel
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt b/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt
new file mode 100644
index 0000000000..367f24235b
--- /dev/null
+++ b/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from simplewidgetmapper.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(simplewidgetmapper LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(simplewidgetmapper
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(simplewidgetmapper PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS simplewidgetmapper
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt b/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt
new file mode 100644
index 0000000000..0c08a1bbba
--- /dev/null
+++ b/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from spinboxdelegate.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(spinboxdelegate LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(spinboxdelegate
+ delegate.cpp delegate.h
+ main.cpp
+)
+target_link_libraries(spinboxdelegate PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS spinboxdelegate
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/spreadsheet/CMakeLists.txt b/examples/widgets/itemviews/spreadsheet/CMakeLists.txt
new file mode 100644
index 0000000000..7916d07a4d
--- /dev/null
+++ b/examples/widgets/itemviews/spreadsheet/CMakeLists.txt
@@ -0,0 +1,37 @@
+# Generated from spreadsheet.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(spreadsheet LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS PrintSupport) # special case
+
+add_qt_gui_executable(spreadsheet
+ main.cpp
+ printview.cpp printview.h
+ spreadsheet.cpp spreadsheet.h spreadsheet.qrc
+ spreadsheetdelegate.cpp spreadsheetdelegate.h
+ spreadsheetitem.cpp spreadsheetitem.h
+)
+target_link_libraries(spreadsheet PUBLIC
+ Qt::Widgets
+)
+# special case begin
+if (TARGET Qt::PrintSupport)
+ target_link_libraries(spreadsheet PUBLIC Qt::PrintSupport)
+endif()
+# special case end
+
+install(TARGETS spreadsheet
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/stardelegate/CMakeLists.txt b/examples/widgets/itemviews/stardelegate/CMakeLists.txt
new file mode 100644
index 0000000000..da3a4a07b4
--- /dev/null
+++ b/examples/widgets/itemviews/stardelegate/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from stardelegate.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(stardelegate LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(stardelegate
+ main.cpp
+ stardelegate.cpp stardelegate.h
+ stareditor.cpp stareditor.h
+ starrating.cpp starrating.h
+)
+target_link_libraries(stardelegate PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS stardelegate
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/itemviews/storageview/CMakeLists.txt b/examples/widgets/itemviews/storageview/CMakeLists.txt
new file mode 100644
index 0000000000..06c8afc932
--- /dev/null
+++ b/examples/widgets/itemviews/storageview/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from storageview.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(storageview LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(storageview
+ main.cpp
+ storagemodel.cpp storagemodel.h
+)
+target_link_libraries(storageview PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+install(TARGETS storageview
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/layouts/CMakeLists.txt b/examples/widgets/layouts/CMakeLists.txt
new file mode 100644
index 0000000000..eaca669248
--- /dev/null
+++ b/examples/widgets/layouts/CMakeLists.txt
@@ -0,0 +1,6 @@
+# Generated from layouts.pro.
+
+add_subdirectory(basiclayouts)
+add_subdirectory(borderlayout)
+add_subdirectory(dynamiclayouts)
+add_subdirectory(flowlayout)
diff --git a/examples/widgets/layouts/basiclayouts/CMakeLists.txt b/examples/widgets/layouts/basiclayouts/CMakeLists.txt
new file mode 100644
index 0000000000..210ad8d7ff
--- /dev/null
+++ b/examples/widgets/layouts/basiclayouts/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from basiclayouts.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(basiclayouts LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(basiclayouts
+ dialog.cpp dialog.h
+ main.cpp
+)
+target_link_libraries(basiclayouts PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS basiclayouts
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/layouts/borderlayout/CMakeLists.txt b/examples/widgets/layouts/borderlayout/CMakeLists.txt
new file mode 100644
index 0000000000..0d1b2e772d
--- /dev/null
+++ b/examples/widgets/layouts/borderlayout/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from borderlayout.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(borderlayout LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(borderlayout
+ borderlayout.cpp borderlayout.h
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(borderlayout PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS borderlayout
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt b/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt
new file mode 100644
index 0000000000..65fe32f181
--- /dev/null
+++ b/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from dynamiclayouts.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(dynamiclayouts LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(dynamiclayouts
+ dialog.cpp dialog.h
+ main.cpp
+)
+target_link_libraries(dynamiclayouts PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS dynamiclayouts
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/layouts/flowlayout/CMakeLists.txt b/examples/widgets/layouts/flowlayout/CMakeLists.txt
new file mode 100644
index 0000000000..fff6fa004b
--- /dev/null
+++ b/examples/widgets/layouts/flowlayout/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from flowlayout.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(flowlayout LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(flowlayout
+ flowlayout.cpp flowlayout.h
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(flowlayout PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS flowlayout
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/mac/CMakeLists.txt b/examples/widgets/mac/CMakeLists.txt
new file mode 100644
index 0000000000..82038acfae
--- /dev/null
+++ b/examples/widgets/mac/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from mac.pro.
+
+
+if(APPLE_OSX)
+ add_subdirectory(qmaccocoaviewcontainer)
+ add_subdirectory(qmacnativewidget)
+endif()
diff --git a/examples/widgets/mac/qmaccocoaviewcontainer/CMakeLists.txt b/examples/widgets/mac/qmaccocoaviewcontainer/CMakeLists.txt
new file mode 100644
index 0000000000..7aece18580
--- /dev/null
+++ b/examples/widgets/mac/qmaccocoaviewcontainer/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from qmaccocoaviewcontainer.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(qmaccocoaviewcontainer LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(qmaccocoaviewcontainer
+ main.mm
+)
+target_link_libraries(qmaccocoaviewcontainer PUBLIC
+ ${FWAppKit}
+ Qt::Widgets
+)
+
+install(TARGETS qmaccocoaviewcontainer
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/mac/qmacnativewidget/CMakeLists.txt b/examples/widgets/mac/qmacnativewidget/CMakeLists.txt
new file mode 100644
index 0000000000..f7d3ba6431
--- /dev/null
+++ b/examples/widgets/mac/qmacnativewidget/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from qmacnativewidget.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(qmacnativewidget LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(qmacnativewidget
+ main.mm
+)
+target_link_libraries(qmacnativewidget PUBLIC
+ ${FWAppKit}
+ Qt::Widgets
+)
+
+install(TARGETS qmacnativewidget
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/mainwindows/CMakeLists.txt b/examples/widgets/mainwindows/CMakeLists.txt
new file mode 100644
index 0000000000..8bb5f52f92
--- /dev/null
+++ b/examples/widgets/mainwindows/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from mainwindows.pro.
+
+add_subdirectory(application)
+add_subdirectory(dockwidgets)
+add_subdirectory(mainwindow)
+add_subdirectory(mdi)
+add_subdirectory(menus)
+add_subdirectory(sdi)
diff --git a/examples/widgets/mainwindows/application/CMakeLists.txt b/examples/widgets/mainwindows/application/CMakeLists.txt
new file mode 100644
index 0000000000..a59270e824
--- /dev/null
+++ b/examples/widgets/mainwindows/application/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from application.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(application LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(application
+ application.qrc
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(application PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS application
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt b/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt
new file mode 100644
index 0000000000..5a58d3b7f7
--- /dev/null
+++ b/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from dockwidgets.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(dockwidgets LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS PrintSupport) # special case
+
+add_qt_gui_executable(dockwidgets
+ dockwidgets.qrc
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(dockwidgets PUBLIC
+ Qt::Widgets
+)
+# special case begin
+if (TARGET Qt::PrintSupport)
+ target_link_libraries(dockwidgets PUBLIC Qt::PrintSupport)
+endif()
+# special case end
+
+install(TARGETS dockwidgets
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/mainwindows/mainwindow/CMakeLists.txt b/examples/widgets/mainwindows/mainwindow/CMakeLists.txt
new file mode 100644
index 0000000000..f4f8bdb4ca
--- /dev/null
+++ b/examples/widgets/mainwindows/mainwindow/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from mainwindow.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mainwindow LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(mainwindow
+ colorswatch.cpp colorswatch.h
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.qrc
+ toolbar.cpp toolbar.h
+)
+target_link_libraries(mainwindow PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS mainwindow
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/mainwindows/mdi/CMakeLists.txt b/examples/widgets/mainwindows/mdi/CMakeLists.txt
new file mode 100644
index 0000000000..ef5100b998
--- /dev/null
+++ b/examples/widgets/mainwindows/mdi/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from mdi.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mdi LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(mdi
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ mdi.qrc
+ mdichild.cpp mdichild.h
+)
+target_link_libraries(mdi PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS mdi
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/mainwindows/menus/CMakeLists.txt b/examples/widgets/mainwindows/menus/CMakeLists.txt
new file mode 100644
index 0000000000..ee3123423b
--- /dev/null
+++ b/examples/widgets/mainwindows/menus/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from menus.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(menus LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(menus
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(menus PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS menus
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/mainwindows/sdi/CMakeLists.txt b/examples/widgets/mainwindows/sdi/CMakeLists.txt
new file mode 100644
index 0000000000..7e737d0eb1
--- /dev/null
+++ b/examples/widgets/mainwindows/sdi/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from sdi.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(sdi LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(sdi
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ sdi.qrc
+)
+target_link_libraries(sdi PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS sdi
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/painting/CMakeLists.txt b/examples/widgets/painting/CMakeLists.txt
new file mode 100644
index 0000000000..e7d612da3b
--- /dev/null
+++ b/examples/widgets/painting/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from painting.pro.
+
+add_subdirectory(shared) # special case
+add_subdirectory(basicdrawing)
+add_subdirectory(concentriccircles)
+add_subdirectory(affine)
+# add_subdirectory(composition) # FIXME: Seems buggy wrt. usesOpenGL function
+add_subdirectory(deform)
+add_subdirectory(gradients)
+add_subdirectory(pathstroke)
+add_subdirectory(imagecomposition)
+add_subdirectory(painterpaths)
+add_subdirectory(transformations)
+add_subdirectory(fontsampler)
diff --git a/examples/widgets/painting/affine/CMakeLists.txt b/examples/widgets/painting/affine/CMakeLists.txt
new file mode 100644
index 0000000000..f526cffb77
--- /dev/null
+++ b/examples/widgets/painting/affine/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from affine.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(affine LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(affine
+ # special case: remove files from ../shared
+ affine.qrc
+ main.cpp
+ xform.cpp xform.h
+)
+target_include_directories(affine PUBLIC
+ ../shared
+)
+target_link_libraries(affine PUBLIC
+ Qt::Widgets
+ painting_shared # special case
+)
+
+install(TARGETS affine
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/painting/basicdrawing/CMakeLists.txt b/examples/widgets/painting/basicdrawing/CMakeLists.txt
new file mode 100644
index 0000000000..cee7e48052
--- /dev/null
+++ b/examples/widgets/painting/basicdrawing/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from basicdrawing.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(basicdrawing LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(basicdrawing
+ basicdrawing.qrc
+ main.cpp
+ renderarea.cpp renderarea.h
+ window.cpp window.h
+)
+target_link_libraries(basicdrawing PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS basicdrawing
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/painting/composition/CMakeLists.txt b/examples/widgets/painting/composition/CMakeLists.txt
new file mode 100644
index 0000000000..b971f32052
--- /dev/null
+++ b/examples/widgets/painting/composition/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from composition.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(composition LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(composition
+ # special case: remove files from ../shared
+ composition.cpp composition.h composition.qrc
+ main.cpp
+)
+target_include_directories(composition PUBLIC
+ ../shared
+)
+target_link_libraries(composition PUBLIC
+ Qt::Widgets
+ painting_shared # special case
+)
+
+install(TARGETS composition
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/painting/concentriccircles/CMakeLists.txt b/examples/widgets/painting/concentriccircles/CMakeLists.txt
new file mode 100644
index 0000000000..d01d7db607
--- /dev/null
+++ b/examples/widgets/painting/concentriccircles/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from concentriccircles.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(concentriccircles LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(concentriccircles
+ circlewidget.cpp circlewidget.h
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(concentriccircles PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS concentriccircles
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/painting/deform/CMakeLists.txt b/examples/widgets/painting/deform/CMakeLists.txt
new file mode 100644
index 0000000000..d3ce6bb06d
--- /dev/null
+++ b/examples/widgets/painting/deform/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from deform.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(deform LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(deform
+ # special case: remove files from ../shared
+ deform.qrc
+ main.cpp
+ pathdeform.cpp pathdeform.h
+)
+target_include_directories(deform PUBLIC
+ ../shared
+)
+target_link_libraries(deform PUBLIC
+ Qt::Widgets
+ painting_shared # special case
+)
+
+install(TARGETS deform
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/painting/fontsampler/CMakeLists.txt b/examples/widgets/painting/fontsampler/CMakeLists.txt
new file mode 100644
index 0000000000..701512198c
--- /dev/null
+++ b/examples/widgets/painting/fontsampler/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from fontsampler.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(fontsampler LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(fontsampler
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ mainwindowbase.ui
+)
+target_link_libraries(fontsampler PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS fontsampler
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/painting/gradients/CMakeLists.txt b/examples/widgets/painting/gradients/CMakeLists.txt
new file mode 100644
index 0000000000..c0f1924e33
--- /dev/null
+++ b/examples/widgets/painting/gradients/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from gradients.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(gradients LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(gradients
+ # special case: remove files from ../shared
+ gradients.cpp gradients.h gradients.qrc
+ main.cpp
+)
+target_include_directories(gradients PUBLIC
+ ../shared
+)
+target_link_libraries(gradients PUBLIC
+ Qt::Widgets
+ painting_shared # special case
+)
+
+install(TARGETS gradients
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/painting/imagecomposition/CMakeLists.txt b/examples/widgets/painting/imagecomposition/CMakeLists.txt
new file mode 100644
index 0000000000..f6ff7eb2e5
--- /dev/null
+++ b/examples/widgets/painting/imagecomposition/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from imagecomposition.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(imagecomposition LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(imagecomposition
+ imagecomposer.cpp imagecomposer.h
+ imagecomposition.qrc
+ main.cpp
+)
+target_link_libraries(imagecomposition PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS imagecomposition
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/painting/painterpaths/CMakeLists.txt b/examples/widgets/painting/painterpaths/CMakeLists.txt
new file mode 100644
index 0000000000..0631f5ed01
--- /dev/null
+++ b/examples/widgets/painting/painterpaths/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from painterpaths.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(painterpaths LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(painterpaths
+ main.cpp
+ renderarea.cpp renderarea.h
+ window.cpp window.h
+)
+target_link_libraries(painterpaths PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS painterpaths
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/painting/pathstroke/CMakeLists.txt b/examples/widgets/painting/pathstroke/CMakeLists.txt
new file mode 100644
index 0000000000..27f18bb848
--- /dev/null
+++ b/examples/widgets/painting/pathstroke/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from pathstroke.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(pathstroke LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(pathstroke
+ ../shared/arthurstyle.cpp ../shared/arthurstyle.h
+ ../shared/arthurwidgets.cpp ../shared/arthurwidgets.h
+ ../shared/hoverpoints.cpp ../shared/hoverpoints.h
+ ../shared/shared.qrc
+ main.cpp
+ pathstroke.cpp pathstroke.h pathstroke.qrc
+)
+target_include_directories(pathstroke PUBLIC
+ ../shared
+)
+target_link_libraries(pathstroke PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS pathstroke
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/painting/shared/CMakeLists.txt b/examples/widgets/painting/shared/CMakeLists.txt
new file mode 100644
index 0000000000..4b873962a6
--- /dev/null
+++ b/examples/widgets/painting/shared/CMakeLists.txt
@@ -0,0 +1,27 @@
+# special case: Entire file!
+
+# special case:
+add_library(painting_shared OBJECT)
+qt6_wrap_cpp(moc_files arthurwidgets.h hoverpoints.h) # no automoc for OBJECT libs:-/
+target_sources(painting_shared PRIVATE
+ arthurstyle.cpp arthurstyle.h
+ arthurwidgets.cpp arthurwidgets.h
+ hoverpoints.cpp hoverpoints.h
+ ${moc_files}
+)
+target_link_libraries(painting_shared PUBLIC Qt::Widgets)
+target_include_directories(painting_shared PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}")
+
+qt6_add_resources(res_files shared.qrc)
+target_sources(painting_shared PRIVATE ${res_files})
+
+## Scopes:
+#####################################################################
+
+if (TARGET Qt::OpenGL OR QT_FEATURE_opengles2)
+ target_compile_definitions(painting_shared PRIVATE QT_OPENGL_SUPPORT)
+ target_link_libraries(painting_shared PRIVATE
+ Qt::OpenGL
+ Qt::Widgets
+ )
+endif()
diff --git a/examples/widgets/painting/transformations/CMakeLists.txt b/examples/widgets/painting/transformations/CMakeLists.txt
new file mode 100644
index 0000000000..af50385877
--- /dev/null
+++ b/examples/widgets/painting/transformations/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from transformations.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(transformations LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(transformations
+ main.cpp
+ renderarea.cpp renderarea.h
+ window.cpp window.h
+)
+target_link_libraries(transformations PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS transformations
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/richtext/CMakeLists.txt b/examples/widgets/richtext/CMakeLists.txt
new file mode 100644
index 0000000000..adb98e38f9
--- /dev/null
+++ b/examples/widgets/richtext/CMakeLists.txt
@@ -0,0 +1,6 @@
+# Generated from richtext.pro.
+
+add_subdirectory(calendar)
+add_subdirectory(orderform)
+add_subdirectory(syntaxhighlighter)
+add_subdirectory(textedit)
diff --git a/examples/widgets/richtext/calendar/CMakeLists.txt b/examples/widgets/richtext/calendar/CMakeLists.txt
new file mode 100644
index 0000000000..c09ebe5895
--- /dev/null
+++ b/examples/widgets/richtext/calendar/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from calendar.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(calendar LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(calendar
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(calendar PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS calendar
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/richtext/orderform/CMakeLists.txt b/examples/widgets/richtext/orderform/CMakeLists.txt
new file mode 100644
index 0000000000..58dae9ee5d
--- /dev/null
+++ b/examples/widgets/richtext/orderform/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from orderform.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(orderform LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS PrintSupport)
+
+add_qt_gui_executable(orderform
+ detailsdialog.cpp detailsdialog.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(orderform PUBLIC
+ Qt::Widgets
+)
+if (TARGET Qt::PrintSupport)
+ target_link_libraries(orderform PUBLIC Qt::PrintSupport)
+endif()
+
+install(TARGETS orderform
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt b/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt
new file mode 100644
index 0000000000..fb06e038ec
--- /dev/null
+++ b/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from syntaxhighlighter.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(syntaxhighlighter LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(syntaxhighlighter
+ highlighter.cpp highlighter.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(syntaxhighlighter PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS syntaxhighlighter
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/richtext/textedit/CMakeLists.txt b/examples/widgets/richtext/textedit/CMakeLists.txt
new file mode 100644
index 0000000000..4e63898264
--- /dev/null
+++ b/examples/widgets/richtext/textedit/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from textedit.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(textedit LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS PrintSupport) # special case
+
+add_qt_gui_executable(textedit
+ main.cpp
+ textedit.cpp textedit.h textedit.qrc
+)
+target_link_libraries(textedit PUBLIC
+ Qt::Widgets
+)
+# special case begin
+if (TARGET Qt::PrintSupport)
+ target_link_libraries(textedit PUBLIC Qt::PrintSupport)
+endif()
+# special case end
+
+install(TARGETS textedit
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/scroller/CMakeLists.txt b/examples/widgets/scroller/CMakeLists.txt
new file mode 100644
index 0000000000..f663cd9890
--- /dev/null
+++ b/examples/widgets/scroller/CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from scroller.pro.
+
+add_subdirectory(graphicsview)
diff --git a/examples/widgets/scroller/graphicsview/CMakeLists.txt b/examples/widgets/scroller/graphicsview/CMakeLists.txt
new file mode 100644
index 0000000000..599d865b65
--- /dev/null
+++ b/examples/widgets/scroller/graphicsview/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from graphicsview.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(graphicsview LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(graphicsview
+ main.cpp
+)
+target_link_libraries(graphicsview PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS graphicsview
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/statemachine/CMakeLists.txt b/examples/widgets/statemachine/CMakeLists.txt
new file mode 100644
index 0000000000..8527fcbc69
--- /dev/null
+++ b/examples/widgets/statemachine/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from statemachine.pro.
+
+add_subdirectory(factorial)
+add_subdirectory(pingpong)
+
+if(TARGET Qt::Widgets)
+ add_subdirectory(eventtransitions)
+ add_subdirectory(rogue)
+ add_subdirectory(trafficlight)
+ add_subdirectory(twowaybutton)
+endif()
diff --git a/examples/widgets/statemachine/eventtransitions/CMakeLists.txt b/examples/widgets/statemachine/eventtransitions/CMakeLists.txt
new file mode 100644
index 0000000000..244ee89f67
--- /dev/null
+++ b/examples/widgets/statemachine/eventtransitions/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from eventtransitions.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(eventtransitions LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(eventtransitions
+ main.cpp
+)
+target_link_libraries(eventtransitions PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS eventtransitions
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/statemachine/factorial/CMakeLists.txt b/examples/widgets/statemachine/factorial/CMakeLists.txt
new file mode 100644
index 0000000000..55dc15cd38
--- /dev/null
+++ b/examples/widgets/statemachine/factorial/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from factorial.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(factorial LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+
+add_executable(factorial
+ main.cpp
+)
+target_link_libraries(factorial PUBLIC
+ Qt::Core
+)
+
+install(TARGETS factorial
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/statemachine/pingpong/CMakeLists.txt b/examples/widgets/statemachine/pingpong/CMakeLists.txt
new file mode 100644
index 0000000000..4104635b59
--- /dev/null
+++ b/examples/widgets/statemachine/pingpong/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from pingpong.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(pingpong LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+
+add_executable(pingpong
+ main.cpp
+)
+target_link_libraries(pingpong PUBLIC
+ Qt::Core
+)
+
+install(TARGETS pingpong
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/statemachine/rogue/CMakeLists.txt b/examples/widgets/statemachine/rogue/CMakeLists.txt
new file mode 100644
index 0000000000..25d69a8ce9
--- /dev/null
+++ b/examples/widgets/statemachine/rogue/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from rogue.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(rogue LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(rogue
+ main.cpp
+ movementtransition.h
+ window.cpp window.h
+)
+target_link_libraries(rogue PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS rogue
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/statemachine/trafficlight/CMakeLists.txt b/examples/widgets/statemachine/trafficlight/CMakeLists.txt
new file mode 100644
index 0000000000..c89fec5db1
--- /dev/null
+++ b/examples/widgets/statemachine/trafficlight/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from trafficlight.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(trafficlight LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(trafficlight
+ main.cpp
+)
+target_link_libraries(trafficlight PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS trafficlight
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/statemachine/twowaybutton/CMakeLists.txt b/examples/widgets/statemachine/twowaybutton/CMakeLists.txt
new file mode 100644
index 0000000000..8402fd2f12
--- /dev/null
+++ b/examples/widgets/statemachine/twowaybutton/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from twowaybutton.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(twowaybutton LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(twowaybutton
+ main.cpp
+)
+target_link_libraries(twowaybutton PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS twowaybutton
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tools/CMakeLists.txt b/examples/widgets/tools/CMakeLists.txt
new file mode 100644
index 0000000000..042f751b0f
--- /dev/null
+++ b/examples/widgets/tools/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from tools.pro.
+
+add_subdirectory(codecs)
+add_subdirectory(completer)
+add_subdirectory(customcompleter)
+if(QT_FEATURE_translation) # special case
+ add_subdirectory(i18n)
+endif()
+add_subdirectory(regexp)
+add_subdirectory(regularexpression)
+add_subdirectory(settingseditor)
+add_subdirectory(styleplugin)
+add_subdirectory(treemodelcompleter)
+add_subdirectory(undo)
+add_subdirectory(undoframework)
+
+if(QT_FEATURE_library) # special case
+ add_subdirectory(echoplugin)
+ # FIXME: Currently broken # special case
+ # Fails to link (ld: error: undefined symbol: qt_static_plugin_BasicToolsPlugin()) # special case
+ #add_subdirectory(plugandpaint) # special case
+endif()
diff --git a/examples/widgets/tools/codecs/CMakeLists.txt b/examples/widgets/tools/codecs/CMakeLists.txt
new file mode 100644
index 0000000000..ed0a303835
--- /dev/null
+++ b/examples/widgets/tools/codecs/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from codecs.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(codecs LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(codecs
+ codecs.qrc
+ encodingdialog.cpp encodingdialog.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ previewform.cpp previewform.h
+)
+target_link_libraries(codecs PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS codecs
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tools/completer/CMakeLists.txt b/examples/widgets/tools/completer/CMakeLists.txt
new file mode 100644
index 0000000000..f5df74ffc8
--- /dev/null
+++ b/examples/widgets/tools/completer/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from completer.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(completer LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(completer
+ completer.qrc
+ fsmodel.cpp fsmodel.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(completer PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS completer
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tools/customcompleter/CMakeLists.txt b/examples/widgets/tools/customcompleter/CMakeLists.txt
new file mode 100644
index 0000000000..06b21fcf5b
--- /dev/null
+++ b/examples/widgets/tools/customcompleter/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from customcompleter.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(customcompleter LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(customcompleter
+ customcompleter.qrc
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ textedit.cpp textedit.h
+)
+target_link_libraries(customcompleter PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS customcompleter
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tools/echoplugin/CMakeLists.txt b/examples/widgets/tools/echoplugin/CMakeLists.txt
new file mode 100644
index 0000000000..b848e08e72
--- /dev/null
+++ b/examples/widgets/tools/echoplugin/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from echoplugin.pro.
+
+add_subdirectory(echowindow)
+add_subdirectory(plugin)
diff --git a/examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt b/examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt
new file mode 100644
index 0000000000..959dc7ad0a
--- /dev/null
+++ b/examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from echowindow.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(echoplugin LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(echopluginwindow # special case: renamed target
+ echointerface.h
+ echowindow.cpp echowindow.h
+ main.cpp
+)
+target_link_libraries(echopluginwindow PUBLIC # special case: renamed target
+ Qt::Widgets
+)
+
+install(TARGETS echopluginwindow # special case: renamed target
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt b/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt
new file mode 100644
index 0000000000..78f5dcbe70
--- /dev/null
+++ b/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt
@@ -0,0 +1,10 @@
+# special case begin
+
+add_library(echoplugin MODULE
+ echoplugin.cpp echoplugin.h
+)
+
+target_include_directories(echoplugin PUBLIC ../echowindow)
+target_link_libraries(echoplugin PUBLIC Qt::Widgets)
+
+# special case end
diff --git a/examples/widgets/tools/i18n/CMakeLists.txt b/examples/widgets/tools/i18n/CMakeLists.txt
new file mode 100644
index 0000000000..24759b6d01
--- /dev/null
+++ b/examples/widgets/tools/i18n/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from i18n.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(i18n LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(i18n
+ i18n.qrc
+ languagechooser.cpp languagechooser.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(i18n PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS i18n
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tools/plugandpaint/CMakeLists.txt b/examples/widgets/tools/plugandpaint/CMakeLists.txt
new file mode 100644
index 0000000000..2bde4718b2
--- /dev/null
+++ b/examples/widgets/tools/plugandpaint/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from plugandpaint.pro.
+
+add_subdirectory(plugins)
+add_subdirectory(app)
diff --git a/examples/widgets/tools/plugandpaint/app/CMakeLists.txt b/examples/widgets/tools/plugandpaint/app/CMakeLists.txt
new file mode 100644
index 0000000000..8d7f931996
--- /dev/null
+++ b/examples/widgets/tools/plugandpaint/app/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from app.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(plugandpaint LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(plugandpaint
+ interfaces.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ paintarea.cpp paintarea.h
+ plugindialog.cpp plugindialog.h
+)
+target_link_libraries(plugandpaint PUBLIC
+ # Remove: L../plugins
+ Qt::Widgets
+ pnp_basictools # special case
+)
+target_link_libraries(plugandpaint PUBLIC pnp_basictools) # special case
+
+install(TARGETS plugandpaint
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tools/plugandpaint/plugins/CMakeLists.txt b/examples/widgets/tools/plugandpaint/plugins/CMakeLists.txt
new file mode 100644
index 0000000000..1e63da97ca
--- /dev/null
+++ b/examples/widgets/tools/plugandpaint/plugins/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from plugins.pro.
+
+add_subdirectory(basictools)
+add_subdirectory(extrafilters)
diff --git a/examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt b/examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt
new file mode 100644
index 0000000000..64d239b054
--- /dev/null
+++ b/examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt
@@ -0,0 +1,13 @@
+# special case begin
+
+add_library(pnp_basictools MODULE STATIC
+ basictoolsplugin.cpp basictoolsplugin.h
+)
+set_target_properties(pnp_basictools PROPERTIES
+ LIBRARY_OUTPUT_DIRECTORY "../../plugins"
+ RUNTIME_OUTPUT_DIRECTORY "../../plugins"
+)
+target_include_directories(pnp_basictools PUBLIC ../../app)
+target_link_libraries(pnp_basictools PUBLIC Qt::Widgets)
+
+# special case end
diff --git a/examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt b/examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt
new file mode 100644
index 0000000000..31d6f5ef65
--- /dev/null
+++ b/examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt
@@ -0,0 +1,9 @@
+# special case begin
+
+add_library(pnp_extrafilters_plugin MODULE
+ extrafiltersplugin.cpp extrafiltersplugin.h
+)
+target_include_directories(pnp_extrafilters_plugin PRIVATE ../../app)
+target_link_libraries(pnp_extrafilters_plugin PRIVATE Qt::Widgets)
+
+# special case end
diff --git a/examples/widgets/tools/regexp/CMakeLists.txt b/examples/widgets/tools/regexp/CMakeLists.txt
new file mode 100644
index 0000000000..52fc49a084
--- /dev/null
+++ b/examples/widgets/tools/regexp/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from regexp.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(regexp LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(regexp
+ main.cpp
+ regexpdialog.cpp regexpdialog.h
+)
+target_link_libraries(regexp PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS regexp
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tools/regularexpression/CMakeLists.txt b/examples/widgets/tools/regularexpression/CMakeLists.txt
new file mode 100644
index 0000000000..6b18721801
--- /dev/null
+++ b/examples/widgets/tools/regularexpression/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from regularexpression.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(regularexpression LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(regularexpression
+ main.cpp
+ regularexpression.qrc
+ regularexpressiondialog.cpp regularexpressiondialog.h
+)
+target_link_libraries(regularexpression PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS regularexpression
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tools/settingseditor/CMakeLists.txt b/examples/widgets/tools/settingseditor/CMakeLists.txt
new file mode 100644
index 0000000000..28a842c493
--- /dev/null
+++ b/examples/widgets/tools/settingseditor/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from settingseditor.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(settingseditor LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(settingseditor
+ locationdialog.cpp locationdialog.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ settingstree.cpp settingstree.h
+ variantdelegate.cpp variantdelegate.h
+)
+target_link_libraries(settingseditor PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS settingseditor
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tools/styleplugin/CMakeLists.txt b/examples/widgets/tools/styleplugin/CMakeLists.txt
new file mode 100644
index 0000000000..af10d38700
--- /dev/null
+++ b/examples/widgets/tools/styleplugin/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from styleplugin.pro.
+
+# special case begin
+cmake_minimum_required(VERSION 3.14)
+project(styleplugin LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+# special case end
+
+add_subdirectory(stylewindow)
+add_subdirectory(plugin)
diff --git a/examples/widgets/tools/styleplugin/plugin/CMakeLists.txt b/examples/widgets/tools/styleplugin/plugin/CMakeLists.txt
new file mode 100644
index 0000000000..28c6ec07ab
--- /dev/null
+++ b/examples/widgets/tools/styleplugin/plugin/CMakeLists.txt
@@ -0,0 +1,9 @@
+# special case begin
+
+add_library(simplestyleplugin MODULE
+ simplestyle.cpp simplestyle.h
+ simplestyleplugin.cpp simplestyleplugin.h
+)
+target_link_libraries(simplestyleplugin PUBLIC Qt::Widgets)
+
+# special case end
diff --git a/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt b/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt
new file mode 100644
index 0000000000..381419a49c
--- /dev/null
+++ b/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from stylewindow.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(styleplugin LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(styleplugin
+ main.cpp
+ stylewindow.cpp stylewindow.h
+)
+target_link_libraries(styleplugin PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS styleplugin
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tools/treemodelcompleter/CMakeLists.txt b/examples/widgets/tools/treemodelcompleter/CMakeLists.txt
new file mode 100644
index 0000000000..367cddaaf3
--- /dev/null
+++ b/examples/widgets/tools/treemodelcompleter/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from treemodelcompleter.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(treemodelcompleter LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(treemodelcompleter
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ treemodelcompleter.cpp treemodelcompleter.h treemodelcompleter.qrc
+)
+target_link_libraries(treemodelcompleter PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS treemodelcompleter
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tools/undo/CMakeLists.txt b/examples/widgets/tools/undo/CMakeLists.txt
new file mode 100644
index 0000000000..94df672b96
--- /dev/null
+++ b/examples/widgets/tools/undo/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from undo.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(undo LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(undo
+ commands.cpp commands.h
+ document.cpp document.h
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ undo.qrc
+)
+target_link_libraries(undo PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS undo
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tools/undoframework/CMakeLists.txt b/examples/widgets/tools/undoframework/CMakeLists.txt
new file mode 100644
index 0000000000..0ccf52e7ad
--- /dev/null
+++ b/examples/widgets/tools/undoframework/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from undoframework.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(undoframework LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(undoframework
+ commands.cpp commands.h
+ diagramitem.cpp diagramitem.h
+ diagramscene.cpp diagramscene.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ undoframework.qrc
+)
+target_link_libraries(undoframework PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS undoframework
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/touch/CMakeLists.txt b/examples/widgets/touch/CMakeLists.txt
new file mode 100644
index 0000000000..06b72cada7
--- /dev/null
+++ b/examples/widgets/touch/CMakeLists.txt
@@ -0,0 +1,6 @@
+# Generated from touch.pro.
+
+add_subdirectory(pinchzoom)
+add_subdirectory(fingerpaint)
+add_subdirectory(knobs)
+add_subdirectory(dials)
diff --git a/examples/widgets/touch/dials/CMakeLists.txt b/examples/widgets/touch/dials/CMakeLists.txt
new file mode 100644
index 0000000000..638302a8ac
--- /dev/null
+++ b/examples/widgets/touch/dials/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from dials.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(dials LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(dials
+ dials.ui
+ main.cpp
+)
+target_link_libraries(dials PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS dials
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/touch/fingerpaint/CMakeLists.txt b/examples/widgets/touch/fingerpaint/CMakeLists.txt
new file mode 100644
index 0000000000..25b5c706e6
--- /dev/null
+++ b/examples/widgets/touch/fingerpaint/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from fingerpaint.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(fingerpaint LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS PrintSupport) # special case
+
+add_qt_gui_executable(fingerpaint
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ scribblearea.cpp scribblearea.h
+)
+target_link_libraries(fingerpaint PUBLIC
+ Qt::Widgets
+)
+# special case begin
+if (TARGET Qt::PrintSupport)
+ target_link_libraries(fingerpaint PUBLIC Qt::PrintSupport)
+endif()
+# special case end
+
+install(TARGETS fingerpaint
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/touch/knobs/CMakeLists.txt b/examples/widgets/touch/knobs/CMakeLists.txt
new file mode 100644
index 0000000000..a1eacb4766
--- /dev/null
+++ b/examples/widgets/touch/knobs/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from knobs.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(knobs LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(knobs
+ knob.cpp knob.h
+ main.cpp
+)
+target_link_libraries(knobs PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS knobs
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/touch/pinchzoom/CMakeLists.txt b/examples/widgets/touch/pinchzoom/CMakeLists.txt
new file mode 100644
index 0000000000..b14056ade5
--- /dev/null
+++ b/examples/widgets/touch/pinchzoom/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from pinchzoom.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(pinchzoom LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(pinchzoom
+ graphicsview.cpp graphicsview.h
+ main.cpp
+ mice.qrc
+ mouse.cpp mouse.h
+)
+target_link_libraries(pinchzoom PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS pinchzoom
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/CMakeLists.txt b/examples/widgets/tutorials/CMakeLists.txt
new file mode 100644
index 0000000000..c2fa4a81d7
--- /dev/null
+++ b/examples/widgets/tutorials/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from tutorials.pro.
+
+add_subdirectory(addressbook)
+add_subdirectory(widgets)
+add_subdirectory(modelview)
+add_subdirectory(gettingStarted)
+add_subdirectory(notepad)
diff --git a/examples/widgets/tutorials/addressbook/CMakeLists.txt b/examples/widgets/tutorials/addressbook/CMakeLists.txt
new file mode 100644
index 0000000000..a8823d059a
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/CMakeLists.txt
@@ -0,0 +1,9 @@
+# Generated from addressbook.pro.
+
+add_subdirectory(part1)
+add_subdirectory(part2)
+add_subdirectory(part3)
+add_subdirectory(part4)
+add_subdirectory(part5)
+add_subdirectory(part6)
+add_subdirectory(part7)
diff --git a/examples/widgets/tutorials/addressbook/part1/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part1/CMakeLists.txt
new file mode 100644
index 0000000000..74e9d98418
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part1/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from part1.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(part1 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(part1
+ addressbook.cpp addressbook.h
+ main.cpp
+)
+target_link_libraries(part1 PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS part1
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt
new file mode 100644
index 0000000000..dd7c53170e
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from part2.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(part2 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(part2
+ addressbook.cpp addressbook.h
+ main.cpp
+)
+target_link_libraries(part2 PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS part2
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt
new file mode 100644
index 0000000000..f1923a9947
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from part3.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(part3 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(part3
+ addressbook.cpp addressbook.h
+ main.cpp
+)
+target_link_libraries(part3 PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS part3
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt
new file mode 100644
index 0000000000..fd6ec7d4e7
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from part4.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(part4 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(part4
+ addressbook.cpp addressbook.h
+ main.cpp
+)
+target_link_libraries(part4 PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS part4
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt
new file mode 100644
index 0000000000..84f7bd607a
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from part5.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(part5 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(part5
+ addressbook.cpp addressbook.h
+ finddialog.cpp finddialog.h
+ main.cpp
+)
+target_link_libraries(part5 PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS part5
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt
new file mode 100644
index 0000000000..172a8157a8
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from part6.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(part6 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(part6
+ addressbook.cpp addressbook.h
+ finddialog.cpp finddialog.h
+ main.cpp
+)
+target_link_libraries(part6 PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS part6
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt
new file mode 100644
index 0000000000..f420ebeff7
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from part7.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(part7 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(part7
+ addressbook.cpp addressbook.h
+ finddialog.cpp finddialog.h
+ main.cpp
+)
+target_link_libraries(part7 PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS part7
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/gettingStarted/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/CMakeLists.txt
new file mode 100644
index 0000000000..2aa8163029
--- /dev/null
+++ b/examples/widgets/tutorials/gettingStarted/CMakeLists.txt
@@ -0,0 +1,2 @@
+# Generated from gettingStarted.pro.
+
diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/CMakeLists.txt
new file mode 100644
index 0000000000..7a9ade8511
--- /dev/null
+++ b/examples/widgets/tutorials/gettingStarted/gsQt/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from gsqt.pro.
+
+add_subdirectory(part1)
+add_subdirectory(part2)
+add_subdirectory(part3)
+add_subdirectory(part4)
+add_subdirectory(part5)
diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt
new file mode 100644
index 0000000000..c47d130e3b
--- /dev/null
+++ b/examples/widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from part1.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(part1 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(part1
+ main.cpp
+)
+target_link_libraries(part1 PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS part1
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt
new file mode 100644
index 0000000000..024fc717d4
--- /dev/null
+++ b/examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from part2.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(part2 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(part2
+ main.cpp
+)
+target_link_libraries(part2 PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS part2
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt
new file mode 100644
index 0000000000..886598c11f
--- /dev/null
+++ b/examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from part3.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(part3 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(part3
+ main.cpp
+)
+target_link_libraries(part3 PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS part3
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt
new file mode 100644
index 0000000000..e4a532ca37
--- /dev/null
+++ b/examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from part4.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(part4 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(part4
+ main.cpp
+)
+target_link_libraries(part4 PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS part4
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt
new file mode 100644
index 0000000000..1b118f50e9
--- /dev/null
+++ b/examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from part5.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(part5 LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(part5
+ main.cpp
+)
+target_link_libraries(part5 PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS part5
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt b/examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt
new file mode 100644
index 0000000000..8c35a4027d
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from 1_readonly.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mv_readonly LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(mv_readonly
+ main.cpp
+ mymodel.cpp mymodel.h
+)
+target_link_libraries(mv_readonly PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS mv_readonly
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt b/examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt
new file mode 100644
index 0000000000..8a872c928f
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from 2_formatting.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mv_formatting LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(mv_formatting
+ main.cpp
+ mymodel.cpp mymodel.h
+)
+target_link_libraries(mv_formatting PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS mv_formatting
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt b/examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt
new file mode 100644
index 0000000000..04939138fa
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from 3_changingmodel.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mv_changingmodel LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(mv_changingmodel
+ main.cpp
+ mymodel.cpp mymodel.h
+)
+target_link_libraries(mv_changingmodel PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS mv_changingmodel
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt b/examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt
new file mode 100644
index 0000000000..f4f9b7ae84
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from 4_headers.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mv_headers LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(mv_headers
+ main.cpp
+ mymodel.cpp mymodel.h
+)
+target_link_libraries(mv_headers PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS mv_headers
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt b/examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt
new file mode 100644
index 0000000000..1f70f4a0bf
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from 5_edit.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mv_edit LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(mv_edit
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ mymodel.cpp mymodel.h
+)
+target_link_libraries(mv_edit PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS mv_edit
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt b/examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt
new file mode 100644
index 0000000000..9300b9e837
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from 6_treeview.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mv_tree LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(mv_tree
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(mv_tree PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS mv_tree
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt b/examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt
new file mode 100644
index 0000000000..0e397deadd
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from 7_selections.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mv_selections LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(mv_selections
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(mv_selections PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS mv_selections
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/modelview/CMakeLists.txt b/examples/widgets/tutorials/modelview/CMakeLists.txt
new file mode 100644
index 0000000000..10f2cf6ecf
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/CMakeLists.txt
@@ -0,0 +1,9 @@
+# Generated from modelview.pro.
+
+add_subdirectory(1_readonly)
+add_subdirectory(2_formatting)
+add_subdirectory(3_changingmodel)
+add_subdirectory(4_headers)
+add_subdirectory(5_edit)
+add_subdirectory(6_treeview)
+add_subdirectory(7_selections)
diff --git a/examples/widgets/tutorials/notepad/.prev_CMakeLists.txt b/examples/widgets/tutorials/notepad/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..6634c8c148
--- /dev/null
+++ b/examples/widgets/tutorials/notepad/.prev_CMakeLists.txt
@@ -0,0 +1,49 @@
+# Generated from notepad.pro.
+
+#####################################################################
+## notepad Binary:
+#####################################################################
+
+add_qt_executable(notepad
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/notepad"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/notepad"
+ SOURCES
+ main.cpp
+ notepad.cpp notepad.h notepad.ui
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+# Resources:
+add_qt_resource(notepad "notepad" PREFIX "/" FILES
+ images/bold.png
+ images/copy.png
+ images/create.png
+ images/cut.png
+ images/edit_redo.png
+ images/edit_undo.png
+ images/exit.png
+ images/font.png
+ images/info.png
+ images/italic.png
+ images/new.png
+ images/open.png
+ images/paste.png
+ images/pencil.png
+ images/print.png
+ images/save.png
+ images/save_as.png
+ images/underline.png)
+
+
+#### Keys ignored in scope 1:.:.:notepad.pro:<TRUE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(notepad CONDITION TARGET Qt::PrintSupport
+ PUBLIC_LIBRARIES
+ Qt::PrintSupport
+)
diff --git a/examples/widgets/tutorials/notepad/CMakeLists.txt b/examples/widgets/tutorials/notepad/CMakeLists.txt
new file mode 100644
index 0000000000..8a9b39871e
--- /dev/null
+++ b/examples/widgets/tutorials/notepad/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from notepad.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(notepad LANGUAGES CXX)
+
+find_package(Qt6 COMPONENTS Widgets) # special case: add
+find_package(Qt6 COMPONENTS PrintSupport) # special case: add
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+add_qt_gui_executable(notepad
+ main.cpp
+ notepad.cpp notepad.h notepad.qrc notepad.ui
+)
+# special case begin
+target_link_libraries(notepad PUBLIC
+ Qt::Widgets
+)
+if (TARGET Qt::PrintSupport)
+ target_link_libraries(notepad PUBLIC
+ Qt::PrintSupport
+ )
+endif()
+# special case end
+
+install(TARGETS notepad
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/widgets/CMakeLists.txt b/examples/widgets/tutorials/widgets/CMakeLists.txt
new file mode 100644
index 0000000000..1f4afee780
--- /dev/null
+++ b/examples/widgets/tutorials/widgets/CMakeLists.txt
@@ -0,0 +1,6 @@
+# Generated from widgets.pro.
+
+add_subdirectory(toplevel)
+add_subdirectory(childwidget)
+add_subdirectory(windowlayout)
+add_subdirectory(nestedlayouts)
diff --git a/examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt b/examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt
new file mode 100644
index 0000000000..cfbb5fe430
--- /dev/null
+++ b/examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from childwidget.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(childwidget LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(childwidget
+ main.cpp
+)
+target_link_libraries(childwidget PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS childwidget
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt b/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt
new file mode 100644
index 0000000000..4bdde3b10c
--- /dev/null
+++ b/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from nestedlayouts.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(nestedlayouts LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(nestedlayouts
+ main.cpp
+)
+target_link_libraries(nestedlayouts PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS nestedlayouts
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt b/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt
new file mode 100644
index 0000000000..c9636c17b4
--- /dev/null
+++ b/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from toplevel.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(toplevel LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(toplevel
+ main.cpp
+)
+target_link_libraries(toplevel PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS toplevel
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt b/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt
new file mode 100644
index 0000000000..6e247de6b6
--- /dev/null
+++ b/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from windowlayout.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(windowlayout LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(windowlayout
+ main.cpp
+)
+target_link_libraries(windowlayout PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS windowlayout
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/CMakeLists.txt b/examples/widgets/widgets/CMakeLists.txt
new file mode 100644
index 0000000000..8daf6a69ae
--- /dev/null
+++ b/examples/widgets/widgets/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from widgets.pro.
+
+add_subdirectory(analogclock)
+add_subdirectory(calculator)
+add_subdirectory(calendarwidget)
+add_subdirectory(charactermap)
+add_subdirectory(codeeditor)
+add_subdirectory(digitalclock)
+add_subdirectory(elidedlabel)
+add_subdirectory(groupbox)
+add_subdirectory(icons)
+add_subdirectory(imageviewer)
+add_subdirectory(lineedits)
+add_subdirectory(movie)
+add_subdirectory(mousebuttons)
+add_subdirectory(scribble)
+add_subdirectory(shapedclock)
+add_subdirectory(sliders)
+add_subdirectory(spinboxes)
+add_subdirectory(styles)
+add_subdirectory(stylesheet)
+add_subdirectory(tablet)
+add_subdirectory(tetrix)
+add_subdirectory(tooltips)
+add_subdirectory(validators)
+add_subdirectory(wiggly)
+add_subdirectory(windowflags)
diff --git a/examples/widgets/widgets/analogclock/CMakeLists.txt b/examples/widgets/widgets/analogclock/CMakeLists.txt
new file mode 100644
index 0000000000..0c940d9bb5
--- /dev/null
+++ b/examples/widgets/widgets/analogclock/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from analogclock.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(analogclock LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(analogclock
+ analogclock.cpp analogclock.h
+ main.cpp
+)
+target_link_libraries(analogclock PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS analogclock
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/calculator/CMakeLists.txt b/examples/widgets/widgets/calculator/CMakeLists.txt
new file mode 100644
index 0000000000..1f5b0a50ea
--- /dev/null
+++ b/examples/widgets/widgets/calculator/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from calculator.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(calculator LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(calculator
+ button.cpp button.h
+ calculator.cpp calculator.h
+ main.cpp
+)
+target_link_libraries(calculator PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS calculator
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/calendarwidget/CMakeLists.txt b/examples/widgets/widgets/calendarwidget/CMakeLists.txt
new file mode 100644
index 0000000000..7295b45dc5
--- /dev/null
+++ b/examples/widgets/widgets/calendarwidget/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from calendarwidget.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(calendarwidget LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(calendarwidget
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(calendarwidget PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS calendarwidget
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/charactermap/CMakeLists.txt b/examples/widgets/widgets/charactermap/CMakeLists.txt
new file mode 100644
index 0000000000..f397213830
--- /dev/null
+++ b/examples/widgets/widgets/charactermap/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from charactermap.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(charactermap LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(charactermap
+ characterwidget.cpp characterwidget.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_link_libraries(charactermap PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS charactermap
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/codeeditor/CMakeLists.txt b/examples/widgets/widgets/codeeditor/CMakeLists.txt
new file mode 100644
index 0000000000..0d1f036d79
--- /dev/null
+++ b/examples/widgets/widgets/codeeditor/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from codeeditor.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(codeeditor LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(codeeditor
+ codeeditor.cpp codeeditor.h
+ main.cpp
+)
+target_link_libraries(codeeditor PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS codeeditor
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/digitalclock/CMakeLists.txt b/examples/widgets/widgets/digitalclock/CMakeLists.txt
new file mode 100644
index 0000000000..50f7233004
--- /dev/null
+++ b/examples/widgets/widgets/digitalclock/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from digitalclock.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(digitalclock LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(digitalclock
+ digitalclock.cpp digitalclock.h
+ main.cpp
+)
+target_link_libraries(digitalclock PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS digitalclock
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/elidedlabel/CMakeLists.txt b/examples/widgets/widgets/elidedlabel/CMakeLists.txt
new file mode 100644
index 0000000000..d5ad7791fd
--- /dev/null
+++ b/examples/widgets/widgets/elidedlabel/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from elidedlabel.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(elidedlabel LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(elidedlabel
+ elidedlabel.cpp elidedlabel.h
+ main.cpp
+ testwidget.cpp testwidget.h
+)
+target_link_libraries(elidedlabel PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+install(TARGETS elidedlabel
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/groupbox/CMakeLists.txt b/examples/widgets/widgets/groupbox/CMakeLists.txt
new file mode 100644
index 0000000000..74af580846
--- /dev/null
+++ b/examples/widgets/widgets/groupbox/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from groupbox.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(groupbox LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(groupbox
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(groupbox PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS groupbox
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/icons/CMakeLists.txt b/examples/widgets/widgets/icons/CMakeLists.txt
new file mode 100644
index 0000000000..607c430b8c
--- /dev/null
+++ b/examples/widgets/widgets/icons/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from icons.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(icons LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(icons
+ iconpreviewarea.cpp iconpreviewarea.h
+ iconsizespinbox.cpp iconsizespinbox.h
+ imagedelegate.cpp imagedelegate.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+)
+target_compile_definitions(icons PUBLIC
+ SRCDIR="${CMAKE_CURRENT_SOURCE_DIR}"
+)
+target_link_libraries(icons PUBLIC
+ Qt::Widgets
+)
+install(TARGETS icons
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/imageviewer/CMakeLists.txt b/examples/widgets/widgets/imageviewer/CMakeLists.txt
new file mode 100644
index 0000000000..88f28a6dad
--- /dev/null
+++ b/examples/widgets/widgets/imageviewer/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from imageviewer.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(imageviewer LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS PrintSupport) # special case
+
+add_qt_gui_executable(imageviewer
+ imageviewer.cpp imageviewer.h
+ main.cpp
+)
+target_link_libraries(imageviewer PUBLIC
+ Qt::Widgets
+)
+# special case begin
+if (TARGET Qt::PrintSupport)
+ target_link_libraries(imageviewer PUBLIC Qt::PrintSupport)
+endif()
+# special case end
+
+install(TARGETS imageviewer
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/lineedits/CMakeLists.txt b/examples/widgets/widgets/lineedits/CMakeLists.txt
new file mode 100644
index 0000000000..cd616c31e3
--- /dev/null
+++ b/examples/widgets/widgets/lineedits/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from lineedits.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(lineedits LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(lineedits
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(lineedits PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS lineedits
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/mousebuttons/CMakeLists.txt b/examples/widgets/widgets/mousebuttons/CMakeLists.txt
new file mode 100644
index 0000000000..103d3aa215
--- /dev/null
+++ b/examples/widgets/widgets/mousebuttons/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from mousebuttons.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(mousebuttons LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(mousebuttons
+ buttontester.cpp buttontester.h
+ main.cpp
+)
+target_link_libraries(mousebuttons PUBLIC
+ Qt::Core
+ Qt::Widgets
+)
+
+install(TARGETS mousebuttons
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/movie/CMakeLists.txt b/examples/widgets/widgets/movie/CMakeLists.txt
new file mode 100644
index 0000000000..8a0d3f3d2f
--- /dev/null
+++ b/examples/widgets/widgets/movie/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from movie.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(movie LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(movie
+ main.cpp
+ movieplayer.cpp movieplayer.h
+)
+target_link_libraries(movie PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS movie
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/scribble/CMakeLists.txt b/examples/widgets/widgets/scribble/CMakeLists.txt
new file mode 100644
index 0000000000..6032e9f58b
--- /dev/null
+++ b/examples/widgets/widgets/scribble/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from scribble.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(scribble LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+find_package(Qt6 COMPONENTS PrintSupport) # special case
+
+add_qt_gui_executable(scribble
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ scribblearea.cpp scribblearea.h
+)
+target_link_libraries(scribble PUBLIC
+ Qt::Widgets
+)
+# special case begin
+if (TARGET Qt::PrintSupport)
+ target_link_libraries(scribble PUBLIC Qt::PrintSupport)
+endif()
+# special case end
+
+install(TARGETS scribble
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/shapedclock/CMakeLists.txt b/examples/widgets/widgets/shapedclock/CMakeLists.txt
new file mode 100644
index 0000000000..3bc86df1d9
--- /dev/null
+++ b/examples/widgets/widgets/shapedclock/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from shapedclock.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(shapedclock LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(shapedclock
+ main.cpp
+ shapedclock.cpp shapedclock.h
+)
+target_link_libraries(shapedclock PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS shapedclock
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/sliders/CMakeLists.txt b/examples/widgets/widgets/sliders/CMakeLists.txt
new file mode 100644
index 0000000000..b4f2cfd62b
--- /dev/null
+++ b/examples/widgets/widgets/sliders/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from sliders.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(sliders LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(sliders
+ main.cpp
+ slidersgroup.cpp slidersgroup.h
+ window.cpp window.h
+)
+target_link_libraries(sliders PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS sliders
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/spinboxes/CMakeLists.txt b/examples/widgets/widgets/spinboxes/CMakeLists.txt
new file mode 100644
index 0000000000..e4d63153b9
--- /dev/null
+++ b/examples/widgets/widgets/spinboxes/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from spinboxes.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(spinboxes LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(spinboxes
+ main.cpp
+ window.cpp window.h
+)
+target_link_libraries(spinboxes PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS spinboxes
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/styles/CMakeLists.txt b/examples/widgets/widgets/styles/CMakeLists.txt
new file mode 100644
index 0000000000..00c0481ce7
--- /dev/null
+++ b/examples/widgets/widgets/styles/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from styles.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(styles LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(styles
+ main.cpp
+ norwegianwoodstyle.cpp norwegianwoodstyle.h
+ styles.qrc
+ widgetgallery.cpp widgetgallery.h
+)
+target_link_libraries(styles PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS styles
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/stylesheet/CMakeLists.txt b/examples/widgets/widgets/stylesheet/CMakeLists.txt
new file mode 100644
index 0000000000..34b73c30f4
--- /dev/null
+++ b/examples/widgets/widgets/stylesheet/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from stylesheet.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(stylesheet LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(stylesheet
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ stylesheet.qrc
+ stylesheeteditor.cpp stylesheeteditor.h stylesheeteditor.ui
+)
+target_link_libraries(stylesheet PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS stylesheet
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/tablet/CMakeLists.txt b/examples/widgets/widgets/tablet/CMakeLists.txt
new file mode 100644
index 0000000000..b94fa63d2d
--- /dev/null
+++ b/examples/widgets/widgets/tablet/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from tablet.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(qttablet LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(qttablet
+ images.qrc
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ tabletapplication.cpp tabletapplication.h
+ tabletcanvas.cpp tabletcanvas.h
+)
+target_link_libraries(qttablet PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS qttablet
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/tetrix/CMakeLists.txt b/examples/widgets/widgets/tetrix/CMakeLists.txt
new file mode 100644
index 0000000000..4a12ff602b
--- /dev/null
+++ b/examples/widgets/widgets/tetrix/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from tetrix.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(tetrix LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(tetrix
+ main.cpp
+ tetrixboard.cpp tetrixboard.h
+ tetrixpiece.cpp tetrixpiece.h
+ tetrixwindow.cpp tetrixwindow.h
+)
+target_link_libraries(tetrix PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS tetrix
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/tooltips/CMakeLists.txt b/examples/widgets/widgets/tooltips/CMakeLists.txt
new file mode 100644
index 0000000000..3e35b67ec1
--- /dev/null
+++ b/examples/widgets/widgets/tooltips/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from tooltips.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(tooltips LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(tooltips
+ main.cpp
+ shapeitem.cpp shapeitem.h
+ sortingbox.cpp sortingbox.h
+ tooltips.qrc
+)
+target_link_libraries(tooltips PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS tooltips
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/validators/CMakeLists.txt b/examples/widgets/widgets/validators/CMakeLists.txt
new file mode 100644
index 0000000000..c4b66f0c6a
--- /dev/null
+++ b/examples/widgets/widgets/validators/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from validators.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(validators LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(validators
+ ledwidget.cpp ledwidget.h
+ localeselector.cpp localeselector.h
+ main.cpp
+ validators.qrc validators.ui
+ validatorwidget.cpp validatorwidget.h
+)
+target_link_libraries(validators PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS validators
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/wiggly/CMakeLists.txt b/examples/widgets/widgets/wiggly/CMakeLists.txt
new file mode 100644
index 0000000000..e2e73665ec
--- /dev/null
+++ b/examples/widgets/widgets/wiggly/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from wiggly.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(wiggly LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(wiggly
+ dialog.cpp dialog.h
+ main.cpp
+ wigglywidget.cpp wigglywidget.h
+)
+target_link_libraries(wiggly PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS wiggly
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/widgets/windowflags/CMakeLists.txt b/examples/widgets/widgets/windowflags/CMakeLists.txt
new file mode 100644
index 0000000000..7a1f14c90c
--- /dev/null
+++ b/examples/widgets/widgets/windowflags/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from windowflags.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(windowflags LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(windowflags
+ controllerwindow.cpp controllerwindow.h
+ main.cpp
+ previewwindow.cpp previewwindow.h
+)
+target_link_libraries(windowflags PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS windowflags
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/widgets/windowcontainer/CMakeLists.txt b/examples/widgets/windowcontainer/CMakeLists.txt
new file mode 100644
index 0000000000..463fe8f8a6
--- /dev/null
+++ b/examples/widgets/windowcontainer/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from windowcontainer.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(windowcontainer LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(windowcontainer
+ ../../gui/openglwindow/openglwindow.cpp ../../gui/openglwindow/openglwindow.h
+ windowcontainer.cpp
+)
+target_include_directories(windowcontainer PUBLIC
+ ../../gui/openglwindow
+)
+target_link_libraries(windowcontainer PUBLIC
+ Qt::Widgets
+)
+
+install(TARGETS windowcontainer
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/xml/CMakeLists.txt b/examples/xml/CMakeLists.txt
new file mode 100644
index 0000000000..af7f096d19
--- /dev/null
+++ b/examples/xml/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from xml.pro.
+
+add_subdirectory(htmlinfo)
+add_subdirectory(xmlstreamlint)
+
+if(TARGET Qt::Widgets)
+ add_subdirectory(dombookmarks)
+ add_subdirectory(saxbookmarks)
+ add_subdirectory(streambookmarks)
+
+ if(TARGET Qt::Network)
+ add_subdirectory(rsslisting)
+ endif()
+endif()
diff --git a/examples/xml/dombookmarks/CMakeLists.txt b/examples/xml/dombookmarks/CMakeLists.txt
new file mode 100644
index 0000000000..7a9059393d
--- /dev/null
+++ b/examples/xml/dombookmarks/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from dombookmarks.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(dombookmarks LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Xml)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(dombookmarks
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ xbeltree.cpp xbeltree.h
+)
+target_link_libraries(dombookmarks PUBLIC
+ Qt::Widgets
+ Qt::Xml
+)
+install(TARGETS dombookmarks
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/xml/htmlinfo/CMakeLists.txt b/examples/xml/htmlinfo/CMakeLists.txt
new file mode 100644
index 0000000000..dde6e17fa0
--- /dev/null
+++ b/examples/xml/htmlinfo/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from htmlinfo.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(htmlinfo LANGUAGES CXX)
+
+find_package(Qt6 COMPONENTS Core) # special case: add
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+add_executable(htmlinfo
+ main.cpp
+)
+target_link_libraries(htmlinfo PUBLIC
+ Qt::Core
+)
+install(TARGETS htmlinfo
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/xml/rsslisting/CMakeLists.txt b/examples/xml/rsslisting/CMakeLists.txt
new file mode 100644
index 0000000000..c2c699ac5a
--- /dev/null
+++ b/examples/xml/rsslisting/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from rsslisting.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(rsslisting LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Network)
+find_package(Qt6 COMPONENTS Xml)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(rsslisting
+ main.cpp
+ rsslisting.cpp rsslisting.h
+)
+target_link_libraries(rsslisting PUBLIC
+ Qt::Network
+ Qt::Widgets
+ Qt::Xml
+)
+install(TARGETS rsslisting
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/xml/streambookmarks/CMakeLists.txt b/examples/xml/streambookmarks/CMakeLists.txt
new file mode 100644
index 0000000000..a7ec5dfac7
--- /dev/null
+++ b/examples/xml/streambookmarks/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from streambookmarks.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(streambookmarks LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+find_package(Qt6 COMPONENTS Xml)
+find_package(Qt6 COMPONENTS Widgets)
+
+add_qt_gui_executable(streambookmarks
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ xbelreader.cpp xbelreader.h
+ xbelwriter.cpp xbelwriter.h
+)
+target_link_libraries(streambookmarks PUBLIC
+ Qt::Widgets
+ Qt::Xml
+)
+install(TARGETS streambookmarks
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/xml/xmlstreamlint/CMakeLists.txt b/examples/xml/xmlstreamlint/CMakeLists.txt
new file mode 100644
index 0000000000..d12b549996
--- /dev/null
+++ b/examples/xml/xmlstreamlint/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from xmlstreamlint.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(xmlstreamlint LANGUAGES CXX)
+
+find_package(Qt6 COMPONENTS Core Xml) # special case: add
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples")
+
+add_executable(xmlstreamlint
+ main.cpp
+)
+target_link_libraries(xmlstreamlint PUBLIC
+ Qt::Core
+ Qt::Xml # special case: add
+)
+install(TARGETS xmlstreamlint
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/qmake/.prev_CMakeLists.txt b/qmake/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..21abc53457
--- /dev/null
+++ b/qmake/.prev_CMakeLists.txt
@@ -0,0 +1,186 @@
+# Generated from qmake.pro.
+
+#####################################################################
+## qmake Binary:
+#####################################################################
+
+qt_add_executable(qmake
+ SOURCES
+ ../src/corelib/codecs/qutfcodec.cpp ../src/corelib/codecs/qutfcodec_p.h
+ ../src/corelib/global/qglobal.cpp ../src/corelib/global/qglobal.h
+ ../src/corelib/global/qlibraryinfo.cpp
+ ../src/corelib/global/qlogging.cpp
+ ../src/corelib/global/qmalloc.cpp
+ ../src/corelib/global/qnumeric.cpp ../src/corelib/global/qnumeric.h
+ ../src/corelib/io/qabstractfileengine.cpp ../src/corelib/io/qabstractfileengine_p.h
+ ../src/corelib/io/qbuffer.cpp ../src/corelib/io/qbuffer.h
+ ../src/corelib/io/qdir.cpp ../src/corelib/io/qdir.h ../src/corelib/io/qdir_p.h
+ ../src/corelib/io/qdiriterator.cpp ../src/corelib/io/qdiriterator.h
+ ../src/corelib/io/qfile.cpp ../src/corelib/io/qfile.h
+ ../src/corelib/io/qfiledevice.cpp
+ ../src/corelib/io/qfileinfo.cpp ../src/corelib/io/qfileinfo.h
+ ../src/corelib/io/qfilesystemengine.cpp
+ ../src/corelib/io/qfilesystementry.cpp
+ ../src/corelib/io/qfsfileengine.cpp
+ ../src/corelib/io/qfsfileengine_iterator.cpp
+ ../src/corelib/io/qiodevice.cpp ../src/corelib/io/qiodevice.h
+ ../src/corelib/io/qsettings.cpp
+ ../src/corelib/io/qtemporaryfile.cpp ../src/corelib/io/qtemporaryfile.h
+ ../src/corelib/kernel/qmetatype.cpp ../src/corelib/kernel/qmetatype.h
+ ../src/corelib/kernel/qsystemerror.cpp ../src/corelib/kernel/qsystemerror_p.h
+ ../src/corelib/kernel/qvariant.cpp
+ ../src/corelib/plugin/quuid.cpp ../src/corelib/plugin/quuid.h
+ ../src/corelib/serialization/qcborvalue.cpp ../src/corelib/serialization/qcborvalue.h ../src/corelib/serialization/qcborvalue_p.h
+ ../src/corelib/serialization/qjson_p.h
+ ../src/corelib/serialization/qjsonarray.cpp ../src/corelib/serialization/qjsonarray.h
+ ../src/corelib/serialization/qjsoncbor.cpp
+ ../src/corelib/serialization/qjsondocument.cpp ../src/corelib/serialization/qjsondocument.h
+ ../src/corelib/serialization/qjsonobject.cpp ../src/corelib/serialization/qjsonobject.h
+ ../src/corelib/serialization/qjsonparser.cpp ../src/corelib/serialization/qjsonparser_p.h
+ ../src/corelib/serialization/qjsonvalue.cpp ../src/corelib/serialization/qjsonvalue.h
+ ../src/corelib/serialization/qjsonwriter_p.h
+ ../src/corelib/serialization/qtextstream.cpp ../src/corelib/serialization/qtextstream.h
+ ../src/corelib/serialization/qxmlstream.cpp ../src/corelib/serialization/qxmlstream.h
+ ../src/corelib/serialization/qxmlutils.cpp ../src/corelib/serialization/qxmlutils_p.h
+ ../src/corelib/tools/qarraydata.cpp ../src/corelib/tools/qarraydata.h
+ ../src/corelib/tools/qarraydataops.h
+ ../src/corelib/tools/qarraydatapointer.h
+ ../src/corelib/tools/qbitarray.cpp ../src/corelib/tools/qbitarray.h
+ ../src/corelib/tools/qcryptographichash.cpp ../src/corelib/tools/qcryptographichash.h
+ ../src/corelib/tools/qhash.cpp ../src/corelib/tools/qhash.h
+ ../src/corelib/tools/qlist.cpp ../src/corelib/tools/qlist.h
+ ../src/corelib/tools/qmap.cpp ../src/corelib/tools/qmap.h
+ ../src/corelib/tools/qvector.h
+ ../src/corelib/tools/qversionnumber.cpp ../src/corelib/tools/qversionnumber.h
+ cachekeys.h
+ generators/mac/pbuilder_pbx.cpp generators/mac/pbuilder_pbx.h
+ generators/makefile.cpp generators/makefile.h
+ generators/makefiledeps.cpp generators/makefiledeps.h
+ generators/metamakefile.cpp generators/metamakefile.h
+ generators/projectgenerator.cpp generators/projectgenerator.h
+ generators/unix/unixmake.cpp generators/unix/unixmake.h
+ generators/unix/unixmake2.cpp
+ generators/win32/mingw_make.cpp generators/win32/mingw_make.h
+ generators/win32/msbuild_objectmodel.cpp generators/win32/msbuild_objectmodel.h
+ generators/win32/msvc_nmake.cpp generators/win32/msvc_nmake.h
+ generators/win32/msvc_objectmodel.cpp generators/win32/msvc_objectmodel.h
+ generators/win32/msvc_vcproj.cpp generators/win32/msvc_vcproj.h
+ generators/win32/msvc_vcxproj.cpp generators/win32/msvc_vcxproj.h
+ generators/win32/winmakefile.cpp generators/win32/winmakefile.h
+ generators/xmloutput.cpp generators/xmloutput.h
+ library/ioutils.cpp library/ioutils.h
+ library/proitems.cpp library/proitems.h
+ library/qmake_global.h
+ library/qmakebuiltins.cpp
+ library/qmakeevaluator.cpp library/qmakeevaluator.h library/qmakeevaluator_p.h
+ library/qmakeglobals.cpp library/qmakeglobals.h
+ library/qmakeparser.cpp library/qmakeparser.h
+ library/qmakevfs.cpp library/qmakevfs.h
+ main.cpp
+ meta.cpp meta.h
+ option.cpp option.h
+ project.cpp project.h
+ property.cpp property.h
+ qbytearray.cpp-NOTFOUND qbytearray.h-NOTFOUND
+ qbytearraymatcher.cpp-NOTFOUND qbytearraymatcher.h-NOTFOUND
+ qcalendar.cpp-NOTFOUND qcalendar.h-NOTFOUND
+ qcalendarbackend_p.h-NOTFOUND
+ qcalendarmath_p.h-NOTFOUND
+ qchar.h-NOTFOUND
+ qdatetime.cpp-NOTFOUND qdatetime.h-NOTFOUND qdatetime_p.h-NOTFOUND
+ qgregoriancalendar.cpp-NOTFOUND qgregoriancalendar_p.h-NOTFOUND
+ qlocale.cpp-NOTFOUND qlocale.h-NOTFOUND
+ qlocale_tools.cpp-NOTFOUND qlocale_tools_p.h-NOTFOUND
+ qregexp.cpp-NOTFOUND qregexp.h-NOTFOUND
+ qromancalendar.cpp-NOTFOUND qromancalendar_p.h-NOTFOUND
+ qstring.cpp-NOTFOUND qstring.h-NOTFOUND
+ qstringlist.cpp-NOTFOUND qstringlist.h-NOTFOUND
+ qstringmatcher.h-NOTFOUND
+ qvsnprintf.cpp-NOTFOUND
+ DEFINES
+ (QT_VERSION_STR=\"\")
+ PROEVALUATOR_FULL
+ QT_BOOTSTRAPPED
+ QT_BUILD_QMAKE
+ QT_NO_FOREACH
+ QT_VERSION_MAJOR=
+ QT_VERSION_MINOR=
+ QT_VERSION_PATCH=
+ INCLUDE_DIRECTORIES
+ (..)/include
+ (..)/include/QtCore (..)/include/QtCore
+ (..)/include/QtCore//QtCore
+ (..)/src/corelib/global
+ .
+ generators
+ generators/mac
+ generators/unix
+ generators/win32
+ library
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "qmake_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:qmake.pro:<TRUE>:
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qmake CONDITION WIN32
+ SOURCES
+ ../src/corelib/global/qoperatingsystemversion_win.cpp
+ ../src/corelib/io/qfilesystemengine_win.cpp
+ ../src/corelib/io/qfilesystemiterator_win.cpp
+ ../src/corelib/io/qfsfileengine_win.cpp
+ ../src/corelib/io/qsettings_win.cpp
+ ../src/corelib/plugin/qsystemlibrary.cpp
+ qlocale_win.cpp-NOTFOUND
+ registry.cpp-NOTFOUND
+ DEFINES
+ UNICODE
+ _CRT_SECURE_NO_WARNINGS
+ _ENABLE_EXTENDED_ALIGNED_STORAGE
+ _SCL_SECURE_NO_WARNINGS
+ PUBLIC_LIBRARIES
+ advapi32
+ kernel32
+ netapi32
+ ole32
+)
+
+qt_extend_target(qmake CONDITION UNIX
+ SOURCES
+ ../src/corelib/io/qfilesystemengine_unix.cpp
+ ../src/corelib/io/qfilesystemiterator_unix.cpp
+ ../src/corelib/io/qfsfileengine_unix.cpp
+ ../src/corelib/kernel/qcore_unix.cpp
+ qlocale_unix.cpp-NOTFOUND
+)
+
+qt_extend_target(qmake CONDITION APPLE_OSX
+ SOURCES
+ qcore_foundation.mm
+ qcore_mac.cpp
+ qoperatingsystemversion_darwin.mm
+ qsettings_mac.cpp
+ PUBLIC_LIBRARIES
+ ${FWApplicationServices}
+ ${FWCoreServices}
+ ${FWFoundation}
+ COMPILE_OPTIONS
+ -fconstant-cfstrings
+)
+
+qt_extend_target(qmake CONDITION WIN32 AND mingw
+ PUBLIC_LIBRARIES
+ uuid
+)
+
+qt_extend_target(qmake CONDITION CLANG AND WIN32
+ COMPILE_OPTIONS
+ -Wno-microsoft-enum-value
+ -fms-compatibility-version=19.00.23506
+)
diff --git a/qmake/CMakeLists.txt b/qmake/CMakeLists.txt
new file mode 100644
index 0000000000..056f17699b
--- /dev/null
+++ b/qmake/CMakeLists.txt
@@ -0,0 +1,216 @@
+# Generated from qmake.pro.
+
+#####################################################################
+## qmake Binary:
+#####################################################################
+
+qt_add_tool(qmake # special case
+ NO_QT # special case
+ TOOLS_TARGET Core # special case
+ # GUI # special case: remove this
+ SOURCES
+ ../src/corelib/codecs/qutfcodec.cpp ../src/corelib/codecs/qutfcodec_p.h
+ ../src/corelib/global/qendian.cpp # special case
+ ../src/corelib/global/qglobal.cpp ../src/corelib/global/qglobal.h
+ ../src/corelib/global/qlibraryinfo.cpp
+ ../src/corelib/global/qlogging.cpp
+ ../src/corelib/global/qmalloc.cpp
+ ../src/corelib/global/qnumeric.cpp ../src/corelib/global/qnumeric.h
+ ../src/corelib/global/qoperatingsystemversion.cpp # special case
+ ../src/corelib/global/qrandom.cpp # special case
+ ../src/corelib/io/qabstractfileengine.cpp ../src/corelib/io/qabstractfileengine_p.h
+ ../src/corelib/io/qbuffer.cpp ../src/corelib/io/qbuffer.h
+ ../src/corelib/io/qdebug.cpp # special case
+ ../src/corelib/io/qdir.cpp ../src/corelib/io/qdir.h ../src/corelib/io/qdir_p.h
+ ../src/corelib/io/qdiriterator.cpp ../src/corelib/io/qdiriterator.h
+ ../src/corelib/io/qfile.cpp ../src/corelib/io/qfile.h
+ ../src/corelib/io/qfiledevice.cpp
+ ../src/corelib/io/qfileinfo.cpp ../src/corelib/io/qfileinfo.h
+ ../src/corelib/io/qfilesystemengine.cpp
+ ../src/corelib/io/qfilesystementry.cpp
+ ../src/corelib/io/qfsfileengine.cpp
+ ../src/corelib/io/qfsfileengine_iterator.cpp
+ ../src/corelib/io/qiodevice.cpp ../src/corelib/io/qiodevice.h
+ ../src/corelib/io/qsettings.cpp
+ ../src/corelib/io/qtemporaryfile.cpp ../src/corelib/io/qtemporaryfile.h
+ ../src/corelib/kernel/qmetatype.cpp ../src/corelib/kernel/qmetatype.h
+ ../src/corelib/kernel/qsystemerror.cpp ../src/corelib/kernel/qsystemerror_p.h
+ ../src/corelib/kernel/qvariant.cpp
+ ../src/corelib/plugin/quuid.cpp ../src/corelib/plugin/quuid.h
+ ../src/corelib/serialization/qcborvalue.cpp ../src/corelib/serialization/qcborvalue.h ../src/corelib/serialization/qcborvalue_p.h
+ ../src/corelib/serialization/qjson_p.h
+ ../src/corelib/serialization/qjsonarray.cpp ../src/corelib/serialization/qjsonarray.h
+ ../src/corelib/serialization/qjsoncbor.cpp
+ ../src/corelib/serialization/qjsondocument.cpp ../src/corelib/serialization/qjsondocument.h
+ ../src/corelib/serialization/qjsonobject.cpp ../src/corelib/serialization/qjsonobject.h
+ ../src/corelib/serialization/qjsonparser.cpp ../src/corelib/serialization/qjsonparser_p.h
+ ../src/corelib/serialization/qjsonvalue.cpp ../src/corelib/serialization/qjsonvalue.h
+ ../src/corelib/serialization/qjsonwriter_p.h
+ ../src/corelib/serialization/qtextstream.cpp ../src/corelib/serialization/qtextstream.h
+ ../src/corelib/serialization/qxmlstream.cpp ../src/corelib/serialization/qxmlstream.h
+ ../src/corelib/serialization/qxmlutils.cpp ../src/corelib/serialization/qxmlutils_p.h
+ ../src/corelib/tools/qarraydata.cpp ../src/corelib/tools/qarraydata.h
+ ../src/corelib/tools/qarraydataops.h
+ ../src/corelib/tools/qarraydatapointer.h
+ ../src/corelib/tools/qbitarray.cpp ../src/corelib/tools/qbitarray.h
+ ../src/corelib/text/qbytearray.cpp ../src/corelib/text/qbytearray.h
+ ../src/corelib/text/qbytearraylist.cpp ../src/corelib/text/qbytearraylist.h # special case
+ ../src/corelib/text/qbytearraymatcher.cpp ../src/corelib/text/qbytearraymatcher.h
+ ../src/corelib/text/qchar.h
+ ../src/corelib/tools/qcryptographichash.cpp ../src/corelib/tools/qcryptographichash.h
+ ../src/corelib/time/qcalendar.cpp ../src/corelib/time/qcalendar.h # special case
+ ../src/corelib/time/qcalendarbackend_p.h ../src/corelib/time/qcalendarmath_p.h # special case
+ ../src/corelib/time/qgregoriancalendar.cpp ../src/corelib/time/qgregoriancalendar_p.h # special case
+ ../src/corelib/time/qromancalendar.cpp ../src/corelib/time/qromancalendar_p.h # special case
+ ../src/corelib/time/qdatetime.cpp ../src/corelib/time/qdatetime.h ../src/corelib/time/qdatetime_p.h # special case
+ ../src/corelib/tools/qhash.cpp ../src/corelib/tools/qhash.h
+ ../src/corelib/tools/qlist.cpp ../src/corelib/tools/qlist.h
+ ../src/corelib/text/qlocale.cpp ../src/corelib/text/qlocale.h
+ ../src/corelib/text/qlocale_tools.cpp ../src/corelib/text/qlocale_tools_p.h
+ ../src/corelib/tools/qmap.cpp ../src/corelib/tools/qmap.h
+ ../src/corelib/text/qregexp.cpp ../src/corelib/text/qregexp.h
+ ../src/corelib/tools/qringbuffer.cpp # special case
+ ../src/corelib/text/qstring.cpp ../src/corelib/text/qstring.h
+ ../src/corelib/text/qstringlist.cpp ../src/corelib/text/qstringlist.h
+ ../src/corelib/text/qstringmatcher.h
+ ../src/corelib/tools/qvector.h
+ ../src/corelib/tools/qversionnumber.cpp ../src/corelib/tools/qversionnumber.h
+ ../src/corelib/text/qvsnprintf.cpp
+ cachekeys.h
+ generators/mac/pbuilder_pbx.cpp generators/mac/pbuilder_pbx.h
+ generators/makefile.cpp generators/makefile.h
+ generators/makefiledeps.cpp generators/makefiledeps.h
+ generators/metamakefile.cpp generators/metamakefile.h
+ generators/projectgenerator.cpp generators/projectgenerator.h
+ generators/unix/unixmake.cpp generators/unix/unixmake.h
+ generators/unix/unixmake2.cpp
+ generators/win32/mingw_make.cpp generators/win32/mingw_make.h
+ generators/win32/msbuild_objectmodel.cpp generators/win32/msbuild_objectmodel.h
+ generators/win32/msvc_nmake.cpp generators/win32/msvc_nmake.h
+ generators/win32/msvc_objectmodel.cpp generators/win32/msvc_objectmodel.h
+ generators/win32/msvc_vcproj.cpp generators/win32/msvc_vcproj.h
+ generators/win32/msvc_vcxproj.cpp generators/win32/msvc_vcxproj.h
+ generators/win32/winmakefile.cpp generators/win32/winmakefile.h
+ generators/xmloutput.cpp generators/xmloutput.h
+ library/ioutils.cpp library/ioutils.h
+ library/proitems.cpp library/proitems.h
+ library/qmake_global.h
+ library/qmakebuiltins.cpp
+ library/qmakeevaluator.cpp library/qmakeevaluator.h library/qmakeevaluator_p.h
+ library/qmakeglobals.cpp library/qmakeglobals.h
+ library/qmakeparser.cpp library/qmakeparser.h
+ library/qmakevfs.cpp library/qmakevfs.h
+ main.cpp
+ meta.cpp meta.h
+ option.cpp option.h
+ project.cpp project.h
+ property.cpp property.h
+ DEFINES
+ PROEVALUATOR_FULL
+ QT_BOOTSTRAPPED
+ QT_BUILD_QMAKE
+ QT_NO_FOREACH
+ QT_VERSION_STR="${PROJECT_VERSION}" # special case
+ QT_VERSION_MAJOR=${PROJECT_VERSION_MAJOR} # special case
+ QT_VERSION_MINOR=${PROJECT_VERSION_MINOR} # special case
+ QT_VERSION_PATCH=${PROJECT_VERSION_PATCH} # special case
+ INCLUDE_DIRECTORIES
+ # . # special case remove
+ generators
+ generators/mac
+ generators/unix
+ generators/win32
+ library
+ $<TARGET_PROPERTY:Qt::Core,INCLUDE_DIRECTORIES> # special case
+ "${PROJECT_BINARY_DIR}/src/corelib/global" # special case: for qconfig.cpp
+ PRECOMPILED_HEADER
+ "qmake_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:qmake.pro:<TRUE>:
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qmake CONDITION WIN32
+ SOURCES
+ ../src/corelib/global/qoperatingsystemversion_win.cpp
+ ../src/corelib/io/qfilesystemengine_win.cpp
+ ../src/corelib/io/qfilesystemiterator_win.cpp
+ ../src/corelib/io/qfsfileengine_win.cpp
+ ../src/corelib/io/qsettings_win.cpp
+ ../src/corelib/plugin/qsystemlibrary.cpp
+ ../src/corelib/text/qlocale_win.cpp # special case
+ library/registry.cpp # special case
+ DEFINES
+ UNICODE
+ _CRT_SECURE_NO_WARNINGS
+ _ENABLE_EXTENDED_ALIGNED_STORAGE
+ _SCL_SECURE_NO_WARNINGS
+ PUBLIC_LIBRARIES
+ advapi32
+ kernel32
+ netapi32
+ ole32
+)
+
+qt_extend_target(qmake CONDITION UNIX
+ SOURCES
+ ../src/corelib/io/qfilesystemengine_unix.cpp
+ ../src/corelib/io/qfilesystemiterator_unix.cpp
+ ../src/corelib/io/qfsfileengine_unix.cpp
+ ../src/corelib/kernel/qcore_unix.cpp
+ ../src/corelib/text/qlocale_unix.cpp
+)
+
+qt_extend_target(qmake CONDITION APPLE_OSX
+ SOURCES
+ ../src/corelib/kernel/qcore_foundation.mm # special case
+ ../src/corelib/kernel/qcore_mac.cpp # special case
+ ../src/corelib/global/qoperatingsystemversion_darwin.mm # special case
+ ../src/corelib/io/qsettings_mac.cpp # special case
+ PUBLIC_LIBRARIES
+ ${FWApplicationServices}
+ ${FWCoreServices}
+ ${FWFoundation}
+ COMPILE_OPTIONS
+ "-fconstant-cfstrings"
+)
+
+# special case big
+extend_target(qmake CONDITION WIN32
+ SOURCES
+ ../src/corelib/io/qfilesystemengine_win.cpp
+ ../src/corelib/io/qfilesystemiterator_win.cpp
+ ../src/corelib/io/qfsfileengine_win.cpp
+ ../src/corelib/text/qlocale_win.cpp
+ ../src/corelib/io/qsettings_win.cpp
+ # ../src/corelib/global/qoperatingsystemversion.cpp special case: remove this
+ ../src/corelib/plugin/qsystemlibrary.cpp
+ library/registry.cpp
+ DEFINES
+ UNICODE _ENABLE_EXTENDED_ALIGNED_STORAGE _CRT_SECURE_NO_WARNINGS _SCL_SECURE_NO_WARNINGS
+ LIBRARIES
+ ole32 advapi32 kernel32 netapi32
+)
+
+qt_extend_target(qmake CONDITION WIN32 AND mingw
+ PUBLIC_LIBRARIES
+ uuid
+)
+
+qt_extend_target(qmake CONDITION CLANG AND WIN32
+ COMPILE_OPTIONS
+ "-fms-compatibility-version=19.00.23506"
+ "-Wno-microsoft-enum-value"
+)
+
+# special case:
+set_target_properties(qmake PROPERTIES
+ AUTOMOC OFF
+ AUTORCC OFF
+ AUTOUIC OFF
+)
+
+qt_internal_add_link_flags_gc_sections(qmake PRIVATE) # special case
diff --git a/qmake/generators/makefiledeps.cpp b/qmake/generators/makefiledeps.cpp
index 7c4be64aa8..0ff64c4fbc 100644
--- a/qmake/generators/makefiledeps.cpp
+++ b/qmake/generators/makefiledeps.cpp
@@ -246,7 +246,7 @@ bool QMakeSourceFileInfo::mocable(const QString &file)
return false;
}
-QMakeSourceFileInfo::QMakeSourceFileInfo(const QString &cf)
+QMakeSourceFileInfo::QMakeSourceFileInfo()
{
//dep_mode
dep_mode = Recursive;
diff --git a/qmake/generators/makefiledeps.h b/qmake/generators/makefiledeps.h
index 7e39396754..b97ace42a6 100644
--- a/qmake/generators/makefiledeps.h
+++ b/qmake/generators/makefiledeps.h
@@ -86,7 +86,7 @@ protected:
public:
- QMakeSourceFileInfo(const QString &cachefile="");
+ QMakeSourceFileInfo();
virtual ~QMakeSourceFileInfo();
QVector<QMakeLocalFileName> dependencyPaths() const { return depdirs; }
diff --git a/qmake/main.cpp b/qmake/main.cpp
index 86f91031df..c0e6088d80 100644
--- a/qmake/main.cpp
+++ b/qmake/main.cpp
@@ -265,6 +265,8 @@ static bool copyFileTimes(QFile &targetFile, const QString &sourceFilePath,
return false;
}
}
+#else
+ Q_UNUSED(mustEnsureWritability);
#endif
if (!IoUtils::touchFile(targetFile.fileName(), sourceFilePath, errorString))
return false;
diff --git a/src/3rdparty/CMakeLists.txt b/src/3rdparty/CMakeLists.txt
new file mode 100644
index 0000000000..79ff5cd93c
--- /dev/null
+++ b/src/3rdparty/CMakeLists.txt
@@ -0,0 +1,8 @@
+add_subdirectory(harfbuzz)
+add_subdirectory(double-conversion)
+
+#special case begin
+if (ANDROID)
+ add_subdirectory(gradle)
+endif()
+#special case end
diff --git a/src/3rdparty/double-conversion/CMakeLists.txt b/src/3rdparty/double-conversion/CMakeLists.txt
new file mode 100644
index 0000000000..7450bc48ec
--- /dev/null
+++ b/src/3rdparty/double-conversion/CMakeLists.txt
@@ -0,0 +1,21 @@
+# special case begin
+
+add_library(QtDoubleConversion STATIC
+ ${CMAKE_CURRENT_SOURCE_DIR}/bignum.cc
+ ${CMAKE_CURRENT_SOURCE_DIR}/bignum-dtoa.cc
+ ${CMAKE_CURRENT_SOURCE_DIR}/cached-powers.cc
+ ${CMAKE_CURRENT_SOURCE_DIR}/diy-fp.cc
+ ${CMAKE_CURRENT_SOURCE_DIR}/double-conversion.cc
+ ${CMAKE_CURRENT_SOURCE_DIR}/fast-dtoa.cc
+ ${CMAKE_CURRENT_SOURCE_DIR}/fixed-dtoa.cc
+ ${CMAKE_CURRENT_SOURCE_DIR}/strtod.cc
+ )
+
+target_include_directories(QtDoubleConversion PUBLIC
+ $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/..>
+ $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
+ $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include/double-conversion>
+ )
+
+qt_install_3rdparty_library(QtDoubleConversion)
+# special case end
diff --git a/src/3rdparty/gradle/CMakeLists.txt b/src/3rdparty/gradle/CMakeLists.txt
new file mode 100644
index 0000000000..d4eaa60838
--- /dev/null
+++ b/src/3rdparty/gradle/CMakeLists.txt
@@ -0,0 +1,21 @@
+# special case begin
+# special case skip regeneration
+
+install(
+ FILES
+ gradlew
+ gradlew.bat
+ DESTINATION
+ src/3rdparty/gradle
+ COMPONENT
+ Devel)
+
+install(
+ DIRECTORY
+ gradle
+ DESTINATION
+ src/3rdparty/gradle
+ COMPONENT
+ Devel)
+
+# special case end
diff --git a/src/3rdparty/harfbuzz/CMakeLists.txt b/src/3rdparty/harfbuzz/CMakeLists.txt
new file mode 100644
index 0000000000..3eaddbb2db
--- /dev/null
+++ b/src/3rdparty/harfbuzz/CMakeLists.txt
@@ -0,0 +1,14 @@
+add_library(QtHarfBuzz STATIC
+ src/harfbuzz-shaper-all.cpp
+ src/harfbuzz-buffer.c
+ src/harfbuzz-gdef.c
+ src/harfbuzz-gsub.c
+ src/harfbuzz-gpos.c
+ src/harfbuzz-impl.c
+ src/harfbuzz-open.c
+ src/harfbuzz-stream.c
+ )
+target_include_directories(QtHarfBuzz PUBLIC
+ $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src>)
+
+qt_install_3rdparty_library(QtHarfBuzz)
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
new file mode 100644
index 0000000000..bb2b8a6ee2
--- /dev/null
+++ b/src/CMakeLists.txt
@@ -0,0 +1,60 @@
+# special case skip regeneration
+add_subdirectory(3rdparty)
+
+function(find_or_build_bootstrap_names)
+ if (QT_WILL_BUILD_TOOLS)
+ add_subdirectory(tools/bootstrap) # bootstrap library
+ endif()
+ add_subdirectory(tools/moc)
+ add_subdirectory(tools/rcc)
+ add_subdirectory(tools/tracegen)
+ add_subdirectory(tools/cmake_automoc_parser)
+endfunction()
+
+find_or_build_bootstrap_names()
+
+add_subdirectory(corelib)
+if (QT_FEATURE_concurrent)
+ add_subdirectory(concurrent)
+endif()
+if (QT_FEATURE_sql)
+ add_subdirectory(sql)
+endif()
+if (QT_FEATURE_network)
+ add_subdirectory(network)
+endif()
+if (QT_FEATURE_xml)
+ add_subdirectory(xml)
+endif()
+add_subdirectory(tools)
+
+if (QT_FEATURE_dbus)
+ add_subdirectory(dbus)
+endif()
+if(QT_FEATURE_gui)
+ add_subdirectory(gui)
+
+ if(QT_FEATURE_opengl)
+ add_subdirectory(openglextensions)
+ endif()
+
+ if(QT_FEATURE_widgets)
+ add_subdirectory(widgets)
+ if(QT_FEATURE_opengl)
+ add_subdirectory(opengl)
+ endif()
+ endif()
+ add_subdirectory(platformsupport)
+ add_subdirectory(platformheaders)
+endif()
+if (QT_FEATURE_testlib)
+ add_subdirectory(testlib)
+endif()
+if(QT_FEATURE_gui AND QT_FEATURE_widgets)
+ add_subdirectory(printsupport)
+endif()
+add_subdirectory(plugins)
+
+add_subdirectory(winmain)
+
+add_subdirectory(android)
diff --git a/src/android/CMakeLists.txt b/src/android/CMakeLists.txt
new file mode 100644
index 0000000000..a821cee44b
--- /dev/null
+++ b/src/android/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from android.pro.
+
+# special case skip regeneration
+# special case begin
+# Only build jars during Android build and install the templates for the
+# androiddeployqt tool.
+# android
+if (ANDROID)
+ add_subdirectory(jar)
+ add_subdirectory(java)
+ add_subdirectory(templates)
+endif()
+# special case end
+
diff --git a/src/android/jar/.prev_CMakeLists.txt b/src/android/jar/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..f4c807c33a
--- /dev/null
+++ b/src/android/jar/.prev_CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from jar.pro.
+
+set(java_sources
+ src/org/qtproject/qt5/android//accessibility/QtAccessibilityDelegate.java
+ src/org/qtproject/qt5/android//accessibility/QtNativeAccessibility.java
+ src/org/qtproject/qt5/android//CursorHandle.java
+ src/org/qtproject/qt5/android//EditContextView.java
+ src/org/qtproject/qt5/android//EditPopupMenu.java
+ src/org/qtproject/qt5/android//ExtractStyle.java
+ src/org/qtproject/qt5/android//QtActivityDelegate.java
+ src/org/qtproject/qt5/android//QtEditText.java
+ src/org/qtproject/qt5/android//QtInputConnection.java
+ src/org/qtproject/qt5/android//QtLayout.java
+ src/org/qtproject/qt5/android//QtMessageDialogHelper.java
+ src/org/qtproject/qt5/android//QtNative.java
+ src/org/qtproject/qt5/android//QtNativeLibrariesDir.java
+ src/org/qtproject/qt5/android//QtSurface.java
+ src/org/qtproject/qt5/android//QtThread.java
+)
+
+add_jar(QtAndroid
+ INCLUDE_JARS ${QT_ANDROID_JAR}
+ SOURCES ${java_sources}
+)
+
+install_jar(QtAndroid
+ DESTINATION jar
+ COMPONENT Devel
+)
+
diff --git a/src/android/jar/CMakeLists.txt b/src/android/jar/CMakeLists.txt
new file mode 100644
index 0000000000..61af168a67
--- /dev/null
+++ b/src/android/jar/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from jar.pro.
+
+set(java_sources
+ src/org/qtproject/qt5/android/accessibility/QtAccessibilityDelegate.java
+ src/org/qtproject/qt5/android/accessibility/QtNativeAccessibility.java
+ src/org/qtproject/qt5/android/CursorHandle.java
+ src/org/qtproject/qt5/android/EditContextView.java
+ src/org/qtproject/qt5/android/EditPopupMenu.java
+ src/org/qtproject/qt5/android/ExtractStyle.java
+ src/org/qtproject/qt5/android/QtActivityDelegate.java
+ src/org/qtproject/qt5/android/QtEditText.java
+ src/org/qtproject/qt5/android/QtInputConnection.java
+ src/org/qtproject/qt5/android/QtLayout.java
+ src/org/qtproject/qt5/android/QtMessageDialogHelper.java
+ src/org/qtproject/qt5/android/QtNative.java
+ src/org/qtproject/qt5/android/QtNativeLibrariesDir.java
+ src/org/qtproject/qt5/android/QtSurface.java
+ src/org/qtproject/qt5/android/QtThread.java
+ src/org/qtproject/qt5/android/QtServiceDelegate.java # special case
+)
+
+add_jar(QtAndroid
+ INCLUDE_JARS ${QT_ANDROID_JAR}
+ SOURCES ${java_sources}
+)
+
+install_jar(QtAndroid
+ DESTINATION jar
+ COMPONENT Devel
+)
+
diff --git a/src/android/java/CMakeLists.txt b/src/android/java/CMakeLists.txt
new file mode 100644
index 0000000000..1c24bd5e82
--- /dev/null
+++ b/src/android/java/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Android Java Resource files
+
+# special case skip regeneration
+# special case begin
+set(resource_directories
+ res
+ src)
+
+qt_install(DIRECTORY ${resource_directories}
+ DESTINATION src/android/java
+ COMPONENT Devel)
+# special case end
diff --git a/src/android/templates/CMakeLists.txt b/src/android/templates/CMakeLists.txt
new file mode 100644
index 0000000000..8e007b7215
--- /dev/null
+++ b/src/android/templates/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Android template files
+
+# special case skip regeneration
+# special case begin
+set(template_files
+ AndroidManifest.xml
+ build.gradle)
+
+set(template_directories
+ res)
+
+qt_install(FILES ${template_files}
+ DESTINATION src/android/templates
+ COMPONENT Devel)
+
+qt_install(DIRECTORY ${template_directories}
+ DESTINATION src/android/templates
+ COMPONENT Devel)
+# special case end
diff --git a/src/concurrent/CMakeLists.txt b/src/concurrent/CMakeLists.txt
new file mode 100644
index 0000000000..b908ef90a1
--- /dev/null
+++ b/src/concurrent/CMakeLists.txt
@@ -0,0 +1,46 @@
+# Generated from concurrent.pro.
+
+#####################################################################
+## Concurrent Module:
+#####################################################################
+
+qt_add_module(Concurrent
+ EXCEPTIONS
+ SOURCES
+ qtconcurrent_global.h
+ qtconcurrentcompilertest.h
+ qtconcurrentexception.h
+ qtconcurrentfilter.cpp qtconcurrentfilter.h
+ qtconcurrentfilterkernel.h
+ qtconcurrentfunctionwrappers.h
+ qtconcurrentiteratekernel.cpp qtconcurrentiteratekernel.h
+ qtconcurrentmap.cpp qtconcurrentmap.h
+ qtconcurrentmapkernel.h
+ qtconcurrentmedian.h
+ qtconcurrentreducekernel.h
+ qtconcurrentrun.cpp qtconcurrentrun.h
+ qtconcurrentrunbase.h
+ qtconcurrentstoredfunctioncall.h
+ qtconcurrentthreadengine.cpp qtconcurrentthreadengine.h
+ DEFINES
+ QT_NO_FOREACH
+ QT_NO_USING_NAMESPACE
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ PRECOMPILED_HEADER
+ "../corelib/global/qt_pch.h"
+)
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(Concurrent CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x66000000"
+)
+qt_add_docs(Concurrent
+ doc/qtconcurrent.qdocconf
+)
+
diff --git a/src/corelib/.prev_CMakeLists.txt b/src/corelib/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..f32ff1f8f3
--- /dev/null
+++ b/src/corelib/.prev_CMakeLists.txt
@@ -0,0 +1,1056 @@
+# Generated from corelib.pro.
+
+#####################################################################
+## Core Module:
+#####################################################################
+
+qt_add_module(Core
+ GENERATE_METATYPES
+ QMAKE_MODULE_CONFIG moc resources
+ EXCEPTIONS
+ SOURCES
+ ../3rdparty/harfbuzz/src/harfbuzz.h
+ ../3rdparty/harfbuzz/src/harfbuzz-buffer.c
+ ../3rdparty/harfbuzz/src/harfbuzz-gdef.c
+ ../3rdparty/harfbuzz/src/harfbuzz-gpos.c
+ ../3rdparty/harfbuzz/src/harfbuzz-gsub.c
+ ../3rdparty/harfbuzz/src/harfbuzz-impl.c
+ ../3rdparty/harfbuzz/src/harfbuzz-open.c
+ ../3rdparty/harfbuzz/src/harfbuzz-shaper-all.cpp
+ ../3rdparty/harfbuzz/src/harfbuzz-stream.c
+ codecs/qtextcodec_p.h
+ codecs/qutfcodec.cpp codecs/qutfcodec_p.h
+ global/archdetect.cpp
+ global/qcompilerdetection.h
+ global/qendian.cpp global/qendian.h global/qendian_p.h
+ global/qflags.h
+ global/qfloat16.cpp global/qfloat16.h
+ global/qglobal.cpp global/qglobal.h
+ global/qglobalstatic.h
+ global/qhooks.cpp global/qhooks_p.h
+ global/qisenum.h
+ global/qlibraryinfo.cpp global/qlibraryinfo.h
+ global/qlogging.cpp global/qlogging.h
+ global/qmalloc.cpp
+ global/qmemory_p.h
+ global/qnamespace.h
+ global/qnumeric.cpp global/qnumeric.h global/qnumeric_p.h
+ global/qoperatingsystemversion.cpp global/qoperatingsystemversion.h global/qoperatingsystemversion_p.h
+ global/qprocessordetection.h
+ global/qrandom.cpp global/qrandom.h global/qrandom_p.h
+ global/qsysinfo.h
+ global/qsystemdetection.h
+ global/qtypeinfo.h
+ global/qtypetraits.h
+ global/qversiontagging.h
+ io/qabstractfileengine.cpp io/qabstractfileengine_p.h
+ io/qbuffer.cpp io/qbuffer.h
+ io/qdataurl.cpp io/qdataurl_p.h
+ io/qdebug.cpp io/qdebug.h io/qdebug_p.h
+ io/qdir.cpp io/qdir.h io/qdir_p.h
+ io/qdiriterator.cpp io/qdiriterator.h
+ io/qfile.cpp io/qfile.h
+ io/qfiledevice.cpp io/qfiledevice.h io/qfiledevice_p.h
+ io/qfileinfo.cpp io/qfileinfo.h io/qfileinfo_p.h
+ io/qfileselector.cpp io/qfileselector.h io/qfileselector_p.h
+ io/qfilesystemengine.cpp io/qfilesystemengine_p.h
+ io/qfilesystementry.cpp io/qfilesystementry_p.h
+ io/qfilesystemiterator_p.h
+ io/qfilesystemmetadata_p.h
+ io/qfsfileengine.cpp io/qfsfileengine_p.h
+ io/qfsfileengine_iterator.cpp io/qfsfileengine_iterator_p.h
+ io/qiodevice.cpp io/qiodevice.h io/qiodevice_p.h
+ io/qipaddress.cpp io/qipaddress_p.h
+ io/qlockfile.cpp io/qlockfile.h io/qlockfile_p.h
+ io/qloggingcategory.cpp io/qloggingcategory.h
+ io/qloggingregistry.cpp io/qloggingregistry_p.h
+ io/qnoncontiguousbytedevice.cpp io/qnoncontiguousbytedevice_p.h
+ io/qresource.cpp io/qresource_p.h
+ io/qresource_iterator.cpp io/qresource_iterator_p.h
+ io/qsavefile.cpp io/qsavefile.h
+ io/qstandardpaths.cpp io/qstandardpaths.h
+ io/qstorageinfo.cpp io/qstorageinfo.h io/qstorageinfo_p.h
+ io/qtemporarydir.cpp io/qtemporarydir.h
+ io/qtemporaryfile.cpp io/qtemporaryfile.h io/qtemporaryfile_p.h
+ io/qtldurl.cpp io/qtldurl_p.h
+ io/qurl.cpp io/qurl.h io/qurl_p.h
+ io/qurlidna.cpp
+ io/qurlquery.cpp io/qurlquery.h
+ io/qurlrecode.cpp
+ io/qurltlds_p.h
+ itemmodels/qabstractitemmodel.cpp itemmodels/qabstractitemmodel.h itemmodels/qabstractitemmodel_p.h
+ itemmodels/qitemselectionmodel.cpp itemmodels/qitemselectionmodel.h itemmodels/qitemselectionmodel_p.h
+ kernel/qabstracteventdispatcher.cpp kernel/qabstracteventdispatcher.h kernel/qabstracteventdispatcher_p.h
+ kernel/qabstractnativeeventfilter.cpp kernel/qabstractnativeeventfilter.h
+ kernel/qbasictimer.cpp kernel/qbasictimer.h
+ kernel/qcoreapplication.cpp kernel/qcoreapplication.h kernel/qcoreapplication_p.h
+ kernel/qcorecmdlineargs_p.h
+ kernel/qcoreevent.cpp kernel/qcoreevent.h
+ kernel/qcoreglobaldata.cpp kernel/qcoreglobaldata_p.h
+ kernel/qdeadlinetimer.cpp kernel/qdeadlinetimer.h kernel/qdeadlinetimer_p.h
+ kernel/qelapsedtimer.cpp kernel/qelapsedtimer.h
+ kernel/qeventloop.cpp kernel/qeventloop.h
+ kernel/qfunctions_p.h
+ kernel/qmath.cpp kernel/qmath.h
+ kernel/qmetaobject.cpp kernel/qmetaobject.h kernel/qmetaobject_p.h
+ kernel/qmetaobject_moc_p.h
+ kernel/qmetaobjectbuilder.cpp kernel/qmetaobjectbuilder_p.h
+ kernel/qmetatype.cpp kernel/qmetatype.h kernel/qmetatype_p.h
+ kernel/qmetatypeswitcher_p.h
+ kernel/qmimedata.cpp kernel/qmimedata.h
+ kernel/qobject.cpp kernel/qobject.h kernel/qobject_p.h
+ kernel/qobject_impl.h
+ kernel/qobjectcleanuphandler.cpp kernel/qobjectcleanuphandler.h
+ kernel/qobjectdefs.h
+ kernel/qobjectdefs_impl.h
+ kernel/qpointer.cpp kernel/qpointer.h
+ kernel/qsharedmemory.cpp kernel/qsharedmemory.h kernel/qsharedmemory_p.h
+ kernel/qsignalmapper.cpp kernel/qsignalmapper.h
+ kernel/qsocketnotifier.cpp kernel/qsocketnotifier.h
+ kernel/qsystemerror.cpp kernel/qsystemerror_p.h
+ kernel/qsystemsemaphore.cpp kernel/qsystemsemaphore.h kernel/qsystemsemaphore_p.h
+ kernel/qtestsupport_core.cpp kernel/qtestsupport_core.h
+ kernel/qtimer.cpp kernel/qtimer.h
+ kernel/qtranslator.cpp kernel/qtranslator.h kernel/qtranslator_p.h
+ kernel/qvariant.cpp kernel/qvariant.h kernel/qvariant_p.h
+ plugin/qfactoryinterface.cpp plugin/qfactoryinterface.h
+ plugin/qfactoryloader.cpp plugin/qfactoryloader_p.h
+ plugin/qplugin.h plugin/qplugin_p.h
+ plugin/qpluginloader.cpp plugin/qpluginloader.h
+ plugin/quuid.cpp plugin/quuid.h
+ serialization/qcborarray.h
+ serialization/qcborcommon.h
+ serialization/qcbordiagnostic.cpp
+ serialization/qcbormap.h
+ serialization/qcborvalue.cpp serialization/qcborvalue.h serialization/qcborvalue_p.h
+ serialization/qdatastream.cpp serialization/qdatastream.h serialization/qdatastream_p.h
+ serialization/qjson_p.h
+ serialization/qjsonarray.cpp serialization/qjsonarray.h
+ serialization/qjsoncbor.cpp
+ serialization/qjsondocument.cpp serialization/qjsondocument.h
+ serialization/qjsonobject.cpp serialization/qjsonobject.h
+ serialization/qjsonparser.cpp serialization/qjsonparser_p.h
+ serialization/qjsonvalue.cpp serialization/qjsonvalue.h
+ serialization/qjsonwriter.cpp serialization/qjsonwriter_p.h
+ serialization/qtextstream.cpp serialization/qtextstream.h serialization/qtextstream_p.h
+ serialization/qxmlstream.cpp serialization/qxmlstream.h serialization/qxmlstream_p.h
+ serialization/qxmlutils.cpp serialization/qxmlutils_p.h
+ statemachine/qabstractstate.cpp statemachine/qabstractstate.h statemachine/qabstractstate_p.h
+ statemachine/qabstracttransition.cpp statemachine/qabstracttransition.h statemachine/qabstracttransition_p.h
+ statemachine/qfinalstate.cpp statemachine/qfinalstate.h statemachine/qfinalstate_p.h
+ statemachine/qhistorystate.cpp statemachine/qhistorystate.h statemachine/qhistorystate_p.h
+ statemachine/qsignaleventgenerator_p.h
+ statemachine/qsignaltransition.cpp statemachine/qsignaltransition.h statemachine/qsignaltransition_p.h
+ statemachine/qstate.cpp statemachine/qstate.h statemachine/qstate_p.h
+ statemachine/qstatemachine.cpp statemachine/qstatemachine.h statemachine/qstatemachine_p.h
+ text/qbytearray.cpp text/qbytearray.h text/qbytearray_p.h
+ text/qbytearraylist.cpp text/qbytearraylist.h
+ text/qbytearraymatcher.cpp text/qbytearraymatcher.h
+ text/qbytedata_p.h
+ text/qchar.h
+ text/qcollator.cpp text/qcollator.h text/qcollator_p.h
+ text/qdoublescanprint_p.h
+ text/qharfbuzz.cpp text/qharfbuzz_p.h
+ text/qlocale.cpp text/qlocale.h text/qlocale_p.h
+ text/qlocale_data_p.h
+ text/qlocale_tools.cpp text/qlocale_tools_p.h
+ text/qregexp.cpp text/qregexp.h
+ text/qstring.cpp text/qstring.h
+ text/qstring_compat.cpp
+ text/qstringalgorithms.h text/qstringalgorithms_p.h
+ text/qstringbuilder.cpp text/qstringbuilder.h
+ text/qstringiterator_p.h
+ text/qstringlist.cpp text/qstringlist.h
+ text/qstringliteral.h
+ text/qstringmatcher.h
+ text/qstringview.cpp text/qstringview.h
+ text/qtextboundaryfinder.cpp text/qtextboundaryfinder.h
+ text/qunicodetables_p.h
+ text/qunicodetools.cpp text/qunicodetools_p.h
+ text/qvsnprintf.cpp
+ thread/qmutex.h
+ thread/qreadwritelock.h
+ thread/qrunnable.cpp thread/qrunnable.h
+ thread/qthread.cpp thread/qthread.h
+ thread/qthreadstorage.h
+ thread/qwaitcondition.h thread/qwaitcondition_p.h
+ time/qcalendar.cpp time/qcalendar.h
+ time/qcalendarbackend_p.h
+ time/qcalendarmath_p.h
+ time/qdatetime.cpp time/qdatetime.h time/qdatetime_p.h
+ time/qgregoriancalendar.cpp time/qgregoriancalendar_p.h
+ time/qjuliancalendar.cpp time/qjuliancalendar_p.h
+ time/qmilankoviccalendar.cpp time/qmilankoviccalendar_p.h
+ time/qromancalendar.cpp time/qromancalendar_p.h
+ time/qromancalendar_data_p.h
+ tools/qalgorithms.h
+ tools/qarraydata.cpp tools/qarraydata.h
+ tools/qarraydataops.h
+ tools/qarraydatapointer.h
+ tools/qbitarray.cpp tools/qbitarray.h
+ tools/qcache.h
+ tools/qcontainerfwd.h
+ tools/qcontainertools_impl.h
+ tools/qcontiguouscache.cpp tools/qcontiguouscache.h
+ tools/qcryptographichash.cpp tools/qcryptographichash.h
+ tools/qfreelist.cpp tools/qfreelist_p.h
+ tools/qhash.cpp tools/qhash.h
+ tools/qhashfunctions.h
+ tools/qiterator.h
+ tools/qline.cpp tools/qline.h
+ tools/qlinkedlist.cpp tools/qlinkedlist.h
+ tools/qlist.cpp tools/qlist.h
+ tools/qmakearray_p.h
+ tools/qmap.cpp tools/qmap.h
+ tools/qmargins.cpp tools/qmargins.h
+ tools/qmessageauthenticationcode.cpp tools/qmessageauthenticationcode.h
+ tools/qoffsetstringarray_p.h
+ tools/qpair.h
+ tools/qpoint.cpp tools/qpoint.h
+ tools/qqueue.h
+ tools/qrect.cpp tools/qrect.h
+ tools/qrefcount.cpp tools/qrefcount.h
+ tools/qringbuffer.cpp tools/qringbuffer_p.h
+ tools/qscopedpointer.h tools/qscopedpointer_p.h
+ tools/qscopedvaluerollback.h
+ tools/qscopeguard.h
+ tools/qset.h
+ tools/qshareddata.cpp tools/qshareddata.h
+ tools/qsharedpointer.cpp tools/qsharedpointer.h
+ tools/qsharedpointer_impl.h
+ tools/qsimd.cpp tools/qsimd_p.h
+ tools/qsize.cpp tools/qsize.h
+ tools/qstack.h
+ tools/qtools_p.h
+ tools/qvarlengtharray.h
+ tools/qvector.h
+ tools/qversionnumber.cpp tools/qversionnumber.h
+ DEFINES
+ QT_NO_FOREACH
+ QT_NO_USING_NAMESPACE
+ INCLUDE_DIRECTORIES
+ ${PROJECT_BINARY_DIR}/src/corelib/global
+ ../3rdparty/harfbuzz/src
+ ../3rdparty/md4
+ ../3rdparty/md5
+ ../3rdparty/sha3
+ ../3rdparty/tinycbor/src
+ LIBRARIES
+ ZLIB::ZLIB
+ doubleconversion
+ PRECOMPILED_HEADER
+ "global/qt_pch.h"
+ NO_PCH_SOURCES
+ "text/qstring_compat.cpp"
+)
+
+
+qt_add_simd_part(Core SIMD mips_dsp
+ SOURCES
+ ../gui/painting/qt_mips_asm_dsp_p.h
+ text/qstring_mips_dsp_asm.S
+)
+
+
+if(ANDROID)
+ set_property(TARGET Core APPEND PROPERTY QT_ANDROID_BUNDLED_JAR_DEPENDENCIES
+ jar/QtAndroid.jar
+ )
+ set_property(TARGET Core APPEND PROPERTY QT_ANDROID_LIB_DEPENDENCIES
+ plugins/platforms/libplugins_platforms_qtforandroid.so
+ )
+ set_property(TARGET Core APPEND PROPERTY QT_ANDROID_PERMISSIONS
+ android.permission.INTERNET android.permission.WRITE_EXTERNAL_STORAGE
+ )
+endif()
+
+#### Keys ignored in scope 1:.:.:corelib.pro:<TRUE>:
+# CMAKE_DISABLED_FEATURES = "$$join(QT_DISABLED_FEATURES, "$$escape_expand(\\n) ")"
+# CMAKE_HOST_DATA_DIR = "$$cmakeRelativePath($$[QT_HOST_DATA/src], $$[QT_INSTALL_PREFIX])"
+# CMAKE_INSTALL_DATA_DIR = "$$cmakeRelativePath($$[QT_HOST_DATA], $$[QT_INSTALL_PREFIX])"
+# HOST_BINS = "$$[QT_HOST_BINS]"
+# INSTALLS = "ctest_qt5_module_files" "cmake_qt5_umbrella_module_files"
+# MODULE = "core"
+# MODULE_CONFIG = "moc" "resources"
+# QMAKE_DSYM_DEBUG_SCRIPT = "$$PWD/debug_script.py"
+# QMAKE_DYNAMIC_LIST_FILE = "$$PWD/QtCore.dynlist"
+# QMAKE_PKGCONFIG_VARIABLES = "host_bins" "qt_conf"
+# QMAKE_SUBSTITUTES = "ctest_macros_file" "cmake_umbrella_config_file" "cmake_umbrella_config_module_location" "cmake_umbrella_config_module_location_for_install" "cmake_umbrella_config_version_file" "cmake_extras_mkspec_dir" "cmake_extras_mkspec_dir_for_install"
+# cmake_extras_mkspec_dir.input = "$$PWD/Qt5CoreConfigExtrasMkspecDir.cmake.in"
+# cmake_extras_mkspec_dir.output = "$$DESTDIR/cmake/Qt5Core/Qt5CoreConfigExtrasMkspecDir.cmake"
+# cmake_extras_mkspec_dir_for_install.input = "$$PWD/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in"
+# cmake_extras_mkspec_dir_for_install.output = "$$DESTDIR/cmake/install/Qt5Core/Qt5CoreConfigExtrasMkspecDir.cmake"
+# cmake_qt5_umbrella_module_files.files = "$$cmake_umbrella_config_file.output" "$$cmake_umbrella_config_version_file.output" "$$cmake_umbrella_config_module_location_for_install.output"
+# cmake_qt5_umbrella_module_files.path = "$$[QT_INSTALL_LIBS]/cmake/Qt5"
+# cmake_umbrella_config_file.input = "$$PWD/Qt5Config.cmake.in"
+# cmake_umbrella_config_file.output = "$$DESTDIR/cmake/Qt5/Qt5Config.cmake"
+# cmake_umbrella_config_module_location.input = "$$PWD/Qt5ModuleLocation.cmake.in"
+# cmake_umbrella_config_module_location.output = "$$DESTDIR/cmake/Qt5/Qt5ModuleLocation.cmake"
+# cmake_umbrella_config_module_location_for_install.input = "$$PWD/Qt5ModuleLocationForInstall.cmake.in"
+# cmake_umbrella_config_module_location_for_install.output = "$$DESTDIR/cmake/install/Qt5/Qt5ModuleLocation.cmake"
+# cmake_umbrella_config_version_file.input = "$$PWD/../../mkspecs/features/data/cmake/Qt5ConfigVersion.cmake.in"
+# cmake_umbrella_config_version_file.output = "$$DESTDIR/cmake/Qt5/Qt5ConfigVersion.cmake"
+# ctest_macros_file.CONFIG = "verbatim"
+# ctest_macros_file.input = "$$PWD/Qt5CTestMacros.cmake"
+# ctest_macros_file.output = "$$DESTDIR/cmake/Qt5Core/Qt5CTestMacros.cmake"
+# ctest_qt5_module_files.files = "$$ctest_macros_file.output" "$$cmake_extras_mkspec_dir_for_install.output"
+# ctest_qt5_module_files.path = "$$[QT_INSTALL_LIBS]/cmake/Qt5Core"
+# host_bins.name = "host_bins"
+# host_bins.variable = "HOST_BINS"
+# qt_conf.name = "qt_config"
+# qt_conf.variable = "QT_CONFIG"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:corelib.pro:QT_FEATURE_gc_binaries:
+# MODULE_CONFIG = "gc_binaries"
+
+#### Keys ignored in scope 3:.:.:corelib.pro:NOT QT_NAMESPACE_ISEMPTY:
+# MODULE_DEFINES = "QT_NAMESPACE=$$QT_NAMESPACE"
+
+qt_extend_target(Core CONDITION ANDROID
+ SOURCES
+ kernel/qsharedmemory_android.cpp
+ kernel/qsystemsemaphore_android.cpp
+ DEFINES
+ LIBS_SUFFIX='\\"_${CMAKE_SYSTEM_PROCESSOR}.so\\"'
+)
+
+qt_extend_target(Core CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x67000000"
+)
+
+#### Keys ignored in scope 6:.:.:corelib.pro:FREEBSD OR OPENBSD:
+# QMAKE_LFLAGS_NOUNDEF = <EMPTY>
+
+qt_extend_target(Core CONDITION QT_FEATURE_animation
+ SOURCES
+ animation/qabstractanimation.cpp animation/qabstractanimation.h animation/qabstractanimation_p.h
+ animation/qanimationgroup.cpp animation/qanimationgroup.h animation/qanimationgroup_p.h
+ animation/qparallelanimationgroup.cpp animation/qparallelanimationgroup.h animation/qparallelanimationgroup_p.h
+ animation/qpauseanimation.cpp animation/qpauseanimation.h
+ animation/qpropertyanimation.cpp animation/qpropertyanimation.h animation/qpropertyanimation_p.h
+ animation/qsequentialanimationgroup.cpp animation/qsequentialanimationgroup.h animation/qsequentialanimationgroup_p.h
+ animation/qvariantanimation.cpp animation/qvariantanimation.h animation/qvariantanimation_p.h
+)
+
+qt_extend_target(Core CONDITION WIN32
+ SOURCES
+ global/qoperatingsystemversion_win.cpp global/qoperatingsystemversion_win_p.h
+ io/qfilesystemengine_win.cpp
+ io/qfsfileengine_win.cpp
+ io/qlockfile_win.cpp
+ kernel/qcoreapplication_win.cpp
+ kernel/qelapsedtimer_win.cpp
+ kernel/qsharedmemory_win.cpp
+ kernel/qsystemsemaphore_win.cpp
+ kernel/qwineventnotifier.cpp kernel/qwineventnotifier.h kernel/qwineventnotifier_p.h
+ plugin/qsystemlibrary.cpp plugin/qsystemlibrary_p.h
+ thread/qatomic_msvc.h
+ thread/qthread_win.cpp
+ DEFINES
+ -QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ ws2_32
+)
+
+qt_extend_target(Core CONDITION WIN32 AND NOT WINRT
+ SOURCES
+ io/qstandardpaths_win.cpp
+ io/qstorageinfo_win.cpp
+ io/qwindowspipereader.cpp io/qwindowspipereader_p.h
+ io/qwindowspipewriter.cpp io/qwindowspipewriter_p.h
+ kernel/qeventdispatcher_win.cpp kernel/qeventdispatcher_win_p.h
+ kernel/qwinregistry.cpp kernel/qwinregistry_p.h
+ LIBRARIES
+ advapi32
+ kernel32
+ netapi32
+ ole32
+ shell32
+ user32
+ uuid
+ version
+ winmm
+ PUBLIC_LIBRARIES
+ mpr
+ userenv
+)
+
+qt_extend_target(Core CONDITION APPLE
+ SOURCES
+ global/qoperatingsystemversion_darwin.mm
+ io/qstandardpaths_mac.mm
+ io/qstorageinfo_mac.cpp
+ kernel/qcfsocketnotifier.cpp kernel/qcfsocketnotifier_p.h
+ kernel/qcore_foundation.mm
+ kernel/qcore_mac.cpp kernel/qcore_mac_p.h
+ kernel/qcore_mac_objc.mm
+ kernel/qcoreapplication_mac.cpp
+ kernel/qeventdispatcher_cf.mm kernel/qeventdispatcher_cf_p.h
+ LIBRARIES
+ ${FWCoreFoundation}
+ ${FWFoundation}
+)
+
+qt_extend_target(Core CONDITION APPLE_OSX
+ LIBRARIES
+ ${FWAppKit}
+ ${FWApplicationServices}
+ ${FWCoreServices}
+ ${FWSecurity}
+ PUBLIC_LIBRARIES
+ ${FWDiskArbitration}
+ ${FWIOKit}
+)
+
+qt_extend_target(Core CONDITION INTEGRITY
+ LIBRARIES
+ ivfs
+ net
+ posix
+ shm_client
+ socket
+ COMPILE_OPTIONS
+ --pending_instantiations=128
+)
+
+#### Keys ignored in scope 15:.:.:corelib.pro:pathIsAbsolute(_ss_CMAKE_HOST_DATA_DIR):
+# CMAKE_HOST_DATA_DIR = "$$[QT_HOST_DATA/src]/"
+# CMAKE_HOST_DATA_DIR_IS_ABSOLUTE = "True"
+
+#### Keys ignored in scope 16:.:.:corelib.pro:pathIsAbsolute(_ss_CMAKE_INSTALL_DATA_DIR):
+# CMAKE_INSTALL_DATA_DIR = "$$[QT_HOST_DATA]/"
+# CMAKE_INSTALL_DATA_DIR_IS_ABSOLUTE = "True"
+
+#### Keys ignored in scope 21:.:global:global/global.pri:QT_CPU_FEATURES__ss_QT_ARCH___contains___f16c:
+# f16c_cxx = "true"
+
+#### Keys ignored in scope 23:.:global:global/global.pri:CLANG OR intel_icl OR ICC:
+# f16c_cxx = "false"
+
+#### Keys ignored in scope 25:.:global:global/global.pri:GCC AND f16c AND x86SimdAlways:
+# f16c_cxx = "true"
+
+#### Keys ignored in scope 27:.:global:global/global.pri:MSVC AND QT_CPU_FEATURES__ss_QT_ARCH___contains___avx:
+# f16c_cxx = "true"
+
+#### Keys ignored in scope 28:.:global:global/global.pri:else:
+# f16c_cxx = "false"
+
+qt_extend_target(Core CONDITION _ss_f16c_cxx
+ DEFINES
+ QFLOAT16_INCLUDE_FAST
+)
+
+if(NOT _ss_f16c_cxx)
+ qt_add_simd_part(Core SIMD f16c
+ SOURCES
+ global/qfloat16_f16c.c
+ )
+endif()
+
+qt_extend_target(Core CONDITION NOT CMAKE_CROSSCOMPILING AND NOT _x_-armcc_x_ AND NOT static AND (hurd_x_ OR linux_x_)
+ DEFINES
+ ELF_INTERPRETER=\\\"=Creadelf-l/bin/ls|perl-n-e\'['quote', ['if', ['/program', 'interpreter:', ['.*'], ']/'], '{', 'print', '$1;', '}']]\'\\\"
+ LINK_OPTIONS
+ "-Wl,-e,qt_core_boilerplate"
+)
+
+qt_extend_target(Core CONDITION LINUX AND NOT static
+ SOURCES
+ global/minimum-linux_p.h
+)
+
+#### Keys ignored in scope 35:.:global:global/global.pri:precompile_header:
+# NO_PCH_ASM = "global/minimum-linux.S"
+# QMAKE_EXTRA_COMPILERS = "no_pch_assembler"
+# no_pch_assembler.commands = "$$QMAKE_CC" "-c" "$(CFLAGS)" "$(INCPATH)" "${QMAKE_FILE_IN}" "-o" "${QMAKE_FILE_OUT}"
+# no_pch_assembler.dependency_type = "TYPE_C"
+# no_pch_assembler.input = "NO_PCH_ASM"
+# no_pch_assembler.name = "compiling[no_pch]" "${QMAKE_FILE_IN}"
+# no_pch_assembler.output = "${QMAKE_VAR_OBJECTS_DIR}${QMAKE_FILE_BASE}$${firstQMAKE_EXT_OBJ}"
+
+#### Keys ignored in scope 36:.:global:global/global.pri:silent:
+# no_pch_assembler.commands = "@echo" "compiling[no_pch]" "${QMAKE_FILE_IN}" "&&"
+
+qt_extend_target(Core CONDITION LINUX AND NOT precompile_header AND NOT static
+ SOURCES
+ global/minimum-linux.S
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_slog2
+ LIBRARIES
+ Slog2::Slog2
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_journald
+ LIBRARIES
+ PkgConfig::Libsystemd
+)
+
+#### Keys ignored in scope 40:.:global:global/global.pri:GCC AND ltcg:
+# QMAKE_EXTRA_COMPILERS = "versiontagging_compiler"
+# versiontagging_compiler.commands = "$$QMAKE_CXX" "-c" "$(CXXFLAGS)" "$(INCPATH)" "-fno-lto" "-o" "${QMAKE_FILE_OUT}" "${QMAKE_FILE_IN}"
+# versiontagging_compiler.dependency_type = "TYPE_C"
+# versiontagging_compiler.input = "VERSIONTAGGING_SOURCES"
+# versiontagging_compiler.name = "compiling[versiontagging]" "${QMAKE_FILE_IN}"
+# versiontagging_compiler.output = "${QMAKE_VAR_OBJECTS_DIR}${QMAKE_FILE_BASE}$${firstQMAKE_EXT_OBJ}"
+# versiontagging_compiler.variable_out = "OBJECTS"
+
+#### Keys ignored in scope 41:.:global:global/global.pri:silent:
+# versiontagging_compiler.commands = "@echo" "compiling[versiontagging]" "${QMAKE_FILE_IN}" "&&"
+
+qt_extend_target(Core CONDITION NOT GCC OR NOT ltcg
+ SOURCES
+ global/qversiontagging.cpp
+)
+
+qt_extend_target(Core CONDITION UNIX
+ SOURCES
+ io/qfilesystemengine_unix.cpp
+ io/qfilesystemiterator_unix.cpp
+ io/qfsfileengine_unix.cpp
+ io/qlockfile_unix.cpp
+ kernel/qcore_unix.cpp kernel/qcore_unix_p.h
+ kernel/qeventdispatcher_unix.cpp kernel/qeventdispatcher_unix_p.h
+ kernel/qpoll_p.h
+ kernel/qtimerinfo_unix.cpp kernel/qtimerinfo_unix_p.h
+ thread/qthread_unix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_thread
+ SOURCES
+ thread/qatomic.cpp thread/qatomic.h
+ thread/qatomic_bootstrap.h
+ thread/qatomic_cxx11.h
+ thread/qbasicatomic.h
+ thread/qfutex_p.h
+ thread/qgenericatomic.h
+ thread/qlocking_p.h
+ thread/qmutex.cpp thread/qmutex_p.h
+ thread/qorderedmutexlocker_p.h
+ thread/qreadwritelock.cpp thread/qreadwritelock_p.h
+ thread/qsemaphore.cpp thread/qsemaphore.h
+ thread/qthread_p.h
+ thread/qthreadpool.cpp thread/qthreadpool.h thread/qthreadpool_p.h
+ thread/qthreadstorage.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_thread AND WIN32
+ SOURCES
+ thread/qmutex_win.cpp
+ thread/qwaitcondition_win.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_thread AND UNIX
+ SOURCES
+ thread/qwaitcondition_unix.cpp
+)
+
+qt_extend_target(Core CONDITION APPLE AND QT_FEATURE_thread
+ SOURCES
+ thread/qmutex_mac.cpp
+)
+
+qt_extend_target(Core CONDITION LINUX AND QT_FEATURE_thread
+ SOURCES
+ thread/qmutex_linux.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_thread AND UNIX AND NOT APPLE AND NOT LINUX
+ SOURCES
+ thread/qmutex_unix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_future
+ SOURCES
+ thread/qexception.cpp thread/qexception.h
+ thread/qfuture.h
+ thread/qfutureinterface.cpp thread/qfutureinterface.h thread/qfutureinterface_p.h
+ thread/qfuturesynchronizer.h
+ thread/qfuturewatcher.cpp thread/qfuturewatcher.h thread/qfuturewatcher_p.h
+ thread/qresultstore.cpp thread/qresultstore.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_std_atomic64
+ PUBLIC_LIBRARIES
+ Atomic
+)
+
+qt_extend_target(Core CONDITION ICC
+ COMPILE_OPTIONS
+ -fp-model
+ strict
+)
+
+qt_extend_target(Core CONDITION MSVC
+ SOURCES
+ tools/qvector_msvc.cpp
+ NO_PCH_SOURCES
+ "tools/qvector_msvc.cpp"
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_commandlineparser
+ SOURCES
+ tools/qcommandlineoption.cpp tools/qcommandlineoption.h
+ tools/qcommandlineparser.cpp tools/qcommandlineparser.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_easingcurve
+ SOURCES
+ tools/qeasingcurve.cpp tools/qeasingcurve.h
+ tools/qtimeline.cpp tools/qtimeline.h
+)
+
+qt_extend_target(Core CONDITION UNIX AND NOT HAIKU AND NOT INTEGRITY AND NOT VXWORKS AND NOT WASM AND (NOT APPLE_OSX OR NOT ICC)
+ LIBRARIES
+ m
+)
+
+qt_extend_target(Core CONDITION APPLE_OSX AND NOT NACL
+ SOURCES
+ text/qlocale_mac.mm
+)
+
+qt_extend_target(Core CONDITION UNIX AND (NACL OR NOT APPLE_OSX)
+ SOURCES
+ text/qlocale_unix.cpp
+)
+
+qt_extend_target(Core CONDITION WIN32 AND (NACL OR NOT APPLE_OSX)
+ SOURCES
+ text/qlocale_win.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_icu
+ SOURCES
+ text/qcollator_icu.cpp
+ text/qlocale_icu.cpp
+ LIBRARIES
+ ICU::i18n ICU::uc ICU::data
+)
+
+qt_extend_target(Core CONDITION WIN32 AND NOT QT_FEATURE_icu
+ SOURCES
+ text/qcollator_win.cpp
+)
+
+qt_extend_target(Core CONDITION APPLE_OSX AND NOT QT_FEATURE_icu
+ SOURCES
+ text/qcollator_macx.cpp
+)
+
+qt_extend_target(Core CONDITION UNIX AND NOT APPLE_OSX AND NOT QT_FEATURE_icu
+ SOURCES
+ text/qcollator_posix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_regularexpression
+ SOURCES
+ text/qregularexpression.cpp text/qregularexpression.h
+ LIBRARIES
+ WrapPCRE2::WrapPCRE2
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_hijricalendar
+ SOURCES
+ time/qhijricalendar.cpp time/qhijricalendar_p.h
+ time/qhijricalendar_data_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_islamiccivilcalendar
+ SOURCES
+ time/qislamiccivilcalendar.cpp time/qislamiccivilcalendar_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_jalalicalendar
+ SOURCES
+ time/qjalalicalendar.cpp time/qjalalicalendar_p.h
+ time/qjalalicalendar_data_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_timezone
+ SOURCES
+ time/qtimezone.cpp time/qtimezone.h
+ time/qtimezoneprivate.cpp time/qtimezoneprivate_p.h
+ time/qtimezoneprivate_data_p.h
+)
+
+qt_extend_target(Core CONDITION APPLE AND QT_FEATURE_timezone AND NOT NACL
+ SOURCES
+ time/qtimezoneprivate_mac.mm
+)
+
+qt_extend_target(Core CONDITION ANDROID AND QT_FEATURE_timezone AND NOT ANDROID_EMBEDDED AND (NACL OR NOT APPLE)
+ SOURCES
+ time/qtimezoneprivate_android.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_timezone AND UNIX AND (ANDROID_EMBEDDED OR NOT ANDROID) AND (NACL OR NOT APPLE)
+ SOURCES
+ time/qtimezoneprivate_tz.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_icu AND QT_FEATURE_timezone AND UNIX AND (ANDROID_EMBEDDED OR NOT ANDROID) AND (NACL OR NOT APPLE)
+ SOURCES
+ time/qtimezoneprivate_icu.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_icu AND QT_FEATURE_timezone AND WIN32 AND (ANDROID_EMBEDDED OR NOT ANDROID) AND (NACL OR NOT APPLE)
+ SOURCES
+ time/qtimezoneprivate_icu.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_timezone AND WIN32 AND NOT QT_FEATURE_icu AND (ANDROID_EMBEDDED OR NOT ANDROID) AND (NACL OR NOT APPLE)
+ SOURCES
+ time/qtimezoneprivate_win.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_datetimeparser
+ SOURCES
+ time/qdatetimeparser.cpp time/qdatetimeparser_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_zstd
+ LIBRARIES
+ ZSTD::ZSTD
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_filesystemwatcher
+ SOURCES
+ io/qfilesystemwatcher.cpp io/qfilesystemwatcher.h io/qfilesystemwatcher_p.h
+ io/qfilesystemwatcher_polling.cpp io/qfilesystemwatcher_polling_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_filesystemwatcher AND WIN32
+ SOURCES
+ io/qfilesystemwatcher_win.cpp io/qfilesystemwatcher_win_p.h
+)
+
+qt_extend_target(Core CONDITION APPLE_OSX AND QT_FEATURE_filesystemwatcher
+ SOURCES
+ io/qfilesystemwatcher_fsevents.mm io/qfilesystemwatcher_fsevents_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_filesystemwatcher AND QT_FEATURE_inotify AND UNIX AND NOT APPLE_OSX
+ SOURCES
+ io/qfilesystemwatcher_inotify.cpp io/qfilesystemwatcher_inotify_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_filesystemwatcher AND UNIX AND NOT APPLE_OSX AND NOT QT_FEATURE_inotify AND (APPLE OR FREEBSD OR NETBSD OR OPENBSD)
+ SOURCES
+ io/qfilesystemwatcher_kqueue.cpp io/qfilesystemwatcher_kqueue_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_processenvironment
+ SOURCES
+ io/qprocess.cpp io/qprocess.h io/qprocess_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_processenvironment AND WIN32 AND NOT WINRT
+ SOURCES
+ io/qprocess_win.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_processenvironment AND UNIX
+ SOURCES
+ io/qprocess_unix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_settings
+ SOURCES
+ io/qsettings.cpp io/qsettings.h io/qsettings_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_settings AND WIN32 AND NOT WINRT
+ SOURCES
+ io/qsettings_win.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_settings AND WINRT
+ SOURCES
+ io/qsettings_winrt.cpp
+)
+
+qt_extend_target(Core CONDITION APPLE AND QT_FEATURE_settings AND NOT NACL
+ SOURCES
+ io/qsettings_mac.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_filesystemiterator AND WIN32
+ SOURCES
+ io/qfilesystemiterator_win.cpp
+)
+
+qt_extend_target(Core CONDITION WINRT
+ SOURCES
+ io/qstandardpaths_winrt.cpp
+ io/qstorageinfo_stub.cpp
+ kernel/qeventdispatcher_winrt.cpp kernel/qeventdispatcher_winrt_p.h
+ kernel/qfunctions_fake_env_p.h
+ kernel/qfunctions_winrt.cpp kernel/qfunctions_winrt.h
+)
+
+qt_extend_target(Core CONDITION UNIX AND NOT APPLE_UIKIT AND NOT INTEGRITY AND NOT rtems
+ SOURCES
+ ../3rdparty/forkfd/forkfd.h
+ io/forkfd_qt.cpp
+ INCLUDE_DIRECTORIES
+ ../3rdparty/forkfd
+)
+
+qt_extend_target(Core CONDITION APPLE AND QT_FEATURE_processenvironment
+ SOURCES
+ io/qprocess_darwin.mm
+)
+
+qt_extend_target(Core CONDITION APPLE AND NOT APPLE_OSX
+ PUBLIC_LIBRARIES
+ ${FWMobileCoreServices}
+)
+
+qt_extend_target(Core CONDITION ANDROID AND NOT ANDROID_EMBEDDED
+ SOURCES
+ io/qstandardpaths_android.cpp
+ io/qstorageinfo_unix.cpp
+ kernel/qjni.cpp kernel/qjni_p.h
+ kernel/qjnihelpers.cpp kernel/qjnihelpers_p.h
+ kernel/qjnionload.cpp
+)
+
+qt_extend_target(Core CONDITION HAIKU AND (ANDROID_EMBEDDED OR NOT ANDROID)
+ SOURCES
+ io/qstandardpaths_haiku.cpp
+ io/qstorageinfo_unix.cpp
+ PUBLIC_LIBRARIES
+ be
+)
+
+qt_extend_target(Core CONDITION UNIX AND NOT APPLE AND NOT HAIKU AND (ANDROID_EMBEDDED OR NOT ANDROID)
+ SOURCES
+ io/qstandardpaths_unix.cpp
+ io/qstorageinfo_unix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_proxymodel
+ SOURCES
+ itemmodels/qabstractproxymodel.cpp itemmodels/qabstractproxymodel.h itemmodels/qabstractproxymodel_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_concatenatetablesproxymodel AND QT_FEATURE_proxymodel
+ SOURCES
+ itemmodels/qconcatenatetablesproxymodel.cpp itemmodels/qconcatenatetablesproxymodel.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_identityproxymodel AND QT_FEATURE_proxymodel
+ SOURCES
+ itemmodels/qidentityproxymodel.cpp itemmodels/qidentityproxymodel.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_proxymodel AND QT_FEATURE_sortfilterproxymodel
+ SOURCES
+ itemmodels/qsortfilterproxymodel.cpp itemmodels/qsortfilterproxymodel.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_proxymodel AND QT_FEATURE_transposeproxymodel
+ SOURCES
+ itemmodels/qtransposeproxymodel.cpp itemmodels/qtransposeproxymodel.h itemmodels/qtransposeproxymodel_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_stringlistmodel
+ SOURCES
+ itemmodels/qstringlistmodel.cpp itemmodels/qstringlistmodel.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_library
+ SOURCES
+ plugin/qelfparser_p.cpp plugin/qelfparser_p.h
+ plugin/qlibrary.cpp plugin/qlibrary.h plugin/qlibrary_p.h
+ plugin/qmachparser.cpp plugin/qmachparser_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_library AND UNIX
+ SOURCES
+ plugin/qlibrary_unix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_library AND WIN32
+ SOURCES
+ plugin/qlibrary_win.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_dlopen AND QT_FEATURE_library
+ LIBRARIES
+ ${CMAKE_DL_LIBS}
+)
+
+qt_extend_target(Core CONDITION APPLE AND NOT NACL
+ SOURCES
+ kernel/qelapsedtimer_mac.cpp
+)
+
+qt_extend_target(Core CONDITION APPLE AND (APPLE_IOS OR APPLE_TVOS)
+ LIBRARIES
+ ${FWUIKit}
+)
+
+qt_extend_target(Core CONDITION APPLE_WATCHOS
+ LIBRARIES
+ ${FWWatchKit}
+)
+
+qt_extend_target(Core CONDITION NACL
+ SOURCES
+ kernel/qfunctions_nacl.cpp kernel/qfunctions_nacl.h
+)
+
+qt_extend_target(Core CONDITION INTEGRITY OR (NACL AND UNIX) OR (UNIX AND NOT APPLE)
+ SOURCES
+ kernel/qelapsedtimer_unix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_poll_select AND UNIX
+ SOURCES
+ kernel/qpoll.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_glib AND UNIX
+ SOURCES
+ kernel/qeventdispatcher_glib.cpp kernel/qeventdispatcher_glib_p.h
+ LIBRARIES
+ GLIB2::GLIB2
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_clock_gettime AND UNIX
+ LIBRARIES
+ WrapRt
+)
+
+qt_extend_target(Core CONDITION UNIX AND NOT ANDROID
+ SOURCES
+ kernel/qsharedmemory_posix.cpp
+ kernel/qsharedmemory_systemv.cpp
+ kernel/qsharedmemory_unix.cpp
+ kernel/qsystemsemaphore_posix.cpp
+ kernel/qsystemsemaphore_systemv.cpp
+ kernel/qsystemsemaphore_unix.cpp
+)
+
+qt_extend_target(Core CONDITION VXWORKS
+ SOURCES
+ kernel/qfunctions_vxworks.cpp kernel/qfunctions_vxworks.h
+)
+
+qt_extend_target(Core CONDITION QNX AND QT_FEATURE_qqnx_pps
+ SOURCES
+ kernel/qppsattribute.cpp kernel/qppsattribute_p.h
+ kernel/qppsattributeprivate_p.h
+ kernel/qppsobject.cpp kernel/qppsobject_p.h
+ kernel/qppsobjectprivate_p.h
+ LIBRARIES
+ PPS::PPS
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_textcodec
+ SOURCES
+ codecs/qlatincodec.cpp codecs/qlatincodec_p.h
+ codecs/qsimplecodec.cpp codecs/qsimplecodec_p.h
+ codecs/qtextcodec.cpp codecs/qtextcodec.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_codecs AND QT_FEATURE_textcodec
+ SOURCES
+ codecs/qisciicodec.cpp codecs/qisciicodec_p.h
+ codecs/qtsciicodec.cpp codecs/qtsciicodec_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_icu AND QT_FEATURE_textcodec
+ SOURCES
+ codecs/qicucodec.cpp codecs/qicucodec_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_big_codecs AND QT_FEATURE_textcodec AND NOT QT_FEATURE_icu
+ SOURCES
+ codecs/qbig5codec.cpp codecs/qbig5codec_p.h
+ codecs/qeucjpcodec.cpp codecs/qeucjpcodec_p.h
+ codecs/qeuckrcodec.cpp codecs/qeuckrcodec_p.h
+ codecs/qgb18030codec.cpp codecs/qgb18030codec_p.h
+ codecs/qjiscodec.cpp codecs/qjiscodec_p.h
+ codecs/qjpunicode.cpp
+ codecs/qsjiscodec.cpp codecs/qsjiscodec_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_iconv AND QT_FEATURE_textcodec AND NOT QT_FEATURE_icu
+ SOURCES
+ codecs/qiconvcodec.cpp codecs/qiconvcodec_p.h
+ LIBRARIES
+ iconv
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_textcodec AND WIN32 AND NOT QT_FEATURE_icu
+ SOURCES
+ codecs/qwindowscodec.cpp codecs/qwindowscodec_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_cborstream
+ SOURCES
+ serialization/qcborstream.cpp serialization/qcborstream.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_binaryjson
+ SOURCES
+ serialization/qbinaryjson.cpp serialization/qbinaryjson_p.h
+ serialization/qbinaryjsonarray.cpp serialization/qbinaryjsonarray_p.h
+ serialization/qbinaryjsonobject.cpp serialization/qbinaryjsonobject_p.h
+ serialization/qbinaryjsonvalue.cpp serialization/qbinaryjsonvalue_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_qeventtransition
+ SOURCES
+ statemachine/qeventtransition.cpp statemachine/qeventtransition.h statemachine/qeventtransition_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_mimetype
+ SOURCES
+ mimetypes/qmimedatabase.cpp mimetypes/qmimedatabase.h mimetypes/qmimedatabase_p.h
+ mimetypes/qmimeglobpattern.cpp mimetypes/qmimeglobpattern_p.h
+ mimetypes/qmimemagicrule.cpp mimetypes/qmimemagicrule_p.h
+ mimetypes/qmimemagicrulematcher.cpp mimetypes/qmimemagicrulematcher_p.h
+ mimetypes/qmimeprovider.cpp mimetypes/qmimeprovider_p.h
+ mimetypes/qmimetype.cpp mimetypes/qmimetype.h mimetypes/qmimetype_p.h
+ mimetypes/qmimetypeparser.cpp mimetypes/qmimetypeparser_p.h
+)
+
+if(QT_FEATURE_mimetype AND QT_FEATURE_mimetype_database)
+ # Resources:
+ set_source_files_properties("mimetypes/mime/packages/freedesktop.org.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "freedesktop.org.xml"
+ )
+ set(mimetypes_resource_files
+ "mime/packages/freedesktop.org.xml"
+ )
+
+ qt_add_resource(Core "mimetypes"
+ PREFIX
+ "/qt-project.org/qmime/packages"
+ BASE
+ "mimetypes"
+ FILES
+ ${mimetypes_resource_files}
+ )
+endif()
+
+qt_extend_target(Core CONDITION WASM
+ SOURCES
+ platform/wasm/qstdweb.cpp platform/wasm/qstdweb_p.h
+)
+
+
+qt_create_tracepoints(Core qtcore.tracepoints)
+qt_add_docs(Core
+ doc/qtcore.qdocconf
+)
+
diff --git a/src/corelib/CMakeLists.txt b/src/corelib/CMakeLists.txt
new file mode 100644
index 0000000000..77f0d5a02d
--- /dev/null
+++ b/src/corelib/CMakeLists.txt
@@ -0,0 +1,1166 @@
+# Generated from corelib.pro.
+
+# special case begin
+qt_find_package(Threads PROVIDED_TARGETS Threads::Threads)
+qt_find_package(WrapDoubleConversion REQUIRED
+ PROVIDED_TARGETS WrapDoubleConversion::WrapDoubleConversion)
+
+if (NOT WrapDoubleConversion_FOUND)
+ message(FATAL_ERROR "Your C library does not provide \
+ sscanf_l/snprintf_l _snprintf_l/_sscanf_l. \
+ You need to use libdouble-conversion for double/string conversion.")
+endif()
+
+# compute the reverse relative path from QtCoreConfigExtras to the install prefix
+# this is used in QtCoreConfigExtras to make its install paths relocatable
+if(QT_WILL_INSTALL)
+ get_filename_component(_clean_prefix "${CMAKE_INSTALL_PREFIX}/${QT_CONFIG_INSTALL_DIR}" ABSOLUTE)
+else()
+ get_filename_component(_clean_prefix "${QT_CONFIG_BUILD_DIR}" ABSOLUTE)
+endif()
+file(RELATIVE_PATH QT_INVERSE_CONFIG_INSTALL_DIR ${_clean_prefix} ${CMAKE_INSTALL_PREFIX})
+
+# special case end
+
+#####################################################################
+## Core Module:
+#####################################################################
+
+qt_add_module(Core
+ GENERATE_METATYPES
+ QMAKE_MODULE_CONFIG moc resources
+ EXCEPTIONS
+ SOURCES
+ # special case: remove ../3rdparty/harfbuzz
+ codecs/qtextcodec_p.h
+ codecs/qutfcodec.cpp codecs/qutfcodec_p.h
+ global/archdetect.cpp
+ global/qcompilerdetection.h
+ global/qendian.cpp global/qendian.h global/qendian_p.h
+ global/qflags.h
+ global/qfloat16.cpp global/qfloat16.h
+ global/qglobal.cpp global/qglobal.h
+ global/qglobalstatic.h
+ global/qhooks.cpp global/qhooks_p.h
+ global/qisenum.h
+ global/qlibraryinfo.cpp global/qlibraryinfo.h
+ global/qlogging.cpp global/qlogging.h
+ global/qmalloc.cpp
+ global/qmemory_p.h
+ # global/qnamespace.h # special case
+ global/qnumeric.cpp global/qnumeric.h global/qnumeric_p.h
+ global/qoperatingsystemversion.cpp global/qoperatingsystemversion.h global/qoperatingsystemversion_p.h
+ global/qprocessordetection.h
+ global/qrandom.cpp global/qrandom.h global/qrandom_p.h
+ global/qsysinfo.h
+ global/qsystemdetection.h
+ global/qtypeinfo.h
+ global/qtypetraits.h
+ global/qversiontagging.cpp global/qversiontagging.h # special case
+ io/qabstractfileengine.cpp io/qabstractfileengine_p.h
+ io/qbuffer.cpp io/qbuffer.h
+ io/qdataurl.cpp io/qdataurl_p.h
+ io/qdebug.cpp io/qdebug.h io/qdebug_p.h
+ io/qdir.cpp io/qdir.h io/qdir_p.h
+ io/qdiriterator.cpp io/qdiriterator.h
+ io/qfile.cpp io/qfile.h
+ io/qfiledevice.cpp io/qfiledevice.h io/qfiledevice_p.h
+ io/qfileinfo.cpp io/qfileinfo.h io/qfileinfo_p.h
+ io/qfileselector.cpp io/qfileselector.h io/qfileselector_p.h
+ io/qfilesystemengine.cpp io/qfilesystemengine_p.h
+ io/qfilesystementry.cpp io/qfilesystementry_p.h
+ io/qfilesystemiterator_p.h
+ io/qfilesystemmetadata_p.h
+ io/qfsfileengine.cpp io/qfsfileengine_p.h
+ io/qfsfileengine_iterator.cpp io/qfsfileengine_iterator_p.h
+ io/qiodevice.cpp io/qiodevice.h io/qiodevice_p.h
+ io/qipaddress.cpp io/qipaddress_p.h
+ io/qlockfile.cpp io/qlockfile.h io/qlockfile_p.h
+ io/qloggingcategory.cpp io/qloggingcategory.h
+ io/qloggingregistry.cpp io/qloggingregistry_p.h
+ io/qnoncontiguousbytedevice.cpp io/qnoncontiguousbytedevice_p.h
+ io/qresource.cpp io/qresource_p.h
+ io/qresource_iterator.cpp io/qresource_iterator_p.h
+ io/qsavefile.cpp io/qsavefile.h
+ io/qstandardpaths.cpp io/qstandardpaths.h
+ io/qstorageinfo.cpp io/qstorageinfo.h io/qstorageinfo_p.h
+ io/qtemporarydir.cpp io/qtemporarydir.h
+ io/qtemporaryfile.cpp io/qtemporaryfile.h io/qtemporaryfile_p.h
+ io/qtldurl.cpp io/qtldurl_p.h
+ io/qurl.cpp io/qurl.h io/qurl_p.h
+ io/qurlidna.cpp
+ io/qurlquery.cpp io/qurlquery.h
+ io/qurlrecode.cpp
+ io/qurltlds_p.h
+ itemmodels/qabstractitemmodel.cpp itemmodels/qabstractitemmodel.h itemmodels/qabstractitemmodel_p.h
+ itemmodels/qitemselectionmodel.cpp itemmodels/qitemselectionmodel.h itemmodels/qitemselectionmodel_p.h
+ kernel/qabstracteventdispatcher.cpp kernel/qabstracteventdispatcher.h kernel/qabstracteventdispatcher_p.h
+ kernel/qabstractnativeeventfilter.cpp kernel/qabstractnativeeventfilter.h
+ kernel/qbasictimer.cpp kernel/qbasictimer.h
+ kernel/qcoreapplication.cpp kernel/qcoreapplication.h kernel/qcoreapplication_p.h
+ kernel/qcorecmdlineargs_p.h
+ kernel/qcoreevent.cpp kernel/qcoreevent.h
+ kernel/qcoreglobaldata.cpp kernel/qcoreglobaldata_p.h
+ kernel/qdeadlinetimer.cpp kernel/qdeadlinetimer.h kernel/qdeadlinetimer_p.h
+ kernel/qelapsedtimer.cpp kernel/qelapsedtimer.h
+ kernel/qeventloop.cpp kernel/qeventloop.h
+ kernel/qfunctions_p.h
+ kernel/qmath.cpp kernel/qmath.h
+ kernel/qmetaobject.cpp kernel/qmetaobject.h kernel/qmetaobject_p.h
+ kernel/qmetaobject_moc_p.h
+ kernel/qmetaobjectbuilder.cpp kernel/qmetaobjectbuilder_p.h
+ kernel/qmetatype.cpp kernel/qmetatype.h kernel/qmetatype_p.h
+ kernel/qmetatypeswitcher_p.h
+ kernel/qmimedata.cpp kernel/qmimedata.h
+ # kernel/qobject.cpp kernel/qobject.h kernel/qobject_p.h # special case
+ kernel/qobject_impl.h
+ kernel/qobjectcleanuphandler.cpp kernel/qobjectcleanuphandler.h
+ kernel/qobjectdefs.h
+ kernel/qobjectdefs_impl.h
+ kernel/qpointer.cpp kernel/qpointer.h
+ kernel/qsharedmemory.cpp kernel/qsharedmemory.h kernel/qsharedmemory_p.h
+ kernel/qsignalmapper.cpp kernel/qsignalmapper.h
+ kernel/qsocketnotifier.cpp kernel/qsocketnotifier.h
+ kernel/qsystemerror.cpp kernel/qsystemerror_p.h
+ kernel/qsystemsemaphore.cpp kernel/qsystemsemaphore.h kernel/qsystemsemaphore_p.h
+ kernel/qtestsupport_core.cpp kernel/qtestsupport_core.h
+ kernel/qtimer.cpp kernel/qtimer.h
+ kernel/qtranslator.cpp kernel/qtranslator.h kernel/qtranslator_p.h
+ kernel/qvariant.cpp kernel/qvariant.h kernel/qvariant_p.h
+ plugin/qfactoryinterface.cpp plugin/qfactoryinterface.h
+ plugin/qfactoryloader.cpp plugin/qfactoryloader_p.h
+ plugin/qplugin.h plugin/qplugin_p.h
+ plugin/qpluginloader.cpp plugin/qpluginloader.h
+ plugin/quuid.cpp plugin/quuid.h
+ serialization/qcborarray.h
+ serialization/qcborcommon.h
+ serialization/qcbordiagnostic.cpp
+ serialization/qcbormap.h
+ serialization/qcborvalue.cpp serialization/qcborvalue.h serialization/qcborvalue_p.h
+ serialization/qdatastream.cpp serialization/qdatastream.h serialization/qdatastream_p.h
+ serialization/qjson_p.h
+ serialization/qjsonarray.cpp serialization/qjsonarray.h
+ serialization/qjsoncbor.cpp
+ serialization/qjsondocument.cpp serialization/qjsondocument.h
+ serialization/qjsonobject.cpp serialization/qjsonobject.h
+ serialization/qjsonparser.cpp serialization/qjsonparser_p.h
+ serialization/qjsonvalue.cpp serialization/qjsonvalue.h
+ serialization/qjsonwriter.cpp serialization/qjsonwriter_p.h
+ serialization/qtextstream.cpp serialization/qtextstream.h serialization/qtextstream_p.h
+ serialization/qxmlstream.cpp serialization/qxmlstream.h serialization/qxmlstream_p.h
+ serialization/qxmlutils.cpp serialization/qxmlutils_p.h
+ statemachine/qabstractstate.cpp statemachine/qabstractstate.h statemachine/qabstractstate_p.h
+ statemachine/qabstracttransition.cpp statemachine/qabstracttransition.h statemachine/qabstracttransition_p.h
+ statemachine/qfinalstate.cpp statemachine/qfinalstate.h statemachine/qfinalstate_p.h
+ statemachine/qhistorystate.cpp statemachine/qhistorystate.h statemachine/qhistorystate_p.h
+ statemachine/qsignaleventgenerator_p.h
+ statemachine/qsignaltransition.cpp statemachine/qsignaltransition.h statemachine/qsignaltransition_p.h
+ statemachine/qstate.cpp statemachine/qstate.h statemachine/qstate_p.h
+ statemachine/qstatemachine.cpp statemachine/qstatemachine.h statemachine/qstatemachine_p.h
+ text/qbytearray.cpp text/qbytearray.h text/qbytearray_p.h
+ text/qbytearraylist.cpp text/qbytearraylist.h
+ text/qbytearraymatcher.cpp text/qbytearraymatcher.h
+ text/qbytedata_p.h
+ text/qchar.h
+ text/qcollator.cpp text/qcollator.h text/qcollator_p.h
+ text/qdoublescanprint_p.h
+ text/qharfbuzz.cpp text/qharfbuzz_p.h
+ text/qlocale.cpp text/qlocale.h text/qlocale_p.h
+ text/qlocale_data_p.h
+ text/qlocale_tools.cpp text/qlocale_tools_p.h
+ text/qregexp.cpp text/qregexp.h
+ text/qstring.cpp text/qstring.h
+ text/qstring_compat.cpp
+ text/qstringalgorithms.h text/qstringalgorithms_p.h
+ text/qstringbuilder.cpp text/qstringbuilder.h
+ text/qstringiterator_p.h
+ text/qstringlist.cpp text/qstringlist.h
+ text/qstringliteral.h
+ text/qstringmatcher.h
+ text/qstringview.cpp text/qstringview.h
+ text/qtextboundaryfinder.cpp text/qtextboundaryfinder.h
+ text/qunicodetables_p.h
+ text/qunicodetools.cpp text/qunicodetools_p.h
+ text/qvsnprintf.cpp
+ thread/qmutex.h
+ thread/qreadwritelock.h
+ thread/qrunnable.cpp thread/qrunnable.h
+ thread/qthread.cpp thread/qthread.h
+ thread/qthreadstorage.h
+ thread/qwaitcondition.h thread/qwaitcondition_p.h
+ time/qcalendar.cpp time/qcalendar.h
+ time/qcalendarbackend_p.h
+ time/qcalendarmath_p.h
+ time/qdatetime.cpp time/qdatetime.h time/qdatetime_p.h
+ time/qgregoriancalendar.cpp time/qgregoriancalendar_p.h
+ time/qjuliancalendar.cpp time/qjuliancalendar_p.h
+ time/qmilankoviccalendar.cpp time/qmilankoviccalendar_p.h
+ time/qromancalendar.cpp time/qromancalendar_p.h
+ time/qromancalendar_data_p.h
+ tools/qalgorithms.h
+ tools/qarraydata.cpp tools/qarraydata.h
+ tools/qarraydataops.h
+ tools/qarraydatapointer.h
+ tools/qbitarray.cpp tools/qbitarray.h
+ tools/qcache.h
+ tools/qcontainerfwd.h
+ tools/qcontainertools_impl.h
+ tools/qcontiguouscache.cpp tools/qcontiguouscache.h
+ tools/qcryptographichash.cpp tools/qcryptographichash.h
+ tools/qfreelist.cpp tools/qfreelist_p.h
+ tools/qhash.cpp tools/qhash.h
+ tools/qhashfunctions.h
+ tools/qiterator.h
+ tools/qline.cpp tools/qline.h
+ tools/qlinkedlist.cpp tools/qlinkedlist.h
+ tools/qlist.cpp tools/qlist.h
+ tools/qmakearray_p.h
+ tools/qmap.cpp tools/qmap.h
+ tools/qmargins.cpp tools/qmargins.h
+ tools/qmessageauthenticationcode.cpp tools/qmessageauthenticationcode.h
+ tools/qoffsetstringarray_p.h
+ tools/qpair.h
+ tools/qpoint.cpp tools/qpoint.h
+ tools/qqueue.h
+ tools/qrect.cpp tools/qrect.h
+ tools/qrefcount.cpp tools/qrefcount.h
+ tools/qringbuffer.cpp tools/qringbuffer_p.h
+ tools/qscopedpointer.h tools/qscopedpointer_p.h
+ tools/qscopedvaluerollback.h
+ tools/qscopeguard.h
+ tools/qset.h
+ tools/qshareddata.cpp tools/qshareddata.h
+ tools/qsharedpointer.cpp tools/qsharedpointer.h
+ tools/qsharedpointer_impl.h
+ tools/qsimd.cpp tools/qsimd_p.h
+ tools/qsize.cpp tools/qsize.h
+ tools/qstack.h
+ tools/qtools_p.h
+ tools/qvarlengtharray.h
+ tools/qvector.h
+ tools/qversionnumber.cpp tools/qversionnumber.h
+ DEFINES
+ QT_NO_FOREACH
+ QT_NO_USING_NAMESPACE
+ INCLUDE_DIRECTORIES
+ "${CMAKE_CURRENT_BINARY_DIR}/global" # special case
+ ../3rdparty/tinycbor/src
+ # special case: remove ../3rdparty/...
+ PRECOMPILED_HEADER
+ global/qt_pch.h
+ NO_PCH_SOURCES
+ "text/qstring_compat.cpp"
+ LIBRARIES
+ ZLIB::ZLIB
+ # double-conversion # special case
+ Qt::GlobalConfigPrivate # special case
+ QtHarfBuzz # special case
+ Threads::Threads # special case
+ WrapDoubleConversion::WrapDoubleConversion # special case
+ PUBLIC_LIBRARIES # special case:
+ Qt::Platform # special case:
+ # special case begin
+ # Generated in QtBaseGlobalTargets
+ EXTRA_CMAKE_FILES ${QT_CORE_RESOURCE_GENERATED_FILE_PATH}
+ EXTRA_CMAKE_INCLUDES ${QT_CORE_RESOURCE_GENERATED_FILE_NAME}
+ # special case end
+)
+
+# special case begin
+add_dependencies(Core ${QT_CMAKE_EXPORT_NAMESPACE}::moc)
+add_dependencies(Core ${QT_CMAKE_EXPORT_NAMESPACE}::rcc)
+add_dependencies(CorePrivate ${QT_CMAKE_EXPORT_NAMESPACE}::moc)
+add_dependencies(CorePrivate ${QT_CMAKE_EXPORT_NAMESPACE}::rcc)
+
+if (QT_NAMESPACE STREQUAL "")
+else()
+ target_compile_definitions(Core PUBLIC "QT_NAMESPACE=${QT_NAMESPACE}")
+endif()
+
+qt_generate_qconfig_cpp()
+
+# Handle QObject: Automoc does not work for this as it would
+# require to spill internals into users:
+add_library(Core_qobject OBJECT)
+qt_manual_moc(qobject_moc_files kernel/qobject.h global/qnamespace.h)
+set_source_files_properties(${qobject_moc_files} PROPERTIES HEADER_FILE_ONLY ON)
+target_sources(Core_qobject PRIVATE
+ global/qnamespace.h
+ kernel/qobject.cpp kernel/qobject.h kernel/qobject_p.h ${qobject_moc_files})
+set_target_properties(Core_qobject PROPERTIES
+ COMPILE_OPTIONS $<TARGET_PROPERTY:Core,COMPILE_OPTIONS>
+ COMPILE_DEFINITIONS $<TARGET_PROPERTY:Core,COMPILE_DEFINITIONS>
+ INCLUDE_DIRECTORIES $<TARGET_PROPERTY:Core,INCLUDE_DIRECTORIES>
+)
+target_include_directories(Core_qobject PRIVATE "${CMAKE_CURRENT_BINARY_DIR}/kernel") # for moc_qobject.cpp
+target_link_libraries(Core_qobject PRIVATE Qt::Platform Qt::GlobalConfig)
+target_link_libraries(Core PRIVATE Core_qobject)
+
+if(NOT BUILD_SHARED_LIBS)
+ install(
+ TARGETS Core_qobject
+ EXPORT "${INSTALL_CMAKE_NAMESPACE}Targets"
+ )
+endif()
+
+set_property(TARGET Core APPEND PROPERTY
+ PUBLIC_HEADER "${CMAKE_CURRENT_BINARY_DIR}/global/qconfig.h")
+set_property(TARGET Core APPEND PROPERTY
+ PRIVATE_HEADER "${CMAKE_CURRENT_BINARY_DIR}/global/qconfig_p.h")
+
+# Find ELF interpreter and define a macro for that:
+if (LINUX AND NOT CMAKE_CROSSCOMPILING AND BUILD_SHARED_LIBS)
+ if (NOT DEFINED ELF_INTERPRETER)
+ execute_process(COMMAND ${CMAKE_COMMAND} -E env LC_ALL=C readelf -l /bin/ls
+ RESULT_VARIABLE readelf_ok
+ OUTPUT_VARIABLE readelf_output
+ )
+ if ("${readelf_ok}" STREQUAL "0"
+ AND "${readelf_output}" MATCHES "program interpreter: (.*)]")
+ set(ELF_INTERPRETER "${CMAKE_MATCH_1}" CACHE INTERNAL "ELF interpreter location")
+ else()
+ set(ELF_INTERPRETER "" CACHE INTERNAL "ELF interpreter location")
+ endif()
+ endif()
+ if (ELF_INTERPRETER)
+ target_link_options(Core PRIVATE "-Wl,-e,qt_core_boilerplate")
+ target_compile_definitions(Core PRIVATE ELF_INTERPRETER="${ELF_INTERPRETER}")
+ endif()
+endif()
+# special case end
+
+qt_add_simd_part(Core SIMD mips_dsp
+ SOURCES
+ ../gui/painting/qt_mips_asm_dsp_p.h
+ text/qstring_mips_dsp_asm.S
+)
+
+
+if(ANDROID)
+ set_property(TARGET Core APPEND PROPERTY QT_ANDROID_BUNDLED_JAR_DEPENDENCIES
+ jar/QtAndroid.jar
+ )
+ set_property(TARGET Core APPEND PROPERTY QT_ANDROID_LIB_DEPENDENCIES
+ plugins/platforms/libplugins_platforms_qtforandroid.so
+ )
+ set_property(TARGET Core APPEND PROPERTY QT_ANDROID_PERMISSIONS
+ android.permission.INTERNET android.permission.WRITE_EXTERNAL_STORAGE
+ )
+endif()
+
+#### Keys ignored in scope 1:.:.:corelib.pro:<TRUE>:
+# CMAKE_DISABLED_FEATURES = "$$join(QT_DISABLED_FEATURES, "$$escape_expand(\\n) ")"
+# CMAKE_HOST_DATA_DIR = "$$cmakeRelativePath($$[QT_HOST_DATA/src], $$[QT_INSTALL_PREFIX])"
+# CMAKE_INSTALL_DATA_DIR = "$$cmakeRelativePath($$[QT_HOST_DATA], $$[QT_INSTALL_PREFIX])"
+# HOST_BINS = "$$[QT_HOST_BINS]"
+# INSTALLS = "ctest_qt5_module_files" "cmake_qt5_umbrella_module_files"
+# MODULE = "core"
+# MODULE_CONFIG = "moc" "resources"
+# QMAKE_DSYM_DEBUG_SCRIPT = "$$PWD/debug_script.py"
+# QMAKE_DYNAMIC_LIST_FILE = "$$PWD/QtCore.dynlist"
+# QMAKE_PKGCONFIG_VARIABLES = "host_bins" "qt_conf"
+# QMAKE_SUBSTITUTES = "ctest_macros_file" "cmake_umbrella_config_file" "cmake_umbrella_config_module_location" "cmake_umbrella_config_module_location_for_install" "cmake_umbrella_config_version_file" "cmake_extras_mkspec_dir" "cmake_extras_mkspec_dir_for_install"
+# cmake_extras_mkspec_dir.input = "$$PWD/Qt5CoreConfigExtrasMkspecDir.cmake.in"
+# cmake_extras_mkspec_dir.output = "$$DESTDIR/cmake/Qt5Core/Qt5CoreConfigExtrasMkspecDir.cmake"
+# cmake_extras_mkspec_dir_for_install.input = "$$PWD/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in"
+# cmake_extras_mkspec_dir_for_install.output = "$$DESTDIR/cmake/install/Qt5Core/Qt5CoreConfigExtrasMkspecDir.cmake"
+# cmake_qt5_umbrella_module_files.files = "$$cmake_umbrella_config_file.output" "$$cmake_umbrella_config_version_file.output" "$$cmake_umbrella_config_module_location_for_install.output"
+# cmake_qt5_umbrella_module_files.path = "$$[QT_INSTALL_LIBS]/cmake/Qt5"
+# cmake_umbrella_config_file.input = "$$PWD/Qt5Config.cmake.in"
+# cmake_umbrella_config_file.output = "$$DESTDIR/cmake/Qt5/Qt5Config.cmake"
+# cmake_umbrella_config_module_location.input = "$$PWD/Qt5ModuleLocation.cmake.in"
+# cmake_umbrella_config_module_location.output = "$$DESTDIR/cmake/Qt5/Qt5ModuleLocation.cmake"
+# cmake_umbrella_config_module_location_for_install.input = "$$PWD/Qt5ModuleLocationForInstall.cmake.in"
+# cmake_umbrella_config_module_location_for_install.output = "$$DESTDIR/cmake/install/Qt5/Qt5ModuleLocation.cmake"
+# cmake_umbrella_config_version_file.input = "$$PWD/../../mkspecs/features/data/cmake/Qt5ConfigVersion.cmake.in"
+# cmake_umbrella_config_version_file.output = "$$DESTDIR/cmake/Qt5/Qt5ConfigVersion.cmake"
+# ctest_macros_file.CONFIG = "verbatim"
+# ctest_macros_file.input = "$$PWD/Qt5CTestMacros.cmake"
+# ctest_macros_file.output = "$$DESTDIR/cmake/Qt5Core/Qt5CTestMacros.cmake"
+# ctest_qt5_module_files.files = "$$ctest_macros_file.output" "$$cmake_extras_mkspec_dir_for_install.output"
+# ctest_qt5_module_files.path = "$$[QT_INSTALL_LIBS]/cmake/Qt5Core"
+# host_bins.name = "host_bins"
+# host_bins.variable = "HOST_BINS"
+# qt_conf.name = "qt_config"
+# qt_conf.variable = "QT_CONFIG"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:corelib.pro:QT_FEATURE_gc_binaries:
+# MODULE_CONFIG = "gc_binaries"
+
+#### Keys ignored in scope 3:.:.:corelib.pro:NOT QT_NAMESPACE_ISEMPTY:
+# MODULE_DEFINES = "QT_NAMESPACE=$$QT_NAMESPACE"
+
+qt_extend_target(Core CONDITION ANDROID
+ SOURCES
+ kernel/qsharedmemory_android.cpp
+ kernel/qsystemsemaphore_android.cpp
+ DEFINES
+ LIBS_SUFFIX="\\\\"_${CMAKE_SYSTEM_PROCESSOR}.so\\\\"" # special case
+)
+
+qt_extend_target(Core CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x67000000"
+)
+
+#### Keys ignored in scope 6:.:.:corelib.pro:FREEBSD OR OPENBSD:
+# QMAKE_LFLAGS_NOUNDEF = <EMPTY>
+
+qt_extend_target(Core CONDITION QT_FEATURE_animation
+ SOURCES
+ animation/qabstractanimation.cpp animation/qabstractanimation.h animation/qabstractanimation_p.h
+ animation/qanimationgroup.cpp animation/qanimationgroup.h animation/qanimationgroup_p.h
+ animation/qparallelanimationgroup.cpp animation/qparallelanimationgroup.h animation/qparallelanimationgroup_p.h
+ animation/qpauseanimation.cpp animation/qpauseanimation.h
+ animation/qpropertyanimation.cpp animation/qpropertyanimation.h animation/qpropertyanimation_p.h
+ animation/qsequentialanimationgroup.cpp animation/qsequentialanimationgroup.h animation/qsequentialanimationgroup_p.h
+ animation/qvariantanimation.cpp animation/qvariantanimation.h animation/qvariantanimation_p.h
+)
+
+qt_extend_target(Core CONDITION WIN32
+ SOURCES
+ global/qoperatingsystemversion_win.cpp global/qoperatingsystemversion_win_p.h
+ io/qfilesystemengine_win.cpp
+ io/qfsfileengine_win.cpp
+ io/qlockfile_win.cpp
+ kernel/qcoreapplication_win.cpp
+ kernel/qelapsedtimer_win.cpp
+ kernel/qsharedmemory_win.cpp
+ kernel/qsystemsemaphore_win.cpp
+ kernel/qwineventnotifier.cpp kernel/qwineventnotifier.h kernel/qwineventnotifier_p.h
+ plugin/qsystemlibrary.cpp plugin/qsystemlibrary_p.h
+ thread/qatomic_msvc.h
+ thread/qthread_win.cpp
+ # DEFINES # special case: remove
+ LIBRARIES
+ ws2_32
+)
+
+qt_extend_target(Core CONDITION WIN32 AND NOT WINRT
+ SOURCES
+ io/qstandardpaths_win.cpp
+ io/qstorageinfo_win.cpp
+ io/qwindowspipereader.cpp io/qwindowspipereader_p.h
+ io/qwindowspipewriter.cpp io/qwindowspipewriter_p.h
+ kernel/qeventdispatcher_win.cpp kernel/qeventdispatcher_win_p.h
+ kernel/qwinregistry.cpp kernel/qwinregistry_p.h
+ LIBRARIES
+ advapi32
+ kernel32
+ netapi32
+ ole32
+ shell32
+ user32
+ uuid
+ version
+ winmm
+ PUBLIC_LIBRARIES
+ mpr
+ userenv
+)
+
+qt_extend_target(Core CONDITION APPLE
+ SOURCES
+ global/qoperatingsystemversion_darwin.mm
+ io/qstandardpaths_mac.mm
+ io/qstorageinfo_mac.cpp
+ kernel/qcfsocketnotifier.cpp kernel/qcfsocketnotifier_p.h
+ kernel/qcore_foundation.mm
+ kernel/qcore_mac.cpp kernel/qcore_mac_p.h
+ kernel/qcore_mac_objc.mm
+ kernel/qcoreapplication_mac.cpp
+ kernel/qeventdispatcher_cf.mm kernel/qeventdispatcher_cf_p.h
+ LIBRARIES
+ ${FWCoreFoundation}
+ ${FWFoundation}
+)
+
+qt_extend_target(Core CONDITION APPLE_OSX
+ LIBRARIES
+ ${FWAppKit}
+ ${FWApplicationServices}
+ ${FWCoreServices}
+ ${FWSecurity}
+ PUBLIC_LIBRARIES
+ ${FWDiskArbitration}
+ ${FWIOKit}
+)
+
+qt_extend_target(Core CONDITION INTEGRITY
+ LIBRARIES
+ ivfs
+ net
+ posix
+ shm_client
+ socket
+ COMPILE_OPTIONS
+ --pending_instantiations=128
+)
+
+#### Keys ignored in scope 15:.:.:corelib.pro:pathIsAbsolute(_ss_CMAKE_HOST_DATA_DIR):
+# CMAKE_HOST_DATA_DIR = "$$[QT_HOST_DATA/src]/"
+# CMAKE_HOST_DATA_DIR_IS_ABSOLUTE = "True"
+
+#### Keys ignored in scope 16:.:.:corelib.pro:pathIsAbsolute(_ss_CMAKE_INSTALL_DATA_DIR):
+# CMAKE_INSTALL_DATA_DIR = "$$[QT_HOST_DATA]/"
+# CMAKE_INSTALL_DATA_DIR_IS_ABSOLUTE = "True"
+
+#### Keys ignored in scope 21:.:global:global/global.pri:QT_CPU_FEATURES__ss_QT_ARCH___contains___f16c:
+# f16c_cxx = "true"
+
+#### Keys ignored in scope 23:.:global:global/global.pri:CLANG OR intel_icl OR ICC:
+# f16c_cxx = "false"
+
+#### Keys ignored in scope 25:.:global:global/global.pri:GCC AND f16c AND x86SimdAlways:
+# f16c_cxx = "true"
+
+#### Keys ignored in scope 27:.:global:global/global.pri:MSVC AND QT_CPU_FEATURES__ss_QT_ARCH___contains___avx:
+# f16c_cxx = "true"
+
+#### Keys ignored in scope 28:.:global:global/global.pri:else:
+# f16c_cxx = "false"
+
+# extend_target(Core CONDITION _ss_f16c_cxx ... # special case remove: Handled manually
+
+# special case begin
+# Remove this because it's handled manually
+#extend_target(Core CONDITION NOT _x_-armcc_x_ AND NOT cross_compile AND NOT static AND (hurd_x_ OR linux_x_)
+# DEFINES
+# ELF_INTERPRETER=\\\"=Creadelf-l/bin/ls|perl-n-e\'['quote', ['if', ['/program', 'interpreter:', ['.*'], ']/'], '{', 'print', '$1;', '}']]\'\\\"
+# LINK_OPTIONS
+# "-Wl,-e,qt_core_boilerplate"
+#)
+# special case end
+
+qt_extend_target(Core CONDITION LINUX AND NOT static
+ SOURCES
+ global/minimum-linux_p.h
+)
+
+#### Keys ignored in scope 35:.:global:global/global.pri:precompile_header:
+# NO_PCH_ASM = "global/minimum-linux.S"
+# QMAKE_EXTRA_COMPILERS = "no_pch_assembler"
+# no_pch_assembler.commands = "$$QMAKE_CC" "-c" "$(CFLAGS)" "$(INCPATH)" "${QMAKE_FILE_IN}" "-o" "${QMAKE_FILE_OUT}"
+# no_pch_assembler.dependency_type = "TYPE_C"
+# no_pch_assembler.input = "NO_PCH_ASM"
+# no_pch_assembler.name = "compiling[no_pch]" "${QMAKE_FILE_IN}"
+# no_pch_assembler.output = "${QMAKE_VAR_OBJECTS_DIR}${QMAKE_FILE_BASE}$${firstQMAKE_EXT_OBJ}"
+
+#### Keys ignored in scope 36:.:global:global/global.pri:silent:
+# no_pch_assembler.commands = "@echo" "compiling[no_pch]" "${QMAKE_FILE_IN}" "&&"
+
+qt_extend_target(Core CONDITION LINUX AND NOT precompile_header AND NOT static
+ SOURCES
+ global/minimum-linux.S
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_slog2
+ LIBRARIES
+ Slog2::Slog2
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_journald
+ LIBRARIES
+ PkgConfig::Libsystemd
+)
+
+#### Keys ignored in scope 40:.:global:global/global.pri:GCC AND ltcg:
+# QMAKE_EXTRA_COMPILERS = "versiontagging_compiler"
+# versiontagging_compiler.commands = "$$QMAKE_CXX" "-c" "$(CXXFLAGS)" "$(INCPATH)" "-fno-lto" "-o" "${QMAKE_FILE_OUT}" "${QMAKE_FILE_IN}"
+# versiontagging_compiler.dependency_type = "TYPE_C"
+# versiontagging_compiler.input = "VERSIONTAGGING_SOURCES"
+# versiontagging_compiler.name = "compiling[versiontagging]" "${QMAKE_FILE_IN}"
+# versiontagging_compiler.output = "${QMAKE_VAR_OBJECTS_DIR}${QMAKE_FILE_BASE}$${firstQMAKE_EXT_OBJ}"
+# versiontagging_compiler.variable_out = "OBJECTS"
+
+#### Keys ignored in scope 41:.:global:global/global.pri:silent:
+# versiontagging_compiler.commands = "@echo" "compiling[versiontagging]" "${QMAKE_FILE_IN}" "&&"
+
+qt_extend_target(Core CONDITION NOT GCC OR NOT ltcg
+ SOURCES
+ global/qversiontagging.cpp
+)
+
+qt_extend_target(Core CONDITION UNIX
+ SOURCES
+ io/qfilesystemengine_unix.cpp
+ io/qfilesystemiterator_unix.cpp
+ io/qfsfileengine_unix.cpp
+ io/qlockfile_unix.cpp
+ kernel/qcore_unix.cpp kernel/qcore_unix_p.h
+ kernel/qeventdispatcher_unix.cpp kernel/qeventdispatcher_unix_p.h
+ kernel/qpoll_p.h
+ kernel/qtimerinfo_unix.cpp kernel/qtimerinfo_unix_p.h
+ thread/qthread_unix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_thread
+ SOURCES
+ thread/qatomic.cpp thread/qatomic.h
+ thread/qatomic_bootstrap.h
+ thread/qatomic_cxx11.h
+ thread/qbasicatomic.h
+ thread/qfutex_p.h
+ thread/qgenericatomic.h
+ thread/qlocking_p.h
+ thread/qmutex.cpp thread/qmutex_p.h
+ thread/qorderedmutexlocker_p.h
+ thread/qreadwritelock.cpp thread/qreadwritelock_p.h
+ thread/qsemaphore.cpp thread/qsemaphore.h
+ thread/qthread_p.h
+ thread/qthreadpool.cpp thread/qthreadpool.h thread/qthreadpool_p.h
+ thread/qthreadstorage.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_thread AND WIN32
+ SOURCES
+ thread/qmutex_win.cpp
+ thread/qwaitcondition_win.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_thread AND UNIX
+ SOURCES
+ thread/qwaitcondition_unix.cpp
+)
+
+qt_extend_target(Core CONDITION APPLE AND QT_FEATURE_thread
+ SOURCES
+ thread/qmutex_mac.cpp
+)
+
+qt_extend_target(Core CONDITION LINUX AND QT_FEATURE_thread
+ SOURCES
+ thread/qmutex_linux.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_thread AND UNIX AND NOT APPLE AND NOT LINUX
+ SOURCES
+ thread/qmutex_unix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_future
+ SOURCES
+ thread/qexception.cpp thread/qexception.h
+ thread/qfuture.h
+ thread/qfutureinterface.cpp thread/qfutureinterface.h thread/qfutureinterface_p.h
+ thread/qfuturesynchronizer.h
+ thread/qfuturewatcher.cpp thread/qfuturewatcher.h thread/qfuturewatcher_p.h
+ thread/qresultstore.cpp thread/qresultstore.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_std_atomic64
+ PUBLIC_LIBRARIES
+ Atomic
+)
+
+qt_extend_target(Core CONDITION ICC
+ COMPILE_OPTIONS
+ -fp-model
+ strict
+)
+
+qt_extend_target(Core CONDITION MSVC
+ SOURCES
+ tools/qvector_msvc.cpp
+ NO_PCH_SOURCES
+ "tools/qvector_msvc.cpp"
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_commandlineparser
+ SOURCES
+ tools/qcommandlineoption.cpp tools/qcommandlineoption.h
+ tools/qcommandlineparser.cpp tools/qcommandlineparser.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_easingcurve
+ SOURCES
+ tools/qeasingcurve.cpp tools/qeasingcurve.h
+ tools/qtimeline.cpp tools/qtimeline.h
+)
+
+qt_extend_target(Core CONDITION UNIX AND NOT HAIKU AND NOT INTEGRITY AND NOT VXWORKS AND NOT WASM AND (NOT APPLE_OSX OR NOT ICC)
+ LIBRARIES
+ m
+)
+
+qt_extend_target(Core CONDITION APPLE_OSX AND NOT NACL
+ SOURCES
+ text/qlocale_mac.mm
+)
+
+qt_extend_target(Core CONDITION UNIX AND (NACL OR NOT APPLE_OSX)
+ SOURCES
+ text/qlocale_unix.cpp
+)
+
+qt_extend_target(Core CONDITION WIN32 AND (NACL OR NOT APPLE_OSX)
+ SOURCES
+ text/qlocale_win.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_icu
+ SOURCES
+ text/qcollator_icu.cpp
+ text/qlocale_icu.cpp
+ LIBRARIES
+ ICU::i18n ICU::uc ICU::data
+)
+
+qt_extend_target(Core CONDITION WIN32 AND NOT QT_FEATURE_icu
+ SOURCES
+ text/qcollator_win.cpp
+)
+
+qt_extend_target(Core CONDITION APPLE_OSX AND NOT QT_FEATURE_icu
+ SOURCES
+ text/qcollator_macx.cpp
+)
+
+qt_extend_target(Core CONDITION UNIX AND NOT APPLE_OSX AND NOT QT_FEATURE_icu
+ SOURCES
+ text/qcollator_posix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_regularexpression
+ SOURCES
+ text/qregularexpression.cpp text/qregularexpression.h
+ LIBRARIES
+ WrapPCRE2::WrapPCRE2
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_hijricalendar
+ SOURCES
+ time/qhijricalendar.cpp time/qhijricalendar_p.h
+ time/qhijricalendar_data_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_islamiccivilcalendar
+ SOURCES
+ time/qislamiccivilcalendar.cpp time/qislamiccivilcalendar_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_jalalicalendar
+ SOURCES
+ time/qjalalicalendar.cpp time/qjalalicalendar_p.h
+ time/qjalalicalendar_data_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_timezone
+ SOURCES
+ time/qtimezone.cpp time/qtimezone.h
+ time/qtimezoneprivate.cpp time/qtimezoneprivate_p.h
+ time/qtimezoneprivate_data_p.h
+)
+
+qt_extend_target(Core CONDITION APPLE AND QT_FEATURE_timezone AND NOT NACL
+ SOURCES
+ time/qtimezoneprivate_mac.mm
+)
+
+qt_extend_target(Core CONDITION ANDROID AND QT_FEATURE_timezone AND NOT ANDROID_EMBEDDED AND (NACL OR NOT APPLE)
+ SOURCES
+ time/qtimezoneprivate_android.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_timezone AND UNIX AND (ANDROID_EMBEDDED OR NOT ANDROID) AND (NACL OR NOT APPLE)
+ SOURCES
+ time/qtimezoneprivate_tz.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_icu AND QT_FEATURE_timezone AND UNIX AND (ANDROID_EMBEDDED OR NOT ANDROID) AND (NACL OR NOT APPLE)
+ SOURCES
+ time/qtimezoneprivate_icu.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_icu AND QT_FEATURE_timezone AND WIN32 AND (ANDROID_EMBEDDED OR NOT ANDROID) AND (NACL OR NOT APPLE)
+ SOURCES
+ time/qtimezoneprivate_icu.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_timezone AND WIN32 AND NOT QT_FEATURE_icu AND (ANDROID_EMBEDDED OR NOT ANDROID) AND (NACL OR NOT APPLE)
+ SOURCES
+ time/qtimezoneprivate_win.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_datetimeparser
+ SOURCES
+ time/qdatetimeparser.cpp time/qdatetimeparser_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_zstd
+ LIBRARIES
+ ZSTD::ZSTD
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_filesystemwatcher
+ SOURCES
+ io/qfilesystemwatcher.cpp io/qfilesystemwatcher.h io/qfilesystemwatcher_p.h
+ io/qfilesystemwatcher_polling.cpp io/qfilesystemwatcher_polling_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_filesystemwatcher AND WIN32
+ SOURCES
+ io/qfilesystemwatcher_win.cpp io/qfilesystemwatcher_win_p.h
+)
+
+qt_extend_target(Core CONDITION APPLE_OSX AND QT_FEATURE_filesystemwatcher
+ SOURCES
+ io/qfilesystemwatcher_fsevents.mm io/qfilesystemwatcher_fsevents_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_filesystemwatcher AND QT_FEATURE_inotify AND UNIX AND NOT APPLE_OSX
+ SOURCES
+ io/qfilesystemwatcher_inotify.cpp io/qfilesystemwatcher_inotify_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_filesystemwatcher AND UNIX AND NOT APPLE_OSX AND NOT QT_FEATURE_inotify AND (APPLE OR FREEBSD OR NETBSD OR OPENBSD)
+ SOURCES
+ io/qfilesystemwatcher_kqueue.cpp io/qfilesystemwatcher_kqueue_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_processenvironment
+ SOURCES
+ io/qprocess.cpp io/qprocess.h io/qprocess_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_processenvironment AND WIN32 AND NOT WINRT
+ SOURCES
+ io/qprocess_win.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_processenvironment AND UNIX
+ SOURCES
+ io/qprocess_unix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_settings
+ SOURCES
+ io/qsettings.cpp io/qsettings.h io/qsettings_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_settings AND WIN32 AND NOT WINRT
+ SOURCES
+ io/qsettings_win.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_settings AND WINRT
+ SOURCES
+ io/qsettings_winrt.cpp
+)
+
+qt_extend_target(Core CONDITION APPLE AND QT_FEATURE_settings AND NOT NACL
+ SOURCES
+ io/qsettings_mac.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_filesystemiterator AND WIN32
+ SOURCES
+ io/qfilesystemiterator_win.cpp
+)
+
+qt_extend_target(Core CONDITION WINRT
+ SOURCES
+ io/qstandardpaths_winrt.cpp
+ io/qstorageinfo_stub.cpp
+ kernel/qeventdispatcher_winrt.cpp kernel/qeventdispatcher_winrt_p.h
+ kernel/qfunctions_fake_env_p.h
+ kernel/qfunctions_winrt.cpp kernel/qfunctions_winrt.h
+)
+
+qt_extend_target(Core CONDITION UNIX AND NOT APPLE_UIKIT AND NOT INTEGRITY AND NOT rtems
+ SOURCES
+ ../3rdparty/forkfd/forkfd.h
+ io/forkfd_qt.cpp
+ INCLUDE_DIRECTORIES
+ ../3rdparty/forkfd
+)
+
+qt_extend_target(Core CONDITION APPLE AND QT_FEATURE_processenvironment
+ SOURCES
+ io/qprocess_darwin.mm
+)
+
+qt_extend_target(Core CONDITION APPLE AND NOT APPLE_OSX
+ PUBLIC_LIBRARIES
+ ${FWMobileCoreServices}
+)
+
+qt_extend_target(Core CONDITION ANDROID AND NOT ANDROID_EMBEDDED
+ SOURCES
+ io/qstandardpaths_android.cpp
+ io/qstorageinfo_unix.cpp
+ kernel/qjni.cpp kernel/qjni_p.h
+ kernel/qjnihelpers.cpp kernel/qjnihelpers_p.h
+ kernel/qjnionload.cpp
+)
+
+qt_extend_target(Core CONDITION HAIKU AND (ANDROID_EMBEDDED OR NOT ANDROID)
+ SOURCES
+ io/qstandardpaths_haiku.cpp
+ io/qstorageinfo_unix.cpp
+ PUBLIC_LIBRARIES
+ be
+)
+
+qt_extend_target(Core CONDITION UNIX AND NOT APPLE AND NOT HAIKU AND (ANDROID_EMBEDDED OR NOT ANDROID)
+ SOURCES
+ io/qstandardpaths_unix.cpp
+ io/qstorageinfo_unix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_proxymodel
+ SOURCES
+ itemmodels/qabstractproxymodel.cpp itemmodels/qabstractproxymodel.h itemmodels/qabstractproxymodel_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_concatenatetablesproxymodel AND QT_FEATURE_proxymodel
+ SOURCES
+ itemmodels/qconcatenatetablesproxymodel.cpp itemmodels/qconcatenatetablesproxymodel.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_identityproxymodel AND QT_FEATURE_proxymodel
+ SOURCES
+ itemmodels/qidentityproxymodel.cpp itemmodels/qidentityproxymodel.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_proxymodel AND QT_FEATURE_sortfilterproxymodel
+ SOURCES
+ itemmodels/qsortfilterproxymodel.cpp itemmodels/qsortfilterproxymodel.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_proxymodel AND QT_FEATURE_transposeproxymodel
+ SOURCES
+ itemmodels/qtransposeproxymodel.cpp itemmodels/qtransposeproxymodel.h itemmodels/qtransposeproxymodel_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_stringlistmodel
+ SOURCES
+ itemmodels/qstringlistmodel.cpp itemmodels/qstringlistmodel.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_library
+ SOURCES
+ plugin/qelfparser_p.cpp plugin/qelfparser_p.h
+ plugin/qlibrary.cpp plugin/qlibrary.h plugin/qlibrary_p.h
+ plugin/qmachparser.cpp plugin/qmachparser_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_library AND UNIX
+ SOURCES
+ plugin/qlibrary_unix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_library AND WIN32
+ SOURCES
+ plugin/qlibrary_win.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_dlopen AND QT_FEATURE_library
+ LIBRARIES
+ ${CMAKE_DL_LIBS}
+)
+
+qt_extend_target(Core CONDITION APPLE AND NOT NACL
+ SOURCES
+ kernel/qelapsedtimer_mac.cpp
+)
+
+qt_extend_target(Core CONDITION APPLE AND (APPLE_IOS OR APPLE_TVOS)
+ LIBRARIES
+ ${FWUIKit}
+)
+
+qt_extend_target(Core CONDITION APPLE_WATCHOS
+ LIBRARIES
+ ${FWWatchKit}
+)
+
+qt_extend_target(Core CONDITION NACL
+ SOURCES
+ kernel/qfunctions_nacl.cpp kernel/qfunctions_nacl.h
+)
+
+qt_extend_target(Core CONDITION INTEGRITY OR (NACL AND UNIX) OR (UNIX AND NOT APPLE)
+ SOURCES
+ kernel/qelapsedtimer_unix.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_poll_select AND UNIX
+ SOURCES
+ kernel/qpoll.cpp
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_glib AND UNIX
+ SOURCES
+ kernel/qeventdispatcher_glib.cpp kernel/qeventdispatcher_glib_p.h
+ LIBRARIES
+ GLIB2::GLIB2
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_clock_gettime AND UNIX
+ LIBRARIES
+ WrapRt
+)
+
+qt_extend_target(Core CONDITION UNIX AND NOT ANDROID
+ SOURCES
+ kernel/qsharedmemory_posix.cpp
+ kernel/qsharedmemory_systemv.cpp
+ kernel/qsharedmemory_unix.cpp
+ kernel/qsystemsemaphore_posix.cpp
+ kernel/qsystemsemaphore_systemv.cpp
+ kernel/qsystemsemaphore_unix.cpp
+)
+
+qt_extend_target(Core CONDITION VXWORKS
+ SOURCES
+ kernel/qfunctions_vxworks.cpp kernel/qfunctions_vxworks.h
+)
+
+qt_extend_target(Core CONDITION QNX AND QT_FEATURE_qqnx_pps
+ SOURCES
+ kernel/qppsattribute.cpp kernel/qppsattribute_p.h
+ kernel/qppsattributeprivate_p.h
+ kernel/qppsobject.cpp kernel/qppsobject_p.h
+ kernel/qppsobjectprivate_p.h
+ LIBRARIES
+ PPS::PPS
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_textcodec
+ SOURCES
+ codecs/qlatincodec.cpp codecs/qlatincodec_p.h
+ codecs/qsimplecodec.cpp codecs/qsimplecodec_p.h
+ codecs/qtextcodec.cpp codecs/qtextcodec.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_codecs AND QT_FEATURE_textcodec
+ SOURCES
+ codecs/qisciicodec.cpp codecs/qisciicodec_p.h
+ codecs/qtsciicodec.cpp codecs/qtsciicodec_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_icu AND QT_FEATURE_textcodec
+ SOURCES
+ codecs/qicucodec.cpp codecs/qicucodec_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_big_codecs AND QT_FEATURE_textcodec AND NOT QT_FEATURE_icu
+ SOURCES
+ codecs/qbig5codec.cpp codecs/qbig5codec_p.h
+ codecs/qeucjpcodec.cpp codecs/qeucjpcodec_p.h
+ codecs/qeuckrcodec.cpp codecs/qeuckrcodec_p.h
+ codecs/qgb18030codec.cpp codecs/qgb18030codec_p.h
+ codecs/qjiscodec.cpp codecs/qjiscodec_p.h
+ codecs/qjpunicode.cpp
+ codecs/qsjiscodec.cpp codecs/qsjiscodec_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_iconv AND QT_FEATURE_textcodec AND NOT QT_FEATURE_icu
+ SOURCES
+ codecs/qiconvcodec.cpp codecs/qiconvcodec_p.h
+ LIBRARIES
+ iconv
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_textcodec AND WIN32 AND NOT QT_FEATURE_icu
+ SOURCES
+ codecs/qwindowscodec.cpp codecs/qwindowscodec_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_cborstream
+ SOURCES
+ serialization/qcborstream.cpp serialization/qcborstream.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_binaryjson
+ SOURCES
+ serialization/qbinaryjson.cpp serialization/qbinaryjson_p.h
+ serialization/qbinaryjsonarray.cpp serialization/qbinaryjsonarray_p.h
+ serialization/qbinaryjsonobject.cpp serialization/qbinaryjsonobject_p.h
+ serialization/qbinaryjsonvalue.cpp serialization/qbinaryjsonvalue_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_qeventtransition
+ SOURCES
+ statemachine/qeventtransition.cpp statemachine/qeventtransition.h statemachine/qeventtransition_p.h
+)
+
+qt_extend_target(Core CONDITION QT_FEATURE_mimetype
+ SOURCES
+ mimetypes/qmimedatabase.cpp mimetypes/qmimedatabase.h mimetypes/qmimedatabase_p.h
+ mimetypes/qmimeglobpattern.cpp mimetypes/qmimeglobpattern_p.h
+ mimetypes/qmimemagicrule.cpp mimetypes/qmimemagicrule_p.h
+ mimetypes/qmimemagicrulematcher.cpp mimetypes/qmimemagicrulematcher_p.h
+ mimetypes/qmimeprovider.cpp mimetypes/qmimeprovider_p.h
+ mimetypes/qmimetype.cpp mimetypes/qmimetype.h mimetypes/qmimetype_p.h
+ mimetypes/qmimetypeparser.cpp mimetypes/qmimetypeparser_p.h
+)
+
+# Resources:
+# special case begin
+# We can't specify the resources directly as we have unit tests that
+# depend on these as well and we no longer support the use of hand
+# edited qrc files.
+if(QT_FEATURE_mimetype AND QT_FEATURE_mimetype_database)
+ include(${CMAKE_CURRENT_SOURCE_DIR}/mimetypes/mimetypes_resources.cmake)
+ corelib_add_mimetypes_resources(Core)
+endif()
+# special case end
+
+qt_extend_target(Core CONDITION WASM
+ SOURCES
+ platform/wasm/qstdweb.cpp platform/wasm/qstdweb_p.h
+)
+
+# special case begin
+# needs refinement for the other compiler specific cases.
+if(TEST_arch_${TEST_architecture_arch}_subarch_f16c)
+ # Equivalent to contains(QT_CPU_FEATURES.$$QT_ARCH, f16c)
+ extend_target(Core
+ DEFINES
+ QFLOAT16_INCLUDE_FAST
+ )
+else()
+ qt_add_simd_part(Core SIMD f16c
+ SOURCES
+ global/qfloat16_f16c.c
+ )
+endif()
+
+set_source_files_properties(
+ thread/qmutex_linux.cpp
+ thread/qmutex_mac.cpp
+ thread/qmutex_unix.cpp
+ thread/qmutex_win.cpp
+ PROPERTIES HEADER_FILE_ONLY ON) # special case: These files are included by qmutex.cpp!
+
+
+# Remove QT_NO_CAST_TO_ASCII to ensure that the symbols are included in the library.
+if(WIN32)
+ get_target_property(defines Core COMPILE_DEFINITIONS)
+ list(REMOVE_ITEM defines QT_NO_CAST_TO_ASCII)
+ set_target_properties(Core PROPERTIES COMPILE_DEFINITIONS "${defines}")
+endif()
+
+qt_internal_add_link_flags_gc_sections(Core PRIVATE)
+
+if(WIN32)
+ set(isExe $<STREQUAL:$<TARGET_PROPERTY:TYPE>,EXECUTABLE>)
+ set(isWin32 $<BOOL:$<TARGET_PROPERTY:WIN32_EXECUTABLE>>)
+ set(isNotExcluded $<NOT:$<BOOL:$<TARGET_PROPERTY:Qt5_NO_LINK_QTMAIN>>>)
+ set(isPolicyNEW $<TARGET_POLICY:CMP0020>)
+
+ target_link_libraries(Core INTERFACE $<$<AND:${isExe},${isWin32},${isNotExcluded},${isPolicyNEW}>:Qt::WinMain>)
+ qt_record_extra_qt_package_dependency(Core WinMain "${PROJECT_VERSION}")
+endif()
+# special case end
+
+qt_create_tracepoints(Core qtcore.tracepoints)
+qt_add_docs(Core
+ doc/qtcore.qdocconf
+)
+
diff --git a/src/corelib/Qt5CoreConfigExtras.cmake.in b/src/corelib/Qt5CoreConfigExtras.cmake.in
deleted file mode 100644
index 9b672327ef..0000000000
--- a/src/corelib/Qt5CoreConfigExtras.cmake.in
+++ /dev/null
@@ -1,179 +0,0 @@
-
-if (NOT TARGET Qt5::qmake)
- add_executable(Qt5::qmake IMPORTED)
-
-!!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_BIN_DIR}qmake$$CMAKE_BIN_SUFFIX\")
-!!ELSE
- set(imported_location \"$${CMAKE_BIN_DIR}qmake$$CMAKE_BIN_SUFFIX\")
-!!ENDIF
- _qt5_Core_check_file_exists(${imported_location})
-
- set_target_properties(Qt5::qmake PROPERTIES
- IMPORTED_LOCATION ${imported_location}
- )
-endif()
-
-if (NOT TARGET Qt5::moc)
- add_executable(Qt5::moc IMPORTED)
-
-!!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_BIN_DIR}moc$$CMAKE_BIN_SUFFIX\")
-!!ELSE
- set(imported_location \"$${CMAKE_BIN_DIR}moc$$CMAKE_BIN_SUFFIX\")
-!!ENDIF
- _qt5_Core_check_file_exists(${imported_location})
-
- set_target_properties(Qt5::moc PROPERTIES
- IMPORTED_LOCATION ${imported_location}
- )
- # For CMake automoc feature
- get_target_property(QT_MOC_EXECUTABLE Qt5::moc LOCATION)
-endif()
-
-if (NOT TARGET Qt5::rcc)
- add_executable(Qt5::rcc IMPORTED)
-
-!!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_BIN_DIR}rcc$$CMAKE_BIN_SUFFIX\")
-!!ELSE
- set(imported_location \"$${CMAKE_BIN_DIR}rcc$$CMAKE_BIN_SUFFIX\")
-!!ENDIF
- _qt5_Core_check_file_exists(${imported_location})
-
- set_target_properties(Qt5::rcc PROPERTIES
- IMPORTED_LOCATION ${imported_location}
- )
-endif()
-
-set(CMAKE_AUTOMOC_MACRO_NAMES "Q_OBJECT" "Q_GADGET" "Q_NAMESPACE" "Q_NAMESPACE_EXPORT")
-
-set(Qt5Core_QMAKE_EXECUTABLE Qt5::qmake)
-set(Qt5Core_MOC_EXECUTABLE Qt5::moc)
-set(Qt5Core_RCC_EXECUTABLE Qt5::rcc)
-
-set_property(TARGET Qt5::Core PROPERTY INTERFACE_QT_MAJOR_VERSION 5)
-set_property(TARGET Qt5::Core PROPERTY INTERFACE_QT_COORD_TYPE $$QT_COORD_TYPE)
-set_property(TARGET Qt5::Core APPEND PROPERTY
- COMPATIBLE_INTERFACE_STRING QT_MAJOR_VERSION QT_COORD_TYPE
-)
-
-include(\"${CMAKE_CURRENT_LIST_DIR}/Qt5CoreConfigExtrasMkspecDir.cmake\")
-
-foreach(_dir ${_qt5_corelib_extra_includes})
- _qt5_Core_check_file_exists(${_dir})
-endforeach()
-
-list(APPEND Qt5Core_INCLUDE_DIRS ${_qt5_corelib_extra_includes})
-set_property(TARGET Qt5::Core APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${_qt5_corelib_extra_includes})
-set(_qt5_corelib_extra_includes)
-
-# Targets using Qt need to use the POSITION_INDEPENDENT_CODE property. The
-# Qt5_POSITION_INDEPENDENT_CODE variable is used in the # qt5_use_module
-# macro to add it.
-set(Qt5_POSITION_INDEPENDENT_CODE True)
-
-# On x86 and x86-64 systems with ELF binaries (especially Linux), due to
-# a new optimization in GCC 5.x in combination with a recent version of
-# GNU binutils, compiling Qt applications with -fPIE is no longer
-# enough.
-# Applications now need to be compiled with the -fPIC option if the Qt option
-# \"reduce relocations\" is active. For backward compatibility only, Qt accepts
-# the use of -fPIE for GCC 4.x versions.
-set_property(TARGET Qt5::Core APPEND PROPERTY INTERFACE_COMPILE_OPTIONS $$QMAKE_CXXFLAGS_APP)
-
-# TODO Qt6: Remove
-set(Qt5Core_EXECUTABLE_COMPILE_FLAGS \"\")
-
-!!IF !isEmpty(QT_NAMESPACE)
-list(APPEND Qt5Core_DEFINITIONS -DQT_NAMESPACE=$$QT_NAMESPACE)
-list(APPEND Qt5Core_COMPILE_DEFINITIONS QT_NAMESPACE=$$QT_NAMESPACE)
-set_property(TARGET Qt5::Core APPEND PROPERTY INTERFACE_COMPILE_DEFINITIONS QT_NAMESPACE=$$QT_NAMESPACE)
-!!ENDIF
-
-!!IF !isEmpty(CMAKE_DISABLED_FEATURES)
-set(Qt5_DISABLED_FEATURES
- $$CMAKE_DISABLED_FEATURES
-)
-!!ENDIF
-
-set_property(TARGET Qt5::Core APPEND PROPERTY INTERFACE_COMPILE_DEFINITIONS $<$<NOT:$<CONFIG:Debug>>:QT_NO_DEBUG>)
-
-set_property(TARGET Qt5::Core PROPERTY INTERFACE_COMPILE_FEATURES cxx_decltype)
-
-!!IF qtConfig(reduce_exports)
-set(QT_VISIBILITY_AVAILABLE \"True\")
-!!ENDIF
-
-!!IF !isEmpty(QT_LIBINFIX)
-set(QT_LIBINFIX \"$${QT_LIBINFIX}\")
-!!ENDIF
-
-!!IF !isEmpty(CMAKE_WINDOWS_BUILD)
-set(Qt5Core_QTMAIN_LIBRARIES Qt5::WinMain)
-
-if (NOT TARGET Qt5::WinMain)
- add_library(Qt5::WinMain STATIC IMPORTED)
-
-!!IF !isEmpty(CMAKE_RELEASE_TYPE)
- set_property(TARGET Qt5::WinMain APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)
-!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_WINMAIN_FILE_LOCATION_RELEASE}\")
-!!ELSE
- set(imported_location \"$${CMAKE_LIB_DIR}$${CMAKE_WINMAIN_FILE_LOCATION_RELEASE}\")
-!!ENDIF
-
- set_target_properties(Qt5::WinMain PROPERTIES
- IMPORTED_LOCATION_RELEASE ${imported_location}
- )
-!!ENDIF
-
-!!IF !isEmpty(CMAKE_DEBUG_TYPE)
- set_property(TARGET Qt5::WinMain APPEND PROPERTY IMPORTED_CONFIGURATIONS DEBUG)
-
-!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_WINMAIN_FILE_LOCATION_DEBUG}\")
-!!ELSE
- set(imported_location \"$${CMAKE_LIB_DIR}$${CMAKE_WINMAIN_FILE_LOCATION_DEBUG}\")
-!!ENDIF
-
- set_target_properties(Qt5::WinMain PROPERTIES
- IMPORTED_LOCATION_DEBUG ${imported_location}
- )
-!!ENDIF
-
- if (NOT Qt5_NO_LINK_QTMAIN)
- set(_isExe $<STREQUAL:$<TARGET_PROPERTY:TYPE>,EXECUTABLE>)
- set(_isWin32 $<BOOL:$<TARGET_PROPERTY:WIN32_EXECUTABLE>>)
- set(_isNotExcluded $<NOT:$<BOOL:$<TARGET_PROPERTY:Qt5_NO_LINK_QTMAIN>>>)
- set(_isPolicyNEW $<TARGET_POLICY:CMP0020>)
- get_target_property(_configs Qt5::Core IMPORTED_CONFIGURATIONS)
- set_property(TARGET Qt5::Core APPEND PROPERTY
- INTERFACE_LINK_LIBRARIES
- $<$<AND:${_isExe},${_isWin32},${_isNotExcluded},${_isPolicyNEW}>:Qt5::WinMain>
- )
- # For backward compatibility with CMake < 2.8.12
- foreach(_config ${_configs})
- set_property(TARGET Qt5::Core APPEND PROPERTY
- IMPORTED_LINK_INTERFACE_LIBRARIES_${_config}
- $<$<AND:${_isExe},${_isWin32},${_isNotExcluded},${_isPolicyNEW}>:Qt5::WinMain>
- )
- endforeach()
- unset(_configs)
- unset(_isExe)
- unset(_isWin32)
- unset(_isNotExcluded)
- unset(_isPolicyNEW)
- endif()
-endif()
-!!ENDIF
-
-get_filename_component(_Qt5CoreConfigDir ${CMAKE_CURRENT_LIST_FILE} PATH)
-
-set(_Qt5CTestMacros \"${_Qt5CoreConfigDir}/Qt5CTestMacros.cmake\")
-
-if (ANDROID_PLATFORM)
- include(\"${CMAKE_CURRENT_LIST_DIR}/Qt5AndroidSupport.cmake\")
-endif()
-
-_qt5_Core_check_file_exists(${_Qt5CTestMacros})
diff --git a/src/corelib/Qt5CTestMacros.cmake b/src/corelib/Qt6CTestMacros.cmake
index 962d49d6b2..962d49d6b2 100644
--- a/src/corelib/Qt5CTestMacros.cmake
+++ b/src/corelib/Qt6CTestMacros.cmake
diff --git a/src/corelib/Qt5Config.cmake.in b/src/corelib/Qt6Config.cmake.in
index 6b6544f932..6b6544f932 100644
--- a/src/corelib/Qt5Config.cmake.in
+++ b/src/corelib/Qt6Config.cmake.in
diff --git a/src/corelib/Qt6CoreConfigExtras.cmake.in b/src/corelib/Qt6CoreConfigExtras.cmake.in
new file mode 100644
index 0000000000..21bf788c89
--- /dev/null
+++ b/src/corelib/Qt6CoreConfigExtras.cmake.in
@@ -0,0 +1,53 @@
+
+# include(\"${CMAKE_CURRENT_LIST_DIR}/Qt5CoreConfigExtrasMkspecDir.cmake\")
+#
+# foreach(_dir ${_qt5_corelib_extra_includes})
+# _qt5_Core_check_file_exists(${_dir})
+# endforeach()
+
+# list(APPEND Qt5Core_INCLUDE_DIRS ${_qt5_corelib_extra_includes})
+# set_property(TARGET @QT_CMAKE_EXPORT_NAMESPACE@::Core APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${_qt5_corelib_extra_includes})
+# set(_qt5_corelib_extra_includes)
+
+if (NOT QT_NO_CREATE_TARGETS)
+ set_property(TARGET @QT_CMAKE_EXPORT_NAMESPACE@::Core PROPERTY INTERFACE_QT_MAJOR_VERSION @PROJECT_VERSION_MAJOR@)
+ set_property(TARGET @QT_CMAKE_EXPORT_NAMESPACE@::Core PROPERTY INTERFACE_QT_COORD_TYPE @QT_COORD_TYPE@)
+ set_property(TARGET @QT_CMAKE_EXPORT_NAMESPACE@::Core APPEND PROPERTY
+ COMPATIBLE_INTERFACE_STRING QT_MAJOR_VERSION QT_COORD_TYPE
+ )
+
+ # On x86 and x86-64 systems with ELF binaries (especially Linux), due to
+ # a new optimization in GCC 5.x in combination with a recent version of
+ # GNU binutils, compiling Qt applications with -fPIE is no longer
+ # enough.
+ # Applications now need to be compiled with the -fPIC option if the Qt option
+ # \"reduce relocations\" is active. For backward compatibility only, Qt accepts
+ # the use of -fPIE for GCC 4.x versions.
+ if (CMAKE_CXX_COMPILER MATCHES "icc.*$" OR CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
+ set_property(TARGET @QT_CMAKE_EXPORT_NAMESPACE@::Core APPEND PROPERTY INTERFACE_COMPILE_OPTIONS "-fPIC")
+ endif()
+
+ if (NOT "@QT_NAMESPACE@" STREQUAL "")
+ set_property(TARGET @QT_CMAKE_EXPORT_NAMESPACE@::Core APPEND PROPERTY INTERFACE_COMPILE_DEFINITIONS QT_NAMESPACE=@QT_NAMESPACE@)
+ endif()
+ set_property(TARGET @QT_CMAKE_EXPORT_NAMESPACE@::Core APPEND PROPERTY INTERFACE_COMPILE_DEFINITIONS $<$<NOT:$<CONFIG:Debug>>:QT_NO_DEBUG>)
+ set_property(TARGET @QT_CMAKE_EXPORT_NAMESPACE@::Core PROPERTY INTERFACE_COMPILE_FEATURES cxx_decltype)
+endif()
+
+set(CMAKE_AUTOMOC_MACRO_NAMES "Q_OBJECT" "Q_GADGET" "Q_NAMESPACE" "Q_NAMESPACE_EXPORT")
+
+# install layout information, following what qmake -query provides
+get_filename_component(QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX ${CMAKE_CURRENT_LIST_DIR}/../@QT_INVERSE_CONFIG_INSTALL_DIR@ ABSOLUTE)
+set(QT@PROJECT_VERSION_MAJOR@_INSTALL_ARCHDATA ${QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX}/@INSTALL_ARCHDATADIR@)
+set(QT@PROJECT_VERSION_MAJOR@_INSTALL_BINS ${QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX}/@INSTALL_BINDIR@)
+set(QT@PROJECT_VERSION_MAJOR@_INSTALL_CONFIGURATION ${QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX}/@INSTALL_SYSCONFDIR@)
+set(QT@PROJECT_VERSION_MAJOR@_INSTALL_DATA ${QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX}/@INSTALL_DATADIR@)
+set(QT@PROJECT_VERSION_MAJOR@_INSTALL_DOCS ${QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX}/@INSTALL_DOCDIR@)
+set(QT@PROJECT_VERSION_MAJOR@_INSTALL_EXAMPLES ${QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX}/@INSTALL_EXAMPLESDIR@)
+set(QT@PROJECT_VERSION_MAJOR@_INSTALL_HEADERS ${QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX}/@INSTALL_INCLUDEDIR@)
+set(QT@PROJECT_VERSION_MAJOR@_INSTALL_LIBS ${QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX}/@INSTALL_LIBDIR@)
+set(QT@PROJECT_VERSION_MAJOR@_INSTALL_LIBEXECS ${QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX}/@INSTALL_LIBEXECDIR@)
+set(QT@PROJECT_VERSION_MAJOR@_INSTALL_PLUGINS ${QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX}/@INSTALL_PLUGINSDIR@)
+set(QT@PROJECT_VERSION_MAJOR@_INSTALL_QML ${QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX}/@INSTALL_QMLDIR@)
+set(QT@PROJECT_VERSION_MAJOR@_INSTALL_TESTS ${QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX}/@INSTALL_TESTSDIR@)
+set(QT@PROJECT_VERSION_MAJOR@_INSTALL_TRANSLATIONS ${QT@PROJECT_VERSION_MAJOR@_INSTALL_PREFIX}/@INSTALL_TRANSLATIONSDIR@)
diff --git a/src/corelib/Qt5CoreConfigExtrasMkspecDir.cmake.in b/src/corelib/Qt6CoreConfigExtrasMkspecDir.cmake.in
index c357237d0e..c357237d0e 100644
--- a/src/corelib/Qt5CoreConfigExtrasMkspecDir.cmake.in
+++ b/src/corelib/Qt6CoreConfigExtrasMkspecDir.cmake.in
diff --git a/src/corelib/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in b/src/corelib/Qt6CoreConfigExtrasMkspecDirForInstall.cmake.in
index 706304cf34..706304cf34 100644
--- a/src/corelib/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in
+++ b/src/corelib/Qt6CoreConfigExtrasMkspecDirForInstall.cmake.in
diff --git a/src/corelib/Qt5CoreMacros.cmake b/src/corelib/Qt6CoreMacros.cmake
index e298cf7de7..da0b4641ae 100644
--- a/src/corelib/Qt5CoreMacros.cmake
+++ b/src/corelib/Qt6CoreMacros.cmake
@@ -39,7 +39,7 @@
include(CMakeParseArguments)
# macro used to create the names of output files preserving relative dirs
-macro(qt5_make_output_file infile prefix ext outfile )
+macro(qt6_make_output_file infile prefix ext outfile )
string(LENGTH ${CMAKE_CURRENT_BINARY_DIR} _binlength)
string(LENGTH ${infile} _infileLength)
set(_checkinfile ${CMAKE_CURRENT_SOURCE_DIR})
@@ -65,7 +65,7 @@ macro(qt5_make_output_file infile prefix ext outfile )
endmacro()
-macro(qt5_get_moc_flags _moc_flags)
+macro(qt6_get_moc_flags _moc_flags)
set(${_moc_flags})
get_directory_property(_inc_DIRS INCLUDE_DIRECTORIES)
@@ -97,7 +97,7 @@ endmacro()
# helper macro to set up a moc rule
-function(qt5_create_moc_command infile outfile moc_flags moc_options moc_target moc_depends)
+function(qt6_create_moc_command infile outfile moc_flags moc_options moc_target moc_depends)
# Pass the parameters in a file. Set the working directory to
# be that containing the parameters file and reference it by
# just the file name. This is necessary because the moc tool on
@@ -133,7 +133,7 @@ function(qt5_create_moc_command infile outfile moc_flags moc_options moc_target
set(_moc_extra_parameters_file @${_moc_parameters_file})
add_custom_command(OUTPUT ${outfile}
- COMMAND ${Qt5Core_MOC_EXECUTABLE} ${_moc_extra_parameters_file}
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::moc ${_moc_extra_parameters_file}
DEPENDS ${infile} ${moc_depends}
${_moc_working_dir}
VERBATIM)
@@ -143,9 +143,9 @@ function(qt5_create_moc_command infile outfile moc_flags moc_options moc_target
endfunction()
-function(qt5_generate_moc infile outfile )
+function(qt6_generate_moc infile outfile )
# get include dirs and flags
- qt5_get_moc_flags(moc_flags)
+ qt6_get_moc_flags(moc_flags)
get_filename_component(abs_infile ${infile} ABSOLUTE)
set(_outfile "${outfile}")
if(NOT IS_ABSOLUTE "${outfile}")
@@ -154,15 +154,15 @@ function(qt5_generate_moc infile outfile )
if ("x${ARGV2}" STREQUAL "xTARGET")
set(moc_target ${ARGV3})
endif()
- qt5_create_moc_command(${abs_infile} ${_outfile} "${moc_flags}" "" "${moc_target}" "")
+ qt6_create_moc_command(${abs_infile} ${_outfile} "${moc_flags}" "" "${moc_target}" "")
endfunction()
-# qt5_wrap_cpp(outfiles inputfile ... )
+# qt6_wrap_cpp(outfiles inputfile ... )
-function(qt5_wrap_cpp outfiles )
+function(qt6_wrap_cpp outfiles )
# get include dirs
- qt5_get_moc_flags(moc_flags)
+ qt6_get_moc_flags(moc_flags)
set(options)
set(oneValueArgs TARGET)
@@ -177,8 +177,8 @@ function(qt5_wrap_cpp outfiles )
foreach(it ${moc_files})
get_filename_component(it ${it} ABSOLUTE)
- qt5_make_output_file(${it} moc_ cpp outfile)
- qt5_create_moc_command(${it} ${outfile} "${moc_flags}" "${moc_options}" "${moc_target}" "${moc_depends}")
+ qt6_make_output_file(${it} moc_ cpp outfile)
+ qt6_create_moc_command(${it} ${outfile} "${moc_flags}" "${moc_options}" "${moc_target}" "${moc_depends}")
list(APPEND ${outfiles} ${outfile})
endforeach()
set(${outfiles} ${${outfiles}} PARENT_SCOPE)
@@ -186,10 +186,10 @@ endfunction()
-# _qt5_parse_qrc_file(infile _out_depends _rc_depends)
+# _qt6_parse_qrc_file(infile _out_depends _rc_depends)
# internal
-function(_qt5_parse_qrc_file infile _out_depends _rc_depends)
+function(_qt6_parse_qrc_file infile _out_depends _rc_depends)
get_filename_component(rc_path ${infile} PATH)
if(EXISTS "${infile}")
@@ -207,7 +207,7 @@ function(_qt5_parse_qrc_file infile _out_depends _rc_depends)
# Since this cmake macro is doing the dependency scanning for these files,
# let's make a configured file and add it as a dependency so cmake is run
# again when dependencies need to be recomputed.
- qt5_make_output_file("${infile}" "" "qrc.depends" out_depends)
+ qt6_make_output_file("${infile}" "" "qrc.depends" out_depends)
configure_file("${infile}" "${out_depends}" COPYONLY)
else()
# The .qrc file does not exist (yet). Let's add a dependency and hope
@@ -220,9 +220,9 @@ function(_qt5_parse_qrc_file infile _out_depends _rc_depends)
endfunction()
-# qt5_add_binary_resources(target inputfiles ... )
+# qt6_add_binary_resources(target inputfiles ... )
-function(qt5_add_binary_resources target )
+function(qt6_add_binary_resources target )
set(options)
set(oneValueArgs DESTINATION)
@@ -241,7 +241,7 @@ function(qt5_add_binary_resources target )
foreach(it ${rcc_files})
get_filename_component(infile ${it} ABSOLUTE)
- _qt5_parse_qrc_file(${infile} _out_depends _rc_depends)
+ _qt6_parse_qrc_file(${infile} _out_depends _rc_depends)
set_source_files_properties(${infile} PROPERTIES SKIP_AUTORCC ON)
set(infiles ${infiles} ${infile})
set(out_depends ${out_depends} ${_out_depends})
@@ -249,55 +249,64 @@ function(qt5_add_binary_resources target )
endforeach()
add_custom_command(OUTPUT ${rcc_destination}
- COMMAND ${Qt5Core_RCC_EXECUTABLE}
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::rcc
ARGS ${rcc_options} --binary --name ${target} --output ${rcc_destination} ${infiles}
DEPENDS ${rc_depends} ${out_depends} ${infiles} VERBATIM)
add_custom_target(${target} ALL DEPENDS ${rcc_destination})
endfunction()
-# qt5_add_resources(outfiles inputfile ... )
+# qt6_add_resources(target resourcename ...
+# or
+# qt6_add_resources(outfiles inputfile ... )
-function(qt5_add_resources outfiles )
+function(qt6_add_resources outfiles )
+ if (TARGET ${outfiles})
+ cmake_parse_arguments(arg "" "OUTPUT_TARGETS" "" ${ARGN})
+ qt6_process_resource(${ARGV})
+ if (arg_OUTPUT_TARGETS)
+ set(${arg_OUTPUT_TARGETS} ${${arg_OUTPUT_TARGETS}} PARENT_SCOPE)
+ endif()
+ else()
+ set(options)
+ set(oneValueArgs)
+ set(multiValueArgs OPTIONS)
- set(options)
- set(oneValueArgs)
- set(multiValueArgs OPTIONS)
+ cmake_parse_arguments(_RCC "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN})
- cmake_parse_arguments(_RCC "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN})
+ set(rcc_files ${_RCC_UNPARSED_ARGUMENTS})
+ set(rcc_options ${_RCC_OPTIONS})
- set(rcc_files ${_RCC_UNPARSED_ARGUMENTS})
- set(rcc_options ${_RCC_OPTIONS})
+ if("${rcc_options}" MATCHES "-binary")
+ message(WARNING "Use qt6_add_binary_resources for binary option")
+ endif()
- if("${rcc_options}" MATCHES "-binary")
- message(WARNING "Use qt5_add_binary_resources for binary option")
+ foreach(it ${rcc_files})
+ get_filename_component(outfilename ${it} NAME_WE)
+ get_filename_component(infile ${it} ABSOLUTE)
+ set(outfile ${CMAKE_CURRENT_BINARY_DIR}/qrc_${outfilename}.cpp)
+
+ _qt6_parse_qrc_file(${infile} _out_depends _rc_depends)
+ set_source_files_properties(${infile} PROPERTIES SKIP_AUTORCC ON)
+
+ add_custom_command(OUTPUT ${outfile}
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::rcc
+ ARGS ${rcc_options} --name ${outfilename} --output ${outfile} ${infile}
+ MAIN_DEPENDENCY ${infile}
+ DEPENDS ${_rc_depends} "${_out_depends}" VERBATIM)
+ set_source_files_properties(${outfile} PROPERTIES SKIP_AUTOMOC ON)
+ set_source_files_properties(${outfile} PROPERTIES SKIP_AUTOUIC ON)
+ list(APPEND ${outfiles} ${outfile})
+ endforeach()
+ set(${outfiles} ${${outfiles}} PARENT_SCOPE)
endif()
-
- foreach(it ${rcc_files})
- get_filename_component(outfilename ${it} NAME_WE)
- get_filename_component(infile ${it} ABSOLUTE)
- set(outfile ${CMAKE_CURRENT_BINARY_DIR}/qrc_${outfilename}.cpp)
-
- _qt5_parse_qrc_file(${infile} _out_depends _rc_depends)
- set_source_files_properties(${infile} PROPERTIES SKIP_AUTORCC ON)
-
- add_custom_command(OUTPUT ${outfile}
- COMMAND ${Qt5Core_RCC_EXECUTABLE}
- ARGS ${rcc_options} --name ${outfilename} --output ${outfile} ${infile}
- MAIN_DEPENDENCY ${infile}
- DEPENDS ${_rc_depends} "${_out_depends}" VERBATIM)
- set_source_files_properties(${outfile} PROPERTIES SKIP_AUTOMOC ON)
- set_source_files_properties(${outfile} PROPERTIES SKIP_AUTOUIC ON)
- list(APPEND ${outfiles} ${outfile})
- endforeach()
- set(${outfiles} ${${outfiles}} PARENT_SCOPE)
endfunction()
-# qt5_add_big_resources(outfiles inputfile ... )
+# qt6_add_big_resources(outfiles inputfile ... )
-function(qt5_add_big_resources outfiles )
+function(qt6_add_big_resources outfiles )
if (CMAKE_VERSION VERSION_LESS 3.9)
- message(FATAL_ERROR, "qt5_add_big_resources requires CMake 3.9 or newer")
+ message(FATAL_ERROR, "qt6_add_big_resources requires CMake 3.9 or newer")
endif()
set(options)
@@ -310,7 +319,7 @@ function(qt5_add_big_resources outfiles )
set(rcc_options ${_RCC_OPTIONS})
if("${rcc_options}" MATCHES "-binary")
- message(WARNING "Use qt5_add_binary_resources for binary option")
+ message(WARNING "Use qt6_add_binary_resources for binary option")
endif()
foreach(it ${rcc_files})
@@ -319,10 +328,10 @@ function(qt5_add_big_resources outfiles )
set(tmpoutfile ${CMAKE_CURRENT_BINARY_DIR}/qrc_${outfilename}tmp.cpp)
set(outfile ${CMAKE_CURRENT_BINARY_DIR}/qrc_${outfilename}.o)
- _qt5_parse_qrc_file(${infile} _out_depends _rc_depends)
+ _qt6_parse_qrc_file(${infile} _out_depends _rc_depends)
set_source_files_properties(${infile} PROPERTIES SKIP_AUTORCC ON)
add_custom_command(OUTPUT ${tmpoutfile}
- COMMAND ${Qt5Core_RCC_EXECUTABLE} ${rcc_options} --name ${outfilename} --pass 1 --output ${tmpoutfile} ${infile}
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::rcc ${rcc_options} --name ${outfilename} --pass 1 --output ${tmpoutfile} ${infile}
DEPENDS ${infile} ${_rc_depends} "${out_depends}" VERBATIM)
add_custom_target(big_resources_${outfilename} ALL DEPENDS ${tmpoutfile})
add_library(rcc_object_${outfilename} OBJECT ${tmpoutfile})
@@ -332,7 +341,7 @@ function(qt5_add_big_resources outfiles )
# The modification of TARGET_OBJECTS needs the following change in cmake
# https://gitlab.kitware.com/cmake/cmake/commit/93c89bc75ceee599ba7c08b8fe1ac5104942054f
add_custom_command(OUTPUT ${outfile}
- COMMAND ${Qt5Core_RCC_EXECUTABLE}
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::rcc
ARGS ${rcc_options} --name ${outfilename} --pass 2 --temp $<TARGET_OBJECTS:rcc_object_${outfilename}> --output ${outfile} ${infile}
DEPENDS rcc_object_${outfilename}
VERBATIM)
@@ -341,9 +350,9 @@ function(qt5_add_big_resources outfiles )
set(${outfiles} ${${outfiles}} PARENT_SCOPE)
endfunction()
-set(_Qt5_COMPONENT_PATH "${CMAKE_CURRENT_LIST_DIR}/..")
+set(_Qt6_COMPONENT_PATH "${CMAKE_CURRENT_LIST_DIR}/..")
-macro(qt5_use_modules _target _link_type)
+macro(qt6_use_modules _target _link_type)
if(CMAKE_WARN_DEPRECATED)
set(messageType WARNING)
endif()
@@ -351,45 +360,141 @@ macro(qt5_use_modules _target _link_type)
set(messageType FATAL_ERROR)
endif()
if(messageType)
- message(${messageType} "The qt5_use_modules macro is obsolete. Use target_link_libraries with IMPORTED targets instead.")
+ message(${messageType} "The qt6_use_modules macro is obsolete. Use target_link_libraries with IMPORTED targets instead.")
endif()
if (NOT TARGET ${_target})
- message(FATAL_ERROR "The first argument to qt5_use_modules must be an existing target.")
+ message(FATAL_ERROR "The first argument to qt6_use_modules must be an existing target.")
endif()
if ("${_link_type}" STREQUAL "LINK_PUBLIC" OR "${_link_type}" STREQUAL "LINK_PRIVATE" )
- set(_qt5_modules ${ARGN})
- set(_qt5_link_type ${_link_type})
+ set(_qt6_modules ${ARGN})
+ set(_qt6_link_type ${_link_type})
else()
- set(_qt5_modules ${_link_type} ${ARGN})
+ set(_qt6_modules ${_link_type} ${ARGN})
endif()
- if ("${_qt5_modules}" STREQUAL "")
- message(FATAL_ERROR "qt5_use_modules requires at least one Qt module to use.")
+ if ("${_qt6_modules}" STREQUAL "")
+ message(FATAL_ERROR "qt6_use_modules requires at least one Qt module to use.")
endif()
- foreach(_module ${_qt5_modules})
- if (NOT Qt5${_module}_FOUND)
- find_package(Qt5${_module} PATHS "${_Qt5_COMPONENT_PATH}" NO_DEFAULT_PATH)
- if (NOT Qt5${_module}_FOUND)
+ foreach(_module ${_qt6_modules})
+ if (NOT Qt6${_module}_FOUND)
+ find_package(Qt6${_module} PATHS "${_Qt6_COMPONENT_PATH}" NO_DEFAULT_PATH)
+ if (NOT Qt6${_module}_FOUND)
message(FATAL_ERROR "Cannot use \"${_module}\" module which has not yet been found.")
endif()
endif()
- target_link_libraries(${_target} ${_qt5_link_type} ${Qt5${_module}_LIBRARIES})
- set_property(TARGET ${_target} APPEND PROPERTY INCLUDE_DIRECTORIES ${Qt5${_module}_INCLUDE_DIRS})
- set_property(TARGET ${_target} APPEND PROPERTY COMPILE_DEFINITIONS ${Qt5${_module}_COMPILE_DEFINITIONS})
+ target_link_libraries(${_target} ${_qt6_link_type} ${Qt6${_module}_LIBRARIES})
+ set_property(TARGET ${_target} APPEND PROPERTY INCLUDE_DIRECTORIES ${Qt6${_module}_INCLUDE_DIRS})
+ set_property(TARGET ${_target} APPEND PROPERTY COMPILE_DEFINITIONS ${Qt6${_module}_COMPILE_DEFINITIONS})
set_property(TARGET ${_target} APPEND PROPERTY COMPILE_DEFINITIONS_RELEASE QT_NO_DEBUG)
set_property(TARGET ${_target} APPEND PROPERTY COMPILE_DEFINITIONS_RELWITHDEBINFO QT_NO_DEBUG)
set_property(TARGET ${_target} APPEND PROPERTY COMPILE_DEFINITIONS_MINSIZEREL QT_NO_DEBUG)
- if (Qt5_POSITION_INDEPENDENT_CODE
- AND (NOT CMAKE_CXX_COMPILER_ID STREQUAL "GNU"
- OR CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5.0))
- set_property(TARGET ${_target} PROPERTY POSITION_INDEPENDENT_CODE ${Qt5_POSITION_INDEPENDENT_CODE})
+ if (Qt6_POSITION_INDEPENDENT_CODE
+ AND (NOT CMAKE_CXX_COMPILER_ID STREQUAL "GNU"
+ OR CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5.0))
+ set_property(TARGET ${_target} PROPERTY POSITION_INDEPENDENT_CODE ${Qt6_POSITION_INDEPENDENT_CODE})
endif()
endforeach()
endmacro()
-function(qt5_import_plugins TARGET_NAME)
+function(add_qt_gui_executable target)
+ if(ANDROID)
+ add_library("${target}" MODULE ${ARGN})
+ # On our qmake builds we do don't compile the executables with
+ # visibility=hidden. Not having this flag set will cause the
+ # executable to have main() hidden and can then no longer be loaded
+ # through dlopen()
+ set_property(TARGET "${target}" PROPERTY C_VISIBILITY_PRESET default)
+ set_property(TARGET "${target}" PROPERTY CXX_VISIBILITY_PRESET default)
+ qt_android_apply_arch_suffix("${target}")
+ else()
+ add_executable("${target}" WIN32 MACOSX_BUNDLE ${ARGN})
+ endif()
+ target_link_libraries("${target}" PRIVATE Qt::Core)
+ if(TARGET Qt::Gui)
+ target_link_libraries("${target}" PRIVATE Qt::Gui)
+ endif()
+
+ if(ANDROID)
+ qt_android_generate_deployment_settings("${target}")
+ qt_android_add_apk_target("${target}")
+ endif()
+endfunction()
+
+macro(_qt_import_plugin target plugin)
+ get_target_property(plugin_class_name "${plugin}" QT_PLUGIN_CLASS_NAME)
+ if(plugin_class_name)
+ set_property(TARGET "${target}" APPEND PROPERTY QT_PLUGINS "${plugin}")
+ endif()
+endmacro()
+
+# This function is used to indicate which plug-ins are going to be
+# used by a given target.
+# This allows static linking to a correct set of plugins.
+# Options :
+# NO_DEFAULT: disable linking against any plug-in by default for that target, e.g. no platform plug-in.
+# INCLUDE <list of additional plug-ins to be linked against>
+# EXCLUDE <list of plug-ins to be removed from the default set>
+# INCLUDE_BY_TYPE <type> <included plugins>
+# EXCLUDE_BY_TYPE <type to be excluded>
+#
+# Example :
+# qt_import_plugins(myapp
+# INCLUDE Qt::QCocoaIntegrationPlugin
+# EXCLUDE Qt::QMinimalIntegrationPlugin
+# INCLUDE_BY_TYPE imageformats Qt::QGifPlugin Qt::QJpegPlugin
+# EXCLUDE_BY_TYPE sqldrivers
+# )
+
+# TODO : support qml plug-ins.
+function(qt_import_plugins target)
+ cmake_parse_arguments(arg "NO_DEFAULT" "" "INCLUDE;EXCLUDE;INCLUDE_BY_TYPE;EXCLUDE_BY_TYPE" ${ARGN})
+
+ # Handle NO_DEFAULT
+ if(${arg_NO_DEFAULT})
+ set_target_properties(${target} PROPERTIES QT_DEFAULT_PLUGINS 0)
+ endif()
+
+ # Handle INCLUDE
+ foreach(plugin ${arg_INCLUDE})
+ _qt_import_plugin("${target}" "${plugin}")
+ endforeach()
+
+ # Handle EXCLUDE
+ foreach(plugin ${arg_EXCLUDE})
+ set_property(TARGET "${target}" APPEND PROPERTY QT_NO_PLUGINS "${plugin}")
+ endforeach()
+
+ # Handle INCLUDE_BY_TYPE
+ set(_current_type "")
+ foreach(_arg ${arg_INCLUDE_BY_TYPE})
+ string(REGEX REPLACE "[-/]" "_" _plugin_type "${_arg}")
+ list(FIND QT_ALL_PLUGIN_TYPES_FOUND_VIA_FIND_PACKAGE "${_plugin_type}" _has_plugin_type)
+
+ if(${_has_plugin_type} GREATER_EQUAL 0)
+ set(_current_type "${_plugin_type}")
+ else()
+ if("${_current_type}" STREQUAL "")
+ message(FATAL_ERROR "qt_import_plugins: invalid syntax for INCLUDE_BY_TYPE")
+ endif()
+
+ if(TARGET "${_arg}")
+ set_property(TARGET "${target}" APPEND PROPERTY "QT_PLUGINS_${_current_type}" "${_arg}")
+ else()
+ message("Warning: plug-in ${_arg} is not known to the current Qt installation.")
+ endif()
+ endif()
+ endforeach()
+
+ # Handle EXCLUDE_BY_TYPE
+ foreach(_arg ${arg_EXCLUDE_BY_TYPE})
+ string(REGEX REPLACE "[-/]" "_" _plugin_type "${_arg}")
+ set_property(TARGET "${target}" PROPERTY "QT_PLUGINS_${_plugin_type}" "-")
+ endforeach()
+endfunction()
+
+function(qt6_import_plugins TARGET_NAME)
set(_doing "")
foreach(_arg ${ARGN})
if(_arg STREQUAL "INCLUDE")
@@ -420,3 +525,61 @@ function(qt5_import_plugins TARGET_NAME)
endif()
endforeach()
endfunction()
+
+
+function(qt6_generate_meta_types_json_file target)
+
+ get_target_property(target_type ${target} TYPE)
+ if (target_type STREQUAL "INTERFACE_LIBRARY" OR CMAKE_VERSION VERSION_LESS "3.16.0")
+ # interface libraries not supported or cmake version is not high enough
+ message(WARNING "Meta types generation requires CMake >= 3.16")
+ return()
+ endif()
+
+ get_target_property(existing_meta_types_file ${target} QT_MODULE_META_TYPES_FILE)
+ if (existing_meta_types_file)
+ return()
+ endif()
+
+ get_target_property(target_binary_dir ${target} BINARY_DIR)
+
+ set(cmake_autogen_cache_file
+ "${target_binary_dir}/CMakeFiles/${target}_autogen.dir/ParseCache.txt")
+ set(cmake_autogen_info_file
+ "${target_binary_dir}/CMakeFiles/${target}_autogen.dir/AutogenInfo.json")
+ set(type_list_file "${target_binary_dir}/meta_types/json_file_list.txt")
+
+ add_custom_target(${target}_automoc_json_extraction
+ BYPRODUCTS ${type_list_file}
+ COMMAND
+ ${QT_CMAKE_EXPORT_NAMESPACE}::cmake_automoc_parser
+ --cmake-autogen-cache-file "${cmake_autogen_cache_file}"
+ --cmake-autogen-info-file "${cmake_autogen_info_file}"
+ --output-file-path "${type_list_file}"
+ --cmake-autogen-include-dir-path "${target_binary_dir}/${target}_autogen/include"
+ COMMENT "Running Automoc file extraction"
+ )
+
+ add_dependencies(${target}_automoc_json_extraction ${target}_autogen)
+
+ if (CMAKE_BUILD_TYPE)
+ string(TOLOWER ${target}_${CMAKE_BUILD_TYPE} target_lowercase)
+ else()
+ message(FATAL_ERROR "add_custom_command's OUTPUT parameter does not support generator expressions, so we can't generate this file for multi-config generators")
+ endif()
+ set(metatypes_file "${target_binary_dir}/meta_types/qt6${target_lowercase}_metatypes.json")
+ add_custom_command(OUTPUT ${metatypes_file}
+ DEPENDS ${type_list_file}
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::moc
+ -o ${metatypes_file}
+ --collect-json "@${type_list_file}"
+ COMMENT "Runing automoc with --collect-json"
+ )
+
+ target_sources(${target} PRIVATE ${metatypes_file})
+ set_source_files_properties(${metatypes_file} PROPERTIES HEADER_FILE_ONLY TRUE)
+
+ set_target_properties(${target} PROPERTIES
+ QT_MODULE_META_TYPES_FILE ${metatypes_file}
+ )
+endfunction()
diff --git a/src/corelib/Qt5ModuleLocation.cmake.in b/src/corelib/Qt6ModuleLocation.cmake.in
index cf70f6bc0e..cf70f6bc0e 100644
--- a/src/corelib/Qt5ModuleLocation.cmake.in
+++ b/src/corelib/Qt6ModuleLocation.cmake.in
diff --git a/src/corelib/Qt5ModuleLocationForInstall.cmake.in b/src/corelib/Qt6ModuleLocationForInstall.cmake.in
index 8751e4acbc..8751e4acbc 100644
--- a/src/corelib/Qt5ModuleLocationForInstall.cmake.in
+++ b/src/corelib/Qt6ModuleLocationForInstall.cmake.in
diff --git a/src/corelib/configure.cmake b/src/corelib/configure.cmake
new file mode 100644
index 0000000000..4e97964b8c
--- /dev/null
+++ b/src/corelib/configure.cmake
@@ -0,0 +1,954 @@
+
+
+#### Inputs
+
+# input iconv
+set(INPUT_iconv "undefined" CACHE STRING "")
+set_property(CACHE INPUT_iconv PROPERTY STRINGS undefined no yes posix sun gnu)
+
+
+
+#### Libraries
+
+qt_find_package(GLIB2 PROVIDED_TARGETS GLIB2::GLIB2)
+qt_find_package(ICU COMPONENTS i18n uc data PROVIDED_TARGETS ICU::i18n ICU::uc ICU::data)
+qt_find_package(Libsystemd PROVIDED_TARGETS PkgConfig::Libsystemd)
+qt_find_package(Atomic PROVIDED_TARGETS Atomic)
+qt_find_package(WrapRt PROVIDED_TARGETS WrapRt)
+qt_find_package(LTTngUST PROVIDED_TARGETS LTTng::UST)
+qt_find_package(WrapPCRE2 PROVIDED_TARGETS WrapPCRE2::WrapPCRE2)
+set_package_properties(WrapPCRE2 PROPERTIES TYPE REQUIRED)
+if((QNX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(PPS PROVIDED_TARGETS PPS::PPS)
+endif()
+qt_find_package(Slog2 PROVIDED_TARGETS Slog2::Slog2)
+
+
+#### Tests
+
+# atomicfptr
+qt_config_compile_test(atomicfptr
+ LABEL "working std::atomic for function pointers"
+ CODE
+"
+#include <atomic>
+typedef void (*fptr)(int);
+typedef std::atomic<fptr> atomicfptr;
+void testfunction(int) { }
+void test(volatile atomicfptr &a)
+{
+ fptr v = a.load(std::memory_order_acquire);
+ while (!a.compare_exchange_strong(v, &testfunction,
+ std::memory_order_acq_rel,
+ std::memory_order_acquire)) {
+ v = a.exchange(&testfunction);
+ }
+ a.store(&testfunction, std::memory_order_release);
+}
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+atomicfptr fptr(testfunction);
+test(fptr);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# clock-monotonic
+qt_config_compile_test(clock_monotonic
+ LABEL "POSIX monotonic clock"
+ LIBRARIES
+ WrapRt
+ CODE
+"
+#include <unistd.h>
+#include <time.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+#if defined(_POSIX_MONOTONIC_CLOCK) && (_POSIX_MONOTONIC_CLOCK-0 >= 0)
+timespec ts;
+clock_gettime(CLOCK_MONOTONIC, &ts);
+#else
+# error Feature _POSIX_MONOTONIC_CLOCK not available
+#endif
+ /* END TEST: */
+ return 0;
+}
+")
+
+# cloexec
+qt_config_compile_test(cloexec
+ LABEL "O_CLOEXEC"
+ CODE
+"#define _GNU_SOURCE 1
+#include <sys/types.h>
+#include <sys/socket.h>
+#include <fcntl.h>
+#include <unistd.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+int pipes[2];
+(void) pipe2(pipes, O_CLOEXEC | O_NONBLOCK);
+(void) fcntl(0, F_DUPFD_CLOEXEC, 0);
+(void) dup3(0, 3, O_CLOEXEC);
+#if defined(__NetBSD__)
+(void) paccept(0, 0, 0, NULL, SOCK_CLOEXEC | SOCK_NONBLOCK);
+#else
+(void) accept4(0, 0, 0, SOCK_CLOEXEC | SOCK_NONBLOCK);
+#endif
+ /* END TEST: */
+ return 0;
+}
+")
+
+# cxx11_future
+if (UNIX)
+ set(cxx11_future_TEST_LIBRARIES pthread)
+endif()
+qt_config_compile_test(cxx11_future
+ LABEL "C++11 <future>"
+ LIBRARIES
+ "${cxx11_future_TEST_LIBRARIES}"
+ CODE
+"
+#include <future>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+std::future<int> f = std::async([]() { return 42; });
+(void)f.get();
+ /* END TEST: */
+ return 0;
+}
+")
+
+# cxx11_random
+qt_config_compile_test(cxx11_random
+ LABEL "C++11 <random>"
+ CODE
+"
+#include <random>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+std::mt19937 mt(0);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# eventfd
+qt_config_compile_test(eventfd
+ LABEL "eventfd"
+ CODE
+"
+#include <sys/eventfd.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+eventfd_t value;
+int fd = eventfd(0, EFD_CLOEXEC);
+eventfd_read(fd, &value);
+eventfd_write(fd, value);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# futimens
+qt_config_compile_test(futimens
+ LABEL "futimens()"
+ CODE
+"
+#include <sys/stat.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+futimens(-1, 0);
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: qmake: ["# Block futimens() on Apple platforms unless it's available on ALL", '# deployment targets. This simplifies the logic at the call site', "# dramatically, as it isn't strictly needed compared to futimes().", 'darwin: QMAKE_CXXFLAGS += -Werror=unguarded-availability']
+)
+
+# futimes
+qt_config_compile_test(futimes
+ LABEL "futimes()"
+ CODE
+"
+#include <sys/time.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+futimes(-1, 0);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# getauxval
+qt_config_compile_test(getauxval
+ LABEL "getauxval()"
+ CODE
+"
+#include <sys/auxv.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+(void) getauxval(AT_NULL);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# getentropy
+qt_config_compile_test(getentropy
+ LABEL "getentropy()"
+ CODE
+"
+#include <unistd.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+char buf[32];
+(void) getentropy(buf, sizeof(buf));
+ /* END TEST: */
+ return 0;
+}
+")
+
+# glibc
+qt_config_compile_test(glibc
+ LABEL "GNU libc"
+ CODE
+"
+#include <stdlib.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+return __GLIBC__;
+ /* END TEST: */
+ return 0;
+}
+")
+
+# inotify
+qt_config_compile_test(inotify
+ LABEL "inotify"
+ CODE
+"
+#include <sys/inotify.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+inotify_init();
+inotify_add_watch(0, \"foobar\", IN_ACCESS);
+inotify_rm_watch(0, 1);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# ipc_sysv
+qt_config_compile_test(ipc_sysv
+ LABEL "SysV IPC"
+ CODE
+"
+#include <sys/types.h>
+#include <sys/ipc.h>
+#include <sys/sem.h>
+#include <sys/shm.h>
+#include <fcntl.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+key_t unix_key = ftok(\"test\", 'Q');
+semctl(semget(unix_key, 1, 0666 | IPC_CREAT | IPC_EXCL), 0, IPC_RMID, 0);
+shmget(unix_key, 0, 0666 | IPC_CREAT | IPC_EXCL);
+shmctl(0, 0, (struct shmid_ds *)(0));
+ /* END TEST: */
+ return 0;
+}
+")
+
+# ipc_posix
+if (LINUX)
+ set(ipc_posix_TEST_LIBRARIES pthread rt)
+endif()
+qt_config_compile_test(ipc_posix
+ LABEL "POSIX IPC"
+ LIBRARIES
+ "${ipc_posix_TEST_LIBRARIES}"
+ CODE
+"
+#include <sys/types.h>
+#include <sys/mman.h>
+#include <semaphore.h>
+#include <fcntl.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+sem_close(sem_open(\"test\", O_CREAT | O_EXCL, 0666, 0));
+shm_open(\"test\", O_RDWR | O_CREAT | O_EXCL, 0666);
+shm_unlink(\"test\");
+ /* END TEST: */
+ return 0;
+}
+")
+
+# linkat
+qt_config_compile_test(linkat
+ LABEL "linkat()"
+ CODE
+"#define _ATFILE_SOURCE 1
+#include <fcntl.h>
+#include <unistd.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+linkat(AT_FDCWD, \"foo\", AT_FDCWD, \"bar\", AT_SYMLINK_FOLLOW);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# ppoll
+qt_config_compile_test(ppoll
+ LABEL "ppoll()"
+ CODE
+"
+#include <signal.h>
+#include <poll.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+struct pollfd pfd;
+struct timespec ts;
+sigset_t sig;
+ppoll(&pfd, 1, &ts, &sig);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# pollts
+qt_config_compile_test(pollts
+ LABEL "pollts()"
+ CODE
+"
+#include <poll.h>
+#include <signal.h>
+#include <time.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+struct pollfd pfd;
+struct timespec ts;
+sigset_t sig;
+pollts(&pfd, 1, &ts, &sig);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# poll
+qt_config_compile_test(poll
+ LABEL "poll()"
+ CODE
+"
+#include <poll.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+struct pollfd pfd;
+poll(&pfd, 1, 0);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# renameat2
+qt_config_compile_test(renameat2
+ LABEL "renameat2()"
+ CODE
+"#define _ATFILE_SOURCE 1
+#include <fcntl.h>
+#include <stdio.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+renameat2(AT_FDCWD, argv[1], AT_FDCWD, argv[2], RENAME_NOREPLACE | RENAME_WHITEOUT);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# statx
+qt_config_compile_test(statx
+ LABEL "statx() in libc"
+ CODE
+"#define _ATFILE_SOURCE 1
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <unistd.h>
+#include <fcntl.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+struct statx statxbuf;
+unsigned int mask = STATX_BASIC_STATS;
+return statx(AT_FDCWD, \"\", AT_STATX_SYNC_AS_STAT, mask, &statxbuf);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# syslog
+qt_config_compile_test(syslog
+ LABEL "syslog"
+ CODE
+"
+#include <syslog.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+openlog(\"qt\", 0, LOG_USER);
+syslog(LOG_INFO, \"configure\");
+closelog();
+ /* END TEST: */
+ return 0;
+}
+")
+
+# xlocalescanprint
+qt_config_compile_test(xlocalescanprint
+ LABEL "xlocale.h (or equivalents)"
+ CODE
+"
+
+#define QT_BEGIN_NAMESPACE
+#define QT_END_NAMESPACE
+
+#ifdef _MSVC_VER
+#define Q_CC_MSVC _MSVC_VER
+#endif
+
+#define QT_NO_DOUBLECONVERSION
+
+#include QDSP_P_H
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+#ifdef _MSVC_VER
+_locale_t invalidLocale = NULL;
+#else
+locale_t invalidLocale = NULL;
+#endif
+double a = 3.4;
+qDoubleSnprintf(argv[0], 1, invalidLocale, \"invalid format\", a);
+qDoubleSscanf(argv[0], invalidLocale, \"invalid format\", &a, &argc);
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: qmake: DEFINES += QDSP_P_H=$$shell_quote(\"@PWD@/text/qdoublescanprint_p.h\")
+)
+
+
+
+#### Features
+
+qt_feature("clock-gettime" PRIVATE
+ LABEL "clock_gettime()"
+ CONDITION UNIX AND WrapRt_FOUND
+)
+qt_feature("clock-monotonic" PUBLIC
+ LABEL "POSIX monotonic clock"
+ CONDITION QT_FEATURE_clock_gettime AND TEST_clock_monotonic
+)
+qt_feature_definition("clock-monotonic" "QT_NO_CLOCK_MONOTONIC" NEGATE VALUE "1")
+qt_feature("cxx11_future" PUBLIC
+ LABEL "C++11 <future>"
+ CONDITION TEST_cxx11_future
+)
+qt_feature("eventfd" PUBLIC
+ LABEL "eventfd"
+ CONDITION NOT WASM AND TEST_eventfd
+)
+qt_feature_definition("eventfd" "QT_NO_EVENTFD" NEGATE VALUE "1")
+qt_feature("futimens" PRIVATE
+ LABEL "futimens()"
+ CONDITION NOT WIN32 AND TEST_futimens
+)
+qt_feature("futimes" PRIVATE
+ LABEL "futimes()"
+ CONDITION NOT WIN32 AND NOT QT_FEATURE_futimens AND TEST_futimes
+)
+qt_feature("getauxval" PRIVATE
+ LABEL "getauxval()"
+ CONDITION LINUX AND TEST_getauxval
+)
+qt_feature("getentropy" PRIVATE
+ LABEL "getentropy()"
+ CONDITION UNIX AND TEST_getentropy
+)
+qt_feature("glib" PUBLIC PRIVATE
+ LABEL "GLib"
+ AUTODETECT NOT WIN32
+ CONDITION GLIB2_FOUND
+)
+qt_feature_definition("glib" "QT_NO_GLIB" NEGATE VALUE "1")
+qt_feature("glibc" PRIVATE
+ LABEL "GNU libc"
+ AUTODETECT LINUX
+ CONDITION TEST_glibc
+)
+qt_feature("iconv" PUBLIC PRIVATE
+ SECTION "Internationalization"
+ LABEL "iconv"
+ PURPOSE "Provides internationalization on Unix."
+ CONDITION NOT QT_FEATURE_icu AND QT_FEATURE_textcodec AND ( TEST_posix_iconv OR TEST_sun_iconv )
+)
+qt_feature_definition("iconv" "QT_NO_ICONV" NEGATE VALUE "1")
+qt_feature("posix-libiconv" PRIVATE
+ LABEL "POSIX iconv"
+ CONDITION NOT WIN32 AND NOT QNX AND NOT ANDROID AND NOT APPLE AND TEST_posix_iconv AND TEST_iconv_needlib
+ ENABLE TEST_posix_iconv AND TEST_iconv_needlib
+ DISABLE NOT TEST_posix_iconv OR NOT TEST_iconv_needlib
+)
+qt_feature("sun-libiconv"
+ LABEL "SUN iconv"
+ CONDITION NOT WIN32 AND NOT QNX AND NOT ANDROID AND NOT APPLE AND TEST_sun_iconv
+ ENABLE TEST_sun_iconv
+ DISABLE NOT TEST_sun_iconv
+)
+qt_feature("gnu-libiconv" PRIVATE
+ LABEL "GNU iconv"
+ CONDITION NOT WIN32 AND NOT QNX AND NOT ANDROID AND NOT APPLE AND TEST_posix_iconv AND NOT TEST_iconv_needlib
+ ENABLE TEST_posix_iconv AND NOT TEST_iconv_needlib
+ DISABLE NOT TEST_posix_iconv OR TEST_iconv_needlib
+)
+qt_feature("icu" PRIVATE
+ LABEL "ICU"
+ AUTODETECT NOT WIN32
+ CONDITION ICU_FOUND
+)
+qt_feature("inotify" PUBLIC PRIVATE
+ LABEL "inotify"
+ CONDITION TEST_inotify
+)
+qt_feature_definition("inotify" "QT_NO_INOTIFY" NEGATE VALUE "1")
+qt_feature("ipc_posix"
+ LABEL "Using POSIX IPC"
+ AUTODETECT NOT WIN32
+ CONDITION NOT TEST_ipc_sysv AND TEST_ipc_posix
+)
+qt_feature_definition("ipc_posix" "QT_POSIX_IPC")
+qt_feature("journald" PRIVATE
+ LABEL "journald"
+ AUTODETECT OFF
+ CONDITION Libsystemd_FOUND
+)
+# Currently only used by QTemporaryFile; linkat() exists on Android, but hardlink creation fails due to security rules
+qt_feature("linkat" PRIVATE
+ LABEL "linkat()"
+ AUTODETECT LINUX AND NOT ANDROID
+ CONDITION TEST_linkat
+)
+qt_feature("std-atomic64" PUBLIC
+ LABEL "64 bit atomic operations"
+ CONDITION Atomic_FOUND
+)
+qt_feature("mimetype" PUBLIC
+ SECTION "Utilities"
+ LABEL "Mimetype handling"
+ PURPOSE "Provides MIME type handling."
+ CONDITION QT_FEATURE_textcodec
+)
+qt_feature_definition("mimetype" "QT_NO_MIMETYPE" NEGATE VALUE "1")
+qt_feature("mimetype-database" PRIVATE
+ LABEL "Built-in copy of the MIME database"
+ CONDITION QT_FEATURE_mimetype
+)
+qt_feature("pcre2"
+ LABEL "PCRE2"
+ ENABLE INPUT_pcre STREQUAL 'qt'
+ DISABLE INPUT_pcre STREQUAL 'no' OR INPUT_pcre STREQUAL 'system'
+)
+qt_feature_config("pcre2" QMAKE_PRIVATE_CONFIG)
+qt_feature("poll_ppoll" PRIVATE
+ LABEL "Native ppoll()"
+ CONDITION NOT WASM AND TEST_ppoll
+ EMIT_IF NOT WIN32
+)
+qt_feature("poll_pollts" PRIVATE
+ LABEL "Native pollts()"
+ CONDITION NOT QT_FEATURE_poll_ppoll AND TEST_pollts
+ EMIT_IF NOT WIN32
+)
+qt_feature("poll_poll" PRIVATE
+ LABEL "Native poll()"
+ CONDITION NOT QT_FEATURE_poll_ppoll AND NOT QT_FEATURE_poll_pollts AND TEST_poll
+ EMIT_IF NOT WIN32
+)
+qt_feature("poll_select" PRIVATE
+ LABEL "Emulated poll()"
+ CONDITION NOT QT_FEATURE_poll_ppoll AND NOT QT_FEATURE_poll_pollts AND NOT QT_FEATURE_poll_poll
+ EMIT_IF NOT WIN32
+)
+qt_feature_definition("poll_select" "QT_NO_NATIVE_POLL")
+qt_feature("qqnx_pps" PRIVATE
+ LABEL "PPS"
+ CONDITION PPS_FOUND
+ EMIT_IF QNX
+)
+qt_feature("renameat2" PRIVATE
+ LABEL "renameat2()"
+ CONDITION LINUX AND TEST_renameat2
+)
+qt_feature("slog2" PRIVATE
+ LABEL "slog2"
+ CONDITION Slog2_FOUND
+)
+qt_feature("statx" PRIVATE
+ LABEL "statx() in libc"
+ CONDITION LINUX AND TEST_statx
+)
+qt_feature("syslog" PRIVATE
+ LABEL "syslog"
+ AUTODETECT OFF
+ CONDITION TEST_syslog
+)
+qt_feature("threadsafe-cloexec"
+ LABEL "Threadsafe pipe creation"
+ CONDITION TEST_cloexec
+)
+qt_feature_definition("threadsafe-cloexec" "QT_THREADSAFE_CLOEXEC" VALUE "1")
+qt_feature_config("threadsafe-cloexec" QMAKE_PUBLIC_QT_CONFIG)
+qt_feature("properties" PUBLIC
+ SECTION "Kernel"
+ LABEL "Properties"
+ PURPOSE "Supports scripting Qt-based applications."
+)
+qt_feature_definition("properties" "QT_NO_PROPERTIES" NEGATE VALUE "1")
+qt_feature("regularexpression" PUBLIC
+ SECTION "Kernel"
+ LABEL "QRegularExpression"
+ PURPOSE "Provides an API to Perl-compatible regular expressions."
+ CONDITION ON OR QT_FEATURE_pcre2
+)
+qt_feature_definition("regularexpression" "QT_NO_REGULAREXPRESSION" NEGATE VALUE "1")
+qt_feature("sharedmemory" PUBLIC
+ SECTION "Kernel"
+ LABEL "QSharedMemory"
+ PURPOSE "Provides access to a shared memory segment."
+ CONDITION ( ANDROID OR WIN32 OR ( NOT VXWORKS AND ( TEST_ipc_sysv OR TEST_ipc_posix ) ) )
+)
+qt_feature_definition("sharedmemory" "QT_NO_SHAREDMEMORY" NEGATE VALUE "1")
+qt_feature("shortcut" PUBLIC
+ SECTION "Kernel"
+ LABEL "QShortcut"
+ PURPOSE "Provides keyboard accelerators and shortcuts."
+)
+qt_feature_definition("shortcut" "QT_NO_SHORTCUT" NEGATE VALUE "1")
+qt_feature("systemsemaphore" PUBLIC
+ SECTION "Kernel"
+ LABEL "QSystemSemaphore"
+ PURPOSE "Provides a general counting system semaphore."
+ CONDITION ( NOT INTEGRITY AND NOT VXWORKS AND NOT rtems ) AND ( ANDROID OR WIN32 OR TEST_ipc_sysv OR TEST_ipc_posix )
+)
+qt_feature_definition("systemsemaphore" "QT_NO_SYSTEMSEMAPHORE" NEGATE VALUE "1")
+qt_feature("xmlstream" PUBLIC
+ SECTION "Kernel"
+ LABEL "XML Streaming APIs"
+ PURPOSE "Provides a simple streaming API for XML."
+)
+qt_feature_definition("xmlstream" "QT_NO_XMLSTREAM" NEGATE VALUE "1")
+qt_feature("xmlstreamreader" PUBLIC
+ SECTION "Kernel"
+ LABEL "QXmlStreamReader"
+ PURPOSE "Provides a well-formed XML parser with a simple streaming API."
+ CONDITION QT_FEATURE_xmlstream
+)
+qt_feature_definition("xmlstreamreader" "QT_NO_XMLSTREAMREADER" NEGATE VALUE "1")
+qt_feature("xmlstreamwriter" PUBLIC
+ SECTION "Kernel"
+ LABEL "QXmlStreamWriter"
+ PURPOSE "Provides a XML writer with a simple streaming API."
+ CONDITION QT_FEATURE_xmlstream
+)
+qt_feature_definition("xmlstreamwriter" "QT_NO_XMLSTREAMWRITER" NEGATE VALUE "1")
+qt_feature("textdate" PUBLIC
+ SECTION "Data structures"
+ LABEL "Text Date"
+ PURPOSE "Supports month and day names in dates."
+)
+qt_feature_definition("textdate" "QT_NO_TEXTDATE" NEGATE VALUE "1")
+qt_feature("datestring" PUBLIC
+ SECTION "Data structures"
+ LABEL "QDate/QTime/QDateTime"
+ PURPOSE "Provides conversion between dates and strings."
+ CONDITION QT_FEATURE_textdate
+)
+qt_feature_definition("datestring" "QT_NO_DATESTRING" NEGATE VALUE "1")
+qt_feature("process" PUBLIC
+ SECTION "File I/O"
+ LABEL "QProcess"
+ PURPOSE "Supports external process invocation."
+ CONDITION QT_FEATURE_processenvironment AND NOT WINRT AND NOT APPLE_UIKIT AND NOT INTEGRITY AND NOT VXWORKS AND NOT rtems
+)
+qt_feature_definition("process" "QT_NO_PROCESS" NEGATE VALUE "1")
+qt_feature("processenvironment" PUBLIC
+ SECTION "File I/O"
+ LABEL "QProcessEnvironment"
+ PURPOSE "Provides a higher-level abstraction of environment variables."
+ CONDITION NOT WINRT AND NOT INTEGRITY AND NOT rtems
+)
+qt_feature("temporaryfile" PUBLIC
+ SECTION "File I/O"
+ LABEL "QTemporaryFile"
+ PURPOSE "Provides an I/O device that operates on temporary files."
+)
+qt_feature_definition("temporaryfile" "QT_NO_TEMPORARYFILE" NEGATE VALUE "1")
+qt_feature("library" PUBLIC
+ SECTION "File I/O"
+ LABEL "QLibrary"
+ PURPOSE "Provides a wrapper for dynamically loaded libraries."
+ CONDITION WIN32 OR HPUX OR ( NOT NACL AND QT_FEATURE_dlopen )
+)
+qt_feature_definition("library" "QT_NO_LIBRARY" NEGATE VALUE "1")
+qt_feature("settings" PUBLIC
+ SECTION "File I/O"
+ LABEL "QSettings"
+ PURPOSE "Provides persistent application settings."
+)
+qt_feature_definition("settings" "QT_NO_SETTINGS" NEGATE VALUE "1")
+qt_feature("filesystemwatcher" PUBLIC
+ SECTION "File I/O"
+ LABEL "QFileSystemWatcher"
+ PURPOSE "Provides an interface for monitoring files and directories for modifications."
+ CONDITION NOT WINRT
+)
+qt_feature_definition("filesystemwatcher" "QT_NO_FILESYSTEMWATCHER" NEGATE VALUE "1")
+qt_feature("filesystemiterator" PUBLIC
+ SECTION "File I/O"
+ LABEL "QFileSystemIterator"
+ PURPOSE "Provides fast file system iteration."
+)
+qt_feature_definition("filesystemiterator" "QT_NO_FILESYSTEMITERATOR" NEGATE VALUE "1")
+qt_feature("itemmodel" PUBLIC
+ SECTION "ItemViews"
+ LABEL "Qt Item Model"
+ PURPOSE "Provides the item model for item views"
+)
+qt_feature_definition("itemmodel" "QT_NO_ITEMMODEL" NEGATE VALUE "1")
+qt_feature("proxymodel" PUBLIC
+ SECTION "ItemViews"
+ LABEL "QAbstractProxyModel"
+ PURPOSE "Supports processing of data passed between another model and a view."
+ CONDITION QT_FEATURE_itemmodel
+)
+qt_feature_definition("proxymodel" "QT_NO_PROXYMODEL" NEGATE VALUE "1")
+qt_feature("sortfilterproxymodel" PUBLIC
+ SECTION "ItemViews"
+ LABEL "QSortFilterProxyModel"
+ PURPOSE "Supports sorting and filtering of data passed between another model and a view."
+ CONDITION QT_FEATURE_proxymodel
+)
+qt_feature_definition("sortfilterproxymodel" "QT_NO_SORTFILTERPROXYMODEL" NEGATE VALUE "1")
+qt_feature("identityproxymodel" PUBLIC
+ SECTION "ItemViews"
+ LABEL "QIdentityProxyModel"
+ PURPOSE "Supports proxying a source model unmodified."
+ CONDITION QT_FEATURE_proxymodel
+)
+qt_feature_definition("identityproxymodel" "QT_NO_IDENTITYPROXYMODEL" NEGATE VALUE "1")
+qt_feature("transposeproxymodel" PUBLIC
+ SECTION "ItemViews"
+ LABEL "QTransposeProxyModel"
+ PURPOSE "Provides a proxy to swap rows and columns of a model."
+ CONDITION QT_FEATURE_proxymodel
+)
+qt_feature_definition("transposeproxymodel" "QT_NO_TRANSPOSEPROXYMODEL" NEGATE VALUE "1")
+qt_feature("concatenatetablesproxymodel" PUBLIC
+ SECTION "ItemViews"
+ LABEL "QConcatenateTablesProxyModel"
+ PURPOSE "Supports concatenating source models."
+ CONDITION QT_FEATURE_proxymodel
+)
+qt_feature_definition("concatenatetablesproxymodel" "QT_NO_CONCATENATETABLESPROXYMODEL" NEGATE VALUE "1")
+qt_feature("stringlistmodel" PUBLIC
+ SECTION "ItemViews"
+ LABEL "QStringListModel"
+ PURPOSE "Provides a model that supplies strings to views."
+ CONDITION QT_FEATURE_itemmodel
+)
+qt_feature_definition("stringlistmodel" "QT_NO_STRINGLISTMODEL" NEGATE VALUE "1")
+qt_feature("translation" PUBLIC
+ SECTION "Internationalization"
+ LABEL "Translation"
+ PURPOSE "Supports translations using QObject::tr()."
+)
+qt_feature_definition("translation" "QT_NO_TRANSLATION" NEGATE VALUE "1")
+qt_feature("textcodec" PUBLIC
+ SECTION "Internationalization"
+ LABEL "QTextCodec"
+ PURPOSE "Supports conversions between text encodings."
+)
+qt_feature_definition("textcodec" "QT_NO_TEXTCODEC" NEGATE VALUE "1")
+qt_feature("codecs" PUBLIC
+ SECTION "Internationalization"
+ LABEL "Codecs"
+ PURPOSE "Supports non-unicode text conversions."
+ CONDITION QT_FEATURE_textcodec
+)
+qt_feature_definition("codecs" "QT_NO_CODECS" NEGATE VALUE "1")
+qt_feature("big_codecs" PUBLIC
+ SECTION "Internationalization"
+ LABEL "Big Codecs"
+ PURPOSE "Supports big codecs, e.g. CJK."
+ CONDITION QT_FEATURE_textcodec
+)
+qt_feature_definition("big_codecs" "QT_NO_BIG_CODECS" NEGATE VALUE "1")
+qt_feature("easingcurve" PUBLIC
+ SECTION "Utilities"
+ LABEL "Easing curve"
+ PURPOSE "Provides easing curve."
+)
+qt_feature("animation" PUBLIC
+ SECTION "Utilities"
+ LABEL "Animation"
+ PURPOSE "Provides a framework for animations."
+ CONDITION QT_FEATURE_properties AND QT_FEATURE_easingcurve
+)
+qt_feature_definition("animation" "QT_NO_ANIMATION" NEGATE VALUE "1")
+qt_feature("statemachine" PUBLIC
+ SECTION "Utilities"
+ LABEL "State machine"
+ PURPOSE "Provides hierarchical finite state machines."
+ CONDITION QT_FEATURE_properties
+)
+qt_feature_definition("statemachine" "QT_NO_STATEMACHINE" NEGATE VALUE "1")
+qt_feature("qeventtransition" PUBLIC
+ LABEL "QEventTransition class"
+ CONDITION QT_FEATURE_statemachine
+)
+qt_feature("gestures" PUBLIC
+ SECTION "Utilities"
+ LABEL "Gesture"
+ PURPOSE "Provides a framework for gestures."
+)
+qt_feature_definition("gestures" "QT_NO_GESTURES" NEGATE VALUE "1")
+qt_feature("sha3-fast" PRIVATE
+ SECTION "Utilities"
+ LABEL "Speed optimized SHA3"
+ PURPOSE "Optimizes SHA3 for speed instead of size."
+)
+qt_feature("jalalicalendar" PUBLIC
+ SECTION "Utilities"
+ LABEL "QJalaliCalendar"
+ PURPOSE "Support the Jalali (Persian) calendar"
+)
+qt_feature("hijricalendar" PRIVATE
+ SECTION "Utilities"
+ LABEL "QHijriCalendar"
+ PURPOSE "Generic basis for Islamic calendars, providing shared locale data"
+)
+qt_feature("islamiccivilcalendar" PUBLIC
+ SECTION "Utilities"
+ LABEL "QIslamicCivilCalendar"
+ PURPOSE "Support the Islamic Civil calendar"
+ CONDITION QT_FEATURE_hijricalendar
+)
+qt_feature("timezone" PUBLIC
+ SECTION "Utilities"
+ LABEL "QTimeZone"
+ PURPOSE "Provides support for time-zone handling."
+)
+qt_feature("datetimeparser" PRIVATE
+ SECTION "Utilities"
+ LABEL "QDateTimeParser"
+ PURPOSE "Provides support for parsing date-time texts."
+)
+qt_feature("commandlineparser" PUBLIC
+ SECTION "Utilities"
+ LABEL "QCommandlineParser"
+ PURPOSE "Provides support for command line parsing."
+)
+qt_feature("lttng" PRIVATE
+ LABEL "LTTNG"
+ AUTODETECT OFF
+ CONDITION LINUX AND LTTNGUST_FOUND
+ ENABLE INPUT_trace STREQUAL 'lttng' OR ( INPUT_trace STREQUAL 'yes' AND LINUX )
+ DISABLE INPUT_trace STREQUAL 'etw' OR INPUT_trace STREQUAL 'no'
+)
+qt_feature("etw" PRIVATE
+ LABEL "ETW"
+ AUTODETECT OFF
+ CONDITION WIN32
+ ENABLE INPUT_trace STREQUAL 'etw' OR ( INPUT_trace STREQUAL 'yes' AND WIN32 )
+ DISABLE INPUT_trace STREQUAL 'lttng' OR INPUT_trace STREQUAL 'no'
+)
+qt_feature("topleveldomain" PUBLIC
+ SECTION "Utilities"
+ LABEL "QUrl::topLevelDomain()"
+ PURPOSE "Provides support for extracting the top level domain from URLs. If enabled, a binary dump of the Public Suffix List (http://www.publicsuffix.org, Mozilla License) is included. The data is then also used in QNetworkCookieJar::validateCookie."
+)
+qt_feature("win32_system_libs"
+ LABEL "Windows System Libraries"
+ CONDITION WIN32 AND libs.advapi32 AND libs.gdi32 AND libs.kernel32 AND libs.netapi32 AND libs.ole32 AND libs.shell32 AND libs.uuid AND libs.user32 AND libs.winmm AND libs.ws2_32 OR FIXME
+)
+qt_feature("cborstream" PUBLIC
+ SECTION "Utilities"
+ LABEL "CBOR stream I/O"
+ PURPOSE "Provides support for reading and writing the CBOR binary format. Note that this is required for plugin loading. Qt GUI needs QPA plugins for basic operation."
+)
+qt_feature("binaryjson" PUBLIC
+ SECTION "Utilities"
+ LABEL "Binary JSON (deprecated)"
+ PURPOSE "Provides support for the deprecated binary JSON format."
+)
diff --git a/src/corelib/configure.json b/src/corelib/configure.json
index c8e650ca9f..b607c300dd 100644
--- a/src/corelib/configure.json
+++ b/src/corelib/configure.json
@@ -770,11 +770,6 @@
"condition": "libs.pps",
"output": [ "privateFeature" ]
},
- "qeventtransition": {
- "label": "QEventTransition class",
- "condition": "features.statemachine",
- "output": [ "publicFeature" ]
- },
"renameat2": {
"label": "renameat2()",
"condition": "config.linux && tests.renameat2",
@@ -1015,6 +1010,11 @@
"condition": "features.properties",
"output": [ "publicFeature", "feature" ]
},
+ "qeventtransition": {
+ "label": "QEventTransition class",
+ "condition": "features.statemachine",
+ "output": [ "publicFeature" ]
+ },
"gestures": {
"label": "Gesture",
"purpose": "Provides a framework for gestures.",
@@ -1082,10 +1082,7 @@
},
"topleveldomain": {
"label": "QUrl::topLevelDomain()",
- "purpose": "Provides support for extracting the top level domain from URLs.
-
-If enabled, a binary dump of the Public Suffix List (http://www.publicsuffix.org,
-Mozilla License) is included. The data is then also used in QNetworkCookieJar::validateCookie.",
+ "purpose": "Provides support for extracting the top level domain from URLs. If enabled, a binary dump of the Public Suffix List (http://www.publicsuffix.org, Mozilla License) is included. The data is then also used in QNetworkCookieJar::validateCookie.",
"section": "Utilities",
"output": [ "publicFeature" ]
},
@@ -1119,10 +1116,7 @@ Note that this is required for plugin loading. Qt GUI needs QPA plugins for basi
{
"type": "note",
"condition": "features.journald || features.syslog || (config.qnx && features.slog2)",
- "message": "journald, syslog or slog2 integration is enabled.
-If your users intend to develop applications against this build,
-ensure that the IDEs they use either set QT_FORCE_STDERR_LOGGING to 1
-or are able to read the logged output from journald, syslog or slog2."
+ "message": "journald, syslog or slog2 integration is enabled. If your users intend to develop applications against this build, ensure that the IDEs they use either set QT_FORCE_STDERR_LOGGING to 1 or are able to read the logged output from journald, syslog or slog2."
},
{
"type": "error",
@@ -1132,15 +1126,12 @@ or are able to read the logged output from journald, syslog or slog2."
{
"type": "error",
"condition": "input.doubleconversion == 'no' && !tests.xlocalescanprint",
- "message": "Your C library does not provide sscanf_l or snprintf_l.
-You need to use libdouble-conversion for double/string conversion."
+ "message": "Your C library does not provide sscanf_l or snprintf_l. You need to use libdouble-conversion for double/string conversion."
},
{
"type": "error",
"condition": "!tests.atomicfptr",
- "message": "detected a std::atomic implementation that fails for function pointers.
-Please apply the patch corresponding to your Standard Library vendor, found in
- qtbase/config.tests/atomicfptr"
+ "message": "detected a std::atomic implementation that fails for function pointers. Please apply the patch corresponding to your Standard Library vendor, found in qtbase/config.tests/atomicfptr"
},
{
"type": "error",
diff --git a/src/corelib/global/qconfig.cpp.in b/src/corelib/global/qconfig.cpp.in
new file mode 100644
index 0000000000..7fa21bcfed
--- /dev/null
+++ b/src/corelib/global/qconfig.cpp.in
@@ -0,0 +1,32 @@
+/* Installation date */
+static const char qt_configure_installation [12+11] = "qt_instdate=2012-12-20";
+/* Installation Info */
+static const char qt_configure_prefix_path_str [12+256] = "qt_prfxpath=@CMAKE_INSTALL_PREFIX@";
+#ifdef QT_BUILD_QMAKE
+static const char qt_configure_ext_prefix_path_str [12+256] = "qt_epfxpath=@CMAKE_INSTALL_PREFIX@";
+static const char qt_configure_host_prefix_path_str [12+256] = "qt_hpfxpath=@CMAKE_INSTALL_PREFIX@";
+#endif
+static const short qt_configure_str_offsets[] = {
+@QT_CONFIG_STR_OFFSETS_FIRST@
+#ifdef QT_BUILD_QMAKE
+@QT_CONFIG_STR_OFFSETS_SECOND@
+#endif
+};
+static const char qt_configure_strs[] =
+@QT_CONFIG_STRS_FIRST@
+#ifdef QT_BUILD_QMAKE
+@QT_CONFIG_STRS_SECOND@
+#endif
+;
+#define QT_CONFIGURE_SETTINGS_PATH "@QT_DEFAULT_SYS_CONF_DIR@"
+#define QT_CONFIGURE_LIBLOCATION_TO_PREFIX_PATH "@QT_CONFIGURE_LIBLOCATION_TO_PREFIX_PATH@"
+#define QT_CONFIGURE_HOSTBINDIR_TO_EXTPREFIX_PATH "@QT_CONFIGURE_HOSTBINDIR_TO_EXTPREFIX_PATH@"
+#define QT_CONFIGURE_HOSTBINDIR_TO_HOSTPREFIX_PATH "@QT_CONFIGURE_HOSTBINDIR_TO_HOSTPREFIX_PATH@"
+#ifdef QT_BUILD_QMAKE
+# define QT_CONFIGURE_SYSROOTIFY_PREFIX false
+#endif
+#define QT_CONFIGURE_PREFIX_PATH qt_configure_prefix_path_str + 12
+#ifdef QT_BUILD_QMAKE
+# define QT_CONFIGURE_EXT_PREFIX_PATH qt_configure_ext_prefix_path_str + 12
+# define QT_CONFIGURE_HOST_PREFIX_PATH qt_configure_host_prefix_path_str + 12
+#endif
diff --git a/src/corelib/global/qlibraryinfo.cpp b/src/corelib/global/qlibraryinfo.cpp
index 9fab49a73e..f8accab548 100644
--- a/src/corelib/global/qlibraryinfo.cpp
+++ b/src/corelib/global/qlibraryinfo.cpp
@@ -653,6 +653,8 @@ static const char *getPrefix(
# if QT_CONFIGURE_CROSSBUILD
if (group == QLibraryInfo::DevicePaths)
return QT_CONFIGURE_PREFIX_PATH;
+# else
+ Q_UNUSED(group);
# endif
static QByteArray extPrefixPath = getExtPrefixFromHostBinDir().toLatin1();
return extPrefixPath.constData();
diff --git a/src/corelib/io/qfilesystemiterator_unix.cpp b/src/corelib/io/qfilesystemiterator_unix.cpp
index ad6dbaba11..ceea3a467c 100644
--- a/src/corelib/io/qfilesystemiterator_unix.cpp
+++ b/src/corelib/io/qfilesystemiterator_unix.cpp
@@ -85,6 +85,8 @@ static bool checkNameDecodable(const char *d_name, qsizetype len)
codec->toUnicode(d_name, len, &cs);
return cs.invalidChars == 0 && cs.remainingChars == 0;
#else
+ Q_UNUSED(d_name);
+ Q_UNUSED(len);
// if we have no text codecs, then QString::fromLocal8Bit is fromLatin1
Q_UNUSED(d_name)
Q_UNUSED(len)
diff --git a/src/corelib/kernel/qvariant.cpp b/src/corelib/kernel/qvariant.cpp
index 888da17a98..d1bd2d308f 100644
--- a/src/corelib/kernel/qvariant.cpp
+++ b/src/corelib/kernel/qvariant.cpp
@@ -4126,8 +4126,8 @@ QDebug operator<<(QDebug dbg, const QVariant::Type p)
If the QVariant contains a pointer to a type derived from QObject then
\c{T} may be any QObject type. If the pointer stored in the QVariant can be
qobject_cast to T, then that result is returned. Otherwise \nullptr is
- returned. Note that this only works for QObject subclasses which use the
- Q_OBJECT macro.
+ returned. Note that this only works for QObject subclasses which use
+ the Q_OBJECT macro.
If the QVariant contains a sequential container and \c{T} is QVariantList, the
elements of the container will be converted into \l {QVariant}s and returned as a QVariantList.
diff --git a/src/corelib/mimetypes/mimetypes_resources.cmake b/src/corelib/mimetypes/mimetypes_resources.cmake
new file mode 100644
index 0000000000..a91d25cc2c
--- /dev/null
+++ b/src/corelib/mimetypes/mimetypes_resources.cmake
@@ -0,0 +1,21 @@
+# List of files that need to be packaged as resources.
+# This file exists solely because of unit tests that need access to this
+# information as well. This was previosly handled by referrencing a qrc
+# file with the same information
+
+set(corelib_mimetypes_resource_file
+ "${CMAKE_CURRENT_LIST_DIR}/mime/packages/freedesktop.org.xml"
+)
+
+function(corelib_add_mimetypes_resources target)
+ set(source_file "${corelib_mimetypes_resource_file}")
+ set_source_files_properties("${source_file}"
+ PROPERTIES QT_RESOURCE_ALIAS "freedesktop.org.xml"
+ )
+ qt_add_resource(${target} "mimetypes"
+ PREFIX
+ "/qt-project.org/qmime/packages"
+ FILES
+ "${source_file}"
+ )
+endfunction()
diff --git a/src/dbus/.prev_CMakeLists.txt b/src/dbus/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..45e1e11a25
--- /dev/null
+++ b/src/dbus/.prev_CMakeLists.txt
@@ -0,0 +1,74 @@
+# Generated from dbus.pro.
+
+#####################################################################
+## DBus Module:
+#####################################################################
+
+qt_add_module(DBus
+ QMAKE_MODULE_CONFIG dbusadaptors dbusinterfaces
+ SOURCES
+ dbus_minimal_p.h
+ qdbus_symbols.cpp qdbus_symbols_p.h
+ qdbusabstractadaptor.cpp qdbusabstractadaptor.h qdbusabstractadaptor_p.h
+ qdbusabstractinterface.cpp qdbusabstractinterface.h qdbusabstractinterface_p.h
+ qdbusargument.cpp qdbusargument.h qdbusargument_p.h
+ qdbusconnection.cpp qdbusconnection.h qdbusconnection_p.h
+ qdbusconnectioninterface.cpp qdbusconnectioninterface.h
+ qdbusconnectionmanager_p.h
+ qdbuscontext.cpp qdbuscontext.h qdbuscontext_p.h
+ qdbuserror.cpp qdbuserror.h
+ qdbusextratypes.cpp qdbusextratypes.h
+ qdbusintegrator.cpp qdbusintegrator_p.h
+ qdbusinterface.cpp qdbusinterface.h qdbusinterface_p.h
+ qdbusinternalfilters.cpp
+ qdbusintrospection.cpp qdbusintrospection_p.h
+ qdbusmarshaller.cpp
+ qdbusmessage.cpp qdbusmessage.h qdbusmessage_p.h
+ qdbusmetaobject.cpp
+ qdbusmetatype.cpp qdbusmetatype.h
+ qdbusmisc.cpp
+ qdbuspendingcall.cpp qdbuspendingcall.h qdbuspendingcall_p.h
+ qdbuspendingreply.cpp qdbuspendingreply.h
+ qdbusreply.cpp qdbusreply.h
+ qdbusserver.cpp qdbusserver.h
+ qdbusservicewatcher.cpp qdbusservicewatcher.h
+ qdbusthreaddebug_p.h
+ qdbusunixfiledescriptor.cpp qdbusunixfiledescriptor.h
+ qdbusutil.cpp qdbusutil_p.h
+ qdbusvirtualobject.cpp qdbusvirtualobject.h
+ qdbusxmlgenerator.cpp
+ qdbusxmlparser.cpp qdbusxmlparser_p.h
+ qtdbusglobal.h qtdbusglobal_p.h
+ DEFINES
+ DBUS_API_SUBJECT_TO_CHANGE
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:dbus.pro:<TRUE>:
+# MODULE_CONFIG = "dbusadaptors" "dbusinterfaces"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(DBus CONDITION QT_FEATURE_dbus_linked
+ DEFINES
+ QT_LINKED_LIBDBUS
+ LIBRARIES
+ dbus-1
+)
+
+qt_extend_target(DBus CONDITION WIN32
+ LIBRARIES
+ advapi32
+ netapi32
+ user32
+ ws2_32
+)
+qt_add_docs(DBus
+ doc/qtdbus.qdocconf
+)
+
diff --git a/src/dbus/CMakeLists.txt b/src/dbus/CMakeLists.txt
new file mode 100644
index 0000000000..d6b6d95798
--- /dev/null
+++ b/src/dbus/CMakeLists.txt
@@ -0,0 +1,77 @@
+# Generated from dbus.pro.
+
+#####################################################################
+## DBus Module:
+#####################################################################
+
+qt_add_module(DBus
+ QMAKE_MODULE_CONFIG dbusadaptors dbusinterfaces
+ SOURCES
+ dbus_minimal_p.h
+ qdbus_symbols.cpp qdbus_symbols_p.h
+ qdbusabstractadaptor.cpp qdbusabstractadaptor.h qdbusabstractadaptor_p.h
+ qdbusabstractinterface.cpp qdbusabstractinterface.h qdbusabstractinterface_p.h
+ qdbusargument.cpp qdbusargument.h qdbusargument_p.h
+ qdbusconnection.cpp qdbusconnection.h qdbusconnection_p.h
+ qdbusconnectioninterface.cpp qdbusconnectioninterface.h
+ qdbusconnectionmanager_p.h
+ qdbuscontext.cpp qdbuscontext.h qdbuscontext_p.h
+ qdbuserror.cpp qdbuserror.h
+ qdbusextratypes.cpp qdbusextratypes.h
+ qdbusintegrator.cpp qdbusintegrator_p.h
+ qdbusinterface.cpp qdbusinterface.h qdbusinterface_p.h
+ qdbusinternalfilters.cpp
+ qdbusintrospection.cpp qdbusintrospection_p.h
+ qdbusmarshaller.cpp
+ qdbusmessage.cpp qdbusmessage.h qdbusmessage_p.h
+ qdbusmetaobject.cpp
+ qdbusmetatype.cpp qdbusmetatype.h
+ qdbusmisc.cpp
+ qdbuspendingcall.cpp qdbuspendingcall.h qdbuspendingcall_p.h
+ qdbuspendingreply.cpp qdbuspendingreply.h
+ qdbusreply.cpp qdbusreply.h
+ qdbusserver.cpp qdbusserver.h
+ qdbusservicewatcher.cpp qdbusservicewatcher.h
+ qdbusthreaddebug_p.h
+ qdbusunixfiledescriptor.cpp qdbusunixfiledescriptor.h
+ qdbusutil.cpp qdbusutil_p.h
+ qdbusvirtualobject.cpp qdbusvirtualobject.h
+ qdbusxmlgenerator.cpp
+ qdbusxmlparser.cpp qdbusxmlparser_p.h
+ qtdbusglobal.h qtdbusglobal_p.h
+ DEFINES
+ DBUS_API_SUBJECT_TO_CHANGE
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+set_source_files_properties(qdbusmarshaller.cpp
+ PROPERTIES HEADER_FILE_ONLY ON) # special case: This file is included by qdbusargument.cpp
+
+#### Keys ignored in scope 1:.:.:dbus.pro:<TRUE>:
+# MODULE_CONFIG = "dbusadaptors" "dbusinterfaces"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(DBus CONDITION QT_FEATURE_dbus_linked
+ DEFINES
+ QT_LINKED_LIBDBUS
+ LIBRARIES
+ dbus-1
+)
+
+qt_extend_target(DBus CONDITION WIN32
+ LIBRARIES
+ advapi32
+ netapi32
+ user32
+ ws2_32
+)
+qt_add_docs(DBus
+ doc/qtdbus.qdocconf
+)
+
diff --git a/src/dbus/Qt5DBusConfigExtras.cmake.in b/src/dbus/Qt5DBusConfigExtras.cmake.in
deleted file mode 100644
index 1d947159e2..0000000000
--- a/src/dbus/Qt5DBusConfigExtras.cmake.in
+++ /dev/null
@@ -1,33 +0,0 @@
-
-if (NOT TARGET Qt5::qdbuscpp2xml)
- add_executable(Qt5::qdbuscpp2xml IMPORTED)
-
-!!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5DBus_install_prefix}/$${CMAKE_BIN_DIR}qdbuscpp2xml$$CMAKE_BIN_SUFFIX\")
-!!ELSE
- set(imported_location \"$${CMAKE_BIN_DIR}qdbuscpp2xml$$CMAKE_BIN_SUFFIX\")
-!!ENDIF
- _qt5_DBus_check_file_exists(${imported_location})
-
- set_target_properties(Qt5::qdbuscpp2xml PROPERTIES
- IMPORTED_LOCATION ${imported_location}
- )
-endif()
-
-if (NOT TARGET Qt5::qdbusxml2cpp)
- add_executable(Qt5::qdbusxml2cpp IMPORTED)
-
-!!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5DBus_install_prefix}/$${CMAKE_BIN_DIR}qdbusxml2cpp$$CMAKE_BIN_SUFFIX\")
-!!ELSE
- set(imported_location \"$${CMAKE_BIN_DIR}qdbusxml2cpp$$CMAKE_BIN_SUFFIX\")
-!!ENDIF
- _qt5_DBus_check_file_exists(${imported_location})
-
- set_target_properties(Qt5::qdbusxml2cpp PROPERTIES
- IMPORTED_LOCATION ${imported_location}
- )
-endif()
-
-set(Qt5DBus_QDBUSCPP2XML_EXECUTABLE Qt5::qdbuscpp2xml)
-set(Qt5DBus_QDBUSXML2CPP_EXECUTABLE Qt5::qdbusxml2cpp)
diff --git a/src/dbus/Qt5DBusMacros.cmake b/src/dbus/Qt6DBusMacros.cmake
index 9b69e77dc7..edbadab3d1 100644
--- a/src/dbus/Qt5DBusMacros.cmake
+++ b/src/dbus/Qt6DBusMacros.cmake
@@ -34,7 +34,7 @@ include(MacroAddFileDependencies)
include(CMakeParseArguments)
-function(qt5_add_dbus_interface _sources _interface _basename)
+function(qt6_add_dbus_interface _sources _interface _basename)
get_filename_component(_infile ${_interface} ABSOLUTE)
set(_header "${CMAKE_CURRENT_BINARY_DIR}/${_basename}.h")
set(_impl "${CMAKE_CURRENT_BINARY_DIR}/${_basename}.cpp")
@@ -58,12 +58,12 @@ function(qt5_add_dbus_interface _sources _interface _basename)
endif()
add_custom_command(OUTPUT "${_impl}" "${_header}"
- COMMAND ${Qt5DBus_QDBUSXML2CPP_EXECUTABLE} ${_params} -p ${_basename} ${_infile}
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::qdbusxml2cpp ${_params} -p ${_basename} ${_infile}
DEPENDS ${_infile} VERBATIM)
set_source_files_properties("${_impl}" "${_header}" PROPERTIES SKIP_AUTOMOC TRUE)
- qt5_generate_moc("${_header}" "${_moc}")
+ qt6_generate_moc("${_header}" "${_moc}")
list(APPEND ${_sources} "${_impl}" "${_header}" "${_moc}")
macro_add_file_dependencies("${_impl}" "${_moc}")
@@ -71,20 +71,20 @@ function(qt5_add_dbus_interface _sources _interface _basename)
endfunction()
-function(qt5_add_dbus_interfaces _sources)
+function(qt6_add_dbus_interfaces _sources)
foreach(_current_FILE ${ARGN})
get_filename_component(_infile ${_current_FILE} ABSOLUTE)
get_filename_component(_basename ${_current_FILE} NAME)
# get the part before the ".xml" suffix
string(TOLOWER ${_basename} _basename)
string(REGEX REPLACE "(.*\\.)?([^\\.]+)\\.xml" "\\2" _basename ${_basename})
- qt5_add_dbus_interface(${_sources} ${_infile} ${_basename}interface)
+ qt6_add_dbus_interface(${_sources} ${_infile} ${_basename}interface)
endforeach()
set(${_sources} ${${_sources}} PARENT_SCOPE)
endfunction()
-function(qt5_generate_dbus_interface _header) # _customName OPTIONS -some -options )
+function(qt6_generate_dbus_interface _header) # _customName OPTIONS -some -options )
set(options)
set(oneValueArgs)
set(multiValueArgs OPTIONS)
@@ -111,13 +111,13 @@ function(qt5_generate_dbus_interface _header) # _customName OPTIONS -some -optio
endif()
add_custom_command(OUTPUT ${_target}
- COMMAND ${Qt5DBus_QDBUSCPP2XML_EXECUTABLE} ${_DBUS_INTERFACE_OPTIONS} ${_in_file} -o ${_target}
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::qdbuscpp2xml ${_DBUS_INTERFACE_OPTIONS} ${_in_file} -o ${_target}
DEPENDS ${_in_file} VERBATIM
)
endfunction()
-function(qt5_add_dbus_adaptor _sources _xml_file _include _parentClass) # _optionalBasename _optionalClassName)
+function(qt6_add_dbus_adaptor _sources _xml_file _include _parentClass) # _optionalBasename _optionalClassName)
get_filename_component(_infile ${_xml_file} ABSOLUTE)
set(_optionalBasename "${ARGV4}")
@@ -135,17 +135,17 @@ function(qt5_add_dbus_adaptor _sources _xml_file _include _parentClass) # _optio
if(_optionalClassName)
add_custom_command(OUTPUT "${_impl}" "${_header}"
- COMMAND ${Qt5DBus_QDBUSXML2CPP_EXECUTABLE} -m -a ${_basename} -c ${_optionalClassName} -i ${_include} -l ${_parentClass} ${_infile}
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::qdbusxml2cpp -m -a ${_basename} -c ${_optionalClassName} -i ${_include} -l ${_parentClass} ${_infile}
DEPENDS ${_infile} VERBATIM
)
else()
add_custom_command(OUTPUT "${_impl}" "${_header}"
- COMMAND ${Qt5DBus_QDBUSXML2CPP_EXECUTABLE} -m -a ${_basename} -i ${_include} -l ${_parentClass} ${_infile}
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::qdbusxml2cpp -m -a ${_basename} -i ${_include} -l ${_parentClass} ${_infile}
DEPENDS ${_infile} VERBATIM
)
endif()
- qt5_generate_moc("${_header}" "${_moc}")
+ qt6_generate_moc("${_header}" "${_moc}")
set_source_files_properties("${_impl}" "${_header}" PROPERTIES SKIP_AUTOMOC TRUE)
macro_add_file_dependencies("${_impl}" "${_moc}")
diff --git a/src/gui/.prev_CMakeLists.txt b/src/gui/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..90b66fd882
--- /dev/null
+++ b/src/gui/.prev_CMakeLists.txt
@@ -0,0 +1,658 @@
+# Generated from gui.pro.
+
+#####################################################################
+## Gui Module:
+#####################################################################
+
+qt_add_module(Gui
+ GENERATE_METATYPES
+ PLUGIN_TYPES platforms platforms/darwin xcbglintegrations platformthemes platforminputcontexts generic iconengines imageformats egldeviceintegrations
+ SOURCES
+ image/qbitmap.cpp image/qbitmap.h
+ image/qbmphandler.cpp image/qbmphandler_p.h
+ image/qicon.cpp image/qicon.h image/qicon_p.h
+ image/qiconengine.cpp image/qiconengine.h
+ image/qiconengineplugin.cpp image/qiconengineplugin.h
+ image/qiconloader.cpp image/qiconloader_p.h
+ image/qimage.cpp image/qimage.h image/qimage_p.h
+ image/qimage_conversions.cpp
+ image/qimageiohandler.cpp image/qimageiohandler.h
+ image/qimagepixmapcleanuphooks.cpp image/qimagepixmapcleanuphooks_p.h
+ image/qimagereader.cpp image/qimagereader.h
+ image/qimagereaderwriterhelpers.cpp image/qimagereaderwriterhelpers_p.h
+ image/qimagewriter.cpp image/qimagewriter.h
+ image/qpaintengine_pic.cpp image/qpaintengine_pic_p.h
+ image/qpicture.cpp image/qpicture.h image/qpicture_p.h
+ image/qpixmap.cpp image/qpixmap.h
+ image/qpixmap_blitter.cpp image/qpixmap_blitter_p.h
+ image/qpixmap_raster.cpp image/qpixmap_raster_p.h
+ image/qpixmapcache.cpp image/qpixmapcache.h image/qpixmapcache_p.h
+ image/qplatformpixmap.cpp image/qplatformpixmap.h
+ image/qppmhandler.cpp image/qppmhandler_p.h
+ image/qxbmhandler.cpp image/qxbmhandler_p.h
+ image/qxpmhandler.cpp image/qxpmhandler_p.h
+ itemmodels/qstandarditemmodel.cpp itemmodels/qstandarditemmodel.h itemmodels/qstandarditemmodel_p.h
+ kernel/qclipboard.cpp kernel/qclipboard.h
+ kernel/qcursor.cpp kernel/qcursor.h kernel/qcursor_p.h
+ kernel/qevent.cpp kernel/qevent.h kernel/qevent_p.h
+ kernel/qgenericplugin.cpp kernel/qgenericplugin.h
+ kernel/qgenericpluginfactory.cpp kernel/qgenericpluginfactory.h
+ kernel/qguiapplication.cpp kernel/qguiapplication.h kernel/qguiapplication_p.h
+ kernel/qguivariant.cpp
+ kernel/qhighdpiscaling.cpp kernel/qhighdpiscaling_p.h
+ kernel/qinputdevicemanager.cpp kernel/qinputdevicemanager_p.h
+ kernel/qinputdevicemanager_p_p.h
+ kernel/qinputmethod.cpp kernel/qinputmethod.h kernel/qinputmethod_p.h
+ kernel/qinternalmimedata.cpp kernel/qinternalmimedata_p.h
+ kernel/qkeymapper.cpp kernel/qkeymapper_p.h
+ kernel/qoffscreensurface.cpp kernel/qoffscreensurface.h
+ kernel/qpaintdevicewindow.cpp kernel/qpaintdevicewindow.h kernel/qpaintdevicewindow_p.h
+ kernel/qpalette.cpp kernel/qpalette.h
+ kernel/qpixelformat.cpp kernel/qpixelformat.h
+ kernel/qplatformclipboard.cpp kernel/qplatformclipboard.h
+ kernel/qplatformcursor.cpp kernel/qplatformcursor.h
+ kernel/qplatformdialoghelper.cpp kernel/qplatformdialoghelper.h
+ kernel/qplatformgraphicsbuffer.cpp kernel/qplatformgraphicsbuffer.h
+ kernel/qplatformgraphicsbufferhelper.cpp kernel/qplatformgraphicsbufferhelper.h
+ kernel/qplatforminputcontext.cpp kernel/qplatforminputcontext.h kernel/qplatforminputcontext_p.h
+ kernel/qplatforminputcontextfactory.cpp kernel/qplatforminputcontextfactory_p.h
+ kernel/qplatforminputcontextplugin.cpp kernel/qplatforminputcontextplugin_p.h
+ kernel/qplatformintegration.cpp kernel/qplatformintegration.h
+ kernel/qplatformintegrationfactory.cpp kernel/qplatformintegrationfactory_p.h
+ kernel/qplatformintegrationplugin.cpp kernel/qplatformintegrationplugin.h
+ kernel/qplatformmenu.cpp kernel/qplatformmenu.h
+ kernel/qplatformnativeinterface.cpp kernel/qplatformnativeinterface.h
+ kernel/qplatformoffscreensurface.cpp kernel/qplatformoffscreensurface.h
+ kernel/qplatformscreen.cpp kernel/qplatformscreen.h kernel/qplatformscreen_p.h
+ kernel/qplatformservices.cpp kernel/qplatformservices.h
+ kernel/qplatformsessionmanager.cpp kernel/qplatformsessionmanager.h
+ kernel/qplatformsharedgraphicscache.cpp kernel/qplatformsharedgraphicscache.h
+ kernel/qplatformsurface.cpp kernel/qplatformsurface.h
+ kernel/qplatformsystemtrayicon.cpp kernel/qplatformsystemtrayicon.h
+ kernel/qplatformtheme.cpp kernel/qplatformtheme.h kernel/qplatformtheme_p.h
+ kernel/qplatformthemefactory.cpp kernel/qplatformthemefactory_p.h
+ kernel/qplatformthemeplugin.cpp kernel/qplatformthemeplugin.h
+ kernel/qplatformwindow.cpp kernel/qplatformwindow.h kernel/qplatformwindow_p.h
+ kernel/qrasterwindow.cpp kernel/qrasterwindow.h
+ kernel/qscreen.cpp kernel/qscreen.h kernel/qscreen_p.h
+ kernel/qsessionmanager.cpp kernel/qsessionmanager.h kernel/qsessionmanager_p.h
+ kernel/qstylehints.cpp kernel/qstylehints.h
+ kernel/qsurface.cpp kernel/qsurface.h
+ kernel/qsurfaceformat.cpp kernel/qsurfaceformat.h
+ kernel/qtestsupport_gui.cpp kernel/qtestsupport_gui.h
+ kernel/qtguiglobal.h kernel/qtguiglobal_p.h
+ kernel/qtouchdevice.cpp kernel/qtouchdevice.h kernel/qtouchdevice_p.h
+ kernel/qwindow.cpp kernel/qwindow.h kernel/qwindow_p.h
+ kernel/qwindowdefs.h
+ kernel/qwindowsysteminterface.cpp kernel/qwindowsysteminterface.h kernel/qwindowsysteminterface_p.h
+ math3d/qgenericmatrix.cpp math3d/qgenericmatrix.h
+ math3d/qmatrix4x4.cpp math3d/qmatrix4x4.h
+ math3d/qquaternion.cpp math3d/qquaternion.h
+ math3d/qvector2d.cpp math3d/qvector2d.h
+ math3d/qvector3d.cpp math3d/qvector3d.h
+ math3d/qvector4d.cpp math3d/qvector4d.h
+ painting/qbackingstore.cpp painting/qbackingstore.h
+ painting/qbezier.cpp painting/qbezier_p.h
+ painting/qblendfunctions.cpp painting/qblendfunctions_p.h
+ painting/qblittable.cpp painting/qblittable_p.h
+ painting/qbrush.cpp painting/qbrush.h
+ painting/qcolor.cpp painting/qcolor.h painting/qcolor_p.h
+ painting/qcolormatrix_p.h
+ painting/qcolorspace.cpp painting/qcolorspace.h painting/qcolorspace_p.h
+ painting/qcolortransferfunction_p.h
+ painting/qcolortransfertable_p.h
+ painting/qcolortransform.cpp painting/qcolortransform.h painting/qcolortransform_p.h
+ painting/qcolortrc_p.h
+ painting/qcolortrclut.cpp painting/qcolortrclut_p.h
+ painting/qcompositionfunctions.cpp
+ painting/qcosmeticstroker.cpp painting/qcosmeticstroker_p.h
+ painting/qdatabuffer_p.h
+ painting/qdrawhelper_p.h
+ painting/qdrawhelper_x86_p.h
+ painting/qdrawingprimitive_sse2_p.h
+ painting/qemulationpaintengine.cpp painting/qemulationpaintengine_p.h
+ painting/qfixed_p.h
+ painting/qgrayraster.c painting/qgrayraster_p.h
+ painting/qicc.cpp painting/qicc_p.h
+ painting/qimagescale.cpp
+ painting/qmatrix.cpp painting/qmatrix.h
+ painting/qmemrotate.cpp painting/qmemrotate_p.h
+ painting/qoutlinemapper.cpp painting/qoutlinemapper_p.h
+ painting/qpagedpaintdevice.cpp painting/qpagedpaintdevice.h painting/qpagedpaintdevice_p.h
+ painting/qpagelayout.cpp painting/qpagelayout.h
+ painting/qpagesize.cpp painting/qpagesize.h
+ painting/qpaintdevice.cpp painting/qpaintdevice.h
+ painting/qpaintengine.cpp painting/qpaintengine.h painting/qpaintengine_p.h
+ painting/qpaintengine_blitter.cpp painting/qpaintengine_blitter_p.h
+ painting/qpaintengine_raster.cpp painting/qpaintengine_raster_p.h
+ painting/qpaintengineex.cpp painting/qpaintengineex_p.h
+ painting/qpainter.cpp painting/qpainter.h painting/qpainter_p.h
+ painting/qpainterpath.cpp painting/qpainterpath.h painting/qpainterpath_p.h
+ painting/qpathclipper.cpp painting/qpathclipper_p.h
+ painting/qpathsimplifier.cpp painting/qpathsimplifier_p.h
+ painting/qpdf.cpp painting/qpdf_p.h
+ painting/qpdfwriter.cpp painting/qpdfwriter.h
+ painting/qpen.cpp painting/qpen.h
+ painting/qplatformbackingstore.cpp painting/qplatformbackingstore.h
+ painting/qpolygon.cpp painting/qpolygon.h
+ painting/qpolygonclipper_p.h
+ painting/qrasterdefs_p.h
+ painting/qrasterizer.cpp painting/qrasterizer_p.h
+ painting/qrbtree_p.h
+ painting/qregion.cpp painting/qregion.h
+ painting/qrgb.h
+ painting/qrgba64.h painting/qrgba64_p.h
+ painting/qstroker.cpp painting/qstroker_p.h
+ painting/qtextureglyphcache.cpp painting/qtextureglyphcache_p.h
+ painting/qtransform.cpp painting/qtransform.h
+ painting/qtriangulatingstroker.cpp painting/qtriangulatingstroker_p.h
+ painting/qtriangulator.cpp painting/qtriangulator_p.h
+ painting/qvectorpath_p.h
+ rhi/qrhi.cpp rhi/qrhi_p.h
+ rhi/qrhi_p_p.h
+ rhi/qrhinull.cpp rhi/qrhinull_p.h
+ rhi/qrhinull_p_p.h
+ rhi/qrhiprofiler.cpp rhi/qrhiprofiler_p.h
+ rhi/qrhiprofiler_p_p.h
+ rhi/qshader.cpp rhi/qshader_p.h
+ rhi/qshader_p_p.h
+ rhi/qshaderdescription.cpp rhi/qshaderdescription_p.h
+ rhi/qshaderdescription_p_p.h
+ text/qabstracttextdocumentlayout.cpp text/qabstracttextdocumentlayout.h text/qabstracttextdocumentlayout_p.h
+ text/qdistancefield.cpp text/qdistancefield_p.h
+ text/qfont.cpp text/qfont.h text/qfont_p.h
+ text/qfontdatabase.cpp text/qfontdatabase.h
+ text/qfontengine.cpp text/qfontengine_p.h
+ text/qfontengine_qpf2.cpp
+ text/qfontengineglyphcache.cpp text/qfontengineglyphcache_p.h
+ text/qfontinfo.h
+ text/qfontmetrics.cpp text/qfontmetrics.h
+ text/qfontsubset.cpp text/qfontsubset_p.h
+ text/qfragmentmap.cpp text/qfragmentmap_p.h
+ text/qglyphrun.cpp text/qglyphrun.h text/qglyphrun_p.h
+ text/qinputcontrol.cpp text/qinputcontrol_p.h
+ text/qplatformfontdatabase.cpp text/qplatformfontdatabase.h
+ text/qrawfont.cpp text/qrawfont.h text/qrawfont_p.h
+ text/qstatictext.cpp text/qstatictext.h text/qstatictext_p.h
+ text/qsyntaxhighlighter.cpp text/qsyntaxhighlighter.h
+ text/qtextcursor.cpp text/qtextcursor.h text/qtextcursor_p.h
+ text/qtextdocument.cpp text/qtextdocument.h text/qtextdocument_p.cpp text/qtextdocument_p.h
+ text/qtextdocumentfragment.cpp text/qtextdocumentfragment.h text/qtextdocumentfragment_p.h
+ text/qtextdocumentlayout.cpp text/qtextdocumentlayout_p.h
+ text/qtextdocumentwriter.cpp text/qtextdocumentwriter.h
+ text/qtextengine.cpp text/qtextengine_p.h
+ text/qtextformat.cpp text/qtextformat.h text/qtextformat_p.h
+ text/qtexthtmlparser.cpp text/qtexthtmlparser_p.h
+ text/qtextimagehandler.cpp text/qtextimagehandler_p.h
+ text/qtextlayout.cpp text/qtextlayout.h
+ text/qtextlist.cpp text/qtextlist.h
+ text/qtextobject.cpp text/qtextobject.h text/qtextobject_p.h
+ text/qtextoption.cpp text/qtextoption.h
+ text/qtexttable.cpp text/qtexttable.h text/qtexttable_p.h
+ util/qabstractlayoutstyleinfo.cpp util/qabstractlayoutstyleinfo_p.h
+ util/qastchandler.cpp util/qastchandler_p.h
+ util/qdesktopservices.cpp util/qdesktopservices.h
+ util/qgridlayoutengine.cpp util/qgridlayoutengine_p.h
+ util/qhexstring_p.h
+ util/qktxhandler.cpp util/qktxhandler_p.h
+ util/qlayoutpolicy.cpp util/qlayoutpolicy_p.h
+ util/qpkmhandler.cpp util/qpkmhandler_p.h
+ util/qshaderformat.cpp util/qshaderformat_p.h
+ util/qshadergraph.cpp util/qshadergraph_p.h
+ util/qshadergraphloader.cpp util/qshadergraphloader_p.h
+ util/qshaderlanguage.cpp util/qshaderlanguage_p.h
+ util/qshadernode.cpp util/qshadernode_p.h
+ util/qshadernodeport.cpp util/qshadernodeport_p.h
+ util/qshadernodesloader.cpp util/qshadernodesloader_p.h
+ util/qtexturefiledata.cpp util/qtexturefiledata_p.h
+ util/qtexturefilehandler_p.h
+ util/qtexturefilereader.cpp util/qtexturefilereader_p.h
+ util/qvalidator.cpp util/qvalidator.h
+ DEFINES
+ QT_NO_FOREACH
+ QT_NO_USING_NAMESPACE
+ INCLUDE_DIRECTORIES
+ ../3rdparty/VulkanMemoryAllocator
+ LIBRARIES
+ Qt::CorePrivate
+ ZLIB::ZLIB
+ PUBLIC_LIBRARIES
+ Qt::Core
+ PRECOMPILED_HEADER
+ "kernel/qt_gui_pch.h"
+)
+
+# Resources:
+set_source_files_properties("painting/../../3rdparty/icc/sRGB2014.icc"
+ PROPERTIES QT_RESOURCE_ALIAS "sRGB2014.icc"
+)
+set(qpdf_resource_files
+ "../../3rdparty/icc/sRGB2014.icc"
+ "qpdfa_metadata.xml"
+)
+
+qt_add_resource(Gui "qpdf"
+ PREFIX
+ "/qpdf/"
+ BASE
+ "painting"
+ FILES
+ ${qpdf_resource_files}
+)
+set(qmake_webgradients_resource_files
+ "painting/webgradients.binaryjson"
+)
+
+qt_add_resource(Gui "qmake_webgradients"
+ PREFIX
+ "qgradient"
+ BASE
+ "painting"
+ FILES
+ ${qmake_webgradients_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:gui.pro:<TRUE>:
+# QMAKE_DYNAMIC_LIST_FILE = "$$PWD/QtGui.dynlist"
+# QMAKE_LIBS = "$$QMAKE_LIBS_GUI"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(Gui CONDITION QT_FEATURE_opengl
+ SOURCES
+ kernel/qopenglcontext.cpp kernel/qopenglcontext.h kernel/qopenglcontext_p.h
+ kernel/qopenglwindow.cpp kernel/qopenglwindow.h
+ kernel/qplatformopenglcontext.cpp kernel/qplatformopenglcontext.h
+ opengl/qopengl.cpp opengl/qopengl.h opengl/qopengl_p.h
+ opengl/qopengl2pexvertexarray.cpp opengl/qopengl2pexvertexarray_p.h
+ opengl/qopenglbuffer.cpp opengl/qopenglbuffer.h
+ opengl/qopenglcustomshaderstage.cpp opengl/qopenglcustomshaderstage_p.h
+ opengl/qopengldebug.cpp opengl/qopengldebug.h
+ opengl/qopenglengineshadermanager.cpp opengl/qopenglengineshadermanager_p.h
+ opengl/qopenglengineshadersource_p.h
+ opengl/qopenglextensions_p.h
+ opengl/qopenglextrafunctions.h
+ opengl/qopenglframebufferobject.cpp opengl/qopenglframebufferobject.h opengl/qopenglframebufferobject_p.h
+ opengl/qopenglfunctions.cpp opengl/qopenglfunctions.h
+ opengl/qopenglgradientcache.cpp opengl/qopenglgradientcache_p.h
+ opengl/qopenglpaintdevice.cpp opengl/qopenglpaintdevice.h opengl/qopenglpaintdevice_p.h
+ opengl/qopenglpaintengine.cpp opengl/qopenglpaintengine_p.h
+ opengl/qopenglpixeltransferoptions.cpp opengl/qopenglpixeltransferoptions.h
+ opengl/qopenglprogrambinarycache.cpp opengl/qopenglprogrambinarycache_p.h
+ opengl/qopenglshadercache_p.h
+ opengl/qopenglshaderprogram.cpp opengl/qopenglshaderprogram.h
+ opengl/qopengltexture.cpp opengl/qopengltexture.h opengl/qopengltexture_p.h
+ opengl/qopengltextureblitter.cpp opengl/qopengltextureblitter.h
+ opengl/qopengltexturecache.cpp opengl/qopengltexturecache_p.h
+ opengl/qopengltextureglyphcache.cpp opengl/qopengltextureglyphcache_p.h
+ opengl/qopengltexturehelper.cpp opengl/qopengltexturehelper_p.h
+ opengl/qopengltextureuploader.cpp opengl/qopengltextureuploader_p.h
+ opengl/qopenglversionfunctions.cpp opengl/qopenglversionfunctions.h
+ opengl/qopenglversionfunctionsfactory.cpp opengl/qopenglversionfunctionsfactory_p.h
+ opengl/qopenglvertexarrayobject.cpp opengl/qopenglvertexarrayobject.h
+ rhi/qrhigles2.cpp rhi/qrhigles2_p.h
+ rhi/qrhigles2_p_p.h
+)
+
+#### Keys ignored in scope 2:.:.:gui.pro:QT_FEATURE_opengl:
+# MODULE_CONFIG = "opengl"
+
+#### Keys ignored in scope 3:.:.:gui.pro:QT_FEATURE_angle:
+# MODULE_AUX_INCLUDES = "\$\$QT_MODULE_INCLUDE_BASE/QtANGLE"
+
+qt_extend_target(Gui CONDITION APPLE_OSX
+ SOURCES
+ rhi/qrhimetal.mm rhi/qrhimetal_p.h
+ rhi/qrhimetal_p_p.h
+ LIBRARIES
+ ${FWAppKit}
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+ ${FWMetal}
+)
+
+qt_extend_target(Gui CONDITION APPLE
+ SOURCES
+ image/qimage_darwin.mm
+ painting/qcoregraphics.mm painting/qcoregraphics_p.h
+ LIBRARIES
+ ${FWCoreGraphics}
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_animation
+ SOURCES
+ animation/qguivariantanimation.cpp
+)
+
+qt_extend_target(Gui CONDITION WIN32
+ SOURCES
+ kernel/qwindowdefs_win.h
+ rhi/qrhid3d11.cpp rhi/qrhid3d11_p.h
+ rhi/qrhid3d11_p_p.h
+ PUBLIC_LIBRARIES
+ d3d11
+ dxgi
+ dxguid
+)
+
+#### Keys ignored in scope 8:.:.:gui.pro:WIN32:
+# CMAKE_WINDOWS_BUILD = "True"
+
+#### Keys ignored in scope 11:.:.:gui.pro:QT_FEATURE_egl:
+# CMAKE_EGL_LIBS = "$$cmakeProcessLibs($$QMAKE_LIBS_EGL)"
+
+#### Keys ignored in scope 12:.:.:gui.pro:NOT QMAKE_LIBDIR_EGL_ISEMPTY:
+# CMAKE_EGL_LIBDIR = "$$cmakeTargetPath($$QMAKE_LIBDIR_EGL)"
+
+#### Keys ignored in scope 13:.:.:gui.pro:QT_FEATURE_opengles2:
+# CMAKE_GL_HEADER_NAME = "GLES2/gl2.h"
+# CMAKE_OPENGL_INCDIRS = "$$cmakePortablePaths($$QMAKE_INCDIR_OPENGL_ES2)"
+# CMAKE_OPENGL_LIBS = "$$cmakeProcessLibs($$QMAKE_LIBS_OPENGL_ES2)"
+# CMAKE_QT_OPENGL_IMPLEMENTATION = "GLESv2"
+
+#### Keys ignored in scope 14:.:.:gui.pro:NOT QMAKE_INCDIR_OPENGL_ES2_ISEMPTY:
+# CMAKE_GL_INCDIRS = "$$cmakeTargetPaths($$QMAKE_INCDIR_OPENGL_ES2)"
+
+#### Keys ignored in scope 15:.:.:gui.pro:NOT QMAKE_LIBDIR_OPENGL_ES2_ISEMPTY:
+# CMAKE_OPENGL_LIBDIR = "$$cmakePortablePaths($$QMAKE_LIBDIR_OPENGL_ES2)"
+
+#### Keys ignored in scope 17:.:.:gui.pro:QT_FEATURE_opengl:
+# CMAKE_GL_HEADER_NAME = "GL/gl.h"
+# CMAKE_OPENGL_INCDIRS = "$$cmakePortablePaths($$QMAKE_INCDIR_OPENGL)"
+# CMAKE_QT_OPENGL_IMPLEMENTATION = "GL"
+
+#### Keys ignored in scope 18:.:.:gui.pro:NOT QMAKE_INCDIR_OPENGL_ISEMPTY:
+# CMAKE_GL_INCDIRS = "$$cmakeTargetPaths($$QMAKE_INCDIR_OPENGL)"
+
+#### Keys ignored in scope 19:.:.:gui.pro:NOT QT_FEATURE_dynamicgl:
+# CMAKE_OPENGL_LIBS = "$$cmakeProcessLibs($$QMAKE_LIBS_OPENGL)"
+
+#### Keys ignored in scope 20:.:.:gui.pro:NOT QMAKE_LIBDIR_OPENGL_ISEMPTY:
+# CMAKE_OPENGL_LIBDIR = "$$cmakePortablePaths($$QMAKE_LIBDIR_OPENGL)"
+
+#### Keys ignored in scope 21:.:.:gui.pro:APPLE:
+# CMAKE_GL_HEADER_NAME = "gl.h"
+
+#### Keys ignored in scope 22:.:.:gui.pro:QT_FEATURE_egl:
+# CMAKE_EGL_INCDIRS = "$$cmakePortablePaths($$QMAKE_INCDIR_EGL)"
+
+qt_extend_target(Gui CONDITION QT_FEATURE_accessibility
+ SOURCES
+ accessible/qaccessible.cpp accessible/qaccessible.h
+ accessible/qaccessiblebridge.cpp accessible/qaccessiblebridge.h
+ accessible/qaccessiblecache.cpp accessible/qaccessiblecache_p.h
+ accessible/qaccessibleobject.cpp accessible/qaccessibleobject.h
+ accessible/qaccessibleplugin.cpp accessible/qaccessibleplugin.h
+ accessible/qplatformaccessibility.cpp accessible/qplatformaccessibility.h
+)
+
+qt_extend_target(Gui CONDITION APPLE AND QT_FEATURE_accessibility
+ SOURCES
+ accessible/qaccessiblecache_mac.mm
+ LIBRARIES
+ ${FWFoundation}
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_action
+ SOURCES
+ kernel/qguiaction.cpp kernel/qguiaction.h kernel/qguiaction_p.h
+ kernel/qguiactiongroup.cpp kernel/qguiactiongroup.h kernel/qguiactiongroup_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_draganddrop
+ SOURCES
+ kernel/qdnd.cpp kernel/qdnd_p.h
+ kernel/qdrag.cpp kernel/qdrag.h
+ kernel/qplatformdrag.cpp kernel/qplatformdrag.h
+ kernel/qshapedpixmapdndwindow.cpp kernel/qshapedpixmapdndwindow_p.h
+ kernel/qsimpledrag.cpp kernel/qsimpledrag_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_shortcut
+ SOURCES
+ kernel/qguishortcut.cpp kernel/qguishortcut.h kernel/qguishortcut_p.h
+ kernel/qkeysequence.cpp kernel/qkeysequence.h kernel/qkeysequence_p.h
+ kernel/qshortcutmap.cpp kernel/qshortcutmap_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_movie
+ SOURCES
+ image/qmovie.cpp image/qmovie.h
+)
+
+qt_extend_target(Gui CONDITION WIN32 AND NOT WINRT
+ SOURCES
+ image/qpixmap_win.cpp
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_png
+ SOURCES
+ image/qpnghandler.cpp image/qpnghandler_p.h
+ LIBRARIES
+ PNG::PNG
+)
+
+if(NOT ANDROID)
+ qt_add_simd_part(Gui SIMD sse2
+ SOURCES
+ painting/qdrawhelper_sse2.cpp
+ )
+
+ qt_add_simd_part(Gui SIMD ssse3
+ SOURCES
+ image/qimage_ssse3.cpp
+ painting/qdrawhelper_ssse3.cpp
+ )
+
+ qt_add_simd_part(Gui SIMD sse4_1
+ SOURCES
+ painting/qdrawhelper_sse4.cpp
+ painting/qimagescale_sse4.cpp
+ )
+
+ qt_add_simd_part(Gui SIMD neon
+ SOURCES
+ image/qimage_neon.cpp
+ painting/qdrawhelper_neon.cpp painting/qdrawhelper_neon_p.h
+ painting/qimagescale_neon.cpp
+ )
+
+ qt_add_simd_part(Gui SIMD mips_dsp
+ SOURCES
+ painting/qdrawhelper_mips_dsp.cpp painting/qdrawhelper_mips_dsp_p.h
+ painting/qdrawhelper_mips_dsp_asm.S
+ painting/qt_mips_asm_dsp_p.h
+ )
+
+ qt_add_simd_part(Gui SIMD mips_dspr2
+ SOURCES
+ image/qimage_mips_dspr2.cpp
+ image/qimage_mips_dspr2_asm.S
+ painting/qdrawhelper_mips_dspr2_asm.S
+ )
+
+ qt_add_simd_part(Gui SIMD arch_haswell
+ SOURCES
+ painting/qdrawhelper_avx2.cpp
+ )
+endif()
+
+qt_extend_target(Gui CONDITION ANDROID AND TEST_architecture_arch STREQUAL arm64
+ SOURCES
+ image/qimage_neon.cpp
+ painting/qdrawhelper_neon.cpp painting/qdrawhelper_neon_p.h
+ painting/qimagescale_neon.cpp
+)
+
+qt_extend_target(Gui CONDITION ANDROID AND (TEST_architecture_arch STREQUAL i386 OR TEST_architecture_arch STREQUAL x86_64)
+ SOURCES
+ image/qimage_ssse3.cpp
+ painting/qdrawhelper_sse2.cpp
+ painting/qdrawhelper_ssse3.cpp
+ DEFINES
+ QT_COMPILER_SUPPORTS_SSE2 QT_COMPILER_SUPPORTS_SSE2
+ QT_COMPILER_SUPPORTS_SSE3 QT_COMPILER_SUPPORTS_SSE3
+ QT_COMPILER_SUPPORTS_SSSE3 QT_COMPILER_SUPPORTS_SSSE3
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_harfbuzz
+ SOURCES
+ text/qharfbuzzng.cpp text/qharfbuzzng_p.h
+ LIBRARIES
+ WrapHarfbuzz::WrapHarfbuzz
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_textodfwriter
+ SOURCES
+ text/qtextodfwriter.cpp text/qtextodfwriter_p.h
+ text/qzip.cpp
+ text/qzipreader_p.h
+ text/qzipwriter_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_textmarkdownreader
+ SOURCES
+ text/qtextmarkdownimporter.cpp text/qtextmarkdownimporter_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_system_textmarkdownreader AND QT_FEATURE_textmarkdownreader
+ PUBLIC_LIBRARIES
+ libmd4c
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_textmarkdownreader AND NOT QT_FEATURE_system_textmarkdownreader
+ SOURCES
+ ../3rdparty/md4c/md4c.c ../3rdparty/md4c/md4c.h
+ INCLUDE_DIRECTORIES
+ ../3rdparty/md4c
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_textmarkdownwriter
+ SOURCES
+ text/qtextmarkdownwriter.cpp text/qtextmarkdownwriter_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_cssparser
+ SOURCES
+ painting/qcssutil.cpp
+ text/qcssparser.cpp text/qcssparser_p.h
+)
+
+qt_extend_target(Gui CONDITION UNIX AND NOT ANDROID AND NOT APPLE_UIKIT AND NOT INTEGRITY AND NOT (TEST_architecture_arch STREQUAL "arm64")
+ DEFINES
+ ENABLE_PIXMAN_DRAWHELPERS
+)
+
+if(UNIX AND NOT ANDROID AND NOT APPLE_UIKIT AND NOT INTEGRITY AND NOT (TEST_architecture_arch STREQUAL "arm64"))
+ qt_add_simd_part(Gui SIMD neon
+ SOURCES
+ ../3rdparty/pixman/pixman-arm-neon-asm.S
+ painting/qdrawhelper_neon_asm.S
+ )
+endif()
+
+qt_extend_target(Gui CONDITION ANDROID AND TEST_architecture_arch STREQUAL x86_64
+ SOURCES
+ painting/qdrawhelper_sse4.cpp
+ painting/qimagescale_sse4.cpp
+ DEFINES
+ QT_COMPILER_SUPPORTS_SSE4_1
+ QT_COMPILER_SUPPORTS_SSE4_2
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_regularexpression
+ SOURCES
+ util/qshadergenerator.cpp util/qshadergenerator_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_opengl AND NOT QT_FEATURE_opengles2
+ SOURCES
+ opengl/qopenglfunctions_1_0.cpp opengl/qopenglfunctions_1_0.h
+ opengl/qopenglfunctions_1_1.cpp opengl/qopenglfunctions_1_1.h
+ opengl/qopenglfunctions_1_2.cpp opengl/qopenglfunctions_1_2.h
+ opengl/qopenglfunctions_1_3.cpp opengl/qopenglfunctions_1_3.h
+ opengl/qopenglfunctions_1_4.cpp opengl/qopenglfunctions_1_4.h
+ opengl/qopenglfunctions_1_5.cpp opengl/qopenglfunctions_1_5.h
+ opengl/qopenglfunctions_2_0.cpp opengl/qopenglfunctions_2_0.h
+ opengl/qopenglfunctions_2_1.cpp opengl/qopenglfunctions_2_1.h
+ opengl/qopenglfunctions_3_0.cpp opengl/qopenglfunctions_3_0.h
+ opengl/qopenglfunctions_3_1.cpp opengl/qopenglfunctions_3_1.h
+ opengl/qopenglfunctions_3_2_compatibility.cpp opengl/qopenglfunctions_3_2_compatibility.h
+ opengl/qopenglfunctions_3_2_core.cpp opengl/qopenglfunctions_3_2_core.h
+ opengl/qopenglfunctions_3_3_compatibility.cpp opengl/qopenglfunctions_3_3_compatibility.h
+ opengl/qopenglfunctions_3_3_core.cpp opengl/qopenglfunctions_3_3_core.h
+ opengl/qopenglfunctions_4_0_compatibility.cpp opengl/qopenglfunctions_4_0_compatibility.h
+ opengl/qopenglfunctions_4_0_core.cpp opengl/qopenglfunctions_4_0_core.h
+ opengl/qopenglfunctions_4_1_compatibility.cpp opengl/qopenglfunctions_4_1_compatibility.h
+ opengl/qopenglfunctions_4_1_core.cpp opengl/qopenglfunctions_4_1_core.h
+ opengl/qopenglfunctions_4_2_compatibility.cpp opengl/qopenglfunctions_4_2_compatibility.h
+ opengl/qopenglfunctions_4_2_core.cpp opengl/qopenglfunctions_4_2_core.h
+ opengl/qopenglfunctions_4_3_compatibility.cpp opengl/qopenglfunctions_4_3_compatibility.h
+ opengl/qopenglfunctions_4_3_core.cpp opengl/qopenglfunctions_4_3_core.h
+ opengl/qopenglfunctions_4_4_compatibility.cpp opengl/qopenglfunctions_4_4_compatibility.h
+ opengl/qopenglfunctions_4_4_core.cpp opengl/qopenglfunctions_4_4_core.h
+ opengl/qopenglfunctions_4_5_compatibility.cpp opengl/qopenglfunctions_4_5_compatibility.h
+ opengl/qopenglfunctions_4_5_core.cpp opengl/qopenglfunctions_4_5_core.h
+ opengl/qopenglqueryhelper_p.h
+ opengl/qopengltimerquery.cpp opengl/qopengltimerquery.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_opengl AND QT_FEATURE_opengles2
+ SOURCES
+ opengl/qopenglfunctions_es2.cpp opengl/qopenglfunctions_es2.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_vulkan
+ SOURCES
+ rhi/qrhivulkan.cpp rhi/qrhivulkan_p.h
+ rhi/qrhivulkan_p_p.h
+ vulkan/qplatformvulkaninstance.cpp vulkan/qplatformvulkaninstance.h
+ vulkan/qvulkanfunctions.cpp
+ vulkan/qvulkaninstance.cpp vulkan/qvulkaninstance.h
+ vulkan/qvulkanwindow.cpp vulkan/qvulkanwindow.h vulkan/qvulkanwindow_p.h
+ PUBLIC_LIBRARIES
+ Vulkan::Vulkan_nolink
+)
+
+#### Keys ignored in scope 80:.:vulkan:vulkan/vulkan.pri:QT_FEATURE_vkgen:
+# QMAKE_EXTRA_COMPILERS = "qvkgen_h" "qvkgen_ph" "qvkgen_pimpl"
+# QMAKE_QVKGEN_INPUT = "vulkan/vk.xml"
+# QMAKE_QVKGEN_LICENSE_HEADER = "$$QT_SOURCE_TREE/header.LGPL"
+# qvkgen_h.commands = "$$QMAKE_QVKGEN" "${QMAKE_FILE_IN}" "$$shell_quote($$QMAKE_QVKGEN_LICENSE_HEADER)" "${QMAKE_FILE_OUT_PATH}/${QMAKE_FILE_OUT_BASE}"
+# qvkgen_h.input = "QMAKE_QVKGEN_INPUT"
+# qvkgen_h.output = "$$OUT_PWD/vulkan/qvulkanfunctions.h"
+# qvkgen_ph.commands = "$$escape_expand(\\n)"
+# qvkgen_ph.depends = "$$OUT_PWD/vulkan/qvulkanfunctions.h"
+# qvkgen_ph.input = "QMAKE_QVKGEN_INPUT"
+# qvkgen_ph.output = "$$OUT_PWD/vulkan/qvulkanfunctions_p.h"
+# qvkgen_pimpl.commands = "$$escape_expand(\\n)"
+# qvkgen_pimpl.depends = "$$OUT_PWD/vulkan/qvulkanfunctions_p.h"
+# qvkgen_pimpl.input = "QMAKE_QVKGEN_INPUT"
+# qvkgen_pimpl.output = "$$OUT_PWD/vulkan/qvulkanfunctions_p.cpp"
+
+#### Keys ignored in scope 81:.:vulkan:vulkan/vulkan.pri:QT_FEATURE_vulkan:
+# qvkgen_h.variable_out = "HEADERS"
+
+#### Keys ignored in scope 82:.:vulkan:vulkan/vulkan.pri:else:
+# qvkgen_h.CONFIG = "target_predeps" "no_link"
+
+qt_extend_target(Gui CONDITION WASM
+ SOURCES
+ platform/wasm/qwasmlocalfileaccess.cpp platform/wasm/qwasmlocalfileaccess_p.h
+)
+
+qt_extend_target(Gui CONDITION NOT GCC OR NOT QT_COMPILER_VERSION_MAJOR STREQUAL 5
+ SOURCES
+ painting/qdrawhelper.cpp
+ NO_PCH_SOURCES
+ "painting/qdrawhelper.cpp"
+)
+
+
+qt_create_tracepoints(Gui qtgui.tracepoints)
+qt_add_docs(Gui
+ doc/qtgui.qdocconf
+)
+
diff --git a/src/gui/CMakeLists.txt b/src/gui/CMakeLists.txt
new file mode 100644
index 0000000000..c3139c60b6
--- /dev/null
+++ b/src/gui/CMakeLists.txt
@@ -0,0 +1,806 @@
+# Generated from gui.pro.
+
+set(OpenGL_GL_PREFERENCE GLVND) # special case:
+
+#####################################################################
+## Gui Module:
+#####################################################################
+
+# special case begin
+qt_find_package(X11_XCB)
+
+if (QT_FEATURE_gui)
+ if (WINRT)
+ set(_default_platform "winrt")
+ elseif(WIN32)
+ set(_default_platform "windows")
+ elseif(ANDROID)
+ set(_default_platform "android")
+ elseif(APPLE_OSX)
+ set(_default_platform "cocoa")
+ elseif(APPLE_TVOS OR APPLE_IOS)
+ set(_default_platform "ios")
+ elseif(APPLE_WATCHOS)
+ set(_default_platform "minimal")
+ elseif(QNX)
+ set(_default_platform "qnx")
+ elseif(INTEGRITY)
+ set(_default_platform "integrityfb")
+ elseif(HAIKU)
+ set(_default_platform "haiku")
+ elseif(WASM)
+ set(_default_platform "wasm")
+ else()
+ set(_default_platform "xcb")
+ endif()
+
+ set(QT_QPA_DEFAULT_PLATFORM "${_default_platform}" CACHE STRING "QPA default platform")
+endif()
+
+if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
+ set_source_files_properties(../3rdparty/md4c/md4c.c PROPERTIES COMPILE_FLAGS "-Wno-error=unused-parameter -Wno-error=sign-compare -Wno-error=missing-field-initializers")
+elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang" OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "AppleClang")
+ set_source_files_properties(../3rdparty/md4c/md4c.c PROPERTIES COMPILE_FLAGS "-Wno-error=unused-parameter -Wno-error=sign-compare -Wno-error=missing-field-initializers -Wno-error=missing-braces")
+endif()
+
+# special case end
+
+qt_add_module(Gui
+ GENERATE_METATYPES
+ PLUGIN_TYPES platforms platforms/darwin xcbglintegrations platformthemes platforminputcontexts generic iconengines imageformats egldeviceintegrations
+ FEATURE_DEPENDENCIES # special case:
+ Qt::Network # special case:
+ SOURCES
+ image/qbitmap.cpp image/qbitmap.h
+ image/qbmphandler.cpp image/qbmphandler_p.h
+ image/qicon.cpp image/qicon.h image/qicon_p.h
+ image/qiconengine.cpp image/qiconengine.h
+ image/qiconengineplugin.cpp image/qiconengineplugin.h
+ image/qiconloader.cpp image/qiconloader_p.h
+ image/qimage.cpp image/qimage.h image/qimage_p.h
+ image/qimage_conversions.cpp
+ image/qimageiohandler.cpp image/qimageiohandler.h
+ image/qimagepixmapcleanuphooks.cpp image/qimagepixmapcleanuphooks_p.h
+ image/qimagereader.cpp image/qimagereader.h
+ image/qimagereaderwriterhelpers.cpp image/qimagereaderwriterhelpers_p.h
+ image/qimagewriter.cpp image/qimagewriter.h
+ image/qpaintengine_pic.cpp image/qpaintengine_pic_p.h
+ image/qpicture.cpp image/qpicture.h image/qpicture_p.h
+ image/qpixmap.cpp image/qpixmap.h
+ image/qpixmap_blitter.cpp image/qpixmap_blitter_p.h
+ image/qpixmap_raster.cpp image/qpixmap_raster_p.h
+ image/qpixmapcache.cpp image/qpixmapcache.h image/qpixmapcache_p.h
+ image/qplatformpixmap.cpp image/qplatformpixmap.h
+ image/qppmhandler.cpp image/qppmhandler_p.h
+ image/qxbmhandler.cpp image/qxbmhandler_p.h
+ image/qxpmhandler.cpp image/qxpmhandler_p.h
+ # itemmodels/qstandarditemmodel.cpp itemmodels/qstandarditemmodel.h itemmodels/qstandarditemmodel_p.h # special case
+ kernel/qclipboard.cpp kernel/qclipboard.h
+ kernel/qcursor.cpp kernel/qcursor.h kernel/qcursor_p.h
+ kernel/qevent.cpp kernel/qevent.h kernel/qevent_p.h
+ kernel/qgenericplugin.cpp kernel/qgenericplugin.h
+ kernel/qgenericpluginfactory.cpp kernel/qgenericpluginfactory.h
+ kernel/qguiapplication.cpp kernel/qguiapplication.h kernel/qguiapplication_p.h
+ kernel/qguivariant.cpp
+ kernel/qhighdpiscaling.cpp kernel/qhighdpiscaling_p.h
+ kernel/qinputdevicemanager.cpp kernel/qinputdevicemanager_p.h
+ kernel/qinputdevicemanager_p_p.h
+ kernel/qinputmethod.cpp kernel/qinputmethod.h kernel/qinputmethod_p.h
+ kernel/qinternalmimedata.cpp kernel/qinternalmimedata_p.h
+ kernel/qkeymapper.cpp kernel/qkeymapper_p.h
+ kernel/qoffscreensurface.cpp kernel/qoffscreensurface.h
+ kernel/qpaintdevicewindow.cpp kernel/qpaintdevicewindow.h kernel/qpaintdevicewindow_p.h
+ kernel/qpalette.cpp kernel/qpalette.h
+ kernel/qpixelformat.cpp kernel/qpixelformat.h
+ kernel/qplatformclipboard.cpp kernel/qplatformclipboard.h
+ kernel/qplatformcursor.cpp kernel/qplatformcursor.h
+ kernel/qplatformdialoghelper.cpp kernel/qplatformdialoghelper.h
+ kernel/qplatformgraphicsbuffer.cpp kernel/qplatformgraphicsbuffer.h
+ kernel/qplatformgraphicsbufferhelper.cpp kernel/qplatformgraphicsbufferhelper.h
+ kernel/qplatforminputcontext.cpp kernel/qplatforminputcontext.h kernel/qplatforminputcontext_p.h
+ kernel/qplatforminputcontextfactory.cpp kernel/qplatforminputcontextfactory_p.h
+ kernel/qplatforminputcontextplugin.cpp kernel/qplatforminputcontextplugin_p.h
+ kernel/qplatformintegration.cpp kernel/qplatformintegration.h
+ kernel/qplatformintegrationfactory.cpp kernel/qplatformintegrationfactory_p.h
+ kernel/qplatformintegrationplugin.cpp kernel/qplatformintegrationplugin.h
+ kernel/qplatformmenu.cpp kernel/qplatformmenu.h
+ kernel/qplatformnativeinterface.cpp kernel/qplatformnativeinterface.h
+ kernel/qplatformoffscreensurface.cpp kernel/qplatformoffscreensurface.h
+ kernel/qplatformscreen.cpp kernel/qplatformscreen.h kernel/qplatformscreen_p.h
+ kernel/qplatformservices.cpp kernel/qplatformservices.h
+ kernel/qplatformsessionmanager.cpp kernel/qplatformsessionmanager.h
+ kernel/qplatformsharedgraphicscache.cpp kernel/qplatformsharedgraphicscache.h
+ kernel/qplatformsurface.cpp kernel/qplatformsurface.h
+ kernel/qplatformsystemtrayicon.cpp kernel/qplatformsystemtrayicon.h
+ kernel/qplatformtheme.cpp kernel/qplatformtheme.h kernel/qplatformtheme_p.h
+ kernel/qplatformthemefactory.cpp kernel/qplatformthemefactory_p.h
+ kernel/qplatformthemeplugin.cpp kernel/qplatformthemeplugin.h
+ kernel/qplatformwindow.cpp kernel/qplatformwindow.h kernel/qplatformwindow_p.h
+ kernel/qrasterwindow.cpp kernel/qrasterwindow.h
+ kernel/qscreen.cpp kernel/qscreen.h kernel/qscreen_p.h
+ kernel/qsessionmanager.cpp kernel/qsessionmanager.h kernel/qsessionmanager_p.h
+ kernel/qstylehints.cpp kernel/qstylehints.h
+ kernel/qsurface.cpp kernel/qsurface.h
+ kernel/qsurfaceformat.cpp kernel/qsurfaceformat.h
+ kernel/qtestsupport_gui.cpp kernel/qtestsupport_gui.h
+ kernel/qtguiglobal.h kernel/qtguiglobal_p.h
+ kernel/qtouchdevice.cpp kernel/qtouchdevice.h kernel/qtouchdevice_p.h
+ kernel/qwindow.cpp kernel/qwindow.h kernel/qwindow_p.h
+ kernel/qwindowdefs.h
+ kernel/qwindowsysteminterface.cpp kernel/qwindowsysteminterface.h kernel/qwindowsysteminterface_p.h
+ math3d/qgenericmatrix.cpp math3d/qgenericmatrix.h
+ math3d/qmatrix4x4.cpp math3d/qmatrix4x4.h
+ math3d/qquaternion.cpp math3d/qquaternion.h
+ math3d/qvector2d.cpp math3d/qvector2d.h
+ math3d/qvector3d.cpp math3d/qvector3d.h
+ math3d/qvector4d.cpp math3d/qvector4d.h
+ painting/qbackingstore.cpp painting/qbackingstore.h
+ painting/qbezier.cpp painting/qbezier_p.h
+ painting/qblendfunctions.cpp painting/qblendfunctions_p.h
+ painting/qblittable.cpp painting/qblittable_p.h
+ painting/qbrush.cpp painting/qbrush.h
+ painting/qcolor.cpp painting/qcolor.h painting/qcolor_p.h
+ painting/qcolormatrix_p.h
+ painting/qcolorspace.cpp painting/qcolorspace.h painting/qcolorspace_p.h
+ painting/qcolortransferfunction_p.h
+ painting/qcolortransfertable_p.h
+ painting/qcolortransform.cpp painting/qcolortransform.h painting/qcolortransform_p.h
+ painting/qcolortrc_p.h
+ painting/qcolortrclut.cpp painting/qcolortrclut_p.h
+ painting/qcompositionfunctions.cpp
+ painting/qcosmeticstroker.cpp painting/qcosmeticstroker_p.h
+ painting/qdatabuffer_p.h
+ painting/qdrawhelper_p.h
+ painting/qdrawhelper_x86_p.h
+ painting/qdrawingprimitive_sse2_p.h
+ painting/qemulationpaintengine.cpp painting/qemulationpaintengine_p.h
+ painting/qfixed_p.h
+ painting/qgrayraster.c painting/qgrayraster_p.h
+ painting/qicc.cpp painting/qicc_p.h
+ painting/qimagescale.cpp
+ painting/qmatrix.cpp painting/qmatrix.h
+ painting/qmemrotate.cpp painting/qmemrotate_p.h
+ painting/qoutlinemapper.cpp painting/qoutlinemapper_p.h
+ painting/qpagedpaintdevice.cpp painting/qpagedpaintdevice.h painting/qpagedpaintdevice_p.h
+ painting/qpagelayout.cpp painting/qpagelayout.h
+ painting/qpagesize.cpp painting/qpagesize.h
+ painting/qpaintdevice.cpp painting/qpaintdevice.h
+ painting/qpaintengine.cpp painting/qpaintengine.h painting/qpaintengine_p.h
+ painting/qpaintengine_blitter.cpp painting/qpaintengine_blitter_p.h
+ painting/qpaintengine_raster.cpp painting/qpaintengine_raster_p.h
+ painting/qpaintengineex.cpp painting/qpaintengineex_p.h
+ painting/qpainter.cpp painting/qpainter.h painting/qpainter_p.h
+ painting/qpainterpath.cpp painting/qpainterpath.h painting/qpainterpath_p.h
+ painting/qpathclipper.cpp painting/qpathclipper_p.h
+ painting/qpathsimplifier.cpp painting/qpathsimplifier_p.h
+ painting/qpdf.cpp painting/qpdf_p.h
+ painting/qpdfwriter.cpp painting/qpdfwriter.h
+ painting/qpen.cpp painting/qpen.h
+ painting/qplatformbackingstore.cpp painting/qplatformbackingstore.h
+ painting/qpolygon.cpp painting/qpolygon.h
+ painting/qpolygonclipper_p.h
+ painting/qrasterdefs_p.h
+ painting/qrasterizer.cpp painting/qrasterizer_p.h
+ painting/qrbtree_p.h
+ painting/qregion.cpp painting/qregion.h
+ painting/qrgb.h
+ painting/qrgba64.h painting/qrgba64_p.h
+ painting/qstroker.cpp painting/qstroker_p.h
+ painting/qtextureglyphcache.cpp painting/qtextureglyphcache_p.h
+ painting/qtransform.cpp painting/qtransform.h
+ painting/qtriangulatingstroker.cpp painting/qtriangulatingstroker_p.h
+ painting/qtriangulator.cpp painting/qtriangulator_p.h
+ painting/qvectorpath_p.h
+ rhi/qrhi.cpp rhi/qrhi_p.h
+ rhi/qrhi_p_p.h
+ rhi/qrhinull.cpp rhi/qrhinull_p.h
+ rhi/qrhinull_p_p.h
+ rhi/qrhiprofiler.cpp rhi/qrhiprofiler_p.h
+ rhi/qrhiprofiler_p_p.h
+ rhi/qshader.cpp rhi/qshader_p.h
+ rhi/qshader_p_p.h
+ rhi/qshaderdescription.cpp rhi/qshaderdescription_p.h
+ rhi/qshaderdescription_p_p.h
+ text/qabstracttextdocumentlayout.cpp text/qabstracttextdocumentlayout.h text/qabstracttextdocumentlayout_p.h
+ text/qdistancefield.cpp text/qdistancefield_p.h
+ text/qfont.cpp text/qfont.h text/qfont_p.h
+ text/qfontdatabase.cpp text/qfontdatabase.h
+ text/qfontengine.cpp text/qfontengine_p.h
+ text/qfontengine_qpf2.cpp
+ text/qfontengineglyphcache.cpp text/qfontengineglyphcache_p.h
+ text/qfontinfo.h
+ text/qfontmetrics.cpp text/qfontmetrics.h
+ text/qfontsubset.cpp text/qfontsubset_p.h
+ text/qfragmentmap.cpp text/qfragmentmap_p.h
+ text/qglyphrun.cpp text/qglyphrun.h text/qglyphrun_p.h
+ text/qinputcontrol.cpp text/qinputcontrol_p.h
+ text/qplatformfontdatabase.cpp text/qplatformfontdatabase.h
+ text/qrawfont.cpp text/qrawfont.h text/qrawfont_p.h
+ text/qstatictext.cpp text/qstatictext.h text/qstatictext_p.h
+ text/qsyntaxhighlighter.cpp text/qsyntaxhighlighter.h
+ text/qtextcursor.cpp text/qtextcursor.h text/qtextcursor_p.h
+ text/qtextdocument.cpp text/qtextdocument.h text/qtextdocument_p.cpp text/qtextdocument_p.h
+ text/qtextdocumentfragment.cpp text/qtextdocumentfragment.h text/qtextdocumentfragment_p.h
+ text/qtextdocumentlayout.cpp text/qtextdocumentlayout_p.h
+ text/qtextdocumentwriter.cpp text/qtextdocumentwriter.h
+ text/qtextengine.cpp text/qtextengine_p.h
+ text/qtextformat.cpp text/qtextformat.h text/qtextformat_p.h
+ text/qtexthtmlparser.cpp text/qtexthtmlparser_p.h
+ text/qtextimagehandler.cpp text/qtextimagehandler_p.h
+ text/qtextlayout.cpp text/qtextlayout.h
+ text/qtextlist.cpp text/qtextlist.h
+ text/qtextobject.cpp text/qtextobject.h text/qtextobject_p.h
+ text/qtextoption.cpp text/qtextoption.h
+ text/qtexttable.cpp text/qtexttable.h text/qtexttable_p.h
+ util/qabstractlayoutstyleinfo.cpp util/qabstractlayoutstyleinfo_p.h
+ util/qastchandler.cpp util/qastchandler_p.h
+ util/qdesktopservices.cpp util/qdesktopservices.h
+ util/qgridlayoutengine.cpp util/qgridlayoutengine_p.h
+ util/qhexstring_p.h
+ util/qktxhandler.cpp util/qktxhandler_p.h
+ util/qlayoutpolicy.cpp util/qlayoutpolicy_p.h
+ util/qpkmhandler.cpp util/qpkmhandler_p.h
+ util/qshaderformat.cpp util/qshaderformat_p.h
+ util/qshadergraph.cpp util/qshadergraph_p.h
+ util/qshadergraphloader.cpp util/qshadergraphloader_p.h
+ util/qshaderlanguage.cpp util/qshaderlanguage_p.h
+ util/qshadernode.cpp util/qshadernode_p.h
+ util/qshadernodeport.cpp util/qshadernodeport_p.h
+ util/qshadernodesloader.cpp util/qshadernodesloader_p.h
+ util/qtexturefiledata.cpp util/qtexturefiledata_p.h
+ util/qtexturefilehandler_p.h
+ util/qtexturefilereader.cpp util/qtexturefilereader_p.h
+ util/qvalidator.cpp util/qvalidator.h
+ DEFINES
+ QT_NO_FOREACH
+ QT_NO_USING_NAMESPACE
+ QT_QPA_DEFAULT_PLATFORM_NAME="${QT_QPA_DEFAULT_PLATFORM}" # special case
+ INCLUDE_DIRECTORIES
+ ../3rdparty/VulkanMemoryAllocator
+ LIBRARIES
+ Qt::CorePrivate
+ ZLIB::ZLIB
+ PUBLIC_LIBRARIES
+ Qt::Core
+ NO_PCH_SOURCES # special case
+ "painting/qdrawhelper.cpp" # special case
+ PRECOMPILED_HEADER
+ "kernel/qt_gui_pch.h"
+)
+
+# Resources:
+
+set_source_files_properties("painting/../../3rdparty/icc/sRGB2014.icc"
+ PROPERTIES QT_RESOURCE_ALIAS "sRGB2014.icc"
+)
+set(qpdf_resource_files
+ "../../3rdparty/icc/sRGB2014.icc"
+ "qpdfa_metadata.xml"
+)
+
+qt_add_resource(Gui "qpdf"
+ PREFIX
+ "/qpdf/"
+ BASE
+ "painting"
+ FILES
+ ${qpdf_resource_files}
+)
+set(qmake_webgradients_resource_files
+ "painting/webgradients.binaryjson"
+)
+
+qt_add_resource(Gui "qmake_webgradients"
+ PREFIX
+ "/qgradient/" # special case
+ #BASE # special case remove
+ #"painting" # special case remove
+ FILES
+ ${qmake_webgradients_resource_files}
+)
+
+# special case begin
+# Replace arch_haswell with avx2 feature. That is what is used in the code requireing
+# this file, too!
+qt_add_simd_part(Gui SIMD avx2
+ SOURCES
+ painting/qdrawhelper_avx2.cpp
+)
+# special case end
+
+# special case begin
+qt_extend_target(Gui CONDITION QT_FEATURE_standarditemmodel
+ SOURCES
+ itemmodels/qstandarditemmodel.cpp itemmodels/qstandarditemmodel.h itemmodels/qstandarditemmodel_p.h
+)
+# special case end
+
+
+#### Keys ignored in scope 1:.:.:gui.pro:<TRUE>:
+# MODULE_PLUGIN_TYPES = "platforms" "platforms/darwin" "xcbglintegrations" "platformthemes" "platforminputcontexts" "generic" "iconengines" "imageformats" "egldeviceintegrations"
+# QMAKE_DYNAMIC_LIST_FILE = "$$PWD/QtGui.dynlist"
+# QMAKE_LIBS = "$$QMAKE_LIBS_GUI"
+
+## Scopes:
+#####################################################################
+
+# special case begin
+# With qmake, gui's opengl.pri used CONFIG += opengl, where opengl.prf
+# used direct public linkage against either libGLESv2 or libGL, depending
+# on the opengl _feature_. This is done by hand now here (where the
+# feature is available).
+# DO NOT MOVE THIS TO THE BEGINNING OF THE FILE, the feature variables are not
+# available until the qt_add_module call.
+if(QT_FEATURE_opengl)
+ if(QT_FEATURE_opengles2)
+ find_package(GLESv2)
+ target_link_libraries(Gui PUBLIC GLESv2::GLESv2)
+ else()
+ find_package(OpenGL)
+ target_link_libraries(Gui PUBLIC OpenGL::GL)
+ endif()
+endif()
+# special case end
+
+qt_extend_target(Gui CONDITION QT_FEATURE_opengl
+ SOURCES
+ kernel/qopenglcontext.cpp kernel/qopenglcontext.h kernel/qopenglcontext_p.h
+ kernel/qopenglwindow.cpp kernel/qopenglwindow.h
+ kernel/qplatformopenglcontext.cpp kernel/qplatformopenglcontext.h
+ opengl/qopengl.cpp opengl/qopengl.h opengl/qopengl_p.h
+ opengl/qopengl2pexvertexarray.cpp opengl/qopengl2pexvertexarray_p.h
+ opengl/qopenglbuffer.cpp opengl/qopenglbuffer.h
+ opengl/qopenglcustomshaderstage.cpp opengl/qopenglcustomshaderstage_p.h
+ opengl/qopengldebug.cpp opengl/qopengldebug.h
+ opengl/qopenglengineshadermanager.cpp opengl/qopenglengineshadermanager_p.h
+ opengl/qopenglengineshadersource_p.h
+ opengl/qopenglextensions_p.h
+ opengl/qopenglextrafunctions.h
+ opengl/qopenglframebufferobject.cpp opengl/qopenglframebufferobject.h opengl/qopenglframebufferobject_p.h
+ opengl/qopenglfunctions.cpp opengl/qopenglfunctions.h
+ opengl/qopenglgradientcache.cpp opengl/qopenglgradientcache_p.h
+ opengl/qopenglpaintdevice.cpp opengl/qopenglpaintdevice.h opengl/qopenglpaintdevice_p.h
+ opengl/qopenglpaintengine.cpp opengl/qopenglpaintengine_p.h
+ opengl/qopenglpixeltransferoptions.cpp opengl/qopenglpixeltransferoptions.h
+ opengl/qopenglprogrambinarycache.cpp opengl/qopenglprogrambinarycache_p.h
+ opengl/qopenglshadercache_p.h
+ opengl/qopenglshaderprogram.cpp opengl/qopenglshaderprogram.h
+ opengl/qopengltexture.cpp opengl/qopengltexture.h opengl/qopengltexture_p.h
+ opengl/qopengltextureblitter.cpp opengl/qopengltextureblitter.h
+ opengl/qopengltexturecache.cpp opengl/qopengltexturecache_p.h
+ opengl/qopengltextureglyphcache.cpp opengl/qopengltextureglyphcache_p.h
+ opengl/qopengltexturehelper.cpp opengl/qopengltexturehelper_p.h
+ opengl/qopengltextureuploader.cpp opengl/qopengltextureuploader_p.h
+ opengl/qopenglversionfunctions.cpp opengl/qopenglversionfunctions.h
+ opengl/qopenglversionfunctionsfactory.cpp opengl/qopenglversionfunctionsfactory_p.h
+ opengl/qopenglvertexarrayobject.cpp opengl/qopenglvertexarrayobject.h
+ rhi/qrhigles2.cpp rhi/qrhigles2_p.h
+ rhi/qrhigles2_p_p.h
+)
+
+#### Keys ignored in scope 2:.:.:gui.pro:QT_FEATURE_opengl:
+# MODULE_CONFIG = "opengl"
+
+#### Keys ignored in scope 3:.:.:gui.pro:QT_FEATURE_angle:
+# MODULE_AUX_INCLUDES = "\$\$QT_MODULE_INCLUDE_BASE/QtANGLE"
+
+qt_extend_target(Gui CONDITION APPLE_OSX
+ SOURCES
+ rhi/qrhimetal.mm rhi/qrhimetal_p.h
+ rhi/qrhimetal_p_p.h
+ LIBRARIES
+ ${FWAppKit}
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+ ${FWMetal}
+)
+
+qt_extend_target(Gui CONDITION APPLE
+ SOURCES
+ image/qimage_darwin.mm
+ painting/qcoregraphics.mm painting/qcoregraphics_p.h
+ LIBRARIES
+ ${FWCoreGraphics}
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_animation
+ SOURCES
+ animation/qguivariantanimation.cpp
+)
+
+qt_extend_target(Gui CONDITION WIN32
+ SOURCES
+ kernel/qwindowdefs_win.h
+ rhi/qrhid3d11.cpp rhi/qrhid3d11_p.h
+ rhi/qrhid3d11_p_p.h
+ PUBLIC_LIBRARIES
+ d3d11
+ dxgi
+ dxguid
+)
+
+#### Keys ignored in scope 8:.:.:gui.pro:WIN32:
+# CMAKE_WINDOWS_BUILD = "True"
+
+#### Keys ignored in scope 11:.:.:gui.pro:QT_FEATURE_egl:
+# CMAKE_EGL_LIBS = "$$cmakeProcessLibs($$QMAKE_LIBS_EGL)"
+
+#### Keys ignored in scope 12:.:.:gui.pro:NOT QMAKE_LIBDIR_EGL_ISEMPTY:
+# CMAKE_EGL_LIBDIR = "$$cmakeTargetPath($$QMAKE_LIBDIR_EGL)"
+
+#### Keys ignored in scope 13:.:.:gui.pro:QT_FEATURE_opengles2:
+# CMAKE_GL_HEADER_NAME = "GLES2/gl2.h"
+# CMAKE_OPENGL_INCDIRS = "$$cmakePortablePaths($$QMAKE_INCDIR_OPENGL_ES2)"
+# CMAKE_OPENGL_LIBS = "$$cmakeProcessLibs($$QMAKE_LIBS_OPENGL_ES2)"
+# CMAKE_QT_OPENGL_IMPLEMENTATION = "GLESv2"
+
+#### Keys ignored in scope 14:.:.:gui.pro:NOT QMAKE_INCDIR_OPENGL_ES2_ISEMPTY:
+# CMAKE_GL_INCDIRS = "$$cmakeTargetPaths($$QMAKE_INCDIR_OPENGL_ES2)"
+
+#### Keys ignored in scope 15:.:.:gui.pro:NOT QMAKE_LIBDIR_OPENGL_ES2_ISEMPTY:
+# CMAKE_OPENGL_LIBDIR = "$$cmakePortablePaths($$QMAKE_LIBDIR_OPENGL_ES2)"
+
+#### Keys ignored in scope 17:.:.:gui.pro:QT_FEATURE_opengl:
+# CMAKE_GL_HEADER_NAME = "GL/gl.h"
+# CMAKE_OPENGL_INCDIRS = "$$cmakePortablePaths($$QMAKE_INCDIR_OPENGL)"
+# CMAKE_QT_OPENGL_IMPLEMENTATION = "GL"
+
+#### Keys ignored in scope 18:.:.:gui.pro:NOT QMAKE_INCDIR_OPENGL_ISEMPTY:
+# CMAKE_GL_INCDIRS = "$$cmakeTargetPaths($$QMAKE_INCDIR_OPENGL)"
+
+#### Keys ignored in scope 19:.:.:gui.pro:NOT QT_FEATURE_dynamicgl:
+# CMAKE_OPENGL_LIBS = "$$cmakeProcessLibs($$QMAKE_LIBS_OPENGL)"
+
+#### Keys ignored in scope 20:.:.:gui.pro:NOT QMAKE_LIBDIR_OPENGL_ISEMPTY:
+# CMAKE_OPENGL_LIBDIR = "$$cmakePortablePaths($$QMAKE_LIBDIR_OPENGL)"
+
+#### Keys ignored in scope 21:.:.:gui.pro:APPLE:
+# CMAKE_GL_HEADER_NAME = "gl.h"
+
+#### Keys ignored in scope 22:.:.:gui.pro:QT_FEATURE_egl:
+# CMAKE_EGL_INCDIRS = "$$cmakePortablePaths($$QMAKE_INCDIR_EGL)"
+
+qt_extend_target(Gui CONDITION QT_FEATURE_accessibility
+ SOURCES
+ accessible/qaccessible.cpp accessible/qaccessible.h
+ accessible/qaccessiblebridge.cpp accessible/qaccessiblebridge.h
+ accessible/qaccessiblecache.cpp accessible/qaccessiblecache_p.h
+ accessible/qaccessibleobject.cpp accessible/qaccessibleobject.h
+ accessible/qaccessibleplugin.cpp accessible/qaccessibleplugin.h
+ accessible/qplatformaccessibility.cpp accessible/qplatformaccessibility.h
+)
+
+qt_extend_target(Gui CONDITION APPLE AND QT_FEATURE_accessibility
+ SOURCES
+ accessible/qaccessiblecache_mac.mm
+ LIBRARIES
+ ${FWFoundation}
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_action
+ SOURCES
+ kernel/qguiaction.cpp kernel/qguiaction.h kernel/qguiaction_p.h
+ kernel/qguiactiongroup.cpp kernel/qguiactiongroup.h kernel/qguiactiongroup_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_draganddrop
+ SOURCES
+ kernel/qdnd.cpp kernel/qdnd_p.h
+ kernel/qdrag.cpp kernel/qdrag.h
+ kernel/qplatformdrag.cpp kernel/qplatformdrag.h
+ kernel/qshapedpixmapdndwindow.cpp kernel/qshapedpixmapdndwindow_p.h
+ kernel/qsimpledrag.cpp kernel/qsimpledrag_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_shortcut
+ SOURCES
+ kernel/qguishortcut.cpp kernel/qguishortcut.h kernel/qguishortcut_p.h
+ kernel/qkeysequence.cpp kernel/qkeysequence.h kernel/qkeysequence_p.h
+ kernel/qshortcutmap.cpp kernel/qshortcutmap_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_movie
+ SOURCES
+ image/qmovie.cpp image/qmovie.h
+)
+
+qt_extend_target(Gui CONDITION WIN32 AND NOT WINRT
+ SOURCES
+ image/qpixmap_win.cpp
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_png
+ SOURCES
+ image/qpnghandler.cpp image/qpnghandler_p.h
+ LIBRARIES
+ PNG::PNG
+)
+
+if(NOT ANDROID)
+ qt_add_simd_part(Gui SIMD sse2
+ SOURCES
+ painting/qdrawhelper_sse2.cpp
+ )
+
+ qt_add_simd_part(Gui SIMD ssse3
+ SOURCES
+ image/qimage_ssse3.cpp
+ painting/qdrawhelper_ssse3.cpp
+ )
+
+ qt_add_simd_part(Gui SIMD sse4_1
+ SOURCES
+ painting/qdrawhelper_sse4.cpp
+ painting/qimagescale_sse4.cpp
+ )
+
+ qt_add_simd_part(Gui SIMD neon
+ SOURCES
+ image/qimage_neon.cpp
+ painting/qdrawhelper_neon.cpp painting/qdrawhelper_neon_p.h
+ painting/qimagescale_neon.cpp
+ )
+
+ qt_add_simd_part(Gui SIMD mips_dsp
+ SOURCES
+ painting/qdrawhelper_mips_dsp.cpp painting/qdrawhelper_mips_dsp_p.h
+ painting/qdrawhelper_mips_dsp_asm.S
+ painting/qt_mips_asm_dsp_p.h
+ )
+
+ qt_add_simd_part(Gui SIMD mips_dspr2
+ SOURCES
+ image/qimage_mips_dspr2.cpp
+ image/qimage_mips_dspr2_asm.S
+ painting/qdrawhelper_mips_dspr2_asm.S
+ )
+
+ qt_add_simd_part(Gui SIMD arch_haswell
+ SOURCES
+ painting/qdrawhelper_avx2.cpp
+ )
+endif()
+
+qt_extend_target(Gui CONDITION ANDROID AND TEST_architecture_arch STREQUAL arm64
+ SOURCES
+ image/qimage_neon.cpp
+ painting/qdrawhelper_neon.cpp painting/qdrawhelper_neon_p.h
+ painting/qimagescale_neon.cpp
+)
+
+qt_extend_target(Gui CONDITION ANDROID AND (TEST_architecture_arch STREQUAL i386 OR TEST_architecture_arch STREQUAL x86_64)
+ SOURCES
+ image/qimage_ssse3.cpp
+ painting/qdrawhelper_sse2.cpp
+ painting/qdrawhelper_ssse3.cpp
+ DEFINES
+ QT_COMPILER_SUPPORTS_SSE2 QT_COMPILER_SUPPORTS_SSE2
+ QT_COMPILER_SUPPORTS_SSE3 QT_COMPILER_SUPPORTS_SSE3
+ QT_COMPILER_SUPPORTS_SSSE3 QT_COMPILER_SUPPORTS_SSSE3
+)
+
+# special case begin
+if (MINGW AND CMAKE_CXX_COMPILER_VERSION VERSION_EQUAL 8.1.0)
+ # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86048
+ set_source_files_properties(image/qpnghandler.cpp
+ PROPERTIES COMPILE_OPTIONS -fno-reorder-blocks-and-partition
+ )
+endif()
+# special case end
+
+qt_extend_target(Gui CONDITION QT_FEATURE_harfbuzz
+ SOURCES
+ text/qharfbuzzng.cpp text/qharfbuzzng_p.h
+ LIBRARIES
+ WrapHarfbuzz::WrapHarfbuzz
+)
+
+# special case begin
+# Replicate what src/3rdparty/harfbuzz-ng/harfbuzz-ng.pro does, which is link CoreText
+# when targeting uikit.
+
+qt_extend_target(Gui CONDITION QT_FEATURE_harfbuzz AND APPLE_UIKIT
+ LIBRARIES
+ ${FWCoreText}
+)
+# special case end
+
+qt_extend_target(Gui CONDITION QT_FEATURE_textodfwriter
+ SOURCES
+ text/qtextodfwriter.cpp text/qtextodfwriter_p.h
+ text/qzip.cpp
+ text/qzipreader_p.h
+ text/qzipwriter_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_textmarkdownreader
+ SOURCES
+ text/qtextmarkdownimporter.cpp text/qtextmarkdownimporter_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_system_textmarkdownreader AND QT_FEATURE_textmarkdownreader
+ PUBLIC_LIBRARIES
+ libmd4c
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_textmarkdownreader AND NOT QT_FEATURE_system_textmarkdownreader
+ SOURCES
+ ../3rdparty/md4c/md4c.c ../3rdparty/md4c/md4c.h
+ INCLUDE_DIRECTORIES
+ ../3rdparty/md4c
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_textmarkdownwriter
+ SOURCES
+ text/qtextmarkdownwriter.cpp text/qtextmarkdownwriter_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_cssparser
+ SOURCES
+ painting/qcssutil.cpp
+ text/qcssparser.cpp text/qcssparser_p.h
+)
+
+qt_extend_target(Gui CONDITION UNIX AND NOT ANDROID AND NOT APPLE_UIKIT AND NOT INTEGRITY AND NOT (TEST_architecture_arch STREQUAL "arm64")
+ DEFINES
+ ENABLE_PIXMAN_DRAWHELPERS
+)
+
+if(UNIX AND NOT ANDROID AND NOT APPLE_UIKIT AND NOT INTEGRITY AND NOT (TEST_architecture_arch STREQUAL "arm64"))
+ qt_add_simd_part(Gui SIMD neon
+ SOURCES
+ ../3rdparty/pixman/pixman-arm-neon-asm.S
+ painting/qdrawhelper_neon_asm.S
+ )
+endif()
+
+qt_extend_target(Gui CONDITION ANDROID AND TEST_architecture_arch STREQUAL x86_64
+ SOURCES
+ painting/qdrawhelper_sse4.cpp
+ painting/qimagescale_sse4.cpp
+ DEFINES
+ QT_COMPILER_SUPPORTS_SSE4_1
+ QT_COMPILER_SUPPORTS_SSE4_2
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_regularexpression
+ SOURCES
+ util/qshadergenerator.cpp util/qshadergenerator_p.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_opengl AND NOT QT_FEATURE_opengles2
+ SOURCES
+ opengl/qopenglfunctions_1_0.cpp opengl/qopenglfunctions_1_0.h
+ opengl/qopenglfunctions_1_1.cpp opengl/qopenglfunctions_1_1.h
+ opengl/qopenglfunctions_1_2.cpp opengl/qopenglfunctions_1_2.h
+ opengl/qopenglfunctions_1_3.cpp opengl/qopenglfunctions_1_3.h
+ opengl/qopenglfunctions_1_4.cpp opengl/qopenglfunctions_1_4.h
+ opengl/qopenglfunctions_1_5.cpp opengl/qopenglfunctions_1_5.h
+ opengl/qopenglfunctions_2_0.cpp opengl/qopenglfunctions_2_0.h
+ opengl/qopenglfunctions_2_1.cpp opengl/qopenglfunctions_2_1.h
+ opengl/qopenglfunctions_3_0.cpp opengl/qopenglfunctions_3_0.h
+ opengl/qopenglfunctions_3_1.cpp opengl/qopenglfunctions_3_1.h
+ opengl/qopenglfunctions_3_2_compatibility.cpp opengl/qopenglfunctions_3_2_compatibility.h
+ opengl/qopenglfunctions_3_2_core.cpp opengl/qopenglfunctions_3_2_core.h
+ opengl/qopenglfunctions_3_3_compatibility.cpp opengl/qopenglfunctions_3_3_compatibility.h
+ opengl/qopenglfunctions_3_3_core.cpp opengl/qopenglfunctions_3_3_core.h
+ opengl/qopenglfunctions_4_0_compatibility.cpp opengl/qopenglfunctions_4_0_compatibility.h
+ opengl/qopenglfunctions_4_0_core.cpp opengl/qopenglfunctions_4_0_core.h
+ opengl/qopenglfunctions_4_1_compatibility.cpp opengl/qopenglfunctions_4_1_compatibility.h
+ opengl/qopenglfunctions_4_1_core.cpp opengl/qopenglfunctions_4_1_core.h
+ opengl/qopenglfunctions_4_2_compatibility.cpp opengl/qopenglfunctions_4_2_compatibility.h
+ opengl/qopenglfunctions_4_2_core.cpp opengl/qopenglfunctions_4_2_core.h
+ opengl/qopenglfunctions_4_3_compatibility.cpp opengl/qopenglfunctions_4_3_compatibility.h
+ opengl/qopenglfunctions_4_3_core.cpp opengl/qopenglfunctions_4_3_core.h
+ opengl/qopenglfunctions_4_4_compatibility.cpp opengl/qopenglfunctions_4_4_compatibility.h
+ opengl/qopenglfunctions_4_4_core.cpp opengl/qopenglfunctions_4_4_core.h
+ opengl/qopenglfunctions_4_5_compatibility.cpp opengl/qopenglfunctions_4_5_compatibility.h
+ opengl/qopenglfunctions_4_5_core.cpp opengl/qopenglfunctions_4_5_core.h
+ opengl/qopenglqueryhelper_p.h
+ opengl/qopengltimerquery.cpp opengl/qopengltimerquery.h
+)
+
+qt_extend_target(Gui CONDITION QT_FEATURE_opengl AND QT_FEATURE_opengles2
+ SOURCES
+ opengl/qopenglfunctions_es2.cpp opengl/qopenglfunctions_es2.h
+)
+
+# special case begin
+# Make Vulkan a global imported target, so that generator expressions involving Vulkan
+# can be correctly evaluated in any sub project directory.
+if(TARGET Vulkan::Vulkan)
+ set_property(TARGET Vulkan::Vulkan PROPERTY IMPORTED_GLOBAL TRUE)
+endif()
+# special case end
+
+qt_extend_target(Gui CONDITION QT_FEATURE_vulkan
+ SOURCES
+ rhi/qrhivulkan.cpp rhi/qrhivulkan_p.h
+ rhi/qrhivulkan_p_p.h
+ vulkan/qplatformvulkaninstance.cpp vulkan/qplatformvulkaninstance.h
+ vulkan/qvulkanfunctions.cpp
+ vulkan/qvulkaninstance.cpp vulkan/qvulkaninstance.h
+ vulkan/qvulkanwindow.cpp vulkan/qvulkanwindow.h vulkan/qvulkanwindow_p.h
+ PUBLIC_LIBRARIES
+ Vulkan::Vulkan_nolink
+)
+
+# special case begin
+# We must always generate syncqt-injected header files,
+# because we added a custom command earlier for those for framework builds.
+set(vulkan_fun "qvulkanfunctions.h")
+set(vulkan_fun_p "qvulkanfunctions_p.h")
+set(vulkan_fun_outputs "vulkan/${vulkan_fun}" "vulkan/${vulkan_fun_p}")
+set(vulkan_fun_command_content COMMAND "${CMAKE_COMMAND}" -E make_directory "vulkan")
+if (QT_FEATURE_vulkan)
+ set(vulkan_fun_p_cpp "qvulkanfunctions_p.cpp")
+ list(APPEND vulkan_fun_outputs "vulkan/${vulkan_fun_p_cpp}")
+
+ list(APPEND vulkan_fun_command_content
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::qvkgen
+ "${CMAKE_CURRENT_SOURCE_DIR}/vulkan/vk.xml"
+ "${PROJECT_SOURCE_DIR}/header.LGPL"
+ "${CMAKE_CURRENT_BINARY_DIR}/vulkan/qvulkanfunctions"
+ DEPENDS vulkan/vk.xml
+ COMMENT "Generating vulkan data"
+ )
+
+ extend_target(Gui
+ SOURCES
+ "${CMAKE_CURRENT_BINARY_DIR}/vulkan/${vulkan_fun}"
+ "${CMAKE_CURRENT_BINARY_DIR}/vulkan/${vulkan_fun_p}"
+ "${CMAKE_CURRENT_BINARY_DIR}/vulkan/${vulkan_fun_p_cpp}"
+ )
+else()
+ foreach(file ${vulkan_fun_outputs})
+ list(APPEND vulkan_fun_command_content
+ COMMAND "${CMAKE_COMMAND}" -E touch "${file}")
+ endforeach()
+endif()
+add_custom_command(
+ OUTPUT ${vulkan_fun_outputs}
+ ${vulkan_fun_command_content}
+ WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"
+)
+# special case end
+
+#### Keys ignored in scope 68:.:vulkan:vulkan/vulkan.pri:QT_FEATURE_vkgen:
+# QMAKE_EXTRA_COMPILERS = "qvkgen_h" "qvkgen_ph" "qvkgen_pimpl"
+# QMAKE_QVKGEN_INPUT = "vulkan/vk.xml"
+# QMAKE_QVKGEN_LICENSE_HEADER = "$$QT_SOURCE_TREE/header.LGPL"
+# qvkgen_h.commands = "$$QMAKE_QVKGEN" "${QMAKE_FILE_IN}" "$$shell_quote($$QMAKE_QVKGEN_LICENSE_HEADER)" "${QMAKE_FILE_OUT_PATH}/${QMAKE_FILE_OUT_BASE}"
+# qvkgen_h.input = "QMAKE_QVKGEN_INPUT"
+# qvkgen_h.output = "$$OUT_PWD/vulkan/qvulkanfunctions.h"
+# qvkgen_ph.commands = "$$escape_expand(\\n)"
+# qvkgen_ph.depends = "$$OUT_PWD/vulkan/qvulkanfunctions.h"
+# qvkgen_ph.input = "QMAKE_QVKGEN_INPUT"
+# qvkgen_ph.output = "$$OUT_PWD/vulkan/qvulkanfunctions_p.h"
+# qvkgen_pimpl.commands = "$$escape_expand(\\n)"
+# qvkgen_pimpl.depends = "$$OUT_PWD/vulkan/qvulkanfunctions_p.h"
+# qvkgen_pimpl.input = "QMAKE_QVKGEN_INPUT"
+# qvkgen_pimpl.output = "$$OUT_PWD/vulkan/qvulkanfunctions_p.cpp"
+
+#### Keys ignored in scope 81:.:vulkan:vulkan/vulkan.pri:QT_FEATURE_vulkan:
+# qvkgen_h.variable_out = "HEADERS"
+
+#### Keys ignored in scope 82:.:vulkan:vulkan/vulkan.pri:else:
+# qvkgen_h.CONFIG = "target_predeps" "no_link"
+
+qt_extend_target(Gui CONDITION WASM
+ SOURCES
+ platform/wasm/qwasmlocalfileaccess.cpp platform/wasm/qwasmlocalfileaccess_p.h
+)
+
+qt_extend_target(Gui CONDITION NOT GCC OR NOT QT_COMPILER_VERSION_MAJOR STREQUAL 5
+ SOURCES
+ painting/qdrawhelper.cpp
+ NO_PCH_SOURCES
+ "painting/qdrawhelper.cpp"
+)
+
+
+qt_create_tracepoints(Gui qtgui.tracepoints)
+qt_add_docs(Gui
+ doc/qtgui.qdocconf
+)
+
diff --git a/src/gui/Qt5GuiConfigExtras.cmake.in b/src/gui/Qt5GuiConfigExtras.cmake.in
deleted file mode 100644
index 84dbbfebd4..0000000000
--- a/src/gui/Qt5GuiConfigExtras.cmake.in
+++ /dev/null
@@ -1,193 +0,0 @@
-
-!!IF !isEmpty(CMAKE_ANGLE_EGL_DLL_RELEASE)
-
-!!IF isEmpty(CMAKE_INCLUDE_DIR_IS_ABSOLUTE)
-set(Qt5Gui_EGL_INCLUDE_DIRS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$$CMAKE_INCLUDE_DIR/QtANGLE\")
-!!ELSE
-set(Qt5Gui_EGL_INCLUDE_DIRS \"$$CMAKE_INCLUDE_DIR/QtANGLE\")
-!!ENDIF
-
-_qt5_Gui_check_file_exists(${Qt5Gui_EGL_INCLUDE_DIRS})
-
-list(APPEND Qt5Gui_INCLUDE_DIRS ${Qt5Gui_EGL_INCLUDE_DIRS})
-set_property(TARGET Qt5::Gui APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${Qt5Gui_EGL_INCLUDE_DIRS})
-set(Qt5Gui_OPENGL_INCLUDE_DIRS ${Qt5Gui_EGL_INCLUDE_DIRS})
-
-macro(_populate_qt5gui_gl_target_properties TargetName Configuration LIB_LOCATION IMPLIB_LOCATION)
- set_property(TARGET Qt5::${TargetName} APPEND PROPERTY IMPORTED_CONFIGURATIONS ${Configuration})
-
-!!IF isEmpty(CMAKE_DLL_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Gui_install_prefix}/$${CMAKE_DLL_DIR}${LIB_LOCATION}\")
-!!ELSE
- set(imported_location \"$${CMAKE_DLL_DIR}${LIB_LOCATION}\")
-!!ENDIF
-
-!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- set(imported_implib \"${_qt5Gui_install_prefix}/$${CMAKE_LIB_DIR}${IMPLIB_LOCATION}\")
-!!ELSE
- set(imported_implib \"$${CMAKE_LIB_DIR}${IMPLIB_LOCATION}\")
-!!ENDIF
-
- set_target_properties(Qt5::${TargetName} PROPERTIES
- \"IMPORTED_LOCATION_${Configuration}\" ${imported_location}
- \"IMPORTED_IMPLIB_${Configuration}\" ${imported_implib}
- )
-endmacro()
-
-add_library(Qt5::Gui_EGL SHARED IMPORTED)
-_populate_qt5gui_gl_target_properties(Gui_EGL RELEASE $${CMAKE_ANGLE_EGL_DLL_RELEASE} $${CMAKE_ANGLE_EGL_IMPLIB_RELEASE})
-add_library(Qt5::Gui_GLESv2 SHARED IMPORTED)
-_populate_qt5gui_gl_target_properties(Gui_GLESv2 RELEASE $${CMAKE_ANGLE_GLES2_DLL_RELEASE} $${CMAKE_ANGLE_GLES2_IMPLIB_RELEASE})
-
-set_property(TARGET Qt5::Gui_EGL APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${Qt5Gui_EGL_INCLUDE_DIRS})
-set_property(TARGET Qt5::Gui_GLESv2 APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${Qt5Gui_OPENGL_INCLUDE_DIRS})
-
-!!IF !isEmpty(CMAKE_DEBUG_TYPE)
-_populate_qt5gui_gl_target_properties(Gui_EGL DEBUG $${CMAKE_ANGLE_EGL_DLL_DEBUG} $${CMAKE_ANGLE_EGL_IMPLIB_DEBUG})
-_populate_qt5gui_gl_target_properties(Gui_GLESv2 DEBUG $${CMAKE_ANGLE_GLES2_DLL_DEBUG} $${CMAKE_ANGLE_GLES2_IMPLIB_DEBUG})
-!!ENDIF
-
-set(Qt5Gui_EGL_LIBRARIES Qt5::Gui_EGL)
-set(Qt5Gui_OPENGL_LIBRARIES Qt5::Gui_GLESv2)
-
-!!ELSE
-
-!!IF !isEmpty(CMAKE_GL_INCDIRS)
-
-set(_GL_INCDIRS $$CMAKE_GL_INCDIRS)
-find_path(_qt5gui_OPENGL_INCLUDE_DIR $$CMAKE_GL_HEADER_NAME
- PATHS ${_GL_INCDIRS}
-)
-if (NOT _qt5gui_OPENGL_INCLUDE_DIR)
- message(FATAL_ERROR \"Failed to find \\\"$$CMAKE_GL_HEADER_NAME\\\" in \\\"${_GL_INCDIRS}\\\".\")
-endif()
-unset(_GL_INCDIRS)
-
-# Don\'t check for existence of the "_qt5gui_OPENGL_INCLUDE_DIR" because it is
-# optional.
-
-list(APPEND Qt5Gui_INCLUDE_DIRS ${_qt5gui_OPENGL_INCLUDE_DIR})
-set_property(TARGET Qt5::Gui APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${_qt5gui_OPENGL_INCLUDE_DIR})
-
-unset(_qt5gui_OPENGL_INCLUDE_DIR CACHE)
-
-!!ENDIF
-
-macro(_qt5gui_find_extra_libs Name Libs LibDir IncDirs)
- set(Qt5Gui_${Name}_LIBRARIES)
-!!IF !mac
- set(Qt5Gui_${Name}_INCLUDE_DIRS ${IncDirs})
-!!ELSE
- foreach(_dir ${IncDirs})
- if (EXISTS ${_dir})
- list(APPEND Qt5Gui_${Name}_INCLUDE_DIRS ${_dir})
- else()
- find_path(_actual_dir ${_dir}) # Look in sdk directories
- if (_actual_dir)
- list(APPEND Qt5Gui_${Name}_INCLUDE_DIRS ${_actual_dir})
- endif()
- unset(_actual_dir CACHE)
- endif()
- endforeach()
-!!ENDIF
- foreach(_lib ${Libs})
- if (IS_ABSOLUTE ${_lib})
- get_filename_component(_libFile ${_lib} NAME_WE)
- if (_libFile MATCHES \"^${CMAKE_SHARED_LIBRARY_PREFIX}(.*)\")
- set(_libFile ${CMAKE_MATCH_1})
- endif()
- else()
- set(_libFile ${_lib})
- endif()
-
- string(REGEX REPLACE "[^_A-Za-z0-9]" "_" _cmake_lib_name ${_libFile})
- if (NOT TARGET Qt5::Gui_${_cmake_lib_name} AND NOT _Qt5Gui_${_cmake_lib_name}_LIBRARY_DONE)
- if (IS_ABSOLUTE ${_lib})
- set(Qt5Gui_${_cmake_lib_name}_LIBRARY ${_lib})
- else()
- find_library(Qt5Gui_${_cmake_lib_name}_LIBRARY ${_lib}
-!!IF !isEmpty(CROSS_COMPILE)
- PATHS \"${LibDir}\"
-!!IF !mac
- NO_DEFAULT_PATH
-!!ENDIF
-!!ENDIF
- )
- endif()
-!!IF mac
- set(Qt5Gui_${_cmake_lib_name}_LIBRARY "${Qt5Gui_${_cmake_lib_name}_LIBRARY}/${_lib}")
- if (NOT EXISTS "${Qt5Gui_${_cmake_lib_name}_LIBRARY}")
- set(Qt5Gui_${_cmake_lib_name}_LIBRARY)
- endif()
-!!ENDIF
- if (NOT Qt5Gui_${_cmake_lib_name}_LIBRARY)
- # The above find_library call doesn\'t work for finding
- # libraries in Windows SDK paths outside of the proper
- # environment, even if the libraries are present. In other
- # cases it is OK for the libraries to not be found
- # because they are optional dependencies of Qt5Gui, needed
- # only if the qopengl.h header is used.
- # We try to find the libraries in the first place because Qt may be
- # compiled with another set of GL libraries (such as coming
- # from ANGLE). The point of these find calls is to try to
- # find the same binaries as Qt is compiled with (as they are
- # in the interface of QtGui), so an effort is made to do so
- # above with paths known to qmake.
- set(_Qt5Gui_${_cmake_lib_name}_LIBRARY_DONE TRUE)
- unset(Qt5Gui_${_cmake_lib_name}_LIBRARY CACHE)
- else()
- add_library(Qt5::Gui_${_cmake_lib_name} SHARED IMPORTED)
- set_property(TARGET Qt5::Gui_${_cmake_lib_name} APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${Qt5Gui_${Name}_INCLUDE_DIRS})
-
- set_property(TARGET Qt5::Gui_${_cmake_lib_name} APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)
- _qt5_Gui_check_file_exists(\"${Qt5Gui_${_cmake_lib_name}_LIBRARY}\")
- set_property(TARGET Qt5::Gui_${_cmake_lib_name} PROPERTY IMPORTED_LOCATION_RELEASE \"${Qt5Gui_${_cmake_lib_name}_LIBRARY}\")
-
-!!IF !isEmpty(CMAKE_WINDOWS_BUILD)
- set_property(TARGET Qt5::Gui_${_cmake_lib_name} PROPERTY IMPORTED_IMPLIB_RELEASE \"${Qt5Gui_${_cmake_lib_name}_LIBRARY}\")
-!!ENDIF
- unset(Qt5Gui_${_cmake_lib_name}_LIBRARY CACHE)
-
- find_library(Qt5Gui_${_cmake_lib_name}_LIBRARY_DEBUG ${_lib}d
- PATHS \"${LibDir}\"
-!!IF !mac
- NO_DEFAULT_PATH
-!!ENDIF
- )
- if (Qt5Gui_${_cmake_lib_name}_LIBRARY_DEBUG)
- set_property(TARGET Qt5::Gui_${_cmake_lib_name} APPEND PROPERTY IMPORTED_CONFIGURATIONS DEBUG)
- _qt5_Gui_check_file_exists(\"${Qt5Gui_${_cmake_lib_name}_LIBRARY_DEBUG}\")
- set_property(TARGET Qt5::Gui_${_cmake_lib_name} PROPERTY IMPORTED_LOCATION_DEBUG \"${Qt5Gui_${_cmake_lib_name}_LIBRARY_DEBUG}\")
-!!IF !isEmpty(CMAKE_WINDOWS_BUILD)
- set_property(TARGET Qt5::Gui_${_cmake_lib_name} PROPERTY IMPORTED_IMPLIB_DEBUG \"${Qt5Gui_${_cmake_lib_name}_LIBRARY_DEBUG}\")
-!!ENDIF
- endif()
- unset(Qt5Gui_${_cmake_lib_name}_LIBRARY_DEBUG CACHE)
- list(APPEND Qt5Gui_${Name}_LIBRARIES Qt5::Gui_${_cmake_lib_name})
- endif()
- endif()
- endforeach()
-endmacro()
-
-
-!!IF !isEmpty(CMAKE_EGL_LIBS)
-_qt5gui_find_extra_libs(EGL \"$$CMAKE_EGL_LIBS\" \"$$CMAKE_EGL_LIBDIR\" \"$$CMAKE_EGL_INCDIRS\")
-!!ENDIF
-
-!!IF !isEmpty(CMAKE_OPENGL_LIBS)
-_qt5gui_find_extra_libs(OPENGL \"$$CMAKE_OPENGL_LIBS\" \"$$CMAKE_OPENGL_LIBDIR\" \"$$CMAKE_OPENGL_INCDIRS\")
-
-!!ENDIF
-
-!!ENDIF
-
-set(Qt5Gui_OPENGL_IMPLEMENTATION $$CMAKE_QT_OPENGL_IMPLEMENTATION)
-
-get_target_property(_configs Qt5::Gui IMPORTED_CONFIGURATIONS)
-foreach(_config ${_configs})
- set_property(TARGET Qt5::Gui APPEND PROPERTY
- IMPORTED_LINK_DEPENDENT_LIBRARIES_${_config}
- ${Qt5Gui_EGL_LIBRARIES} ${Qt5Gui_OPENGL_LIBRARIES}
- )
-endforeach()
-unset(_configs)
diff --git a/src/gui/configure.cmake b/src/gui/configure.cmake
new file mode 100644
index 0000000000..11723b785b
--- /dev/null
+++ b/src/gui/configure.cmake
@@ -0,0 +1,1106 @@
+
+
+#### Inputs
+
+# input freetype
+set(INPUT_freetype "undefined" CACHE STRING "")
+set_property(CACHE INPUT_freetype PROPERTY STRINGS undefined no qt system)
+
+# input libjpeg
+set(INPUT_libjpeg "undefined" CACHE STRING "")
+set_property(CACHE INPUT_libjpeg PROPERTY STRINGS undefined no qt system)
+
+# input libmd4c
+set(INPUT_libmd4c "undefined" CACHE STRING "")
+set_property(CACHE INPUT_libmd4c PROPERTY STRINGS undefined no qt system)
+
+# input libpng
+set(INPUT_libpng "undefined" CACHE STRING "")
+set_property(CACHE INPUT_libpng PROPERTY STRINGS undefined no qt system)
+
+
+
+#### Libraries
+
+qt_find_package(ATSPI2 PROVIDED_TARGETS PkgConfig::ATSPI2)
+qt_find_package(DirectFB PROVIDED_TARGETS PkgConfig::DirectFB)
+qt_find_package(Libdrm PROVIDED_TARGETS Libdrm::Libdrm)
+qt_find_package(EGL PROVIDED_TARGETS EGL::EGL)
+qt_find_package(WrapFreetype PROVIDED_TARGETS WrapFreetype::WrapFreetype)
+set_package_properties(WrapFreetype PROPERTIES TYPE REQUIRED)
+qt_find_package(Fontconfig PROVIDED_TARGETS Fontconfig::Fontconfig)
+qt_find_package(gbm PROVIDED_TARGETS gbm::gbm)
+qt_find_package(WrapHarfbuzz PROVIDED_TARGETS WrapHarfbuzz::WrapHarfbuzz)
+qt_find_package(Libinput PROVIDED_TARGETS Libinput::Libinput)
+qt_find_package(JPEG PROVIDED_TARGETS JPEG::JPEG)
+qt_find_package(PNG PROVIDED_TARGETS PNG::PNG)
+qt_find_package(Mtdev PROVIDED_TARGETS PkgConfig::Mtdev)
+qt_find_package(OpenGL PROVIDED_TARGETS OpenGL::GL)
+qt_find_package(GLESv2 PROVIDED_TARGETS GLESv2::GLESv2)
+qt_find_package(Tslib PROVIDED_TARGETS PkgConfig::Tslib)
+qt_find_package(Vulkan PROVIDED_TARGETS Vulkan::Vulkan)
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(Wayland PROVIDED_TARGETS Wayland::Server)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(X11 PROVIDED_TARGETS X11::XCB)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(X11 PROVIDED_TARGETS ${X11_SM_LIB} ${X11_ICE_LIB})
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB 1.9 PROVIDED_TARGETS XCB::XCB)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS ICCCM PROVIDED_TARGETS XCB::ICCCM)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS IMAGE PROVIDED_TARGETS XCB::IMAGE)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS KEYSYMS PROVIDED_TARGETS XCB::KEYSYMS)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS RENDERUTIL PROVIDED_TARGETS XCB::RENDERUTIL)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS RANDR PROVIDED_TARGETS XCB::RANDR)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS SHAPE PROVIDED_TARGETS XCB::SHAPE)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS SHM PROVIDED_TARGETS XCB::SHM)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS SYNC PROVIDED_TARGETS XCB::SYNC)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS XFIXES PROVIDED_TARGETS XCB::XFIXES)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS XINERAMA PROVIDED_TARGETS XCB::XINERAMA)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS XKB PROVIDED_TARGETS XCB::XKB)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS RENDER PROVIDED_TARGETS XCB::RENDER)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS GLX PROVIDED_TARGETS XCB::GLX)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XCB COMPONENTS XINPUT PROVIDED_TARGETS XCB::XINPUT)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XKB 0.4.1 PROVIDED_TARGETS XKB::XKB)
+endif()
+if((LINUX) OR QT_FIND_ALL_PACKAGES_ALWAYS)
+ qt_find_package(XRender PROVIDED_TARGETS PkgConfig::XRender)
+endif()
+
+
+#### Tests
+
+# angle_d3d11_qdtd
+qt_config_compile_test(angle_d3d11_qdtd
+ LABEL "D3D11_QUERY_DATA_TIMESTAMP_DISJOINT"
+ CODE
+"
+#include <d3d11.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+D3D11_QUERY_DATA_TIMESTAMP_DISJOINT qdtd;
+(void) qdtd;
+ /* END TEST: */
+ return 0;
+}
+")
+
+# drm_atomic
+qt_config_compile_test(drm_atomic
+ LABEL "DRM Atomic API"
+ LIBRARIES
+ Libdrm::Libdrm
+ CODE
+"#include <stdlib.h>
+#include <stdint.h>
+extern \"C\" {
+#include <xf86drmMode.h>
+#include <xf86drm.h>
+}
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+drmModeAtomicReq *request;
+ /* END TEST: */
+ return 0;
+}
+")
+
+# egl-x11
+qt_config_compile_test(egl_x11
+ LABEL "EGL on X11"
+ LIBRARIES
+ EGL::EGL
+ X11::XCB
+ CODE
+"// Check if EGL is compatible with X. Some EGL implementations, typically on
+// embedded devices, are not intended to be used together with X. EGL support
+// has to be disabled in plugins like xcb in this case since the native display,
+// window and pixmap types will be different than what an X-based platform
+// plugin would expect.
+#include <EGL/egl.h>
+#include <X11/Xlib.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+Display *dpy = EGL_DEFAULT_DISPLAY;
+EGLNativeDisplayType egldpy = XOpenDisplay(\"\");
+dpy = egldpy;
+EGLNativeWindowType w = XCreateWindow(dpy, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+XDestroyWindow(dpy, w);
+XCloseDisplay(dpy);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# egl-brcm
+qt_config_compile_test(egl_brcm
+ LABEL "Broadcom EGL (Raspberry Pi)"
+ LIBRARIES
+ EGL::EGL
+ CODE
+"
+#include <EGL/egl.h>
+#include <bcm_host.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+vc_dispmanx_display_open(0);
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: use: unmapped library: bcm_host
+)
+
+# egl-egldevice
+qt_config_compile_test(egl_egldevice
+ LABEL "EGLDevice"
+ LIBRARIES
+ EGL::EGL
+ CODE
+"
+#include <EGL/egl.h>
+#include <EGL/eglext.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+EGLDeviceEXT device = 0;
+EGLStreamKHR stream = 0;
+EGLOutputLayerEXT layer = 0;
+(void) EGL_DRM_CRTC_EXT;
+ /* END TEST: */
+ return 0;
+}
+")
+
+# egl-mali
+qt_config_compile_test(egl_mali
+ LABEL "Mali EGL"
+ LIBRARIES
+ EGL::EGL
+ CODE
+"
+#include <EGL/fbdev_window.h>
+#include <EGL/egl.h>
+#include <GLES2/gl2.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+fbdev_window *w = 0;
+ /* END TEST: */
+ return 0;
+}
+")
+
+# egl-mali-2
+qt_config_compile_test(egl_mali_2
+ LABEL "Mali 2 EGL"
+ LIBRARIES
+ EGL::EGL
+ CODE
+"
+#include <EGL/egl.h>
+#include <GLES2/gl2.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+mali_native_window *w = 0;
+ /* END TEST: */
+ return 0;
+}
+")
+
+# egl-viv
+qt_config_compile_test(egl_viv
+ LABEL "i.Mx6 EGL"
+ LIBRARIES
+ EGL::EGL
+ CODE
+"
+#include <EGL/egl.h>
+#include <EGL/eglvivante.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+#ifdef __INTEGRITY
+fbGetDisplay();
+#else
+// Do not rely on fbGetDisplay(), since the signature has changed over time.
+// Stick to fbGetDisplayByIndex().
+fbGetDisplayByIndex(0);
+#endif
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: qmake: ['DEFINES += EGL_API_FB=1', '!integrity: DEFINES += LINUX=1']
+)
+
+# egl-openwfd
+qt_config_compile_test(egl_openwfd
+ LABEL "OpenWFD EGL"
+ LIBRARIES
+ EGL::EGL
+ CODE
+"
+#include <wfd.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+wfdEnumerateDevices(nullptr, 0, nullptr);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# egl-rcar
+qt_config_compile_test(egl_rcar
+ LABEL "RCAR EGL"
+ LIBRARIES
+ EGL::EGL
+ GLESv2::GLESv2
+ CODE
+"
+#include <EGL/egl.h>
+extern \"C\" {
+extern unsigned long PVRGrfxServerInit(void);
+}
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+PVRGrfxServerInit();
+ /* END TEST: */
+ return 0;
+}
+")
+
+# evdev
+qt_config_compile_test(evdev
+ LABEL "evdev"
+ CODE
+"#if defined(__FreeBSD__)
+# include <dev/evdev/input.h>
+#else
+# include <linux/input.h>
+# include <linux/kd.h>
+#endif
+enum {
+ e1 = ABS_PRESSURE,
+ e2 = ABS_X,
+ e3 = REL_X,
+ e4 = SYN_REPORT,
+};
+
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+input_event buf[32];
+(void) buf;
+ /* END TEST: */
+ return 0;
+}
+")
+
+# integrityfb
+qt_config_compile_test(integrityfb
+ LABEL "INTEGRITY framebuffer"
+ CODE
+"
+#include <device/fbdriver.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+FBDriver *driver = 0;
+ /* END TEST: */
+ return 0;
+}
+")
+
+# linuxfb
+qt_config_compile_test(linuxfb
+ LABEL "LinuxFB"
+ CODE
+"
+#include <linux/fb.h>
+#include <sys/kd.h>
+#include <sys/ioctl.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+fb_fix_screeninfo finfo;
+fb_var_screeninfo vinfo;
+int fd = 3;
+ioctl(fd, FBIOGET_FSCREENINFO, &finfo);
+ioctl(fd, FBIOGET_VSCREENINFO, &vinfo);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# opengles3
+qt_config_compile_test(opengles3
+ LABEL "OpenGL ES 3.0"
+ LIBRARIES
+ GLESv2::GLESv2
+ CODE
+"#ifdef __APPLE__
+# include <OpenGLES/ES3/gl.h>
+#else
+# define GL_GLEXT_PROTOTYPES
+# include <GLES3/gl3.h>
+#endif
+
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+static GLfloat f[6];
+glGetStringi(GL_EXTENSIONS, 0);
+glReadBuffer(GL_COLOR_ATTACHMENT1);
+glUniformMatrix2x3fv(0, 0, GL_FALSE, f);
+glMapBufferRange(GL_ARRAY_BUFFER, 0, 0, GL_MAP_READ_BIT);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# opengles31
+qt_config_compile_test(opengles31
+ LABEL "OpenGL ES 3.1"
+ LIBRARIES
+ GLESv2::GLESv2
+ CODE
+"
+#include <GLES3/gl31.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+glDispatchCompute(1, 1, 1);
+glProgramUniform1i(0, 0, 0);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# opengles32
+qt_config_compile_test(opengles32
+ LABEL "OpenGL ES 3.2"
+ LIBRARIES
+ GLESv2::GLESv2
+ CODE
+"
+#include <GLES3/gl32.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+glFramebufferTexture(GL_TEXTURE_2D, GL_DEPTH_STENCIL_ATTACHMENT, 1, 0);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# xcb_syslibs
+qt_config_compile_test(xcb_syslibs
+ LABEL "XCB (extensions)"
+ LIBRARIES
+ XCB::ICCCM
+ XCB::IMAGE
+ XCB::KEYSYMS
+ XCB::RANDR
+ XCB::RENDER
+ XCB::RENDERUTIL
+ XCB::SHAPE
+ XCB::SHM
+ XCB::SYNC
+ XCB::XFIXES
+ XCB::XINERAMA
+ XCB::XKB
+ XCB::XCB
+ CODE
+"// xkb.h is using a variable called 'explicit', which is a reserved keyword in C++
+#define explicit dont_use_cxx_explicit
+#include <xcb/xcb.h>
+#include <xcb/xcb_image.h>
+#include <xcb/xcb_keysyms.h>
+#include <xcb/randr.h>
+#include <xcb/render.h>
+#include <xcb/shape.h>
+#include <xcb/shm.h>
+#include <xcb/sync.h>
+#include <xcb/xfixes.h>
+#include <xcb/xinerama.h>
+#include <xcb/xcb_icccm.h>
+#include <xcb/xcb_renderutil.h>
+#include <xcb/xkb.h>
+#undef explicit
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+int primaryScreen = 0;
+xcb_connection_t *c = xcb_connect(\"\", &primaryScreen);
+/* RENDER */
+xcb_generic_error_t *error = nullptr;
+xcb_render_query_pict_formats_cookie_t formatsCookie =
+ xcb_render_query_pict_formats(c);
+xcb_render_query_pict_formats_reply_t *formatsReply =
+ xcb_render_query_pict_formats_reply(c, formatsCookie, &error);
+/* RENDERUTIL: xcb_renderutil.h include won't compile unless version >= 0.3.9 */
+xcb_render_util_find_standard_format(nullptr, XCB_PICT_STANDARD_ARGB_32);
+/* XKB: This takes more arguments in xcb-xkb < 1.11 */
+xcb_xkb_get_kbd_by_name_replies_key_names_value_list_sizeof(nullptr, 0, 0, 0, 0, 0, 0, 0, 0);
+ /* END TEST: */
+ return 0;
+}
+")
+
+
+
+#### Features
+
+qt_feature("accessibility-atspi-bridge" PUBLIC PRIVATE
+ LABEL "ATSPI Bridge"
+ CONDITION QT_FEATURE_accessibility AND QT_FEATURE_xcb AND QT_FEATURE_dbus AND ATSPI2_FOUND
+)
+qt_feature_definition("accessibility-atspi-bridge" "QT_NO_ACCESSIBILITY_ATSPI_BRIDGE" NEGATE VALUE "1")
+qt_feature("angle" PUBLIC
+ LABEL "ANGLE"
+ AUTODETECT QT_FEATURE_opengles2 OR QT_FEATURE_opengl_dynamic
+ CONDITION NOT QT_FEATURE_opengl_desktop AND QT_FEATURE_dxguid AND tests.fxc AND ( QT_FEATURE_direct3d9 OR ( WINRT AND QT_FEATURE_direct3d11 AND libs.d3dcompiler ) ) OR FIXME
+)
+qt_feature_definition("angle" "QT_OPENGL_ES_2_ANGLE")
+qt_feature("angle_d3d11_qdtd" PRIVATE
+ LABEL "D3D11_QUERY_DATA_TIMESTAMP_DISJOINT"
+ CONDITION QT_FEATURE_angle AND TEST_angle_d3d11_qdtd
+)
+qt_feature("combined-angle-lib" PUBLIC
+ LABEL "Combined ANGLE Library"
+ AUTODETECT OFF
+ CONDITION QT_FEATURE_angle
+)
+qt_feature("directfb" PRIVATE
+ SECTION "Platform plugins"
+ LABEL "DirectFB"
+ AUTODETECT OFF
+ CONDITION DirectFB_FOUND
+)
+qt_feature("directwrite" PRIVATE
+ LABEL "DirectWrite"
+ CONDITION libs.dwrite OR FIXME
+ EMIT_IF WIN32
+)
+qt_feature("directwrite1" PRIVATE
+ LABEL "DirectWrite 1"
+ CONDITION libs.dwrite_1 OR FIXME
+ EMIT_IF WIN32
+)
+qt_feature("directwrite2" PRIVATE
+ LABEL "DirectWrite 2"
+ CONDITION QT_FEATURE_directwrite1 AND libs.dwrite_2 OR FIXME
+ EMIT_IF WIN32
+)
+qt_feature("dxguid" PRIVATE
+ LABEL "DirectX GUID"
+ CONDITION WIN32 AND libs.dxguid OR FIXME
+)
+qt_feature("direct3d9" PRIVATE
+ LABEL "Direct 3D 9"
+ CONDITION WIN32 AND NOT WINRT AND libs.d3d9 OR FIXME
+)
+qt_feature("dxgi" PRIVATE
+ LABEL "DirectX GI"
+ CONDITION WIN32 AND libs.dxgi OR FIXME
+)
+qt_feature("dxgi1_2" PRIVATE
+ LABEL "DirectX GI 1.2"
+ CONDITION QT_FEATURE_dxgi AND libs.dxgi1_2 OR FIXME
+)
+qt_feature("direct3d11" PRIVATE
+ LABEL "Direct 3D 11"
+ CONDITION QT_FEATURE_dxgi AND libs.d3d11 OR FIXME
+)
+qt_feature("direct3d11_1" PRIVATE
+ LABEL "Direct 3D 11.1"
+ CONDITION QT_FEATURE_direct3d11 AND QT_FEATURE_dxgi1_2 AND libs.d3d11_1 OR FIXME
+)
+qt_feature("direct2d" PRIVATE
+ LABEL "Direct 2D"
+ CONDITION WIN32 AND NOT WINRT AND QT_FEATURE_direct3d11 AND libs.d2d1 OR FIXME
+)
+qt_feature("direct2d1_1" PRIVATE
+ LABEL "Direct 2D 1.1"
+ CONDITION QT_FEATURE_direct2d AND libs.d2d1_1 OR FIXME
+)
+qt_feature("evdev" PRIVATE
+ LABEL "evdev"
+ CONDITION QT_FEATURE_thread AND TEST_evdev
+)
+qt_feature("freetype" PUBLIC PRIVATE
+ SECTION "Fonts"
+ LABEL "FreeType"
+ PURPOSE "Supports the FreeType 2 font engine (and its supported font formats)."
+)
+qt_feature_definition("freetype" "QT_NO_FREETYPE" NEGATE VALUE "1")
+qt_feature("fontconfig" PUBLIC PRIVATE
+ LABEL "Fontconfig"
+ AUTODETECT NOT APPLE
+ CONDITION NOT MSVC AND ON AND FONTCONFIG_FOUND
+)
+qt_feature_definition("fontconfig" "QT_NO_FONTCONFIG" NEGATE VALUE "1")
+qt_feature("gbm"
+ LABEL "GBM"
+ CONDITION gbm_FOUND
+)
+qt_feature_config("gbm" QMAKE_PUBLIC_QT_CONFIG)
+qt_feature("harfbuzz" PUBLIC PRIVATE
+ LABEL "HarfBuzz"
+ CONDITION harfbuzz_FOUND
+)
+qt_feature_definition("harfbuzz" "QT_NO_HARFBUZZ" NEGATE VALUE "1")
+qt_feature("qqnx_imf" PRIVATE
+ LABEL "IMF"
+ CONDITION libs.imf OR FIXME
+ EMIT_IF QNX
+)
+qt_feature("integrityfb" PRIVATE
+ SECTION "Platform plugins"
+ LABEL "INTEGRITY framebuffer"
+ CONDITION INTEGRITY AND TEST_integrityfb
+)
+qt_feature("kms" PRIVATE
+ LABEL "KMS"
+ CONDITION Libdrm_FOUND
+)
+qt_feature_config("kms" QMAKE_PUBLIC_QT_CONFIG)
+qt_feature("drm_atomic" PRIVATE
+ LABEL "DRM Atomic API"
+ CONDITION Libdrm_FOUND AND TEST_drm_atomic
+)
+qt_feature("libinput" PRIVATE
+ LABEL "libinput"
+ CONDITION QT_FEATURE_libudev AND Libinput_FOUND
+)
+qt_feature("integrityhid" PRIVATE
+ LABEL "INTEGRITY HID"
+ CONDITION INTEGRITY AND libs.integrityhid OR FIXME
+)
+qt_feature("libinput-axis-api" PRIVATE
+ LABEL "axis API in libinput"
+ CONDITION QT_FEATURE_libinput AND ON
+)
+qt_feature("lgmon"
+ LABEL "lgmon"
+ CONDITION libs.lgmon OR FIXME
+ EMIT_IF QNX
+)
+qt_feature_config("lgmon" QMAKE_PRIVATE_CONFIG)
+qt_feature("linuxfb" PRIVATE
+ SECTION "Platform plugins"
+ LABEL "LinuxFB"
+ CONDITION TEST_linuxfb AND QT_FEATURE_regularexpression
+)
+qt_feature("vsp2" PRIVATE
+ LABEL "VSP2"
+ AUTODETECT OFF
+ CONDITION libs.v4l2 OR FIXME
+)
+qt_feature("vnc" PRIVATE
+ SECTION "Platform plugins"
+ LABEL "VNC"
+ CONDITION ( UNIX AND NOT ANDROID AND NOT APPLE ) AND ( QT_FEATURE_regularexpression AND QT_FEATURE_network )
+)
+qt_feature("mtdev" PRIVATE
+ LABEL "mtdev"
+ CONDITION Mtdev_FOUND
+)
+qt_feature("opengles2" PUBLIC
+ LABEL "OpenGL ES 2.0"
+ CONDITION NOT WIN32 AND ( NOT APPLE_WATCHOS AND NOT QT_FEATURE_opengl_desktop AND GLESv2_FOUND )
+ ENABLE INPUT_opengl STREQUAL 'es2' OR INPUT_angle STREQUAL 'yes'
+ DISABLE INPUT_opengl STREQUAL 'desktop' OR INPUT_opengl STREQUAL 'dynamic' OR INPUT_opengl STREQUAL 'no'
+)
+qt_feature_definition("opengles2" "QT_OPENGL_ES")
+qt_feature_definition("opengles2" "QT_OPENGL_ES_2")
+qt_feature_config("opengles2" QMAKE_PUBLIC_QT_CONFIG)
+qt_feature("opengles3" PUBLIC
+ LABEL "OpenGL ES 3.0"
+ CONDITION QT_FEATURE_opengles2 AND NOT QT_FEATURE_angle AND TEST_opengles3 AND NOT WASM
+)
+qt_feature_definition("opengles3" "QT_OPENGL_ES_3")
+qt_feature("opengles31" PUBLIC
+ LABEL "OpenGL ES 3.1"
+ CONDITION QT_FEATURE_opengles3 AND TEST_opengles31
+)
+qt_feature_definition("opengles31" "QT_OPENGL_ES_3_1")
+qt_feature("opengles32" PUBLIC
+ LABEL "OpenGL ES 3.2"
+ CONDITION QT_FEATURE_opengles31 AND TEST_opengles32
+)
+qt_feature_definition("opengles32" "QT_OPENGL_ES_3_2")
+qt_feature("opengl-desktop"
+ LABEL "Desktop OpenGL"
+ CONDITION ( WIN32 AND NOT WINRT AND NOT QT_FEATURE_opengles2 AND ( MSVC OR OpenGL_OpenGL_FOUND ) ) OR ( NOT APPLE_WATCHOS AND NOT WIN32 AND NOT WASM AND OpenGL_OpenGL_FOUND )
+ ENABLE INPUT_opengl STREQUAL 'desktop'
+ DISABLE INPUT_opengl STREQUAL 'es2' OR INPUT_opengl STREQUAL 'dynamic' OR INPUT_opengl STREQUAL 'no'
+)
+qt_feature("opengl-dynamic"
+ LABEL "Dynamic OpenGL"
+ AUTODETECT OFF
+ CONDITION WIN32 AND NOT WINRT
+ DISABLE INPUT_angle STREQUAL 'yes' OR INPUT_opengl STREQUAL 'no' OR INPUT_opengl STREQUAL 'desktop'
+)
+qt_feature("dynamicgl" PUBLIC
+ LABEL "Dynamic OpenGL: dynamicgl"
+ CONDITION QT_FEATURE_opengl_dynamic
+ DISABLE INPUT_angle STREQUAL 'yes' OR INPUT_opengl STREQUAL 'no' OR INPUT_opengl STREQUAL 'desktop'
+)
+qt_feature_definition("opengl-dynamic" "QT_OPENGL_DYNAMIC")
+qt_feature("opengl" PUBLIC
+ LABEL "OpenGL"
+ CONDITION QT_FEATURE_opengl_desktop OR QT_FEATURE_opengl_dynamic OR QT_FEATURE_opengles2
+)
+qt_feature_definition("opengl" "QT_NO_OPENGL" NEGATE VALUE "1")
+qt_feature("vkgen" PRIVATE
+ LABEL "vkgen"
+ CONDITION QT_FEATURE_xmlstreamreader
+)
+qt_feature("vulkan" PUBLIC
+ LABEL "Vulkan"
+ CONDITION QT_FEATURE_vkgen AND Vulkan_FOUND
+)
+qt_feature("openvg" PUBLIC
+ LABEL "OpenVG"
+ CONDITION libs.openvg OR FIXME
+)
+qt_feature("egl" PUBLIC PRIVATE
+ LABEL "EGL"
+ CONDITION ( QT_FEATURE_opengl OR QT_FEATURE_openvg ) AND ( QT_FEATURE_angle OR EGL_FOUND ) AND ( QT_FEATURE_dlopen OR NOT UNIX )
+)
+qt_feature_definition("egl" "QT_NO_EGL" NEGATE VALUE "1")
+qt_feature("egl_x11" PRIVATE
+ LABEL "EGL on X11"
+ CONDITION QT_FEATURE_thread AND QT_FEATURE_egl AND TEST_egl_x11
+)
+qt_feature("eglfs" PRIVATE
+ SECTION "Platform plugins"
+ LABEL "EGLFS"
+ CONDITION NOT ANDROID AND NOT APPLE AND NOT WIN32 AND NOT WASM AND QT_FEATURE_egl
+)
+qt_feature("eglfs_brcm" PRIVATE
+ LABEL "EGLFS Raspberry Pi"
+ CONDITION QT_FEATURE_eglfs AND TEST_egl_brcm
+)
+qt_feature("eglfs_egldevice" PRIVATE
+ LABEL "EGLFS EGLDevice"
+ CONDITION QT_FEATURE_eglfs AND TEST_egl_egldevice AND QT_FEATURE_kms
+)
+qt_feature("eglfs_gbm" PRIVATE
+ LABEL "EGLFS GBM"
+ CONDITION QT_FEATURE_eglfs AND gbm_FOUND AND QT_FEATURE_kms
+)
+qt_feature("eglfs_vsp2" PRIVATE
+ LABEL "EGLFS VSP2"
+ CONDITION QT_FEATURE_eglfs AND gbm_FOUND AND QT_FEATURE_kms AND QT_FEATURE_vsp2
+)
+qt_feature("eglfs_mali" PRIVATE
+ LABEL "EGLFS Mali"
+ CONDITION QT_FEATURE_eglfs AND ( TEST_egl_mali OR TEST_egl_mali_2 )
+)
+qt_feature("eglfs_viv" PRIVATE
+ LABEL "EGLFS i.Mx6"
+ CONDITION QT_FEATURE_eglfs AND TEST_egl_viv
+)
+qt_feature("eglfs_rcar" PRIVATE
+ LABEL "EGLFS RCAR"
+ CONDITION INTEGRITY AND QT_FEATURE_eglfs AND TEST_egl_rcar
+)
+qt_feature("eglfs_viv_wl" PRIVATE
+ LABEL "EGLFS i.Mx6 Wayland"
+ CONDITION QT_FEATURE_eglfs_viv AND Wayland_FOUND
+)
+qt_feature("eglfs_openwfd" PRIVATE
+ LABEL "EGLFS OpenWFD"
+ CONDITION INTEGRITY AND QT_FEATURE_eglfs AND TEST_egl_openwfd
+)
+qt_feature("eglfs_x11" PRIVATE
+ LABEL "EGLFS X11"
+ CONDITION QT_FEATURE_eglfs AND QT_FEATURE_xcb_xlib AND QT_FEATURE_egl_x11
+)
+qt_feature("gif" PRIVATE
+ LABEL "GIF"
+ CONDITION QT_FEATURE_imageformatplugin
+)
+qt_feature_definition("gif" "QT_NO_IMAGEFORMAT_GIF" NEGATE)
+qt_feature("ico" PUBLIC PRIVATE
+ LABEL "ICO"
+ CONDITION QT_FEATURE_imageformatplugin
+)
+qt_feature_definition("ico" "QT_NO_ICO" NEGATE VALUE "1")
+qt_feature("jpeg" PRIVATE
+ LABEL "JPEG"
+ CONDITION QT_FEATURE_imageformatplugin AND JPEG_FOUND
+ DISABLE INPUT_libjpeg STREQUAL 'no'
+)
+qt_feature_definition("jpeg" "QT_NO_IMAGEFORMAT_JPEG" NEGATE)
+qt_feature("png" PRIVATE
+ LABEL "PNG"
+ DISABLE INPUT_libpng STREQUAL 'no'
+)
+qt_feature_definition("png" "QT_NO_IMAGEFORMAT_PNG" NEGATE)
+qt_feature("sessionmanager" PUBLIC
+ SECTION "Kernel"
+ LABEL "Session Management"
+ PURPOSE "Provides an interface to the windowing system's session management."
+)
+qt_feature_definition("sessionmanager" "QT_NO_SESSIONMANAGER" NEGATE VALUE "1")
+qt_feature("tslib" PRIVATE
+ LABEL "tslib"
+ CONDITION Tslib_FOUND
+)
+qt_feature("tuiotouch" PRIVATE
+ LABEL "TuioTouch"
+ PURPOSE "Provides the TuioTouch input plugin."
+ CONDITION QT_FEATURE_network AND QT_FEATURE_udpsocket
+)
+qt_feature("xcb" PRIVATE
+ SECTION "Platform plugins"
+ LABEL "XCB"
+ AUTODETECT NOT APPLE
+ CONDITION QT_FEATURE_thread AND TARGET XCB::XCB AND TEST_xcb_syslibs AND QT_FEATURE_xkbcommon_x11
+)
+qt_feature("xcb-glx-plugin" PRIVATE
+ LABEL "GLX Plugin"
+ CONDITION QT_FEATURE_xcb_xlib AND QT_FEATURE_opengl AND NOT QT_FEATURE_opengles2
+ EMIT_IF QT_FEATURE_xcb
+)
+qt_feature("xcb-glx" PRIVATE
+ LABEL " XCB GLX"
+ CONDITION XCB_GLX_FOUND
+ EMIT_IF QT_FEATURE_xcb AND QT_FEATURE_xcb_glx_plugin
+)
+qt_feature("xcb-egl-plugin" PRIVATE
+ LABEL "EGL-X11 Plugin"
+ CONDITION QT_FEATURE_egl_x11 AND QT_FEATURE_opengl
+ EMIT_IF QT_FEATURE_xcb
+)
+qt_feature("xcb-native-painting" PRIVATE
+ LABEL "Native painting (experimental)"
+ AUTODETECT OFF
+ CONDITION QT_FEATURE_xcb_xlib AND QT_FEATURE_fontconfig AND XRender_FOUND
+ EMIT_IF QT_FEATURE_xcb
+)
+qt_feature("xrender" PRIVATE
+ LABEL "XRender for native painting"
+ CONDITION QT_FEATURE_xcb_native_painting
+ EMIT_IF QT_FEATURE_xcb AND QT_FEATURE_xcb_native_painting
+)
+qt_feature("xcb-xlib" PRIVATE
+ LABEL "XCB Xlib"
+ CONDITION QT_FEATURE_xlib AND X11_XCB_FOUND
+)
+qt_feature("xcb-sm" PRIVATE
+ LABEL "xcb-sm"
+ CONDITION QT_FEATURE_sessionmanager AND X11_SM_FOUND
+ EMIT_IF QT_FEATURE_xcb
+)
+qt_feature("system-xcb-xinput" PRIVATE
+ LABEL "Using system-provided xcb-xinput"
+ CONDITION XCB_XINPUT_FOUND
+ ENABLE INPUT_bundled_xcb_xinput STREQUAL 'no'
+ DISABLE INPUT_bundled_xcb_xinput STREQUAL 'yes'
+ EMIT_IF QT_FEATURE_xcb
+)
+qt_feature("xkbcommon" PRIVATE
+ LABEL "xkbcommon"
+ CONDITION XKB_FOUND
+)
+qt_feature("xkbcommon-x11" PRIVATE
+ LABEL "xkbcommon-x11"
+ CONDITION QT_FEATURE_xkbcommon AND XKB_FOUND
+)
+qt_feature("xlib" PRIVATE
+ LABEL "XLib"
+ AUTODETECT NOT APPLE OR QT_FEATURE_xcb
+ CONDITION X11_FOUND
+)
+qt_feature("texthtmlparser" PUBLIC
+ SECTION "Kernel"
+ LABEL "HtmlParser"
+ PURPOSE "Provides a parser for HTML."
+)
+qt_feature_definition("texthtmlparser" "QT_NO_TEXTHTMLPARSER" NEGATE VALUE "1")
+qt_feature("textmarkdownreader" PUBLIC
+ SECTION "Kernel"
+ LABEL "MarkdownReader"
+ PURPOSE "Provides a Markdown (CommonMark and GitHub) reader"
+ ENABLE INPUT_libmd4c STREQUAL 'system' OR INPUT_libmd4c STREQUAL 'qt' OR INPUT_libmd4c STREQUAL 'yes'
+ DISABLE INPUT_libmd4c STREQUAL 'no'
+)
+qt_feature("system-textmarkdownreader" PUBLIC
+ SECTION "Kernel"
+ LABEL " Using system libmd4c"
+ CONDITION libs.libmd4c OR FIXME
+ ENABLE INPUT_libmd4c STREQUAL 'system'
+ DISABLE INPUT_libmd4c STREQUAL 'qt'
+)
+qt_feature("textmarkdownwriter" PUBLIC
+ SECTION "Kernel"
+ LABEL "MarkdownWriter"
+ PURPOSE "Provides a Markdown (CommonMark) writer"
+)
+qt_feature("textodfwriter" PUBLIC
+ SECTION "Kernel"
+ LABEL "OdfWriter"
+ PURPOSE "Provides an ODF writer."
+ CONDITION QT_FEATURE_xmlstreamwriter
+)
+qt_feature_definition("textodfwriter" "QT_NO_TEXTODFWRITER" NEGATE VALUE "1")
+qt_feature("cssparser" PUBLIC
+ SECTION "Kernel"
+ LABEL "CssParser"
+ PURPOSE "Provides a parser for Cascading Style Sheets."
+)
+qt_feature_definition("cssparser" "QT_NO_CSSPARSER" NEGATE VALUE "1")
+qt_feature("draganddrop" PUBLIC
+ SECTION "Kernel"
+ LABEL "Drag and Drop"
+ PURPOSE "Supports the drag and drop mechansim."
+ CONDITION QT_FEATURE_imageformat_xpm
+)
+qt_feature_definition("draganddrop" "QT_NO_DRAGANDDROP" NEGATE VALUE "1")
+qt_feature("action" PUBLIC
+ SECTION "Kernel"
+ LABEL "Q(Gui)Action(Group)"
+ PURPOSE "Provides abstract user interface actions."
+)
+qt_feature_definition("action" "QT_NO_ACTION" NEGATE VALUE "1")
+qt_feature("cursor" PUBLIC
+ SECTION "Kernel"
+ LABEL "QCursor"
+ PURPOSE "Provides mouse cursors."
+)
+qt_feature_definition("cursor" "QT_NO_CURSOR" NEGATE VALUE "1")
+qt_feature("clipboard" PUBLIC
+ SECTION "Kernel"
+ LABEL "QClipboard"
+ PURPOSE "Provides cut and paste operations."
+ CONDITION NOT INTEGRITY AND NOT QNX AND NOT rtems
+)
+qt_feature_definition("clipboard" "QT_NO_CLIPBOARD" NEGATE VALUE "1")
+qt_feature("wheelevent" PUBLIC
+ SECTION "Kernel"
+ LABEL "QWheelEvent"
+ PURPOSE "Supports wheel events."
+)
+qt_feature_definition("wheelevent" "QT_NO_WHEELEVENT" NEGATE VALUE "1")
+qt_feature("tabletevent" PUBLIC
+ SECTION "Kernel"
+ LABEL "QTabletEvent"
+ PURPOSE "Supports tablet events."
+)
+qt_feature_definition("tabletevent" "QT_NO_TABLETEVENT" NEGATE VALUE "1")
+qt_feature("im" PUBLIC
+ SECTION "Kernel"
+ LABEL "QInputContext"
+ PURPOSE "Provides complex input methods."
+ CONDITION QT_FEATURE_library
+)
+qt_feature_definition("im" "QT_NO_IM" NEGATE VALUE "1")
+qt_feature("highdpiscaling" PUBLIC
+ SECTION "Kernel"
+ LABEL "High DPI Scaling"
+ PURPOSE "Provides automatic scaling of DPI-unaware applications on high-DPI displays."
+)
+qt_feature_definition("highdpiscaling" "QT_NO_HIGHDPISCALING" NEGATE VALUE "1")
+qt_feature("validator" PUBLIC
+ SECTION "Widgets"
+ LABEL "QValidator"
+ PURPOSE "Supports validation of input text."
+)
+qt_feature_definition("validator" "QT_NO_VALIDATOR" NEGATE VALUE "1")
+qt_feature("standarditemmodel" PUBLIC
+ SECTION "ItemViews"
+ LABEL "QStandardItemModel"
+ PURPOSE "Provides a generic model for storing custom data."
+ CONDITION QT_FEATURE_itemmodel
+)
+qt_feature_definition("standarditemmodel" "QT_NO_STANDARDITEMMODEL" NEGATE VALUE "1")
+qt_feature("imageformatplugin" PUBLIC
+ SECTION "Images"
+ LABEL "QImageIOPlugin"
+ PURPOSE "Provides a base for writing a image format plugins."
+)
+qt_feature_definition("imageformatplugin" "QT_NO_IMAGEFORMATPLUGIN" NEGATE VALUE "1")
+qt_feature("movie" PUBLIC
+ SECTION "Images"
+ LABEL "QMovie"
+ PURPOSE "Supports animated images."
+)
+qt_feature_definition("movie" "QT_NO_MOVIE" NEGATE VALUE "1")
+qt_feature("imageformat_bmp" PUBLIC
+ SECTION "Images"
+ LABEL "BMP Image Format"
+ PURPOSE "Supports Microsoft's Bitmap image file format."
+)
+qt_feature_definition("imageformat_bmp" "QT_NO_IMAGEFORMAT_BMP" NEGATE VALUE "1")
+qt_feature("imageformat_ppm" PUBLIC
+ SECTION "Images"
+ LABEL "PPM Image Format"
+ PURPOSE "Supports the Portable Pixmap image file format."
+)
+qt_feature_definition("imageformat_ppm" "QT_NO_IMAGEFORMAT_PPM" NEGATE VALUE "1")
+qt_feature("imageformat_xbm" PUBLIC
+ SECTION "Images"
+ LABEL "XBM Image Format"
+ PURPOSE "Supports the X11 Bitmap image file format."
+)
+qt_feature_definition("imageformat_xbm" "QT_NO_IMAGEFORMAT_XBM" NEGATE VALUE "1")
+qt_feature("imageformat_xpm" PUBLIC
+ SECTION "Images"
+ LABEL "XPM Image Format"
+ PURPOSE "Supports the X11 Pixmap image file format."
+)
+qt_feature_definition("imageformat_xpm" "QT_NO_IMAGEFORMAT_XPM" NEGATE VALUE "1")
+qt_feature("imageformat_png" PUBLIC
+ SECTION "Images"
+ LABEL "PNG Image Format"
+ PURPOSE "Supports the Portable Network Graphics image file format."
+)
+qt_feature_definition("imageformat_png" "QT_NO_IMAGEFORMAT_PNG" NEGATE VALUE "1")
+qt_feature("imageformat_jpeg" PUBLIC
+ SECTION "Images"
+ LABEL "JPEG Image Format"
+ PURPOSE "Supports the Joint Photographic Experts Group image file format."
+)
+qt_feature_definition("imageformat_jpeg" "QT_NO_IMAGEFORMAT_JPEG" NEGATE VALUE "1")
+qt_feature("image_heuristic_mask" PUBLIC
+ SECTION "Images"
+ LABEL "QImage::createHeuristicMask()"
+ PURPOSE "Supports creating a 1-bpp heuristic mask for images."
+)
+qt_feature_definition("image_heuristic_mask" "QT_NO_IMAGE_HEURISTIC_MASK" NEGATE VALUE "1")
+qt_feature("image_text" PUBLIC
+ SECTION "Images"
+ LABEL "Image Text"
+ PURPOSE "Supports image file text strings."
+)
+qt_feature_definition("image_text" "QT_NO_IMAGE_TEXT" NEGATE VALUE "1")
+qt_feature("picture" PUBLIC
+ SECTION "Painting"
+ LABEL "QPicture"
+ PURPOSE "Supports recording and replaying QPainter commands."
+)
+qt_feature_definition("picture" "QT_NO_PICTURE" NEGATE VALUE "1")
+qt_feature("colornames" PUBLIC
+ SECTION "Painting"
+ LABEL "Color Names"
+ PURPOSE "Supports color names such as \"red\", used by QColor and by some HTML documents."
+)
+qt_feature_definition("colornames" "QT_NO_COLORNAMES" NEGATE VALUE "1")
+qt_feature("pdf" PUBLIC
+ SECTION "Painting"
+ LABEL "QPdf"
+ PURPOSE "Provides a PDF backend for QPainter."
+ CONDITION QT_FEATURE_temporaryfile
+)
+qt_feature_definition("pdf" "QT_NO_PDF" NEGATE VALUE "1")
+qt_feature("desktopservices" PUBLIC
+ SECTION "Utilities"
+ LABEL "QDesktopServices"
+ PURPOSE "Provides methods for accessing common desktop services."
+)
+qt_feature_definition("desktopservices" "QT_NO_DESKTOPSERVICES" NEGATE VALUE "1")
+qt_feature("systemtrayicon" PUBLIC
+ SECTION "Utilities"
+ LABEL "QSystemTrayIcon"
+ PURPOSE "Provides an icon for an application in the system tray."
+ CONDITION QT_FEATURE_temporaryfile
+)
+qt_feature_definition("systemtrayicon" "QT_NO_SYSTEMTRAYICON" NEGATE VALUE "1")
+qt_feature("accessibility" PUBLIC
+ SECTION "Utilities"
+ LABEL "Accessibility"
+ PURPOSE "Provides accessibility support."
+ CONDITION QT_FEATURE_properties
+)
+qt_feature_definition("accessibility" "QT_NO_ACCESSIBILITY" NEGATE VALUE "1")
+qt_feature("multiprocess" PRIVATE
+ SECTION "Utilities"
+ LABEL "Multi process"
+ PURPOSE "Provides support for detecting the desktop environment, launching external processes and opening URLs."
+ CONDITION NOT INTEGRITY AND NOT rtems
+)
+qt_feature("whatsthis" PUBLIC
+ SECTION "Widget Support"
+ LABEL "QWhatsThis"
+ PURPOSE "Supports displaying \"What's this\" help."
+)
+qt_feature_definition("whatsthis" "QT_NO_WHATSTHIS" NEGATE VALUE "1")
+qt_feature("raster-64bit" PRIVATE
+ SECTION "Painting"
+ LABEL "QPainter - 64 bit raster"
+ PURPOSE "Internal painting support for 64 bit (16 bpc) rasterization."
+)
diff --git a/src/gui/configure.json b/src/gui/configure.json
index 9d9d312048..469473af22 100644
--- a/src/gui/configure.json
+++ b/src/gui/configure.json
@@ -1343,8 +1343,7 @@
"autoDetect": "!config.win32",
"enable": "input.opengl == 'desktop'",
"disable": "input.opengl == 'es2' || input.opengl == 'dynamic' || input.opengl == 'no'",
- "condition": "(config.win32 && !config.winrt && !features.opengles2 && (config.msvc || libs.opengl))
- || (!config.watchos && !config.win32 && !config.wasm && libs.opengl)"
+ "condition": "(config.win32 && !config.winrt && !features.opengles2 && (config.msvc || libs.opengl)) || (!config.watchos && !config.win32 && !config.wasm && libs.opengl)"
},
"opengl-dynamic": {
"label": "Dynamic OpenGL",
@@ -1827,9 +1826,7 @@
{
"type": "note",
"condition": "features.xcb && config.darwin",
- "message": "XCB support on macOS is minimal and untested. Some features will
-not work properly or at all (e.g. OpenGL, desktop services or accessibility),
-or may depend on your system and XQuartz setup."
+ "message": "XCB support on macOS is minimal and untested. Some features will not work properly or at all (e.g. OpenGL, desktop services or accessibility), or may depend on your system and XQuartz setup."
},
{
"type": "note",
@@ -1844,16 +1841,12 @@ or may depend on your system and XQuartz setup."
{
"type": "warning",
"condition": "features.gui && config.linux && !config.android && !features.xcb && !features.eglfs && !features.directfb && !features.linuxfb",
- "message": "No QPA platform plugin enabled! This will
-produce a Qt that cannot run GUI applications.
-See \"Platform backends\" in the output of --help."
+ "message": "No QPA platform plugin enabled! This will produce a Qt that cannot run GUI applications. See \"Platform backends\" in the output of --help."
},
{
"type": "warning",
"condition": "config.win32 && (features.opengles2 || features.opengl-dynamic) && !features.angle",
- "message": "Using OpenGL ES 2.0 on Windows without ANGLE.
-The build will most likely fail.
-Specify -opengl desktop to use regular OpenGL."
+ "message": "Using OpenGL ES 2.0 on Windows without ANGLE. The build will most likely fail. Specify -opengl desktop to use regular OpenGL."
},
{
"type": "warning",
@@ -1863,9 +1856,7 @@ Specify -opengl desktop to use regular OpenGL."
{
"type": "error",
"condition": "features.gui && !config.watchos && input.opengl != 'no' && !features.opengl-desktop && !features.opengles2 && !features.opengl-dynamic",
- "message": "The OpenGL functionality tests failed!
-You might need to modify the include and library search paths by editing QMAKE_INCDIR_OPENGL[_ES2],
-QMAKE_LIBDIR_OPENGL[_ES2] and QMAKE_LIBS_OPENGL[_ES2] in the mkspec for your platform."
+ "message": "The OpenGL functionality tests failed! You might need to modify the include and library search paths by editing QMAKE_INCDIR_OPENGL[_ES2], QMAKE_LIBDIR_OPENGL[_ES2] and QMAKE_LIBS_OPENGL[_ES2] in the mkspec for your platform."
},
{
"type": "warning",
diff --git a/src/network/.prev_CMakeLists.txt b/src/network/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..87bf4cefe3
--- /dev/null
+++ b/src/network/.prev_CMakeLists.txt
@@ -0,0 +1,429 @@
+# Generated from network.pro.
+
+#####################################################################
+## Network Module:
+#####################################################################
+
+qt_add_module(Network
+ PLUGIN_TYPES bearer
+ SOURCES
+ access/qabstractnetworkcache.cpp access/qabstractnetworkcache.h access/qabstractnetworkcache_p.h
+ access/qhsts.cpp access/qhsts_p.h
+ access/qhstspolicy.cpp access/qhstspolicy.h
+ access/qnetworkaccessauthenticationmanager.cpp access/qnetworkaccessauthenticationmanager_p.h
+ access/qnetworkaccessbackend.cpp access/qnetworkaccessbackend_p.h
+ access/qnetworkaccesscache.cpp access/qnetworkaccesscache_p.h
+ access/qnetworkaccesscachebackend.cpp access/qnetworkaccesscachebackend_p.h
+ access/qnetworkaccessdebugpipebackend.cpp access/qnetworkaccessdebugpipebackend_p.h
+ access/qnetworkaccessfilebackend.cpp access/qnetworkaccessfilebackend_p.h
+ access/qnetworkaccessmanager.cpp access/qnetworkaccessmanager.h access/qnetworkaccessmanager_p.h
+ access/qnetworkcookie.cpp access/qnetworkcookie.h access/qnetworkcookie_p.h
+ access/qnetworkcookiejar.cpp access/qnetworkcookiejar.h access/qnetworkcookiejar_p.h
+ access/qnetworkfile.cpp access/qnetworkfile_p.h
+ access/qnetworkreply.cpp access/qnetworkreply.h access/qnetworkreply_p.h
+ access/qnetworkreplydataimpl.cpp access/qnetworkreplydataimpl_p.h
+ access/qnetworkreplyfileimpl.cpp access/qnetworkreplyfileimpl_p.h
+ access/qnetworkreplyimpl.cpp access/qnetworkreplyimpl_p.h
+ access/qnetworkrequest.cpp access/qnetworkrequest.h access/qnetworkrequest_p.h
+ bearer/qbearerengine.cpp bearer/qbearerengine_p.h
+ bearer/qbearerengine_impl_p.h
+ bearer/qbearerplugin.cpp bearer/qbearerplugin_p.h
+ bearer/qnetworkconfigmanager.cpp bearer/qnetworkconfigmanager.h bearer/qnetworkconfigmanager_p.cpp bearer/qnetworkconfigmanager_p.h
+ bearer/qnetworkconfiguration.cpp bearer/qnetworkconfiguration.h bearer/qnetworkconfiguration_p.h
+ bearer/qnetworksession.cpp bearer/qnetworksession.h bearer/qnetworksession_p.h
+ bearer/qnetworksession_impl.cpp bearer/qnetworksession_impl_p.h
+ bearer/qsharednetworksession.cpp bearer/qsharednetworksession_p.h
+ kernel/qauthenticator.cpp kernel/qauthenticator.h kernel/qauthenticator_p.h
+ kernel/qhostaddress.cpp kernel/qhostaddress.h kernel/qhostaddress_p.h
+ kernel/qhostinfo.cpp kernel/qhostinfo.h kernel/qhostinfo_p.h
+ kernel/qnetconmonitor_p.h
+ kernel/qnetworkdatagram.cpp kernel/qnetworkdatagram.h kernel/qnetworkdatagram_p.h
+ kernel/qnetworkinterface.cpp kernel/qnetworkinterface.h kernel/qnetworkinterface_p.h
+ kernel/qnetworkinterface_unix_p.h
+ kernel/qnetworkproxy.cpp kernel/qnetworkproxy.h
+ kernel/qtnetworkglobal.h kernel/qtnetworkglobal_p.h
+ socket/qabstractsocket.cpp socket/qabstractsocket.h socket/qabstractsocket_p.h
+ socket/qabstractsocketengine.cpp socket/qabstractsocketengine_p.h
+ socket/qtcpserver.cpp socket/qtcpserver.h socket/qtcpserver_p.h
+ socket/qtcpsocket.cpp socket/qtcpsocket.h socket/qtcpsocket_p.h
+ socket/qudpsocket.cpp socket/qudpsocket.h
+ ssl/qasn1element.cpp ssl/qasn1element_p.h
+ ssl/qpassworddigestor.cpp ssl/qpassworddigestor.h
+ ssl/qssl.cpp ssl/qssl.h ssl/qssl_p.h
+ ssl/qsslcertificate.cpp ssl/qsslcertificate.h ssl/qsslcertificate_p.h
+ ssl/qsslcertificateextension.cpp ssl/qsslcertificateextension.h ssl/qsslcertificateextension_p.h
+ DEFINES
+ QT_NO_FOREACH
+ QT_NO_USING_NAMESPACE
+ INCLUDE_DIRECTORIES
+ kernel
+ LIBRARIES
+ Qt::CorePrivate
+ ZLIB::ZLIB
+ PUBLIC_LIBRARIES
+ Qt::Core
+ PRECOMPILED_HEADER
+ "../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:network.pro:<TRUE>:
+# MODULE_WINRT_CAPABILITIES = "internetClient" "internetClientServer" "privateNetworkClientServer"
+# QMAKE_LIBS = "$$QMAKE_LIBS_NETWORK"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(Network CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x64000000"
+)
+
+if(ANDROID AND (QT_FEATURE_bearermanagement))
+ set_property(TARGET Network APPEND PROPERTY QT_ANDROID_BUNDLED_JAR_DEPENDENCIES
+ jar/QtAndroidBearer.jar
+ )
+ set_property(TARGET Network APPEND PROPERTY QT_ANDROID_LIB_DEPENDENCIES
+ plugins/bearer/libplugins_bearer_qandroidbearer.so
+ )
+ set_property(TARGET Network APPEND PROPERTY QT_ANDROID_PERMISSIONS
+ android.permission.ACCESS_NETWORK_STATE
+ )
+endif()
+
+qt_extend_target(Network CONDITION QT_FEATURE_ftp
+ SOURCES
+ access/qftp.cpp access/qftp_p.h
+ access/qnetworkaccessftpbackend.cpp access/qnetworkaccessftpbackend_p.h
+ kernel/qurlinfo.cpp kernel/qurlinfo_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_networkdiskcache
+ SOURCES
+ access/qnetworkdiskcache.cpp access/qnetworkdiskcache.h access/qnetworkdiskcache_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_settings
+ SOURCES
+ access/qhstsstore.cpp access/qhstsstore_p.h
+)
+
+qt_extend_target(Network CONDITION APPLE
+ LIBRARIES
+ ${FWCoreFoundation}
+ ${FWSecurity}
+)
+
+qt_extend_target(Network CONDITION WASM
+ SOURCES
+ access/qnetworkreplywasmimpl.cpp access/qnetworkreplywasmimpl_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_http
+ SOURCES
+ access/http2/bitstreams.cpp access/http2/bitstreams_p.h
+ access/http2/hpack.cpp access/http2/hpack_p.h
+ access/http2/hpacktable.cpp access/http2/hpacktable_p.h
+ access/http2/http2frames.cpp access/http2/http2frames_p.h
+ access/http2/http2protocol.cpp access/http2/http2protocol_p.h
+ access/http2/http2streams.cpp access/http2/http2streams_p.h
+ access/http2/huffman.cpp access/http2/huffman_p.h
+ access/qabstractprotocolhandler.cpp access/qabstractprotocolhandler_p.h
+ access/qhttp2configuration.cpp access/qhttp2configuration.h
+ access/qhttp2protocolhandler.cpp access/qhttp2protocolhandler_p.h
+ access/qhttpmultipart.cpp access/qhttpmultipart.h access/qhttpmultipart_p.h
+ access/qhttpnetworkconnection.cpp access/qhttpnetworkconnection_p.h
+ access/qhttpnetworkconnectionchannel.cpp access/qhttpnetworkconnectionchannel_p.h
+ access/qhttpnetworkheader.cpp access/qhttpnetworkheader_p.h
+ access/qhttpnetworkreply.cpp access/qhttpnetworkreply_p.h
+ access/qhttpnetworkrequest.cpp access/qhttpnetworkrequest_p.h
+ access/qhttpprotocolhandler.cpp access/qhttpprotocolhandler_p.h
+ access/qhttpthreaddelegate.cpp access/qhttpthreaddelegate_p.h
+ access/qnetworkreplyhttpimpl.cpp access/qnetworkreplyhttpimpl_p.h
+ socket/qhttpsocketengine.cpp socket/qhttpsocketengine_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dnslookup
+ SOURCES
+ kernel/qdnslookup.cpp kernel/qdnslookup.h kernel/qdnslookup_p.h
+)
+
+qt_extend_target(Network CONDITION UNIX
+ SOURCES
+ kernel/qhostinfo_unix.cpp
+ socket/qnativesocketengine_unix.cpp
+ socket/qnet_unix_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dlopen AND UNIX
+ LIBRARIES
+ ${CMAKE_DL_LIBS}
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_linux_netlink AND UNIX
+ SOURCES
+ kernel/qnetworkinterface_linux.cpp
+)
+
+qt_extend_target(Network CONDITION UNIX AND NOT QT_FEATURE_linux_netlink
+ SOURCES
+ kernel/qnetworkinterface_unix.cpp
+)
+
+qt_extend_target(Network CONDITION ANDROID AND QT_FEATURE_dnslookup
+ SOURCES
+ kernel/qdnslookup_android.cpp
+)
+
+qt_extend_target(Network CONDITION WIN32
+ SOURCES
+ kernel/qhostinfo_win.cpp
+)
+
+qt_extend_target(Network CONDITION WIN32 AND NOT WINRT
+ SOURCES
+ kernel/qnetworkinterface_win.cpp
+ kernel/qnetworkproxy_win.cpp
+ socket/qnativesocketengine_win.cpp
+ LIBRARIES
+ advapi32
+ dnsapi
+ iphlpapi
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dnslookup AND WIN32 AND NOT WINRT
+ SOURCES
+ kernel/qdnslookup_win.cpp
+)
+
+qt_extend_target(Network CONDITION WINRT
+ SOURCES
+ kernel/qnetworkinterface_winrt.cpp
+ socket/qnativesocketengine_winrt.cpp socket/qnativesocketengine_winrt_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dnslookup AND WINRT
+ SOURCES
+ kernel/qdnslookup_winrt.cpp
+)
+
+qt_extend_target(Network CONDITION APPLE AND NOT APPLE_UIKIT
+ LIBRARIES
+ ${FWCoreServices}
+ ${FWSystemConfiguration}
+)
+
+qt_extend_target(Network CONDITION APPLE_IOS OR APPLE_OSX
+ SOURCES
+ kernel/qnetconmonitor_darwin.mm
+ LIBRARIES
+ ${FWSystemConfiguration}
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_netlistmgr AND NOT APPLE_IOS AND NOT APPLE_OSX
+ SOURCES
+ kernel/qnetconmonitor_win.cpp
+)
+
+qt_extend_target(Network CONDITION NOT APPLE_IOS AND NOT APPLE_OSX AND NOT QT_FEATURE_netlistmgr
+ SOURCES
+ kernel/qnetconmonitor_stub.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_gssapi
+ LIBRARIES
+ GSSAPI::GSSAPI
+)
+
+qt_extend_target(Network CONDITION APPLE_UIKIT
+ SOURCES
+ kernel/qnetworkinterface_uikit_p.h
+)
+
+qt_extend_target(Network CONDITION APPLE_OSX
+ SOURCES
+ kernel/qnetworkproxy_mac.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_libproxy AND NOT APPLE_OSX AND (UNIX OR WINRT)
+ SOURCES
+ kernel/qnetworkproxy_libproxy.cpp
+ LIBRARIES
+ ${CMAKE_DL_LIBS}
+ PkgConfig::Libproxy
+)
+
+qt_extend_target(Network CONDITION NOT APPLE_OSX AND NOT QT_FEATURE_libproxy AND (UNIX OR WINRT)
+ SOURCES
+ kernel/qnetworkproxy_generic.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_socks5
+ SOURCES
+ socket/qsocks5socketengine.cpp socket/qsocks5socketengine_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_sctp
+ SOURCES
+ socket/qsctpserver.cpp socket/qsctpserver.h socket/qsctpserver_p.h
+ socket/qsctpsocket.cpp socket/qsctpsocket.h socket/qsctpsocket_p.h
+)
+
+qt_extend_target(Network CONDITION NOT WINRT
+ SOURCES
+ socket/qnativesocketengine.cpp socket/qnativesocketengine_p.h
+)
+
+qt_extend_target(Network CONDITION MSVC
+ MOC_OPTIONS
+ "-D_WINSOCK_DEPRECATED_NO_WARNINGS"
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_localserver
+ SOURCES
+ socket/qlocalserver.cpp socket/qlocalserver.h socket/qlocalserver_p.h
+ socket/qlocalsocket.cpp socket/qlocalsocket.h socket/qlocalsocket_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_localserver AND (INTEGRITY OR WINRT)
+ SOURCES
+ socket/qlocalserver_tcp.cpp
+ socket/qlocalsocket_tcp.cpp
+ DEFINES
+ QT_LOCALSOCKET_TCP
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_localserver AND UNIX AND NOT INTEGRITY AND NOT WINRT
+ SOURCES
+ socket/qlocalserver_unix.cpp
+ socket/qlocalsocket_unix.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_localserver AND WIN32 AND NOT WINRT
+ SOURCES
+ socket/qlocalserver_win.cpp
+ socket/qlocalsocket_win.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_system_proxies
+ DEFINES
+ QT_USE_SYSTEM_PROXIES
+)
+
+qt_extend_target(Network CONDITION NOT QT_FEATURE_openssl
+ SOURCES
+ ssl/qsslcertificate_qt.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_ssl
+ SOURCES
+ ssl/qocspresponse.cpp ssl/qocspresponse.h ssl/qocspresponse_p.h
+ ssl/qsslcipher.cpp ssl/qsslcipher.h ssl/qsslcipher_p.h
+ ssl/qsslconfiguration.cpp ssl/qsslconfiguration.h ssl/qsslconfiguration_p.h
+ ssl/qssldiffiehellmanparameters.cpp ssl/qssldiffiehellmanparameters.h ssl/qssldiffiehellmanparameters_p.h
+ ssl/qsslellipticcurve.cpp ssl/qsslellipticcurve.h
+ ssl/qsslerror.cpp ssl/qsslerror.h
+ ssl/qsslkey.h ssl/qsslkey_p.cpp ssl/qsslkey_p.h
+ ssl/qsslpresharedkeyauthenticator.cpp ssl/qsslpresharedkeyauthenticator.h ssl/qsslpresharedkeyauthenticator_p.h
+ ssl/qsslsocket.cpp ssl/qsslsocket.h ssl/qsslsocket_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_ssl AND WINRT
+ SOURCES
+ ssl/qsslcertificate_winrt.cpp
+ ssl/qssldiffiehellmanparameters_dummy.cpp
+ ssl/qsslellipticcurve_dummy.cpp
+ ssl/qsslkey_qt.cpp
+ ssl/qsslkey_winrt.cpp
+ ssl/qsslsocket_winrt.cpp ssl/qsslsocket_winrt_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_schannel AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qsslcertificate_schannel.cpp
+ ssl/qssldiffiehellmanparameters_dummy.cpp
+ ssl/qsslellipticcurve_dummy.cpp
+ ssl/qsslkey_qt.cpp
+ ssl/qsslkey_schannel.cpp
+ ssl/qsslsocket_qt.cpp
+ ssl/qsslsocket_schannel.cpp ssl/qsslsocket_schannel_p.h
+ LIBRARIES
+ Crypt32
+ Secur32
+ bcrypt
+ ncrypt
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_securetransport AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qssldiffiehellmanparameters_dummy.cpp
+ ssl/qsslellipticcurve_dummy.cpp
+ ssl/qsslkey_mac.cpp
+ ssl/qsslkey_qt.cpp
+ ssl/qsslsocket_mac.cpp ssl/qsslsocket_mac_p.h
+ ssl/qsslsocket_mac_shared.cpp
+ ssl/qsslsocket_qt.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dtls AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qdtls.cpp ssl/qdtls.h ssl/qdtls_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_openssl AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qsslcertificate_openssl.cpp
+ ssl/qsslcontext_openssl.cpp ssl/qsslcontext_openssl_p.h
+ ssl/qssldiffiehellmanparameters_openssl.cpp
+ ssl/qsslellipticcurve_openssl.cpp
+ ssl/qsslkey_openssl.cpp
+ ssl/qsslsocket_openssl.cpp ssl/qsslsocket_openssl_p.h
+ ssl/qsslsocket_openssl_symbols.cpp ssl/qsslsocket_openssl_symbols_p.h
+ DEFINES
+ OPENSSL_API_COMPAT=0x10100000L
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dtls AND QT_FEATURE_openssl AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qdtls_openssl.cpp ssl/qdtls_openssl_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_ocsp AND QT_FEATURE_openssl AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qocsp_p.h
+)
+
+qt_extend_target(Network CONDITION APPLE AND QT_FEATURE_openssl AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qsslsocket_mac_shared.cpp
+)
+
+qt_extend_target(Network CONDITION ANDROID AND QT_FEATURE_openssl AND QT_FEATURE_ssl AND NOT ANDROID_EMBEDDED
+ SOURCES
+ ssl/qsslsocket_openssl_android.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_openssl AND QT_FEATURE_openssl_linked AND QT_FEATURE_ssl
+ LIBRARIES
+ OpenSSL::SSL
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_openssl AND QT_FEATURE_ssl AND NOT QT_FEATURE_openssl_linked
+ LIBRARIES
+ OpenSSL::SSL_nolink
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_openssl AND QT_FEATURE_ssl AND WIN32
+ SOURCES
+ ssl/qwindowscarootfetcher.cpp ssl/qwindowscarootfetcher_p.h
+ LIBRARIES
+ crypt32
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dnslookup AND UNIX AND NOT ANDROID AND NOT INTEGRITY
+ SOURCES
+ kernel/qdnslookup_unix.cpp
+)
+qt_add_docs(Network
+ doc/qtnetwork.qdocconf
+)
+
diff --git a/src/network/CMakeLists.txt b/src/network/CMakeLists.txt
new file mode 100644
index 0000000000..8b2753e6ff
--- /dev/null
+++ b/src/network/CMakeLists.txt
@@ -0,0 +1,445 @@
+# Generated from network.pro.
+
+# special case begin
+# Temporary fix for OpenSSL feature detection until we can provide a
+# proper implementation of additional compile tests for library dependencies
+# in configure.json
+
+if (UNIX OR ANDROID)
+find_package(OpenSSL)
+if (NOT OPENSSL_FOUND OR NOT OPENSSL_VERSION VERSION_GREATER_EQUAL "1.1.0")
+ set(QT_FEATURE_openssl_runtime OFF CACHE BOOL "" FORCE)
+ set(QT_FEATURE_openssl_linked OFF CACHE BOOL "" FORCE)
+ set(QT_FEATURE_openssl OFF CACHE BOOL "" FORCE)
+endif()
+endif()
+# special case end
+
+#####################################################################
+## Network Module:
+#####################################################################
+
+qt_add_module(Network
+ PLUGIN_TYPES bearer
+ SOURCES
+ access/qabstractnetworkcache.cpp access/qabstractnetworkcache.h access/qabstractnetworkcache_p.h
+ access/qhsts.cpp access/qhsts_p.h
+ access/qhstspolicy.cpp access/qhstspolicy.h
+ access/qnetworkaccessauthenticationmanager.cpp access/qnetworkaccessauthenticationmanager_p.h
+ access/qnetworkaccessbackend.cpp access/qnetworkaccessbackend_p.h
+ access/qnetworkaccesscache.cpp access/qnetworkaccesscache_p.h
+ access/qnetworkaccesscachebackend.cpp access/qnetworkaccesscachebackend_p.h
+ access/qnetworkaccessdebugpipebackend.cpp access/qnetworkaccessdebugpipebackend_p.h
+ access/qnetworkaccessfilebackend.cpp access/qnetworkaccessfilebackend_p.h
+ access/qnetworkaccessmanager.cpp access/qnetworkaccessmanager.h access/qnetworkaccessmanager_p.h
+ access/qnetworkcookie.cpp access/qnetworkcookie.h access/qnetworkcookie_p.h
+ access/qnetworkcookiejar.cpp access/qnetworkcookiejar.h access/qnetworkcookiejar_p.h
+ access/qnetworkfile.cpp access/qnetworkfile_p.h
+ access/qnetworkreply.cpp access/qnetworkreply.h access/qnetworkreply_p.h
+ access/qnetworkreplydataimpl.cpp access/qnetworkreplydataimpl_p.h
+ access/qnetworkreplyfileimpl.cpp access/qnetworkreplyfileimpl_p.h
+ access/qnetworkreplyimpl.cpp access/qnetworkreplyimpl_p.h
+ access/qnetworkrequest.cpp access/qnetworkrequest.h access/qnetworkrequest_p.h
+ bearer/qbearerengine.cpp bearer/qbearerengine_p.h
+ bearer/qbearerengine_impl_p.h
+ bearer/qbearerplugin.cpp bearer/qbearerplugin_p.h
+ bearer/qnetworkconfigmanager.cpp bearer/qnetworkconfigmanager.h bearer/qnetworkconfigmanager_p.cpp bearer/qnetworkconfigmanager_p.h
+ bearer/qnetworkconfiguration.cpp bearer/qnetworkconfiguration.h bearer/qnetworkconfiguration_p.h
+ bearer/qnetworksession.cpp bearer/qnetworksession.h bearer/qnetworksession_p.h
+ bearer/qnetworksession_impl.cpp bearer/qnetworksession_impl_p.h
+ bearer/qsharednetworksession.cpp bearer/qsharednetworksession_p.h
+ kernel/qauthenticator.cpp kernel/qauthenticator.h kernel/qauthenticator_p.h
+ kernel/qhostaddress.cpp kernel/qhostaddress.h kernel/qhostaddress_p.h
+ kernel/qhostinfo.cpp kernel/qhostinfo.h kernel/qhostinfo_p.h
+ kernel/qnetconmonitor_p.h
+ kernel/qnetworkdatagram.cpp kernel/qnetworkdatagram.h kernel/qnetworkdatagram_p.h
+ kernel/qnetworkinterface.cpp kernel/qnetworkinterface.h kernel/qnetworkinterface_p.h
+ kernel/qnetworkinterface_unix_p.h
+ kernel/qnetworkproxy.cpp kernel/qnetworkproxy.h
+ kernel/qtnetworkglobal.h kernel/qtnetworkglobal_p.h
+ socket/qabstractsocket.cpp socket/qabstractsocket.h socket/qabstractsocket_p.h
+ socket/qabstractsocketengine.cpp socket/qabstractsocketengine_p.h
+ socket/qtcpserver.cpp socket/qtcpserver.h socket/qtcpserver_p.h
+ socket/qtcpsocket.cpp socket/qtcpsocket.h socket/qtcpsocket_p.h
+ socket/qudpsocket.cpp socket/qudpsocket.h
+ ssl/qasn1element.cpp ssl/qasn1element_p.h
+ ssl/qpassworddigestor.cpp ssl/qpassworddigestor.h
+ ssl/qssl.cpp ssl/qssl.h ssl/qssl_p.h
+ ssl/qsslcertificate.cpp ssl/qsslcertificate.h ssl/qsslcertificate_p.h
+ ssl/qsslcertificateextension.cpp ssl/qsslcertificateextension.h ssl/qsslcertificateextension_p.h
+ DEFINES
+ QT_NO_FOREACH
+ QT_NO_USING_NAMESPACE
+ INCLUDE_DIRECTORIES
+ kernel
+ LIBRARIES
+ Qt::CorePrivate
+ ZLIB::ZLIB
+ PUBLIC_LIBRARIES
+ Qt::Core
+ PRECOMPILED_HEADER
+ "../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:network.pro:<TRUE>:
+# MODULE_WINRT_CAPABILITIES = "internetClient" "internetClientServer" "privateNetworkClientServer"
+# QMAKE_LIBS = "$$QMAKE_LIBS_NETWORK"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(Network CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x64000000"
+)
+
+if(ANDROID AND (QT_FEATURE_bearermanagement))
+ set_property(TARGET Network APPEND PROPERTY QT_ANDROID_BUNDLED_JAR_DEPENDENCIES
+ jar/QtAndroidBearer.jar
+ )
+ set_property(TARGET Network APPEND PROPERTY QT_ANDROID_LIB_DEPENDENCIES
+ plugins/bearer/libplugins_bearer_qandroidbearer.so
+ )
+ set_property(TARGET Network APPEND PROPERTY QT_ANDROID_PERMISSIONS
+ android.permission.ACCESS_NETWORK_STATE
+ )
+endif()
+
+qt_extend_target(Network CONDITION QT_FEATURE_ftp
+ SOURCES
+ access/qftp.cpp access/qftp_p.h
+ access/qnetworkaccessftpbackend.cpp access/qnetworkaccessftpbackend_p.h
+ kernel/qurlinfo.cpp kernel/qurlinfo_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_networkdiskcache
+ SOURCES
+ access/qnetworkdiskcache.cpp access/qnetworkdiskcache.h access/qnetworkdiskcache_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_settings
+ SOURCES
+ access/qhstsstore.cpp access/qhstsstore_p.h
+)
+
+qt_extend_target(Network CONDITION APPLE
+ LIBRARIES
+ ${FWCoreFoundation}
+ ${FWSecurity}
+)
+
+qt_extend_target(Network CONDITION WASM
+ SOURCES
+ access/qnetworkreplywasmimpl.cpp access/qnetworkreplywasmimpl_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_http
+ SOURCES
+ access/http2/bitstreams.cpp access/http2/bitstreams_p.h
+ access/http2/hpack.cpp access/http2/hpack_p.h
+ access/http2/hpacktable.cpp access/http2/hpacktable_p.h
+ access/http2/http2frames.cpp access/http2/http2frames_p.h
+ access/http2/http2protocol.cpp access/http2/http2protocol_p.h
+ access/http2/http2streams.cpp access/http2/http2streams_p.h
+ access/http2/huffman.cpp access/http2/huffman_p.h
+ access/qabstractprotocolhandler.cpp access/qabstractprotocolhandler_p.h
+ access/qhttp2configuration.cpp access/qhttp2configuration.h
+ access/qhttp2protocolhandler.cpp access/qhttp2protocolhandler_p.h
+ access/qhttpmultipart.cpp access/qhttpmultipart.h access/qhttpmultipart_p.h
+ access/qhttpnetworkconnection.cpp access/qhttpnetworkconnection_p.h
+ access/qhttpnetworkconnectionchannel.cpp access/qhttpnetworkconnectionchannel_p.h
+ access/qhttpnetworkheader.cpp access/qhttpnetworkheader_p.h
+ access/qhttpnetworkreply.cpp access/qhttpnetworkreply_p.h
+ access/qhttpnetworkrequest.cpp access/qhttpnetworkrequest_p.h
+ access/qhttpprotocolhandler.cpp access/qhttpprotocolhandler_p.h
+ access/qhttpthreaddelegate.cpp access/qhttpthreaddelegate_p.h
+ access/qnetworkreplyhttpimpl.cpp access/qnetworkreplyhttpimpl_p.h
+ socket/qhttpsocketengine.cpp socket/qhttpsocketengine_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dnslookup
+ SOURCES
+ kernel/qdnslookup.cpp kernel/qdnslookup.h kernel/qdnslookup_p.h
+)
+
+qt_extend_target(Network CONDITION UNIX
+ SOURCES
+ kernel/qhostinfo_unix.cpp
+ socket/qnativesocketengine_unix.cpp
+ socket/qnet_unix_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dlopen AND UNIX
+ LIBRARIES
+ ${CMAKE_DL_LIBS}
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_linux_netlink AND UNIX
+ SOURCES
+ kernel/qnetworkinterface_linux.cpp
+)
+
+qt_extend_target(Network CONDITION UNIX AND NOT QT_FEATURE_linux_netlink
+ SOURCES
+ kernel/qnetworkinterface_unix.cpp
+)
+
+qt_extend_target(Network CONDITION ANDROID AND QT_FEATURE_dnslookup
+ SOURCES
+ kernel/qdnslookup_android.cpp
+)
+
+qt_extend_target(Network CONDITION WIN32
+ SOURCES
+ kernel/qhostinfo_win.cpp
+)
+
+qt_extend_target(Network CONDITION WIN32 AND NOT WINRT
+ SOURCES
+ kernel/qnetworkinterface_win.cpp
+ kernel/qnetworkproxy_win.cpp
+ socket/qnativesocketengine_win.cpp
+ LIBRARIES
+ advapi32
+ dnsapi
+ iphlpapi
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dnslookup AND WIN32 AND NOT WINRT
+ SOURCES
+ kernel/qdnslookup_win.cpp
+)
+
+qt_extend_target(Network CONDITION WINRT
+ SOURCES
+ kernel/qnetworkinterface_winrt.cpp
+ socket/qnativesocketengine_winrt.cpp socket/qnativesocketengine_winrt_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dnslookup AND WINRT
+ SOURCES
+ kernel/qdnslookup_winrt.cpp
+)
+
+qt_extend_target(Network CONDITION APPLE AND NOT APPLE_UIKIT
+ LIBRARIES
+ ${FWCoreServices}
+ ${FWSystemConfiguration}
+)
+
+qt_extend_target(Network CONDITION APPLE_IOS OR APPLE_OSX
+ SOURCES
+ kernel/qnetconmonitor_darwin.mm
+ LIBRARIES
+ ${FWSystemConfiguration}
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_netlistmgr AND NOT APPLE_IOS AND NOT APPLE_OSX
+ SOURCES
+ kernel/qnetconmonitor_win.cpp
+)
+
+qt_extend_target(Network CONDITION NOT APPLE_IOS AND NOT APPLE_OSX AND NOT QT_FEATURE_netlistmgr
+ SOURCES
+ kernel/qnetconmonitor_stub.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_gssapi
+ LIBRARIES
+ GSSAPI::GSSAPI
+)
+
+qt_extend_target(Network CONDITION APPLE_UIKIT
+ SOURCES
+ kernel/qnetworkinterface_uikit_p.h
+)
+
+qt_extend_target(Network CONDITION APPLE_OSX
+ SOURCES
+ kernel/qnetworkproxy_mac.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_libproxy AND NOT APPLE_OSX AND (UNIX OR WINRT)
+ SOURCES
+ kernel/qnetworkproxy_libproxy.cpp
+ LIBRARIES
+ ${CMAKE_DL_LIBS}
+ PkgConfig::Libproxy
+)
+
+qt_extend_target(Network CONDITION NOT APPLE_OSX AND NOT QT_FEATURE_libproxy AND (UNIX OR WINRT)
+ SOURCES
+ kernel/qnetworkproxy_generic.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_socks5
+ SOURCES
+ socket/qsocks5socketengine.cpp socket/qsocks5socketengine_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_sctp
+ SOURCES
+ socket/qsctpserver.cpp socket/qsctpserver.h socket/qsctpserver_p.h
+ socket/qsctpsocket.cpp socket/qsctpsocket.h socket/qsctpsocket_p.h
+)
+
+qt_extend_target(Network CONDITION NOT WINRT
+ SOURCES
+ socket/qnativesocketengine.cpp socket/qnativesocketengine_p.h
+)
+
+qt_extend_target(Network CONDITION MSVC
+ MOC_OPTIONS
+ "-D_WINSOCK_DEPRECATED_NO_WARNINGS"
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_localserver
+ SOURCES
+ socket/qlocalserver.cpp socket/qlocalserver.h socket/qlocalserver_p.h
+ socket/qlocalsocket.cpp socket/qlocalsocket.h socket/qlocalsocket_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_localserver AND (INTEGRITY OR WINRT)
+ SOURCES
+ socket/qlocalserver_tcp.cpp
+ socket/qlocalsocket_tcp.cpp
+ DEFINES
+ QT_LOCALSOCKET_TCP
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_localserver AND UNIX AND NOT INTEGRITY AND NOT WINRT
+ SOURCES
+ socket/qlocalserver_unix.cpp
+ socket/qlocalsocket_unix.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_localserver AND WIN32 AND NOT WINRT
+ SOURCES
+ socket/qlocalserver_win.cpp
+ socket/qlocalsocket_win.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_system_proxies
+ DEFINES
+ QT_USE_SYSTEM_PROXIES
+)
+
+qt_extend_target(Network CONDITION NOT QT_FEATURE_openssl
+ SOURCES
+ ssl/qsslcertificate_qt.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_ssl
+ SOURCES
+ ssl/qocspresponse.cpp ssl/qocspresponse.h ssl/qocspresponse_p.h
+ ssl/qsslcipher.cpp ssl/qsslcipher.h ssl/qsslcipher_p.h
+ ssl/qsslconfiguration.cpp ssl/qsslconfiguration.h ssl/qsslconfiguration_p.h
+ ssl/qssldiffiehellmanparameters.cpp ssl/qssldiffiehellmanparameters.h ssl/qssldiffiehellmanparameters_p.h
+ ssl/qsslellipticcurve.cpp ssl/qsslellipticcurve.h
+ ssl/qsslerror.cpp ssl/qsslerror.h
+ ssl/qsslkey.h ssl/qsslkey_p.cpp ssl/qsslkey_p.h
+ ssl/qsslpresharedkeyauthenticator.cpp ssl/qsslpresharedkeyauthenticator.h ssl/qsslpresharedkeyauthenticator_p.h
+ ssl/qsslsocket.cpp ssl/qsslsocket.h ssl/qsslsocket_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_ssl AND WINRT
+ SOURCES
+ ssl/qsslcertificate_winrt.cpp
+ ssl/qssldiffiehellmanparameters_dummy.cpp
+ ssl/qsslellipticcurve_dummy.cpp
+ ssl/qsslkey_qt.cpp
+ ssl/qsslkey_winrt.cpp
+ ssl/qsslsocket_winrt.cpp ssl/qsslsocket_winrt_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_schannel AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qsslcertificate_schannel.cpp
+ ssl/qssldiffiehellmanparameters_dummy.cpp
+ ssl/qsslellipticcurve_dummy.cpp
+ ssl/qsslkey_qt.cpp
+ ssl/qsslkey_schannel.cpp
+ ssl/qsslsocket_qt.cpp
+ ssl/qsslsocket_schannel.cpp ssl/qsslsocket_schannel_p.h
+ LIBRARIES
+ Crypt32
+ Secur32
+ bcrypt
+ ncrypt
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_securetransport AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qssldiffiehellmanparameters_dummy.cpp
+ ssl/qsslellipticcurve_dummy.cpp
+ ssl/qsslkey_mac.cpp
+ ssl/qsslkey_qt.cpp
+ ssl/qsslsocket_mac.cpp ssl/qsslsocket_mac_p.h
+ ssl/qsslsocket_mac_shared.cpp
+ ssl/qsslsocket_qt.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dtls AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qdtls.cpp ssl/qdtls.h ssl/qdtls_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_openssl AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qsslcertificate_openssl.cpp
+ ssl/qsslcontext_openssl.cpp ssl/qsslcontext_openssl_p.h
+ ssl/qssldiffiehellmanparameters_openssl.cpp
+ ssl/qsslellipticcurve_openssl.cpp
+ ssl/qsslkey_openssl.cpp
+ ssl/qsslsocket_openssl.cpp ssl/qsslsocket_openssl_p.h
+ ssl/qsslsocket_openssl_symbols.cpp ssl/qsslsocket_openssl_symbols_p.h
+ DEFINES
+ OPENSSL_API_COMPAT=0x10100000L
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dtls AND QT_FEATURE_openssl AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qdtls_openssl.cpp ssl/qdtls_openssl_p.h
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_ocsp AND QT_FEATURE_openssl AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qocsp_p.h
+)
+
+qt_extend_target(Network CONDITION APPLE AND QT_FEATURE_openssl AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qsslsocket_mac_shared.cpp
+)
+
+qt_extend_target(Network CONDITION ANDROID AND QT_FEATURE_openssl AND QT_FEATURE_ssl AND NOT ANDROID_EMBEDDED
+ SOURCES
+ ssl/qsslsocket_openssl_android.cpp
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_openssl AND QT_FEATURE_openssl_linked AND QT_FEATURE_ssl
+ LIBRARIES
+ OpenSSL::SSL
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_openssl AND QT_FEATURE_ssl AND NOT QT_FEATURE_openssl_linked
+ LIBRARIES
+ OpenSSL::SSL_nolink
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_openssl AND QT_FEATURE_ssl AND WIN32
+ SOURCES
+ ssl/qwindowscarootfetcher.cpp ssl/qwindowscarootfetcher_p.h
+ LIBRARIES
+ crypt32
+)
+
+qt_extend_target(Network CONDITION QT_FEATURE_dnslookup AND UNIX AND NOT ANDROID AND NOT INTEGRITY
+ SOURCES
+ kernel/qdnslookup_unix.cpp
+)
+qt_add_docs(Network
+ doc/qtnetwork.qdocconf
+)
+
+qt_extend_target(Network CONDITION WIN32 PUBLIC_LIBRARIES ws2_32) # special case: mkspecs/common/msvc-desktop.conf
diff --git a/src/network/configure.cmake b/src/network/configure.cmake
new file mode 100644
index 0000000000..9046464cf4
--- /dev/null
+++ b/src/network/configure.cmake
@@ -0,0 +1,359 @@
+
+
+#### Inputs
+
+
+
+#### Libraries
+
+qt_find_package(Libproxy PROVIDED_TARGETS PkgConfig::Libproxy)
+qt_find_package(OpenSSL PROVIDED_TARGETS OpenSSL::SSL)
+qt_find_package(OpenSSL PROVIDED_TARGETS OpenSSL::SSL)
+qt_find_package(GSSAPI PROVIDED_TARGETS GSSAPI::GSSAPI)
+
+
+#### Tests
+
+# getifaddrs
+qt_config_compile_test(getifaddrs
+ LABEL "getifaddrs()"
+ CODE
+"
+#include <sys/types.h>
+#include <sys/socket.h>
+#include <net/if.h>
+#include <ifaddrs.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+ifaddrs *list;
+getifaddrs(&list);
+freeifaddrs(list);
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: use: unmapped library: network
+)
+
+# ipv6ifname
+qt_config_compile_test(ipv6ifname
+ LABEL "IPv6 ifname"
+ CODE
+"
+#include <sys/types.h>
+#include <sys/socket.h>
+#include <net/if.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+char buf[IFNAMSIZ];
+if_nametoindex(\"eth0\");
+if_indextoname(1, buf);
+if_freenameindex(if_nameindex());
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: use: unmapped library: network
+)
+
+# linux-netlink
+qt_config_compile_test(linux_netlink
+ LABEL "Linux AF_NETLINK sockets"
+ CODE
+"
+#include <asm/types.h>
+#include <linux/netlink.h>
+#include <linux/rtnetlink.h>
+#include <sys/socket.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+struct rtattr rta = { };
+struct ifinfomsg ifi = {};
+struct ifaddrmsg ifa = {};
+struct ifa_cacheinfo ci;
+ci.ifa_prefered = ci.ifa_valid = 0;
+(void)RTM_NEWLINK; (void)RTM_NEWADDR;
+(void)IFLA_ADDRESS; (void)IFLA_IFNAME;
+(void)IFA_ADDRESS; (void)IFA_LABEL; (void)IFA_CACHEINFO;
+(void)(IFA_F_SECONDARY | IFA_F_DEPRECATED | IFA_F_PERMANENT | IFA_F_MANAGETEMPADDR);
+ /* END TEST: */
+ return 0;
+}
+")
+
+# sctp
+qt_config_compile_test(sctp
+ LABEL "SCTP support"
+ CODE
+"
+#include <sys/types.h>
+#include <sys/socket.h>
+#include <netinet/in.h>
+#include <netinet/sctp.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+sctp_initmsg sctpInitMsg;
+socklen_t sctpInitMsgSize = sizeof(sctpInitMsg);
+(void) socket(PF_INET, SOCK_STREAM, IPPROTO_SCTP);
+(void) getsockopt(-1, SOL_SCTP, SCTP_INITMSG, &sctpInitMsg, &sctpInitMsgSize);
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: use: unmapped library: network
+)
+
+# dtls
+qt_config_compile_test(dtls
+ LABEL "DTLS support in OpenSSL"
+ LIBRARIES
+ OpenSSL::SSL
+ CODE
+"
+#include <openssl/ssl.h>
+#if defined(OPENSSL_NO_DTLS) || !defined(DTLS1_2_VERSION)
+# error OpenSSL without DTLS support
+#endif
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+
+ /* END TEST: */
+ return 0;
+}
+")
+
+# ocsp
+qt_config_compile_test(ocsp
+ LABEL "OCSP stapling support in OpenSSL"
+ LIBRARIES
+ OpenSSL::SSL
+ CODE
+"
+#include <openssl/ssl.h>
+#include <openssl/ocsp.h>
+#if defined(OPENSSL_NO_OCSP) || defined(OPENSSL_NO_TLSEXT)
+# error OpenSSL without OCSP stapling
+#endif
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+
+ /* END TEST: */
+ return 0;
+}
+")
+
+# netlistmgr
+qt_config_compile_test(netlistmgr
+ LABEL "Network List Manager"
+ CODE
+"
+#include <netlistmgr.h>
+#include <wrl/client.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+using namespace Microsoft::WRL;
+ComPtr<INetworkListManager> networkListManager;
+ComPtr<IConnectionPoint> connectionPoint;
+ComPtr<IConnectionPointContainer> connectionPointContainer;
+networkListManager.As(&connectionPointContainer);
+connectionPointContainer->FindConnectionPoint(IID_INetworkConnectionEvents, &connectionPoint);
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: qmake: LIBS += -lOle32
+)
+
+
+
+#### Features
+
+qt_feature("corewlan" PUBLIC PRIVATE
+ LABEL "CoreWLan"
+ CONDITION libs.corewlan OR FIXME
+ EMIT_IF APPLE
+)
+qt_feature_definition("corewlan" "QT_NO_COREWLAN" NEGATE VALUE "1")
+qt_feature("getifaddrs" PUBLIC
+ LABEL "getifaddrs()"
+ CONDITION TEST_getifaddrs
+)
+qt_feature_definition("getifaddrs" "QT_NO_GETIFADDRS" NEGATE VALUE "1")
+qt_feature("ipv6ifname" PUBLIC
+ LABEL "IPv6 ifname"
+ CONDITION TEST_ipv6ifname
+)
+qt_feature_definition("ipv6ifname" "QT_NO_IPV6IFNAME" NEGATE VALUE "1")
+qt_feature("libproxy" PRIVATE
+ LABEL "libproxy"
+ AUTODETECT OFF
+ CONDITION Libproxy_FOUND
+)
+qt_feature("linux-netlink" PRIVATE
+ LABEL "Linux AF_NETLINK"
+ CONDITION LINUX AND TEST_linux_netlink
+)
+qt_feature("openssl" PRIVATE
+ LABEL "OpenSSL"
+ CONDITION QT_FEATURE_openssl_runtime OR QT_FEATURE_openssl_linked
+ ENABLE false
+)
+qt_feature_definition("openssl" "QT_NO_OPENSSL" NEGATE)
+qt_feature_config("openssl" QMAKE_PUBLIC_QT_CONFIG)
+qt_feature("openssl-runtime"
+ AUTODETECT NOT WINRT AND NOT WASM
+ CONDITION NOT QT_FEATURE_securetransport AND NOT QT_FEATURE_schannel AND OPENSSL_INCLUDE_DIR
+ ENABLE INPUT_openssl STREQUAL 'yes' OR INPUT_openssl STREQUAL 'runtime'
+ DISABLE INPUT_openssl STREQUAL 'no' OR INPUT_openssl STREQUAL 'linked' OR INPUT_ssl STREQUAL 'no'
+)
+qt_feature("openssl-linked" PRIVATE
+ LABEL " Qt directly linked to OpenSSL"
+ AUTODETECT OFF
+ CONDITION NOT QT_FEATURE_securetransport AND NOT QT_FEATURE_schannel AND OpenSSL_FOUND
+ ENABLE INPUT_openssl STREQUAL 'linked'
+)
+qt_feature_definition("openssl-linked" "QT_LINKED_OPENSSL")
+qt_feature("securetransport" PUBLIC
+ LABEL "SecureTransport"
+ CONDITION APPLE AND ( INPUT_openssl STREQUAL '' OR INPUT_openssl STREQUAL 'no' )
+ DISABLE INPUT_securetransport STREQUAL 'no' OR INPUT_ssl STREQUAL 'no'
+)
+qt_feature_definition("securetransport" "QT_SECURETRANSPORT")
+qt_feature("schannel" PUBLIC
+ LABEL "Schannel"
+ CONDITION INPUT_schannel STREQUAL 'yes' AND WIN32 AND NOT WINRT AND ( INPUT_openssl STREQUAL '' OR INPUT_openssl STREQUAL 'no' )
+ DISABLE INPUT_schannel STREQUAL 'no' OR INPUT_ssl STREQUAL 'no'
+)
+qt_feature_definition("schannel" "QT_SCHANNEL")
+qt_feature("ssl" PUBLIC
+ LABEL "SSL"
+ CONDITION WINRT OR QT_FEATURE_securetransport OR QT_FEATURE_openssl OR QT_FEATURE_schannel
+)
+qt_feature_definition("ssl" "QT_NO_SSL" NEGATE VALUE "1")
+qt_feature("dtls" PUBLIC
+ SECTION "Networking"
+ LABEL "DTLS"
+ PURPOSE "Provides a DTLS implementation"
+ CONDITION QT_FEATURE_openssl AND QT_FEATURE_udpsocket AND TEST_dtls
+)
+qt_feature("ocsp" PUBLIC
+ SECTION "Networking"
+ LABEL "OCSP-stapling"
+ PURPOSE "Provides OCSP stapling support"
+ CONDITION QT_FEATURE_opensslv11 AND TEST_ocsp
+)
+qt_feature("opensslv11" PUBLIC
+ LABEL "OpenSSL 1.1"
+ CONDITION QT_FEATURE_openssl
+)
+qt_feature("sctp" PUBLIC
+ LABEL "SCTP"
+ AUTODETECT OFF
+ CONDITION TEST_sctp
+)
+qt_feature_definition("sctp" "QT_NO_SCTP" NEGATE VALUE "1")
+qt_feature("system-proxies" PRIVATE
+ LABEL "Use system proxies"
+)
+qt_feature("ftp" PUBLIC
+ SECTION "Networking"
+ LABEL "FTP"
+ PURPOSE "Provides support for the File Transfer Protocol in QNetworkAccessManager."
+ CONDITION QT_FEATURE_textdate
+)
+qt_feature_definition("ftp" "QT_NO_FTP" NEGATE VALUE "1")
+qt_feature("http" PUBLIC
+ SECTION "Networking"
+ LABEL "HTTP"
+ PURPOSE "Provides support for the Hypertext Transfer Protocol in QNetworkAccessManager."
+ CONDITION QT_FEATURE_thread
+)
+qt_feature_definition("http" "QT_NO_HTTP" NEGATE VALUE "1")
+qt_feature("udpsocket" PUBLIC
+ SECTION "Networking"
+ LABEL "QUdpSocket"
+ PURPOSE "Provides access to UDP sockets."
+)
+qt_feature_definition("udpsocket" "QT_NO_UDPSOCKET" NEGATE VALUE "1")
+qt_feature("networkproxy" PUBLIC
+ SECTION "Networking"
+ LABEL "QNetworkProxy"
+ PURPOSE "Provides network proxy support."
+)
+qt_feature_definition("networkproxy" "QT_NO_NETWORKPROXY" NEGATE VALUE "1")
+qt_feature("socks5" PUBLIC
+ SECTION "Networking"
+ LABEL "SOCKS5"
+ PURPOSE "Provides SOCKS5 support in QNetworkProxy."
+ CONDITION QT_FEATURE_networkproxy
+)
+qt_feature_definition("socks5" "QT_NO_SOCKS5" NEGATE VALUE "1")
+qt_feature("networkinterface" PUBLIC
+ SECTION "Networking"
+ LABEL "QNetworkInterface"
+ PURPOSE "Supports enumerating a host's IP addresses and network interfaces."
+ CONDITION NOT WASM
+)
+qt_feature_definition("networkinterface" "QT_NO_NETWORKINTERFACE" NEGATE VALUE "1")
+qt_feature("networkdiskcache" PUBLIC
+ SECTION "Networking"
+ LABEL "QNetworkDiskCache"
+ PURPOSE "Provides a disk cache for network resources."
+ CONDITION QT_FEATURE_temporaryfile
+)
+qt_feature_definition("networkdiskcache" "QT_NO_NETWORKDISKCACHE" NEGATE VALUE "1")
+qt_feature("bearermanagement" PUBLIC
+ SECTION "Networking"
+ LABEL "Bearer management"
+ PURPOSE "Provides bearer management for the network stack."
+ CONDITION QT_FEATURE_thread AND QT_FEATURE_library AND QT_FEATURE_networkinterface AND QT_FEATURE_properties
+)
+qt_feature_definition("bearermanagement" "QT_NO_BEARERMANAGEMENT" NEGATE VALUE "1")
+qt_feature_definition("bearermanagement" "QT_NO_BEARERMANAGEMENT" NEGATE)
+qt_feature("localserver" PUBLIC
+ SECTION "Networking"
+ LABEL "QLocalServer"
+ PURPOSE "Provides a local socket based server."
+ CONDITION QT_FEATURE_temporaryfile
+)
+qt_feature_definition("localserver" "QT_NO_LOCALSERVER" NEGATE VALUE "1")
+qt_feature("dnslookup" PUBLIC
+ SECTION "Networking"
+ LABEL "QDnsLookup"
+ PURPOSE "Provides API for DNS lookups."
+)
+qt_feature("gssapi" PUBLIC
+ SECTION "Networking"
+ LABEL "GSSAPI"
+ PURPOSE "Enable SPNEGO authentication through GSSAPI"
+ CONDITION NOT WIN32 AND GSSAPI_FOUND
+)
+qt_feature_definition("gssapi" "QT_NO_GSSAPI" NEGATE VALUE "1")
+qt_feature("sspi" PUBLIC
+ SECTION "Networking"
+ LABEL "SSPI"
+ PURPOSE "Enable NTLM/SPNEGO authentication through SSPI"
+ CONDITION WIN32 AND NOT WINRT
+)
+qt_feature_definition("sspi" "QT_NO_SSPI" NEGATE VALUE "1")
+qt_feature("netlistmgr" PRIVATE
+ SECTION "Networking"
+ LABEL "Network List Manager"
+ PURPOSE "Use Network List Manager to keep track of network connectivity"
+ CONDITION WIN32 AND TEST_netlistmgr
+)
diff --git a/src/network/configure.json b/src/network/configure.json
index 496401749f..1f1e6fafbf 100644
--- a/src/network/configure.json
+++ b/src/network/configure.json
@@ -446,15 +446,7 @@ For example:
{
"type": "warning",
"condition": "features.libproxy && input.qt_namespace == ''",
- "message": "Some of libproxy's plugins may use incompatible Qt versions.
-
- Some platforms and distributions ship libproxy with plugins, such
- as config_kde4.so, that are linked against old versions of Qt; and
- libproxy loads these plugins automatically when initialized. If Qt
- is not in a namespace, that loading causes a crash. Even if the
- systems on which you build and test have no such plugins, your
- users' systems may have them. We therefore recommend that you
- combine -libproxy with -qtnamespace when configuring Qt."
+ "message": "Some of libproxy's plugins may use incompatible Qt versions. Some platforms and distributions ship libproxy with plugins, such as config_kde4.so, that are linked against old versions of Qt; and libproxy loads these plugins automatically when initialized. If Qt is not in a namespace, that loading causes a crash. Even if the systems on which you build and test have no such plugins, your users' systems may have them. We therefore recommend that you combine -libproxy with -qtnamespace when configuring Qt."
}
],
diff --git a/src/network/socket/qabstractsocketengine.cpp b/src/network/socket/qabstractsocketengine.cpp
index 54c7452c66..44139ff81d 100644
--- a/src/network/socket/qabstractsocketengine.cpp
+++ b/src/network/socket/qabstractsocketengine.cpp
@@ -274,3 +274,5 @@ int QAbstractSocketEngine::outboundStreamCount() const
}
QT_END_NAMESPACE
+
+#include "moc_qabstractsocketengine_p.cpp"
diff --git a/src/network/socket/qhttpsocketengine.cpp b/src/network/socket/qhttpsocketengine.cpp
index 9a26868edc..98f850ba1b 100644
--- a/src/network/socket/qhttpsocketengine.cpp
+++ b/src/network/socket/qhttpsocketengine.cpp
@@ -865,3 +865,5 @@ QAbstractSocketEngine *QHttpSocketEngineHandler::createSocketEngine(qintptr, QOb
QT_END_NAMESPACE
#endif // !QT_NO_NETWORKPROXY
+
+#include "moc_qhttpsocketengine_p.cpp"
diff --git a/src/network/socket/qnativesocketengine.cpp b/src/network/socket/qnativesocketengine.cpp
index 31628846dc..ad625b758e 100644
--- a/src/network/socket/qnativesocketengine.cpp
+++ b/src/network/socket/qnativesocketengine.cpp
@@ -1382,3 +1382,5 @@ void QNativeSocketEngine::setExceptionNotificationEnabled(bool enable)
}
QT_END_NAMESPACE
+
+#include "moc_qnativesocketengine_p.cpp"
diff --git a/src/network/socket/qsocks5socketengine.cpp b/src/network/socket/qsocks5socketengine.cpp
index 3bce891ee9..b2eefa352f 100644
--- a/src/network/socket/qsocks5socketengine.cpp
+++ b/src/network/socket/qsocks5socketengine.cpp
@@ -1927,3 +1927,5 @@ QAbstractSocketEngine *QSocks5SocketEngineHandler::createSocketEngine(qintptr so
}
QT_END_NAMESPACE
+
+#include "moc_qsocks5socketengine_p.cpp"
diff --git a/src/opengl/.prev_CMakeLists.txt b/src/opengl/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..85e382fa16
--- /dev/null
+++ b/src/opengl/.prev_CMakeLists.txt
@@ -0,0 +1,57 @@
+# Generated from opengl.pro.
+
+#####################################################################
+## OpenGL Module:
+#####################################################################
+
+qt_add_module(OpenGL
+ SOURCES
+ gl2paintengineex/qgl2pexvertexarray.cpp gl2paintengineex/qgl2pexvertexarray_p.h
+ gl2paintengineex/qglcustomshaderstage.cpp gl2paintengineex/qglcustomshaderstage_p.h
+ gl2paintengineex/qglengineshadermanager.cpp gl2paintengineex/qglengineshadermanager_p.h
+ gl2paintengineex/qglengineshadersource_p.h
+ gl2paintengineex/qglgradientcache.cpp gl2paintengineex/qglgradientcache_p.h
+ gl2paintengineex/qglshadercache_p.h
+ gl2paintengineex/qpaintengineex_opengl2.cpp gl2paintengineex/qpaintengineex_opengl2_p.h
+ gl2paintengineex/qtextureglyphcache_gl.cpp gl2paintengineex/qtextureglyphcache_gl_p.h
+ qgl.cpp qgl.h qgl_p.h
+ qglbuffer.cpp qglbuffer.h
+ qglcolormap.cpp qglcolormap.h
+ qglframebufferobject.cpp qglframebufferobject.h qglframebufferobject_p.h
+ qglfunctions.cpp qglfunctions.h
+ qglpaintdevice.cpp qglpaintdevice_p.h
+ qglpixelbuffer.cpp qglpixelbuffer.h qglpixelbuffer_p.h
+ qglshaderprogram.cpp qglshaderprogram.h
+ qtopenglglobal.h
+ DEFINES
+ QT_NO_FOREACH
+ QT_NO_USING_NAMESPACE
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(OpenGL CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x63000000"
+)
+
+#### Keys ignored in scope 3:.:.:opengl.pro:solaris-cc_x_:
+# QMAKE_CXXFLAGS_RELEASE = "--O2"
+
+qt_extend_target(OpenGL CONDITION QT_FEATURE_graphicseffect
+ SOURCES
+ qgraphicsshadereffect.cpp qgraphicsshadereffect_p.h
+)
+qt_add_docs(OpenGL
+ doc/qtopengl.qdocconf
+)
+
diff --git a/src/opengl/CMakeLists.txt b/src/opengl/CMakeLists.txt
new file mode 100644
index 0000000000..85e382fa16
--- /dev/null
+++ b/src/opengl/CMakeLists.txt
@@ -0,0 +1,57 @@
+# Generated from opengl.pro.
+
+#####################################################################
+## OpenGL Module:
+#####################################################################
+
+qt_add_module(OpenGL
+ SOURCES
+ gl2paintengineex/qgl2pexvertexarray.cpp gl2paintengineex/qgl2pexvertexarray_p.h
+ gl2paintengineex/qglcustomshaderstage.cpp gl2paintengineex/qglcustomshaderstage_p.h
+ gl2paintengineex/qglengineshadermanager.cpp gl2paintengineex/qglengineshadermanager_p.h
+ gl2paintengineex/qglengineshadersource_p.h
+ gl2paintengineex/qglgradientcache.cpp gl2paintengineex/qglgradientcache_p.h
+ gl2paintengineex/qglshadercache_p.h
+ gl2paintengineex/qpaintengineex_opengl2.cpp gl2paintengineex/qpaintengineex_opengl2_p.h
+ gl2paintengineex/qtextureglyphcache_gl.cpp gl2paintengineex/qtextureglyphcache_gl_p.h
+ qgl.cpp qgl.h qgl_p.h
+ qglbuffer.cpp qglbuffer.h
+ qglcolormap.cpp qglcolormap.h
+ qglframebufferobject.cpp qglframebufferobject.h qglframebufferobject_p.h
+ qglfunctions.cpp qglfunctions.h
+ qglpaintdevice.cpp qglpaintdevice_p.h
+ qglpixelbuffer.cpp qglpixelbuffer.h qglpixelbuffer_p.h
+ qglshaderprogram.cpp qglshaderprogram.h
+ qtopenglglobal.h
+ DEFINES
+ QT_NO_FOREACH
+ QT_NO_USING_NAMESPACE
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(OpenGL CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x63000000"
+)
+
+#### Keys ignored in scope 3:.:.:opengl.pro:solaris-cc_x_:
+# QMAKE_CXXFLAGS_RELEASE = "--O2"
+
+qt_extend_target(OpenGL CONDITION QT_FEATURE_graphicseffect
+ SOURCES
+ qgraphicsshadereffect.cpp qgraphicsshadereffect_p.h
+)
+qt_add_docs(OpenGL
+ doc/qtopengl.qdocconf
+)
+
diff --git a/src/openglextensions/CMakeLists.txt b/src/openglextensions/CMakeLists.txt
new file mode 100644
index 0000000000..d2fc027398
--- /dev/null
+++ b/src/openglextensions/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from openglextensions.pro.
+
+#####################################################################
+## OpenGLExtensions Module:
+#####################################################################
+
+qt_add_module(OpenGLExtensions
+ STATIC
+ SOURCES
+ qopenglextensions.cpp qopenglextensions.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
diff --git a/src/platformheaders/.prev_CMakeLists.txt b/src/platformheaders/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..5456de5c80
--- /dev/null
+++ b/src/platformheaders/.prev_CMakeLists.txt
@@ -0,0 +1,2 @@
+# Generated from platformheaders.pro.
+
diff --git a/src/platformheaders/CMakeLists.txt b/src/platformheaders/CMakeLists.txt
new file mode 100644
index 0000000000..820bbb71a5
--- /dev/null
+++ b/src/platformheaders/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from platformheaders.pro.
+
+# special case begin
+
+# FIXME Add the rest of the stuff? I don't think any other stuff is needed?
+
+qt_add_module(PlatformHeaders HEADER_MODULE)
+
+qt_add_docs(PlatformHeaders
+ doc/qtplatformheaders.qdocconf
+)
+
+# special case end
diff --git a/src/platformheaders/fake.cpp b/src/platformheaders/fake.cpp
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/src/platformheaders/fake.cpp
diff --git a/src/platformsupport/CMakeLists.txt b/src/platformsupport/CMakeLists.txt
new file mode 100644
index 0000000000..fc980f3707
--- /dev/null
+++ b/src/platformsupport/CMakeLists.txt
@@ -0,0 +1,49 @@
+# Generated from platformsupport.pro.
+
+add_subdirectory(edid)
+add_subdirectory(eventdispatchers)
+add_subdirectory(devicediscovery)
+add_subdirectory(fbconvenience)
+add_subdirectory(themes)
+# special case begin
+if (QT_FEATURE_dbus)
+ add_subdirectory(linuxofono)
+endif()
+# special case end
+if(APPLE OR QT_FEATURE_freetype OR WIN32)
+ add_subdirectory(fontdatabases)
+endif()
+if(QT_FEATURE_evdev OR QT_FEATURE_integrityhid OR QT_FEATURE_libinput OR QT_FEATURE_tslib)
+ add_subdirectory(input)
+endif()
+if(QT_FEATURE_xcb OR (UNIX AND NOT APPLE_UIKIT))
+ add_subdirectory(services)
+endif()
+if(QT_FEATURE_opengl)
+ add_subdirectory(platformcompositor)
+endif()
+if(QT_FEATURE_egl)
+ add_subdirectory(eglconvenience)
+endif()
+if(QT_FEATURE_opengl AND QT_FEATURE_xlib AND NOT QT_FEATURE_opengles2)
+ add_subdirectory(glxconvenience)
+endif()
+if(QT_FEATURE_kms)
+ add_subdirectory(kmsconvenience)
+endif()
+if(QT_FEATURE_accessibility)
+ add_subdirectory(accessibility)
+endif()
+if(QT_FEATURE_accessibility AND QT_FEATURE_accessibility_atspi_bridge)
+ add_subdirectory(linuxaccessibility)
+endif()
+if(QT_FEATURE_accessibility AND WIN32 AND NOT WINRT)
+ add_subdirectory(windowsuiautomation)
+endif()
+if(APPLE)
+ add_subdirectory(clipboard)
+ add_subdirectory(graphics)
+endif()
+if(QT_FEATURE_vulkan)
+ add_subdirectory(vkconvenience)
+endif()
diff --git a/src/platformsupport/accessibility/CMakeLists.txt b/src/platformsupport/accessibility/CMakeLists.txt
new file mode 100644
index 0000000000..35c1758b86
--- /dev/null
+++ b/src/platformsupport/accessibility/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from accessibility.pro.
+
+#####################################################################
+## AccessibilitySupport Module:
+#####################################################################
+
+qt_add_module(AccessibilitySupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qaccessiblebridgeutils.cpp qaccessiblebridgeutils_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:accessibility.pro:<TRUE>:
+# MODULE = "accessibility_support"
diff --git a/src/platformsupport/clipboard/CMakeLists.txt b/src/platformsupport/clipboard/CMakeLists.txt
new file mode 100644
index 0000000000..e6eb577973
--- /dev/null
+++ b/src/platformsupport/clipboard/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from clipboard.pro.
+
+#####################################################################
+## ClipboardSupport Module:
+#####################################################################
+
+qt_add_module(ClipboardSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qmacmime.mm qmacmime_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ ${FWImageIO}
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:clipboard.pro:<TRUE>:
+# MODULE = "clipboard_support"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(ClipboardSupport CONDITION APPLE_OSX
+ LIBRARIES
+ ${FWAppKit}
+)
diff --git a/src/platformsupport/devicediscovery/CMakeLists.txt b/src/platformsupport/devicediscovery/CMakeLists.txt
new file mode 100644
index 0000000000..47ce31a66a
--- /dev/null
+++ b/src/platformsupport/devicediscovery/CMakeLists.txt
@@ -0,0 +1,42 @@
+# Generated from devicediscovery.pro.
+
+#####################################################################
+## DeviceDiscoverySupport Module:
+#####################################################################
+
+qt_add_module(DeviceDiscoverySupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qdevicediscovery_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:devicediscovery.pro:<TRUE>:
+# MODULE = "devicediscovery_support"
+# QT_FOR_CONFIG = "gui-private"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(DeviceDiscoverySupport CONDITION QT_FEATURE_libudev
+ SOURCES
+ qdevicediscovery_udev.cpp qdevicediscovery_udev_p.h
+ LIBRARIES
+ PkgConfig::Libudev
+)
+
+qt_extend_target(DeviceDiscoverySupport CONDITION QT_FEATURE_evdev AND NOT QT_FEATURE_libudev
+ SOURCES
+ qdevicediscovery_static.cpp qdevicediscovery_static_p.h
+)
+
+qt_extend_target(DeviceDiscoverySupport CONDITION NOT QT_FEATURE_evdev AND NOT QT_FEATURE_libudev
+ SOURCES
+ qdevicediscovery_dummy.cpp qdevicediscovery_dummy_p.h
+)
diff --git a/src/platformsupport/edid/CMakeLists.txt b/src/platformsupport/edid/CMakeLists.txt
new file mode 100644
index 0000000000..e27aa34335
--- /dev/null
+++ b/src/platformsupport/edid/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from edid.pro.
+
+#####################################################################
+## EdidSupport Module:
+#####################################################################
+
+qt_add_module(EdidSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qedidparser.cpp qedidparser_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:edid.pro:<TRUE>:
+# MODULE = "edid_support"
diff --git a/src/platformsupport/eglconvenience/.prev_CMakeLists.txt b/src/platformsupport/eglconvenience/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..2d31b07cea
--- /dev/null
+++ b/src/platformsupport/eglconvenience/.prev_CMakeLists.txt
@@ -0,0 +1,53 @@
+# Generated from eglconvenience.pro.
+
+#####################################################################
+## EglSupport Module:
+#####################################################################
+
+qt_add_module(EglSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qeglconvenience.cpp qeglconvenience_p.h
+ qeglstreamconvenience.cpp qeglstreamconvenience_p.h
+ qt_egl_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:eglconvenience.pro:<TRUE>:
+# MODULE = "egl_support"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(EglSupport CONDITION QT_FEATURE_opengl
+ SOURCES
+ qeglpbuffer.cpp qeglpbuffer_p.h
+ qeglplatformcontext.cpp qeglplatformcontext_p.h
+)
+
+qt_extend_target(EglSupport CONDITION QT_FEATURE_egl_x11
+ SOURCES
+ qxlibeglintegration.cpp qxlibeglintegration_p.h
+ LIBRARIES
+ X11::XCB
+)
+
+qt_extend_target(EglSupport CONDITION NOT QT_FEATURE_egl_x11
+ DEFINES
+ QT_EGL_NO_X11
+)
+
+qt_extend_target(EglSupport CONDITION QT_FEATURE_dlopen
+ PUBLIC_LIBRARIES
+ ${CMAKE_DL_LIBS}
+)
diff --git a/src/platformsupport/eglconvenience/CMakeLists.txt b/src/platformsupport/eglconvenience/CMakeLists.txt
new file mode 100644
index 0000000000..0c56acd711
--- /dev/null
+++ b/src/platformsupport/eglconvenience/CMakeLists.txt
@@ -0,0 +1,56 @@
+# Generated from eglconvenience.pro.
+
+#####################################################################
+## EglSupport Module:
+#####################################################################
+
+qt_find_package(EGL) # special case
+
+qt_add_module(EglSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qeglconvenience.cpp qeglconvenience_p.h
+ qeglstreamconvenience.cpp qeglstreamconvenience_p.h
+ qt_egl_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ EGL::EGL # special case
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:eglconvenience.pro:<TRUE>:
+# MODULE = "egl_support"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(EglSupport CONDITION QT_FEATURE_opengl
+ SOURCES
+ qeglpbuffer.cpp qeglpbuffer_p.h
+ qeglplatformcontext.cpp qeglplatformcontext_p.h
+)
+
+qt_extend_target(EglSupport CONDITION QT_FEATURE_egl_x11
+ SOURCES
+ qxlibeglintegration.cpp qxlibeglintegration_p.h
+ LIBRARIES
+ X11::XCB
+)
+
+qt_extend_target(EglSupport CONDITION NOT QT_FEATURE_egl_x11
+ DEFINES
+ QT_EGL_NO_X11
+)
+
+qt_extend_target(EglSupport CONDITION QT_FEATURE_dlopen
+ PUBLIC_LIBRARIES
+ ${CMAKE_DL_LIBS}
+)
diff --git a/src/platformsupport/eventdispatchers/.prev_CMakeLists.txt b/src/platformsupport/eventdispatchers/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..3a02b06bdd
--- /dev/null
+++ b/src/platformsupport/eventdispatchers/.prev_CMakeLists.txt
@@ -0,0 +1,45 @@
+# Generated from eventdispatchers.pro.
+
+#####################################################################
+## EventDispatcherSupport Module:
+#####################################################################
+
+qt_add_module(EventDispatcherSupport
+ STATIC
+ INTERNAL_MODULE
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:eventdispatchers.pro:<TRUE>:
+# MODULE = "eventdispatcher_support"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(EventDispatcherSupport CONDITION UNIX
+ SOURCES
+ qgenericunixeventdispatcher.cpp qgenericunixeventdispatcher_p.h
+ qunixeventdispatcher.cpp
+ qunixeventdispatcher_qpa_p.h
+)
+
+qt_extend_target(EventDispatcherSupport CONDITION WIN32
+ SOURCES
+ qwindowsguieventdispatcher.cpp qwindowsguieventdispatcher_p.h
+)
+
+qt_extend_target(EventDispatcherSupport CONDITION QT_FEATURE_glib
+ SOURCES
+ qeventdispatcher_glib.cpp qeventdispatcher_glib_p.h
+ LIBRARIES
+ GLIB2::GLIB2
+)
diff --git a/src/platformsupport/eventdispatchers/CMakeLists.txt b/src/platformsupport/eventdispatchers/CMakeLists.txt
new file mode 100644
index 0000000000..74ffbe5cbb
--- /dev/null
+++ b/src/platformsupport/eventdispatchers/CMakeLists.txt
@@ -0,0 +1,47 @@
+# Generated from eventdispatchers.pro.
+
+qt_find_package(GLIB2) # special case
+
+#####################################################################
+## EventDispatcherSupport Module:
+#####################################################################
+
+qt_add_module(EventDispatcherSupport
+ STATIC
+ INTERNAL_MODULE
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:eventdispatchers.pro:<TRUE>:
+# MODULE = "eventdispatcher_support"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(EventDispatcherSupport CONDITION UNIX
+ SOURCES
+ qgenericunixeventdispatcher.cpp qgenericunixeventdispatcher_p.h
+ qunixeventdispatcher.cpp
+ qunixeventdispatcher_qpa_p.h
+)
+
+qt_extend_target(EventDispatcherSupport CONDITION WIN32
+ SOURCES
+ qwindowsguieventdispatcher.cpp qwindowsguieventdispatcher_p.h
+)
+
+qt_extend_target(EventDispatcherSupport CONDITION QT_FEATURE_glib
+ SOURCES
+ qeventdispatcher_glib.cpp qeventdispatcher_glib_p.h
+ LIBRARIES
+ GLIB2::GLIB2
+)
diff --git a/src/platformsupport/fbconvenience/CMakeLists.txt b/src/platformsupport/fbconvenience/CMakeLists.txt
new file mode 100644
index 0000000000..458c169e76
--- /dev/null
+++ b/src/platformsupport/fbconvenience/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from fbconvenience.pro.
+
+#####################################################################
+## FbSupport Module:
+#####################################################################
+
+qt_add_module(FbSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qfbbackingstore.cpp qfbbackingstore_p.h
+ qfbcursor.cpp qfbcursor_p.h
+ qfbscreen.cpp qfbscreen_p.h
+ qfbvthandler.cpp qfbvthandler_p.h
+ qfbwindow.cpp qfbwindow_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:fbconvenience.pro:<TRUE>:
+# MODULE = "fb_support"
diff --git a/src/platformsupport/fontdatabases/.prev_CMakeLists.txt b/src/platformsupport/fontdatabases/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..cdc85fc4c9
--- /dev/null
+++ b/src/platformsupport/fontdatabases/.prev_CMakeLists.txt
@@ -0,0 +1,130 @@
+# Generated from fontdatabases.pro.
+
+#####################################################################
+## FontDatabaseSupport Module:
+#####################################################################
+
+qt_add_module(FontDatabaseSupport
+ STATIC
+ INTERNAL_MODULE
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:fontdatabases.pro:<TRUE>:
+# MODULE = "fontdatabase_support"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(FontDatabaseSupport CONDITION APPLE
+ SOURCES
+ mac/qcoretextfontdatabase.mm mac/qcoretextfontdatabase_p.h
+ mac/qfontengine_coretext.mm mac/qfontengine_coretext_p.h
+ LIBRARIES
+ ${FWCoreFoundation}
+ ${FWCoreGraphics}
+ ${FWCoreText}
+ ${FWFoundation}
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION APPLE_OSX
+ LIBRARIES
+ ${FWAppKit}
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION APPLE AND NOT APPLE_OSX
+ LIBRARIES
+ ${FWUIKit}
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION QT_FEATURE_freetype
+ SOURCES
+ freetype/qfontengine_ft.cpp freetype/qfontengine_ft_p.h
+ freetype/qfreetypefontdatabase.cpp freetype/qfreetypefontdatabase_p.h
+ LIBRARIES
+ WrapFreetype::WrapFreetype
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION UNIX
+ SOURCES
+ genericunix/qgenericunixfontdatabase_p.h
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION QT_FEATURE_fontconfig AND UNIX
+ SOURCES
+ fontconfig/qfontconfigdatabase.cpp fontconfig/qfontconfigdatabase_p.h
+ fontconfig/qfontenginemultifontconfig.cpp fontconfig/qfontenginemultifontconfig_p.h
+ LIBRARIES
+ Fontconfig::Fontconfig
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION WIN32 AND NOT WINRT
+ SOURCES
+ windows/qwindowsfontdatabase.cpp windows/qwindowsfontdatabase_p.h
+ windows/qwindowsfontengine.cpp windows/qwindowsfontengine_p.h
+ windows/qwindowsnativeimage.cpp windows/qwindowsnativeimage_p.h
+ LIBRARIES
+ Qt::GuiPrivate
+ advapi32
+ gdi32
+ ole32
+ user32
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION QT_FEATURE_freetype AND WIN32 AND NOT WINRT
+ SOURCES
+ windows/qwindowsfontdatabase_ft.cpp windows/qwindowsfontdatabase_ft_p.h
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION QT_FEATURE_direct2d AND QT_FEATURE_directwrite AND WIN32 AND NOT WINRT
+ SOURCES
+ windows/qwindowsfontenginedirectwrite.cpp windows/qwindowsfontenginedirectwrite_p.h
+ LIBRARIES
+ d2d1
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION QT_FEATURE_direct2d AND QT_FEATURE_directwrite AND QT_FEATURE_directwrite2 AND WIN32 AND NOT WINRT
+ DEFINES
+ QT_USE_DIRECTWRITE2
+ LIBRARIES
+ dwrite_2
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION QT_FEATURE_direct2d AND QT_FEATURE_directwrite AND WIN32 AND NOT QT_FEATURE_directwrite2 AND NOT WINRT
+ LIBRARIES
+ dwrite
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION WIN32 AND NOT WINRT AND (NOT QT_FEATURE_direct2d OR NOT QT_FEATURE_directwrite)
+ DEFINES
+ QT_NO_DIRECTWRITE
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION WIN32 AND mingw AND NOT WINRT
+ LIBRARIES
+ uuid
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION WINRT
+ SOURCES
+ winrt/qwinrtfontdatabase.cpp winrt/qwinrtfontdatabase_p.h
+ DEFINES
+ __WRL_NO_DEFAULT_LIB__
+ LIBRARIES
+ Qt::GuiPrivate
+ dwrite_1
+ ws2_32
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/src/platformsupport/fontdatabases/CMakeLists.txt b/src/platformsupport/fontdatabases/CMakeLists.txt
new file mode 100644
index 0000000000..e17abc3f3a
--- /dev/null
+++ b/src/platformsupport/fontdatabases/CMakeLists.txt
@@ -0,0 +1,133 @@
+# Generated from fontdatabases.pro.
+
+qt_find_package(WrapFreetype) # special case
+qt_find_package(Fontconfig) # special case
+
+#####################################################################
+## FontDatabaseSupport Module:
+#####################################################################
+
+qt_add_module(FontDatabaseSupport
+ STATIC
+ INTERNAL_MODULE
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:fontdatabases.pro:<TRUE>:
+# MODULE = "fontdatabase_support"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(FontDatabaseSupport CONDITION APPLE
+ SOURCES
+ mac/qcoretextfontdatabase.mm mac/qcoretextfontdatabase_p.h
+ mac/qfontengine_coretext.mm mac/qfontengine_coretext_p.h
+ LIBRARIES
+ ${FWCoreFoundation}
+ ${FWCoreGraphics}
+ ${FWCoreText}
+ ${FWFoundation}
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION APPLE_OSX
+ LIBRARIES
+ ${FWAppKit}
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION APPLE AND NOT APPLE_OSX
+ LIBRARIES
+ ${FWUIKit}
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION QT_FEATURE_freetype
+ SOURCES
+ freetype/qfontengine_ft.cpp freetype/qfontengine_ft_p.h
+ freetype/qfreetypefontdatabase.cpp freetype/qfreetypefontdatabase_p.h
+ LIBRARIES
+ WrapFreetype::WrapFreetype
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION UNIX
+ SOURCES
+ genericunix/qgenericunixfontdatabase_p.h
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION QT_FEATURE_fontconfig AND UNIX
+ SOURCES
+ fontconfig/qfontconfigdatabase.cpp fontconfig/qfontconfigdatabase_p.h
+ fontconfig/qfontenginemultifontconfig.cpp fontconfig/qfontenginemultifontconfig_p.h
+ LIBRARIES
+ Fontconfig::Fontconfig
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION WIN32 AND NOT WINRT
+ SOURCES
+ windows/qwindowsfontdatabase.cpp windows/qwindowsfontdatabase_p.h
+ windows/qwindowsfontengine.cpp windows/qwindowsfontengine_p.h
+ windows/qwindowsnativeimage.cpp windows/qwindowsnativeimage_p.h
+ LIBRARIES
+ Qt::GuiPrivate
+ advapi32
+ gdi32
+ ole32
+ user32
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION QT_FEATURE_freetype AND WIN32 AND NOT WINRT
+ SOURCES
+ windows/qwindowsfontdatabase_ft.cpp windows/qwindowsfontdatabase_ft_p.h
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION QT_FEATURE_direct2d AND QT_FEATURE_directwrite AND WIN32 AND NOT WINRT
+ SOURCES
+ windows/qwindowsfontenginedirectwrite.cpp windows/qwindowsfontenginedirectwrite_p.h
+ LIBRARIES
+ d2d1
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION QT_FEATURE_direct2d AND QT_FEATURE_directwrite AND QT_FEATURE_directwrite2 AND WIN32 AND NOT WINRT
+ DEFINES
+ QT_USE_DIRECTWRITE2
+ LIBRARIES
+ dwrite_2
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION QT_FEATURE_direct2d AND QT_FEATURE_directwrite AND WIN32 AND NOT QT_FEATURE_directwrite2 AND NOT WINRT
+ LIBRARIES
+ dwrite
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION WIN32 AND NOT WINRT AND (NOT QT_FEATURE_direct2d OR NOT QT_FEATURE_directwrite)
+ DEFINES
+ QT_NO_DIRECTWRITE
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION WIN32 AND mingw AND NOT WINRT
+ LIBRARIES
+ uuid
+)
+
+qt_extend_target(FontDatabaseSupport CONDITION WINRT
+ SOURCES
+ winrt/qwinrtfontdatabase.cpp winrt/qwinrtfontdatabase_p.h
+ DEFINES
+ __WRL_NO_DEFAULT_LIB__
+ LIBRARIES
+ Qt::GuiPrivate
+ dwrite_1
+ ws2_32
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/src/platformsupport/fontdatabases/fake.cpp b/src/platformsupport/fontdatabases/fake.cpp
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/src/platformsupport/fontdatabases/fake.cpp
diff --git a/src/platformsupport/glxconvenience/.prev_CMakeLists.txt b/src/platformsupport/glxconvenience/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..4e5e7378d4
--- /dev/null
+++ b/src/platformsupport/glxconvenience/.prev_CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from glxconvenience.pro.
+
+#####################################################################
+## GlxSupport Module:
+#####################################################################
+
+qt_add_module(GlxSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qglxconvenience.cpp qglxconvenience_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ X11::XCB
+)
+
+#### Keys ignored in scope 1:.:.:glxconvenience.pro:<TRUE>:
+# MODULE = "glx_support"
diff --git a/src/platformsupport/glxconvenience/CMakeLists.txt b/src/platformsupport/glxconvenience/CMakeLists.txt
new file mode 100644
index 0000000000..9d687f22a1
--- /dev/null
+++ b/src/platformsupport/glxconvenience/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from glxconvenience.pro.
+
+qt_find_package(X11) # special case
+
+#####################################################################
+## GlxSupport Module:
+#####################################################################
+
+qt_add_module(GlxSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qglxconvenience.cpp qglxconvenience_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ X11::X11 # special case
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:glxconvenience.pro:<TRUE>:
+# MODULE = "glx_support"
diff --git a/src/platformsupport/graphics/CMakeLists.txt b/src/platformsupport/graphics/CMakeLists.txt
new file mode 100644
index 0000000000..cbb9e0937b
--- /dev/null
+++ b/src/platformsupport/graphics/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from graphics.pro.
+
+#####################################################################
+## GraphicsSupport Module:
+#####################################################################
+
+qt_add_module(GraphicsSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qrasterbackingstore.cpp qrasterbackingstore_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:graphics.pro:<TRUE>:
+# MODULE = "graphics_support"
diff --git a/src/platformsupport/input/.prev_CMakeLists.txt b/src/platformsupport/input/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..15ce6207f2
--- /dev/null
+++ b/src/platformsupport/input/.prev_CMakeLists.txt
@@ -0,0 +1,107 @@
+# Generated from input.pro.
+
+#####################################################################
+## InputSupport Module:
+#####################################################################
+
+qt_add_module(InputSupport
+ STATIC
+ INTERNAL_MODULE
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DeviceDiscoverySupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::DeviceDiscoverySupport
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 3:.:.:input-support.pro:<TRUE>:
+# MODULE = "input_support"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_evdev
+ SOURCES
+ evdevkeyboard/qevdevkeyboard_defaultmap_p.h
+ evdevkeyboard/qevdevkeyboardhandler.cpp evdevkeyboard/qevdevkeyboardhandler_p.h
+ evdevkeyboard/qevdevkeyboardmanager.cpp evdevkeyboard/qevdevkeyboardmanager_p.h
+ evdevmouse/qevdevmousehandler.cpp evdevmouse/qevdevmousehandler_p.h
+ evdevmouse/qevdevmousemanager.cpp evdevmouse/qevdevmousemanager_p.h
+ evdevtouch/qevdevtouchhandler.cpp evdevtouch/qevdevtouchhandler_p.h
+ evdevtouch/qevdevtouchmanager.cpp evdevtouch/qevdevtouchmanager_p.h
+ INCLUDE_DIRECTORIES
+ evdevtouch/../shared
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_evdev AND QT_FEATURE_tabletevent
+ SOURCES
+ evdevtablet/qevdevtablethandler.cpp evdevtablet/qevdevtablethandler_p.h
+ evdevtablet/qevdevtabletmanager.cpp evdevtablet/qevdevtabletmanager_p.h
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_evdev AND QT_FEATURE_libudev AND QT_FEATURE_tabletevent
+ LIBRARIES
+ PkgConfig::Libudev
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_evdev AND QT_FEATURE_libudev
+ LIBRARIES
+ PkgConfig::Libudev
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_evdev AND QT_FEATURE_mtdev
+ LIBRARIES
+ PkgConfig::Mtdev
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_tslib
+ SOURCES
+ tslib/qtslib.cpp tslib/qtslib_p.h
+ PUBLIC_LIBRARIES
+ PkgConfig::Tslib
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_libinput
+ SOURCES
+ libinput/qlibinputhandler.cpp libinput/qlibinputhandler_p.h
+ libinput/qlibinputkeyboard.cpp libinput/qlibinputkeyboard_p.h
+ libinput/qlibinputpointer.cpp libinput/qlibinputpointer_p.h
+ libinput/qlibinputtouch.cpp libinput/qlibinputtouch_p.h
+ INCLUDE_DIRECTORIES
+ libinput/../shared
+ LIBRARIES
+ Libinput::Libinput
+ PkgConfig::Libudev
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_libinput AND QT_FEATURE_xkbcommon
+ LIBRARIES
+ Qt::XkbCommonSupportPrivate
+ XKB::XKB
+ PUBLIC_LIBRARIES
+ Qt::XkbCommonSupport
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_evdev OR QT_FEATURE_libinput
+ SOURCES
+ shared/devicehandlerlist_p.h
+ shared/qevdevutil.cpp shared/qevdevutil_p.h
+ shared/qtouchoutputmapping.cpp shared/qtouchoutputmapping_p.h
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_integrityhid
+ SOURCES
+ integrityhid/qintegrityhidmanager.cpp integrityhid/qintegrityhidmanager.h
+ LIBRARIES
+ integrityhid
+)
+if(QT_FEATURE_xkbcommon)
+ add_subdirectory(xkbcommon)
+endif()
diff --git a/src/platformsupport/input/CMakeLists.txt b/src/platformsupport/input/CMakeLists.txt
new file mode 100644
index 0000000000..d19363b6a3
--- /dev/null
+++ b/src/platformsupport/input/CMakeLists.txt
@@ -0,0 +1,112 @@
+# Generated from input.pro.
+
+qt_find_package(Libinput) # special case
+qt_find_package(XKB) # special case
+qt_find_package(Tslib) # special case
+qt_find_package(Mtdev) # special case
+
+#####################################################################
+## InputSupport Module:
+#####################################################################
+
+qt_add_module(InputSupport
+ STATIC
+ INTERNAL_MODULE
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DeviceDiscoverySupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::DeviceDiscoverySupport
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 3:.:.:input-support.pro:<TRUE>:
+# MODULE = "input_support"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_evdev
+ SOURCES
+ evdevkeyboard/qevdevkeyboard_defaultmap_p.h
+ evdevkeyboard/qevdevkeyboardhandler.cpp evdevkeyboard/qevdevkeyboardhandler_p.h
+ evdevkeyboard/qevdevkeyboardmanager.cpp evdevkeyboard/qevdevkeyboardmanager_p.h
+ evdevmouse/qevdevmousehandler.cpp evdevmouse/qevdevmousehandler_p.h
+ evdevmouse/qevdevmousemanager.cpp evdevmouse/qevdevmousemanager_p.h
+ evdevtouch/qevdevtouchhandler.cpp evdevtouch/qevdevtouchhandler_p.h
+ evdevtouch/qevdevtouchmanager.cpp evdevtouch/qevdevtouchmanager_p.h
+ INCLUDE_DIRECTORIES
+ evdevtouch/../shared
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_evdev AND QT_FEATURE_tabletevent
+ SOURCES
+ evdevtablet/qevdevtablethandler.cpp evdevtablet/qevdevtablethandler_p.h
+ evdevtablet/qevdevtabletmanager.cpp evdevtablet/qevdevtabletmanager_p.h
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_evdev AND QT_FEATURE_libudev AND QT_FEATURE_tabletevent
+ LIBRARIES
+ PkgConfig::Libudev
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_evdev AND QT_FEATURE_libudev
+ LIBRARIES
+ PkgConfig::Libudev
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_evdev AND QT_FEATURE_mtdev
+ LIBRARIES
+ PkgConfig::Mtdev
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_tslib
+ SOURCES
+ tslib/qtslib.cpp tslib/qtslib_p.h
+ PUBLIC_LIBRARIES
+ PkgConfig::Tslib
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_libinput
+ SOURCES
+ libinput/qlibinputhandler.cpp libinput/qlibinputhandler_p.h
+ libinput/qlibinputkeyboard.cpp libinput/qlibinputkeyboard_p.h
+ libinput/qlibinputpointer.cpp libinput/qlibinputpointer_p.h
+ libinput/qlibinputtouch.cpp libinput/qlibinputtouch_p.h
+ INCLUDE_DIRECTORIES
+ libinput/../shared
+ LIBRARIES
+ Libinput::Libinput
+ PkgConfig::Libudev
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_libinput AND QT_FEATURE_xkbcommon
+ LIBRARIES
+ Qt::XkbCommonSupportPrivate
+ XKB::XKB
+ PUBLIC_LIBRARIES
+ Qt::XkbCommonSupport
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_evdev OR QT_FEATURE_libinput
+ SOURCES
+ shared/devicehandlerlist_p.h
+ shared/qevdevutil.cpp shared/qevdevutil_p.h
+ shared/qtouchoutputmapping.cpp shared/qtouchoutputmapping_p.h
+)
+
+qt_extend_target(InputSupport CONDITION QT_FEATURE_integrityhid
+ SOURCES
+ integrityhid/qintegrityhidmanager.cpp integrityhid/qintegrityhidmanager.h
+ LIBRARIES
+ integrityhid
+)
+if(QT_FEATURE_xkbcommon)
+ add_subdirectory(xkbcommon)
+endif()
diff --git a/src/platformsupport/input/xkbcommon/CMakeLists.txt b/src/platformsupport/input/xkbcommon/CMakeLists.txt
new file mode 100644
index 0000000000..18d07932d4
--- /dev/null
+++ b/src/platformsupport/input/xkbcommon/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from xkbcommon.pro.
+
+#####################################################################
+## XkbCommonSupport Module:
+#####################################################################
+
+qt_add_module(XkbCommonSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qxkbcommon.cpp qxkbcommon_p.h
+ qxkbcommon_3rdparty.cpp
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ XKB::XKB
+ PRECOMPILED_HEADER
+ "../../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:xkbcommon.pro:<TRUE>:
+# MODULE = "xkbcommon_support"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(XkbCommonSupport CONDITION CLANG AND NOT ICC
+ COMPILE_OPTIONS
+ -ftemplate-depth=1024
+)
diff --git a/src/platformsupport/kmsconvenience/.prev_CMakeLists.txt b/src/platformsupport/kmsconvenience/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..500288db57
--- /dev/null
+++ b/src/platformsupport/kmsconvenience/.prev_CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from kmsconvenience.pro.
+
+#####################################################################
+## KmsSupport Module:
+#####################################################################
+
+qt_add_module(KmsSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qkmsdevice.cpp qkmsdevice_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Libdrm::Libdrm
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:kmsconvenience.pro:<TRUE>:
+# MODULE = "kms_support"
diff --git a/src/platformsupport/kmsconvenience/CMakeLists.txt b/src/platformsupport/kmsconvenience/CMakeLists.txt
new file mode 100644
index 0000000000..08e89f5f07
--- /dev/null
+++ b/src/platformsupport/kmsconvenience/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from kmsconvenience.pro.
+
+qt_find_package(Libdrm) # special case
+
+#####################################################################
+## KmsSupport Module:
+#####################################################################
+
+qt_add_module(KmsSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qkmsdevice.cpp qkmsdevice_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Libdrm::Libdrm
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:kmsconvenience.pro:<TRUE>:
+# MODULE = "kms_support"
diff --git a/src/platformsupport/linuxaccessibility/.prev_CMakeLists.txt b/src/platformsupport/linuxaccessibility/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..6c9b8621ab
--- /dev/null
+++ b/src/platformsupport/linuxaccessibility/.prev_CMakeLists.txt
@@ -0,0 +1,45 @@
+# Generated from linuxaccessibility.pro.
+
+#####################################################################
+## LinuxAccessibilitySupport Module:
+#####################################################################
+
+qt_add_module(LinuxAccessibilitySupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ application.cpp application_p.h
+ atspiadaptor.cpp atspiadaptor_p.h
+ bridge.cpp bridge_p.h
+ cache.cpp cache_p.h
+ constant_mappings.cpp constant_mappings_p.h
+ dbusconnection.cpp dbusconnection_p.h
+ struct_marshallers.cpp struct_marshallers_p.h
+ DBUS_ADAPTOR_SOURCES
+ dbusxml/Cache.xml
+ dbusxml/DeviceEventController.xml
+ DBUS_ADAPTOR_FLAGS
+ "-i" "struct_marshallers_p.h"
+ DBUS_INTERFACE_SOURCES
+ dbusxml/Bus.xml
+ dbusxml/Socket.xml
+ DBUS_INTERFACE_FLAGS
+ "-i" "struct_marshallers_p.h"
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::AccessibilitySupportPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ PkgConfig::ATSPI2_nolink
+ Qt::AccessibilitySupport
+ Qt::Core
+ Qt::DBus
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:linuxaccessibility.pro:<TRUE>:
+# MODULE = "linuxaccessibility_support"
diff --git a/src/platformsupport/linuxaccessibility/CMakeLists.txt b/src/platformsupport/linuxaccessibility/CMakeLists.txt
new file mode 100644
index 0000000000..4ee93f4ca7
--- /dev/null
+++ b/src/platformsupport/linuxaccessibility/CMakeLists.txt
@@ -0,0 +1,47 @@
+# Generated from linuxaccessibility.pro.
+
+qt_find_package(ATSPI2) # special case
+
+#####################################################################
+## LinuxAccessibilitySupport Module:
+#####################################################################
+
+qt_add_module(LinuxAccessibilitySupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ application.cpp application_p.h
+ atspiadaptor.cpp atspiadaptor_p.h
+ bridge.cpp bridge_p.h
+ cache.cpp cache_p.h
+ constant_mappings.cpp constant_mappings_p.h
+ dbusconnection.cpp dbusconnection_p.h
+ struct_marshallers.cpp struct_marshallers_p.h
+ DBUS_ADAPTOR_SOURCES
+ dbusxml/Cache.xml
+ dbusxml/DeviceEventController.xml
+ DBUS_ADAPTOR_FLAGS
+ "-i" "struct_marshallers_p.h"
+ DBUS_INTERFACE_SOURCES
+ dbusxml/Bus.xml
+ dbusxml/Socket.xml
+ DBUS_INTERFACE_FLAGS
+ "-i" "struct_marshallers_p.h"
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::AccessibilitySupportPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ PkgConfig::ATSPI2_nolink
+ Qt::AccessibilitySupport
+ Qt::Core
+ Qt::DBus
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:linuxaccessibility.pro:<TRUE>:
+# MODULE = "linuxaccessibility_support"
diff --git a/src/platformsupport/linuxofono/CMakeLists.txt b/src/platformsupport/linuxofono/CMakeLists.txt
new file mode 100644
index 0000000000..ba8bc97dd6
--- /dev/null
+++ b/src/platformsupport/linuxofono/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from linuxofono.pro.
+
+#####################################################################
+## LinuxOfonoSupport Module:
+#####################################################################
+
+add_qt_module(LinuxOfonoSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qofonoservice_linux.cpp qofonoservice_linux_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::DBus
+)
+
+#### Keys ignored in scope 1:.:.:linuxofono.pro:<TRUE>:
+# MODULE = "linuxofono_support"
diff --git a/src/platformsupport/platformcompositor/CMakeLists.txt b/src/platformsupport/platformcompositor/CMakeLists.txt
new file mode 100644
index 0000000000..b8b59a2723
--- /dev/null
+++ b/src/platformsupport/platformcompositor/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from platformcompositor.pro.
+
+#####################################################################
+## PlatformCompositorSupport Module:
+#####################################################################
+
+qt_add_module(PlatformCompositorSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qopenglcompositor.cpp qopenglcompositor_p.h
+ qopenglcompositorbackingstore.cpp qopenglcompositorbackingstore_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:platformcompositor.pro:<TRUE>:
+# MODULE = "platformcompositor_support"
diff --git a/src/platformsupport/services/CMakeLists.txt b/src/platformsupport/services/CMakeLists.txt
new file mode 100644
index 0000000000..4744455489
--- /dev/null
+++ b/src/platformsupport/services/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from services.pro.
+
+#####################################################################
+## ServiceSupport Module:
+#####################################################################
+
+qt_add_module(ServiceSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ genericunix/qgenericunixservices.cpp genericunix/qgenericunixservices_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:services.pro:<TRUE>:
+# MODULE = "service_support"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(ServiceSupport CONDITION QT_FEATURE_dbus
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/src/platformsupport/themes/CMakeLists.txt b/src/platformsupport/themes/CMakeLists.txt
new file mode 100644
index 0000000000..1c575a8bf1
--- /dev/null
+++ b/src/platformsupport/themes/CMakeLists.txt
@@ -0,0 +1,57 @@
+# Generated from themes.pro.
+
+#####################################################################
+## ThemeSupport Module:
+#####################################################################
+
+qt_add_module(ThemeSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qabstractfileiconengine.cpp qabstractfileiconengine_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:themes.pro:<TRUE>:
+# MODULE = "theme_support"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(ThemeSupport CONDITION QT_FEATURE_xcb OR (UNIX AND NOT APPLE_UIKIT)
+ SOURCES
+ genericunix/qgenericunixthemes.cpp genericunix/qgenericunixthemes_p.h
+)
+
+qt_extend_target(ThemeSupport CONDITION QT_FEATURE_dbus AND (QT_FEATURE_xcb OR UNIX) AND (QT_FEATURE_xcb OR NOT APPLE_UIKIT)
+ SOURCES
+ genericunix/dbusmenu/qdbusmenuadaptor.cpp genericunix/dbusmenu/qdbusmenuadaptor_p.h
+ genericunix/dbusmenu/qdbusmenubar.cpp genericunix/dbusmenu/qdbusmenubar_p.h
+ genericunix/dbusmenu/qdbusmenuconnection.cpp genericunix/dbusmenu/qdbusmenuconnection_p.h
+ genericunix/dbusmenu/qdbusmenuregistrarproxy.cpp genericunix/dbusmenu/qdbusmenuregistrarproxy_p.h
+ genericunix/dbusmenu/qdbusmenutypes.cpp genericunix/dbusmenu/qdbusmenutypes_p.h
+ genericunix/dbusmenu/qdbusplatformmenu.cpp genericunix/dbusmenu/qdbusplatformmenu_p.h
+ INCLUDE_DIRECTORIES
+ genericunix/dbusmenu
+ LIBRARIES
+ Qt::DBus
+)
+
+qt_extend_target(ThemeSupport CONDITION QT_FEATURE_dbus AND QT_FEATURE_systemtrayicon AND (QT_FEATURE_xcb OR UNIX) AND (QT_FEATURE_xcb OR NOT APPLE_UIKIT)
+ SOURCES
+ genericunix/dbustray/qdbustrayicon.cpp genericunix/dbustray/qdbustrayicon_p.h
+ genericunix/dbustray/qdbustraytypes.cpp genericunix/dbustray/qdbustraytypes_p.h
+ genericunix/dbustray/qstatusnotifieritemadaptor.cpp genericunix/dbustray/qstatusnotifieritemadaptor_p.h
+ genericunix/dbustray/qxdgnotificationproxy.cpp genericunix/dbustray/qxdgnotificationproxy_p.h
+ INCLUDE_DIRECTORIES
+ genericunix/dbustray
+ LIBRARIES
+ Qt::DBus
+)
diff --git a/src/platformsupport/vkconvenience/.prev_CMakeLists.txt b/src/platformsupport/vkconvenience/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..070a0ee35f
--- /dev/null
+++ b/src/platformsupport/vkconvenience/.prev_CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from vkconvenience.pro.
+
+#####################################################################
+## VulkanSupport Module:
+#####################################################################
+
+qt_add_module(VulkanSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qbasicvulkanplatforminstance.cpp qbasicvulkanplatforminstance_p.h
+ qvkconvenience.cpp qvkconvenience_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:vkconvenience.pro:<TRUE>:
+# MODULE = "vulkan_support"
diff --git a/src/platformsupport/vkconvenience/CMakeLists.txt b/src/platformsupport/vkconvenience/CMakeLists.txt
new file mode 100644
index 0000000000..99435d1f55
--- /dev/null
+++ b/src/platformsupport/vkconvenience/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from vkconvenience.pro.
+
+qt_find_package(Vulkan) # special case
+
+#####################################################################
+## VulkanSupport Module:
+#####################################################################
+
+qt_add_module(VulkanSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qbasicvulkanplatforminstance.cpp qbasicvulkanplatforminstance_p.h
+ qvkconvenience.cpp qvkconvenience_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "../../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:vkconvenience.pro:<TRUE>:
+# MODULE = "vulkan_support"
diff --git a/src/platformsupport/windowsuiautomation/CMakeLists.txt b/src/platformsupport/windowsuiautomation/CMakeLists.txt
new file mode 100644
index 0000000000..f4c29b8c3e
--- /dev/null
+++ b/src/platformsupport/windowsuiautomation/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from windowsuiautomation.pro.
+
+#####################################################################
+## WindowsUIAutomationSupport Module:
+#####################################################################
+
+qt_add_module(WindowsUIAutomationSupport
+ STATIC
+ INTERNAL_MODULE
+ SOURCES
+ qwindowsuiawrapper.cpp qwindowsuiawrapper_p.h
+ uiaattributeids_p.h
+ uiaclientinterfaces_p.h
+ uiacontroltypeids_p.h
+ uiaerrorids_p.h
+ uiaeventids_p.h
+ uiageneralids_p.h
+ uiapatternids_p.h
+ uiapropertyids_p.h
+ uiaserverinterfaces_p.h
+ uiatypes_p.h
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:windowsuiautomation.pro:<TRUE>:
+# MODULE = "windowsuiautomation_support"
diff --git a/src/plugins/CMakeLists.txt b/src/plugins/CMakeLists.txt
new file mode 100644
index 0000000000..6718d64ca0
--- /dev/null
+++ b/src/plugins/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from plugins.pro.
+
+if(TARGET Qt::Sql)
+ add_subdirectory(sqldrivers)
+endif()
+if(QT_FEATURE_bearermanagement AND TARGET Qt::Network)
+ add_subdirectory(bearer)
+endif()
+if(TARGET Qt::Gui)
+ add_subdirectory(platforms)
+ add_subdirectory(platforminputcontexts)
+ add_subdirectory(platformthemes)
+endif()
+if(QT_FEATURE_imageformatplugin AND TARGET Qt::Gui)
+ add_subdirectory(imageformats)
+endif()
+if(QT_FEATURE_library AND TARGET Qt::Gui AND NOT ANDROID)
+ add_subdirectory(generic)
+endif()
+if(TARGET Qt::Widgets)
+ add_subdirectory(styles)
+endif()
+if(TARGET Qt::PrintSupport AND NOT WINRT)
+ add_subdirectory(printsupport)
+endif()
diff --git a/src/plugins/bearer/.prev_CMakeLists.txt b/src/plugins/bearer/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..a7a36f60c6
--- /dev/null
+++ b/src/plugins/bearer/.prev_CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from bearer.pro.
+
+if(SUBDIRS_ISEMPTY OR (TARGET Qt::DBus AND linux_x_ AND NOT ANDROID))
+ add_subdirectory(generic)
+endif()
+if(TARGET Qt::DBus AND linux_x_ AND NOT ANDROID)
+ add_subdirectory(connman)
+ add_subdirectory(networkmanager)
+endif()
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ add_subdirectory(android)
+endif()
diff --git a/src/plugins/bearer/CMakeLists.txt b/src/plugins/bearer/CMakeLists.txt
new file mode 100644
index 0000000000..528061d264
--- /dev/null
+++ b/src/plugins/bearer/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from bearer.pro.
+
+# special case begin
+# The whole block is manual.
+if(NOT ANDROID AND LINUX AND TARGET Qt::DBus)
+ add_subdirectory(generic)
+ add_subdirectory(connman)
+ add_subdirectory(networkmanager)
+elseif(ANDROID AND NOT ANDROID_EMBEDDED)
+ add_subdirectory(android)
+else()
+ add_subdirectory(generic)
+endif()
+# special case end
diff --git a/src/plugins/bearer/android/CMakeLists.txt b/src/plugins/bearer/android/CMakeLists.txt
new file mode 100644
index 0000000000..193cbf1fe3
--- /dev/null
+++ b/src/plugins/bearer/android/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from android.pro.
+
+add_subdirectory(src)
+add_subdirectory(jar)
diff --git a/src/plugins/bearer/android/jar/.prev_CMakeLists.txt b/src/plugins/bearer/android/jar/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..f5f25c4f8b
--- /dev/null
+++ b/src/plugins/bearer/android/jar/.prev_CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from jar.pro.
+
+set(java_sources
+ src/org/qtproject/qt5/android/bearer/QtNetworkReceiver.java
+)
+
+add_jar(QtAndroidBearer
+ INCLUDE_JARS ${QT_ANDROID_JAR}
+ SOURCES ${java_sources}
+)
+
+install_jar(QtAndroidBearer
+ DESTINATION jar
+ COMPONENT Devel
+)
+
diff --git a/src/plugins/bearer/android/jar/CMakeLists.txt b/src/plugins/bearer/android/jar/CMakeLists.txt
new file mode 100644
index 0000000000..16641d42b7
--- /dev/null
+++ b/src/plugins/bearer/android/jar/CMakeLists.txt
@@ -0,0 +1,22 @@
+#####################################################################
+## QtAndroidBearer Binary:
+#####################################################################
+
+set(java_sources
+ src/org/qtproject/qt5/android/bearer/QtNetworkReceiver.java
+)
+
+add_jar(QtAndroidBearer
+ INCLUDE_JARS ${QT_ANDROID_JAR}
+ SOURCES ${java_sources}
+ )
+
+install_jar(QtAndroidBearer
+ DESTINATION jar
+ COMPONENT Devel)
+
+#### Keys ignored in scope 1:.:.:jar.pro:<TRUE>:
+# JAVACLASSPATH = "$$PWD/src"
+# JAVASOURCES = "$$PWD/src/org/qtproject/qt5/android/bearer/QtNetworkReceiver.java"
+# _LOADED = "qt_build_paths"
+
diff --git a/src/plugins/bearer/android/src/CMakeLists.txt b/src/plugins/bearer/android/src/CMakeLists.txt
new file mode 100644
index 0000000000..8aee553d86
--- /dev/null
+++ b/src/plugins/bearer/android/src/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from src.pro.
+
+#####################################################################
+## qandroidbearer Plugin:
+#####################################################################
+
+qt_add_plugin(qandroidbearer
+ TYPE bearer
+ CLASS_NAME QAndroidBearerEnginePlugin
+ SOURCES
+ main.cpp
+ qandroidbearerengine.cpp qandroidbearerengine.h
+ wrappers/androidconnectivitymanager.cpp wrappers/androidconnectivitymanager.h
+ INCLUDE_DIRECTORIES
+ wrappers
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Network
+)
diff --git a/src/plugins/bearer/connman/.prev_CMakeLists.txt b/src/plugins/bearer/connman/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..1dc42fcce3
--- /dev/null
+++ b/src/plugins/bearer/connman/.prev_CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from connman.pro.
+
+#####################################################################
+## qconnmanbearer Plugin:
+#####################################################################
+
+qt_add_plugin(qconnmanbearer
+ TYPE bearer
+ CLASS_NAME QConnmanEnginePlugin
+ SOURCES
+ main.cpp
+ qconnmanengine.cpp qconnmanengine.h
+ qconnmanservice_linux.cpp qconnmanservice_linux_p.h
+ LIBRARIES
+ Qt::LinuxOfonoSupportPrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::DBus
+ Qt::LinuxOfonoSupport
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:connman.pro:<TRUE>:
+# OTHER_FILES = "connman.json"
diff --git a/src/plugins/bearer/connman/CMakeLists.txt b/src/plugins/bearer/connman/CMakeLists.txt
new file mode 100644
index 0000000000..1dc42fcce3
--- /dev/null
+++ b/src/plugins/bearer/connman/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from connman.pro.
+
+#####################################################################
+## qconnmanbearer Plugin:
+#####################################################################
+
+qt_add_plugin(qconnmanbearer
+ TYPE bearer
+ CLASS_NAME QConnmanEnginePlugin
+ SOURCES
+ main.cpp
+ qconnmanengine.cpp qconnmanengine.h
+ qconnmanservice_linux.cpp qconnmanservice_linux_p.h
+ LIBRARIES
+ Qt::LinuxOfonoSupportPrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::DBus
+ Qt::LinuxOfonoSupport
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:connman.pro:<TRUE>:
+# OTHER_FILES = "connman.json"
diff --git a/src/plugins/bearer/corewlan/CMakeLists.txt b/src/plugins/bearer/corewlan/CMakeLists.txt
new file mode 100644
index 0000000000..914f5ceae1
--- /dev/null
+++ b/src/plugins/bearer/corewlan/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from corewlan.pro.
+
+#####################################################################
+## qcorewlanbearer Plugin:
+#####################################################################
+
+qt_add_plugin(qcorewlanbearer
+ TYPE bearer
+ CLASS_NAME QCoreWlanEnginePlugin
+ SOURCES
+ main.cpp
+ qcorewlanengine.h qcorewlanengine.mm
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ ${FWFoundation}
+ ${FWSystemConfiguration}
+ Qt::Core
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:corewlan.pro:<TRUE>:
+# OTHER_FILES = "corewlan.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qcorewlanbearer CONDITION QT_FEATURE_corewlan
+ PUBLIC_LIBRARIES
+ ${FWCoreWLAN}
+ ${FWSecurity}
+)
diff --git a/src/plugins/bearer/generic/CMakeLists.txt b/src/plugins/bearer/generic/CMakeLists.txt
new file mode 100644
index 0000000000..c41688e82a
--- /dev/null
+++ b/src/plugins/bearer/generic/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from generic.pro.
+
+#####################################################################
+## qgenericbearer Plugin:
+#####################################################################
+
+qt_add_plugin(qgenericbearer
+ TYPE bearer
+ CLASS_NAME QGenericEnginePlugin
+ SOURCES
+ ../platformdefs_win.h
+ main.cpp
+ qgenericengine.cpp qgenericengine.h
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:generic.pro:<TRUE>:
+# OTHER_FILES = "generic.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qgenericbearer CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ iphlpapi
+)
diff --git a/src/plugins/bearer/networkmanager/.prev_CMakeLists.txt b/src/plugins/bearer/networkmanager/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..2d86926aff
--- /dev/null
+++ b/src/plugins/bearer/networkmanager/.prev_CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from networkmanager.pro.
+
+#####################################################################
+## qnmbearer Plugin:
+#####################################################################
+
+qt_add_plugin(qnmbearer
+ TYPE bearer
+ CLASS_NAME QNetworkManagerEnginePlugin
+ SOURCES
+ main.cpp
+ qnetworkmanagerengine.cpp qnetworkmanagerengine.h
+ qnetworkmanagerservice.cpp qnetworkmanagerservice.h
+ LIBRARIES
+ Qt::LinuxOfonoSupportPrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::DBus
+ Qt::LinuxOfonoSupport
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:networkmanager.pro:<TRUE>:
+# OTHER_FILES = "networkmanager.json"
diff --git a/src/plugins/bearer/networkmanager/CMakeLists.txt b/src/plugins/bearer/networkmanager/CMakeLists.txt
new file mode 100644
index 0000000000..2d86926aff
--- /dev/null
+++ b/src/plugins/bearer/networkmanager/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from networkmanager.pro.
+
+#####################################################################
+## qnmbearer Plugin:
+#####################################################################
+
+qt_add_plugin(qnmbearer
+ TYPE bearer
+ CLASS_NAME QNetworkManagerEnginePlugin
+ SOURCES
+ main.cpp
+ qnetworkmanagerengine.cpp qnetworkmanagerengine.h
+ qnetworkmanagerservice.cpp qnetworkmanagerservice.h
+ LIBRARIES
+ Qt::LinuxOfonoSupportPrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::DBus
+ Qt::LinuxOfonoSupport
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:networkmanager.pro:<TRUE>:
+# OTHER_FILES = "networkmanager.json"
diff --git a/src/plugins/generic/.prev_CMakeLists.txt b/src/plugins/generic/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..b3851ffbd1
--- /dev/null
+++ b/src/plugins/generic/.prev_CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from generic.pro.
+
+if(QT_FEATURE_evdev)
+ add_subdirectory(evdevmouse)
+ add_subdirectory(evdevtouch)
+ add_subdirectory(evdevkeyboard)
+endif()
+if(QT_FEATURE_evdev AND QT_FEATURE_tabletevent)
+ add_subdirectory(evdevtablet)
+endif()
+if(QT_FEATURE_tslib)
+ add_subdirectory(tslib)
+endif()
+if(QT_FEATURE_tuiotouch)
+ add_subdirectory(tuiotouch)
+endif()
+if(QT_FEATURE_libinput)
+ add_subdirectory(libinput)
+endif()
+if(FREEBSD)
+ add_subdirectory(bsdkeyboard)
+ add_subdirectory(bsdmouse)
+endif()
diff --git a/src/plugins/generic/CMakeLists.txt b/src/plugins/generic/CMakeLists.txt
new file mode 100644
index 0000000000..f5890d0961
--- /dev/null
+++ b/src/plugins/generic/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from generic.pro.
+
+if(QT_FEATURE_evdev)
+ add_subdirectory(evdevmouse)
+ add_subdirectory(evdevtouch)
+ add_subdirectory(evdevkeyboard)
+endif()
+if(QT_FEATURE_evdev AND QT_FEATURE_tabletevent)
+ add_subdirectory(evdevtablet)
+endif()
+if(QT_FEATURE_tslib)
+ add_subdirectory(tslib)
+endif()
+if(QT_FEATURE_tuiotouch)
+ add_subdirectory(tuiotouch)
+endif()
+if(QT_FEATURE_libinput)
+ add_subdirectory(libinput)
+endif()
+if(FREEBSD)
+ # add_subdirectory(bsdkeyboard) # special case TODO
+ # add_subdirectory(bsdmouse) # special case TODO
+endif()
diff --git a/src/plugins/generic/evdevkeyboard/CMakeLists.txt b/src/plugins/generic/evdevkeyboard/CMakeLists.txt
new file mode 100644
index 0000000000..e8adbd6d51
--- /dev/null
+++ b/src/plugins/generic/evdevkeyboard/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from evdevkeyboard.pro.
+
+#####################################################################
+## qevdevkeyboardplugin Plugin:
+#####################################################################
+
+qt_add_plugin(qevdevkeyboardplugin
+ TYPE generic
+ CLASS_NAME QEvdevKeyboardPlugin
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::InputSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::InputSupport
+)
+
+#### Keys ignored in scope 1:.:.:evdevkeyboard.pro:<TRUE>:
+# OTHER_FILES = "evdevkeyboard.json"
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/generic/evdevmouse/CMakeLists.txt b/src/plugins/generic/evdevmouse/CMakeLists.txt
new file mode 100644
index 0000000000..fc6b3d30c2
--- /dev/null
+++ b/src/plugins/generic/evdevmouse/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from evdevmouse.pro.
+
+#####################################################################
+## qevdevmouseplugin Plugin:
+#####################################################################
+
+qt_add_plugin(qevdevmouseplugin
+ TYPE generic
+ CLASS_NAME QEvdevMousePlugin
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::InputSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::InputSupport
+)
+
+#### Keys ignored in scope 1:.:.:evdevmouse.pro:<TRUE>:
+# OTHER_FILES = "evdevmouse.json"
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/generic/evdevtablet/CMakeLists.txt b/src/plugins/generic/evdevtablet/CMakeLists.txt
new file mode 100644
index 0000000000..1479a2f66b
--- /dev/null
+++ b/src/plugins/generic/evdevtablet/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from evdevtablet.pro.
+
+#####################################################################
+## qevdevtabletplugin Plugin:
+#####################################################################
+
+qt_add_plugin(qevdevtabletplugin
+ TYPE generic
+ CLASS_NAME QEvdevTabletPlugin
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::InputSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::InputSupport
+)
+
+#### Keys ignored in scope 1:.:.:evdevtablet.pro:<TRUE>:
+# OTHER_FILES = "evdevtablet.json"
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/generic/evdevtouch/CMakeLists.txt b/src/plugins/generic/evdevtouch/CMakeLists.txt
new file mode 100644
index 0000000000..79e11d7969
--- /dev/null
+++ b/src/plugins/generic/evdevtouch/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from evdevtouch.pro.
+
+#####################################################################
+## qevdevtouchplugin Plugin:
+#####################################################################
+
+qt_add_plugin(qevdevtouchplugin
+ TYPE generic
+ CLASS_NAME QEvdevTouchScreenPlugin
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::InputSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::InputSupport
+)
+
+#### Keys ignored in scope 1:.:.:evdevtouch.pro:<TRUE>:
+# OTHER_FILES = "evdevtouch.json"
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/generic/libinput/CMakeLists.txt b/src/plugins/generic/libinput/CMakeLists.txt
new file mode 100644
index 0000000000..d0a60938cd
--- /dev/null
+++ b/src/plugins/generic/libinput/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from libinput.pro.
+
+#####################################################################
+## qlibinputplugin Plugin:
+#####################################################################
+
+qt_add_plugin(qlibinputplugin
+ TYPE generic
+ CLASS_NAME QLibInputPlugin
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::InputSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::InputSupport
+)
+
+#### Keys ignored in scope 1:.:.:libinput.pro:<TRUE>:
+# OTHER_FILES = "libinput.json"
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/generic/tslib/.prev_CMakeLists.txt b/src/plugins/generic/tslib/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..fe71451ae4
--- /dev/null
+++ b/src/plugins/generic/tslib/.prev_CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from tslib.pro.
+
+#####################################################################
+## qtslibplugin Plugin:
+#####################################################################
+
+qt_add_plugin(qtslibplugin
+ TYPE generic
+ CLASS_NAME QTsLibPlugin
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::InputSupportPrivate
+ PUBLIC_LIBRARIES
+ PkgConfig::Tslib
+ Qt::Core
+ Qt::Gui
+ Qt::InputSupport
+)
+
+#### Keys ignored in scope 1:.:.:tslib.pro:<TRUE>:
+# OTHER_FILES = "tslib.json"
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/generic/tslib/CMakeLists.txt b/src/plugins/generic/tslib/CMakeLists.txt
new file mode 100644
index 0000000000..e94f32cc04
--- /dev/null
+++ b/src/plugins/generic/tslib/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from tslib.pro.
+
+qt_find_package(Tslib) # special case
+
+#####################################################################
+## qtslibplugin Plugin:
+#####################################################################
+
+qt_add_plugin(qtslibplugin
+ TYPE generic
+ CLASS_NAME QTsLibPlugin
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::InputSupportPrivate
+ PUBLIC_LIBRARIES
+ PkgConfig::Tslib
+ Qt::Core
+ Qt::Gui
+ Qt::InputSupport
+)
+
+#### Keys ignored in scope 1:.:.:tslib.pro:<TRUE>:
+# OTHER_FILES = "tslib.json"
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/generic/tuiotouch/CMakeLists.txt b/src/plugins/generic/tuiotouch/CMakeLists.txt
new file mode 100644
index 0000000000..0c577487a0
--- /dev/null
+++ b/src/plugins/generic/tuiotouch/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from tuiotouch.pro.
+
+#####################################################################
+## qtuiotouchplugin Plugin:
+#####################################################################
+
+qt_add_plugin(qtuiotouchplugin
+ TYPE generic
+ CLASS_NAME QTuioTouchPlugin
+ SOURCES
+ main.cpp
+ qoscbundle.cpp qoscbundle_p.h
+ qoscmessage.cpp qoscmessage_p.h
+ qtuiocursor_p.h
+ qtuiohandler.cpp qtuiohandler_p.h
+ qtuiotoken_p.h
+ DEFINES
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:tuiotouch.pro:<TRUE>:
+# OTHER_FILES = "tuiotouch.json"
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/imageformats/CMakeLists.txt b/src/plugins/imageformats/CMakeLists.txt
new file mode 100644
index 0000000000..00fefbdc0d
--- /dev/null
+++ b/src/plugins/imageformats/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from imageformats.pro.
+
+if(QT_FEATURE_ico)
+ add_subdirectory(ico)
+endif()
+if(QT_FEATURE_jpeg)
+ add_subdirectory(jpeg)
+endif()
+if(QT_FEATURE_gif)
+ add_subdirectory(gif)
+endif()
diff --git a/src/plugins/imageformats/gif/.prev_CMakeLists.txt b/src/plugins/imageformats/gif/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..0dcdf2954d
--- /dev/null
+++ b/src/plugins/imageformats/gif/.prev_CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from gif.pro.
+
+#####################################################################
+## qgif Plugin:
+#####################################################################
+
+qt_add_plugin(qgif
+ TYPE imageformats
+ CLASS_NAME QGifPlugin
+ SOURCES
+ main.cpp main.h
+ qgifhandler.cpp qgifhandler_p.h
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:gif.pro:<TRUE>:
+# OTHER_FILES = "gif.json"
diff --git a/src/plugins/imageformats/gif/CMakeLists.txt b/src/plugins/imageformats/gif/CMakeLists.txt
new file mode 100644
index 0000000000..0255212201
--- /dev/null
+++ b/src/plugins/imageformats/gif/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from gif.pro.
+
+#####################################################################
+## qgif Plugin:
+#####################################################################
+
+qt_add_plugin(qgif
+ TYPE imageformats
+ CLASS_NAME QGifPlugin
+ SOURCES
+ main.cpp main.h
+ qgifhandler.cpp qgifhandler_p.h
+ LIBRARIES # special case
+ Qt::GuiPrivate # special case
+ PUBLIC_LIBRARIES # special case
+ Qt::Gui # special case
+)
+
+#### Keys ignored in scope 1:.:.:gif.pro:<TRUE>:
+# OTHER_FILES = "gif.json"
diff --git a/src/plugins/imageformats/ico/.prev_CMakeLists.txt b/src/plugins/imageformats/ico/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..d054bd9936
--- /dev/null
+++ b/src/plugins/imageformats/ico/.prev_CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from ico.pro.
+
+#####################################################################
+## qico Plugin:
+#####################################################################
+
+add_qt_plugin(qico
+ TYPE imageformats
+ CLASS_NAME QICOPlugin
+ SOURCES
+ main.cpp main.h
+ qicohandler.cpp qicohandler.h
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:ico.pro:<TRUE>:
+# OTHER_FILES = "ico.json"
+# _LOADED = "qt_plugin"
diff --git a/src/plugins/imageformats/ico/CMakeLists.txt b/src/plugins/imageformats/ico/CMakeLists.txt
new file mode 100644
index 0000000000..a07eb59655
--- /dev/null
+++ b/src/plugins/imageformats/ico/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from ico.pro.
+
+#####################################################################
+## qico Plugin:
+#####################################################################
+
+qt_add_plugin(qico
+ TYPE imageformats
+ CLASS_NAME QICOPlugin
+ SOURCES
+ main.cpp main.h
+ qicohandler.cpp qicohandler.h
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:ico.pro:<TRUE>:
+# OTHER_FILES = "ico.json"
diff --git a/src/plugins/imageformats/jpeg/.prev_CMakeLists.txt b/src/plugins/imageformats/jpeg/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..53239e923f
--- /dev/null
+++ b/src/plugins/imageformats/jpeg/.prev_CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from jpeg.pro.
+
+#####################################################################
+## qjpeg Plugin:
+#####################################################################
+
+qt_add_plugin(qjpeg
+ TYPE imageformats
+ CLASS_NAME QJpegPlugin
+ SOURCES
+ main.cpp main.h
+ qjpeghandler.cpp qjpeghandler_p.h
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ JPEG::JPEG
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:jpeg.pro:<TRUE>:
+# OTHER_FILES = "jpeg.json"
diff --git a/src/plugins/imageformats/jpeg/CMakeLists.txt b/src/plugins/imageformats/jpeg/CMakeLists.txt
new file mode 100644
index 0000000000..b6a7c73ea6
--- /dev/null
+++ b/src/plugins/imageformats/jpeg/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from jpeg.pro.
+
+qt_find_package(JPEG) # special case
+
+#####################################################################
+## qjpeg Plugin:
+#####################################################################
+
+qt_add_plugin(qjpeg
+ TYPE imageformats
+ CLASS_NAME QJpegPlugin
+ SOURCES
+ main.cpp main.h
+ qjpeghandler.cpp qjpeghandler_p.h
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ JPEG::JPEG
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:jpeg.pro:<TRUE>:
+# OTHER_FILES = "jpeg.json"
diff --git a/src/plugins/platforminputcontexts/CMakeLists.txt b/src/plugins/platforminputcontexts/CMakeLists.txt
new file mode 100644
index 0000000000..155f5161f2
--- /dev/null
+++ b/src/plugins/platforminputcontexts/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from platforminputcontexts.pro.
+
+if(QT_FEATURE_xkbcommon)
+ add_subdirectory(compose)
+endif()
+if(QT_FEATURE_xkbcommon AND TARGET Qt::DBus AND UNIX AND NOT APPLE_OSX)
+ add_subdirectory(ibus)
+endif()
diff --git a/src/plugins/platforminputcontexts/compose/.prev_CMakeLists.txt b/src/plugins/platforminputcontexts/compose/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..e5cc7cd766
--- /dev/null
+++ b/src/plugins/platforminputcontexts/compose/.prev_CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from compose.pro.
+
+#####################################################################
+## composeplatforminputcontextplugin Plugin:
+#####################################################################
+
+qt_add_plugin(composeplatforminputcontextplugin
+ TYPE platforminputcontexts
+ CLASS_NAME QComposePlatformInputContextPlugin
+ SOURCES
+ qcomposeplatforminputcontext.cpp qcomposeplatforminputcontext.h
+ qcomposeplatforminputcontextmain.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ XKB::XKB
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:compose.pro:<TRUE>:
+# OTHER_FILES = "$$PWD/compose.json"
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforminputcontexts/compose/CMakeLists.txt b/src/plugins/platforminputcontexts/compose/CMakeLists.txt
new file mode 100644
index 0000000000..d28722dc3b
--- /dev/null
+++ b/src/plugins/platforminputcontexts/compose/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from compose.pro.
+
+#####################################################################
+## composeplatforminputcontextplugin Plugin:
+#####################################################################
+
+qt_find_package(XKB) # special case
+pkg_get_variable(PKG_X11_PREFIX x11 prefix) # special case
+
+qt_add_plugin(composeplatforminputcontextplugin
+ TYPE platforminputcontexts
+ CLASS_NAME QComposePlatformInputContextPlugin
+ SOURCES
+ qcomposeplatforminputcontext.cpp qcomposeplatforminputcontext.h
+ qcomposeplatforminputcontextmain.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ XKB::XKB
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:compose.pro:<TRUE>:
+# OTHER_FILES = "$$PWD/compose.json"
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforminputcontexts/ibus/CMakeLists.txt b/src/plugins/platforminputcontexts/ibus/CMakeLists.txt
new file mode 100644
index 0000000000..49f1c79820
--- /dev/null
+++ b/src/plugins/platforminputcontexts/ibus/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from ibus.pro.
+
+#####################################################################
+## ibusplatforminputcontextplugin Plugin:
+#####################################################################
+
+qt_add_plugin(ibusplatforminputcontextplugin
+ TYPE platforminputcontexts
+ CLASS_NAME QIbusPlatformInputContextPlugin
+ SOURCES
+ main.cpp
+ qibusinputcontextproxy.cpp qibusinputcontextproxy.h
+ qibusplatforminputcontext.cpp qibusplatforminputcontext.h
+ qibusproxy.cpp qibusproxy.h
+ qibusproxyportal.cpp qibusproxyportal.h
+ qibustypes.cpp qibustypes.h
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::XkbCommonSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::DBus
+ Qt::Gui
+ Qt::XkbCommonSupport
+)
+
+#### Keys ignored in scope 1:.:.:ibus.pro:<TRUE>:
+# OTHER_FILES = "$$PWD/ibus.json"
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/.prev_CMakeLists.txt b/src/plugins/platforms/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..5797b07233
--- /dev/null
+++ b/src/plugins/platforms/.prev_CMakeLists.txt
@@ -0,0 +1,57 @@
+# Generated from platforms.pro.
+
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ add_subdirectory(android)
+endif()
+if(NOT ANDROID)
+ add_subdirectory(minimal)
+endif()
+if(QT_FEATURE_freetype AND NOT ANDROID)
+ add_subdirectory(offscreen)
+endif()
+if(QT_FEATURE_xcb)
+ add_subdirectory(xcb)
+endif()
+if(APPLE_UIKIT AND NOT APPLE_WATCHOS)
+ add_subdirectory(ios)
+endif()
+if(APPLE_OSX)
+ add_subdirectory(cocoa)
+endif()
+if(QT_FEATURE_direct3d9 AND WIN32 AND NOT WINRT)
+ add_subdirectory(windows)
+endif()
+if(QT_FEATURE_direct3d11 AND WINRT)
+ add_subdirectory(winrt)
+endif()
+if(QT_FEATURE_direct2d1_1 AND QT_FEATURE_direct3d11_1 AND QT_FEATURE_directwrite1)
+ add_subdirectory(direct2d)
+endif()
+if(QNX)
+ add_subdirectory(qnx)
+endif()
+if(QT_FEATURE_eglfs)
+ add_subdirectory(eglfs)
+ add_subdirectory(minimalegl)
+endif()
+if(QT_FEATURE_directfb)
+ add_subdirectory(directfb)
+endif()
+if(QT_FEATURE_linuxfb)
+ add_subdirectory(linuxfb)
+endif()
+if(QT_FEATURE_vnc AND TARGET Qt::Network)
+ add_subdirectory(vnc)
+endif()
+if(FREEBSD)
+ add_subdirectory(bsdfb)
+endif()
+if(HAIKU)
+ add_subdirectory(haiku)
+endif()
+if(WASM)
+ add_subdirectory(wasm)
+endif()
+if(QT_FEATURE_integrityfb)
+ add_subdirectory(integrity)
+endif()
diff --git a/src/plugins/platforms/CMakeLists.txt b/src/plugins/platforms/CMakeLists.txt
new file mode 100644
index 0000000000..57c3952e4c
--- /dev/null
+++ b/src/plugins/platforms/CMakeLists.txt
@@ -0,0 +1,57 @@
+# Generated from platforms.pro.
+
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ add_subdirectory(android)
+endif()
+if(NOT ANDROID)
+ add_subdirectory(minimal)
+endif()
+if(QT_FEATURE_freetype AND NOT ANDROID)
+ add_subdirectory(offscreen)
+endif()
+if(QT_FEATURE_xcb)
+ add_subdirectory(xcb)
+endif()
+if(APPLE_UIKIT AND NOT APPLE_WATCHOS)
+ add_subdirectory(ios)
+endif()
+if(APPLE_OSX)
+ add_subdirectory(cocoa)
+endif()
+if(WIN32 AND NOT WINRT) # special case TODO fix direct3d9 test
+ add_subdirectory(windows)
+endif()
+if(QT_FEATURE_direct3d11 AND WINRT)
+ # add_subdirectory(winrt) # special case TODO
+endif()
+if(QT_FEATURE_direct2d1_1 AND QT_FEATURE_direct3d11_1 AND QT_FEATURE_directwrite1)
+ # add_subdirectory(direct2d) # special case TODO
+endif()
+if(QNX)
+ # add_subdirectory(qnx) # special case TODO
+endif()
+if(QT_FEATURE_eglfs)
+ add_subdirectory(eglfs)
+ add_subdirectory(minimalegl)
+endif()
+if(QT_FEATURE_directfb)
+ add_subdirectory(directfb)
+endif()
+if(QT_FEATURE_linuxfb)
+ add_subdirectory(linuxfb)
+endif()
+if(QT_FEATURE_vnc AND TARGET Qt::Network)
+ add_subdirectory(vnc)
+endif()
+if(FREEBSD)
+ # add_subdirectory(bsdfb) # special case TODO
+endif()
+if(HAIKU)
+ # add_subdirectory(haiku) # special case TODO
+endif()
+if(WASM)
+ # add_subdirectory(wasm) # special case TODO
+endif()
+if(QT_FEATURE_integrityfb)
+ # add_subdirectory(integrity) # special case TODO
+endif()
diff --git a/src/plugins/platforms/android/.prev_CMakeLists.txt b/src/plugins/platforms/android/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..62d66746d8
--- /dev/null
+++ b/src/plugins/platforms/android/.prev_CMakeLists.txt
@@ -0,0 +1,87 @@
+# Generated from android.pro.
+
+#####################################################################
+## qtforandroid Plugin:
+#####################################################################
+
+qt_add_plugin(qtforandroid
+ TYPE platforms
+ CLASS_NAME QAndroidIntegrationPlugin
+ SOURCES
+ androidcontentfileengine.cpp androidcontentfileengine.h
+ androiddeadlockprotector.cpp androiddeadlockprotector.h
+ androidjniaccessibility.cpp androidjniaccessibility.h
+ androidjniclipboard.cpp androidjniclipboard.h
+ androidjniinput.cpp androidjniinput.h
+ androidjnimain.cpp androidjnimain.h
+ androidjnimenu.cpp androidjnimenu.h
+ androidsurfaceclient.h
+ main.cpp
+ qandroidassetsfileenginehandler.cpp qandroidassetsfileenginehandler.h
+ qandroideventdispatcher.cpp qandroideventdispatcher.h
+ qandroidinputcontext.cpp qandroidinputcontext.h
+ qandroidplatformaccessibility.cpp qandroidplatformaccessibility.h
+ qandroidplatformbackingstore.cpp qandroidplatformbackingstore.h
+ qandroidplatformclipboard.cpp qandroidplatformclipboard.h
+ qandroidplatformdialoghelpers.cpp qandroidplatformdialoghelpers.h
+ qandroidplatformfiledialoghelper.cpp qandroidplatformfiledialoghelper.h
+ qandroidplatformfontdatabase.cpp qandroidplatformfontdatabase.h
+ qandroidplatformforeignwindow.cpp qandroidplatformforeignwindow.h
+ qandroidplatformintegration.cpp qandroidplatformintegration.h
+ qandroidplatformmenu.cpp qandroidplatformmenu.h
+ qandroidplatformmenubar.cpp qandroidplatformmenubar.h
+ qandroidplatformmenuitem.cpp qandroidplatformmenuitem.h
+ qandroidplatformoffscreensurface.cpp qandroidplatformoffscreensurface.h
+ qandroidplatformopenglcontext.cpp qandroidplatformopenglcontext.h
+ qandroidplatformopenglwindow.cpp qandroidplatformopenglwindow.h
+ qandroidplatformscreen.cpp qandroidplatformscreen.h
+ qandroidplatformservices.cpp qandroidplatformservices.h
+ qandroidplatformtheme.cpp qandroidplatformtheme.h
+ qandroidplatformwindow.cpp qandroidplatformwindow.h
+ qandroidsystemlocale.cpp qandroidsystemlocale.h
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ ${QT_SOURCE_TREE}/src/3rdparty/android
+ LIBRARIES
+ Qt::AccessibilitySupportPrivate
+ Qt::CorePrivate
+ Qt::EglSupportPrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::AccessibilitySupport
+ Qt::Core
+ Qt::EglSupport
+ Qt::EventDispatcherSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+ android
+ jnigraphics
+)
+
+#### Keys ignored in scope 1:.:.:android.pro:<TRUE>:
+# OTHER_FILES = "$$PWD/android.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qtforandroid CONDITION QT_FEATURE_vulkan
+ SOURCES
+ qandroidplatformvulkaninstance.cpp qandroidplatformvulkaninstance.h
+ qandroidplatformvulkanwindow.cpp qandroidplatformvulkanwindow.h
+ LIBRARIES
+ Qt::VulkanSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::VulkanSupport
+)
+
+qt_extend_target(qtforandroid CONDITION QT_FEATURE_android_style_assets
+ SOURCES
+ extract.cpp
+)
+
+qt_extend_target(qtforandroid CONDITION NOT QT_FEATURE_android_style_assets
+ SOURCES
+ extract-dummy.cpp
+)
diff --git a/src/plugins/platforms/android/CMakeLists.txt b/src/plugins/platforms/android/CMakeLists.txt
new file mode 100644
index 0000000000..406cb54d72
--- /dev/null
+++ b/src/plugins/platforms/android/CMakeLists.txt
@@ -0,0 +1,96 @@
+# Generated from android.pro.
+
+#####################################################################
+## qtforandroid Plugin:
+#####################################################################
+
+qt_add_plugin(qtforandroid
+ TYPE platforms
+ CLASS_NAME QAndroidIntegrationPlugin
+ DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES android # special case
+ SOURCES
+ androidcontentfileengine.cpp androidcontentfileengine.h
+ androiddeadlockprotector.cpp androiddeadlockprotector.h
+ androidjniaccessibility.cpp androidjniaccessibility.h
+ androidjniclipboard.cpp androidjniclipboard.h
+ androidjniinput.cpp androidjniinput.h
+ androidjnimain.cpp androidjnimain.h
+ androidjnimenu.cpp androidjnimenu.h
+ androidsurfaceclient.h
+ main.cpp
+ qandroidassetsfileenginehandler.cpp qandroidassetsfileenginehandler.h
+ qandroideventdispatcher.cpp qandroideventdispatcher.h
+ qandroidinputcontext.cpp qandroidinputcontext.h
+ qandroidplatformaccessibility.cpp qandroidplatformaccessibility.h
+ qandroidplatformbackingstore.cpp qandroidplatformbackingstore.h
+ qandroidplatformclipboard.cpp qandroidplatformclipboard.h
+ qandroidplatformdialoghelpers.cpp qandroidplatformdialoghelpers.h
+ qandroidplatformfiledialoghelper.cpp qandroidplatformfiledialoghelper.h
+ qandroidplatformfontdatabase.cpp qandroidplatformfontdatabase.h
+ qandroidplatformforeignwindow.cpp qandroidplatformforeignwindow.h
+ qandroidplatformintegration.cpp qandroidplatformintegration.h
+ qandroidplatformmenu.cpp qandroidplatformmenu.h
+ qandroidplatformmenubar.cpp qandroidplatformmenubar.h
+ qandroidplatformmenuitem.cpp qandroidplatformmenuitem.h
+ qandroidplatformoffscreensurface.cpp qandroidplatformoffscreensurface.h
+ qandroidplatformopenglcontext.cpp qandroidplatformopenglcontext.h
+ qandroidplatformopenglwindow.cpp qandroidplatformopenglwindow.h
+ qandroidplatformscreen.cpp qandroidplatformscreen.h
+ qandroidplatformservices.cpp qandroidplatformservices.h
+ qandroidplatformtheme.cpp qandroidplatformtheme.h
+ qandroidplatformwindow.cpp qandroidplatformwindow.h
+ qandroidsystemlocale.cpp qandroidsystemlocale.h
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ ${QT_SOURCE_TREE}/src/3rdparty/android
+ LIBRARIES
+ Qt::AccessibilitySupportPrivate
+ Qt::CorePrivate
+ Qt::EglSupportPrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::AccessibilitySupport
+ Qt::Core
+ Qt::EglSupport
+ Qt::EventDispatcherSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+ android
+ jnigraphics
+# special case begin
+ INSTALL_DIRECTORY
+ plugins/platforms
+ OUTPUT_DIRECTORY
+ plugins/platforms
+ ARCHIVE_INSTALL_DIRECTORY
+ plugins/platforms
+# special case end
+)
+
+#### Keys ignored in scope 1:.:.:android.pro:<TRUE>:
+# OTHER_FILES = "$$PWD/android.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qtforandroid CONDITION QT_FEATURE_vulkan
+ SOURCES
+ qandroidplatformvulkaninstance.cpp qandroidplatformvulkaninstance.h
+ qandroidplatformvulkanwindow.cpp qandroidplatformvulkanwindow.h
+ LIBRARIES
+ Qt::VulkanSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::VulkanSupport
+)
+
+qt_extend_target(qtforandroid CONDITION QT_FEATURE_android_style_assets
+ SOURCES
+ extract.cpp
+)
+
+qt_extend_target(qtforandroid CONDITION NOT QT_FEATURE_android_style_assets
+ SOURCES
+ extract-dummy.cpp
+)
diff --git a/src/plugins/platforms/cocoa/.prev_CMakeLists.txt b/src/plugins/platforms/cocoa/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..b590c4fb98
--- /dev/null
+++ b/src/plugins/platforms/cocoa/.prev_CMakeLists.txt
@@ -0,0 +1,154 @@
+# Generated from cocoa.pro.
+
+#####################################################################
+## qcocoa Plugin:
+#####################################################################
+
+qt_add_plugin(qcocoa
+ TYPE platforms
+ CLASS_NAME QCocoaIntegrationPlugin
+ SOURCES
+ main.mm
+ messages.cpp messages.h
+ qcocoaapplication.h qcocoaapplication.mm
+ qcocoaapplicationdelegate.h qcocoaapplicationdelegate.mm
+ qcocoabackingstore.h qcocoabackingstore.mm
+ qcocoaclipboard.h qcocoaclipboard.mm
+ qcocoacursor.h qcocoacursor.mm
+ qcocoadrag.h qcocoadrag.mm
+ qcocoaeventdispatcher.h qcocoaeventdispatcher.mm
+ qcocoahelpers.h qcocoahelpers.mm
+ qcocoainputcontext.h qcocoainputcontext.mm
+ qcocoaintegration.h qcocoaintegration.mm
+ qcocoaintrospection.h qcocoaintrospection.mm
+ qcocoakeymapper.h qcocoakeymapper.mm
+ qcocoamenu.h qcocoamenu.mm
+ qcocoamenubar.h qcocoamenubar.mm
+ qcocoamenuitem.h qcocoamenuitem.mm
+ qcocoamenuloader.h qcocoamenuloader.mm
+ qcocoamimetypes.h qcocoamimetypes.mm
+ qcocoanativeinterface.h qcocoanativeinterface.mm
+ qcocoansmenu.h qcocoansmenu.mm
+ qcocoascreen.h qcocoascreen.mm
+ qcocoaservices.h qcocoaservices.mm
+ qcocoasystemsettings.h qcocoasystemsettings.mm
+ qcocoasystemtrayicon.h qcocoasystemtrayicon.mm
+ qcocoatheme.h qcocoatheme.mm
+ qcocoawindow.h qcocoawindow.mm
+ qcocoawindowmanager.h qcocoawindowmanager.mm
+ qiosurfacegraphicsbuffer.h qiosurfacegraphicsbuffer.mm
+ qmacclipboard.h qmacclipboard.mm
+ qmultitouch_mac.mm qmultitouch_mac_p.h
+ qnsview.h qnsview.mm
+ qnswindow.h qnswindow.mm
+ qnswindowdelegate.h qnswindowdelegate.mm
+ LIBRARIES
+ Qt::ClipboardSupportPrivate
+ Qt::CorePrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GraphicsSupportPrivate
+ Qt::GuiPrivate
+ Qt::ThemeSupportPrivate
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+ ${FWCarbon}
+ ${FWCoreServices}
+ ${FWCoreVideo}
+ ${FWIOKit}
+ ${FWIOSurface}
+ ${FWMetal}
+ ${FWQuartzCore}
+ Cups::Cups
+ Qt::ClipboardSupport
+ Qt::Core
+ Qt::FontDatabaseSupport
+ Qt::GraphicsSupport
+ Qt::Gui
+ Qt::ThemeSupport
+)
+
+# Resources:
+set(qcocoaresources_resource_files
+ "images/sizeallcursor.png"
+ "images/spincursor.png"
+ "images/waitcursor.png"
+)
+
+qt_add_resource(qcocoa "qcocoaresources"
+ PREFIX
+ "/qt-project.org/mac/cursors"
+ FILES
+ ${qcocoaresources_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:cocoa.pro:<TRUE>:
+# OTHER_FILES = "cocoa.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qcocoa CONDITION QT_FEATURE_opengl
+ SOURCES
+ qcocoaglcontext.h qcocoaglcontext.mm
+)
+
+qt_extend_target(qcocoa CONDITION QT_FEATURE_vulkan
+ SOURCES
+ qcocoavulkaninstance.h qcocoavulkaninstance.mm
+ LIBRARIES
+ Qt::VulkanSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::VulkanSupport
+)
+
+qt_extend_target(qcocoa CONDITION QT_FEATURE_accessibility
+ SOURCES
+ qcocoaaccessibility.h qcocoaaccessibility.mm
+ qcocoaaccessibilityelement.h qcocoaaccessibilityelement.mm
+ LIBRARIES
+ Qt::AccessibilitySupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::AccessibilitySupport
+)
+
+qt_extend_target(qcocoa CONDITION TARGET Qt::Widgets
+ SOURCES
+ qpaintengine_mac.mm qpaintengine_mac_p.h
+ LIBRARIES
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 6:.:.:cocoa.pro:TARGET Qt::Widgets:
+# QT_FOR_CONFIG = "widgets"
+
+qt_extend_target(qcocoa CONDITION TARGET Qt::PrintSupport AND TARGET Qt::Widgets
+ SOURCES
+ qcocoaprintdevice.h qcocoaprintdevice.mm
+ qcocoaprintersupport.h qcocoaprintersupport.mm
+ qprintengine_mac.mm qprintengine_mac_p.h
+ LIBRARIES
+ Qt::PrintSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::PrintSupport
+)
+
+qt_extend_target(qcocoa CONDITION QT_FEATURE_colordialog AND TARGET Qt::Widgets
+ SOURCES
+ qcocoacolordialoghelper.h qcocoacolordialoghelper.mm
+)
+
+qt_extend_target(qcocoa CONDITION QT_FEATURE_filedialog AND TARGET Qt::Widgets
+ SOURCES
+ qcocoafiledialoghelper.h qcocoafiledialoghelper.mm
+)
+
+qt_extend_target(qcocoa CONDITION QT_FEATURE_fontdialog AND TARGET Qt::Widgets
+ SOURCES
+ qcocoafontdialoghelper.h qcocoafontdialoghelper.mm
+)
+
+#### Keys ignored in scope 11:.:.:cocoa.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/cocoa/CMakeLists.txt b/src/plugins/platforms/cocoa/CMakeLists.txt
new file mode 100644
index 0000000000..0c76f99790
--- /dev/null
+++ b/src/plugins/platforms/cocoa/CMakeLists.txt
@@ -0,0 +1,158 @@
+# Generated from cocoa.pro.
+
+# special case:
+qt_find_package(Cups PROVIDED_TARGETS Cups::Cups)
+
+#####################################################################
+## qcocoa Plugin:
+#####################################################################
+
+qt_add_plugin(qcocoa
+ TYPE platforms
+ DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES cocoa # special case
+ CLASS_NAME QCocoaIntegrationPlugin
+ SOURCES
+ main.mm
+ messages.cpp messages.h
+ qcocoaapplication.h qcocoaapplication.mm
+ qcocoaapplicationdelegate.h qcocoaapplicationdelegate.mm
+ qcocoabackingstore.h qcocoabackingstore.mm
+ qcocoaclipboard.h qcocoaclipboard.mm
+ qcocoacursor.h qcocoacursor.mm
+ qcocoadrag.h qcocoadrag.mm
+ qcocoaeventdispatcher.h qcocoaeventdispatcher.mm
+ qcocoahelpers.h qcocoahelpers.mm
+ qcocoainputcontext.h qcocoainputcontext.mm
+ qcocoaintegration.h qcocoaintegration.mm
+ qcocoaintrospection.h qcocoaintrospection.mm
+ qcocoakeymapper.h qcocoakeymapper.mm
+ qcocoamenu.h qcocoamenu.mm
+ qcocoamenubar.h qcocoamenubar.mm
+ qcocoamenuitem.h qcocoamenuitem.mm
+ qcocoamenuloader.h qcocoamenuloader.mm
+ qcocoamimetypes.h qcocoamimetypes.mm
+ qcocoanativeinterface.h qcocoanativeinterface.mm
+ qcocoansmenu.h qcocoansmenu.mm
+ qcocoascreen.h qcocoascreen.mm
+ qcocoaservices.h qcocoaservices.mm
+ qcocoasystemsettings.h qcocoasystemsettings.mm
+ qcocoasystemtrayicon.h qcocoasystemtrayicon.mm
+ qcocoatheme.h qcocoatheme.mm
+ qcocoawindow.h qcocoawindow.mm
+ qcocoawindowmanager.h qcocoawindowmanager.mm
+ qiosurfacegraphicsbuffer.h qiosurfacegraphicsbuffer.mm
+ qmacclipboard.h qmacclipboard.mm
+ qmultitouch_mac.mm qmultitouch_mac_p.h
+ qnsview.h qnsview.mm
+ qnswindow.h qnswindow.mm
+ qnswindowdelegate.h qnswindowdelegate.mm
+ LIBRARIES
+ Qt::ClipboardSupportPrivate
+ Qt::CorePrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GraphicsSupportPrivate
+ Qt::GuiPrivate
+ Qt::ThemeSupportPrivate
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+ ${FWCarbon}
+ ${FWCoreServices}
+ ${FWCoreVideo}
+ ${FWIOKit}
+ ${FWIOSurface}
+ ${FWMetal}
+ ${FWQuartzCore}
+ Cups::Cups
+ Qt::ClipboardSupport
+ Qt::Core
+ Qt::FontDatabaseSupport
+ Qt::GraphicsSupport
+ Qt::Gui
+ Qt::ThemeSupport
+)
+
+# Resources:
+set(qcocoaresources_resource_files
+ "images/sizeallcursor.png"
+ "images/spincursor.png"
+ "images/waitcursor.png"
+)
+
+qt_add_resource(qcocoa "qcocoaresources"
+ PREFIX
+ "/qt-project.org/mac/cursors"
+ FILES
+ ${qcocoaresources_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:cocoa.pro:<TRUE>:
+# OTHER_FILES = "cocoa.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qcocoa CONDITION QT_FEATURE_opengl
+ SOURCES
+ qcocoaglcontext.h qcocoaglcontext.mm
+)
+
+qt_extend_target(qcocoa CONDITION QT_FEATURE_vulkan
+ SOURCES
+ qcocoavulkaninstance.h qcocoavulkaninstance.mm
+ LIBRARIES
+ Qt::VulkanSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::VulkanSupport
+)
+
+qt_extend_target(qcocoa CONDITION QT_FEATURE_accessibility
+ SOURCES
+ qcocoaaccessibility.h qcocoaaccessibility.mm
+ qcocoaaccessibilityelement.h qcocoaaccessibilityelement.mm
+ LIBRARIES
+ Qt::AccessibilitySupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::AccessibilitySupport
+)
+
+qt_extend_target(qcocoa CONDITION TARGET Qt::Widgets
+ SOURCES
+ qpaintengine_mac.mm qpaintengine_mac_p.h
+ LIBRARIES
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 6:.:.:cocoa.pro:TARGET Qt::Widgets:
+# QT_FOR_CONFIG = "widgets"
+
+qt_extend_target(qcocoa CONDITION TARGET Qt::PrintSupport AND TARGET Qt::Widgets
+ SOURCES
+ qcocoaprintdevice.h qcocoaprintdevice.mm
+ qcocoaprintersupport.h qcocoaprintersupport.mm
+ qprintengine_mac.mm qprintengine_mac_p.h
+ LIBRARIES
+ Qt::PrintSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::PrintSupport
+)
+
+qt_extend_target(qcocoa CONDITION QT_FEATURE_colordialog AND TARGET Qt::Widgets
+ SOURCES
+ qcocoacolordialoghelper.h qcocoacolordialoghelper.mm
+)
+
+qt_extend_target(qcocoa CONDITION QT_FEATURE_filedialog AND TARGET Qt::Widgets
+ SOURCES
+ qcocoafiledialoghelper.h qcocoafiledialoghelper.mm
+)
+
+qt_extend_target(qcocoa CONDITION QT_FEATURE_fontdialog AND TARGET Qt::Widgets
+ SOURCES
+ qcocoafontdialoghelper.h qcocoafontdialoghelper.mm
+)
+
+#### Keys ignored in scope 11:.:.:cocoa.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/directfb/.prev_CMakeLists.txt b/src/plugins/platforms/directfb/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..3bfdb81666
--- /dev/null
+++ b/src/plugins/platforms/directfb/.prev_CMakeLists.txt
@@ -0,0 +1,67 @@
+# Generated from directfb.pro.
+
+#####################################################################
+## qdirectfb Plugin:
+#####################################################################
+
+qt_add_plugin(qdirectfb
+ TYPE platforms
+ CLASS_NAME QDirectFbIntegrationPlugin
+ SOURCES
+ main.cpp
+ qdirectfbbackingstore.cpp qdirectfbbackingstore.h
+ qdirectfbblitter.cpp qdirectfbblitter.h
+ qdirectfbconvenience.cpp qdirectfbconvenience.h
+ qdirectfbcursor.cpp qdirectfbcursor.h
+ qdirectfbeglhooks.h
+ qdirectfbinput.cpp qdirectfbinput.h
+ qdirectfbintegration.cpp qdirectfbintegration.h
+ qdirectfbscreen.cpp qdirectfbscreen.h
+ qdirectfbwindow.cpp qdirectfbwindow.h
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ServiceSupportPrivate
+ PUBLIC_LIBRARIES
+ PkgConfig::DirectFB
+ Qt::Core
+ Qt::EventDispatcherSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+ Qt::ServiceSupport
+)
+
+#### Keys ignored in scope 1:.:.:directfb.pro:<TRUE>:
+# OTHER_FILES = "directfb.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qdirectfb CONDITION QT_CONFIG___contains___directfb_egl
+ SOURCES
+ qdirectfb_egl.cpp qdirectfb_egl.h
+ DEFINES
+ DIRECTFB_GL_EGL
+ LIBRARIES
+ Qt::EglSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::EglSupport
+)
+
+qt_extend_target(qdirectfb CONDITION NOT DIRECTFB_PLATFORM_HOOKS_SOURCES_ISEMPTY
+ DEFINES
+ DIRECTFB_PLATFORM_HOOKS
+)
+
+#### Keys ignored in scope 3:.:.:directfb.pro:NOT DIRECTFB_PLATFORM_HOOKS_SOURCES_ISEMPTY:
+# QMAKE_LIBDIR = "$$DIRECTFB_PLATFORM_HOOKS_LIBDIR"
+
+qt_extend_target(qdirectfb CONDITION DIRECTFB_PLATFORM_HOOKS_SOURCES_ISEMPTY
+ SOURCES
+ qdirectfbeglhooks_stub.cpp
+)
+
+#### Keys ignored in scope 5:.:.:directfb.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/directfb/CMakeLists.txt b/src/plugins/platforms/directfb/CMakeLists.txt
new file mode 100644
index 0000000000..5629e79385
--- /dev/null
+++ b/src/plugins/platforms/directfb/CMakeLists.txt
@@ -0,0 +1,71 @@
+# Generated from directfb.pro.
+
+# begin special case:
+qt_find_package(DirectFB)
+# end special case:
+
+#####################################################################
+## qdirectfb Plugin:
+#####################################################################
+
+qt_add_plugin(qdirectfb
+ TYPE platforms
+ CLASS_NAME QDirectFbIntegrationPlugin
+ SOURCES
+ main.cpp
+ qdirectfbbackingstore.cpp qdirectfbbackingstore.h
+ qdirectfbblitter.cpp qdirectfbblitter.h
+ qdirectfbconvenience.cpp qdirectfbconvenience.h
+ qdirectfbcursor.cpp qdirectfbcursor.h
+ qdirectfbeglhooks.h
+ qdirectfbinput.cpp qdirectfbinput.h
+ qdirectfbintegration.cpp qdirectfbintegration.h
+ qdirectfbscreen.cpp qdirectfbscreen.h
+ qdirectfbwindow.cpp qdirectfbwindow.h
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ServiceSupportPrivate
+ PUBLIC_LIBRARIES
+ PkgConfig::DirectFB
+ Qt::Core
+ Qt::EventDispatcherSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+ Qt::ServiceSupport
+)
+
+#### Keys ignored in scope 1:.:.:directfb.pro:<TRUE>:
+# OTHER_FILES = "directfb.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qdirectfb CONDITION QT_CONFIG___contains___directfb_egl
+ SOURCES
+ qdirectfb_egl.cpp qdirectfb_egl.h
+ DEFINES
+ DIRECTFB_GL_EGL
+ LIBRARIES
+ Qt::EglSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::EglSupport
+)
+
+qt_extend_target(qdirectfb CONDITION NOT DIRECTFB_PLATFORM_HOOKS_SOURCES_ISEMPTY
+ DEFINES
+ DIRECTFB_PLATFORM_HOOKS
+)
+
+#### Keys ignored in scope 3:.:.:directfb.pro:NOT DIRECTFB_PLATFORM_HOOKS_SOURCES_ISEMPTY:
+# QMAKE_LIBDIR = "$$DIRECTFB_PLATFORM_HOOKS_LIBDIR"
+
+qt_extend_target(qdirectfb CONDITION DIRECTFB_PLATFORM_HOOKS_SOURCES_ISEMPTY
+ SOURCES
+ qdirectfbeglhooks_stub.cpp
+)
+
+#### Keys ignored in scope 5:.:.:directfb.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/eglfs/.prev_CMakeLists.txt b/src/plugins/platforms/eglfs/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..6f3309ea3c
--- /dev/null
+++ b/src/plugins/platforms/eglfs/.prev_CMakeLists.txt
@@ -0,0 +1,121 @@
+# Generated from eglfs.pro.
+
+#####################################################################
+## EglFSDeviceIntegration Module:
+#####################################################################
+
+qt_add_module(EglFSDeviceIntegration
+ INTERNAL_MODULE
+ SOURCES
+ api/qeglfsdeviceintegration.cpp api/qeglfsdeviceintegration_p.h
+ api/qeglfsglobal_p.h
+ api/qeglfshooks.cpp api/qeglfshooks_p.h
+ api/qeglfsintegration.cpp api/qeglfsintegration_p.h
+ api/qeglfsoffscreenwindow.cpp api/qeglfsoffscreenwindow_p.h
+ api/qeglfsscreen.cpp api/qeglfsscreen_p.h
+ api/qeglfswindow.cpp api/qeglfswindow_p.h
+ DEFINES
+ QT_BUILD_EGL_DEVICE_LIB
+ QT_EGL_NO_X11
+ INCLUDE_DIRECTORIES
+ api
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DeviceDiscoverySupportPrivate
+ Qt::EglSupportPrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FbSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ServiceSupportPrivate
+ Qt::ThemeSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::DeviceDiscoverySupport
+ Qt::EglSupport
+ Qt::EventDispatcherSupport
+ Qt::FbSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+ Qt::ServiceSupport
+ Qt::ThemeSupport
+)
+
+#### Keys ignored in scope 2:.:.:eglfsdeviceintegration.pro:<TRUE>:
+# MODULE = "eglfsdeviceintegration"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(EglFSDeviceIntegration CONDITION TARGET Qt::InputSupportPrivate
+ LIBRARIES
+ Qt::InputSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::InputSupport
+)
+
+qt_extend_target(EglFSDeviceIntegration CONDITION TARGET Qt::PlatformCompositorSupportPrivate
+ LIBRARIES
+ Qt::PlatformCompositorSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::PlatformCompositorSupport
+)
+
+qt_extend_target(EglFSDeviceIntegration CONDITION NOT EGLFS_PLATFORM_HOOKS_SOURCES_ISEMPTY
+ DEFINES
+ EGLFS_PLATFORM_HOOKS
+)
+
+qt_extend_target(EglFSDeviceIntegration CONDITION NOT EGLFS_DEVICE_INTEGRATION_ISEMPTY
+ DEFINES
+ EGLFS_PREFERRED_PLUGIN=
+)
+
+if(QT_FEATURE_cursor)
+ # Resources:
+ set(cursor_resource_files
+ "cursor-atlas.png"
+ "cursor.json"
+ )
+
+ qt_add_resource(EglFSDeviceIntegration "cursor"
+ PREFIX
+ "/"
+ FILES
+ ${cursor_resource_files}
+ )
+endif()
+
+qt_extend_target(EglFSDeviceIntegration CONDITION QT_FEATURE_opengl
+ SOURCES
+ api/qeglfscontext.cpp api/qeglfscontext_p.h
+ api/qeglfscursor.cpp api/qeglfscursor_p.h
+)
+#####################################################################
+## qeglfs Plugin:
+#####################################################################
+
+qt_add_plugin(qeglfs
+ TYPE platforms
+ CLASS_NAME QEglFSIntegrationPlugin
+ SOURCES
+ qeglfsmain.cpp
+ DEFINES
+ QT_EGL_NO_X11
+ INCLUDE_DIRECTORIES
+ api
+ LIBRARIES
+ Qt::EglFSDeviceIntegrationPrivate
+ PUBLIC_LIBRARIES
+ Qt::EglFSDeviceIntegration
+)
+
+#### Keys ignored in scope 11:.:.:eglfs-plugin.pro:<TRUE>:
+# OTHER_FILES = "$$PWD/eglfs.json"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 12:.:.:eglfs-plugin.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
+add_subdirectory(deviceintegration)
diff --git a/src/plugins/platforms/eglfs/CMakeLists.txt b/src/plugins/platforms/eglfs/CMakeLists.txt
new file mode 100644
index 0000000000..01949586bc
--- /dev/null
+++ b/src/plugins/platforms/eglfs/CMakeLists.txt
@@ -0,0 +1,108 @@
+# Generated from eglfs.pro.
+qt_find_package(EGL) # special case
+
+#####################################################################
+## EglFSDeviceIntegration Module:
+#####################################################################
+
+qt_add_module(EglFSDeviceIntegration
+ INTERNAL_MODULE
+ SOURCES
+ api/qeglfsdeviceintegration.cpp api/qeglfsdeviceintegration_p.h
+ api/qeglfsglobal_p.h
+ api/qeglfshooks.cpp api/qeglfshooks_p.h
+ api/qeglfsintegration.cpp api/qeglfsintegration_p.h
+ api/qeglfsoffscreenwindow.cpp api/qeglfsoffscreenwindow_p.h
+ api/qeglfsscreen.cpp api/qeglfsscreen_p.h
+ api/qeglfswindow.cpp api/qeglfswindow_p.h
+ DEFINES
+ QT_BUILD_EGL_DEVICE_LIB
+ QT_EGL_NO_X11
+ INCLUDE_DIRECTORIES
+ api
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DeviceDiscoverySupportPrivate
+ Qt::EglSupportPrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FbSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ServiceSupportPrivate
+ Qt::ThemeSupportPrivate
+ EGL::EGL # special case
+)
+
+#### Keys ignored in scope 2:.:.:eglfsdeviceintegration.pro:<TRUE>:
+# MODULE = "eglfsdeviceintegration"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(EglFSDeviceIntegration CONDITION TARGET Qt::InputSupportPrivate
+ LIBRARIES
+ Qt::InputSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::InputSupport
+)
+
+qt_extend_target(EglFSDeviceIntegration CONDITION TARGET Qt::PlatformCompositorSupportPrivate
+ LIBRARIES
+ Qt::PlatformCompositorSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::PlatformCompositorSupport
+)
+
+# special case:
+# extend_target(EglFSDeviceIntegration CONDITION NOT EGLFS_PLATFORM_HOOKS_SOURCES_ISEMPTY ...
+# extend_target(EglFSDeviceIntegration CONDITION NOT EGLFS_DEVICE_INTEGRATION_ISEMPTY ...
+
+if(QT_FEATURE_cursor) # special case
+ # Resources:
+ set(cursor_resource_files
+ "cursor-atlas.png"
+ "cursor.json"
+ )
+
+ qt_add_resource(EglFSDeviceIntegration "cursor"
+ PREFIX
+ "/"
+ FILES
+ ${cursor_resource_files}
+ )
+endif()
+
+qt_extend_target(EglFSDeviceIntegration CONDITION QT_FEATURE_opengl
+ SOURCES
+ api/qeglfscontext.cpp api/qeglfscontext_p.h
+ api/qeglfscursor.cpp api/qeglfscursor_p.h
+)
+#####################################################################
+## qeglfs Plugin:
+#####################################################################
+
+qt_add_plugin(qeglfs
+ TYPE platforms
+ CLASS_NAME QEglFSIntegrationPlugin
+ DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES eglfs # special case
+ SOURCES
+ qeglfsmain.cpp
+ DEFINES
+ QT_EGL_NO_X11
+ INCLUDE_DIRECTORIES
+ api
+ LIBRARIES
+ Qt::CorePrivate # special case
+ Qt::EglFSDeviceIntegrationPrivate
+ EGL::EGL # special case
+)
+
+#### Keys ignored in scope 11:.:.:eglfs-plugin.pro:<TRUE>:
+# OTHER_FILES = "$$PWD/eglfs.json"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 12:.:.:eglfs-plugin.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
+add_subdirectory(deviceintegration)
diff --git a/src/plugins/platforms/eglfs/deviceintegration/.prev_CMakeLists.txt b/src/plugins/platforms/eglfs/deviceintegration/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..d08bf6bc20
--- /dev/null
+++ b/src/plugins/platforms/eglfs/deviceintegration/.prev_CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from deviceintegration.pro.
+
+if(QT_FEATURE_eglfs_x11)
+ add_subdirectory(eglfs_x11)
+endif()
+if(QT_FEATURE_eglfs_egldevice OR QT_FEATURE_eglfs_gbm)
+ add_subdirectory(eglfs_kms_support)
+endif()
+if(QT_FEATURE_eglfs_gbm)
+ add_subdirectory(eglfs_kms)
+endif()
+if(QT_FEATURE_eglfs_egldevice)
+ add_subdirectory(eglfs_kms_egldevice)
+endif()
+if(QT_FEATURE_eglfs_vsp2)
+ add_subdirectory(eglfs_kms_vsp2)
+endif()
+if(QT_FEATURE_eglfs_brcm)
+ add_subdirectory(eglfs_brcm)
+endif()
+if(QT_FEATURE_eglfs_mali)
+ add_subdirectory(eglfs_mali)
+endif()
+if(QT_FEATURE_eglfs_viv)
+ add_subdirectory(eglfs_viv)
+endif()
+if(QT_FEATURE_eglfs_rcar)
+ add_subdirectory(eglfs_rcar)
+endif()
+if(QT_FEATURE_eglfs_viv_wl)
+ add_subdirectory(eglfs_viv_wl)
+endif()
+if(QT_FEATURE_eglfs_openwfd)
+ add_subdirectory(eglfs_openwfd)
+endif()
+if(QT_FEATURE_opengl)
+ add_subdirectory(eglfs_emu)
+endif()
diff --git a/src/plugins/platforms/eglfs/deviceintegration/CMakeLists.txt b/src/plugins/platforms/eglfs/deviceintegration/CMakeLists.txt
new file mode 100644
index 0000000000..7ddcb8993f
--- /dev/null
+++ b/src/plugins/platforms/eglfs/deviceintegration/CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from deviceintegration.pro.
+
+if(QT_FEATURE_eglfs_x11)
+ add_subdirectory(eglfs_x11)
+endif()
+if(QT_FEATURE_eglfs_egldevice OR QT_FEATURE_eglfs_gbm)
+ add_subdirectory(eglfs_kms_support)
+endif()
+if(QT_FEATURE_eglfs_gbm)
+ add_subdirectory(eglfs_kms)
+endif()
+if(QT_FEATURE_eglfs_egldevice)
+ add_subdirectory(eglfs_kms_egldevice)
+endif()
+if(QT_FEATURE_eglfs_vsp2)
+ # add_subdirectory(eglfs_kms_vsp2) # special case TODO
+endif()
+if(QT_FEATURE_eglfs_brcm)
+ # add_subdirectory(eglfs_brcm) # special case TODO
+endif()
+if(QT_FEATURE_eglfs_mali)
+ # add_subdirectory(eglfs_mali) # special case TODO
+endif()
+if(QT_FEATURE_eglfs_viv)
+ # add_subdirectory(eglfs_viv) # special case TODO
+endif()
+if(QT_FEATURE_eglfs_rcar)
+ # add_subdirectory(eglfs_rcar) # special case TODO
+endif()
+if(QT_FEATURE_eglfs_viv_wl)
+ # add_subdirectory(eglfs_viv_wl) # special case TODO
+endif()
+if(QT_FEATURE_eglfs_openwfd)
+ # add_subdirectory(eglfs_openwfd) # special case TODO
+endif()
+if(QT_FEATURE_opengl)
+ add_subdirectory(eglfs_emu)
+endif()
diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_emu/CMakeLists.txt b/src/plugins/platforms/eglfs/deviceintegration/eglfs_emu/CMakeLists.txt
new file mode 100644
index 0000000000..320ef4f1d8
--- /dev/null
+++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_emu/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from eglfs_emu.pro.
+
+#####################################################################
+## qeglfs-emu-integration Plugin:
+#####################################################################
+
+qt_add_plugin(qeglfs-emu-integration
+ TYPE egldeviceintegrations
+ CLASS_NAME QEglFSEmulatorIntegrationPlugin
+ SOURCES
+ qeglfsemulatorintegration.cpp qeglfsemulatorintegration.h
+ qeglfsemulatorscreen.cpp qeglfsemulatorscreen.h
+ qeglfsemumain.cpp
+ DEFINES
+ QT_EGL_NO_X11
+ INCLUDE_DIRECTORIES
+ ../../api
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EglFSDeviceIntegrationPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EglFSDeviceIntegration
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:eglfs_emu.pro:<TRUE>:
+# DISTFILES = "eglfs_emu.json"
+# OTHER_FILES = "$$PWD/eglfs_emu.json"
diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/CMakeLists.txt b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/CMakeLists.txt
new file mode 100644
index 0000000000..656190e7a8
--- /dev/null
+++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/CMakeLists.txt
@@ -0,0 +1,41 @@
+# Generated from eglfs_kms.pro.
+
+#####################################################################
+## qeglfs-kms-integration Plugin:
+#####################################################################
+
+qt_add_plugin(qeglfs-kms-integration
+ TYPE egldeviceintegrations
+ CLASS_NAME QEglFSKmsGbmIntegrationPlugin
+ SOURCES
+ qeglfskmsgbmcursor.cpp qeglfskmsgbmcursor.h
+ qeglfskmsgbmdevice.cpp qeglfskmsgbmdevice.h
+ qeglfskmsgbmintegration.cpp qeglfskmsgbmintegration.h
+ qeglfskmsgbmmain.cpp
+ qeglfskmsgbmscreen.cpp qeglfskmsgbmscreen.h
+ qeglfskmsgbmwindow.cpp qeglfskmsgbmwindow.h
+ DEFINES
+ QT_EGL_NO_X11
+ INCLUDE_DIRECTORIES
+ ../../api
+ ../eglfs_kms_support
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EdidSupportPrivate
+ Qt::EglFSDeviceIntegrationPrivate
+ Qt::EglFsKmsSupportPrivate
+ Qt::GuiPrivate
+ Qt::KmsSupportPrivate
+ PUBLIC_LIBRARIES
+ Libdrm::Libdrm
+ Qt::Core
+ Qt::EdidSupport
+ Qt::EglFSDeviceIntegration
+ Qt::EglFsKmsSupport
+ Qt::Gui
+ Qt::KmsSupport
+ gbm::gbm
+)
+
+#### Keys ignored in scope 1:.:.:eglfs_kms.pro:<TRUE>:
+# OTHER_FILES = "$$PWD/eglfs_kms.json"
diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/CMakeLists.txt b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/CMakeLists.txt
new file mode 100644
index 0000000000..03a2de61eb
--- /dev/null
+++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from eglfs_kms_egldevice.pro.
+
+#####################################################################
+## qeglfs-kms-egldevice-integration Plugin:
+#####################################################################
+
+qt_add_plugin(qeglfs-kms-egldevice-integration
+ TYPE egldeviceintegrations
+ CLASS_NAME QEglFSKmsEglDeviceIntegrationPlugin
+ SOURCES
+ qeglfskmsegldevice.cpp qeglfskmsegldevice.h
+ qeglfskmsegldeviceintegration.cpp qeglfskmsegldeviceintegration.h
+ qeglfskmsegldevicemain.cpp
+ qeglfskmsegldevicescreen.cpp qeglfskmsegldevicescreen.h
+ DEFINES
+ QT_EGL_NO_X11
+ INCLUDE_DIRECTORIES
+ ../../api
+ ../eglfs_kms_support
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EdidSupportPrivate
+ Qt::EglFSDeviceIntegrationPrivate
+ Qt::EglFsKmsSupportPrivate
+ Qt::GuiPrivate
+ Qt::KmsSupportPrivate
+ PUBLIC_LIBRARIES
+ Libdrm::Libdrm
+ Qt::Core
+ Qt::EdidSupport
+ Qt::EglFSDeviceIntegration
+ Qt::EglFsKmsSupport
+ Qt::Gui
+ Qt::KmsSupport
+)
+
+#### Keys ignored in scope 1:.:.:eglfs_kms_egldevice.pro:<TRUE>:
+# OTHER_FILES = "$$PWD/eglfs_kms_egldevice.json"
diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/CMakeLists.txt b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/CMakeLists.txt
new file mode 100644
index 0000000000..2e8819182c
--- /dev/null
+++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from eglfs_kms_support.pro.
+
+#####################################################################
+## EglFsKmsSupport Module:
+#####################################################################
+
+qt_add_module(EglFsKmsSupport
+ INTERNAL_MODULE
+ NO_MODULE_HEADERS
+ SOURCES
+ qeglfskmsdevice.cpp qeglfskmsdevice.h
+ qeglfskmshelpers.h
+ qeglfskmsintegration.cpp qeglfskmsintegration.h
+ qeglfskmsscreen.cpp qeglfskmsscreen.h
+ DEFINES
+ QT_EGL_NO_X11
+ INCLUDE_DIRECTORIES
+ ../../api
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EdidSupportPrivate
+ Qt::EglFSDeviceIntegrationPrivate
+ Qt::GuiPrivate
+ Qt::KmsSupportPrivate
+ PUBLIC_LIBRARIES
+ Libdrm::Libdrm
+ Qt::Core
+ Qt::EdidSupport
+ Qt::EglFSDeviceIntegration
+ Qt::Gui
+ Qt::KmsSupport
+)
diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_x11/CMakeLists.txt b/src/plugins/platforms/eglfs/deviceintegration/eglfs_x11/CMakeLists.txt
new file mode 100644
index 0000000000..fc0bb6847f
--- /dev/null
+++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_x11/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from eglfs_x11.pro.
+
+#####################################################################
+## qeglfs-x11-integration Plugin:
+#####################################################################
+
+qt_add_plugin(qeglfs-x11-integration
+ TYPE egldeviceintegrations
+ CLASS_NAME QEglFSX11IntegrationPlugin
+ SOURCES
+ qeglfsx11integration.cpp qeglfsx11integration.h
+ qeglfsx11main.cpp
+ DEFINES
+ QT_EGL_NO_X11
+ INCLUDE_DIRECTORIES
+ ../../api
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EglFSDeviceIntegrationPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EglFSDeviceIntegration
+ Qt::Gui
+ X11::XCB
+ XCB::XCB
+)
+
+#### Keys ignored in scope 1:.:.:eglfs_x11.pro:<TRUE>:
+# OTHER_FILES = "$$PWD/eglfs_x11.json"
diff --git a/src/plugins/platforms/ios/.prev_CMakeLists.txt b/src/plugins/platforms/ios/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..f23cf8c300
--- /dev/null
+++ b/src/plugins/platforms/ios/.prev_CMakeLists.txt
@@ -0,0 +1,81 @@
+# Generated from ios.pro.
+
+#####################################################################
+## qios Plugin:
+#####################################################################
+
+add_qt_plugin(qios
+ TYPE platforms
+ CLASS_NAME QIOSIntegrationPlugin
+ SOURCES
+ plugin.mm
+ qiosapplicationdelegate.h qiosapplicationdelegate.mm
+ qiosapplicationstate.h qiosapplicationstate.mm
+ qiosbackingstore.h qiosbackingstore.mm
+ qioscontext.h qioscontext.mm
+ qioseventdispatcher.h qioseventdispatcher.mm
+ qiosglobal.h qiosglobal.mm
+ qiosinputcontext.h qiosinputcontext.mm
+ qiosintegration.h qiosintegration.mm
+ qiosplatformaccessibility.h qiosplatformaccessibility.mm
+ qiosscreen.h qiosscreen.mm
+ qiosservices.h qiosservices.mm
+ qiostextresponder.h qiostextresponder.mm
+ qiostheme.h qiostheme.mm
+ qiosviewcontroller.h qiosviewcontroller.mm
+ qioswindow.h qioswindow.mm
+ quiaccessibilityelement.h quiaccessibilityelement.mm
+ quiview.h quiview.mm
+ LIBRARIES
+ Qt::ClipboardSupportPrivate
+ Qt::CorePrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GraphicsSupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ ${FWAudioToolbox}
+ ${FWFoundation}
+ ${FWQuartzCore}
+ ${FWUIKit}
+ Qt::ClipboardSupport
+ Qt::Core
+ Qt::FontDatabaseSupport
+ Qt::GraphicsSupport
+ Qt::Gui
+)
+
+#### Keys ignored in scope 2:.:.:kernel.pro:<TRUE>:
+# OTHER_FILES = "quiview_textinput.mm" "quiview_accessibility.mm"
+# PLUGIN_CLASS_NAME = "QIOSIntegrationPlugin"
+# PLUGIN_TYPE = "platforms"
+# _LOADED = "qt_plugin"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:kernel.pro:QT_FEATURE_shared:
+# CONFIG = "static"
+
+extend_target(qios CONDITION NOT APPLE_TVOS
+ SOURCES
+ qiosclipboard.h qiosclipboard.mm
+ qiosfiledialog.h qiosfiledialog.mm
+ qiosmenu.h qiosmenu.mm
+ qiosmessagedialog.h qiosmessagedialog.mm
+ qiostextinputoverlay.h qiostextinputoverlay.mm
+ PUBLIC_LIBRARIES
+ ${FWAssetsLibrary}
+)
+
+#### Keys ignored in scope 5:.:.:kernel.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
+add_subdirectory(optional)
+
+ if(QT_FEATURE_shared)
+ endif()
+
+ if(NOT APPLE_TVOS)
+ endif()
+
+ if(NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN)
+ endif()
diff --git a/src/plugins/platforms/ios/CMakeLists.txt b/src/plugins/platforms/ios/CMakeLists.txt
new file mode 100644
index 0000000000..4c9cac2bee
--- /dev/null
+++ b/src/plugins/platforms/ios/CMakeLists.txt
@@ -0,0 +1,72 @@
+# Generated from ios.pro.
+
+#####################################################################
+## qios Plugin:
+#####################################################################
+
+add_qt_plugin(qios
+ TYPE platforms
+ CLASS_NAME QIOSIntegrationPlugin
+ SOURCES
+ plugin.mm
+ qiosapplicationdelegate.h qiosapplicationdelegate.mm
+ qiosapplicationstate.h qiosapplicationstate.mm
+ qiosbackingstore.h qiosbackingstore.mm
+ qioscontext.h qioscontext.mm
+ qioseventdispatcher.h qioseventdispatcher.mm
+ qiosglobal.h qiosglobal.mm
+ qiosinputcontext.h qiosinputcontext.mm
+ qiosintegration.h qiosintegration.mm
+ qiosplatformaccessibility.h qiosplatformaccessibility.mm
+ qiosscreen.h qiosscreen.mm
+ qiosservices.h qiosservices.mm
+ qiostextresponder.h qiostextresponder.mm
+ qiostheme.h qiostheme.mm
+ qiosviewcontroller.h qiosviewcontroller.mm
+ qioswindow.h qioswindow.mm
+ quiaccessibilityelement.h quiaccessibilityelement.mm
+ quiview.h quiview.mm
+ LIBRARIES
+ Qt::ClipboardSupportPrivate
+ Qt::CorePrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GraphicsSupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ ${FWAudioToolbox}
+ ${FWFoundation}
+ ${FWQuartzCore}
+ ${FWUIKit}
+ Qt::ClipboardSupport
+ Qt::Core
+ Qt::FontDatabaseSupport
+ Qt::GraphicsSupport
+ Qt::Gui
+)
+
+#### Keys ignored in scope 2:.:.:kernel.pro:<TRUE>:
+# OTHER_FILES = "quiview_textinput.mm" "quiview_accessibility.mm"
+# PLUGIN_CLASS_NAME = "QIOSIntegrationPlugin"
+# PLUGIN_TYPE = "platforms"
+# _LOADED = "qt_plugin"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:kernel.pro:QT_FEATURE_shared:
+# CONFIG = "static"
+
+extend_target(qios CONDITION NOT APPLE_TVOS
+ SOURCES
+ qiosclipboard.h qiosclipboard.mm
+ qiosfiledialog.h qiosfiledialog.mm
+ qiosmenu.h qiosmenu.mm
+ qiosmessagedialog.h qiosmessagedialog.mm
+ qiostextinputoverlay.h qiostextinputoverlay.mm
+ PUBLIC_LIBRARIES
+ ${FWAssetsLibrary}
+)
+
+#### Keys ignored in scope 5:.:.:kernel.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
+add_subdirectory(optional)
diff --git a/src/plugins/platforms/ios/optional/CMakeLists.txt b/src/plugins/platforms/ios/optional/CMakeLists.txt
new file mode 100644
index 0000000000..a3807bee6c
--- /dev/null
+++ b/src/plugins/platforms/ios/optional/CMakeLists.txt
@@ -0,0 +1,6 @@
+# Generated from optional.pro.
+
+
+if(APPLE_IOS)
+ add_subdirectory(nsphotolibrarysupport)
+endif()
diff --git a/src/plugins/platforms/ios/optional/nsphotolibrarysupport/CMakeLists.txt b/src/plugins/platforms/ios/optional/nsphotolibrarysupport/CMakeLists.txt
new file mode 100644
index 0000000000..5adac3cabb
--- /dev/null
+++ b/src/plugins/platforms/ios/optional/nsphotolibrarysupport/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from nsphotolibrarysupport.pro.
+
+#####################################################################
+## qiosnsphotolibrarysupport Plugin:
+#####################################################################
+
+add_qt_plugin(qiosnsphotolibrarysupport
+ TYPE platforms/darwin
+ CLASS_NAME QIosOptionalPlugin_NSPhotoLibrary
+ SOURCES
+ plugin.mm
+ qiosfileengineassetslibrary.h qiosfileengineassetslibrary.mm
+ qiosfileenginefactory.h
+ qiosimagepickercontroller.h qiosimagepickercontroller.mm
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ ${FWAssetsLibrary}
+ ${FWFoundation}
+ ${FWUIKit}
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:nsphotolibrarysupport.pro:<TRUE>:
+# OTHER_FILES = "plugin.json"
+# PLUGIN_EXTENDS = "-"
+
+## Scopes:
+#####################################################################
diff --git a/src/plugins/platforms/linuxfb/.prev_CMakeLists.txt b/src/plugins/platforms/linuxfb/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..76ec42f0ec
--- /dev/null
+++ b/src/plugins/platforms/linuxfb/.prev_CMakeLists.txt
@@ -0,0 +1,55 @@
+# Generated from linuxfb.pro.
+
+#####################################################################
+## qlinuxfb Plugin:
+#####################################################################
+
+qt_add_plugin(qlinuxfb
+ TYPE platforms
+ CLASS_NAME QLinuxFbIntegrationPlugin
+ SOURCES
+ main.cpp
+ qlinuxfbintegration.cpp qlinuxfbintegration.h
+ qlinuxfbscreen.cpp qlinuxfbscreen.h
+ DEFINES
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FbSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ServiceSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EventDispatcherSupport
+ Qt::FbSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+ Qt::ServiceSupport
+)
+
+#### Keys ignored in scope 1:.:.:linuxfb.pro:<TRUE>:
+# OTHER_FILES = "linuxfb.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qlinuxfb CONDITION TARGET Qt::InputSupportPrivate
+ LIBRARIES
+ Qt::InputSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::InputSupport
+)
+
+qt_extend_target(qlinuxfb CONDITION TARGET Qt::KmsSupportPrivate
+ SOURCES
+ qlinuxfbdrmscreen.cpp qlinuxfbdrmscreen.h
+ LIBRARIES
+ Qt::KmsSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::KmsSupport
+)
+
+#### Keys ignored in scope 4:.:.:linuxfb.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/linuxfb/CMakeLists.txt b/src/plugins/platforms/linuxfb/CMakeLists.txt
new file mode 100644
index 0000000000..ac2c216130
--- /dev/null
+++ b/src/plugins/platforms/linuxfb/CMakeLists.txt
@@ -0,0 +1,56 @@
+# Generated from linuxfb.pro.
+
+#####################################################################
+## qlinuxfb Plugin:
+#####################################################################
+
+qt_add_plugin(qlinuxfb
+ TYPE platforms
+ CLASS_NAME QLinuxFbIntegrationPlugin
+ DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES linuxfb # special case
+ SOURCES
+ main.cpp
+ qlinuxfbintegration.cpp qlinuxfbintegration.h
+ qlinuxfbscreen.cpp qlinuxfbscreen.h
+ DEFINES
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FbSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ServiceSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EventDispatcherSupport
+ Qt::FbSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+ Qt::ServiceSupport
+)
+
+#### Keys ignored in scope 1:.:.:linuxfb.pro:<TRUE>:
+# OTHER_FILES = "linuxfb.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qlinuxfb CONDITION TARGET Qt::InputSupportPrivate
+ LIBRARIES
+ Qt::InputSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::InputSupport
+)
+
+qt_extend_target(qlinuxfb CONDITION TARGET Qt::KmsSupportPrivate
+ SOURCES
+ qlinuxfbdrmscreen.cpp qlinuxfbdrmscreen.h
+ LIBRARIES
+ Qt::KmsSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::KmsSupport
+)
+
+#### Keys ignored in scope 4:.:.:linuxfb.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/minimal/.prev_CMakeLists.txt b/src/plugins/platforms/minimal/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..3ceb3e9ef1
--- /dev/null
+++ b/src/plugins/platforms/minimal/.prev_CMakeLists.txt
@@ -0,0 +1,40 @@
+# Generated from minimal.pro.
+
+#####################################################################
+## qminimal Plugin:
+#####################################################################
+
+qt_add_plugin(qminimal
+ TYPE platforms
+ CLASS_NAME QMinimalIntegrationPlugin
+ SOURCES
+ main.cpp
+ qminimalbackingstore.cpp qminimalbackingstore.h
+ qminimalintegration.cpp qminimalintegration.h
+ DEFINES
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EventDispatcherSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:minimal.pro:<TRUE>:
+# OTHER_FILES = "minimal.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qminimal CONDITION QT_FEATURE_freetype
+ LIBRARIES
+ WrapFreetype::WrapFreetype
+)
+
+#### Keys ignored in scope 3:.:.:minimal.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/minimal/CMakeLists.txt b/src/plugins/platforms/minimal/CMakeLists.txt
new file mode 100644
index 0000000000..5a6307889b
--- /dev/null
+++ b/src/plugins/platforms/minimal/CMakeLists.txt
@@ -0,0 +1,41 @@
+# Generated from minimal.pro.
+
+#####################################################################
+## qminimal Plugin:
+#####################################################################
+
+qt_add_plugin(qminimal
+ TYPE platforms
+ CLASS_NAME QMinimalIntegrationPlugin
+ DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES minimal # special case
+ SOURCES
+ main.cpp
+ qminimalbackingstore.cpp qminimalbackingstore.h
+ qminimalintegration.cpp qminimalintegration.h
+ DEFINES
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EventDispatcherSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:minimal.pro:<TRUE>:
+# OTHER_FILES = "minimal.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qminimal CONDITION QT_FEATURE_freetype
+ LIBRARIES
+ WrapFreetype::WrapFreetype
+)
+
+#### Keys ignored in scope 3:.:.:minimal.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/minimalegl/.prev_CMakeLists.txt b/src/plugins/platforms/minimalegl/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..ab797ea67d
--- /dev/null
+++ b/src/plugins/platforms/minimalegl/.prev_CMakeLists.txt
@@ -0,0 +1,43 @@
+# Generated from minimalegl.pro.
+
+#####################################################################
+## qminimalegl Plugin:
+#####################################################################
+
+qt_add_plugin(qminimalegl
+ TYPE platforms
+ CLASS_NAME QMinimalEglIntegrationPlugin
+ SOURCES
+ main.cpp
+ qminimaleglintegration.cpp qminimaleglintegration.h
+ qminimaleglscreen.cpp qminimaleglscreen.h
+ qminimaleglwindow.cpp qminimaleglwindow.h
+ DEFINES
+ QT_EGL_NO_X11
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EglSupportPrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EglSupport
+ Qt::EventDispatcherSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:minimalegl.pro:<TRUE>:
+# OTHER_FILES = "minimalegl.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qminimalegl CONDITION QT_FEATURE_opengl
+ SOURCES
+ qminimaleglbackingstore.cpp qminimaleglbackingstore.h
+)
+
+#### Keys ignored in scope 3:.:.:minimalegl.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/minimalegl/CMakeLists.txt b/src/plugins/platforms/minimalegl/CMakeLists.txt
new file mode 100644
index 0000000000..0d925fed68
--- /dev/null
+++ b/src/plugins/platforms/minimalegl/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from minimalegl.pro.
+
+#####################################################################
+## qminimalegl Plugin:
+#####################################################################
+
+qt_add_plugin(qminimalegl
+ TYPE platforms
+ CLASS_NAME QMinimalEglIntegrationPlugin
+ DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES minimalegl # special case
+ SOURCES
+ main.cpp
+ qminimaleglintegration.cpp qminimaleglintegration.h
+ qminimaleglscreen.cpp qminimaleglscreen.h
+ qminimaleglwindow.cpp qminimaleglwindow.h
+ DEFINES
+ QT_EGL_NO_X11
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EglSupportPrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EglSupport
+ Qt::EventDispatcherSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:minimalegl.pro:<TRUE>:
+# OTHER_FILES = "minimalegl.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qminimalegl CONDITION QT_FEATURE_opengl
+ SOURCES
+ qminimaleglbackingstore.cpp qminimaleglbackingstore.h
+)
+
+#### Keys ignored in scope 3:.:.:minimalegl.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/offscreen/.prev_CMakeLists.txt b/src/plugins/platforms/offscreen/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..3980ab62f8
--- /dev/null
+++ b/src/plugins/platforms/offscreen/.prev_CMakeLists.txt
@@ -0,0 +1,45 @@
+# Generated from offscreen.pro.
+
+#####################################################################
+## qoffscreen Plugin:
+#####################################################################
+
+qt_add_plugin(qoffscreen
+ TYPE platforms
+ CLASS_NAME QOffscreenIntegrationPlugin
+ SOURCES
+ main.cpp
+ qoffscreencommon.cpp qoffscreencommon.h
+ qoffscreenintegration.cpp qoffscreenintegration.h
+ qoffscreenwindow.cpp qoffscreenwindow.h
+ DEFINES
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EventDispatcherSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:offscreen.pro:<TRUE>:
+# OTHER_FILES = "offscreen.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qoffscreen CONDITION QT_FEATURE_opengl AND QT_FEATURE_xlib AND NOT QT_FEATURE_opengles2
+ SOURCES
+ qoffscreenintegration_x11.cpp qoffscreenintegration_x11.h
+ LIBRARIES
+ Qt::GlxSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::GlxSupport
+)
+
+#### Keys ignored in scope 3:.:.:offscreen.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/offscreen/CMakeLists.txt b/src/plugins/platforms/offscreen/CMakeLists.txt
new file mode 100644
index 0000000000..03576b898e
--- /dev/null
+++ b/src/plugins/platforms/offscreen/CMakeLists.txt
@@ -0,0 +1,46 @@
+# Generated from offscreen.pro.
+
+#####################################################################
+## qoffscreen Plugin:
+#####################################################################
+
+qt_add_plugin(qoffscreen
+ TYPE platforms
+ CLASS_NAME QOffscreenIntegrationPlugin
+ DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES offscreen # special case
+ SOURCES
+ main.cpp
+ qoffscreencommon.cpp qoffscreencommon.h
+ qoffscreenintegration.cpp qoffscreenintegration.h
+ qoffscreenwindow.cpp qoffscreenwindow.h
+ DEFINES
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EventDispatcherSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:offscreen.pro:<TRUE>:
+# OTHER_FILES = "offscreen.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qoffscreen CONDITION QT_FEATURE_opengl AND QT_FEATURE_xlib AND NOT QT_FEATURE_opengles2
+ SOURCES
+ qoffscreenintegration_x11.cpp qoffscreenintegration_x11.h
+ LIBRARIES
+ Qt::GlxSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::GlxSupport
+)
+
+#### Keys ignored in scope 3:.:.:offscreen.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/vnc/.prev_CMakeLists.txt b/src/plugins/platforms/vnc/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..276730755a
--- /dev/null
+++ b/src/plugins/platforms/vnc/.prev_CMakeLists.txt
@@ -0,0 +1,51 @@
+# Generated from vnc.pro.
+
+#####################################################################
+## qvnc Plugin:
+#####################################################################
+
+qt_add_plugin(qvnc
+ TYPE platforms
+ CLASS_NAME QVncIntegrationPlugin
+ SOURCES
+ main.cpp
+ qvnc.cpp qvnc_p.h
+ qvncclient.cpp qvncclient.h
+ qvncintegration.cpp qvncintegration.h
+ qvncscreen.cpp qvncscreen.h
+ DEFINES
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FbSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ServiceSupportPrivate
+ Qt::ThemeSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EventDispatcherSupport
+ Qt::FbSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+ Qt::Network
+ Qt::ServiceSupport
+ Qt::ThemeSupport
+)
+
+#### Keys ignored in scope 1:.:.:vnc.pro:<TRUE>:
+# OTHER_FILES = "vnc.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qvnc CONDITION TARGET Qt::InputSupportPrivate
+ LIBRARIES
+ Qt::InputSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::InputSupport
+)
+
+#### Keys ignored in scope 3:.:.:vnc.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/vnc/CMakeLists.txt b/src/plugins/platforms/vnc/CMakeLists.txt
new file mode 100644
index 0000000000..0b5295287b
--- /dev/null
+++ b/src/plugins/platforms/vnc/CMakeLists.txt
@@ -0,0 +1,52 @@
+# Generated from vnc.pro.
+
+#####################################################################
+## qvnc Plugin:
+#####################################################################
+
+qt_add_plugin(qvnc
+ TYPE platforms
+ CLASS_NAME QVncIntegrationPlugin
+ DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES vnc # special case
+ SOURCES
+ main.cpp
+ qvnc.cpp qvnc_p.h
+ qvncclient.cpp qvncclient.h
+ qvncintegration.cpp qvncintegration.h
+ qvncscreen.cpp qvncscreen.h
+ DEFINES
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FbSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ServiceSupportPrivate
+ Qt::ThemeSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EventDispatcherSupport
+ Qt::FbSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+ Qt::Network
+ Qt::ServiceSupport
+ Qt::ThemeSupport
+)
+
+#### Keys ignored in scope 1:.:.:vnc.pro:<TRUE>:
+# OTHER_FILES = "vnc.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qvnc CONDITION TARGET Qt::InputSupportPrivate
+ LIBRARIES
+ Qt::InputSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::InputSupport
+)
+
+#### Keys ignored in scope 3:.:.:vnc.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/windows/.prev_CMakeLists.txt b/src/plugins/platforms/windows/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..a23b1643de
--- /dev/null
+++ b/src/plugins/platforms/windows/.prev_CMakeLists.txt
@@ -0,0 +1,243 @@
+# Generated from windows.pro.
+
+#####################################################################
+## qwindows Plugin:
+#####################################################################
+
+qt_add_plugin(qwindows
+ TYPE platforms
+ CLASS_NAME QWindowsIntegrationPlugin
+ SOURCES
+ main.cpp
+ qtwindowsglobal.h
+ qwin10helpers.cpp qwin10helpers.h
+ qwindowsbackingstore.cpp qwindowsbackingstore.h
+ qwindowscombase.h
+ qwindowscontext.cpp qwindowscontext.h
+ qwindowscursor.cpp qwindowscursor.h
+ qwindowsdialoghelpers.cpp qwindowsdialoghelpers.h
+ qwindowsdropdataobject.cpp qwindowsdropdataobject.h
+ qwindowsgdiintegration.cpp qwindowsgdiintegration.h
+ qwindowsgdinativeinterface.cpp qwindowsgdinativeinterface.h
+ qwindowsinputcontext.cpp qwindowsinputcontext.h
+ qwindowsintegration.cpp qwindowsintegration.h
+ qwindowsinternalmimedata.cpp qwindowsinternalmimedata.h
+ qwindowskeymapper.cpp qwindowskeymapper.h
+ qwindowsmenu.cpp qwindowsmenu.h
+ qwindowsmime.cpp qwindowsmime.h
+ qwindowsmousehandler.cpp qwindowsmousehandler.h
+ qwindowsnativeinterface.cpp qwindowsnativeinterface.h
+ qwindowsole.cpp qwindowsole.h
+ qwindowsopengltester.cpp qwindowsopengltester.h
+ qwindowspointerhandler.cpp qwindowspointerhandler.h
+ qwindowsscreen.cpp qwindowsscreen.h
+ qwindowsservices.cpp qwindowsservices.h
+ qwindowstheme.cpp qwindowstheme.h
+ qwindowsthreadpoolrunner.h
+ qwindowswindow.cpp qwindowswindow.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ThemeSupportPrivate
+ advapi32
+ d3d9
+ gdi32
+ ole32
+ shell32
+ user32
+ winmm
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EventDispatcherSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+ Qt::ThemeSupport
+ dwmapi
+ imm32
+ oleaut32
+ shlwapi
+ winspool
+ wtsapi32
+)
+
+# Resources:
+set_source_files_properties("openglblacklists/default.json"
+ PROPERTIES QT_RESOURCE_ALIAS "default.json"
+)
+set(openglblacklists_resource_files
+ "openglblacklists/default.json"
+)
+
+qt_add_resource(qwindows "openglblacklists"
+ PREFIX
+ "/qt-project.org/windows/openglblacklists"
+ FILES
+ ${openglblacklists_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:windows.pro:<TRUE>:
+# OTHER_FILES = "windows.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_accessibility
+ SOURCES
+ uiautomation/qwindowsuiaaccessibility.cpp uiautomation/qwindowsuiaaccessibility.h
+ uiautomation/qwindowsuiabaseprovider.cpp uiautomation/qwindowsuiabaseprovider.h
+ uiautomation/qwindowsuiagriditemprovider.cpp uiautomation/qwindowsuiagriditemprovider.h
+ uiautomation/qwindowsuiagridprovider.cpp uiautomation/qwindowsuiagridprovider.h
+ uiautomation/qwindowsuiainvokeprovider.cpp uiautomation/qwindowsuiainvokeprovider.h
+ uiautomation/qwindowsuiamainprovider.cpp uiautomation/qwindowsuiamainprovider.h
+ uiautomation/qwindowsuiaprovidercache.cpp uiautomation/qwindowsuiaprovidercache.h
+ uiautomation/qwindowsuiarangevalueprovider.cpp uiautomation/qwindowsuiarangevalueprovider.h
+ uiautomation/qwindowsuiaselectionitemprovider.cpp uiautomation/qwindowsuiaselectionitemprovider.h
+ uiautomation/qwindowsuiaselectionprovider.cpp uiautomation/qwindowsuiaselectionprovider.h
+ uiautomation/qwindowsuiatableitemprovider.cpp uiautomation/qwindowsuiatableitemprovider.h
+ uiautomation/qwindowsuiatableprovider.cpp uiautomation/qwindowsuiatableprovider.h
+ uiautomation/qwindowsuiatextprovider.cpp uiautomation/qwindowsuiatextprovider.h
+ uiautomation/qwindowsuiatextrangeprovider.cpp uiautomation/qwindowsuiatextrangeprovider.h
+ uiautomation/qwindowsuiatoggleprovider.cpp uiautomation/qwindowsuiatoggleprovider.h
+ uiautomation/qwindowsuiautils.cpp uiautomation/qwindowsuiautils.h
+ uiautomation/qwindowsuiavalueprovider.cpp uiautomation/qwindowsuiavalueprovider.h
+ uiautomation/qwindowsuiawindowprovider.cpp uiautomation/qwindowsuiawindowprovider.h
+ LIBRARIES
+ Qt::AccessibilitySupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::AccessibilitySupport
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_vulkan
+ SOURCES
+ qwindowsvulkaninstance.cpp qwindowsvulkaninstance.h
+ LIBRARIES
+ Qt::VulkanSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::VulkanSupport
+)
+
+#### Keys ignored in scope 4:.:.:windows.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_opengl AND NOT QT_FEATURE_dynamicgl AND NOT QT_FEATURE_opengles2
+ PUBLIC_LIBRARIES
+ opengl32
+)
+
+qt_extend_target(qwindows CONDITION mingw
+ PUBLIC_LIBRARIES
+ uuid
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_opengl
+ SOURCES
+ qwindowsopenglcontext.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_opengles2
+ SOURCES
+ qwindowseglcontext.cpp qwindowseglcontext.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_opengl AND NOT QT_FEATURE_opengles2
+ SOURCES
+ qwindowsglcontext.cpp qwindowsglcontext.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_dynamicgl
+ SOURCES
+ qwindowseglcontext.cpp qwindowseglcontext.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_systemtrayicon
+ SOURCES
+ qwindowssystemtrayicon.cpp qwindowssystemtrayicon.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_clipboard
+ SOURCES
+ qwindowsclipboard.cpp qwindowsclipboard.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_clipboard AND QT_FEATURE_draganddrop
+ SOURCES
+ qwindowsdrag.cpp qwindowsdrag.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_tabletevent
+ SOURCES
+ qwindowstabletsupport.cpp qwindowstabletsupport.h
+ INCLUDE_DIRECTORIES
+ ${QT_SOURCE_TREE}/src/3rdparty/wintab
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_sessionmanager
+ SOURCES
+ qwindowssessionmanager.cpp qwindowssessionmanager.h
+)
+
+if(QT_FEATURE_imageformat_png)
+ # Resources:
+ set(cursors_resource_files
+ "images/closedhandcursor_32.png"
+ "images/closedhandcursor_48.png"
+ "images/closedhandcursor_64.png"
+ "images/dragcopycursor_32.png"
+ "images/dragcopycursor_48.png"
+ "images/dragcopycursor_64.png"
+ "images/draglinkcursor_32.png"
+ "images/draglinkcursor_48.png"
+ "images/draglinkcursor_64.png"
+ "images/dragmovecursor_32.png"
+ "images/dragmovecursor_48.png"
+ "images/dragmovecursor_64.png"
+ "images/openhandcursor_32.png"
+ "images/openhandcursor_48.png"
+ "images/openhandcursor_64.png"
+ "images/splithcursor_32.png"
+ "images/splithcursor_48.png"
+ "images/splithcursor_64.png"
+ "images/splitvcursor_32.png"
+ "images/splitvcursor_48.png"
+ "images/splitvcursor_64.png"
+ )
+
+ qt_add_resource(qwindows "cursors"
+ PREFIX
+ "/qt-project.org/windows/cursors"
+ FILES
+ ${cursors_resource_files}
+ )
+endif()
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_accessibility AND TARGET Qt::WindowsUIAutomationSupportPrivate
+ LIBRARIES
+ Qt::WindowsUIAutomationSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::WindowsUIAutomationSupport
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_accessibility AND mingw
+ PUBLIC_LIBRARIES
+ uuid
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_combined_angle_lib
+ DEFINES
+ LIBEGL_NAME=
+ LIBGLESV2_NAME=
+)
+
+qt_extend_target(qwindows CONDITION NOT QT_FEATURE_combined_angle_lib
+ DEFINES
+ LIBEGL_NAME=
+ LIBGLESV2_NAME=
+)
diff --git a/src/plugins/platforms/windows/CMakeLists.txt b/src/plugins/platforms/windows/CMakeLists.txt
new file mode 100644
index 0000000000..7b07bcf5de
--- /dev/null
+++ b/src/plugins/platforms/windows/CMakeLists.txt
@@ -0,0 +1,237 @@
+# Generated from windows.pro.
+
+#####################################################################
+## qwindows Plugin:
+#####################################################################
+
+qt_add_plugin(qwindows
+ TYPE platforms
+ CLASS_NAME QWindowsIntegrationPlugin
+ DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES windows # special case
+ SOURCES
+ main.cpp
+ qtwindowsglobal.h
+ qwin10helpers.cpp qwin10helpers.h
+ qwindowsbackingstore.cpp qwindowsbackingstore.h
+ qwindowscombase.h
+ qwindowscontext.cpp qwindowscontext.h
+ qwindowscursor.cpp qwindowscursor.h
+ qwindowsdialoghelpers.cpp qwindowsdialoghelpers.h
+ qwindowsdropdataobject.cpp qwindowsdropdataobject.h
+ qwindowsgdiintegration.cpp qwindowsgdiintegration.h
+ qwindowsgdinativeinterface.cpp qwindowsgdinativeinterface.h
+ qwindowsinputcontext.cpp qwindowsinputcontext.h
+ qwindowsintegration.cpp qwindowsintegration.h
+ qwindowsinternalmimedata.cpp qwindowsinternalmimedata.h
+ qwindowskeymapper.cpp qwindowskeymapper.h
+ qwindowsmenu.cpp qwindowsmenu.h
+ qwindowsmime.cpp qwindowsmime.h
+ qwindowsmousehandler.cpp qwindowsmousehandler.h
+ qwindowsnativeinterface.cpp qwindowsnativeinterface.h
+ qwindowsole.cpp qwindowsole.h
+ qwindowsopengltester.cpp qwindowsopengltester.h
+ qwindowspointerhandler.cpp qwindowspointerhandler.h
+ qwindowsscreen.cpp qwindowsscreen.h
+ qwindowsservices.cpp qwindowsservices.h
+ qwindowstheme.cpp qwindowstheme.h
+ qwindowsthreadpoolrunner.h
+ qwindowswindow.cpp qwindowswindow.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ThemeSupportPrivate
+ advapi32
+ d3d9
+ gdi32
+ ole32
+ shell32
+ user32
+ winmm
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EventDispatcherSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+ Qt::ThemeSupport
+ dwmapi
+ imm32
+ oleaut32
+ shlwapi
+ winspool
+ wtsapi32
+)
+
+# Resources:
+set_source_files_properties("openglblacklists/default.json"
+ PROPERTIES QT_RESOURCE_ALIAS "default.json"
+)
+set(openglblacklists_resource_files
+ "openglblacklists/default.json"
+)
+
+qt_add_resource(qwindows "openglblacklists"
+ PREFIX
+ "/qt-project.org/windows/openglblacklists"
+ FILES
+ ${openglblacklists_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:windows.pro:<TRUE>:
+# OTHER_FILES = "windows.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_accessibility
+ SOURCES
+ uiautomation/qwindowsuiaaccessibility.cpp uiautomation/qwindowsuiaaccessibility.h
+ uiautomation/qwindowsuiabaseprovider.cpp uiautomation/qwindowsuiabaseprovider.h
+ uiautomation/qwindowsuiagriditemprovider.cpp uiautomation/qwindowsuiagriditemprovider.h
+ uiautomation/qwindowsuiagridprovider.cpp uiautomation/qwindowsuiagridprovider.h
+ uiautomation/qwindowsuiainvokeprovider.cpp uiautomation/qwindowsuiainvokeprovider.h
+ uiautomation/qwindowsuiamainprovider.cpp uiautomation/qwindowsuiamainprovider.h
+ uiautomation/qwindowsuiaprovidercache.cpp uiautomation/qwindowsuiaprovidercache.h
+ uiautomation/qwindowsuiarangevalueprovider.cpp uiautomation/qwindowsuiarangevalueprovider.h
+ uiautomation/qwindowsuiaselectionitemprovider.cpp uiautomation/qwindowsuiaselectionitemprovider.h
+ uiautomation/qwindowsuiaselectionprovider.cpp uiautomation/qwindowsuiaselectionprovider.h
+ uiautomation/qwindowsuiatableitemprovider.cpp uiautomation/qwindowsuiatableitemprovider.h
+ uiautomation/qwindowsuiatableprovider.cpp uiautomation/qwindowsuiatableprovider.h
+ uiautomation/qwindowsuiatextprovider.cpp uiautomation/qwindowsuiatextprovider.h
+ uiautomation/qwindowsuiatextrangeprovider.cpp uiautomation/qwindowsuiatextrangeprovider.h
+ uiautomation/qwindowsuiatoggleprovider.cpp uiautomation/qwindowsuiatoggleprovider.h
+ uiautomation/qwindowsuiautils.cpp uiautomation/qwindowsuiautils.h
+ uiautomation/qwindowsuiavalueprovider.cpp uiautomation/qwindowsuiavalueprovider.h
+ uiautomation/qwindowsuiawindowprovider.cpp uiautomation/qwindowsuiawindowprovider.h
+ LIBRARIES
+ Qt::AccessibilitySupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::AccessibilitySupport
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_vulkan
+ SOURCES
+ qwindowsvulkaninstance.cpp qwindowsvulkaninstance.h
+ LIBRARIES
+ Qt::VulkanSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::VulkanSupport
+)
+
+#### Keys ignored in scope 4:.:.:windows.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_opengl AND NOT QT_FEATURE_dynamicgl AND NOT QT_FEATURE_opengles2
+ PUBLIC_LIBRARIES
+ opengl32
+)
+
+qt_extend_target(qwindows CONDITION mingw
+ PUBLIC_LIBRARIES
+ uuid
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_opengl
+ SOURCES
+ qwindowsopenglcontext.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_opengles2
+ SOURCES
+ qwindowseglcontext.cpp qwindowseglcontext.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_opengl AND NOT QT_FEATURE_opengles2
+ SOURCES
+ qwindowsglcontext.cpp qwindowsglcontext.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_dynamicgl
+ SOURCES
+ qwindowseglcontext.cpp qwindowseglcontext.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_systemtrayicon
+ SOURCES
+ qwindowssystemtrayicon.cpp qwindowssystemtrayicon.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_clipboard
+ SOURCES
+ qwindowsclipboard.cpp qwindowsclipboard.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_clipboard AND QT_FEATURE_draganddrop
+ SOURCES
+ qwindowsdrag.cpp qwindowsdrag.h
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_tabletevent
+ SOURCES
+ qwindowstabletsupport.cpp qwindowstabletsupport.h
+ INCLUDE_DIRECTORIES
+ ${QT_SOURCE_TREE}/src/3rdparty/wintab
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_sessionmanager
+ SOURCES
+ qwindowssessionmanager.cpp qwindowssessionmanager.h
+)
+
+if(QT_FEATURE_imageformat_png)
+ # Resources:
+ set(cursors_resource_files
+ "images/closedhandcursor_32.png"
+ "images/closedhandcursor_48.png"
+ "images/closedhandcursor_64.png"
+ "images/dragcopycursor_32.png"
+ "images/dragcopycursor_48.png"
+ "images/dragcopycursor_64.png"
+ "images/draglinkcursor_32.png"
+ "images/draglinkcursor_48.png"
+ "images/draglinkcursor_64.png"
+ "images/dragmovecursor_32.png"
+ "images/dragmovecursor_48.png"
+ "images/dragmovecursor_64.png"
+ "images/openhandcursor_32.png"
+ "images/openhandcursor_48.png"
+ "images/openhandcursor_64.png"
+ "images/splithcursor_32.png"
+ "images/splithcursor_48.png"
+ "images/splithcursor_64.png"
+ "images/splitvcursor_32.png"
+ "images/splitvcursor_48.png"
+ "images/splitvcursor_64.png"
+ )
+
+ qt_add_resource(qwindows "cursors"
+ PREFIX
+ "/qt-project.org/windows/cursors"
+ FILES
+ ${cursors_resource_files}
+ )
+endif()
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_accessibility AND TARGET Qt::WindowsUIAutomationSupportPrivate
+ LIBRARIES
+ Qt::WindowsUIAutomationSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::WindowsUIAutomationSupport
+)
+
+qt_extend_target(qwindows CONDITION QT_FEATURE_accessibility AND mingw
+ PUBLIC_LIBRARIES
+ uuid
+)
+
+# special case:
+# extend_target(qwindows CONDITION QT_FEATURE_combined_angle_lib ...
+# extend_target(qwindows CONDITION NOT QT_FEATURE_combined_angle_lib ...
+
diff --git a/src/plugins/platforms/windows/qwindowscontext.cpp b/src/plugins/platforms/windows/qwindowscontext.cpp
index d31352b854..88d3131de2 100644
--- a/src/plugins/platforms/windows/qwindowscontext.cpp
+++ b/src/plugins/platforms/windows/qwindowscontext.cpp
@@ -973,7 +973,7 @@ QByteArray QWindowsContext::comErrorString(HRESULT hr)
}
_com_error error(hr);
result += QByteArrayLiteral(" (");
- result += errorMessageFromComError(error);
+ result += errorMessageFromComError(error).toUtf8();
result += ')';
return result;
}
diff --git a/src/plugins/platforms/xcb/.prev_CMakeLists.txt b/src/plugins/platforms/xcb/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..c504bbc64d
--- /dev/null
+++ b/src/plugins/platforms/xcb/.prev_CMakeLists.txt
@@ -0,0 +1,177 @@
+# Generated from xcb.pro.
+
+#####################################################################
+## XcbQpa Module:
+#####################################################################
+
+qt_add_module(XcbQpa
+ INTERNAL_MODULE
+ NO_MODULE_HEADERS
+ SOURCES
+ gl_integrations/qxcbglintegration.cpp gl_integrations/qxcbglintegration.h
+ gl_integrations/qxcbglintegrationfactory.cpp gl_integrations/qxcbglintegrationfactory.h
+ gl_integrations/qxcbglintegrationplugin.h
+ gl_integrations/qxcbnativeinterfacehandler.cpp gl_integrations/qxcbnativeinterfacehandler.h
+ qxcbatom.cpp qxcbatom.h
+ qxcbbackingstore.cpp qxcbbackingstore.h
+ qxcbclipboard.cpp qxcbclipboard.h
+ qxcbconnection.cpp qxcbconnection.h
+ qxcbconnection_basic.cpp qxcbconnection_basic.h
+ qxcbconnection_screens.cpp
+ qxcbconnection_xi2.cpp
+ qxcbcursor.cpp qxcbcursor.h
+ qxcbeventdispatcher.cpp qxcbeventdispatcher.h
+ qxcbeventqueue.cpp qxcbeventqueue.h
+ qxcbimage.cpp qxcbimage.h
+ qxcbintegration.cpp qxcbintegration.h
+ qxcbkeyboard.cpp qxcbkeyboard.h
+ qxcbmime.cpp qxcbmime.h
+ qxcbnativeinterface.cpp qxcbnativeinterface.h
+ qxcbobject.h
+ qxcbscreen.cpp qxcbscreen.h
+ qxcbsystemtraytracker.cpp qxcbsystemtraytracker.h
+ qxcbwindow.cpp qxcbwindow.h
+ qxcbwmsupport.cpp qxcbwmsupport.h
+ qxcbxsettings.cpp qxcbxsettings.h
+ DEFINES
+ QT_BUILD_XCB_PLUGIN
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ gl_integrations
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EdidSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ServiceSupportPrivate
+ Qt::ThemeSupportPrivate
+ Qt::XkbCommonSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EdidSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+ Qt::ServiceSupport
+ Qt::ThemeSupport
+ Qt::XkbCommonSupport
+ XCB::ICCCM
+ XCB::IMAGE
+ XCB::KEYSYMS
+ XCB::RANDR
+ XCB::RENDER
+ XCB::RENDERUTIL
+ XCB::SHAPE
+ XCB::SHM
+ XCB::SYNC
+ XCB::XCB
+ XCB::XFIXES
+ XCB::XINERAMA
+ XCB::XINPUT
+ XCB::XKB
+ XKB::XKB
+)
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(XcbQpa CONDITION TARGET Qt::LinuxAccessibilitySupportPrivate
+ LIBRARIES
+ Qt::LinuxAccessibilitySupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::LinuxAccessibilitySupport
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_vulkan
+ SOURCES
+ qxcbvulkaninstance.cpp qxcbvulkaninstance.h
+ qxcbvulkanwindow.cpp qxcbvulkanwindow.h
+ LIBRARIES
+ Qt::VulkanSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::VulkanSupport
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_glib
+ LIBRARIES
+ GLIB2::GLIB2
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_draganddrop
+ SOURCES
+ qxcbdrag.cpp qxcbdrag.h
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_xcb_xlib
+ PUBLIC_LIBRARIES
+ X11::XCB
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_xcb_sm
+ SOURCES
+ qxcbsessionmanager.cpp qxcbsessionmanager.h
+ PUBLIC_LIBRARIES
+ ${X11_SM_LIB} ${X11_ICE_LIB}
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_dlopen
+ PUBLIC_LIBRARIES
+ ${CMAKE_DL_LIBS}
+)
+
+qt_extend_target(XcbQpa CONDITION CLANG AND NOT ICC
+ COMPILE_OPTIONS
+ -ftemplate-depth=1024
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_xcb_native_painting
+ SOURCES
+ nativepainting/qbackingstore_x11.cpp nativepainting/qbackingstore_x11_p.h
+ nativepainting/qcolormap_x11.cpp nativepainting/qcolormap_x11_p.h
+ nativepainting/qpaintengine_x11.cpp nativepainting/qpaintengine_x11_p.h
+ nativepainting/qpixmap_x11.cpp nativepainting/qpixmap_x11_p.h
+ nativepainting/qt_x11_p.h
+ nativepainting/qtessellator.cpp nativepainting/qtessellator_p.h
+ nativepainting/qxcbnativepainting.cpp nativepainting/qxcbnativepainting.h
+ INCLUDE_DIRECTORIES
+ nativepainting
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_xcb_native_painting AND QT_FEATURE_xrender
+ PUBLIC_LIBRARIES
+ PkgConfig::XRender
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_fontconfig AND QT_FEATURE_xcb_native_painting
+ LIBRARIES
+ WrapFreetype::WrapFreetype
+)
+#####################################################################
+## qxcb Plugin:
+#####################################################################
+
+qt_add_plugin(qxcb
+ TYPE platforms
+ CLASS_NAME QXcbIntegrationPlugin
+ SOURCES
+ qxcbmain.cpp
+ DEFINES
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::XcbQpaPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::XcbQpa
+)
+
+#### Keys ignored in scope 19:.:.:xcb-plugin.pro:<TRUE>:
+# OTHER_FILES = "xcb.json" "README"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 21:.:.:xcb-plugin.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
+add_subdirectory(gl_integrations)
diff --git a/src/plugins/platforms/xcb/CMakeLists.txt b/src/plugins/platforms/xcb/CMakeLists.txt
new file mode 100644
index 0000000000..c74e33e31a
--- /dev/null
+++ b/src/plugins/platforms/xcb/CMakeLists.txt
@@ -0,0 +1,221 @@
+# Generated from xcb.pro.
+
+# begin special case:
+qt_find_package(X11_XCB
+ PROVIDED_TARGETS
+ X11::XCB
+)
+qt_find_package(X11
+ PROVIDED_TARGETS
+ X11::X11
+)
+qt_find_package(XCB)
+qt_find_package(XKB)
+qt_find_package(PkgConfig)
+qt_find_package(WrapFreetype)
+qt_find_package(GLIB2
+ PROVIDED_TARGETS
+ GLIB2::GLIB2
+)
+qt_find_package(XRender PROVIDED_TARGETS PkgConfig::XRender)
+qt_find_package(XKB_COMMON_X11 PROVIDED_TARGETS PkgConfig::XKB_COMMON_X11)
+
+# end special case:
+
+#####################################################################
+## XcbQpa Module:
+#####################################################################
+
+qt_add_module(XcbQpa
+ INTERNAL_MODULE
+ NO_MODULE_HEADERS
+ SOURCES
+ gl_integrations/qxcbglintegration.cpp gl_integrations/qxcbglintegration.h
+ gl_integrations/qxcbglintegrationfactory.cpp gl_integrations/qxcbglintegrationfactory.h
+ gl_integrations/qxcbglintegrationplugin.h
+ gl_integrations/qxcbnativeinterfacehandler.cpp gl_integrations/qxcbnativeinterfacehandler.h
+ qxcbatom.cpp qxcbatom.h
+ qxcbbackingstore.cpp qxcbbackingstore.h
+ qxcbclipboard.cpp qxcbclipboard.h
+ qxcbconnection.cpp qxcbconnection.h
+ qxcbconnection_basic.cpp qxcbconnection_basic.h
+ qxcbconnection_screens.cpp
+ qxcbconnection_xi2.cpp
+ qxcbcursor.cpp qxcbcursor.h
+ qxcbeventdispatcher.cpp qxcbeventdispatcher.h
+ qxcbeventqueue.cpp qxcbeventqueue.h
+ qxcbimage.cpp qxcbimage.h
+ qxcbintegration.cpp qxcbintegration.h
+ qxcbkeyboard.cpp qxcbkeyboard.h
+ qxcbmime.cpp qxcbmime.h
+ qxcbnativeinterface.cpp qxcbnativeinterface.h
+ qxcbobject.h
+ qxcbscreen.cpp qxcbscreen.h
+ qxcbsystemtraytracker.cpp qxcbsystemtraytracker.h
+ qxcbwindow.cpp qxcbwindow.h
+ qxcbwmsupport.cpp qxcbwmsupport.h
+ qxcbxsettings.cpp qxcbxsettings.h
+ DEFINES
+ QT_BUILD_XCB_PLUGIN
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ gl_integrations
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EdidSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ServiceSupportPrivate
+ Qt::ThemeSupportPrivate
+ Qt::XkbCommonSupportPrivate
+ PkgConfig::XKB_COMMON_X11 # special case
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EdidSupport
+ Qt::FontDatabaseSupport
+ Qt::Gui
+ Qt::ServiceSupport
+ Qt::ThemeSupport
+ Qt::XkbCommonSupport
+ XCB::ICCCM
+ XCB::IMAGE
+ XCB::KEYSYMS
+ XCB::RANDR
+ XCB::RENDER
+ XCB::RENDERUTIL
+ XCB::SHAPE
+ XCB::SHM
+ XCB::SYNC
+ XCB::XCB
+ XCB::XFIXES
+ XCB::XINERAMA
+ $<$<TARGET_EXISTS:XCB::XINPUT>:XCB::XINPUT> # special case
+ XCB::XKB
+ XKB::XKB
+)
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(XcbQpa CONDITION TARGET Qt::LinuxAccessibilitySupportPrivate
+ LIBRARIES
+ Qt::LinuxAccessibilitySupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::LinuxAccessibilitySupport
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_vulkan
+ SOURCES
+ qxcbvulkaninstance.cpp qxcbvulkaninstance.h
+ qxcbvulkanwindow.cpp qxcbvulkanwindow.h
+ LIBRARIES
+ Qt::VulkanSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::VulkanSupport
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_glib
+ LIBRARIES
+ GLIB2::GLIB2
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_draganddrop
+ SOURCES
+ qxcbdrag.cpp qxcbdrag.h
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_xcb_xlib
+ PUBLIC_LIBRARIES
+ X11::XCB
+ X11::X11 # special case
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_xcb_sm
+ SOURCES
+ qxcbsessionmanager.cpp qxcbsessionmanager.h
+ PUBLIC_LIBRARIES
+ ${X11_SM_LIB} ${X11_ICE_LIB}
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_dlopen
+ PUBLIC_LIBRARIES
+ ${CMAKE_DL_LIBS}
+)
+
+qt_extend_target(XcbQpa CONDITION CLANG AND NOT ICC
+ COMPILE_OPTIONS
+ -ftemplate-depth=1024
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_xcb_native_painting
+ SOURCES
+ nativepainting/qbackingstore_x11.cpp nativepainting/qbackingstore_x11_p.h
+ nativepainting/qcolormap_x11.cpp nativepainting/qcolormap_x11_p.h
+ nativepainting/qpaintengine_x11.cpp nativepainting/qpaintengine_x11_p.h
+ nativepainting/qpixmap_x11.cpp nativepainting/qpixmap_x11_p.h
+ nativepainting/qt_x11_p.h
+ nativepainting/qtessellator.cpp nativepainting/qtessellator_p.h
+ nativepainting/qxcbnativepainting.cpp nativepainting/qxcbnativepainting.h
+ INCLUDE_DIRECTORIES
+ nativepainting
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_xcb_native_painting AND QT_FEATURE_xrender
+ PUBLIC_LIBRARIES
+ PkgConfig::XRender
+)
+
+qt_extend_target(XcbQpa CONDITION QT_FEATURE_fontconfig AND QT_FEATURE_xcb_native_painting
+ LIBRARIES
+ WrapFreetype::WrapFreetype
+)
+
+# special case begin
+if (NOT QT_FEATURE_system_xcb_input)
+ set(xinput_source "${PROJECT_SOURCE_DIR}/src/3rdparty/xcb/libxcb/xinput.c")
+ set_source_files_properties(
+ "${xinput_source}"
+ PROPERTIES COMPILE_OPTIONS "-w"
+ )
+ target_sources(XcbQpa PRIVATE "${xinput_source}")
+ target_include_directories(XcbQpa PRIVATE
+ "${PROJECT_SOURCE_DIR}/src/3rdparty/xcb/include"
+ )
+endif()
+# special case end
+
+#####################################################################
+## qxcb Plugin:
+#####################################################################
+
+qt_add_plugin(qxcb
+ TYPE platforms
+ CLASS_NAME QXcbIntegrationPlugin
+ DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES xcb # special case
+ SOURCES
+ qxcbmain.cpp
+ DEFINES
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::XcbQpaPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::XcbQpa
+)
+
+#### Keys ignored in scope 19:.:.:xcb-plugin.pro:<TRUE>:
+# OTHER_FILES = "xcb.json" "README"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 21:.:.:xcb-plugin.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
+add_subdirectory(gl_integrations)
+if(OFF)
+ add_subdirectory(xcb-static) # special case TODO: xcb-static sub folder
+endif()
+
diff --git a/src/plugins/platforms/xcb/gl_integrations/CMakeLists.txt b/src/plugins/platforms/xcb/gl_integrations/CMakeLists.txt
new file mode 100644
index 0000000000..210a924550
--- /dev/null
+++ b/src/plugins/platforms/xcb/gl_integrations/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from gl_integrations.pro.
+
+if(QT_FEATURE_xcb_egl_plugin)
+ add_subdirectory(xcb_egl)
+endif()
+if(QT_FEATURE_xcb_glx_plugin)
+ add_subdirectory(xcb_glx)
+endif()
diff --git a/src/plugins/platforms/xcb/gl_integrations/xcb_egl/CMakeLists.txt b/src/plugins/platforms/xcb/gl_integrations/xcb_egl/CMakeLists.txt
new file mode 100644
index 0000000000..1d1833450b
--- /dev/null
+++ b/src/plugins/platforms/xcb/gl_integrations/xcb_egl/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from xcb_egl.pro.
+
+#####################################################################
+## qxcb-egl-integration Plugin:
+#####################################################################
+
+qt_add_plugin(qxcb-egl-integration
+ TYPE xcbglintegrations
+ CLASS_NAME QXcbEglIntegrationPlugin
+ SOURCES
+ qxcbeglcontext.h
+ qxcbeglintegration.cpp qxcbeglintegration.h
+ qxcbeglmain.cpp
+ qxcbeglnativeinterfacehandler.cpp qxcbeglnativeinterfacehandler.h
+ qxcbeglwindow.cpp qxcbeglwindow.h
+ DEFINES
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ ..
+ ../..
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EglSupportPrivate
+ Qt::GuiPrivate
+ Qt::XcbQpaPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::EglSupport
+ Qt::Gui
+ Qt::XcbQpa
+)
diff --git a/src/plugins/platforms/xcb/gl_integrations/xcb_glx/CMakeLists.txt b/src/plugins/platforms/xcb/gl_integrations/xcb_glx/CMakeLists.txt
new file mode 100644
index 0000000000..dfb74d7138
--- /dev/null
+++ b/src/plugins/platforms/xcb/gl_integrations/xcb_glx/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from xcb_glx.pro.
+
+#####################################################################
+## qxcb-glx-integration Plugin:
+#####################################################################
+
+qt_add_plugin(qxcb-glx-integration
+ TYPE xcbglintegrations
+ CLASS_NAME QXcbGlxIntegrationPlugin
+ SOURCES
+ qglxintegration.cpp qglxintegration.h
+ qxcbglxintegration.cpp qxcbglxintegration.h
+ qxcbglxmain.cpp
+ qxcbglxnativeinterfacehandler.cpp qxcbglxnativeinterfacehandler.h
+ qxcbglxwindow.cpp qxcbglxwindow.h
+ DEFINES
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ ..
+ ../..
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GlxSupportPrivate
+ Qt::GuiPrivate
+ Qt::XcbQpaPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::GlxSupport
+ Qt::Gui
+ Qt::XcbQpa
+)
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qxcb-glx-integration CONDITION QT_FEATURE_xcb_glx
+ PUBLIC_LIBRARIES
+ XCB::GLX
+)
+
+qt_extend_target(qxcb-glx-integration CONDITION QT_FEATURE_dlopen AND NOT static
+ PUBLIC_LIBRARIES
+ ${CMAKE_DL_LIBS}
+)
diff --git a/src/plugins/platformthemes/CMakeLists.txt b/src/plugins/platformthemes/CMakeLists.txt
new file mode 100644
index 0000000000..6aa17c234c
--- /dev/null
+++ b/src/plugins/platformthemes/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from platformthemes.pro.
+
+if(QT_FEATURE_dbus AND QT_FEATURE_mimetype AND QT_FEATURE_regularexpression)
+ add_subdirectory(xdgdesktopportal)
+endif()
+if(QT_FEATURE_gtk3 AND TARGET Qt::Widgets)
+ add_subdirectory(gtk3)
+endif()
diff --git a/src/plugins/platformthemes/gtk3/.prev_CMakeLists.txt b/src/plugins/platformthemes/gtk3/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..de76f45c26
--- /dev/null
+++ b/src/plugins/platformthemes/gtk3/.prev_CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from gtk3.pro.
+
+#####################################################################
+## qgtk3 Plugin:
+#####################################################################
+
+qt_add_plugin(qgtk3
+ TYPE platformthemes
+ CLASS_NAME QGtk3ThemePlugin
+ SOURCES
+ main.cpp
+ qgtk3dialoghelpers.cpp qgtk3dialoghelpers.h
+ qgtk3menu.cpp qgtk3menu.h
+ qgtk3theme.cpp qgtk3theme.h
+ DEFINES
+ GDK_VERSION_MIN_REQUIRED=GDK_VERSION_3_6
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::ThemeSupportPrivate
+ PUBLIC_LIBRARIES
+ PkgConfig::GTK3
+ Qt::Core
+ Qt::Gui
+ Qt::ThemeSupport
+)
+
+#### Keys ignored in scope 1:.:.:gtk3.pro:<TRUE>:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platformthemes/gtk3/CMakeLists.txt b/src/plugins/platformthemes/gtk3/CMakeLists.txt
new file mode 100644
index 0000000000..f467f48a9d
--- /dev/null
+++ b/src/plugins/platformthemes/gtk3/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from gtk3.pro.
+
+qt_find_package(GTK3) # special case
+qt_find_package(X11) # special case
+
+#####################################################################
+## qgtk3 Plugin:
+#####################################################################
+
+qt_add_plugin(qgtk3
+ TYPE platformthemes
+ CLASS_NAME QGtk3ThemePlugin
+ SOURCES
+ main.cpp
+ qgtk3dialoghelpers.cpp qgtk3dialoghelpers.h
+ qgtk3menu.cpp qgtk3menu.h
+ qgtk3theme.cpp qgtk3theme.h
+ DEFINES
+ GDK_VERSION_MIN_REQUIRED=GDK_VERSION_3_6
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::ThemeSupportPrivate
+ X11::X11 # special case
+ PUBLIC_LIBRARIES
+ PkgConfig::GTK3
+ Qt::Core
+ Qt::Gui
+ Qt::ThemeSupport
+)
+
+#### Keys ignored in scope 1:.:.:gtk3.pro:<TRUE>:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platformthemes/xdgdesktopportal/CMakeLists.txt b/src/plugins/platformthemes/xdgdesktopportal/CMakeLists.txt
new file mode 100644
index 0000000000..6939c8d9e4
--- /dev/null
+++ b/src/plugins/platformthemes/xdgdesktopportal/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from xdgdesktopportal.pro.
+
+#####################################################################
+## qxdgdesktopportal Plugin:
+#####################################################################
+
+qt_add_plugin(qxdgdesktopportal
+ TYPE platformthemes
+ CLASS_NAME QXdgDesktopPortalThemePlugin
+ SOURCES
+ main.cpp
+ qxdgdesktopportalfiledialog.cpp qxdgdesktopportalfiledialog_p.h
+ qxdgdesktopportaltheme.cpp qxdgdesktopportaltheme.h
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::ThemeSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::DBus
+ Qt::Gui
+ Qt::ThemeSupport
+)
+
+#### Keys ignored in scope 1:.:.:xdgdesktopportal.pro:<TRUE>:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/printsupport/.prev_CMakeLists.txt b/src/plugins/printsupport/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..5853d82c6a
--- /dev/null
+++ b/src/plugins/printsupport/.prev_CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from printsupport.pro.
+
+if(APPLE_OSX)
+ add_subdirectory(cocoa)
+endif()
+if(WIN32)
+ add_subdirectory(windows)
+endif()
+if(QT_FEATURE_cups AND UNIX AND NOT APPLE)
+ add_subdirectory(cups)
+endif()
diff --git a/src/plugins/printsupport/CMakeLists.txt b/src/plugins/printsupport/CMakeLists.txt
new file mode 100644
index 0000000000..22b753f5c0
--- /dev/null
+++ b/src/plugins/printsupport/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from printsupport.pro.
+
+if(APPLE_OSX)
+ add_subdirectory(cocoa)
+endif()
+if(WIN32)
+ # add_subdirectory(windows) # special case TODO
+endif()
+if(QT_FEATURE_cups AND UNIX AND NOT APPLE)
+ add_subdirectory(cups)
+endif()
diff --git a/src/plugins/printsupport/cocoa/CMakeLists.txt b/src/plugins/printsupport/cocoa/CMakeLists.txt
new file mode 100644
index 0000000000..c8de1e76f6
--- /dev/null
+++ b/src/plugins/printsupport/cocoa/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from cocoa.pro.
+
+#####################################################################
+## cocoaprintersupport Plugin:
+#####################################################################
+
+qt_add_plugin(cocoaprintersupport
+ TYPE printsupport
+ CLASS_NAME QCocoaPrinterSupportPlugin
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::PrintSupportPrivate
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+ Qt::Core
+ Qt::Gui
+ Qt::PrintSupport
+)
+
+#### Keys ignored in scope 1:.:.:cocoa.pro:<TRUE>:
+# MODULE = "cocoaprintersupport"
+# OTHER_FILES = "cocoa.json"
diff --git a/src/plugins/printsupport/cups/.prev_CMakeLists.txt b/src/plugins/printsupport/cups/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..bbf8a60b3f
--- /dev/null
+++ b/src/plugins/printsupport/cups/.prev_CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from cups.pro.
+
+#####################################################################
+## cupsprintersupport Plugin:
+#####################################################################
+
+qt_add_plugin(cupsprintersupport
+ TYPE printsupport
+ CLASS_NAME QCupsPrinterSupportPlugin
+ SOURCES
+ main.cpp
+ qcupsprintengine.cpp qcupsprintengine_p.h
+ qcupsprintersupport.cpp qcupsprintersupport_p.h
+ qppdprintdevice.cpp qppdprintdevice.h
+ INCLUDE_DIRECTORIES
+ ../../../printsupport/kernel
+ LIBRARIES
+ Cups::Cups
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::PrintSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::PrintSupport
+)
+
+#### Keys ignored in scope 1:.:.:cups.pro:<TRUE>:
+# MODULE = "cupsprintersupport"
+# OTHER_FILES = "cups.json"
diff --git a/src/plugins/printsupport/cups/CMakeLists.txt b/src/plugins/printsupport/cups/CMakeLists.txt
new file mode 100644
index 0000000000..6fc4efc941
--- /dev/null
+++ b/src/plugins/printsupport/cups/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from cups.pro.
+
+qt_find_package(Cups PROVIDED_TARGETS Cups::Cups) # special case
+
+#####################################################################
+## cupsprintersupport Plugin:
+#####################################################################
+
+qt_add_plugin(cupsprintersupport
+ TYPE printsupport
+ CLASS_NAME QCupsPrinterSupportPlugin
+ SOURCES
+ main.cpp
+ qcupsprintengine.cpp qcupsprintengine_p.h
+ qcupsprintersupport.cpp qcupsprintersupport_p.h
+ qppdprintdevice.cpp qppdprintdevice.h
+ INCLUDE_DIRECTORIES
+ ../../../printsupport/kernel
+ LIBRARIES
+ Cups::Cups
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::PrintSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::PrintSupport
+)
+
+#### Keys ignored in scope 1:.:.:cups.pro:<TRUE>:
+# MODULE = "cupsprintersupport"
+# OTHER_FILES = "cups.json"
diff --git a/src/plugins/sqldrivers/.prev_CMakeLists.txt b/src/plugins/sqldrivers/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..8752cf701f
--- /dev/null
+++ b/src/plugins/sqldrivers/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from sqldrivers.pro.
+
+cmake_minimum_required(VERSION 3.15.0)
+
+project(ldrivers_FIXME
+ VERSION 6.0.0
+ DESCRIPTION "Qt ldrivers_FIXME Libraries"
+ HOMEPAGE_URL "https://qt.io/"
+ LANGUAGES CXX C
+)
+
+find_package(Qt6 ${PROJECT_VERSION} CONFIG REQUIRED COMPONENTS BuildInternals Core SET_ME_TO_SOMETHING_USEFUL)
+find_package(Qt6 ${PROJECT_VERSION} CONFIG OPTIONAL_COMPONENTS SET_ME_TO_SOMETHING_USEFUL)
+
+qt_build_repo()
diff --git a/src/plugins/sqldrivers/CMakeLists.txt b/src/plugins/sqldrivers/CMakeLists.txt
new file mode 100644
index 0000000000..d45f5712a8
--- /dev/null
+++ b/src/plugins/sqldrivers/CMakeLists.txt
@@ -0,0 +1,55 @@
+# Generated from sqldrivers.pro.
+
+# special case begin
+# Currently handled completely manually.
+
+# TODO sqldrivers_standalone {
+# _QMAKE_CACHE_ = $$shadowed($$SQLDRV_SRC_TREE)/.qmake.conf
+# load(qt_configure)
+# }
+
+qt_feature_module_begin(
+ NO_MODULE
+ PUBLIC_FILE "qtsqldrivers-config.h"
+ PRIVATE_FILE "qtsqldrivers-config_p.h"
+)
+include(configure.cmake)
+qt_feature_module_end(NO_MODULE)
+
+
+if(QT_FEATURE_sql_psql)
+ add_subdirectory(psql)
+endif()
+
+if(QT_FEATURE_sql_mysql)
+ add_subdirectory(mysql)
+endif()
+
+if(QT_FEATURE_sql_odbc)
+ add_subdirectory(odbc)
+endif()
+
+if(QT_FEATURE_sql_tds)
+# TODO add_subdirectory(tds)
+endif()
+
+if(QT_FEATURE_sql_oci)
+ add_subdirectory(oci)
+endif()
+
+if(QT_FEATURE_sql_db2)
+ add_subdirectory(db2)
+endif()
+
+if(QT_FEATURE_sql_sqlite)
+ add_subdirectory(sqlite)
+endif()
+
+if(QT_FEATURE_sql_sqlite2)
+# TODO add_subdirectory(sqlite2)
+endif()
+
+if(QT_FEATURE_sql_ibase)
+# TODO add_subdirectory(ibase)
+endif()
+# special case end
diff --git a/src/plugins/sqldrivers/configure.cmake b/src/plugins/sqldrivers/configure.cmake
new file mode 100644
index 0000000000..c8005e16a7
--- /dev/null
+++ b/src/plugins/sqldrivers/configure.cmake
@@ -0,0 +1,58 @@
+
+
+#### Inputs
+
+
+
+#### Libraries
+
+qt_find_package(DB2 PROVIDED_TARGETS DB2::DB2)
+qt_find_package(MySQL PROVIDED_TARGETS MySQL::MySQL)
+qt_find_package(PostgreSQL PROVIDED_TARGETS PostgreSQL::PostgreSQL)
+qt_find_package(Oracle PROVIDED_TARGETS Oracle::OCI)
+qt_find_package(ODBC PROVIDED_TARGETS ODBC::ODBC)
+qt_find_package(SQLite3 PROVIDED_TARGETS SQLite::SQLite3)
+
+
+#### Tests
+
+
+
+#### Features
+
+qt_feature("sql-db2" PRIVATE
+ LABEL "DB2 (IBM)"
+ CONDITION DB2_FOUND
+)
+qt_feature("sql-ibase" PRIVATE
+ LABEL "InterBase"
+ CONDITION libs.ibase OR FIXME
+)
+qt_feature("sql-mysql" PRIVATE
+ LABEL "MySql"
+ CONDITION MySQL_FOUND
+)
+qt_feature("sql-oci" PRIVATE
+ LABEL "OCI (Oracle)"
+ CONDITION Oracle_FOUND
+)
+qt_feature("sql-odbc" PRIVATE
+ LABEL "ODBC"
+ CONDITION QT_FEATURE_datestring AND ODBC_FOUND
+)
+qt_feature("sql-psql" PRIVATE
+ LABEL "PostgreSQL"
+ CONDITION PostgreSQL_FOUND
+)
+qt_feature("sql-sqlite2" PRIVATE
+ LABEL "SQLite2"
+ CONDITION libs.sqlite2 OR FIXME
+)
+qt_feature("sql-sqlite" PRIVATE
+ LABEL "SQLite"
+ CONDITION QT_FEATURE_datestring AND SQLite3_FOUND
+)
+qt_feature("sql-tds" PRIVATE
+ LABEL "TDS (Sybase)"
+ CONDITION QT_FEATURE_datestring AND libs.tds OR FIXME
+)
diff --git a/src/plugins/sqldrivers/configure.json b/src/plugins/sqldrivers/configure.json
index 28ccbeadcd..94cf2dd4a5 100644
--- a/src/plugins/sqldrivers/configure.json
+++ b/src/plugins/sqldrivers/configure.json
@@ -218,9 +218,7 @@
{
"type": "warning",
"condition": "config.win32 && !config.msvc && features.sql-oci",
- "message": "Qt does not support compiling the Oracle database driver with
-MinGW, due to lack of such support from Oracle. Consider disabling the
-Oracle driver, as the current build will most likely fail."
+ "message": "Qt does not support compiling the Oracle database driver with MinGW, due to lack of such support from Oracle. Consider disabling the Oracle driver, as the current build will most likely fail."
}
],
diff --git a/src/plugins/sqldrivers/db2/CMakeLists.txt b/src/plugins/sqldrivers/db2/CMakeLists.txt
new file mode 100644
index 0000000000..d3d46bebbb
--- /dev/null
+++ b/src/plugins/sqldrivers/db2/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from db2.pro.
+
+#####################################################################
+## qsqldb2 Plugin:
+#####################################################################
+
+qt_add_plugin(qsqldb2
+ TYPE sqldrivers
+ CLASS_NAME QDB2DriverPlugin
+ SOURCES
+ main.cpp
+ qsql_db2.cpp qsql_db2_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ DB2::DB2
+ Qt::Core
+ Qt::Sql
+)
+
+#### Keys ignored in scope 1:.:.:db2.pro:<TRUE>:
+# OTHER_FILES = "db2.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qsqldb2 CONDITION (TEST_architecture_arch STREQUAL "x86_64")
+ DEFINES
+ ODBC64
+)
diff --git a/src/plugins/sqldrivers/mysql/CMakeLists.txt b/src/plugins/sqldrivers/mysql/CMakeLists.txt
new file mode 100644
index 0000000000..e55a062c9b
--- /dev/null
+++ b/src/plugins/sqldrivers/mysql/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from mysql.pro.
+
+#####################################################################
+## qsqlmysql Plugin:
+#####################################################################
+
+qt_add_plugin(qsqlmysql
+ TYPE sqldrivers
+ CLASS_NAME QMYSQLDriverPlugin
+ SOURCES
+ main.cpp
+ qsql_mysql.cpp qsql_mysql_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ MySQL::MySQL
+ Qt::Core
+ Qt::Sql
+)
+
+#### Keys ignored in scope 1:.:.:mysql.pro:<TRUE>:
+# OTHER_FILES = "mysql.json"
diff --git a/src/plugins/sqldrivers/oci/CMakeLists.txt b/src/plugins/sqldrivers/oci/CMakeLists.txt
new file mode 100644
index 0000000000..3215b87c46
--- /dev/null
+++ b/src/plugins/sqldrivers/oci/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from oci.pro.
+
+#####################################################################
+## qsqloci Plugin:
+#####################################################################
+
+qt_add_plugin(qsqloci
+ TYPE sqldrivers
+ CLASS_NAME QOCIDriverPlugin
+ SOURCES
+ main.cpp
+ qsql_oci.cpp qsql_oci_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Oracle::OCI
+ Qt::Core
+ Qt::Sql
+)
+
+#### Keys ignored in scope 1:.:.:oci.pro:<TRUE>:
+# OTHER_FILES = "oci.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qsqloci CONDITION APPLE
+ LINK_OPTIONS
+ "-Wl,-flat_namespace,-U,_environ"
+)
diff --git a/src/plugins/sqldrivers/odbc/.prev_CMakeLists.txt b/src/plugins/sqldrivers/odbc/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..5eda5899cf
--- /dev/null
+++ b/src/plugins/sqldrivers/odbc/.prev_CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from odbc.pro.
+
+#####################################################################
+## qsqlodbc Plugin:
+#####################################################################
+
+qt_add_plugin(qsqlodbc
+ TYPE sqldrivers
+ CLASS_NAME QODBCDriverPlugin
+ SOURCES
+ main.cpp
+ qsql_odbc.cpp qsql_odbc_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ ODBC::ODBC
+ Qt::Core
+ Qt::Sql
+)
+
+#### Keys ignored in scope 1:.:.:odbc.pro:<TRUE>:
+# OTHER_FILES = "odbc.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qsqlodbc CONDITION UNIX
+ DEFINES
+ UNICODE
+)
diff --git a/src/plugins/sqldrivers/odbc/CMakeLists.txt b/src/plugins/sqldrivers/odbc/CMakeLists.txt
new file mode 100644
index 0000000000..871e87a4c1
--- /dev/null
+++ b/src/plugins/sqldrivers/odbc/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from odbc.pro.
+
+#####################################################################
+## qsqlodbc Plugin:
+#####################################################################
+
+qt_find_package(ODBC) # special case
+
+qt_add_plugin(qsqlodbc
+ TYPE sqldrivers
+ CLASS_NAME QODBCDriverPlugin
+ SOURCES
+ main.cpp
+ qsql_odbc.cpp qsql_odbc_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ ODBC::ODBC
+ Qt::Core
+ Qt::Sql
+)
+
+#### Keys ignored in scope 1:.:.:odbc.pro:<TRUE>:
+# OTHER_FILES = "odbc.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qsqlodbc CONDITION UNIX
+ DEFINES
+ UNICODE
+)
diff --git a/src/plugins/sqldrivers/odbc/qsql_odbc.cpp b/src/plugins/sqldrivers/odbc/qsql_odbc.cpp
index 7709b13cd1..e1ede4aec1 100644
--- a/src/plugins/sqldrivers/odbc/qsql_odbc.cpp
+++ b/src/plugins/sqldrivers/odbc/qsql_odbc.cpp
@@ -2649,3 +2649,5 @@ bool QODBCDriver::isIdentifierEscaped(const QString &identifier, IdentifierType)
}
QT_END_NAMESPACE
+
+#include "moc_qsql_odbc_p.cpp"
diff --git a/src/plugins/sqldrivers/psql/.prev_CMakeLists.txt b/src/plugins/sqldrivers/psql/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..4047c6b1f6
--- /dev/null
+++ b/src/plugins/sqldrivers/psql/.prev_CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from psql.pro.
+
+#####################################################################
+## qsqlpsql Plugin:
+#####################################################################
+
+qt_add_plugin(qsqlpsql
+ TYPE sqldrivers
+ CLASS_NAME QPSQLDriverPlugin
+ SOURCES
+ main.cpp
+ qsql_psql.cpp qsql_psql_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ PostgreSQL::PostgreSQL
+ Qt::Core
+ Qt::Sql
+)
+
+#### Keys ignored in scope 1:.:.:psql.pro:<TRUE>:
+# OTHER_FILES = "psql.json"
diff --git a/src/plugins/sqldrivers/psql/CMakeLists.txt b/src/plugins/sqldrivers/psql/CMakeLists.txt
new file mode 100644
index 0000000000..46ad12677e
--- /dev/null
+++ b/src/plugins/sqldrivers/psql/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from psql.pro.
+
+# FIXME cmake FindPostgreSQL is more exhaustive than the check we have for libpq-fe.h
+# it also checks for catalog/pg_type.h which is a more internal include, we should
+# add a way to tell cmake FindPostgreSQL to optionally only look for the libpq-fe.h one
+qt_find_package(PostgreSQL) # special case
+
+#####################################################################
+## qsqlpsql Plugin:
+#####################################################################
+
+qt_add_plugin(qsqlpsql
+ TYPE sqldrivers
+ CLASS_NAME QPSQLDriverPlugin
+ SOURCES
+ main.cpp
+ qsql_psql.cpp qsql_psql_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ PostgreSQL::PostgreSQL
+ Qt::Core
+ Qt::Sql
+)
+
+#### Keys ignored in scope 1:.:.:psql.pro:<TRUE>:
+# OTHER_FILES = "psql.json"
diff --git a/src/plugins/sqldrivers/sqlite/.prev_CMakeLists.txt b/src/plugins/sqldrivers/sqlite/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..ae08f26cb9
--- /dev/null
+++ b/src/plugins/sqldrivers/sqlite/.prev_CMakeLists.txt
@@ -0,0 +1,95 @@
+# Generated from sqlite.pro.
+
+#####################################################################
+## qsqlite Plugin:
+#####################################################################
+
+qt_add_plugin(qsqlite
+ TYPE sqldrivers
+ CLASS_NAME QSQLiteDriverPlugin
+ SOURCES
+ qsql_sqlite.cpp qsql_sqlite_p.h
+ smain.cpp
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Sql
+)
+
+#### Keys ignored in scope 1:.:.:sqlite.pro:<TRUE>:
+# OTHER_FILES = "sqlite.json"
+# QT_FOR_CONFIG = "sqldrivers-private"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qsqlite CONDITION QT_FEATURE_system_sqlite
+ PUBLIC_LIBRARIES
+ sqlite
+)
+
+qt_extend_target(qsqlite CONDITION NOT QT_FEATURE_system_sqlite
+ SOURCES
+ ../../../3rdparty/sqlite/sqlite3.c
+ DEFINES
+ SQLITE_ENABLE_COLUMN_METADATA
+ SQLITE_ENABLE_FTS3
+ SQLITE_ENABLE_FTS3_PARENTHESIS
+ SQLITE_ENABLE_FTS5
+ SQLITE_ENABLE_JSON1
+ SQLITE_ENABLE_RTREE
+ SQLITE_OMIT_COMPLETE
+ INCLUDE_DIRECTORIES
+ ../../../3rdparty/sqlite
+)
+
+qt_extend_target(qsqlite CONDITION CMAKE_BUILD_TYPE STREQUAL Release AND NOT QT_FEATURE_system_sqlite
+ DEFINES
+ NDEBUG
+)
+
+qt_extend_target(qsqlite CONDITION NOT CONFIG___contains___largefile AND NOT QT_FEATURE_system_sqlite
+ DEFINES
+ SQLITE_DISABLE_LFS
+)
+
+qt_extend_target(qsqlite CONDITION QT_FEATURE_posix_fallocate AND NOT QT_FEATURE_system_sqlite
+ DEFINES
+ HAVE_POSIX_FALLOCATE=1
+)
+
+qt_extend_target(qsqlite CONDITION WINRT AND NOT QT_FEATURE_system_sqlite
+ DEFINES
+ SQLITE_OS_WINRT
+)
+
+#### Keys ignored in scope 8:.:../../../3rdparty:../../../3rdparty/sqlite.pri:WINRT:
+# QMAKE_CFLAGS = "-Gy"
+
+qt_extend_target(qsqlite CONDITION QNX AND NOT QT_FEATURE_system_sqlite
+ DEFINES
+ _QNX_SOURCE
+)
+
+qt_extend_target(qsqlite CONDITION UNIX AND NOT QT_FEATURE_system_sqlite AND NOT WINRT AND NOT winphone
+ DEFINES
+ HAVE_USLEEP=1
+)
+
+qt_extend_target(qsqlite CONDITION QT_FEATURE_dlopen AND NOT QT_FEATURE_system_sqlite
+ PUBLIC_LIBRARIES
+ ${CMAKE_DL_LIBS}
+)
+
+qt_extend_target(qsqlite CONDITION NOT QT_FEATURE_dlopen AND NOT QT_FEATURE_system_sqlite
+ DEFINES
+ SQLITE_OMIT_LOAD_EXTENSION
+)
+
+#### Keys ignored in scope 13:.:../../../3rdparty:../../../3rdparty/sqlite.pri:INTEGRITY:
+# QMAKE_CFLAGS = "-include" "qplatformdefs.h"
diff --git a/src/plugins/sqldrivers/sqlite/CMakeLists.txt b/src/plugins/sqldrivers/sqlite/CMakeLists.txt
new file mode 100644
index 0000000000..35fe8e69de
--- /dev/null
+++ b/src/plugins/sqldrivers/sqlite/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from sqlite.pro.
+
+#####################################################################
+## qsqlite Plugin:
+#####################################################################
+
+qt_add_plugin(qsqlite
+ TYPE sqldrivers
+ CLASS_NAME QSQLiteDriverPlugin
+ SOURCES
+ qsql_sqlite.cpp qsql_sqlite_p.h
+ smain.cpp
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ SQLite::SQLite3 # special case
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Sql
+)
+
+#### Keys ignored in scope 1:.:.:sqlite.pro:<TRUE>:
+# OTHER_FILES = "sqlite.json"
+# QT_FOR_CONFIG = "sqldrivers-private"
+
+## Scopes:
+#####################################################################
+
+# special case begin
+# Remove non-system-sqlite code
+# qt_extend_target(qsqlite CONDITION QT_FEATURE_system_sqlite
+# special case end
diff --git a/src/plugins/styles/.prev_CMakeLists.txt b/src/plugins/styles/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..73329915f6
--- /dev/null
+++ b/src/plugins/styles/.prev_CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from styles.pro.
+
+if(QT_FEATURE_style_android)
+ add_subdirectory(android)
+endif()
+if(QT_FEATURE_style_mac)
+ add_subdirectory(mac)
+endif()
+if(QT_FEATURE_style_windowsvista)
+ add_subdirectory(windowsvista)
+endif()
diff --git a/src/plugins/styles/CMakeLists.txt b/src/plugins/styles/CMakeLists.txt
new file mode 100644
index 0000000000..d24e3daff8
--- /dev/null
+++ b/src/plugins/styles/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from styles.pro.
+
+if(QT_FEATURE_style_android)
+ # add_subdirectory(android) # special case TODO
+endif()
+if(QT_FEATURE_style_mac)
+ add_subdirectory(mac)
+endif()
+if(QT_FEATURE_style_windowsvista)
+ add_subdirectory(windowsvista)
+endif()
diff --git a/src/plugins/styles/mac/CMakeLists.txt b/src/plugins/styles/mac/CMakeLists.txt
new file mode 100644
index 0000000000..89b9594ebe
--- /dev/null
+++ b/src/plugins/styles/mac/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from mac.pro.
+
+#####################################################################
+## qmacstyle Plugin:
+#####################################################################
+
+qt_add_plugin(qmacstyle
+ TYPE styles
+ CLASS_NAME QMacStylePlugin
+ SOURCES
+ main.mm
+ qmacstyle_mac.mm qmacstyle_mac_p.h
+ qmacstyle_mac_p_p.h
+ LIBRARIES
+ ${FWAppKit}
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:mac.pro:<TRUE>:
+# DISTFILES = "macstyle.json"
diff --git a/src/plugins/styles/windowsvista/CMakeLists.txt b/src/plugins/styles/windowsvista/CMakeLists.txt
new file mode 100644
index 0000000000..bbb9210f10
--- /dev/null
+++ b/src/plugins/styles/windowsvista/CMakeLists.txt
@@ -0,0 +1,39 @@
+# Generated from windowsvista.pro.
+
+#####################################################################
+## qwindowsvistastyle Plugin:
+#####################################################################
+
+qt_add_plugin(qwindowsvistastyle
+ TYPE styles
+ CLASS_NAME QWindowsVistaStylePlugin
+ SOURCES
+ main.cpp
+ qwindowsvistastyle.cpp qwindowsvistastyle_p.h
+ qwindowsvistastyle_p_p.h
+ qwindowsxpstyle.cpp qwindowsxpstyle_p.h
+ qwindowsxpstyle_p_p.h
+ INCLUDE_DIRECTORIES
+ ../3rdparty/wintab
+ LIBRARIES
+ Qt::WidgetsPrivate
+ gdi32
+ user32
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:windowsvista.pro:<TRUE>:
+# DISTFILES = "windowsvistastyle.json"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qwindowsvistastyle CONDITION NOT WINRT
+ LIBRARIES
+ dwmapi
+ shell32
+ uxtheme
+)
diff --git a/src/printsupport/CMakeLists.txt b/src/printsupport/CMakeLists.txt
new file mode 100644
index 0000000000..b2d653125f
--- /dev/null
+++ b/src/printsupport/CMakeLists.txt
@@ -0,0 +1,176 @@
+# Generated from printsupport.pro.
+
+#####################################################################
+## PrintSupport Module:
+#####################################################################
+
+qt_add_module(PrintSupport
+ PLUGIN_TYPES printsupport
+ SOURCES
+ kernel/qpaintengine_alpha.cpp kernel/qpaintengine_alpha_p.h
+ kernel/qplatformprintdevice.cpp kernel/qplatformprintdevice.h
+ kernel/qplatformprintersupport.cpp kernel/qplatformprintersupport.h
+ kernel/qplatformprintplugin.cpp kernel/qplatformprintplugin.h
+ kernel/qprint_p.h
+ kernel/qprintdevice.cpp kernel/qprintdevice_p.h
+ kernel/qprintengine.h
+ kernel/qprintengine_pdf.cpp
+ kernel/qprinter.cpp kernel/qprinter.h kernel/qprinter_p.h
+ kernel/qprinterinfo.cpp kernel/qprinterinfo.h kernel/qprinterinfo_p.h
+ kernel/qtprintsupportglobal.h kernel/qtprintsupportglobal_p.h
+ DEFINES
+ QT_NO_FOREACH
+ QT_NO_USING_NAMESPACE
+ INCLUDE_DIRECTORIES
+ dialogs
+ widgets
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:printsupport.pro:<TRUE>:
+# QMAKE_LIBS = "$$QMAKE_LIBS_PRINTSUPPORT"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(PrintSupport CONDITION QT_FEATURE_printpreviewwidget
+ SOURCES
+ kernel/qpaintengine_preview.cpp kernel/qpaintengine_preview_p.h
+ widgets/qprintpreviewwidget.cpp widgets/qprintpreviewwidget.h
+)
+
+qt_extend_target(PrintSupport CONDITION WIN32
+ SOURCES
+ kernel/qprintengine_win.cpp kernel/qprintengine_win_p.h
+)
+
+qt_extend_target(PrintSupport CONDITION WIN32 AND NOT WINRT
+ LIBRARIES
+ comdlg32
+ gdi32
+ user32
+ winspool
+)
+
+qt_extend_target(PrintSupport CONDITION QT_FEATURE_cups AND UNIX AND NOT APPLE
+ SOURCES
+ kernel/qcups.cpp kernel/qcups_p.h
+)
+
+qt_extend_target(PrintSupport CONDITION QT_FEATURE_cupsjobwidget AND UNIX AND NOT APPLE
+ SOURCES
+ widgets/qcupsjobwidget.cpp widgets/qcupsjobwidget.ui widgets/qcupsjobwidget_p.h
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+qt_extend_target(PrintSupport CONDITION QT_FEATURE_printdialog
+ SOURCES
+ dialogs/qabstractprintdialog.cpp dialogs/qabstractprintdialog.h dialogs/qabstractprintdialog_p.h
+ dialogs/qpagesetupdialog.cpp dialogs/qpagesetupdialog.h dialogs/qpagesetupdialog_p.h
+ dialogs/qpagesetupwidget.ui
+ dialogs/qprintdialog.h
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+if(QT_FEATURE_printdialog)
+ # Resources:
+ set(qprintdialog_resource_files
+ "images/fit-page-24.png"
+ "images/fit-page-32.png"
+ "images/fit-width-24.png"
+ "images/fit-width-32.png"
+ "images/go-first-24.png"
+ "images/go-first-32.png"
+ "images/go-last-24.png"
+ "images/go-last-32.png"
+ "images/go-next-24.png"
+ "images/go-next-32.png"
+ "images/go-previous-24.png"
+ "images/go-previous-32.png"
+ "images/layout-landscape-24.png"
+ "images/layout-landscape-32.png"
+ "images/layout-portrait-24.png"
+ "images/layout-portrait-32.png"
+ "images/page-setup-24.png"
+ "images/page-setup-32.png"
+ "images/print-24.png"
+ "images/print-32.png"
+ "images/view-page-multi-24.png"
+ "images/view-page-multi-32.png"
+ "images/view-page-one-24.png"
+ "images/view-page-one-32.png"
+ "images/view-page-sided-24.png"
+ "images/view-page-sided-32.png"
+ "images/zoom-in-24.png"
+ "images/zoom-in-32.png"
+ "images/zoom-out-24.png"
+ "images/zoom-out-32.png"
+ )
+
+ qt_add_resource(PrintSupport "qprintdialog"
+ PREFIX
+ "/qt-project.org/dialogs/qprintpreviewdialog"
+ BASE
+ "dialogs"
+ FILES
+ ${qprintdialog_resource_files}
+ )
+ set(qprintdialog1_resource_files
+ "images/status-color.png"
+ "images/status-gray-scale.png"
+ )
+
+ qt_add_resource(PrintSupport "qprintdialog1"
+ PREFIX
+ "/qt-project.org/dialogs/qprintdialog"
+ BASE
+ "dialogs"
+ FILES
+ ${qprintdialog1_resource_files}
+ )
+endif()
+
+qt_extend_target(PrintSupport CONDITION APPLE_OSX AND QT_FEATURE_printdialog
+ SOURCES
+ dialogs/qpagesetupdialog_mac.mm
+ dialogs/qprintdialog_mac.mm
+ LIBRARIES
+ ${FWAppKit}
+)
+
+qt_extend_target(PrintSupport CONDITION QT_FEATURE_printdialog AND WIN32
+ SOURCES
+ dialogs/qpagesetupdialog_win.cpp
+ dialogs/qprintdialog_win.cpp
+)
+
+qt_extend_target(PrintSupport CONDITION QT_FEATURE_printdialog AND UNIX AND NOT APPLE
+ SOURCES
+ dialogs/qpagesetupdialog_unix.cpp dialogs/qpagesetupdialog_unix_p.h
+ dialogs/qprintdialog_unix.cpp
+ dialogs/qprintpropertieswidget.ui
+ dialogs/qprintsettingsoutput.ui
+ dialogs/qprintwidget.ui
+ INCLUDE_DIRECTORIES
+ ${QT_SOURCE_TREE}/src/plugins/printsupport/cups
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+qt_extend_target(PrintSupport CONDITION QT_FEATURE_printpreviewdialog
+ SOURCES
+ dialogs/qprintpreviewdialog.cpp dialogs/qprintpreviewdialog.h
+)
+qt_add_docs(PrintSupport
+ doc/qtprintsupport.qdocconf
+)
+
diff --git a/src/printsupport/configure.cmake b/src/printsupport/configure.cmake
new file mode 100644
index 0000000000..c9b5f74750
--- /dev/null
+++ b/src/printsupport/configure.cmake
@@ -0,0 +1,58 @@
+
+
+#### Inputs
+
+
+
+#### Libraries
+
+qt_find_package(Cups PROVIDED_TARGETS Cups::Cups)
+
+
+#### Tests
+
+
+
+#### Features
+
+qt_feature("cups" PUBLIC PRIVATE
+ SECTION "Painting"
+ LABEL "CUPS"
+ PURPOSE "Provides support for the Common Unix Printing System."
+ CONDITION Cups_FOUND AND QT_FEATURE_printer AND QT_FEATURE_datestring
+)
+qt_feature_definition("cups" "QT_NO_CUPS" NEGATE VALUE "1")
+qt_feature("cupsjobwidget" PUBLIC PRIVATE
+ SECTION "Widgets"
+ LABEL "CUPS job control widget"
+ CONDITION ( QT_FEATURE_buttongroup ) AND ( QT_FEATURE_calendarwidget ) AND ( QT_FEATURE_checkbox ) AND ( QT_FEATURE_combobox ) AND ( QT_FEATURE_cups ) AND ( QT_FEATURE_datetimeedit ) AND ( QT_FEATURE_groupbox ) AND ( QT_FEATURE_tablewidget )
+)
+qt_feature_definition("cupsjobwidget" "QT_NO_CUPSJOBWIDGET" NEGATE VALUE "1")
+qt_feature("printer" PUBLIC
+ SECTION "Painting"
+ LABEL "QPrinter"
+ PURPOSE "Provides a printer backend of QPainter."
+ CONDITION NOT APPLE_UIKIT AND NOT WINRT AND QT_FEATURE_picture AND QT_FEATURE_temporaryfile AND QT_FEATURE_pdf
+)
+qt_feature_definition("printer" "QT_NO_PRINTER" NEGATE VALUE "1")
+qt_feature("printpreviewwidget" PUBLIC
+ SECTION "Widgets"
+ LABEL "QPrintPreviewWidget"
+ PURPOSE "Provides a widget for previewing page layouts for printer output."
+ CONDITION QT_FEATURE_graphicsview AND QT_FEATURE_printer AND QT_FEATURE_mainwindow
+)
+qt_feature_definition("printpreviewwidget" "QT_NO_PRINTPREVIEWWIDGET" NEGATE VALUE "1")
+qt_feature("printdialog" PUBLIC
+ SECTION "Dialogs"
+ LABEL "QPrintDialog"
+ PURPOSE "Provides a dialog widget for specifying printer configuration."
+ CONDITION ( QT_FEATURE_buttongroup ) AND ( QT_FEATURE_checkbox ) AND ( QT_FEATURE_combobox ) AND ( QT_FEATURE_dialog ) AND ( QT_FEATURE_datetimeedit ) AND ( QT_FEATURE_dialogbuttonbox ) AND ( QT_FEATURE_printer ) AND ( QT_FEATURE_radiobutton ) AND ( QT_FEATURE_spinbox ) AND ( QT_FEATURE_tabwidget ) AND ( QT_FEATURE_treeview )
+)
+qt_feature_definition("printdialog" "QT_NO_PRINTDIALOG" NEGATE VALUE "1")
+qt_feature("printpreviewdialog" PUBLIC
+ SECTION "Dialogs"
+ LABEL "QPrintPreviewDialog"
+ PURPOSE "Provides a dialog for previewing and configuring page layouts for printer output."
+ CONDITION QT_FEATURE_printpreviewwidget AND QT_FEATURE_printdialog AND QT_FEATURE_toolbar AND QT_FEATURE_formlayout
+)
+qt_feature_definition("printpreviewdialog" "QT_NO_PRINTPREVIEWDIALOG" NEGATE VALUE "1")
diff --git a/src/sql/CMakeLists.txt b/src/sql/CMakeLists.txt
new file mode 100644
index 0000000000..49a1df0fdb
--- /dev/null
+++ b/src/sql/CMakeLists.txt
@@ -0,0 +1,55 @@
+# Generated from sql.pro.
+
+#####################################################################
+## Sql Module:
+#####################################################################
+
+qt_add_module(Sql
+ PLUGIN_TYPES sqldrivers
+ SOURCES
+ kernel/qsqlcachedresult.cpp kernel/qsqlcachedresult_p.h
+ kernel/qsqldatabase.cpp kernel/qsqldatabase.h
+ kernel/qsqldriver.cpp kernel/qsqldriver.h kernel/qsqldriver_p.h
+ kernel/qsqldriverplugin.cpp kernel/qsqldriverplugin.h
+ kernel/qsqlerror.cpp kernel/qsqlerror.h
+ kernel/qsqlfield.cpp kernel/qsqlfield.h
+ kernel/qsqlindex.cpp kernel/qsqlindex.h
+ kernel/qsqlnulldriver_p.h
+ kernel/qsqlquery.cpp kernel/qsqlquery.h
+ kernel/qsqlrecord.cpp kernel/qsqlrecord.h
+ kernel/qsqlresult.cpp kernel/qsqlresult.h kernel/qsqlresult_p.h
+ kernel/qtsqlglobal.h kernel/qtsqlglobal_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ QT_NO_USING_NAMESPACE
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ PRECOMPILED_HEADER
+ "../corelib/global/qt_pch.h"
+)
+
+#### Keys ignored in scope 1:.:.:sql.pro:<TRUE>:
+# SQL_P = "sql"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(Sql CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x62000000"
+)
+
+qt_extend_target(Sql CONDITION QT_FEATURE_sqlmodel
+ SOURCES
+ models/qsqlquerymodel.cpp models/qsqlquerymodel.h models/qsqlquerymodel_p.h
+ models/qsqlrelationaldelegate.cpp models/qsqlrelationaldelegate.h
+ models/qsqlrelationaltablemodel.cpp models/qsqlrelationaltablemodel.h
+ models/qsqltablemodel.cpp models/qsqltablemodel.h models/qsqltablemodel_p.h
+)
+qt_add_docs(Sql
+ doc/qtsql.qdocconf
+)
+
diff --git a/src/sql/configure.cmake b/src/sql/configure.cmake
new file mode 100644
index 0000000000..545b542d6b
--- /dev/null
+++ b/src/sql/configure.cmake
@@ -0,0 +1,21 @@
+
+
+#### Inputs
+
+
+
+#### Libraries
+
+
+
+#### Tests
+
+
+
+#### Features
+
+qt_feature("sqlmodel" PUBLIC
+ LABEL "SQL item models"
+ PURPOSE "Provides item model classes backed by SQL databases."
+ CONDITION QT_FEATURE_itemmodel
+)
diff --git a/src/testlib/.prev_CMakeLists.txt b/src/testlib/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..5859ae18fa
--- /dev/null
+++ b/src/testlib/.prev_CMakeLists.txt
@@ -0,0 +1,143 @@
+# Generated from testlib.pro.
+
+#####################################################################
+## Test Module:
+#####################################################################
+
+qt_add_module(Test
+ QMAKE_MODULE_CONFIG console testlib_defines
+ EXCEPTIONS
+ SOURCES
+ qabstracttestlogger.cpp qabstracttestlogger_p.h
+ qasciikey.cpp
+ qbenchmark.cpp qbenchmark.h qbenchmark_p.h
+ qbenchmarkevent.cpp qbenchmarkevent_p.h
+ qbenchmarkmeasurement.cpp qbenchmarkmeasurement_p.h
+ qbenchmarkmetric.cpp qbenchmarkmetric.h qbenchmarkmetric_p.h
+ qbenchmarkperfevents.cpp qbenchmarkperfevents_p.h
+ qbenchmarktimemeasurers_p.h
+ qcsvbenchmarklogger.cpp qcsvbenchmarklogger_p.h
+ qplaintestlogger.cpp qplaintestlogger_p.h
+ qsignaldumper.cpp qsignaldumper_p.h
+ qsignalspy.h
+ qtaptestlogger.cpp qtaptestlogger_p.h
+ qteamcitylogger.cpp qteamcitylogger_p.h
+ qtest.h
+ qtest_gui.h
+ qtest_network.h
+ qtest_widgets.h
+ qtestaccessible.h
+ qtestassert.h
+ qtestblacklist.cpp qtestblacklist_p.h
+ qtestcase.cpp qtestcase.h
+ qtestcoreelement_p.h
+ qtestcorelist_p.h
+ qtestdata.cpp qtestdata.h
+ qtestelement.cpp qtestelement_p.h
+ qtestelementattribute.cpp qtestelementattribute_p.h
+ qtestevent.h
+ qtesteventloop.h
+ qtesthelpers_p.h
+ qtestkeyboard.h
+ qtestlog.cpp qtestlog_p.h
+ qtestmouse.cpp qtestmouse.h
+ qtestresult.cpp qtestresult_p.h
+ qtestspontaneevent.h
+ qtestsystem.h
+ qtesttable.cpp qtesttable_p.h
+ qtesttouch.h
+ qtestxunitstreamer.cpp qtestxunitstreamer_p.h
+ qttestglobal.h
+ qxmltestlogger.cpp qxmltestlogger_p.h
+ qxunittestlogger.cpp qxunittestlogger_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ QT_NO_DATASTREAM
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ COMPILE_OPTIONS
+ --cs-exclude-file-abs-wildcard=${QT_SOURCE_TREE}/*
+ --cs-include-file-abs-wildcard=*/src/testlib/*
+ --cs-mcc
+ --cs-mcdc
+ LINK_OPTIONS
+ "$$COVERAGE_OPTIONS"
+)
+
+#### Keys ignored in scope 1:.:.:testlib.pro:<TRUE>:
+# MODULE_CONFIG = "console" "testlib_defines"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:testlib.pro:UNIX AND NOT embedded:
+# QMAKE_PKGCONFIG_DESCRIPTION = "Qt" "Unit" "Testing" "Library"
+
+qt_extend_target(Test CONDITION QT_FEATURE_itemmodeltester
+ SOURCES
+ qabstractitemmodeltester.cpp qabstractitemmodeltester.h
+)
+
+qt_extend_target(Test CONDITION QT_FEATURE_valgrind
+ SOURCES
+ qbenchmarkvalgrind.cpp qbenchmarkvalgrind_p.h
+)
+
+qt_extend_target(Test CONDITION embedded
+ COMPILE_OPTIONS
+ -fno-rtti
+)
+
+qt_extend_target(Test CONDITION APPLE
+ SOURCES
+ qappletestlogger.cpp qappletestlogger_p.h
+ PUBLIC_LIBRARIES
+ ${FWSecurity}
+)
+
+qt_extend_target(Test CONDITION APPLE_OSX
+ SOURCES
+ qtestutil_macos.mm qtestutil_macos_p.h
+ PUBLIC_LIBRARIES
+ ${FWApplicationServices}
+ ${FWFoundation}
+ ${FWIOKit}
+)
+
+qt_extend_target(Test CONDITION (APPLE) AND (OFF AND NOT lessThan(QMAKE_XCODE_VERSION, "6.0"))
+ SOURCES
+ qxctestlogger.mm qxctestlogger_p.h
+ DEFINES
+ HAVE_XCTEST
+ PUBLIC_LIBRARIES
+ ${FWFoundation}
+)
+
+qt_extend_target(Test CONDITION ((APPLE) AND (OFF AND NOT lessThan(QMAKE_XCODE_VERSION, "6.0"))) AND (NOT QMAKE_MAC_SDK_PLATFORM_PATH_ISEMPTY)
+ COMPILE_OPTIONS
+ -F/Developer/Library/Frameworks
+ LINK_OPTIONS
+ "-F$${platform_dev_frameworks_path}"
+ "-weak_framework"
+ "XCTest"
+)
+
+#### Keys ignored in scope 9:.:.:testlib.pro:NOT QMAKE_MAC_SDK_PLATFORM_PATH_ISEMPTY:
+# MODULE_CONFIG = "xctest"
+
+#### Keys ignored in scope 10:.:.:testlib.pro:NOT TARGET Qt::Gui:
+# HEADERSCLEAN_EXCLUDE = "qtest_gui.h" "qtestaccessible.h" "qtestkeyboard.h" "qtestmouse.h" "qtesttouch.h"
+
+#### Keys ignored in scope 11:.:.:testlib.pro:NOT TARGET Qt::Widgets:
+# HEADERSCLEAN_EXCLUDE = "qtest_widgets.h"
+
+#### Keys ignored in scope 12:.:.:testlib.pro:NOT TARGET Qt::Network:
+# HEADERSCLEAN_EXCLUDE = "qtest_network.h"
+qt_add_docs(Test
+ doc/qttestlib.qdocconf
+)
+
diff --git a/src/testlib/CMakeLists.txt b/src/testlib/CMakeLists.txt
new file mode 100644
index 0000000000..8d8b09beba
--- /dev/null
+++ b/src/testlib/CMakeLists.txt
@@ -0,0 +1,129 @@
+# Generated from testlib.pro.
+
+#####################################################################
+## Test Module:
+#####################################################################
+
+qt_add_module(Test
+ CONFIG_MODULE_NAME testlib # special case
+ EXCEPTIONS
+ SOURCES
+ qabstracttestlogger.cpp qabstracttestlogger_p.h
+ qasciikey.cpp
+ qbenchmark.cpp qbenchmark.h qbenchmark_p.h
+ qbenchmarkevent.cpp qbenchmarkevent_p.h
+ qbenchmarkmeasurement.cpp qbenchmarkmeasurement_p.h
+ qbenchmarkmetric.cpp qbenchmarkmetric.h qbenchmarkmetric_p.h
+ qbenchmarkperfevents.cpp qbenchmarkperfevents_p.h
+ qbenchmarktimemeasurers_p.h
+ qcsvbenchmarklogger.cpp qcsvbenchmarklogger_p.h
+ qplaintestlogger.cpp qplaintestlogger_p.h
+ qsignaldumper.cpp qsignaldumper_p.h
+ qsignalspy.h
+ qtaptestlogger.cpp qtaptestlogger_p.h
+ qteamcitylogger.cpp qteamcitylogger_p.h
+ qtest.h
+ qtest_gui.h
+ qtest_network.h
+ qtest_widgets.h
+ qtestaccessible.h
+ qtestassert.h
+ qtestblacklist.cpp qtestblacklist_p.h
+ qtestcase.cpp qtestcase.h
+ qtestcoreelement_p.h
+ qtestcorelist_p.h
+ qtestdata.cpp qtestdata.h
+ qtestelement.cpp qtestelement_p.h
+ qtestelementattribute.cpp qtestelementattribute_p.h
+ qtestevent.h
+ qtesteventloop.h
+ qtesthelpers_p.h
+ qtestkeyboard.h
+ qtestlog.cpp qtestlog_p.h
+ qtestmouse.cpp qtestmouse.h
+ qtestresult.cpp qtestresult_p.h
+ qtestspontaneevent.h
+ qtestsystem.h
+ qtesttable.cpp qtesttable_p.h
+ qtesttouch.h
+ qtestxunitstreamer.cpp qtestxunitstreamer_p.h
+ qttestglobal.h
+ qxmltestlogger.cpp qxmltestlogger_p.h
+ qxunittestlogger.cpp qxunittestlogger_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ QT_NO_DATASTREAM
+ QT_NO_FOREACH
+ QT_BUILD_TESTLIB_LIB # special case
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ # special case begin
+ # remove COMPILE_OPTIONS, LINK_OPTIONS, COVERAGE_OPTIONS
+ # figure out how it should be handled.
+ # special case end
+)
+
+#### Keys ignored in scope 1:.:.:testlib.pro:<TRUE>:
+# MODULE_CONFIG = "console" "testlib_defines"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:testlib.pro:UNIX AND NOT embedded:
+# QMAKE_PKGCONFIG_DESCRIPTION = "Qt" "Unit" "Testing" "Library"
+
+qt_extend_target(Test CONDITION QT_FEATURE_itemmodeltester
+ SOURCES
+ qabstractitemmodeltester.cpp qabstractitemmodeltester.h
+)
+
+qt_extend_target(Test CONDITION QT_FEATURE_valgrind
+ SOURCES
+ qbenchmarkvalgrind.cpp qbenchmarkvalgrind_p.h
+)
+
+qt_extend_target(Test CONDITION embedded
+ COMPILE_OPTIONS
+ -fno-rtti
+)
+
+qt_extend_target(Test CONDITION APPLE
+ SOURCES
+ qappletestlogger.cpp qappletestlogger_p.h
+ PUBLIC_LIBRARIES
+ ${FWSecurity}
+)
+
+qt_extend_target(Test CONDITION APPLE_OSX
+ SOURCES
+ qtestutil_macos.mm qtestutil_macos_p.h
+ PUBLIC_LIBRARIES
+ ${FWApplicationServices}
+ ${FWFoundation}
+ ${FWIOKit}
+)
+
+# special case begin
+# Do not bother with disabled stuff:
+# extend_target(Test CONDITION (APPLE_OSX) AND (OFF AND NOT lessThan(QMAKE_XCODE_VERSION, "6.0")) ...
+# extend_target(Test CONDITION ((APPLE_OSX) AND (OFF AND NOT lessThan(QMAKE_XCODE_VERSION, "6.0"))) AND (NOT QMAKE_MAC_SDK_PLATFORM_PATH_ISEMPTY) ...
+# special case end
+
+#### Keys ignored in scope 9:.:.:testlib.pro:NOT QMAKE_MAC_SDK_PLATFORM_PATH_ISEMPTY:
+# MODULE_CONFIG = "xctest"
+
+#### Keys ignored in scope 10:.:.:testlib.pro:NOT TARGET Qt::Gui:
+# HEADERSCLEAN_EXCLUDE = "qtest_gui.h" "qtestaccessible.h" "qtestkeyboard.h" "qtestmouse.h" "qtesttouch.h"
+
+#### Keys ignored in scope 11:.:.:testlib.pro:NOT TARGET Qt::Widgets:
+# HEADERSCLEAN_EXCLUDE = "qtest_widgets.h"
+
+#### Keys ignored in scope 12:.:.:testlib.pro:NOT TARGET Qt::Network:
+# HEADERSCLEAN_EXCLUDE = "qtest_network.h"
+qt_add_docs(Test
+ doc/qttestlib.qdocconf
+)
+
diff --git a/src/testlib/Qt5TestConfigExtras.cmake.in b/src/testlib/Qt5TestConfigExtras.cmake.in
deleted file mode 100644
index 2a575958ae..0000000000
--- a/src/testlib/Qt5TestConfigExtras.cmake.in
+++ /dev/null
@@ -1,5 +0,0 @@
-
-set_property(TARGET Qt5::Test
- APPEND PROPERTY
- INTERFACE_COMPILE_DEFINITIONS QT_TESTCASE_BUILDDIR=\\\"\${CMAKE_BINARY_DIR}\\\"
-)
diff --git a/src/testlib/configure.cmake b/src/testlib/configure.cmake
new file mode 100644
index 0000000000..b02487223c
--- /dev/null
+++ b/src/testlib/configure.cmake
@@ -0,0 +1,31 @@
+
+
+#### Inputs
+
+
+
+#### Libraries
+
+
+
+#### Tests
+
+
+
+#### Features
+
+qt_feature("testlib_selfcover" PUBLIC
+ LABEL "Coverage testing of testlib itself"
+ PURPOSE "Gauges how thoroughly testlib's selftest exercises testlib's code"
+ AUTODETECT OFF
+)
+qt_feature("itemmodeltester" PUBLIC
+ LABEL "Tester for item models"
+ PURPOSE "Provides a utility to test item models."
+ CONDITION QT_FEATURE_itemmodel
+)
+qt_feature("valgrind" PUBLIC
+ LABEL "Valgrind"
+ PURPOSE "Profiling support with callgrind."
+ CONDITION ( LINUX OR APPLE ) AND QT_FEATURE_process AND QT_FEATURE_regularexpression
+)
diff --git a/src/testlib/qtestcase.cpp b/src/testlib/qtestcase.cpp
index 7b407c9073..cb8061737d 100644
--- a/src/testlib/qtestcase.cpp
+++ b/src/testlib/qtestcase.cpp
@@ -2185,7 +2185,8 @@ QSharedPointer<QTemporaryDir> QTest::qExtractTestData(const QString &dirName)
/*! \internal
*/
-QString QTest::qFindTestData(const QString& base, const char *file, int line, const char *builddir)
+QString QTest::qFindTestData(const QString& base, const char *file, int line, const char *builddir,
+ const char *sourcedir)
{
QString found;
@@ -2295,6 +2296,20 @@ QString QTest::qFindTestData(const QString& base, const char *file, int line, co
}
}
+ // 7. Try the supplied source directory
+ if (found.isEmpty() && sourcedir) {
+ const QString candidate = QFile::decodeName(sourcedir) % QLatin1Char('/') % base;
+ if (QFileInfo::exists(candidate)) {
+ found = candidate;
+ } else if (QTestLog::verboseLevel() >= 2) {
+ QTestLog::info(qPrintable(
+ QString::fromLatin1("testdata %1 not found in supplied source directory [%2]")
+ .arg(base, QDir::toNativeSeparators(candidate))),
+ file, line);
+ }
+ }
+
+
if (found.isEmpty()) {
QTest::qWarn(qPrintable(
QString::fromLatin1("testdata %1 could not be located!").arg(base)),
@@ -2310,9 +2325,10 @@ QString QTest::qFindTestData(const QString& base, const char *file, int line, co
/*! \internal
*/
-QString QTest::qFindTestData(const char *base, const char *file, int line, const char *builddir)
+QString QTest::qFindTestData(const char *base, const char *file, int line, const char *builddir,
+ const char *sourcedir)
{
- return qFindTestData(QFile::decodeName(base), file, line, builddir);
+ return qFindTestData(QFile::decodeName(base), file, line, builddir, sourcedir);
}
/*! \internal
diff --git a/src/testlib/qtestcase.h b/src/testlib/qtestcase.h
index e1518708e8..0498681670 100644
--- a/src/testlib/qtestcase.h
+++ b/src/testlib/qtestcase.h
@@ -213,8 +213,13 @@ do {\
QTest::qWarn(static_cast<const char *>(msg), __FILE__, __LINE__)
#ifdef QT_TESTCASE_BUILDDIR
+
+#ifndef QT_TESTCASE_SOURCEDIR
+#define QT_TESTCASE_SOURCEDIR nullptr
+#endif
+
# define QFINDTESTDATA(basepath)\
- QTest::qFindTestData(basepath, __FILE__, __LINE__, QT_TESTCASE_BUILDDIR)
+ QTest::qFindTestData(basepath, __FILE__, __LINE__, QT_TESTCASE_BUILDDIR, QT_TESTCASE_SOURCEDIR)
#else
# define QFINDTESTDATA(basepath)\
QTest::qFindTestData(basepath, __FILE__, __LINE__)
@@ -309,8 +314,8 @@ namespace QTest
#if QT_CONFIG(temporaryfile)
Q_TESTLIB_EXPORT QSharedPointer<QTemporaryDir> qExtractTestData(const QString &dirName);
#endif
- Q_TESTLIB_EXPORT QString qFindTestData(const char* basepath, const char* file = nullptr, int line = 0, const char* builddir = nullptr);
- Q_TESTLIB_EXPORT QString qFindTestData(const QString& basepath, const char* file = nullptr, int line = 0, const char* builddir = nullptr);
+ Q_TESTLIB_EXPORT QString qFindTestData(const char* basepath, const char* file = nullptr, int line = 0, const char* builddir = nullptr, const char* sourcedir = nullptr);
+ Q_TESTLIB_EXPORT QString qFindTestData(const QString& basepath, const char* file = nullptr, int line = 0, const char* builddir = nullptr, const char *sourcedir = nullptr);
Q_TESTLIB_EXPORT void *qData(const char *tagName, int typeId);
Q_TESTLIB_EXPORT void *qGlobalData(const char *tagName, int typeId);
diff --git a/src/tools/CMakeLists.txt b/src/tools/CMakeLists.txt
new file mode 100644
index 0000000000..425a99b552
--- /dev/null
+++ b/src/tools/CMakeLists.txt
@@ -0,0 +1,13 @@
+add_subdirectory(uic)
+if (QT_FEATURE_dbus)
+ add_subdirectory(qdbuscpp2xml)
+ add_subdirectory(qdbusxml2cpp)
+endif()
+add_subdirectory(qlalr)
+add_subdirectory(qvkgen)
+
+# Only include the following tools when performing a host build
+if(NOT CMAKE_CROSSCOMPILING)
+ add_subdirectory(androiddeployqt)
+ add_subdirectory(androidtestrunner)
+endif()
diff --git a/src/tools/androiddeployqt/.prev_CMakeLists.txt b/src/tools/androiddeployqt/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..e445201b82
--- /dev/null
+++ b/src/tools/androiddeployqt/.prev_CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from androiddeployqt.pro.
+
+#####################################################################
+## androiddeployqt Binary:
+#####################################################################
+
+qt_add_executable(androiddeployqt
+ SOURCES
+ main.cpp
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ QT_NO_FOREACH
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:androiddeployqt.pro:<TRUE>:
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(androiddeployqt CONDITION windows
+ COMPILE_OPTIONS
+ -U__STRICT_ANSI__
+)
diff --git a/src/tools/androiddeployqt/CMakeLists.txt b/src/tools/androiddeployqt/CMakeLists.txt
new file mode 100644
index 0000000000..d47e10efd2
--- /dev/null
+++ b/src/tools/androiddeployqt/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from androiddeployqt.pro.
+
+#####################################################################
+## androiddeployqt Binary:
+#####################################################################
+
+qt_add_executable(androiddeployqt
+ SOURCES
+ main.cpp
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ QT_NO_FOREACH
+ PUBLIC_LIBRARIES
+ Qt::Core # special case
+)
+
+#### Keys ignored in scope 1:.:.:androiddeployqt.pro:<TRUE>:
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(androiddeployqt CONDITION windows
+ COMPILE_OPTIONS
+ -U__STRICT_ANSI__
+)
diff --git a/src/tools/androidtestrunner/CMakeLists.txt b/src/tools/androidtestrunner/CMakeLists.txt
new file mode 100644
index 0000000000..d7ec4a66fa
--- /dev/null
+++ b/src/tools/androidtestrunner/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from androidtestrunner.pro.
+
+#####################################################################
+## androidtestrunner Binary:
+#####################################################################
+
+qt_add_executable(androidtestrunner
+ SOURCES
+ main.cpp
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ QT_NO_FOREACH
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:androidtestrunner.pro:<TRUE>:
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(androidtestrunner CONDITION windows
+ COMPILE_OPTIONS
+ -U__STRICT_ANSI__
+)
diff --git a/src/tools/androidtestrunner/main.cpp b/src/tools/androidtestrunner/main.cpp
index 5471db3afd..f25d2c2de9 100644
--- a/src/tools/androidtestrunner/main.cpp
+++ b/src/tools/androidtestrunner/main.cpp
@@ -51,6 +51,7 @@ struct Options
{
bool helpRequested = false;
bool verbose = false;
+ bool skipAddInstallRoot = false;
std::chrono::seconds timeout{300}; // 5minutes
QString androidDeployQtCommand;
QString buildPath;
@@ -233,6 +234,8 @@ static bool parseOptions()
g_options.helpRequested = true;
else
g_options.activity = arguments.at(++i);
+ } else if (argument.compare(QStringLiteral("--skip-install-root"), Qt::CaseInsensitive) == 0) {
+ g_options.skipAddInstallRoot = true;
} else if (argument.compare(QStringLiteral("--timeout"), Qt::CaseInsensitive) == 0) {
if (i + 1 == arguments.size())
g_options.helpRequested = true;
@@ -283,6 +286,7 @@ static void printHelp()
" If make is missing make sure the --path is set.\n"
" --apk <apk path>: If the apk is specified and if exists, we'll skip\n"
" the package building.\n"
+ " --skip-install-root: Do not append INSTALL_ROOT=... to the make command.\n"
" -- arguments that will be passed to the test application.\n"
" --verbose: Prints out information during processing.\n"
" --help: Displays this information.\n\n",
@@ -452,10 +456,17 @@ int main(int argc, char *argv[])
}
} else {
if (!g_options.makeCommand.isEmpty()) {
- // we need to run make INSTALL_ROOT=path install to install the application file(s) first
- if (!execCommand(QStringLiteral("%1 INSTALL_ROOT=%2 install")
- .arg(g_options.makeCommand, QDir::toNativeSeparators(g_options.buildPath)), nullptr, g_options.verbose)) {
- return 1;
+ if (!g_options.skipAddInstallRoot) {
+ // we need to run make INSTALL_ROOT=path install to install the application file(s) first
+ if (!execCommand(QStringLiteral("%1 INSTALL_ROOT=%2 install")
+ .arg(g_options.makeCommand, QDir::toNativeSeparators(g_options.buildPath)), nullptr, g_options.verbose)) {
+ return 1;
+ }
+ } else {
+ if (!execCommand(QStringLiteral("%1")
+ .arg(g_options.makeCommand), nullptr, g_options.verbose)) {
+ return 1;
+ }
}
}
diff --git a/src/tools/bootstrap/.prev_CMakeLists.txt b/src/tools/bootstrap/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..40d2e85cef
--- /dev/null
+++ b/src/tools/bootstrap/.prev_CMakeLists.txt
@@ -0,0 +1,211 @@
+# Generated from bootstrap.pro.
+
+#####################################################################
+## Bootstrap Module:
+#####################################################################
+
+qt_add_module(Bootstrap
+ STATIC
+ INTERNAL_MODULE
+ NO_SYNC_QT
+ QMAKE_MODULE_CONFIG gc_binaries
+ SOURCES
+ ../../corelib/codecs/qlatincodec.cpp
+ ../../corelib/codecs/qtextcodec.cpp
+ ../../corelib/codecs/qutfcodec.cpp
+ ../../corelib/global/qendian.cpp
+ ../../corelib/global/qglobal.cpp
+ ../../corelib/global/qlogging.cpp
+ ../../corelib/global/qmalloc.cpp
+ ../../corelib/global/qnumeric.cpp
+ ../../corelib/global/qoperatingsystemversion.cpp
+ ../../corelib/global/qrandom.cpp
+ ../../corelib/io/qabstractfileengine.cpp
+ ../../corelib/io/qbuffer.cpp
+ ../../corelib/io/qdebug.cpp
+ ../../corelib/io/qdir.cpp
+ ../../corelib/io/qdiriterator.cpp
+ ../../corelib/io/qfile.cpp
+ ../../corelib/io/qfiledevice.cpp
+ ../../corelib/io/qfileinfo.cpp
+ ../../corelib/io/qfilesystemengine.cpp
+ ../../corelib/io/qfilesystementry.cpp
+ ../../corelib/io/qfsfileengine.cpp
+ ../../corelib/io/qfsfileengine_iterator.cpp
+ ../../corelib/io/qiodevice.cpp
+ ../../corelib/io/qipaddress.cpp
+ ../../corelib/io/qloggingcategory.cpp
+ ../../corelib/io/qloggingregistry.cpp
+ ../../corelib/io/qresource.cpp
+ ../../corelib/io/qsavefile.cpp
+ ../../corelib/io/qstandardpaths.cpp
+ ../../corelib/io/qtemporarydir.cpp
+ ../../corelib/io/qtemporaryfile.cpp
+ ../../corelib/io/qurl.cpp
+ ../../corelib/io/qurlidna.cpp
+ ../../corelib/io/qurlquery.cpp
+ ../../corelib/io/qurlrecode.cpp
+ ../../corelib/kernel/qcoreapplication.cpp
+ ../../corelib/kernel/qcoreglobaldata.cpp
+ ../../corelib/kernel/qmetatype.cpp
+ ../../corelib/kernel/qsharedmemory.cpp
+ ../../corelib/kernel/qsystemerror.cpp
+ ../../corelib/kernel/qsystemsemaphore.cpp
+ ../../corelib/kernel/qvariant.cpp
+ ../../corelib/plugin/quuid.cpp
+ ../../corelib/serialization/qcborvalue.cpp
+ ../../corelib/serialization/qdatastream.cpp
+ ../../corelib/serialization/qjsonarray.cpp
+ ../../corelib/serialization/qjsoncbor.cpp
+ ../../corelib/serialization/qjsondocument.cpp
+ ../../corelib/serialization/qjsonobject.cpp
+ ../../corelib/serialization/qjsonparser.cpp
+ ../../corelib/serialization/qjsonvalue.cpp
+ ../../corelib/serialization/qjsonwriter.cpp
+ ../../corelib/serialization/qtextstream.cpp
+ ../../corelib/serialization/qxmlstream.cpp
+ ../../corelib/serialization/qxmlutils.cpp
+ ../../corelib/text/qbytearray.cpp
+ ../../corelib/text/qbytearraylist.cpp
+ ../../corelib/text/qbytearraymatcher.cpp
+ ../../corelib/text/qlocale.cpp
+ ../../corelib/text/qlocale_tools.cpp
+ ../../corelib/text/qregexp.cpp
+ ../../corelib/text/qstring.cpp
+ ../../corelib/text/qstring_compat.cpp
+ ../../corelib/text/qstringbuilder.cpp
+ ../../corelib/text/qstringlist.cpp
+ ../../corelib/text/qstringview.cpp
+ ../../corelib/text/qvsnprintf.cpp
+ ../../corelib/time/qcalendar.cpp
+ ../../corelib/time/qdatetime.cpp
+ ../../corelib/time/qgregoriancalendar.cpp
+ ../../corelib/time/qromancalendar.cpp
+ ../../corelib/tools/qarraydata.cpp
+ ../../corelib/tools/qbitarray.cpp
+ ../../corelib/tools/qcommandlineoption.cpp
+ ../../corelib/tools/qcommandlineparser.cpp
+ ../../corelib/tools/qcryptographichash.cpp
+ ../../corelib/tools/qhash.cpp
+ ../../corelib/tools/qline.cpp
+ ../../corelib/tools/qmap.cpp
+ ../../corelib/tools/qpoint.cpp
+ ../../corelib/tools/qrect.cpp
+ ../../corelib/tools/qringbuffer.cpp
+ ../../corelib/tools/qsize.cpp
+ ../../corelib/tools/qversionnumber.cpp
+ ../../xml/dom/qdom.cpp
+ ../../xml/sax/qxml.cpp
+ DEFINES
+ QT_BOOTSTRAPPED
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ QT_NO_FOREACH
+ QT_VERSION_MAJOR=
+ QT_VERSION_MINOR=
+ QT_VERSION_PATCH=
+ QT_VERSION_STR=\"\"
+)
+
+#### Keys ignored in scope 1:.:.:bootstrap.pro:<TRUE>:
+# INSTALLS = "lib"
+# MODULE_CONFIG = "gc_binaries"
+# MODULE_INCNAME = "QtCore" "QtXml"
+# _OPTION = "host_build"
+# lib.CONFIG = "dummy_install"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(Bootstrap CONDITION UNIX
+ SOURCES
+ ../../corelib/io/qfilesystemengine_unix.cpp
+ ../../corelib/io/qfilesystemiterator_unix.cpp
+ ../../corelib/io/qfsfileengine_unix.cpp
+ ../../corelib/kernel/qcore_unix.cpp
+ ../../corelib/kernel/qsharedmemory_posix.cpp
+ ../../corelib/kernel/qsharedmemory_systemv.cpp
+ ../../corelib/kernel/qsharedmemory_unix.cpp
+ ../../corelib/kernel/qsystemsemaphore_posix.cpp
+ ../../corelib/kernel/qsystemsemaphore_systemv.cpp
+ ../../corelib/kernel/qsystemsemaphore_unix.cpp
+)
+
+qt_extend_target(Bootstrap CONDITION WIN32
+ SOURCES
+ ../../corelib/global/qoperatingsystemversion_win.cpp
+ ../../corelib/io/qfilesystemengine_win.cpp
+ ../../corelib/io/qfilesystemiterator_win.cpp
+ ../../corelib/io/qfsfileengine_win.cpp
+ ../../corelib/io/qstandardpaths_win.cpp
+ ../../corelib/kernel/qcoreapplication_win.cpp
+ ../../corelib/kernel/qsharedmemory_win.cpp
+ ../../corelib/kernel/qsystemsemaphore_win.cpp
+ ../../corelib/kernel/qwinregistry.cpp
+ ../../corelib/plugin/qsystemlibrary.cpp
+ PUBLIC_LIBRARIES
+ advapi32
+ netapi32
+ ole32
+ shell32
+ user32
+)
+
+qt_extend_target(Bootstrap CONDITION APPLE
+ SOURCES
+ ../../corelib/global/qoperatingsystemversion_darwin.mm
+ ../../corelib/kernel/qcore_foundation.mm
+ ../../corelib/kernel/qcore_mac.cpp
+ ../../corelib/kernel/qcore_mac_objc.mm
+ ../../corelib/kernel/qcoreapplication_mac.cpp
+ PUBLIC_LIBRARIES
+ ${FWFoundation}
+)
+
+qt_extend_target(Bootstrap CONDITION APPLE_OSX
+ SOURCES
+ ../../corelib/io/qstandardpaths_mac.mm
+ LIBRARIES
+ ${FWCoreServices}
+)
+
+qt_extend_target(Bootstrap CONDITION APPLE_UIKIT
+ LIBRARIES
+ ${FWUIKit}
+)
+
+qt_extend_target(Bootstrap CONDITION UNIX AND NOT APPLE_OSX
+ SOURCES
+ ../../corelib/io/qstandardpaths_unix.cpp
+)
+
+qt_extend_target(Bootstrap CONDITION CMAKE_CROSSCOMPILING
+ SOURCES
+ ../../3rdparty/zlib/src/adler32.c
+ ../../3rdparty/zlib/src/compress.c
+ ../../3rdparty/zlib/src/crc32.c
+ ../../3rdparty/zlib/src/deflate.c
+ ../../3rdparty/zlib/src/gzclose.c
+ ../../3rdparty/zlib/src/gzlib.c
+ ../../3rdparty/zlib/src/gzread.c
+ ../../3rdparty/zlib/src/gzwrite.c
+ ../../3rdparty/zlib/src/infback.c
+ ../../3rdparty/zlib/src/inffast.c
+ ../../3rdparty/zlib/src/inflate.c
+ ../../3rdparty/zlib/src/inftrees.c
+ ../../3rdparty/zlib/src/trees.c
+ ../../3rdparty/zlib/src/uncompr.c
+ ../../3rdparty/zlib/src/zutil.c
+ INCLUDE_DIRECTORIES
+ ../../3rdparty/zlib/src
+)
+
+qt_extend_target(Bootstrap CONDITION NOT CMAKE_CROSSCOMPILING
+ LIBRARIES
+ ZLIB::ZLIB
+)
+
+qt_extend_target(Bootstrap CONDITION WIN32 AND mingw
+ PUBLIC_LIBRARIES
+ uuid
+)
diff --git a/src/tools/bootstrap/CMakeLists.txt b/src/tools/bootstrap/CMakeLists.txt
new file mode 100644
index 0000000000..7762ef4ae4
--- /dev/null
+++ b/src/tools/bootstrap/CMakeLists.txt
@@ -0,0 +1,224 @@
+# Generated from bootstrap.pro.
+
+#####################################################################
+## Bootstrap Module:
+#####################################################################
+
+# special case:
+add_library(Bootstrap STATIC)
+qt_extend_target(Bootstrap
+ SOURCES
+ ../../corelib/codecs/qlatincodec.cpp
+ ../../corelib/codecs/qtextcodec.cpp
+ ../../corelib/codecs/qutfcodec.cpp
+ ../../corelib/global/qendian.cpp
+ ../../corelib/global/qglobal.cpp
+ ../../corelib/global/qlogging.cpp
+ ../../corelib/global/qmalloc.cpp
+ ../../corelib/global/qnumeric.cpp
+ ../../corelib/global/qoperatingsystemversion.cpp
+ ../../corelib/global/qrandom.cpp
+ ../../corelib/io/qabstractfileengine.cpp
+ ../../corelib/io/qbuffer.cpp
+ ../../corelib/io/qdebug.cpp
+ ../../corelib/io/qdir.cpp
+ ../../corelib/io/qdiriterator.cpp
+ ../../corelib/io/qfile.cpp
+ ../../corelib/io/qfiledevice.cpp
+ ../../corelib/io/qfileinfo.cpp
+ ../../corelib/io/qfilesystemengine.cpp
+ ../../corelib/io/qfilesystementry.cpp
+ ../../corelib/io/qfsfileengine.cpp
+ ../../corelib/io/qfsfileengine_iterator.cpp
+ ../../corelib/io/qiodevice.cpp
+ ../../corelib/io/qipaddress.cpp
+ ../../corelib/io/qloggingcategory.cpp
+ ../../corelib/io/qloggingregistry.cpp
+ ../../corelib/io/qresource.cpp
+ ../../corelib/io/qsavefile.cpp
+ ../../corelib/io/qstandardpaths.cpp
+ ../../corelib/io/qtemporarydir.cpp
+ ../../corelib/io/qtemporaryfile.cpp
+ ../../corelib/io/qurl.cpp
+ ../../corelib/io/qurlidna.cpp
+ ../../corelib/io/qurlquery.cpp
+ ../../corelib/io/qurlrecode.cpp
+ ../../corelib/kernel/qcoreapplication.cpp
+ ../../corelib/kernel/qcoreglobaldata.cpp
+ ../../corelib/kernel/qmetatype.cpp
+ ../../corelib/kernel/qsharedmemory.cpp
+ ../../corelib/kernel/qsystemerror.cpp
+ ../../corelib/kernel/qsystemsemaphore.cpp
+ ../../corelib/kernel/qvariant.cpp
+ ../../corelib/plugin/quuid.cpp
+ ../../corelib/serialization/qcborvalue.cpp
+ ../../corelib/serialization/qdatastream.cpp
+ ../../corelib/serialization/qjsonarray.cpp
+ ../../corelib/serialization/qjsoncbor.cpp
+ ../../corelib/serialization/qjsondocument.cpp
+ ../../corelib/serialization/qjsonobject.cpp
+ ../../corelib/serialization/qjsonparser.cpp
+ ../../corelib/serialization/qjsonvalue.cpp
+ ../../corelib/serialization/qjsonwriter.cpp
+ ../../corelib/serialization/qtextstream.cpp
+ ../../corelib/serialization/qxmlstream.cpp
+ ../../corelib/serialization/qxmlutils.cpp
+ ../../corelib/text/qbytearray.cpp
+ ../../corelib/text/qbytearraylist.cpp
+ ../../corelib/text/qbytearraymatcher.cpp
+ ../../corelib/text/qlocale.cpp
+ ../../corelib/text/qlocale_tools.cpp
+ ../../corelib/text/qregexp.cpp
+ ../../corelib/text/qstring.cpp
+ ../../corelib/text/qstring_compat.cpp
+ ../../corelib/text/qstringbuilder.cpp
+ ../../corelib/text/qstringlist.cpp
+ ../../corelib/text/qstringview.cpp
+ ../../corelib/text/qvsnprintf.cpp
+ ../../corelib/time/qcalendar.cpp
+ ../../corelib/time/qdatetime.cpp
+ ../../corelib/time/qgregoriancalendar.cpp
+ ../../corelib/time/qromancalendar.cpp
+ ../../corelib/tools/qarraydata.cpp
+ ../../corelib/tools/qbitarray.cpp
+ ../../corelib/tools/qcommandlineoption.cpp
+ ../../corelib/tools/qcommandlineparser.cpp
+ ../../corelib/tools/qcryptographichash.cpp
+ ../../corelib/tools/qhash.cpp
+ ../../corelib/tools/qline.cpp
+ ../../corelib/tools/qmap.cpp
+ ../../corelib/tools/qpoint.cpp
+ ../../corelib/tools/qrect.cpp
+ ../../corelib/tools/qringbuffer.cpp
+ ../../corelib/tools/qsize.cpp
+ ../../corelib/tools/qversionnumber.cpp
+ ../../xml/dom/qdom.cpp
+ ../../xml/sax/qxml.cpp
+ PUBLIC_DEFINES # special case
+ QT_VERSION_MAJOR=${PROJECT_VERSION_MAJOR} # special case
+ QT_VERSION_MINOR=${PROJECT_VERSION_MINOR} # special case
+ QT_VERSION_PATCH=${PROJECT_VERSION_PATCH} # special case
+ QT_VERSION_STR="${PROJECT_VERSION}" # special case
+ QT_USE_QSTRINGBUILDER # special case
+ QT_BOOTSTRAPPED
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ QT_NO_FOREACH
+ PUBLIC_INCLUDE_DIRECTORIES # special case
+ $<TARGET_PROPERTY:Core,INCLUDE_DIRECTORIES>
+ $<TARGET_PROPERTY:Xml,INCLUDE_DIRECTORIES>
+ PUBLIC_LIBRARIES # special case
+ ZLIB::ZLIB
+ Qt::Platform
+)
+
+#### Keys ignored in scope 1:.:.:bootstrap.pro:<TRUE>:
+# INSTALLS = "lib"
+# MODULE_CONFIG = "gc_binaries"
+# MODULE_INCNAME = "QtCore" "QtXml"
+# _OPTION = "host_build"
+# lib.CONFIG = "dummy_install"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(Bootstrap CONDITION UNIX
+ SOURCES
+ ../../corelib/io/qfilesystemengine_unix.cpp
+ ../../corelib/io/qfilesystemiterator_unix.cpp
+ ../../corelib/io/qfsfileengine_unix.cpp
+ ../../corelib/kernel/qcore_unix.cpp
+ ../../corelib/kernel/qsharedmemory_posix.cpp
+ ../../corelib/kernel/qsharedmemory_systemv.cpp
+ ../../corelib/kernel/qsharedmemory_unix.cpp
+ ../../corelib/kernel/qsystemsemaphore_posix.cpp
+ ../../corelib/kernel/qsystemsemaphore_systemv.cpp
+ ../../corelib/kernel/qsystemsemaphore_unix.cpp
+)
+
+qt_extend_target(Bootstrap CONDITION WIN32
+ SOURCES
+ ../../corelib/global/qoperatingsystemversion_win.cpp
+ ../../corelib/io/qfilesystemengine_win.cpp
+ ../../corelib/io/qfilesystemiterator_win.cpp
+ ../../corelib/io/qfsfileengine_win.cpp
+ ../../corelib/io/qstandardpaths_win.cpp
+ ../../corelib/kernel/qcoreapplication_win.cpp
+ ../../corelib/kernel/qsharedmemory_win.cpp
+ ../../corelib/kernel/qsystemsemaphore_win.cpp
+ ../../corelib/kernel/qwinregistry.cpp
+ ../../corelib/plugin/qsystemlibrary.cpp
+ PUBLIC_LIBRARIES
+ advapi32
+ netapi32
+ ole32
+ shell32
+ user32
+)
+
+qt_extend_target(Bootstrap CONDITION APPLE
+ SOURCES
+ ../../corelib/global/qoperatingsystemversion_darwin.mm
+ ../../corelib/kernel/qcore_foundation.mm
+ ../../corelib/kernel/qcore_mac.cpp
+ ../../corelib/kernel/qcore_mac_objc.mm
+ ../../corelib/kernel/qcoreapplication_mac.cpp
+ PUBLIC_LIBRARIES
+ ${FWFoundation}
+)
+
+qt_extend_target(Bootstrap CONDITION APPLE_OSX
+ SOURCES
+ ../../corelib/io/qstandardpaths_mac.mm
+ LIBRARIES
+ ${FWCoreServices}
+)
+
+qt_extend_target(Bootstrap CONDITION APPLE_UIKIT
+ LIBRARIES
+ ${FWUIKit}
+)
+
+qt_extend_target(Bootstrap CONDITION UNIX AND NOT APPLE_OSX
+ SOURCES
+ ../../corelib/io/qstandardpaths_unix.cpp
+)
+
+# special case begin
+# These lines need to commented out. This will never get cross_compiled!
+#qt_extend_target(Bootstrap CONDITION CMAKE_CROSSCOMPILING
+# SOURCES
+# ../../3rdparty/zlib/src/adler32.c
+# ../../3rdparty/zlib/src/compress.c
+# ../../3rdparty/zlib/src/crc32.c
+# ../../3rdparty/zlib/src/deflate.c
+# ../../3rdparty/zlib/src/gzclose.c
+# ../../3rdparty/zlib/src/gzlib.c
+# ../../3rdparty/zlib/src/gzread.c
+# ../../3rdparty/zlib/src/gzwrite.c
+# ../../3rdparty/zlib/src/infback.c
+# ../../3rdparty/zlib/src/inffast.c
+# ../../3rdparty/zlib/src/inflate.c
+# ../../3rdparty/zlib/src/inftrees.c
+# ../../3rdparty/zlib/src/trees.c
+# ../../3rdparty/zlib/src/uncompr.c
+# ../../3rdparty/zlib/src/zutil.c
+# INCLUDE_DIRECTORIES
+# ../../3rdparty/zlib/src
+#)
+#
+#qt_extend_target(Bootstrap CONDITION NOT CMAKE_CROSSCOMPILING
+# LIBRARIES
+# ZLIB::ZLIB
+#)
+# special case end
+
+qt_extend_target(Bootstrap CONDITION WIN32 AND mingw
+ PUBLIC_LIBRARIES
+ uuid
+)
+
+# special case:
+qt_internal_add_link_flags_gc_sections(Bootstrap PUBLIC)
+set_target_properties(Bootstrap PROPERTIES AUTOMOC OFF AUTOUIC OFF AUTORCC OFF)
+qt_internal_add_target_aliases(Bootstrap)
diff --git a/src/tools/cmake_automoc_parser/CMakeLists.txt b/src/tools/cmake_automoc_parser/CMakeLists.txt
new file mode 100644
index 0000000000..73303215bb
--- /dev/null
+++ b/src/tools/cmake_automoc_parser/CMakeLists.txt
@@ -0,0 +1,18 @@
+#####################################################################
+## moc Tool:
+#####################################################################
+
+qt_add_tool(cmake_automoc_parser
+ BOOTSTRAP
+ TOOLS_TARGET Core # special case
+ SOURCES
+ main.cpp
+ DEFINES
+ QT_MOC
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_FROM_BYTEARRAY
+ QT_NO_COMPRESS
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+)
diff --git a/src/tools/cmake_automoc_parser/main.cpp b/src/tools/cmake_automoc_parser/main.cpp
new file mode 100644
index 0000000000..456b06b072
--- /dev/null
+++ b/src/tools/cmake_automoc_parser/main.cpp
@@ -0,0 +1,389 @@
+/****************************************************************************
+**
+** Copyright (C) 2019 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
+**
+** This file is part of the tools applications of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:GPL-EXCEPT$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see https://www.qt.io/terms-conditions. For further
+** information use the contact form at https://www.qt.io/contact-us.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3 as published by the Free Software
+** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+** included in the packaging of this file. Please review the following
+** information to ensure the GNU General Public License requirements will
+** be met: https://www.gnu.org/licenses/gpl-3.0.html.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtCore/qglobal.h>
+
+#include <cstdio>
+#include <cstdlib>
+
+#include <qfile.h>
+#include <qjsonarray.h>
+#include <qjsondocument.h>
+#include <qjsonobject.h>
+#include <qdir.h>
+#include <qstring.h>
+#include <qhash.h>
+#include <qvector.h>
+#include <qstack.h>
+#include <qdebug.h>
+#include <qset.h>
+#include <qmap.h>
+#include <qcoreapplication.h>
+#include <qcommandlineoption.h>
+#include <qcommandlineparser.h>
+
+QT_BEGIN_NAMESPACE
+
+using AutoGenHeaderMap = QMap<QString, QString>;
+using AutoGenSourcesList = QVector<QString>;
+
+static bool readAutogenInfoJson(AutoGenHeaderMap &headers, AutoGenSourcesList &sources,
+ QStringList &headerExts, const QString &autoGenInfoJsonPath)
+{
+ QFile file(autoGenInfoJsonPath);
+ if (!file.open(QIODevice::ReadOnly | QIODevice::Text)) {
+ fprintf(stderr, "Could not open: %s\n", qPrintable(autoGenInfoJsonPath));
+ return false;
+ }
+
+ const QByteArray contents = file.readAll();
+ file.close();
+
+ QJsonParseError error;
+ QJsonDocument doc = QJsonDocument::fromJson(contents, &error);
+
+ if (error.error != QJsonParseError::NoError) {
+ fprintf(stderr, "Failed to parse json file: %s\n", qPrintable(autoGenInfoJsonPath));
+ return false;
+ }
+
+ QJsonObject rootObject = doc.object();
+ QJsonValue headersValue = rootObject.value(QLatin1String("HEADERS"));
+ QJsonValue sourcesValue = rootObject.value(QLatin1String("SOURCES"));
+ QJsonValue headerExtValue = rootObject.value(QLatin1String("HEADER_EXTENSIONS"));
+
+ if (!headersValue.isArray() || !sourcesValue.isArray() || !headerExtValue.isArray()) {
+ fprintf(stderr,
+ "%s layout does not match the expected layout. This most likely means that file "
+ "format changed or this file is not a product of CMake's AutoGen process.\n",
+ qPrintable(autoGenInfoJsonPath));
+ return false;
+ }
+
+ QJsonArray headersArray = headersValue.toArray();
+ QJsonArray sourcesArray = sourcesValue.toArray();
+ QJsonArray headerExtArray = headerExtValue.toArray();
+
+ for (const auto &value : headersArray) {
+ QJsonArray entry_array = value.toArray();
+ if (entry_array.size() > 2) {
+ // Array[0] : header path
+ // Array[2] : Location of the generated moc file for this header
+ // if no source file includes it
+ headers.insert(entry_array[0].toString(), entry_array[2].toString());
+ }
+ }
+
+ sources.reserve(sourcesArray.size());
+ for (const auto &value : sourcesArray) {
+ QJsonArray entry_array = value.toArray();
+ if (entry_array.size() > 1) {
+ sources.push_back(entry_array[0].toString());
+ }
+ }
+
+ headerExts.reserve(headerExtArray.size());
+ for (const auto &value : headerExtArray) {
+ headerExts.push_back(value.toString());
+ }
+
+ return true;
+}
+
+struct ParseCacheEntry
+{
+ QStringList mocFiles;
+ QStringList mocIncludes;
+};
+
+using ParseCacheMap = QMap<QString, ParseCacheEntry>;
+
+static bool readParseCache(ParseCacheMap &entries, const QString &parseCacheFilePath)
+{
+
+ QFile file(parseCacheFilePath);
+ if (!file.open(QIODevice::ReadOnly | QIODevice::Text)) {
+ fprintf(stderr, "Could not open: %s\n", qPrintable(parseCacheFilePath));
+ return false;
+ }
+
+ QString source;
+ QStringList mocEntries;
+ QStringList mocIncludes;
+
+ // File format
+ // ....
+ // header/source path N
+ // mmc:Q_OBJECT| mcc:Q_GADGET # This file has been mocked
+ // miu:moc_....cpp # Path of the moc.cpp file generated for the above file
+ // relative to TARGET_BINARY_DIR/TARGET_autgen/include directory. Not
+ // present for headers.
+ // mid: ....moc # Path of .moc file generated for the above file relative
+ // to TARGET_BINARY_DIR/TARGET_autogen/include directory.
+ // uic: UI related info, ignored
+ // mdp: Moc dependencies, ignored
+ // udp: UI dependencies, ignored
+ // header/source path N + 1
+ // ....
+
+ QTextStream textStream(&file);
+ const QString mmcKey = QString(QLatin1String(" mmc:"));
+ const QString miuKey = QString(QLatin1String(" miu:"));
+ const QString uicKey = QString(QLatin1String(" uic:"));
+ const QString midKey = QString(QLatin1String(" mid:"));
+ const QString mdpKey = QString(QLatin1String(" mdp:"));
+ const QString udpKey = QString(QLatin1String(" udp:"));
+ QString line;
+ bool mmc_key_found = false;
+ while (textStream.readLineInto(&line)) {
+ if (!line.startsWith(QLatin1Char(' '))) {
+ if (!mocEntries.isEmpty() || mmc_key_found || !mocIncludes.isEmpty()) {
+ entries.insert(source,
+ ParseCacheEntry { std::move(mocEntries), std::move(mocIncludes) });
+ source.clear();
+ mmc_key_found = false;
+ }
+ source = line;
+ } else if (line.startsWith(mmcKey)) {
+ mmc_key_found = true;
+ } else if (line.startsWith(miuKey)) {
+ mocIncludes.push_back(line.right(line.size() - miuKey.size()));
+ } else if (line.startsWith(midKey)) {
+ mocEntries.push_back(line.right(line.size() - midKey.size()));
+ } else if (line.startsWith(uicKey) || line.startsWith(mdpKey) || line.startsWith(udpKey)) {
+ // nothing to do ignore
+ continue;
+ } else {
+ fprintf(stderr, "Unhandled line entry \"%s\" in %s\n", qPrintable(line),
+ qPrintable(parseCacheFilePath));
+ return false;
+ }
+ }
+
+ // Check if last entry has any data left to processed
+ if (!mocEntries.isEmpty() || !mocIncludes.isEmpty() || mmc_key_found) {
+ entries.insert(source, ParseCacheEntry { std::move(mocEntries), std::move(mocIncludes) });
+ }
+
+ file.close();
+ return true;
+}
+
+static bool readJsonFiles(QVector<QString> &entries, const QString &filePath)
+{
+
+ QFile file(filePath);
+ if (!file.open(QIODevice::ReadOnly | QIODevice::Text)) {
+ fprintf(stderr, "Could not open: %s\n", qPrintable(filePath));
+ return false;
+ }
+
+ QTextStream textStream(&file);
+ QString line;
+ while (textStream.readLineInto(&line)) {
+ entries.push_back(line);
+ }
+ file.close();
+ return true;
+}
+
+static bool writeJsonFiles(const QVector<QString> &fileList, const QString &fileListFilePath)
+{
+ QFile file(fileListFilePath);
+ if (!file.open(QIODevice::WriteOnly | QIODevice::Text)) {
+ fprintf(stderr, "Could not open: %s\n", qPrintable(fileListFilePath));
+ return false;
+ }
+
+ QTextStream textStream(&file);
+ for (const auto &file : fileList) {
+ textStream << file << Qt::endl;
+ }
+
+ file.close();
+ return true;
+}
+
+int main(int argc, char **argv)
+{
+
+ QCoreApplication app(argc, argv);
+ QCommandLineParser parser;
+ parser.setApplicationDescription(QStringLiteral("Qt CMake Autogen parser tool"));
+
+ parser.addHelpOption();
+ parser.setSingleDashWordOptionMode(QCommandLineParser::ParseAsLongOptions);
+
+ QCommandLineOption outputFileOption(QStringLiteral("output-file-path"));
+ outputFileOption.setDescription(
+ QStringLiteral("Output file where the meta type file list will be written."));
+ outputFileOption.setValueName(QStringLiteral("output file"));
+ parser.addOption(outputFileOption);
+
+ QCommandLineOption cmakeAutogenCacheFileOption(QStringLiteral("cmake-autogen-cache-file"));
+ cmakeAutogenCacheFileOption.setDescription(
+ QStringLiteral("Location of the CMake AutoGen ParseCache.txt file."));
+ cmakeAutogenCacheFileOption.setValueName(QStringLiteral("CMake AutoGen ParseCache.txt file"));
+ parser.addOption(cmakeAutogenCacheFileOption);
+
+ QCommandLineOption cmakeAutogenInfoFileOption(QStringLiteral("cmake-autogen-info-file"));
+ cmakeAutogenInfoFileOption.setDescription(
+ QStringLiteral("Location of the CMake AutoGen AutogenInfo.json file."));
+ cmakeAutogenInfoFileOption.setValueName(QStringLiteral("CMake AutoGen AutogenInfo.json file"));
+ parser.addOption(cmakeAutogenInfoFileOption);
+
+ QCommandLineOption cmakeAutogenIncludeDirOption(
+ QStringLiteral("cmake-autogen-include-dir-path"));
+ cmakeAutogenIncludeDirOption.setDescription(
+ QStringLiteral("Location of the CMake AutoGen include directory."));
+ cmakeAutogenIncludeDirOption.setValueName(QStringLiteral("CMake AutoGen include directory"));
+ parser.addOption(cmakeAutogenIncludeDirOption);
+
+ QStringList arguments = QCoreApplication::arguments();
+ parser.process(arguments);
+
+ if (!parser.isSet(outputFileOption) || !parser.isSet(cmakeAutogenInfoFileOption)
+ || !parser.isSet(cmakeAutogenCacheFileOption)
+ || !parser.isSet(cmakeAutogenIncludeDirOption)) {
+ parser.showHelp(1);
+ return EXIT_FAILURE;
+ }
+
+ // Read source files from AutogenInfo.json
+ AutoGenHeaderMap autoGenHeaders;
+ AutoGenSourcesList autoGenSources;
+ QStringList headerExtList;
+ if (!readAutogenInfoJson(autoGenHeaders, autoGenSources, headerExtList,
+ parser.value(cmakeAutogenInfoFileOption))) {
+ return EXIT_FAILURE;
+ }
+
+ ParseCacheMap parseCacheEntries;
+ if (!readParseCache(parseCacheEntries, parser.value(cmakeAutogenCacheFileOption))) {
+ return EXIT_FAILURE;
+ }
+
+ const QString cmakeIncludeDir = parser.value(cmakeAutogenIncludeDirOption);
+
+ // Algorithm description
+ // 1) For each source from the AutoGenSources list check if there is a parse
+ // cache entry.
+ // 1a) If an entry was wound there exists an moc_...cpp file somewhere.
+ // Remove the header file from the AutoGenHeader files
+ // 1b) For every matched source entry, check the moc includes as it is
+ // possible for a source file to include moc files from other headers.
+ // Remove the header from AutoGenHeaders
+ // 2) For every remaining header in AutoGenHeaders, check if there is an
+ // entry for it in the parse cache. Use the value for the location of the
+ // moc.json file
+
+ QVector<QString> jsonFileList;
+ QDir dir(cmakeIncludeDir);
+ jsonFileList.reserve(autoGenSources.size());
+
+ // 1) Process sources
+ for (const auto &source : autoGenSources) {
+ auto it = parseCacheEntries.find(source);
+ if (it == parseCacheEntries.end()) {
+ continue;
+ }
+
+ const QFileInfo fileInfo(source);
+ const QString base = fileInfo.path() + fileInfo.completeBaseName();
+ // 1a) erase header
+ for (const auto &ext : headerExtList) {
+ const QString headerPath = base + QLatin1Char('.') + ext;
+ auto it = autoGenHeaders.find(headerPath);
+ if (it != autoGenHeaders.end()) {
+ autoGenHeaders.erase(it);
+ break;
+ }
+ }
+ // Add extra moc files
+ for (const auto &mocFile : it.value().mocFiles) {
+ jsonFileList.push_back(dir.filePath(mocFile) + QLatin1String(".json"));
+ }
+ // Add main moc files
+ for (const auto &mocFile : it.value().mocIncludes) {
+ jsonFileList.push_back(dir.filePath(mocFile) + QLatin1String(".json"));
+ // 1b) Locate this header and delete it
+ constexpr int mocKeyLen = 4; // length of "moc_"
+ const QString headerBaseName =
+ QFileInfo(mocFile.right(mocFile.size() - mocKeyLen)).completeBaseName();
+ bool breakFree = false;
+ for (auto &ext : headerExtList) {
+ const QString headerSuffix = headerBaseName + QLatin1Char('.') + ext;
+ for (auto it = autoGenHeaders.begin(); it != autoGenHeaders.end(); ++it) {
+ if (it.key().endsWith(headerSuffix)
+ && QFileInfo(it.key()).completeBaseName() == headerBaseName) {
+ autoGenHeaders.erase(it);
+ breakFree = true;
+ break;
+ }
+ }
+ if (breakFree) {
+ break;
+ }
+ }
+ }
+ }
+
+ // 2) Process headers
+ for (auto mapIt = autoGenHeaders.begin(); mapIt != autoGenHeaders.end(); ++mapIt) {
+ auto it = parseCacheEntries.find(mapIt.key());
+ if (it == parseCacheEntries.end()) {
+ continue;
+ }
+ const QString jsonPath =
+ dir.filePath(QLatin1String("../") + mapIt.value() + QLatin1String(".json"));
+ jsonFileList.push_back(jsonPath);
+ }
+
+ // Sort for consistent checks across runs
+ jsonFileList.sort();
+
+ // Read Previous file list (if any)
+ const QString fileListFilePath = parser.value(outputFileOption);
+ QVector<QString> previousList;
+ QFile prev_file(fileListFilePath);
+
+ // Only try to open file if it exists to avoid error messages
+ if (prev_file.exists()) {
+ (void)readJsonFiles(previousList, fileListFilePath);
+ }
+
+ if (previousList != jsonFileList || !QFile(fileListFilePath).exists()) {
+ if (!writeJsonFiles(jsonFileList, fileListFilePath)) {
+ return EXIT_FAILURE;
+ }
+ }
+
+ return EXIT_SUCCESS;
+}
+
+QT_END_NAMESPACE
diff --git a/src/tools/moc/.prev_CMakeLists.txt b/src/tools/moc/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..ffadd2e2be
--- /dev/null
+++ b/src/tools/moc/.prev_CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from moc.pro.
+
+#####################################################################
+## moc Tool:
+#####################################################################
+
+qt_add_tool(moc
+ BOOTSTRAP
+ SOURCES
+ cbordevice.h
+ collectjson.cpp collectjson.h
+ generator.cpp generator.h
+ main.cpp
+ moc.cpp moc.h
+ outputrevision.h
+ parser.cpp parser.h
+ preprocessor.cpp preprocessor.h
+ qdatetime_p.h
+ symbols.h
+ token.cpp token.h
+ utils.h
+ DEFINES
+ QT_MOC
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_FROM_BYTEARRAY
+ QT_NO_COMPRESS
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ ../../3rdparty/tinycbor/src
+)
+
+#### Keys ignored in scope 1:.:.:moc.pro:<TRUE>:
+# QMAKE_TARGET_DESCRIPTION = "Qt Meta Object Compiler"
+# _OPTION = "host_build"
diff --git a/src/tools/moc/CMakeLists.txt b/src/tools/moc/CMakeLists.txt
new file mode 100644
index 0000000000..c9786674f1
--- /dev/null
+++ b/src/tools/moc/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from moc.pro.
+
+#####################################################################
+## moc Tool:
+#####################################################################
+
+qt_add_tool(moc
+ BOOTSTRAP
+ TOOLS_TARGET Core # special case
+ SOURCES
+ cbordevice.h
+ collectjson.cpp collectjson.h
+ generator.cpp generator.h
+ main.cpp
+ moc.cpp moc.h
+ outputrevision.h
+ parser.cpp parser.h
+ preprocessor.cpp preprocessor.h
+ # qdatetime_p.h special case remove
+ symbols.h
+ token.cpp token.h
+ utils.h
+ DEFINES
+ QT_MOC
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_FROM_BYTEARRAY
+ QT_NO_COMPRESS
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ ../../3rdparty/tinycbor/src
+)
+
+#### Keys ignored in scope 1:.:.:moc.pro:<TRUE>:
+# QMAKE_TARGET_DESCRIPTION = "Qt Meta Object Compiler"
+# _OPTION = "host_build"
diff --git a/src/tools/qdbuscpp2xml/.prev_CMakeLists.txt b/src/tools/qdbuscpp2xml/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..9d51b4eac9
--- /dev/null
+++ b/src/tools/qdbuscpp2xml/.prev_CMakeLists.txt
@@ -0,0 +1,49 @@
+# Generated from qdbuscpp2xml.pro.
+
+#####################################################################
+## qdbuscpp2xml Tool:
+#####################################################################
+
+qt_add_tool(qdbuscpp2xml
+ SOURCES
+ ../moc/cbordevice.h
+ ../moc/collectjson.cpp ../moc/collectjson.h
+ ../moc/generator.cpp ../moc/generator.h
+ ../moc/moc.cpp ../moc/moc.h
+ ../moc/outputrevision.h
+ ../moc/parser.cpp ../moc/parser.h
+ ../moc/preprocessor.cpp ../moc/preprocessor.h
+ ../moc/symbols.h
+ ../moc/token.cpp ../moc/token.h
+ ../moc/utils.h
+ qdbuscpp2xml.cpp
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ ../moc
+ ../moc/../../3rdparty/tinycbor/src
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+#### Keys ignored in scope 1:.:.:qdbuscpp2xml.pro:<TRUE>:
+# QMAKE_TARGET_DESCRIPTION = "Qt D-Bus C++ to XML Compiler"
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qdbuscpp2xml CONDITION force_bootstrap
+ LIBRARIES
+ bootstrap_dbusPrivate
+ PUBLIC_LIBRARIES
+ bootstrap_dbus
+)
+
+qt_extend_target(qdbuscpp2xml CONDITION NOT force_bootstrap
+ LIBRARIES
+ Qt::DBusPrivate
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/src/tools/qdbuscpp2xml/CMakeLists.txt b/src/tools/qdbuscpp2xml/CMakeLists.txt
new file mode 100644
index 0000000000..499e5fb6ae
--- /dev/null
+++ b/src/tools/qdbuscpp2xml/CMakeLists.txt
@@ -0,0 +1,48 @@
+# Generated from qdbuscpp2xml.pro.
+
+#####################################################################
+## qdbuscpp2xml Tool:
+#####################################################################
+
+qt_add_tool(qdbuscpp2xml
+ TOOLS_TARGET DBus # special case
+ SOURCES
+ ../moc/cbordevice.h
+ ../moc/collectjson.cpp ../moc/collectjson.h
+ ../moc/generator.cpp ../moc/generator.h
+ ../moc/moc.cpp ../moc/moc.h
+ ../moc/outputrevision.h
+ ../moc/parser.cpp ../moc/parser.h
+ ../moc/preprocessor.cpp ../moc/preprocessor.h
+ ../moc/symbols.h
+ ../moc/token.cpp ../moc/token.h
+ ../moc/utils.h
+ qdbuscpp2xml.cpp
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ ../moc
+ ../moc/../../3rdparty/tinycbor/src
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBusPrivate
+ # COMPILE_OPTIONS # special case
+ # "$$QT_HOST_CFLAGS_DBUS"
+ # QMAKE_TARGET_DESCRIPTION = "Qt D-Bus C++ to XML Compiler"
+ # _LOADED = "qt_tool"
+ # _OPTION = "host_build"
+)
+
+#### Keys ignored in scope 1:.:.:qdbuscpp2xml.pro:<TRUE>:
+# QMAKE_TARGET_DESCRIPTION = "Qt D-Bus C++ to XML Compiler"
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
+
+# special case begin
+# extend_target(qdbuscpp2xml CONDITION force_bootstrap [...])
+# extend_target(qdbuscpp2xml CONDITION NOT force_bootstrap [...])
+# special case end
+
diff --git a/src/tools/qdbusxml2cpp/.prev_CMakeLists.txt b/src/tools/qdbusxml2cpp/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..202e751727
--- /dev/null
+++ b/src/tools/qdbusxml2cpp/.prev_CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from qdbusxml2cpp.pro.
+
+#####################################################################
+## qdbusxml2cpp Tool:
+#####################################################################
+
+qt_add_tool(qdbusxml2cpp
+ SOURCES
+ qdbusxml2cpp.cpp
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+#### Keys ignored in scope 1:.:.:qdbusxml2cpp.pro:<TRUE>:
+# QMAKE_TARGET_DESCRIPTION = "Qt D-Bus XML to C++ Compiler"
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(qdbusxml2cpp CONDITION NOT force_bootstrap
+ LIBRARIES
+ Qt::DBusPrivate
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
+
+qt_extend_target(qdbusxml2cpp CONDITION force_bootstrap
+ LIBRARIES
+ bootstrap_dbusPrivate
+ PUBLIC_LIBRARIES
+ bootstrap_dbus
+)
diff --git a/src/tools/qdbusxml2cpp/CMakeLists.txt b/src/tools/qdbusxml2cpp/CMakeLists.txt
new file mode 100644
index 0000000000..f97cbb1180
--- /dev/null
+++ b/src/tools/qdbusxml2cpp/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from qdbusxml2cpp.pro.
+
+#####################################################################
+## qdbusxml2cpp Tool:
+#####################################################################
+
+qt_add_tool(qdbusxml2cpp
+ TOOLS_TARGET DBus # special case
+ SOURCES
+ qdbusxml2cpp.cpp
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBusPrivate
+ # COMPILE_OPTIONS # special case
+ # "$$QT_HOST_CFLAGS_DBUS"
+ # QMAKE_TARGET_DESCRIPTION = "Qt D-Bus XML to C++ Compiler"
+ # _LOADED = "qt_tool"
+ # _OPTION = "host_build"
+)
+
+#### Keys ignored in scope 1:.:.:qdbusxml2cpp.pro:<TRUE>:
+# QMAKE_TARGET_DESCRIPTION = "Qt D-Bus XML to C++ Compiler"
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
+
+# special case begin
+# extend_target(qdbusxml2cpp CONDITION NOT force_bootstrap [...])
+# extend_target(qdbusxml2cpp CONDITION NOT QT_FEATURE_commandlineparser AND NOT force_bootstrap [...])
+# extend_target(qdbusxml2cpp CONDITION force_bootstrap [...])
+# special case end
diff --git a/src/tools/qlalr/.prev_CMakeLists.txt b/src/tools/qlalr/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..9ff8a54ce4
--- /dev/null
+++ b/src/tools/qlalr/.prev_CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from qlalr.pro.
+
+#####################################################################
+## qlalr Tool:
+#####################################################################
+
+qt_add_tool(qlalr
+ SOURCES
+ compress.cpp compress.h
+ cppgenerator.cpp cppgenerator.h
+ dotgraph.cpp dotgraph.h
+ grammar.cpp grammar_p.h
+ lalr.cpp lalr.h
+ main.cpp
+ parsetable.cpp parsetable.h
+ recognizer.cpp recognizer.h
+ DEFINES
+ QT_NO_FOREACH
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:qlalr.pro:<TRUE>:
+# OTHER_FILES = "lalr.g"
+# QMAKE_TARGET_DESCRIPTION = "Qt Look Ahead LR Parser Generator"
+# _OPTION = "host_build"
diff --git a/src/tools/qlalr/CMakeLists.txt b/src/tools/qlalr/CMakeLists.txt
new file mode 100644
index 0000000000..437c8d918f
--- /dev/null
+++ b/src/tools/qlalr/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from qlalr.pro.
+
+#####################################################################
+## qlalr Tool:
+#####################################################################
+
+qt_add_tool(qlalr
+ TOOLS_TARGET Core # special case
+ SOURCES
+ compress.cpp compress.h
+ cppgenerator.cpp cppgenerator.h
+ dotgraph.cpp dotgraph.h
+ grammar.cpp grammar_p.h
+ lalr.cpp lalr.h
+ main.cpp
+ parsetable.cpp parsetable.h
+ recognizer.cpp recognizer.h
+ DEFINES
+ QT_NO_FOREACH
+ PUBLIC_LIBRARIES
+ Qt::Core # special case
+)
+
+#### Keys ignored in scope 1:.:.:qlalr.pro:<TRUE>:
+# OTHER_FILES = "lalr.g"
+# QMAKE_TARGET_DESCRIPTION = "Qt Look Ahead LR Parser Generator"
+# _OPTION = "host_build"
diff --git a/src/tools/qvkgen/.prev_CMakeLists.txt b/src/tools/qvkgen/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..994b97a9f1
--- /dev/null
+++ b/src/tools/qvkgen/.prev_CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qvkgen.pro.
+
+#####################################################################
+## qvkgen Tool:
+#####################################################################
+
+qt_add_tool(qvkgen
+ SOURCES
+ qvkgen.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:qvkgen.pro:<TRUE>:
+# QMAKE_TARGET_DESCRIPTION = "Qt Vulkan Header Generator"
+# _OPTION = "host_build"
diff --git a/src/tools/qvkgen/CMakeLists.txt b/src/tools/qvkgen/CMakeLists.txt
new file mode 100644
index 0000000000..0f72a8b633
--- /dev/null
+++ b/src/tools/qvkgen/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qvkgen.pro.
+
+#####################################################################
+## qvkgen Tool:
+#####################################################################
+
+qt_add_tool(qvkgen
+ TOOLS_TARGET Gui # special case
+ SOURCES
+ qvkgen.cpp
+ PUBLIC_LIBRARIES
+ Qt::Core # special case
+)
+
+#### Keys ignored in scope 1:.:.:qvkgen.pro:<TRUE>:
+# QMAKE_TARGET_DESCRIPTION = "Qt Vulkan Header Generator"
+# _OPTION = "host_build"
diff --git a/src/tools/rcc/.prev_CMakeLists.txt b/src/tools/rcc/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..307f08bfa7
--- /dev/null
+++ b/src/tools/rcc/.prev_CMakeLists.txt
@@ -0,0 +1,37 @@
+# Generated from rcc.pro.
+
+#####################################################################
+## rcc Tool:
+#####################################################################
+
+qt_add_tool(rcc
+ BOOTSTRAP
+ SOURCES
+ main.cpp
+ rcc.cpp rcc.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ QT_RCC
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+)
+
+#### Keys ignored in scope 1:.:.:rcc.pro:<TRUE>:
+# QMAKE_TARGET_DESCRIPTION = "Qt Resource Compiler"
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(rcc CONDITION QT_FEATURE_zstd AND NOT CMAKE_CROSSCOMPILING
+ DEFINES
+ QT_FEATURE_zstd=1
+ LIBRARIES
+ ZSTD::ZSTD
+)
+
+qt_extend_target(rcc CONDITION CMAKE_CROSSCOMPILING OR NOT QT_FEATURE_zstd
+ DEFINES
+ QT_FEATURE_zstd=-1
+)
diff --git a/src/tools/rcc/CMakeLists.txt b/src/tools/rcc/CMakeLists.txt
new file mode 100644
index 0000000000..e7f45314c3
--- /dev/null
+++ b/src/tools/rcc/CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from rcc.pro.
+
+#####################################################################
+## rcc Tool:
+#####################################################################
+
+qt_add_tool(rcc
+ BOOTSTRAP
+ TOOLS_TARGET Core # special case
+ SOURCES
+ main.cpp
+ rcc.cpp rcc.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ QT_RCC
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+)
+
+#### Keys ignored in scope 1:.:.:rcc.pro:<TRUE>:
+# QMAKE_TARGET_DESCRIPTION = "Qt Resource Compiler"
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(rcc CONDITION QT_FEATURE_zstd AND NOT CMAKE_CROSSCOMPILING
+ DEFINES
+ QT_FEATURE_zstd=1
+ LIBRARIES
+ ZSTD::ZSTD
+)
+
+qt_extend_target(rcc CONDITION CMAKE_CROSSCOMPILING OR NOT QT_FEATURE_zstd
+ DEFINES
+ QT_FEATURE_zstd=-1
+)
diff --git a/src/tools/tracegen/.prev_CMakeLists.txt b/src/tools/tracegen/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..87bcf362d6
--- /dev/null
+++ b/src/tools/tracegen/.prev_CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from tracegen.pro.
+
+#####################################################################
+## tracegen Tool:
+#####################################################################
+
+qt_add_tool(tracegen
+ BOOTSTRAP
+ SOURCES
+ etw.cpp etw.h
+ helpers.cpp helpers.h
+ lttng.cpp lttng.h
+ panic.cpp panic.h
+ provider.cpp provider.h
+ qtheaders.cpp qtheaders.h
+ tracegen.cpp
+)
+
+#### Keys ignored in scope 1:.:.:tracegen.pro:<TRUE>:
+# _OPTION = "host_build"
diff --git a/src/tools/tracegen/CMakeLists.txt b/src/tools/tracegen/CMakeLists.txt
new file mode 100644
index 0000000000..0f12f823c4
--- /dev/null
+++ b/src/tools/tracegen/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from tracegen.pro.
+
+#####################################################################
+## tracegen Tool:
+#####################################################################
+
+qt_add_tool(tracegen
+ BOOTSTRAP
+ TOOLS_TARGET Core # special case
+ SOURCES
+ etw.cpp etw.h
+ helpers.cpp helpers.h
+ lttng.cpp lttng.h
+ panic.cpp panic.h
+ provider.cpp provider.h
+ qtheaders.cpp qtheaders.h
+ tracegen.cpp
+)
+
+#### Keys ignored in scope 1:.:.:tracegen.pro:<TRUE>:
+# _OPTION = "host_build"
diff --git a/src/tools/uic/.prev_CMakeLists.txt b/src/tools/uic/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..4cd28d7070
--- /dev/null
+++ b/src/tools/uic/.prev_CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from uic.pro.
+
+#####################################################################
+## uic Tool:
+#####################################################################
+
+qt_add_tool(uic
+ SOURCES
+ cpp/cppwritedeclaration.cpp cpp/cppwritedeclaration.h
+ cpp/cppwriteincludes.cpp cpp/cppwriteincludes.h
+ cpp/cppwriteinitialization.cpp cpp/cppwriteinitialization.h
+ customwidgetsinfo.cpp customwidgetsinfo.h
+ databaseinfo.cpp databaseinfo.h
+ driver.cpp driver.h
+ main.cpp
+ option.h
+ python/pythonwritedeclaration.cpp python/pythonwritedeclaration.h
+ python/pythonwriteimports.cpp python/pythonwriteimports.h
+ shared/language.cpp shared/language.h
+ treewalker.cpp treewalker.h
+ ui4.cpp ui4.h
+ uic.cpp uic.h
+ utils.h
+ validator.cpp validator.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ QT_UIC
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ ${PROJECT_BINARY_DIR}/src/tools/uic
+ cpp
+ python
+ shared
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:uic.pro:<TRUE>:
+# QMAKE_TARGET_DESCRIPTION = "Qt User Interface Compiler"
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
diff --git a/src/tools/uic/CMakeLists.txt b/src/tools/uic/CMakeLists.txt
new file mode 100644
index 0000000000..21fd232349
--- /dev/null
+++ b/src/tools/uic/CMakeLists.txt
@@ -0,0 +1,45 @@
+# Generated from uic.pro.
+
+#####################################################################
+## uic Tool:
+#####################################################################
+
+qt_add_tool(uic
+ TOOLS_TARGET Widgets # special case
+ SOURCES
+ cpp/cppwritedeclaration.cpp cpp/cppwritedeclaration.h
+ cpp/cppwriteincludes.cpp cpp/cppwriteincludes.h
+ cpp/cppwriteinitialization.cpp cpp/cppwriteinitialization.h
+ customwidgetsinfo.cpp customwidgetsinfo.h
+ databaseinfo.cpp databaseinfo.h
+ driver.cpp driver.h
+ main.cpp
+ option.h
+ python/pythonwritedeclaration.cpp python/pythonwritedeclaration.h
+ python/pythonwriteimports.cpp python/pythonwriteimports.h
+ shared/language.cpp shared/language.h
+ treewalker.cpp treewalker.h
+ ui4.cpp ui4.h
+ uic.cpp uic.h
+ utils.h
+ validator.cpp validator.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ QT_UIC
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ # ${PROJECT_BINARY_DIR}/src/tools/uic # special case remove
+ cpp
+ python
+ shared
+ #PUBLIC_LIBRARIES # special case remove
+ #Qt::Gui # special case remove
+)
+
+#### Keys ignored in scope 1:.:.:uic.pro:<TRUE>:
+# QMAKE_TARGET_DESCRIPTION = "Qt User Interface Compiler"
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
diff --git a/src/widgets/.prev_CMakeLists.txt b/src/widgets/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..c53bb3928f
--- /dev/null
+++ b/src/widgets/.prev_CMakeLists.txt
@@ -0,0 +1,845 @@
+# Generated from widgets.pro.
+
+#####################################################################
+## Widgets Module:
+#####################################################################
+
+qt_add_module(Widgets
+ GENERATE_METATYPES
+ QMAKE_MODULE_CONFIG uic
+ PLUGIN_TYPES styles
+ SOURCES
+ itemviews/qfileiconprovider.cpp itemviews/qfileiconprovider.h itemviews/qfileiconprovider_p.h
+ kernel/qapplication.cpp kernel/qapplication.h kernel/qapplication_p.h
+ kernel/qboxlayout.cpp kernel/qboxlayout.h
+ kernel/qdesktopwidget.cpp kernel/qdesktopwidget.h kernel/qdesktopwidget_p.h
+ kernel/qgesture.cpp kernel/qgesture.h kernel/qgesture_p.h
+ kernel/qgesturemanager.cpp kernel/qgesturemanager_p.h
+ kernel/qgesturerecognizer.cpp kernel/qgesturerecognizer.h
+ kernel/qgridlayout.cpp kernel/qgridlayout.h
+ kernel/qlayout.cpp kernel/qlayout.h kernel/qlayout_p.h
+ kernel/qlayoutengine.cpp kernel/qlayoutengine_p.h
+ kernel/qlayoutitem.cpp kernel/qlayoutitem.h
+ kernel/qsizepolicy.cpp kernel/qsizepolicy.h
+ kernel/qstackedlayout.cpp kernel/qstackedlayout.h
+ kernel/qstandardgestures.cpp kernel/qstandardgestures_p.h
+ kernel/qtestsupport_widgets.cpp kernel/qtestsupport_widgets.h
+ kernel/qtwidgetsglobal.h kernel/qtwidgetsglobal_p.h
+ kernel/qwidget.cpp kernel/qwidget.h kernel/qwidget_p.h
+ kernel/qwidgetrepaintmanager.cpp kernel/qwidgetrepaintmanager_p.h
+ kernel/qwidgetsvariant.cpp
+ kernel/qwidgetwindow.cpp kernel/qwidgetwindow_p.h
+ kernel/qwindowcontainer.cpp kernel/qwindowcontainer_p.h
+ styles/qcommonstyle.cpp styles/qcommonstyle.h styles/qcommonstyle_p.h
+ styles/qcommonstylepixmaps_p.h
+ styles/qdrawutil.cpp styles/qdrawutil.h
+ styles/qpixmapstyle.cpp styles/qpixmapstyle_p.h
+ styles/qpixmapstyle_p_p.h
+ styles/qproxystyle.cpp styles/qproxystyle.h styles/qproxystyle_p.h
+ styles/qstyle.cpp styles/qstyle.h
+ styles/qstylefactory.cpp styles/qstylefactory.h
+ styles/qstylehelper.cpp styles/qstylehelper_p.h
+ styles/qstyleoption.cpp styles/qstyleoption.h
+ styles/qstylepainter.cpp styles/qstylepainter.h
+ styles/qstyleplugin.cpp styles/qstyleplugin.h
+ styles/qstylesheetstyle.cpp styles/qstylesheetstyle_p.h
+ styles/qstylesheetstyle_default.cpp
+ util/qcolormap.cpp util/qcolormap.h
+ util/qsystemtrayicon.cpp util/qsystemtrayicon.h util/qsystemtrayicon_p.h
+ widgets/qabstractscrollarea.cpp widgets/qabstractscrollarea.h widgets/qabstractscrollarea_p.h
+ widgets/qfocusframe.cpp widgets/qfocusframe.h
+ widgets/qframe.cpp widgets/qframe.h widgets/qframe_p.h
+ widgets/qwidgetanimator.cpp widgets/qwidgetanimator_p.h
+ DEFINES
+ QT_NO_USING_NAMESPACE
+ INCLUDE_DIRECTORIES
+ dialogs
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "kernel/qt_widgets_pch.h"
+)
+
+# Resources:
+set(qstyle_resource_files
+ "images/cdr-128.png"
+ "images/cdr-16.png"
+ "images/cdr-32.png"
+ "images/cleartext-16.png"
+ "images/cleartext-32.png"
+ "images/closedock-10.png"
+ "images/closedock-16.png"
+ "images/closedock-20.png"
+ "images/closedock-32.png"
+ "images/closedock-48.png"
+ "images/closedock-64.png"
+ "images/computer-16.png"
+ "images/computer-32.png"
+ "images/desktop-16.png"
+ "images/desktop-32.png"
+ "images/dirclosed-128.png"
+ "images/dirclosed-16.png"
+ "images/dirclosed-32.png"
+ "images/dirlink-128.png"
+ "images/dirlink-16.png"
+ "images/dirlink-32.png"
+ "images/diropen-128.png"
+ "images/diropen-16.png"
+ "images/diropen-32.png"
+ "images/down-128.png"
+ "images/down-16.png"
+ "images/down-32.png"
+ "images/dvd-128.png"
+ "images/dvd-16.png"
+ "images/dvd-32.png"
+ "images/file-128.png"
+ "images/file-16.png"
+ "images/file-32.png"
+ "images/filecontents-128.png"
+ "images/filecontents-16.png"
+ "images/filecontents-32.png"
+ "images/fileinfo-128.png"
+ "images/fileinfo-16.png"
+ "images/fileinfo-32.png"
+ "images/filelink-128.png"
+ "images/filelink-16.png"
+ "images/filelink-32.png"
+ "images/floppy-128.png"
+ "images/floppy-16.png"
+ "images/floppy-32.png"
+ "images/fontbitmap-16.png"
+ "images/fonttruetype-16.png"
+ "images/fusion_groupbox.png"
+ "images/harddrive-128.png"
+ "images/harddrive-16.png"
+ "images/harddrive-32.png"
+ "images/left-128.png"
+ "images/left-16.png"
+ "images/left-32.png"
+ "images/media-pause-16.png"
+ "images/media-pause-32.png"
+ "images/media-play-16.png"
+ "images/media-play-32.png"
+ "images/media-seek-backward-16.png"
+ "images/media-seek-backward-32.png"
+ "images/media-seek-forward-16.png"
+ "images/media-seek-forward-32.png"
+ "images/media-skip-backward-16.png"
+ "images/media-skip-backward-32.png"
+ "images/media-skip-forward-16.png"
+ "images/media-skip-forward-32.png"
+ "images/media-stop-16.png"
+ "images/media-stop-32.png"
+ "images/media-volume-16.png"
+ "images/media-volume-muted-16.png"
+ "images/networkdrive-128.png"
+ "images/networkdrive-16.png"
+ "images/networkdrive-32.png"
+ "images/newdirectory-128.png"
+ "images/newdirectory-16.png"
+ "images/newdirectory-32.png"
+ "images/normalizedockup-10.png"
+ "images/normalizedockup-16.png"
+ "images/normalizedockup-20.png"
+ "images/normalizedockup-32.png"
+ "images/normalizedockup-48.png"
+ "images/normalizedockup-64.png"
+ "images/parentdir-128.png"
+ "images/parentdir-16.png"
+ "images/parentdir-32.png"
+ "images/refresh-24.png"
+ "images/refresh-32.png"
+ "images/right-128.png"
+ "images/right-16.png"
+ "images/right-32.png"
+ "images/standardbutton-apply-128.png"
+ "images/standardbutton-apply-16.png"
+ "images/standardbutton-apply-32.png"
+ "images/standardbutton-cancel-128.png"
+ "images/standardbutton-cancel-16.png"
+ "images/standardbutton-cancel-32.png"
+ "images/standardbutton-clear-128.png"
+ "images/standardbutton-clear-16.png"
+ "images/standardbutton-clear-32.png"
+ "images/standardbutton-close-128.png"
+ "images/standardbutton-close-16.png"
+ "images/standardbutton-close-32.png"
+ "images/standardbutton-closetab-16.png"
+ "images/standardbutton-closetab-down-16.png"
+ "images/standardbutton-closetab-hover-16.png"
+ "images/standardbutton-delete-128.png"
+ "images/standardbutton-delete-16.png"
+ "images/standardbutton-delete-32.png"
+ "images/standardbutton-help-128.png"
+ "images/standardbutton-help-16.png"
+ "images/standardbutton-help-32.png"
+ "images/standardbutton-no-128.png"
+ "images/standardbutton-no-16.png"
+ "images/standardbutton-no-32.png"
+ "images/standardbutton-ok-128.png"
+ "images/standardbutton-ok-16.png"
+ "images/standardbutton-ok-32.png"
+ "images/standardbutton-open-128.png"
+ "images/standardbutton-open-16.png"
+ "images/standardbutton-open-32.png"
+ "images/standardbutton-save-128.png"
+ "images/standardbutton-save-16.png"
+ "images/standardbutton-save-32.png"
+ "images/standardbutton-yes-128.png"
+ "images/standardbutton-yes-16.png"
+ "images/standardbutton-yes-32.png"
+ "images/stop-24.png"
+ "images/stop-32.png"
+ "images/titlebar-contexthelp-16.png"
+ "images/titlebar-contexthelp-32.png"
+ "images/titlebar-contexthelp-48.png"
+ "images/titlebar-max-16.png"
+ "images/titlebar-max-32.png"
+ "images/titlebar-max-48.png"
+ "images/titlebar-min-16.png"
+ "images/titlebar-min-32.png"
+ "images/titlebar-min-48.png"
+ "images/titlebar-shade-16.png"
+ "images/titlebar-shade-32.png"
+ "images/titlebar-shade-48.png"
+ "images/titlebar-unshade-16.png"
+ "images/titlebar-unshade-32.png"
+ "images/titlebar-unshade-48.png"
+ "images/toolbar-ext-h-16.png"
+ "images/toolbar-ext-h-32.png"
+ "images/toolbar-ext-h-8.png"
+ "images/toolbar-ext-h-rtl-16.png"
+ "images/toolbar-ext-h-rtl-32.png"
+ "images/toolbar-ext-h-rtl-8.png"
+ "images/toolbar-ext-v-10.png"
+ "images/toolbar-ext-v-20.png"
+ "images/toolbar-ext-v-5.png"
+ "images/trash-128.png"
+ "images/trash-16.png"
+ "images/trash-32.png"
+ "images/up-128.png"
+ "images/up-16.png"
+ "images/up-32.png"
+ "images/viewdetailed-128.png"
+ "images/viewdetailed-16.png"
+ "images/viewdetailed-32.png"
+ "images/viewlist-128.png"
+ "images/viewlist-16.png"
+ "images/viewlist-32.png"
+)
+
+qt_add_resource(Widgets "qstyle"
+ PREFIX
+ "/qt-project.org/styles/commonstyle"
+ BASE
+ "styles"
+ FILES
+ ${qstyle_resource_files}
+)
+set_source_files_properties("styles/images/closedock-down-macstyle-16.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/closedock-down-16.png"
+)
+set_source_files_properties("styles/images/closedock-macstyle-16.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/closedock-16.png"
+)
+set_source_files_properties("styles/images/dockdock-down-macstyle-16.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dockdock-down-16.png"
+)
+set_source_files_properties("styles/images/dockdock-macstyle-16.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dockdock-16.png"
+)
+set_source_files_properties("styles/images/toolbar-ext-macstyle.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/toolbar-ext.png"
+)
+set_source_files_properties("styles/images/toolbar-ext-macstyle@2x.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/toolbar-ext@2x.png"
+)
+set(qstyle1_resource_files
+ "images/closedock-down-macstyle-16.png"
+ "images/closedock-macstyle-16.png"
+ "images/dockdock-down-macstyle-16.png"
+ "images/dockdock-macstyle-16.png"
+ "images/toolbar-ext-macstyle.png"
+ "images/toolbar-ext-macstyle@2x.png"
+)
+
+qt_add_resource(Widgets "qstyle1"
+ PREFIX
+ "/qt-project.org/styles/macstyle"
+ BASE
+ "styles"
+ FILES
+ ${qstyle1_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:widgets.pro:<TRUE>:
+# MODULE_CONFIG = "uic"
+# QMAKE_DYNAMIC_LIST_FILE = "$$PWD/QtWidgets.dynlist"
+# QMAKE_LIBS = "$$QMAKE_LIBS_GUI"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(Widgets CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x65000000"
+)
+
+qt_extend_target(Widgets CONDITION APPLE_OSX
+ SOURCES
+ kernel/qmacgesturerecognizer.cpp kernel/qmacgesturerecognizer_p.h
+ widgets/qmaccocoaviewcontainer_mac.h widgets/qmaccocoaviewcontainer_mac.mm
+ widgets/qmacnativewidget_mac.h widgets/qmacnativewidget_mac.mm
+ LIBRARIES
+ ${FWAppKit}
+ z
+)
+
+qt_extend_target(Widgets CONDITION WIN32
+ INCLUDE_DIRECTORIES
+ ../3rdparty/wintab
+)
+
+qt_extend_target(Widgets CONDITION WIN32 AND NOT WINRT
+ LIBRARIES
+ dwmapi
+ shell32
+ uxtheme
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_graphicseffect
+ SOURCES
+ effects/qgraphicseffect.cpp effects/qgraphicseffect.h effects/qgraphicseffect_p.h
+ effects/qpixmapfilter.cpp effects/qpixmapfilter_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_action
+ SOURCES
+ kernel/qaction.cpp kernel/qaction.h kernel/qaction_p.h
+ kernel/qactiongroup.cpp kernel/qactiongroup.h
+ kernel/qwidgetaction.cpp kernel/qwidgetaction.h kernel/qwidgetaction_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_opengl
+ SOURCES
+ kernel/qopenglwidget.cpp kernel/qopenglwidget.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_formlayout
+ SOURCES
+ kernel/qformlayout.cpp kernel/qformlayout.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_shortcut
+ SOURCES
+ kernel/qshortcut.cpp kernel/qshortcut.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_tooltip
+ SOURCES
+ kernel/qtooltip.cpp kernel/qtooltip.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_whatsthis
+ SOURCES
+ kernel/qwhatsthis.cpp kernel/qwhatsthis.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_animation
+ SOURCES
+ styles/qstyleanimation.cpp styles/qstyleanimation_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_style_windows
+ SOURCES
+ styles/qwindowsstyle.cpp styles/qwindowsstyle_p.h
+ styles/qwindowsstyle_p_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_style_fusion
+ SOURCES
+ styles/qfusionstyle.cpp styles/qfusionstyle_p.h
+ styles/qfusionstyle_p_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_abstractbutton
+ SOURCES
+ widgets/qabstractbutton.cpp widgets/qabstractbutton.h widgets/qabstractbutton_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_abstractslider
+ SOURCES
+ widgets/qabstractslider.cpp widgets/qabstractslider.h widgets/qabstractslider_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_buttongroup
+ SOURCES
+ widgets/qbuttongroup.cpp widgets/qbuttongroup.h widgets/qbuttongroup_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_calendarwidget
+ SOURCES
+ widgets/qcalendarwidget.cpp widgets/qcalendarwidget.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_checkbox
+ SOURCES
+ widgets/qcheckbox.cpp widgets/qcheckbox.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_combobox
+ SOURCES
+ widgets/qcombobox.cpp widgets/qcombobox.h widgets/qcombobox_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_commandlinkbutton
+ SOURCES
+ widgets/qcommandlinkbutton.cpp widgets/qcommandlinkbutton.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_datetimeedit
+ SOURCES
+ widgets/qdatetimeedit.cpp widgets/qdatetimeedit.h widgets/qdatetimeedit_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_dial
+ SOURCES
+ widgets/qdial.cpp widgets/qdial.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_dockwidget
+ SOURCES
+ widgets/qdockarealayout.cpp widgets/qdockarealayout_p.h
+ widgets/qdockwidget.cpp widgets/qdockwidget.h widgets/qdockwidget_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_effects
+ SOURCES
+ widgets/qeffects.cpp widgets/qeffects_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_fontcombobox
+ SOURCES
+ widgets/qfontcombobox.cpp widgets/qfontcombobox.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_groupbox
+ SOURCES
+ widgets/qgroupbox.cpp widgets/qgroupbox.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_keysequenceedit
+ SOURCES
+ widgets/qkeysequenceedit.cpp widgets/qkeysequenceedit.h widgets/qkeysequenceedit_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_label
+ SOURCES
+ widgets/qlabel.cpp widgets/qlabel.h widgets/qlabel_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_lcdnumber
+ SOURCES
+ widgets/qlcdnumber.cpp widgets/qlcdnumber.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_lineedit
+ SOURCES
+ widgets/qlineedit.cpp widgets/qlineedit.h widgets/qlineedit_p.cpp widgets/qlineedit_p.h
+ widgets/qwidgetlinecontrol.cpp widgets/qwidgetlinecontrol_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_mainwindow
+ SOURCES
+ widgets/qmainwindow.cpp widgets/qmainwindow.h
+ widgets/qmainwindowlayout.cpp widgets/qmainwindowlayout_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_mdiarea
+ SOURCES
+ widgets/qmdiarea.cpp widgets/qmdiarea.h widgets/qmdiarea_p.h
+ widgets/qmdisubwindow.cpp widgets/qmdisubwindow.h widgets/qmdisubwindow_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_menu
+ SOURCES
+ widgets/qmenu.cpp widgets/qmenu.h widgets/qmenu_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_menubar
+ SOURCES
+ widgets/qmenubar.cpp widgets/qmenubar.h widgets/qmenubar_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_progressbar
+ SOURCES
+ widgets/qprogressbar.cpp widgets/qprogressbar.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_pushbutton
+ SOURCES
+ widgets/qpushbutton.cpp widgets/qpushbutton.h widgets/qpushbutton_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_radiobutton
+ SOURCES
+ widgets/qradiobutton.cpp widgets/qradiobutton.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_resizehandler
+ SOURCES
+ widgets/qwidgetresizehandler.cpp widgets/qwidgetresizehandler_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_dialogbuttonbox
+ SOURCES
+ widgets/qdialogbuttonbox.cpp widgets/qdialogbuttonbox.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_rubberband
+ SOURCES
+ widgets/qrubberband.cpp widgets/qrubberband.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_scrollarea
+ SOURCES
+ widgets/qscrollarea.cpp widgets/qscrollarea.h widgets/qscrollarea_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_scrollbar
+ SOURCES
+ widgets/qscrollbar.cpp widgets/qscrollbar.h widgets/qscrollbar_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_sizegrip
+ SOURCES
+ widgets/qsizegrip.cpp widgets/qsizegrip.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_slider
+ SOURCES
+ widgets/qslider.cpp widgets/qslider.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_spinbox
+ SOURCES
+ widgets/qabstractspinbox.cpp widgets/qabstractspinbox.h widgets/qabstractspinbox_p.h
+ widgets/qspinbox.cpp widgets/qspinbox.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_splashscreen
+ SOURCES
+ widgets/qsplashscreen.cpp widgets/qsplashscreen.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_splitter
+ SOURCES
+ widgets/qsplitter.cpp widgets/qsplitter.h widgets/qsplitter_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_stackedwidget
+ SOURCES
+ widgets/qstackedwidget.cpp widgets/qstackedwidget.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_statusbar
+ SOURCES
+ widgets/qstatusbar.cpp widgets/qstatusbar.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_tabbar
+ SOURCES
+ widgets/qtabbar.cpp widgets/qtabbar.h widgets/qtabbar_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_textedit
+ SOURCES
+ widgets/qplaintextedit.cpp widgets/qplaintextedit.h widgets/qplaintextedit_p.h
+ widgets/qtextedit.cpp widgets/qtextedit.h widgets/qtextedit_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_textbrowser
+ SOURCES
+ widgets/qtextbrowser.cpp widgets/qtextbrowser.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_tabwidget
+ SOURCES
+ widgets/qtabwidget.cpp widgets/qtabwidget.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_toolbar
+ SOURCES
+ widgets/qtoolbar.cpp widgets/qtoolbar.h widgets/qtoolbar_p.h
+ widgets/qtoolbararealayout.cpp widgets/qtoolbararealayout_p.h
+ widgets/qtoolbarlayout.cpp widgets/qtoolbarlayout_p.h
+ widgets/qtoolbarseparator.cpp widgets/qtoolbarseparator_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_toolbox
+ SOURCES
+ widgets/qtoolbox.cpp widgets/qtoolbox.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_toolbutton
+ SOURCES
+ widgets/qtoolbarextension.cpp widgets/qtoolbarextension_p.h
+ widgets/qtoolbutton.cpp widgets/qtoolbutton.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_widgettextcontrol
+ SOURCES
+ widgets/qwidgettextcontrol.cpp widgets/qwidgettextcontrol_p.h
+ widgets/qwidgettextcontrol_p_p.h
+)
+
+qt_extend_target(Widgets CONDITION APPLE_OSX AND (QT_FEATURE_menu OR QT_FEATURE_menubar)
+ SOURCES
+ widgets/qmenu_mac.mm
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_colordialog
+ SOURCES
+ dialogs/qcolordialog.cpp dialogs/qcolordialog.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_dialog
+ SOURCES
+ dialogs/qdialog.cpp dialogs/qdialog.h dialogs/qdialog_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_errormessage
+ SOURCES
+ dialogs/qerrormessage.cpp dialogs/qerrormessage.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_filedialog
+ SOURCES
+ dialogs/qfiledialog.cpp dialogs/qfiledialog.h dialogs/qfiledialog.ui dialogs/qfiledialog_p.h
+ dialogs/qsidebar.cpp dialogs/qsidebar_p.h
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_filesystemmodel
+ SOURCES
+ dialogs/qfileinfogatherer.cpp dialogs/qfileinfogatherer_p.h
+ dialogs/qfilesystemmodel.cpp dialogs/qfilesystemmodel.h dialogs/qfilesystemmodel_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_fontdialog
+ SOURCES
+ dialogs/qfontdialog.cpp dialogs/qfontdialog.h dialogs/qfontdialog_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_fscompleter
+ SOURCES
+ dialogs/qfscompleter_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_inputdialog
+ SOURCES
+ dialogs/qinputdialog.cpp dialogs/qinputdialog.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_messagebox
+ SOURCES
+ dialogs/qmessagebox.cpp dialogs/qmessagebox.h
+)
+
+if(QT_FEATURE_messagebox)
+ # Resources:
+ set(qmessagebox_resource_files
+ "images/qtlogo-64.png"
+ )
+
+ qt_add_resource(Widgets "qmessagebox"
+ PREFIX
+ "/qt-project.org/qmessagebox"
+ BASE
+ "dialogs"
+ FILES
+ ${qmessagebox_resource_files}
+ )
+endif()
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_progressdialog
+ SOURCES
+ dialogs/qprogressdialog.cpp dialogs/qprogressdialog.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_wizard
+ SOURCES
+ dialogs/qwizard.cpp dialogs/qwizard.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_wizard AND WIN32
+ SOURCES
+ dialogs/qwizard_win.cpp dialogs/qwizard_win_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_accessibility
+ SOURCES
+ accessible/complexwidgets.cpp accessible/complexwidgets_p.h
+ accessible/qaccessiblemenu.cpp accessible/qaccessiblemenu_p.h
+ accessible/qaccessiblewidget.cpp accessible/qaccessiblewidget.h
+ accessible/qaccessiblewidgetfactory.cpp accessible/qaccessiblewidgetfactory_p.h
+ accessible/qaccessiblewidgets.cpp accessible/qaccessiblewidgets_p.h
+ accessible/rangecontrols.cpp accessible/rangecontrols_p.h
+ accessible/simplewidgets.cpp accessible/simplewidgets_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_accessibility AND QT_FEATURE_itemviews
+ SOURCES
+ accessible/itemviews.cpp accessible/itemviews_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_itemviews
+ SOURCES
+ itemviews/qabstractitemdelegate.cpp itemviews/qabstractitemdelegate.h itemviews/qabstractitemdelegate_p.h
+ itemviews/qabstractitemview.cpp itemviews/qabstractitemview.h itemviews/qabstractitemview_p.h
+ itemviews/qbsptree.cpp itemviews/qbsptree_p.h
+ itemviews/qheaderview.cpp itemviews/qheaderview.h itemviews/qheaderview_p.h
+ itemviews/qitemdelegate.cpp itemviews/qitemdelegate.h
+ itemviews/qitemeditorfactory.cpp itemviews/qitemeditorfactory.h itemviews/qitemeditorfactory_p.h
+ itemviews/qstyleditemdelegate.cpp itemviews/qstyleditemdelegate.h
+ itemviews/qwidgetitemdata_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_columnview
+ SOURCES
+ itemviews/qcolumnview.cpp itemviews/qcolumnview.h itemviews/qcolumnview_p.h
+ itemviews/qcolumnviewgrip.cpp itemviews/qcolumnviewgrip_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_datawidgetmapper
+ SOURCES
+ itemviews/qdatawidgetmapper.cpp itemviews/qdatawidgetmapper.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_dirmodel
+ SOURCES
+ itemviews/qdirmodel.cpp itemviews/qdirmodel.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_listview
+ SOURCES
+ itemviews/qlistview.cpp itemviews/qlistview.h itemviews/qlistview_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_listwidget
+ SOURCES
+ itemviews/qlistwidget.cpp itemviews/qlistwidget.h itemviews/qlistwidget_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_tableview
+ SOURCES
+ itemviews/qtableview.cpp itemviews/qtableview.h itemviews/qtableview_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_tablewidget
+ SOURCES
+ itemviews/qtablewidget.cpp itemviews/qtablewidget.h itemviews/qtablewidget_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_treeview
+ SOURCES
+ itemviews/qtreeview.cpp itemviews/qtreeview.h itemviews/qtreeview_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_treewidget
+ SOURCES
+ itemviews/qtreewidget.cpp itemviews/qtreewidget.h itemviews/qtreewidget_p.h
+ itemviews/qtreewidgetitemiterator.cpp itemviews/qtreewidgetitemiterator.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_graphicsview
+ SOURCES
+ graphicsview/qgraph_p.h
+ graphicsview/qgraphicsanchorlayout.cpp graphicsview/qgraphicsanchorlayout.h graphicsview/qgraphicsanchorlayout_p.cpp graphicsview/qgraphicsanchorlayout_p.h
+ graphicsview/qgraphicsgridlayout.cpp graphicsview/qgraphicsgridlayout.h
+ graphicsview/qgraphicsgridlayoutengine.cpp graphicsview/qgraphicsgridlayoutengine_p.h
+ graphicsview/qgraphicsitem.cpp graphicsview/qgraphicsitem.h graphicsview/qgraphicsitem_p.h
+ graphicsview/qgraphicslayout.cpp graphicsview/qgraphicslayout.h graphicsview/qgraphicslayout_p.cpp graphicsview/qgraphicslayout_p.h
+ graphicsview/qgraphicslayoutitem.cpp graphicsview/qgraphicslayoutitem.h graphicsview/qgraphicslayoutitem_p.h
+ graphicsview/qgraphicslayoutstyleinfo.cpp graphicsview/qgraphicslayoutstyleinfo_p.h
+ graphicsview/qgraphicslinearlayout.cpp graphicsview/qgraphicslinearlayout.h
+ graphicsview/qgraphicsproxywidget.cpp graphicsview/qgraphicsproxywidget.h graphicsview/qgraphicsproxywidget_p.h
+ graphicsview/qgraphicsscene.cpp graphicsview/qgraphicsscene.h graphicsview/qgraphicsscene_p.h
+ graphicsview/qgraphicsscene_bsp.cpp graphicsview/qgraphicsscene_bsp_p.h
+ graphicsview/qgraphicsscenebsptreeindex.cpp graphicsview/qgraphicsscenebsptreeindex_p.h
+ graphicsview/qgraphicssceneevent.cpp graphicsview/qgraphicssceneevent.h
+ graphicsview/qgraphicssceneindex.cpp graphicsview/qgraphicssceneindex_p.h
+ graphicsview/qgraphicsscenelinearindex.cpp graphicsview/qgraphicsscenelinearindex_p.h
+ graphicsview/qgraphicstransform.cpp graphicsview/qgraphicstransform.h graphicsview/qgraphicstransform_p.h
+ graphicsview/qgraphicsview.cpp graphicsview/qgraphicsview.h graphicsview/qgraphicsview_p.h
+ graphicsview/qgraphicswidget.cpp graphicsview/qgraphicswidget.h graphicsview/qgraphicswidget_p.cpp graphicsview/qgraphicswidget_p.h
+ graphicsview/qsimplex_p.cpp graphicsview/qsimplex_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_easingcurve AND QT_FEATURE_graphicsview
+ SOURCES
+ graphicsview/qgraphicsitemanimation.cpp graphicsview/qgraphicsitemanimation.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_completer
+ SOURCES
+ util/qcompleter.cpp util/qcompleter.h util/qcompleter_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_scroller
+ SOURCES
+ util/qflickgesture.cpp util/qflickgesture_p.h
+ util/qscroller.cpp util/qscroller.h util/qscroller_p.h
+ util/qscrollerproperties.cpp util/qscrollerproperties.h util/qscrollerproperties_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_undocommand
+ SOURCES
+ util/qundostack.cpp util/qundostack.h util/qundostack_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_undogroup
+ SOURCES
+ util/qundogroup.cpp util/qundogroup.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_undoview
+ SOURCES
+ util/qundoview.cpp util/qundoview.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_xcb
+ SOURCES
+ util/qsystemtrayicon_x11.cpp
+)
+
+qt_extend_target(Widgets CONDITION NOT QT_FEATURE_xcb
+ SOURCES
+ util/qsystemtrayicon_qpa.cpp
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_statemachine
+ SOURCES
+ statemachine/qguistatemachine.cpp
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_qeventtransition
+ SOURCES
+ statemachine/qbasickeyeventtransition.cpp statemachine/qbasickeyeventtransition_p.h
+ statemachine/qbasicmouseeventtransition.cpp statemachine/qbasicmouseeventtransition_p.h
+ statemachine/qkeyeventtransition.cpp statemachine/qkeyeventtransition.h
+ statemachine/qmouseeventtransition.cpp statemachine/qmouseeventtransition.h
+)
+
+
+qt_create_tracepoints(Widgets qtwidgets.tracepoints)
+qt_add_docs(Widgets
+ doc/qtwidgets.qdocconf
+)
+
diff --git a/src/widgets/CMakeLists.txt b/src/widgets/CMakeLists.txt
new file mode 100644
index 0000000000..35c6c60ae6
--- /dev/null
+++ b/src/widgets/CMakeLists.txt
@@ -0,0 +1,847 @@
+# Generated from widgets.pro.
+
+#####################################################################
+## Widgets Module:
+#####################################################################
+
+qt_add_module(Widgets
+ GENERATE_METATYPES
+ QMAKE_MODULE_CONFIG uic
+ PLUGIN_TYPES styles
+ SOURCES
+ itemviews/qfileiconprovider.cpp itemviews/qfileiconprovider.h itemviews/qfileiconprovider_p.h
+ kernel/qapplication.cpp kernel/qapplication.h kernel/qapplication_p.h
+ kernel/qboxlayout.cpp kernel/qboxlayout.h
+ kernel/qdesktopwidget.cpp kernel/qdesktopwidget.h kernel/qdesktopwidget_p.h
+ kernel/qgesture.cpp kernel/qgesture.h kernel/qgesture_p.h
+ kernel/qgesturemanager.cpp kernel/qgesturemanager_p.h
+ kernel/qgesturerecognizer.cpp kernel/qgesturerecognizer.h
+ kernel/qgridlayout.cpp kernel/qgridlayout.h
+ kernel/qlayout.cpp kernel/qlayout.h kernel/qlayout_p.h
+ kernel/qlayoutengine.cpp kernel/qlayoutengine_p.h
+ kernel/qlayoutitem.cpp kernel/qlayoutitem.h
+ kernel/qsizepolicy.cpp kernel/qsizepolicy.h
+ kernel/qstackedlayout.cpp kernel/qstackedlayout.h
+ kernel/qstandardgestures.cpp kernel/qstandardgestures_p.h
+ kernel/qtestsupport_widgets.cpp kernel/qtestsupport_widgets.h
+ kernel/qtwidgetsglobal.h kernel/qtwidgetsglobal_p.h
+ kernel/qwidget.cpp kernel/qwidget.h kernel/qwidget_p.h
+ kernel/qwidgetrepaintmanager.cpp kernel/qwidgetrepaintmanager_p.h
+ kernel/qwidgetsvariant.cpp
+ kernel/qwidgetwindow.cpp kernel/qwidgetwindow_p.h
+ kernel/qwindowcontainer.cpp kernel/qwindowcontainer_p.h
+ styles/qcommonstyle.cpp styles/qcommonstyle.h styles/qcommonstyle_p.h
+ styles/qcommonstylepixmaps_p.h
+ styles/qdrawutil.cpp styles/qdrawutil.h
+ styles/qpixmapstyle.cpp styles/qpixmapstyle_p.h
+ styles/qpixmapstyle_p_p.h
+ styles/qproxystyle.cpp styles/qproxystyle.h styles/qproxystyle_p.h
+ styles/qstyle.cpp styles/qstyle.h
+ styles/qstylefactory.cpp styles/qstylefactory.h
+ styles/qstylehelper.cpp styles/qstylehelper_p.h
+ styles/qstyleoption.cpp styles/qstyleoption.h
+ styles/qstylepainter.cpp styles/qstylepainter.h
+ styles/qstyleplugin.cpp styles/qstyleplugin.h
+ styles/qstylesheetstyle.cpp styles/qstylesheetstyle_p.h
+ styles/qstylesheetstyle_default.cpp
+ util/qcolormap.cpp util/qcolormap.h
+ util/qsystemtrayicon.cpp util/qsystemtrayicon.h util/qsystemtrayicon_p.h
+ widgets/qabstractscrollarea.cpp widgets/qabstractscrollarea.h widgets/qabstractscrollarea_p.h
+ widgets/qfocusframe.cpp widgets/qfocusframe.h
+ widgets/qframe.cpp widgets/qframe.h widgets/qframe_p.h
+ widgets/qwidgetanimator.cpp widgets/qwidgetanimator_p.h
+ DEFINES
+ QT_NO_USING_NAMESPACE
+ INCLUDE_DIRECTORIES
+ dialogs
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+ PRECOMPILED_HEADER
+ "kernel/qt_widgets_pch.h"
+)
+
+add_dependencies(Widgets ${QT_CMAKE_EXPORT_NAMESPACE}::uic) # special case
+
+# Resources:
+set(qstyle_resource_files
+ "images/cdr-128.png"
+ "images/cdr-16.png"
+ "images/cdr-32.png"
+ "images/cleartext-16.png"
+ "images/cleartext-32.png"
+ "images/closedock-10.png"
+ "images/closedock-16.png"
+ "images/closedock-20.png"
+ "images/closedock-32.png"
+ "images/closedock-48.png"
+ "images/closedock-64.png"
+ "images/computer-16.png"
+ "images/computer-32.png"
+ "images/desktop-16.png"
+ "images/desktop-32.png"
+ "images/dirclosed-128.png"
+ "images/dirclosed-16.png"
+ "images/dirclosed-32.png"
+ "images/dirlink-128.png"
+ "images/dirlink-16.png"
+ "images/dirlink-32.png"
+ "images/diropen-128.png"
+ "images/diropen-16.png"
+ "images/diropen-32.png"
+ "images/down-128.png"
+ "images/down-16.png"
+ "images/down-32.png"
+ "images/dvd-128.png"
+ "images/dvd-16.png"
+ "images/dvd-32.png"
+ "images/file-128.png"
+ "images/file-16.png"
+ "images/file-32.png"
+ "images/filecontents-128.png"
+ "images/filecontents-16.png"
+ "images/filecontents-32.png"
+ "images/fileinfo-128.png"
+ "images/fileinfo-16.png"
+ "images/fileinfo-32.png"
+ "images/filelink-128.png"
+ "images/filelink-16.png"
+ "images/filelink-32.png"
+ "images/floppy-128.png"
+ "images/floppy-16.png"
+ "images/floppy-32.png"
+ "images/fontbitmap-16.png"
+ "images/fonttruetype-16.png"
+ "images/fusion_groupbox.png"
+ "images/harddrive-128.png"
+ "images/harddrive-16.png"
+ "images/harddrive-32.png"
+ "images/left-128.png"
+ "images/left-16.png"
+ "images/left-32.png"
+ "images/media-pause-16.png"
+ "images/media-pause-32.png"
+ "images/media-play-16.png"
+ "images/media-play-32.png"
+ "images/media-seek-backward-16.png"
+ "images/media-seek-backward-32.png"
+ "images/media-seek-forward-16.png"
+ "images/media-seek-forward-32.png"
+ "images/media-skip-backward-16.png"
+ "images/media-skip-backward-32.png"
+ "images/media-skip-forward-16.png"
+ "images/media-skip-forward-32.png"
+ "images/media-stop-16.png"
+ "images/media-stop-32.png"
+ "images/media-volume-16.png"
+ "images/media-volume-muted-16.png"
+ "images/networkdrive-128.png"
+ "images/networkdrive-16.png"
+ "images/networkdrive-32.png"
+ "images/newdirectory-128.png"
+ "images/newdirectory-16.png"
+ "images/newdirectory-32.png"
+ "images/normalizedockup-10.png"
+ "images/normalizedockup-16.png"
+ "images/normalizedockup-20.png"
+ "images/normalizedockup-32.png"
+ "images/normalizedockup-48.png"
+ "images/normalizedockup-64.png"
+ "images/parentdir-128.png"
+ "images/parentdir-16.png"
+ "images/parentdir-32.png"
+ "images/refresh-24.png"
+ "images/refresh-32.png"
+ "images/right-128.png"
+ "images/right-16.png"
+ "images/right-32.png"
+ "images/standardbutton-apply-128.png"
+ "images/standardbutton-apply-16.png"
+ "images/standardbutton-apply-32.png"
+ "images/standardbutton-cancel-128.png"
+ "images/standardbutton-cancel-16.png"
+ "images/standardbutton-cancel-32.png"
+ "images/standardbutton-clear-128.png"
+ "images/standardbutton-clear-16.png"
+ "images/standardbutton-clear-32.png"
+ "images/standardbutton-close-128.png"
+ "images/standardbutton-close-16.png"
+ "images/standardbutton-close-32.png"
+ "images/standardbutton-closetab-16.png"
+ "images/standardbutton-closetab-down-16.png"
+ "images/standardbutton-closetab-hover-16.png"
+ "images/standardbutton-delete-128.png"
+ "images/standardbutton-delete-16.png"
+ "images/standardbutton-delete-32.png"
+ "images/standardbutton-help-128.png"
+ "images/standardbutton-help-16.png"
+ "images/standardbutton-help-32.png"
+ "images/standardbutton-no-128.png"
+ "images/standardbutton-no-16.png"
+ "images/standardbutton-no-32.png"
+ "images/standardbutton-ok-128.png"
+ "images/standardbutton-ok-16.png"
+ "images/standardbutton-ok-32.png"
+ "images/standardbutton-open-128.png"
+ "images/standardbutton-open-16.png"
+ "images/standardbutton-open-32.png"
+ "images/standardbutton-save-128.png"
+ "images/standardbutton-save-16.png"
+ "images/standardbutton-save-32.png"
+ "images/standardbutton-yes-128.png"
+ "images/standardbutton-yes-16.png"
+ "images/standardbutton-yes-32.png"
+ "images/stop-24.png"
+ "images/stop-32.png"
+ "images/titlebar-contexthelp-16.png"
+ "images/titlebar-contexthelp-32.png"
+ "images/titlebar-contexthelp-48.png"
+ "images/titlebar-max-16.png"
+ "images/titlebar-max-32.png"
+ "images/titlebar-max-48.png"
+ "images/titlebar-min-16.png"
+ "images/titlebar-min-32.png"
+ "images/titlebar-min-48.png"
+ "images/titlebar-shade-16.png"
+ "images/titlebar-shade-32.png"
+ "images/titlebar-shade-48.png"
+ "images/titlebar-unshade-16.png"
+ "images/titlebar-unshade-32.png"
+ "images/titlebar-unshade-48.png"
+ "images/toolbar-ext-h-16.png"
+ "images/toolbar-ext-h-32.png"
+ "images/toolbar-ext-h-8.png"
+ "images/toolbar-ext-h-rtl-16.png"
+ "images/toolbar-ext-h-rtl-32.png"
+ "images/toolbar-ext-h-rtl-8.png"
+ "images/toolbar-ext-v-10.png"
+ "images/toolbar-ext-v-20.png"
+ "images/toolbar-ext-v-5.png"
+ "images/trash-128.png"
+ "images/trash-16.png"
+ "images/trash-32.png"
+ "images/up-128.png"
+ "images/up-16.png"
+ "images/up-32.png"
+ "images/viewdetailed-128.png"
+ "images/viewdetailed-16.png"
+ "images/viewdetailed-32.png"
+ "images/viewlist-128.png"
+ "images/viewlist-16.png"
+ "images/viewlist-32.png"
+)
+
+qt_add_resource(Widgets "qstyle"
+ PREFIX
+ "/qt-project.org/styles/commonstyle"
+ BASE
+ "styles"
+ FILES
+ ${qstyle_resource_files}
+)
+set_source_files_properties("styles/images/closedock-down-macstyle-16.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/closedock-down-16.png"
+)
+set_source_files_properties("styles/images/closedock-macstyle-16.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/closedock-16.png"
+)
+set_source_files_properties("styles/images/dockdock-down-macstyle-16.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dockdock-down-16.png"
+)
+set_source_files_properties("styles/images/dockdock-macstyle-16.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dockdock-16.png"
+)
+set_source_files_properties("styles/images/toolbar-ext-macstyle.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/toolbar-ext.png"
+)
+set_source_files_properties("styles/images/toolbar-ext-macstyle@2x.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/toolbar-ext@2x.png"
+)
+set(qstyle1_resource_files
+ "images/closedock-down-macstyle-16.png"
+ "images/closedock-macstyle-16.png"
+ "images/dockdock-down-macstyle-16.png"
+ "images/dockdock-macstyle-16.png"
+ "images/toolbar-ext-macstyle.png"
+ "images/toolbar-ext-macstyle@2x.png"
+)
+
+qt_add_resource(Widgets "qstyle1"
+ PREFIX
+ "/qt-project.org/styles/macstyle"
+ BASE
+ "styles"
+ FILES
+ ${qstyle1_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:widgets.pro:<TRUE>:
+# MODULE_CONFIG = "uic"
+# QMAKE_DYNAMIC_LIST_FILE = "$$PWD/QtWidgets.dynlist"
+# QMAKE_LIBS = "$$QMAKE_LIBS_GUI"
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(Widgets CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x65000000"
+)
+
+qt_extend_target(Widgets CONDITION APPLE_OSX
+ SOURCES
+ kernel/qmacgesturerecognizer.cpp kernel/qmacgesturerecognizer_p.h
+ widgets/qmaccocoaviewcontainer_mac.h widgets/qmaccocoaviewcontainer_mac.mm
+ widgets/qmacnativewidget_mac.h widgets/qmacnativewidget_mac.mm
+ LIBRARIES
+ ${FWAppKit}
+ z
+)
+
+qt_extend_target(Widgets CONDITION WIN32
+ INCLUDE_DIRECTORIES
+ ../3rdparty/wintab
+)
+
+qt_extend_target(Widgets CONDITION WIN32 AND NOT WINRT
+ LIBRARIES
+ dwmapi
+ shell32
+ uxtheme
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_graphicseffect
+ SOURCES
+ effects/qgraphicseffect.cpp effects/qgraphicseffect.h effects/qgraphicseffect_p.h
+ effects/qpixmapfilter.cpp effects/qpixmapfilter_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_action
+ SOURCES
+ kernel/qaction.cpp kernel/qaction.h kernel/qaction_p.h
+ kernel/qactiongroup.cpp kernel/qactiongroup.h
+ kernel/qwidgetaction.cpp kernel/qwidgetaction.h kernel/qwidgetaction_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_opengl
+ SOURCES
+ kernel/qopenglwidget.cpp kernel/qopenglwidget.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_formlayout
+ SOURCES
+ kernel/qformlayout.cpp kernel/qformlayout.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_shortcut
+ SOURCES
+ kernel/qshortcut.cpp kernel/qshortcut.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_tooltip
+ SOURCES
+ kernel/qtooltip.cpp kernel/qtooltip.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_whatsthis
+ SOURCES
+ kernel/qwhatsthis.cpp kernel/qwhatsthis.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_animation
+ SOURCES
+ styles/qstyleanimation.cpp styles/qstyleanimation_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_style_windows
+ SOURCES
+ styles/qwindowsstyle.cpp styles/qwindowsstyle_p.h
+ styles/qwindowsstyle_p_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_style_fusion
+ SOURCES
+ styles/qfusionstyle.cpp styles/qfusionstyle_p.h
+ styles/qfusionstyle_p_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_abstractbutton
+ SOURCES
+ widgets/qabstractbutton.cpp widgets/qabstractbutton.h widgets/qabstractbutton_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_abstractslider
+ SOURCES
+ widgets/qabstractslider.cpp widgets/qabstractslider.h widgets/qabstractslider_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_buttongroup
+ SOURCES
+ widgets/qbuttongroup.cpp widgets/qbuttongroup.h widgets/qbuttongroup_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_calendarwidget
+ SOURCES
+ widgets/qcalendarwidget.cpp widgets/qcalendarwidget.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_checkbox
+ SOURCES
+ widgets/qcheckbox.cpp widgets/qcheckbox.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_combobox
+ SOURCES
+ widgets/qcombobox.cpp widgets/qcombobox.h widgets/qcombobox_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_commandlinkbutton
+ SOURCES
+ widgets/qcommandlinkbutton.cpp widgets/qcommandlinkbutton.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_datetimeedit
+ SOURCES
+ widgets/qdatetimeedit.cpp widgets/qdatetimeedit.h widgets/qdatetimeedit_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_dial
+ SOURCES
+ widgets/qdial.cpp widgets/qdial.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_dockwidget
+ SOURCES
+ widgets/qdockarealayout.cpp widgets/qdockarealayout_p.h
+ widgets/qdockwidget.cpp widgets/qdockwidget.h widgets/qdockwidget_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_effects
+ SOURCES
+ widgets/qeffects.cpp widgets/qeffects_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_fontcombobox
+ SOURCES
+ widgets/qfontcombobox.cpp widgets/qfontcombobox.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_groupbox
+ SOURCES
+ widgets/qgroupbox.cpp widgets/qgroupbox.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_keysequenceedit
+ SOURCES
+ widgets/qkeysequenceedit.cpp widgets/qkeysequenceedit.h widgets/qkeysequenceedit_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_label
+ SOURCES
+ widgets/qlabel.cpp widgets/qlabel.h widgets/qlabel_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_lcdnumber
+ SOURCES
+ widgets/qlcdnumber.cpp widgets/qlcdnumber.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_lineedit
+ SOURCES
+ widgets/qlineedit.cpp widgets/qlineedit.h widgets/qlineedit_p.cpp widgets/qlineedit_p.h
+ widgets/qwidgetlinecontrol.cpp widgets/qwidgetlinecontrol_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_mainwindow
+ SOURCES
+ widgets/qmainwindow.cpp widgets/qmainwindow.h
+ widgets/qmainwindowlayout.cpp widgets/qmainwindowlayout_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_mdiarea
+ SOURCES
+ widgets/qmdiarea.cpp widgets/qmdiarea.h widgets/qmdiarea_p.h
+ widgets/qmdisubwindow.cpp widgets/qmdisubwindow.h widgets/qmdisubwindow_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_menu
+ SOURCES
+ widgets/qmenu.cpp widgets/qmenu.h widgets/qmenu_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_menubar
+ SOURCES
+ widgets/qmenubar.cpp widgets/qmenubar.h widgets/qmenubar_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_progressbar
+ SOURCES
+ widgets/qprogressbar.cpp widgets/qprogressbar.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_pushbutton
+ SOURCES
+ widgets/qpushbutton.cpp widgets/qpushbutton.h widgets/qpushbutton_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_radiobutton
+ SOURCES
+ widgets/qradiobutton.cpp widgets/qradiobutton.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_resizehandler
+ SOURCES
+ widgets/qwidgetresizehandler.cpp widgets/qwidgetresizehandler_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_dialogbuttonbox
+ SOURCES
+ widgets/qdialogbuttonbox.cpp widgets/qdialogbuttonbox.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_rubberband
+ SOURCES
+ widgets/qrubberband.cpp widgets/qrubberband.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_scrollarea
+ SOURCES
+ widgets/qscrollarea.cpp widgets/qscrollarea.h widgets/qscrollarea_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_scrollbar
+ SOURCES
+ widgets/qscrollbar.cpp widgets/qscrollbar.h widgets/qscrollbar_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_sizegrip
+ SOURCES
+ widgets/qsizegrip.cpp widgets/qsizegrip.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_slider
+ SOURCES
+ widgets/qslider.cpp widgets/qslider.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_spinbox
+ SOURCES
+ widgets/qabstractspinbox.cpp widgets/qabstractspinbox.h widgets/qabstractspinbox_p.h
+ widgets/qspinbox.cpp widgets/qspinbox.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_splashscreen
+ SOURCES
+ widgets/qsplashscreen.cpp widgets/qsplashscreen.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_splitter
+ SOURCES
+ widgets/qsplitter.cpp widgets/qsplitter.h widgets/qsplitter_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_stackedwidget
+ SOURCES
+ widgets/qstackedwidget.cpp widgets/qstackedwidget.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_statusbar
+ SOURCES
+ widgets/qstatusbar.cpp widgets/qstatusbar.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_tabbar
+ SOURCES
+ widgets/qtabbar.cpp widgets/qtabbar.h widgets/qtabbar_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_textedit
+ SOURCES
+ widgets/qplaintextedit.cpp widgets/qplaintextedit.h widgets/qplaintextedit_p.h
+ widgets/qtextedit.cpp widgets/qtextedit.h widgets/qtextedit_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_textbrowser
+ SOURCES
+ widgets/qtextbrowser.cpp widgets/qtextbrowser.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_tabwidget
+ SOURCES
+ widgets/qtabwidget.cpp widgets/qtabwidget.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_toolbar
+ SOURCES
+ widgets/qtoolbar.cpp widgets/qtoolbar.h widgets/qtoolbar_p.h
+ widgets/qtoolbararealayout.cpp widgets/qtoolbararealayout_p.h
+ widgets/qtoolbarlayout.cpp widgets/qtoolbarlayout_p.h
+ widgets/qtoolbarseparator.cpp widgets/qtoolbarseparator_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_toolbox
+ SOURCES
+ widgets/qtoolbox.cpp widgets/qtoolbox.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_toolbutton
+ SOURCES
+ widgets/qtoolbarextension.cpp widgets/qtoolbarextension_p.h
+ widgets/qtoolbutton.cpp widgets/qtoolbutton.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_widgettextcontrol
+ SOURCES
+ widgets/qwidgettextcontrol.cpp widgets/qwidgettextcontrol_p.h
+ widgets/qwidgettextcontrol_p_p.h
+)
+
+qt_extend_target(Widgets CONDITION APPLE_OSX AND (QT_FEATURE_menu OR QT_FEATURE_menubar)
+ SOURCES
+ widgets/qmenu_mac.mm
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_colordialog
+ SOURCES
+ dialogs/qcolordialog.cpp dialogs/qcolordialog.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_dialog
+ SOURCES
+ dialogs/qdialog.cpp dialogs/qdialog.h dialogs/qdialog_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_errormessage
+ SOURCES
+ dialogs/qerrormessage.cpp dialogs/qerrormessage.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_filedialog
+ SOURCES
+ dialogs/qfiledialog.cpp dialogs/qfiledialog.h dialogs/qfiledialog.ui dialogs/qfiledialog_p.h
+ dialogs/qsidebar.cpp dialogs/qsidebar_p.h
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_filesystemmodel
+ SOURCES
+ dialogs/qfileinfogatherer.cpp dialogs/qfileinfogatherer_p.h
+ dialogs/qfilesystemmodel.cpp dialogs/qfilesystemmodel.h dialogs/qfilesystemmodel_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_fontdialog
+ SOURCES
+ dialogs/qfontdialog.cpp dialogs/qfontdialog.h dialogs/qfontdialog_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_fscompleter
+ SOURCES
+ dialogs/qfscompleter_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_inputdialog
+ SOURCES
+ dialogs/qinputdialog.cpp dialogs/qinputdialog.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_messagebox
+ SOURCES
+ dialogs/qmessagebox.cpp dialogs/qmessagebox.h
+)
+
+if(QT_FEATURE_messagebox)
+ # Resources:
+ set(qmessagebox_resource_files
+ "images/qtlogo-64.png"
+ )
+
+ qt_add_resource(Widgets "qmessagebox"
+ PREFIX
+ "/qt-project.org/qmessagebox"
+ BASE
+ "dialogs"
+ FILES
+ ${qmessagebox_resource_files}
+ )
+endif()
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_progressdialog
+ SOURCES
+ dialogs/qprogressdialog.cpp dialogs/qprogressdialog.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_wizard
+ SOURCES
+ dialogs/qwizard.cpp dialogs/qwizard.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_wizard AND WIN32
+ SOURCES
+ dialogs/qwizard_win.cpp dialogs/qwizard_win_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_accessibility
+ SOURCES
+ accessible/complexwidgets.cpp accessible/complexwidgets_p.h
+ accessible/qaccessiblemenu.cpp accessible/qaccessiblemenu_p.h
+ accessible/qaccessiblewidget.cpp accessible/qaccessiblewidget.h
+ accessible/qaccessiblewidgetfactory.cpp accessible/qaccessiblewidgetfactory_p.h
+ accessible/qaccessiblewidgets.cpp accessible/qaccessiblewidgets_p.h
+ accessible/rangecontrols.cpp accessible/rangecontrols_p.h
+ accessible/simplewidgets.cpp accessible/simplewidgets_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_accessibility AND QT_FEATURE_itemviews
+ SOURCES
+ accessible/itemviews.cpp accessible/itemviews_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_itemviews
+ SOURCES
+ itemviews/qabstractitemdelegate.cpp itemviews/qabstractitemdelegate.h itemviews/qabstractitemdelegate_p.h
+ itemviews/qabstractitemview.cpp itemviews/qabstractitemview.h itemviews/qabstractitemview_p.h
+ itemviews/qbsptree.cpp itemviews/qbsptree_p.h
+ itemviews/qheaderview.cpp itemviews/qheaderview.h itemviews/qheaderview_p.h
+ itemviews/qitemdelegate.cpp itemviews/qitemdelegate.h
+ itemviews/qitemeditorfactory.cpp itemviews/qitemeditorfactory.h itemviews/qitemeditorfactory_p.h
+ itemviews/qstyleditemdelegate.cpp itemviews/qstyleditemdelegate.h
+ itemviews/qwidgetitemdata_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_columnview
+ SOURCES
+ itemviews/qcolumnview.cpp itemviews/qcolumnview.h itemviews/qcolumnview_p.h
+ itemviews/qcolumnviewgrip.cpp itemviews/qcolumnviewgrip_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_datawidgetmapper
+ SOURCES
+ itemviews/qdatawidgetmapper.cpp itemviews/qdatawidgetmapper.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_dirmodel
+ SOURCES
+ itemviews/qdirmodel.cpp itemviews/qdirmodel.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_listview
+ SOURCES
+ itemviews/qlistview.cpp itemviews/qlistview.h itemviews/qlistview_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_listwidget
+ SOURCES
+ itemviews/qlistwidget.cpp itemviews/qlistwidget.h itemviews/qlistwidget_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_tableview
+ SOURCES
+ itemviews/qtableview.cpp itemviews/qtableview.h itemviews/qtableview_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_tablewidget
+ SOURCES
+ itemviews/qtablewidget.cpp itemviews/qtablewidget.h itemviews/qtablewidget_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_treeview
+ SOURCES
+ itemviews/qtreeview.cpp itemviews/qtreeview.h itemviews/qtreeview_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_treewidget
+ SOURCES
+ itemviews/qtreewidget.cpp itemviews/qtreewidget.h itemviews/qtreewidget_p.h
+ itemviews/qtreewidgetitemiterator.cpp itemviews/qtreewidgetitemiterator.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_graphicsview
+ SOURCES
+ graphicsview/qgraph_p.h
+ graphicsview/qgraphicsanchorlayout.cpp graphicsview/qgraphicsanchorlayout.h graphicsview/qgraphicsanchorlayout_p.cpp graphicsview/qgraphicsanchorlayout_p.h
+ graphicsview/qgraphicsgridlayout.cpp graphicsview/qgraphicsgridlayout.h
+ graphicsview/qgraphicsgridlayoutengine.cpp graphicsview/qgraphicsgridlayoutengine_p.h
+ graphicsview/qgraphicsitem.cpp graphicsview/qgraphicsitem.h graphicsview/qgraphicsitem_p.h
+ graphicsview/qgraphicslayout.cpp graphicsview/qgraphicslayout.h graphicsview/qgraphicslayout_p.cpp graphicsview/qgraphicslayout_p.h
+ graphicsview/qgraphicslayoutitem.cpp graphicsview/qgraphicslayoutitem.h graphicsview/qgraphicslayoutitem_p.h
+ graphicsview/qgraphicslayoutstyleinfo.cpp graphicsview/qgraphicslayoutstyleinfo_p.h
+ graphicsview/qgraphicslinearlayout.cpp graphicsview/qgraphicslinearlayout.h
+ graphicsview/qgraphicsproxywidget.cpp graphicsview/qgraphicsproxywidget.h graphicsview/qgraphicsproxywidget_p.h
+ graphicsview/qgraphicsscene.cpp graphicsview/qgraphicsscene.h graphicsview/qgraphicsscene_p.h
+ graphicsview/qgraphicsscene_bsp.cpp graphicsview/qgraphicsscene_bsp_p.h
+ graphicsview/qgraphicsscenebsptreeindex.cpp graphicsview/qgraphicsscenebsptreeindex_p.h
+ graphicsview/qgraphicssceneevent.cpp graphicsview/qgraphicssceneevent.h
+ graphicsview/qgraphicssceneindex.cpp graphicsview/qgraphicssceneindex_p.h
+ graphicsview/qgraphicsscenelinearindex.cpp graphicsview/qgraphicsscenelinearindex_p.h
+ graphicsview/qgraphicstransform.cpp graphicsview/qgraphicstransform.h graphicsview/qgraphicstransform_p.h
+ graphicsview/qgraphicsview.cpp graphicsview/qgraphicsview.h graphicsview/qgraphicsview_p.h
+ graphicsview/qgraphicswidget.cpp graphicsview/qgraphicswidget.h graphicsview/qgraphicswidget_p.cpp graphicsview/qgraphicswidget_p.h
+ graphicsview/qsimplex_p.cpp graphicsview/qsimplex_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_easingcurve AND QT_FEATURE_graphicsview
+ SOURCES
+ graphicsview/qgraphicsitemanimation.cpp graphicsview/qgraphicsitemanimation.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_completer
+ SOURCES
+ util/qcompleter.cpp util/qcompleter.h util/qcompleter_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_scroller
+ SOURCES
+ util/qflickgesture.cpp util/qflickgesture_p.h
+ util/qscroller.cpp util/qscroller.h util/qscroller_p.h
+ util/qscrollerproperties.cpp util/qscrollerproperties.h util/qscrollerproperties_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_undocommand
+ SOURCES
+ util/qundostack.cpp util/qundostack.h util/qundostack_p.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_undogroup
+ SOURCES
+ util/qundogroup.cpp util/qundogroup.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_undoview
+ SOURCES
+ util/qundoview.cpp util/qundoview.h
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_xcb
+ SOURCES
+ util/qsystemtrayicon_x11.cpp
+)
+
+qt_extend_target(Widgets CONDITION NOT QT_FEATURE_xcb
+ SOURCES
+ util/qsystemtrayicon_qpa.cpp
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_statemachine
+ SOURCES
+ statemachine/qguistatemachine.cpp
+)
+
+qt_extend_target(Widgets CONDITION QT_FEATURE_qeventtransition
+ SOURCES
+ statemachine/qbasickeyeventtransition.cpp statemachine/qbasickeyeventtransition_p.h
+ statemachine/qbasicmouseeventtransition.cpp statemachine/qbasicmouseeventtransition_p.h
+ statemachine/qkeyeventtransition.cpp statemachine/qkeyeventtransition.h
+ statemachine/qmouseeventtransition.cpp statemachine/qmouseeventtransition.h
+)
+
+
+qt_create_tracepoints(Widgets qtwidgets.tracepoints)
+qt_add_docs(Widgets
+ doc/qtwidgets.qdocconf
+)
+
diff --git a/src/widgets/Qt5WidgetsConfigExtras.cmake.in b/src/widgets/Qt5WidgetsConfigExtras.cmake.in
deleted file mode 100644
index 99d87e2e46..0000000000
--- a/src/widgets/Qt5WidgetsConfigExtras.cmake.in
+++ /dev/null
@@ -1,19 +0,0 @@
-
-if (NOT TARGET Qt5::uic)
- add_executable(Qt5::uic IMPORTED)
-
-!!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Widgets_install_prefix}/$${CMAKE_BIN_DIR}uic$$CMAKE_BIN_SUFFIX\")
-!!ELSE
- set(imported_location \"$${CMAKE_BIN_DIR}uic$$CMAKE_BIN_SUFFIX\")
-!!ENDIF
- _qt5_Widgets_check_file_exists(${imported_location})
-
- set_target_properties(Qt5::uic PROPERTIES
- IMPORTED_LOCATION ${imported_location}
- )
-endif()
-
-include(\"${CMAKE_CURRENT_LIST_DIR}/Qt5Widgets_AccessibleFactory.cmake\" OPTIONAL)
-
-set(Qt5Widgets_UIC_EXECUTABLE Qt5::uic)
diff --git a/src/widgets/Qt5WidgetsMacros.cmake b/src/widgets/Qt6WidgetsMacros.cmake
index 21e73d4f0c..f996b66519 100644
--- a/src/widgets/Qt5WidgetsMacros.cmake
+++ b/src/widgets/Qt6WidgetsMacros.cmake
@@ -56,7 +56,7 @@ function(qt5_wrap_ui outfiles )
get_filename_component(infile ${it} ABSOLUTE)
set(outfile ${CMAKE_CURRENT_BINARY_DIR}/ui_${outfile}.h)
add_custom_command(OUTPUT ${outfile}
- COMMAND ${Qt5Widgets_UIC_EXECUTABLE}
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::uic
ARGS ${ui_options} -o ${outfile} ${infile}
MAIN_DEPENDENCY ${infile} VERBATIM)
set_source_files_properties(${infile} PROPERTIES SKIP_AUTOUIC ON)
diff --git a/src/widgets/configure.cmake b/src/widgets/configure.cmake
new file mode 100644
index 0000000000..c508e2dbf4
--- /dev/null
+++ b/src/widgets/configure.cmake
@@ -0,0 +1,563 @@
+
+
+#### Inputs
+
+
+
+#### Libraries
+
+qt_find_package(GTK3 PROVIDED_TARGETS PkgConfig::GTK3)
+
+
+#### Tests
+
+
+
+#### Features
+
+qt_feature("gtk3" PRIVATE
+ LABEL "GTK+"
+ AUTODETECT NOT APPLE
+ CONDITION QT_FEATURE_glib AND GTK3_FOUND
+)
+qt_feature("style-fusion" PRIVATE
+ LABEL "Fusion"
+)
+qt_feature("style-mac" PRIVATE
+ LABEL "macOS"
+ CONDITION APPLE_OSX AND QT_FEATURE_animation
+)
+qt_feature("style-windows" PRIVATE
+ LABEL "Windows"
+)
+qt_feature("style-windowsvista" PRIVATE
+ LABEL "WindowsVista"
+ CONDITION QT_FEATURE_style_windows AND QT_FEATURE_animation AND WIN32 AND NOT WINRT AND tests.uxtheme OR FIXME
+)
+qt_feature("style-android" PRIVATE
+ LABEL "Android"
+ AUTODETECT ANDROID
+)
+qt_feature("style-stylesheet" PUBLIC
+ SECTION "Styles"
+ LABEL "QStyleSheetStyle"
+ PURPOSE "Provides a widget style which is configurable via CSS."
+ CONDITION QT_FEATURE_style_windows AND QT_FEATURE_properties AND QT_FEATURE_cssparser
+)
+qt_feature_definition("style-stylesheet" "QT_NO_STYLE_STYLESHEET" NEGATE VALUE "1")
+qt_feature("effects" PRIVATE
+ SECTION "Kernel"
+ LABEL "Effects"
+ PURPOSE "Provides special widget effects (e.g. fading and scrolling)."
+)
+qt_feature("filesystemmodel" PUBLIC
+ SECTION "File I/O"
+ LABEL "QFileSystemModel"
+ PURPOSE "Provides a data model for the local filesystem."
+ CONDITION QT_FEATURE_itemmodel
+)
+qt_feature_definition("filesystemmodel" "QT_NO_FILESYSTEMMODEL" NEGATE VALUE "1")
+qt_feature("itemviews" PUBLIC
+ SECTION "ItemViews"
+ LABEL "The Model/View Framework"
+ PURPOSE "Provides the model/view architecture managing the relationship between data and the way it is presented to the user."
+ CONDITION QT_FEATURE_itemmodel AND QT_FEATURE_scrollarea
+)
+qt_feature_definition("itemviews" "QT_NO_ITEMVIEWS" NEGATE VALUE "1")
+qt_feature("treewidget" PUBLIC
+ SECTION "Widgets"
+ LABEL "QTreeWidget"
+ PURPOSE "Provides views using tree models."
+ CONDITION QT_FEATURE_treeview
+)
+qt_feature_definition("treewidget" "QT_NO_TREEWIDGET" NEGATE VALUE "1")
+qt_feature("listwidget" PUBLIC
+ SECTION "Widgets"
+ LABEL "QListWidget"
+ PURPOSE "Provides item-based list widgets."
+ CONDITION QT_FEATURE_listview
+)
+qt_feature_definition("listwidget" "QT_NO_LISTWIDGET" NEGATE VALUE "1")
+qt_feature("tablewidget" PUBLIC
+ SECTION "Widgets"
+ LABEL "QTableWidget"
+ PURPOSE "Provides item-based table views."
+ CONDITION QT_FEATURE_tableview
+)
+qt_feature_definition("tablewidget" "QT_NO_TABLEWIDGET" NEGATE VALUE "1")
+qt_feature("abstractbutton" PUBLIC
+ SECTION "Widgets"
+ LABEL "QAbstractButton"
+ PURPOSE "Abstract base class of button widgets, providing functionality common to buttons."
+)
+qt_feature("commandlinkbutton" PUBLIC
+ SECTION "Widgets"
+ LABEL "QCommandLinkButton"
+ PURPOSE "Provides a Vista style command link button."
+ CONDITION QT_FEATURE_pushbutton
+)
+qt_feature("datetimeedit" PUBLIC
+ SECTION "Widgets"
+ LABEL "QDateTimeEdit"
+ PURPOSE "Supports editing dates and times."
+ CONDITION QT_FEATURE_calendarwidget AND QT_FEATURE_datestring AND QT_FEATURE_textdate AND QT_FEATURE_datetimeparser
+)
+qt_feature_definition("datetimeedit" "QT_NO_DATETIMEEDIT" NEGATE VALUE "1")
+qt_feature("stackedwidget" PUBLIC
+ SECTION "Widgets"
+ LABEL "QStackedWidget"
+ PURPOSE "Provides stacked widgets."
+)
+qt_feature_definition("stackedwidget" "QT_NO_STACKEDWIDGET" NEGATE VALUE "1")
+qt_feature("textbrowser" PUBLIC
+ SECTION "Widgets"
+ LABEL "QTextBrowser"
+ PURPOSE "Supports HTML document browsing."
+ CONDITION QT_FEATURE_textedit
+)
+qt_feature_definition("textbrowser" "QT_NO_TEXTBROWSER" NEGATE VALUE "1")
+qt_feature("splashscreen" PUBLIC
+ SECTION "Widgets"
+ LABEL "QSplashScreen"
+ PURPOSE "Supports splash screens that can be shown during application startup."
+)
+qt_feature_definition("splashscreen" "QT_NO_SPLASHSCREEN" NEGATE VALUE "1")
+qt_feature("splitter" PUBLIC
+ SECTION "Widgets"
+ LABEL "QSplitter"
+ PURPOSE "Provides user controlled splitter widgets."
+)
+qt_feature_definition("splitter" "QT_NO_SPLITTER" NEGATE VALUE "1")
+qt_feature("widgettextcontrol" PRIVATE
+ SECTION "Widgets"
+ LABEL "QWidgetTextControl"
+ PURPOSE "Provides text control functionality to other widgets."
+)
+qt_feature("label" PUBLIC
+ SECTION "Widgets"
+ LABEL "QLabel"
+ PURPOSE "Provides a text or image display."
+ CONDITION QT_FEATURE_widgettextcontrol
+)
+qt_feature("formlayout" PUBLIC
+ SECTION "Widgets"
+ LABEL "QFormLayout"
+ PURPOSE "Manages forms of input widgets and their associated labels."
+ CONDITION QT_FEATURE_label
+)
+qt_feature("lcdnumber" PUBLIC
+ SECTION "Widgets"
+ LABEL "QLCDNumber"
+ PURPOSE "Provides LCD-like digits."
+)
+qt_feature_definition("lcdnumber" "QT_NO_LCDNUMBER" NEGATE VALUE "1")
+qt_feature("menu" PUBLIC
+ SECTION "Widgets"
+ LABEL "QMenu"
+ PURPOSE "Provides popup-menus."
+ CONDITION QT_FEATURE_action AND QT_FEATURE_pushbutton
+)
+qt_feature_definition("menu" "QT_NO_MENU" NEGATE VALUE "1")
+qt_feature("lineedit" PUBLIC
+ SECTION "Widgets"
+ LABEL "QLineEdit"
+ PURPOSE "Provides single-line edits."
+ CONDITION QT_FEATURE_widgettextcontrol
+)
+qt_feature_definition("lineedit" "QT_NO_LINEEDIT" NEGATE VALUE "1")
+qt_feature("radiobutton" PUBLIC
+ SECTION "Widgets"
+ LABEL "QRadioButton"
+ PURPOSE "Provides a radio button with a text label."
+ CONDITION QT_FEATURE_abstractbutton
+)
+qt_feature("spinbox" PUBLIC
+ SECTION "Widgets"
+ LABEL "QSpinBox"
+ PURPOSE "Provides spin boxes handling integers and discrete sets of values."
+ CONDITION QT_FEATURE_lineedit AND QT_FEATURE_validator
+)
+qt_feature_definition("spinbox" "QT_NO_SPINBOX" NEGATE VALUE "1")
+qt_feature("tabbar" PUBLIC
+ SECTION "Widgets"
+ LABEL "QTabBar"
+ PURPOSE "Provides tab bars, e.g., for use in tabbed dialogs."
+ CONDITION QT_FEATURE_toolbutton
+)
+qt_feature_definition("tabbar" "QT_NO_TABBAR" NEGATE VALUE "1")
+qt_feature("tabwidget" PUBLIC
+ SECTION "Widgets"
+ LABEL "QTabWidget"
+ PURPOSE "Supports stacking tabbed widgets."
+ CONDITION QT_FEATURE_tabbar AND QT_FEATURE_stackedwidget
+)
+qt_feature_definition("tabwidget" "QT_NO_TABWIDGET" NEGATE VALUE "1")
+qt_feature("combobox" PUBLIC
+ SECTION "Widgets"
+ LABEL "QComboBox"
+ PURPOSE "Provides drop-down boxes presenting a list of options to the user."
+ CONDITION QT_FEATURE_lineedit AND QT_FEATURE_standarditemmodel AND QT_FEATURE_listview
+)
+qt_feature_definition("combobox" "QT_NO_COMBOBOX" NEGATE VALUE "1")
+qt_feature("fontcombobox" PUBLIC
+ SECTION "Widgets"
+ LABEL "QFontComboBox"
+ PURPOSE "Provides a combobox that lets the user select a font family."
+ CONDITION QT_FEATURE_combobox AND QT_FEATURE_stringlistmodel
+)
+qt_feature_definition("fontcombobox" "QT_NO_FONTCOMBOBOX" NEGATE VALUE "1")
+qt_feature("checkbox" PUBLIC
+ SECTION "Widgets"
+ LABEL "QCheckBox("
+ PURPOSE "Provides a checkbox with a text label."
+ CONDITION QT_FEATURE_abstractbutton
+)
+qt_feature("pushbutton" PUBLIC
+ SECTION "Widgets"
+ LABEL "QPushButton"
+ PURPOSE "Provides a command button."
+ CONDITION QT_FEATURE_abstractbutton AND QT_FEATURE_action
+)
+qt_feature("toolbutton" PUBLIC
+ SECTION "Widgets"
+ LABEL "QToolButton"
+ PURPOSE "Provides quick-access buttons to commands and options."
+ CONDITION QT_FEATURE_abstractbutton AND QT_FEATURE_action
+)
+qt_feature_definition("toolbutton" "QT_NO_TOOLBUTTON" NEGATE VALUE "1")
+qt_feature("toolbar" PUBLIC
+ SECTION "Widgets"
+ LABEL "QToolBar"
+ PURPOSE "Provides movable panels containing a set of controls."
+ CONDITION QT_FEATURE_mainwindow
+)
+qt_feature_definition("toolbar" "QT_NO_TOOLBAR" NEGATE VALUE "1")
+qt_feature("toolbox" PUBLIC
+ SECTION "Widgets"
+ LABEL "QToolBox"
+ PURPOSE "Provides columns of tabbed widget items."
+ CONDITION QT_FEATURE_toolbutton AND QT_FEATURE_scrollarea
+)
+qt_feature_definition("toolbox" "QT_NO_TOOLBOX" NEGATE VALUE "1")
+qt_feature("groupbox" PUBLIC
+ SECTION "Widgets"
+ LABEL "QGroupBox"
+ PURPOSE "Provides widget grouping boxes with frames."
+)
+qt_feature_definition("groupbox" "QT_NO_GROUPBOX" NEGATE VALUE "1")
+qt_feature("buttongroup" PUBLIC
+ SECTION "Widgets"
+ LABEL "QButtonGroup"
+ PURPOSE "Supports organizing groups of button widgets."
+ CONDITION QT_FEATURE_abstractbutton AND QT_FEATURE_groupbox
+)
+qt_feature_definition("buttongroup" "QT_NO_BUTTONGROUP" NEGATE VALUE "1")
+qt_feature("mainwindow" PUBLIC
+ SECTION "Widgets"
+ LABEL "QMainWindow"
+ PURPOSE "Provides main application windows."
+ CONDITION QT_FEATURE_menu AND QT_FEATURE_resizehandler AND QT_FEATURE_toolbutton
+)
+qt_feature_definition("mainwindow" "QT_NO_MAINWINDOW" NEGATE VALUE "1")
+qt_feature("dockwidget" PUBLIC
+ SECTION "Widgets"
+ LABEL "QDockwidget"
+ PURPOSE "Supports docking widgets inside a QMainWindow or floated as a top-level window on the desktop."
+ CONDITION QT_FEATURE_mainwindow
+)
+qt_feature_definition("dockwidget" "QT_NO_DOCKWIDGET" NEGATE VALUE "1")
+qt_feature("mdiarea" PUBLIC
+ SECTION "Widgets"
+ LABEL "QMdiArea"
+ PURPOSE "Provides an area in which MDI windows are displayed."
+ CONDITION QT_FEATURE_scrollarea
+)
+qt_feature_definition("mdiarea" "QT_NO_MDIAREA" NEGATE VALUE "1")
+qt_feature("resizehandler" PUBLIC
+ SECTION "Widgets"
+ LABEL "QWidgetResizeHandler"
+ PURPOSE "Provides an internal resize handler for dock widgets."
+)
+qt_feature_definition("resizehandler" "QT_NO_RESIZEHANDLER" NEGATE VALUE "1")
+qt_feature("statusbar" PUBLIC
+ SECTION "Widgets"
+ LABEL "QStatusBar"
+ PURPOSE "Supports presentation of status information."
+)
+qt_feature_definition("statusbar" "QT_NO_STATUSBAR" NEGATE VALUE "1")
+qt_feature("menubar" PUBLIC
+ SECTION "Widgets"
+ LABEL "QMenuBar"
+ PURPOSE "Provides pull-down menu items."
+ CONDITION QT_FEATURE_menu AND QT_FEATURE_toolbutton
+)
+qt_feature_definition("menubar" "QT_NO_MENUBAR" NEGATE VALUE "1")
+qt_feature("contextmenu" PUBLIC
+ SECTION "Widgets"
+ LABEL "Context menus"
+ PURPOSE "Adds pop-up menus on right mouse click to numerous widgets."
+ CONDITION QT_FEATURE_menu
+)
+qt_feature_definition("contextmenu" "QT_NO_CONTEXTMENU" NEGATE VALUE "1")
+qt_feature("progressbar" PUBLIC
+ SECTION "Widgets"
+ LABEL "QProgressBar"
+ PURPOSE "Supports presentation of operation progress."
+)
+qt_feature_definition("progressbar" "QT_NO_PROGRESSBAR" NEGATE VALUE "1")
+qt_feature("abstractslider" PUBLIC
+ SECTION "Widgets"
+ LABEL "QAbstractSlider"
+ PURPOSE "Common super class for widgets like QScrollBar, QSlider and QDial."
+)
+qt_feature("slider" PUBLIC
+ SECTION "Widgets"
+ LABEL "QSlider"
+ PURPOSE "Provides sliders controlling a bounded value."
+ CONDITION QT_FEATURE_abstractslider
+)
+qt_feature_definition("slider" "QT_NO_SLIDER" NEGATE VALUE "1")
+qt_feature("scrollbar" PUBLIC
+ SECTION "Widgets"
+ LABEL "QScrollBar"
+ PURPOSE "Provides scrollbars allowing the user access parts of a document that is larger than the widget used to display it."
+ CONDITION QT_FEATURE_slider
+)
+qt_feature_definition("scrollbar" "QT_NO_SCROLLBAR" NEGATE VALUE "1")
+qt_feature("dial" PUBLIC
+ SECTION "Widgets"
+ LABEL "QDial"
+ PURPOSE "Provides a rounded range control, e.g., like a speedometer."
+ CONDITION QT_FEATURE_slider
+)
+qt_feature_definition("dial" "QT_NO_DIAL" NEGATE VALUE "1")
+qt_feature("scrollarea" PUBLIC
+ SECTION "Widgets"
+ LABEL "QScrollArea"
+ PURPOSE "Supports scrolling views onto widgets."
+ CONDITION QT_FEATURE_scrollbar
+)
+qt_feature_definition("scrollarea" "QT_NO_SCROLLAREA" NEGATE VALUE "1")
+qt_feature("scroller" PUBLIC
+ SECTION "Widgets"
+ LABEL "QScroller"
+ PURPOSE "Enables kinetic scrolling for any scrolling widget or graphics item."
+ CONDITION QT_FEATURE_easingcurve
+)
+qt_feature("graphicsview" PUBLIC
+ SECTION "Widgets"
+ LABEL "QGraphicsView"
+ PURPOSE "Provides a canvas/sprite framework."
+ CONDITION QT_FEATURE_scrollarea AND QT_FEATURE_widgettextcontrol
+)
+qt_feature_definition("graphicsview" "QT_NO_GRAPHICSVIEW" NEGATE VALUE "1")
+qt_feature("graphicseffect" PUBLIC
+ SECTION "Widgets"
+ LABEL "QGraphicsEffect"
+ PURPOSE "Provides various graphics effects."
+ CONDITION QT_FEATURE_graphicsview
+)
+qt_feature_definition("graphicseffect" "QT_NO_GRAPHICSEFFECT" NEGATE VALUE "1")
+qt_feature("textedit" PUBLIC
+ SECTION "Widgets"
+ LABEL "QTextEdit"
+ PURPOSE "Supports rich text editing."
+ CONDITION QT_FEATURE_scrollarea AND QT_FEATURE_properties AND QT_FEATURE_widgettextcontrol
+)
+qt_feature_definition("textedit" "QT_NO_TEXTEDIT" NEGATE VALUE "1")
+qt_feature("syntaxhighlighter" PUBLIC
+ SECTION "Widgets"
+ LABEL "QSyntaxHighlighter"
+ PURPOSE "Supports custom syntax highlighting."
+ CONDITION QT_FEATURE_textedit
+)
+qt_feature_definition("syntaxhighlighter" "QT_NO_SYNTAXHIGHLIGHTER" NEGATE VALUE "1")
+qt_feature("rubberband" PUBLIC
+ SECTION "Widgets"
+ LABEL "QRubberBand"
+ PURPOSE "Supports using rubberbands to indicate selections and boundaries."
+)
+qt_feature_definition("rubberband" "QT_NO_RUBBERBAND" NEGATE VALUE "1")
+qt_feature("tooltip" PUBLIC
+ SECTION "Widgets"
+ LABEL "QToolTip"
+ PURPOSE "Supports presentation of tooltips."
+ CONDITION QT_FEATURE_label
+)
+qt_feature_definition("tooltip" "QT_NO_TOOLTIP" NEGATE VALUE "1")
+qt_feature("statustip" PUBLIC
+ SECTION "Widgets"
+ LABEL "Status Tip"
+ PURPOSE "Supports status tip functionality and events."
+)
+qt_feature_definition("statustip" "QT_NO_STATUSTIP" NEGATE VALUE "1")
+qt_feature("sizegrip" PUBLIC
+ SECTION "Widgets"
+ LABEL "QSizeGrip"
+ PURPOSE "Provides corner-grips for resizing top-level windows."
+)
+qt_feature_definition("sizegrip" "QT_NO_SIZEGRIP" NEGATE VALUE "1")
+qt_feature("calendarwidget" PUBLIC
+ SECTION "Widgets"
+ LABEL "QCalendarWidget"
+ PURPOSE "Provides a monthly based calendar widget allowing the user to select a date."
+ CONDITION ( QT_FEATURE_label ) AND ( QT_FEATURE_menu ) AND ( QT_FEATURE_pushbutton ) AND ( QT_FEATURE_spinbox ) AND ( QT_FEATURE_tableview ) AND ( QT_FEATURE_textdate ) AND ( QT_FEATURE_toolbutton )
+)
+qt_feature_definition("calendarwidget" "QT_NO_CALENDARWIDGET" NEGATE VALUE "1")
+qt_feature("keysequenceedit" PUBLIC
+ SECTION "Widgets"
+ LABEL "QKeySequenceEdit"
+ PURPOSE "Provides a widget for editing QKeySequences."
+ CONDITION QT_FEATURE_lineedit AND QT_FEATURE_shortcut
+)
+qt_feature_definition("keysequenceedit" "QT_NO_KEYSEQUENCEEDIT" NEGATE VALUE "1")
+qt_feature("dialog" PUBLIC
+ SECTION "Dialogs"
+ LABEL "QDialog"
+ PURPOSE "Base class of dialog windows."
+)
+qt_feature("dialogbuttonbox" PUBLIC
+ SECTION "Dialogs"
+ LABEL "QDialogButtonBox"
+ PURPOSE "Presents buttons in a layout that is appropriate for the current widget style."
+ CONDITION QT_FEATURE_dialog AND QT_FEATURE_pushbutton
+)
+qt_feature("messagebox" PUBLIC
+ SECTION "Dialogs"
+ LABEL "QMessageBox"
+ PURPOSE "Provides message boxes displaying informative messages and simple questions."
+ CONDITION ( QT_FEATURE_checkbox ) AND ( QT_FEATURE_dialog ) AND ( QT_FEATURE_dialogbuttonbox ) AND ( QT_FEATURE_label ) AND ( QT_FEATURE_pushbutton )
+)
+qt_feature_definition("messagebox" "QT_NO_MESSAGEBOX" NEGATE VALUE "1")
+qt_feature("colordialog" PUBLIC
+ SECTION "Dialogs"
+ LABEL "QColorDialog"
+ PURPOSE "Provides a dialog widget for specifying colors."
+ CONDITION ( QT_FEATURE_dialog ) AND ( QT_FEATURE_dialogbuttonbox ) AND ( QT_FEATURE_label ) AND ( QT_FEATURE_pushbutton ) AND ( QT_FEATURE_spinbox )
+)
+qt_feature_definition("colordialog" "QT_NO_COLORDIALOG" NEGATE VALUE "1")
+qt_feature("filedialog" PUBLIC
+ SECTION "Dialogs"
+ LABEL "QFileDialog"
+ PURPOSE "Provides a dialog widget for selecting files or directories."
+ CONDITION ( QT_FEATURE_buttongroup ) AND ( QT_FEATURE_combobox ) AND ( QT_FEATURE_dialog ) AND ( QT_FEATURE_dialogbuttonbox ) AND ( QT_FEATURE_dirmodel ) AND ( QT_FEATURE_label ) AND ( QT_FEATURE_proxymodel ) AND ( QT_FEATURE_splitter ) AND ( QT_FEATURE_stackedwidget ) AND ( QT_FEATURE_treeview ) AND ( QT_FEATURE_toolbutton )
+)
+qt_feature_definition("filedialog" "QT_NO_FILEDIALOG" NEGATE VALUE "1")
+qt_feature("fontdialog" PUBLIC
+ SECTION "Dialogs"
+ LABEL "QFontDialog"
+ PURPOSE "Provides a dialog widget for selecting fonts."
+ CONDITION ( QT_FEATURE_checkbox ) AND ( QT_FEATURE_combobox ) AND ( QT_FEATURE_dialog ) AND ( QT_FEATURE_dialogbuttonbox ) AND ( QT_FEATURE_groupbox ) AND ( QT_FEATURE_label ) AND ( QT_FEATURE_pushbutton ) AND ( QT_FEATURE_stringlistmodel ) AND ( QT_FEATURE_validator )
+)
+qt_feature_definition("fontdialog" "QT_NO_FONTDIALOG" NEGATE VALUE "1")
+qt_feature("progressdialog" PUBLIC
+ SECTION "Dialogs"
+ LABEL "QProgressDialog"
+ PURPOSE "Provides feedback on the progress of a slow operation."
+ CONDITION ( QT_FEATURE_dialog ) AND ( QT_FEATURE_label ) AND ( QT_FEATURE_pushbutton ) AND ( QT_FEATURE_progressbar )
+)
+qt_feature_definition("progressdialog" "QT_NO_PROGRESSDIALOG" NEGATE VALUE "1")
+qt_feature("inputdialog" PUBLIC
+ SECTION "Dialogs"
+ LABEL "QInputDialog"
+ PURPOSE "Provides a simple convenience dialog to get a single value from the user."
+ CONDITION ( QT_FEATURE_combobox ) AND ( QT_FEATURE_dialog ) AND ( QT_FEATURE_dialogbuttonbox ) AND ( QT_FEATURE_label ) AND ( QT_FEATURE_pushbutton ) AND ( QT_FEATURE_spinbox ) AND ( QT_FEATURE_stackedwidget ) AND ( QT_FEATURE_textedit )
+)
+qt_feature_definition("inputdialog" "QT_NO_INPUTDIALOG" NEGATE VALUE "1")
+qt_feature("errormessage" PUBLIC
+ SECTION "Dialogs"
+ LABEL "QErrorMessage"
+ PURPOSE "Provides an error message display dialog."
+ CONDITION ( QT_FEATURE_checkbox ) AND ( QT_FEATURE_dialog ) AND ( QT_FEATURE_textedit ) AND ( QT_FEATURE_label ) AND ( QT_FEATURE_pushbutton ) AND ( QT_FEATURE_textedit )
+)
+qt_feature_definition("errormessage" "QT_NO_ERRORMESSAGE" NEGATE VALUE "1")
+qt_feature("wizard" PUBLIC
+ SECTION "Dialogs"
+ LABEL "QWizard"
+ PURPOSE "Provides a framework for multi-page click-through dialogs."
+ CONDITION ( QT_FEATURE_dialog ) AND ( QT_FEATURE_pushbutton ) AND ( QT_FEATURE_properties ) AND ( QT_FEATURE_label )
+)
+qt_feature_definition("wizard" "QT_NO_WIZARD" NEGATE VALUE "1")
+qt_feature("dirmodel" PUBLIC
+ SECTION "ItemViews"
+ LABEL "QDirModel"
+ PURPOSE "Provides a data model for the local filesystem."
+ CONDITION QT_FEATURE_itemviews AND QT_FEATURE_filesystemmodel
+)
+qt_feature_definition("dirmodel" "QT_NO_DIRMODEL" NEGATE VALUE "1")
+qt_feature("listview" PUBLIC
+ SECTION "ItemViews"
+ LABEL "QListView"
+ PURPOSE "Provides a list or icon view onto a model."
+ CONDITION QT_FEATURE_itemviews
+)
+qt_feature_definition("listview" "QT_NO_LISTVIEW" NEGATE VALUE "1")
+qt_feature("tableview" PUBLIC
+ SECTION "ItemViews"
+ LABEL "QTableView"
+ PURPOSE "Provides a default model/view implementation of a table view."
+ CONDITION QT_FEATURE_itemviews
+)
+qt_feature_definition("tableview" "QT_NO_TABLEVIEW" NEGATE VALUE "1")
+qt_feature("treeview" PUBLIC
+ SECTION "ItemViews"
+ LABEL "QTreeView"
+ PURPOSE "Provides a default model/view implementation of a tree view."
+ CONDITION QT_FEATURE_itemviews
+)
+qt_feature_definition("treeview" "QT_NO_TREEVIEW" NEGATE VALUE "1")
+qt_feature("datawidgetmapper" PUBLIC
+ SECTION "ItemViews"
+ LABEL "QDataWidgetMapper"
+ PURPOSE "Provides mapping between a section of a data model to widgets."
+ CONDITION QT_FEATURE_itemviews AND QT_FEATURE_properties
+)
+qt_feature_definition("datawidgetmapper" "QT_NO_DATAWIDGETMAPPER" NEGATE VALUE "1")
+qt_feature("columnview" PUBLIC
+ SECTION "ItemViews"
+ LABEL "QColumnView"
+ PURPOSE "Provides a model/view implementation of a column view."
+ CONDITION QT_FEATURE_listview
+)
+qt_feature_definition("columnview" "QT_NO_COLUMNVIEW" NEGATE VALUE "1")
+qt_feature("completer" PUBLIC
+ SECTION "Utilities"
+ LABEL "QCompleter"
+ PURPOSE "Provides completions based on an item model."
+ CONDITION QT_FEATURE_proxymodel AND QT_FEATURE_itemviews
+)
+qt_feature_definition("completer" "QT_NO_COMPLETER" NEGATE VALUE "1")
+qt_feature("fscompleter" PUBLIC
+ SECTION "Utilities"
+ LABEL "QFSCompleter"
+ PURPOSE "Provides file name completion in QFileDialog."
+ CONDITION QT_FEATURE_filesystemmodel AND QT_FEATURE_completer
+)
+qt_feature_definition("fscompleter" "QT_NO_FSCOMPLETER" NEGATE VALUE "1")
+qt_feature("undocommand" PUBLIC
+ SECTION "Utilities"
+ LABEL "QUndoCommand"
+ PURPOSE "Applies (redo or) undo of a single change in a document."
+)
+qt_feature_definition("undocommand" "QT_NO_UNDOCOMMAND" NEGATE VALUE "1")
+qt_feature("undostack" PUBLIC
+ SECTION "Utilities"
+ LABEL "QUndoStack"
+ PURPOSE "Provides the ability to (redo or) undo a list of changes in a document."
+ CONDITION QT_FEATURE_undocommand
+)
+qt_feature_definition("undostack" "QT_NO_UNDOSTACK" NEGATE VALUE "1")
+qt_feature("undogroup" PUBLIC
+ SECTION "Utilities"
+ LABEL "QUndoGroup"
+ PURPOSE "Provides the ability to cluster QUndoCommands."
+ CONDITION QT_FEATURE_undostack
+)
+qt_feature_definition("undogroup" "QT_NO_UNDOGROUP" NEGATE VALUE "1")
+qt_feature("undoview" PUBLIC
+ SECTION "Utilities"
+ LABEL "QUndoView"
+ PURPOSE "Provides a widget which shows the contents of an undo stack."
+ CONDITION QT_FEATURE_undostack AND QT_FEATURE_listview
+)
+qt_feature_definition("undoview" "QT_NO_UNDOVIEW" NEGATE VALUE "1")
diff --git a/src/winmain/.prev_CMakeLists.txt b/src/winmain/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..a6077dd467
--- /dev/null
+++ b/src/winmain/.prev_CMakeLists.txt
@@ -0,0 +1,48 @@
+# Generated from winmain.pro.
+
+#####################################################################
+## qtLibraryTarget$$TARGET$$QT_LIBINFIX Module:
+#####################################################################
+
+add_qt_module(qtLibraryTarget$$TARGET$$QT_LIBINFIX
+ STATIC
+ DEFINES
+ QT_NO_FOREACH
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:winmain.pro:<TRUE>:
+# CONFIG = "static"
+# DESTDIR = "$$QT.core.libs"
+# TEMPLATE = "lib"
+# _LOADED = "qt_installs" "qt_targets" "qt_build_paths" "qt_common"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:winmain.pro:QT_FEATURE_debug_and_release:
+# CONFIG = "build_all"
+
+#### Keys ignored in scope 4:.:.:winmain.pro:MSVC:
+# QMAKE_CFLAGS_DEBUG = "--Zi" "-Z7"
+
+extend_target(qtLibraryTarget$$TARGET$$QT_LIBINFIX CONDITION mingw
+ DEFINES
+ QT_NEEDS_QMAIN
+)
+
+extend_target(qtLibraryTarget$$TARGET$$QT_LIBINFIX CONDITION WINRT
+ SOURCES
+ qtmain_winrt.cpp
+)
+
+extend_target(qtLibraryTarget$$TARGET$$QT_LIBINFIX CONDITION NOT WINRT
+ SOURCES
+ qtmain_win.cpp
+ LIBRARIES
+ shell32
+)
+
+#### Keys ignored in scope 10:.:.:winmain.pro:else:
+# CONFIG = "-qt"
diff --git a/src/winmain/CMakeLists.txt b/src/winmain/CMakeLists.txt
new file mode 100644
index 0000000000..fb48fec5a3
--- /dev/null
+++ b/src/winmain/CMakeLists.txt
@@ -0,0 +1,28 @@
+# special case begin
+# special case skip regeneration
+if (NOT WIN32)
+ return()
+endif()
+
+qt_add_module(WinMain
+ STATIC
+ NO_SYNC_QT
+ NO_MODULE_HEADERS
+ DEFINES
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ $<TARGET_PROPERTY:Qt::Core,INTERFACE_INCLUDE_DIRECTORIES>
+)
+
+qt_extend_target(WinMain CONDITION WINRT
+ SOURCES qtmain_winrt.cpp
+)
+
+qt_extend_target(WinMain CONDITION NOT WINRT
+ SOURCES qtmain_win.cpp
+)
+
+qt_extend_target(WinMain CONDITION MINGW
+ DEFINES QT_NEEDS_QMAIN
+)
+# special case end
diff --git a/src/xml/CMakeLists.txt b/src/xml/CMakeLists.txt
new file mode 100644
index 0000000000..52bca5c3c4
--- /dev/null
+++ b/src/xml/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from xml.pro.
+
+#####################################################################
+## Xml Module:
+#####################################################################
+
+qt_add_module(Xml
+ SOURCES
+ dom/qdom.cpp dom/qdom.h dom/qdom_p.h
+ dom/qdomhelpers.cpp dom/qdomhelpers_p.h
+ qtxmlglobal.h
+ sax/qxml.cpp sax/qxml.h sax/qxml_p.h
+ DEFINES
+ QT_NO_FOREACH
+ QT_NO_USING_NAMESPACE
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+## Scopes:
+#####################################################################
+
+qt_extend_target(Xml CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x61000000"
+)
+qt_add_docs(Xml
+ doc/qtxml.qdocconf
+)
+
diff --git a/src/xml/configure.cmake b/src/xml/configure.cmake
new file mode 100644
index 0000000000..25a7de5aa2
--- /dev/null
+++ b/src/xml/configure.cmake
@@ -0,0 +1,22 @@
+
+
+#### Inputs
+
+
+
+#### Libraries
+
+
+
+#### Tests
+
+
+
+#### Features
+
+qt_feature("dom" PUBLIC
+ SECTION "File I/O"
+ LABEL "DOM"
+ PURPOSE "Supports the Document Object Model."
+)
+qt_feature_definition("dom" "QT_NO_DOM" NEGATE VALUE "1")
diff --git a/tests/.prev_CMakeLists.txt b/tests/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..221413713e
--- /dev/null
+++ b/tests/.prev_CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from tests.pro.
+
+if(QT_BUILD_STANDALONE_TESTS)
+ # Add qt_find_package calls for extra dependencies that need to be found when building
+ # the standalone tests here.
+endif()
+qt_build_tests()
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
new file mode 100644
index 0000000000..d1a395c9f3
--- /dev/null
+++ b/tests/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from tests.pro.
+
+if(QT_BUILD_STANDALONE_TESTS)
+ # Add qt_find_package calls for extra dependencies that need to be found when building
+ # the standalone tests here.
+ # special case begin
+ qt_find_package(WrapDBus1 PROVIDED_TARGETS dbus-1)
+ qt_find_package(ICU COMPONENTS i18n uc data PROVIDED_TARGETS ICU::i18n ICU::uc ICU::data)
+ qt_find_package(Threads PROVIDED_TARGETS Threads::Threads)
+ qt_find_package(OpenSSL PROVIDED_TARGETS OpenSSL::OpenSSL)
+ # special case end
+endif()
+qt_build_tests()
diff --git a/tests/auto/CMakeLists.txt b/tests/auto/CMakeLists.txt
new file mode 100644
index 0000000000..c03838bee1
--- /dev/null
+++ b/tests/auto/CMakeLists.txt
@@ -0,0 +1,62 @@
+# Generated from auto.pro.
+
+add_subdirectory(corelib)
+if (QT_FEATURE_dbus)
+ set(run_dbus_tests ON)
+ if(NOT CMAKE_CROSSCOMPILING AND TARGET Qt::DBus)
+ execute_process(COMMAND dbus-send --session --type=signal / local.AutotestCheck.Hello
+ RESULT_VARIABLE dbus_session_test
+ OUTPUT_QUIET ERROR_QUIET)
+ if(NOT "${dbus_session_test}" STREQUAL "0")
+ set(run_dbus_tests OFF)
+ if(QT_FEATURE_dbus_linked)
+ message(SEND_ERROR "QtDBus is enabled but session bus is not available for testing. Please check the installation.")
+ else()
+ message(WARNING "QtDBus is enabled with runtime support, but session bus is not available. Skipping QtDBus tests.")
+ endif()
+ endif()
+ endif()
+ if(run_dbus_tests)
+ add_subdirectory(dbus)
+ endif()
+endif()
+if (TARGET Qt::Gui)
+ add_subdirectory(gui)
+endif()
+
+# special case begin
+# Build only corelib and gui tests when targeting uikit (iOS),
+# because the script can't handle the SUBDIRS assignment well.
+if (APPLE_UIKIT)
+ return()
+endif()
+# special case end
+
+if (TARGET Qt::Network AND NOT WINRT)
+ add_subdirectory(network)
+endif()
+if (TARGET Qt::OpenGL AND NOT WINRT)
+ add_subdirectory(opengl)
+endif()
+if (TARGET Qt::Sql)
+ add_subdirectory(sql)
+endif()
+add_subdirectory(testlib)
+if (NOT CMAKE_CROSSCOMPILE AND QT_FEATURE_process)
+ add_subdirectory(tools)
+endif()
+if (TARGET Qt::Xml)
+ add_subdirectory(xml)
+endif()
+if (TARGET Qt::Concurrent)
+ add_subdirectory(concurrent)
+endif()
+add_subdirectory(other)
+if (TARGET Qt::Widgets)
+ add_subdirectory(widgets)
+endif()
+if (TARGET Qt::PrintSupport)
+ add_subdirectory(printsupport)
+endif()
+# add_subdirectory(cmake) ## FIXME: Does this still make sense in this form?
+# add_subdirectory(installed_cmake) ## FIXME: Does this still make sense in this form?
diff --git a/tests/auto/concurrent/CMakeLists.txt b/tests/auto/concurrent/CMakeLists.txt
new file mode 100644
index 0000000000..ae1e256bbd
--- /dev/null
+++ b/tests/auto/concurrent/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from concurrent.pro.
+
+add_subdirectory(qtconcurrentfilter)
+add_subdirectory(qtconcurrentiteratekernel)
+add_subdirectory(qtconcurrentmap)
+add_subdirectory(qtconcurrentmedian)
+add_subdirectory(qtconcurrentrun)
+add_subdirectory(qtconcurrentthreadengine)
diff --git a/tests/auto/concurrent/qtconcurrentfilter/.prev_CMakeLists.txt b/tests/auto/concurrent/qtconcurrentfilter/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..62b0308851
--- /dev/null
+++ b/tests/auto/concurrent/qtconcurrentfilter/.prev_CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qtconcurrentfilter.pro.
+
+#####################################################################
+## tst_qtconcurrentfilter Test:
+#####################################################################
+
+add_qt_test(tst_qtconcurrentfilter
+ SOURCES
+ tst_qtconcurrentfilter.cpp
+ DEFINES
+ -QT_NO_LINKED_LIST
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
diff --git a/tests/auto/concurrent/qtconcurrentfilter/CMakeLists.txt b/tests/auto/concurrent/qtconcurrentfilter/CMakeLists.txt
new file mode 100644
index 0000000000..9da443a3f9
--- /dev/null
+++ b/tests/auto/concurrent/qtconcurrentfilter/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtconcurrentfilter.pro.
+
+#####################################################################
+## tst_qtconcurrentfilter Test:
+#####################################################################
+
+add_qt_test(tst_qtconcurrentfilter
+ SOURCES
+ tst_qtconcurrentfilter.cpp
+ DEFINES
+ # -QT_NO_LINKED_LIST # special case remove until figured out how to deal with this
+ QT_STRICT_ITERATORS
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
diff --git a/tests/auto/concurrent/qtconcurrentiteratekernel/CMakeLists.txt b/tests/auto/concurrent/qtconcurrentiteratekernel/CMakeLists.txt
new file mode 100644
index 0000000000..af44d66642
--- /dev/null
+++ b/tests/auto/concurrent/qtconcurrentiteratekernel/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qtconcurrentiteratekernel.pro.
+
+#####################################################################
+## tst_qtconcurrentiteratekernel Test:
+#####################################################################
+
+add_qt_test(tst_qtconcurrentiteratekernel
+ SOURCES
+ tst_qtconcurrentiteratekernel.cpp
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
diff --git a/tests/auto/concurrent/qtconcurrentmap/.prev_CMakeLists.txt b/tests/auto/concurrent/qtconcurrentmap/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..be51bf09bd
--- /dev/null
+++ b/tests/auto/concurrent/qtconcurrentmap/.prev_CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qtconcurrentmap.pro.
+
+#####################################################################
+## tst_qtconcurrentmap Test:
+#####################################################################
+
+add_qt_test(tst_qtconcurrentmap
+ SOURCES
+ tst_qtconcurrentmap.cpp
+ DEFINES
+ -QT_NO_LINKED_LIST
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/concurrent/qtconcurrentmap/CMakeLists.txt b/tests/auto/concurrent/qtconcurrentmap/CMakeLists.txt
new file mode 100644
index 0000000000..8ae79db0cf
--- /dev/null
+++ b/tests/auto/concurrent/qtconcurrentmap/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qtconcurrentmap.pro.
+
+#####################################################################
+## tst_qtconcurrentmap Test:
+#####################################################################
+
+add_qt_test(tst_qtconcurrentmap
+ SOURCES
+ tst_qtconcurrentmap.cpp
+ DEFINES
+ # -QT_NO_LINKED_LIST # special case remove until we figure this out
+ QT_STRICT_ITERATORS
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/concurrent/qtconcurrentmedian/CMakeLists.txt b/tests/auto/concurrent/qtconcurrentmedian/CMakeLists.txt
new file mode 100644
index 0000000000..27b376a406
--- /dev/null
+++ b/tests/auto/concurrent/qtconcurrentmedian/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qtconcurrentmedian.pro.
+
+#####################################################################
+## tst_qtconcurrentmedian Test:
+#####################################################################
+
+add_qt_test(tst_qtconcurrentmedian
+ SOURCES
+ tst_qtconcurrentmedian.cpp
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
diff --git a/tests/auto/concurrent/qtconcurrentrun/CMakeLists.txt b/tests/auto/concurrent/qtconcurrentrun/CMakeLists.txt
new file mode 100644
index 0000000000..ca1f616137
--- /dev/null
+++ b/tests/auto/concurrent/qtconcurrentrun/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtconcurrentrun.pro.
+
+#####################################################################
+## tst_qtconcurrentrun Test:
+#####################################################################
+
+add_qt_test(tst_qtconcurrentrun
+ SOURCES
+ tst_qtconcurrentrun.cpp
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/concurrent/qtconcurrentthreadengine/CMakeLists.txt b/tests/auto/concurrent/qtconcurrentthreadengine/CMakeLists.txt
new file mode 100644
index 0000000000..e9384c4fb4
--- /dev/null
+++ b/tests/auto/concurrent/qtconcurrentthreadengine/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qtconcurrentthreadengine.pro.
+
+#####################################################################
+## tst_qtconcurrentthreadengine Test:
+#####################################################################
+
+add_qt_test(tst_qtconcurrentthreadengine
+ SOURCES
+ tst_qtconcurrentthreadengine.cpp
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
diff --git a/tests/auto/corelib/.prev_CMakeLists.txt b/tests/auto/corelib/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..1029b14654
--- /dev/null
+++ b/tests/auto/corelib/.prev_CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from corelib.pro.
+
+add_subdirectory(kernel)
+if(NOT APPLE_UIKIT)
+ add_subdirectory(animation)
+ add_subdirectory(codecs)
+ add_subdirectory(global)
+ add_subdirectory(io)
+ add_subdirectory(itemmodels)
+ add_subdirectory(mimetypes)
+ add_subdirectory(plugin)
+ add_subdirectory(serialization)
+ add_subdirectory(statemachine)
+ add_subdirectory(text)
+ add_subdirectory(thread)
+ add_subdirectory(time)
+ add_subdirectory(tools)
+endif()
diff --git a/tests/auto/corelib/CMakeLists.txt b/tests/auto/corelib/CMakeLists.txt
new file mode 100644
index 0000000000..1029b14654
--- /dev/null
+++ b/tests/auto/corelib/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from corelib.pro.
+
+add_subdirectory(kernel)
+if(NOT APPLE_UIKIT)
+ add_subdirectory(animation)
+ add_subdirectory(codecs)
+ add_subdirectory(global)
+ add_subdirectory(io)
+ add_subdirectory(itemmodels)
+ add_subdirectory(mimetypes)
+ add_subdirectory(plugin)
+ add_subdirectory(serialization)
+ add_subdirectory(statemachine)
+ add_subdirectory(text)
+ add_subdirectory(thread)
+ add_subdirectory(time)
+ add_subdirectory(tools)
+endif()
diff --git a/tests/auto/corelib/animation/CMakeLists.txt b/tests/auto/corelib/animation/CMakeLists.txt
new file mode 100644
index 0000000000..ed238bb4f7
--- /dev/null
+++ b/tests/auto/corelib/animation/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_subdirectory(qabstractanimation)
+add_subdirectory(qanimationgroup)
+add_subdirectory(qparallelanimationgroup)
+add_subdirectory(qpauseanimation)
+add_subdirectory(qsequentialanimationgroup)
+add_subdirectory(qvariantanimation)
diff --git a/tests/auto/corelib/animation/qabstractanimation/CMakeLists.txt b/tests/auto/corelib/animation/qabstractanimation/CMakeLists.txt
new file mode 100644
index 0000000000..d5f4a9a016
--- /dev/null
+++ b/tests/auto/corelib/animation/qabstractanimation/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qabstractanimation.pro.
+
+#####################################################################
+## tst_qabstractanimation Test:
+#####################################################################
+
+add_qt_test(tst_qabstractanimation
+ SOURCES
+ tst_qabstractanimation.cpp
+)
diff --git a/tests/auto/corelib/animation/qanimationgroup/CMakeLists.txt b/tests/auto/corelib/animation/qanimationgroup/CMakeLists.txt
new file mode 100644
index 0000000000..9b165f7983
--- /dev/null
+++ b/tests/auto/corelib/animation/qanimationgroup/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qanimationgroup.pro.
+
+#####################################################################
+## tst_qanimationgroup Test:
+#####################################################################
+
+add_qt_test(tst_qanimationgroup
+ SOURCES
+ tst_qanimationgroup.cpp
+)
diff --git a/tests/auto/corelib/animation/qparallelanimationgroup/CMakeLists.txt b/tests/auto/corelib/animation/qparallelanimationgroup/CMakeLists.txt
new file mode 100644
index 0000000000..376c9351bd
--- /dev/null
+++ b/tests/auto/corelib/animation/qparallelanimationgroup/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qparallelanimationgroup.pro.
+
+#####################################################################
+## tst_qparallelanimationgroup Test:
+#####################################################################
+
+add_qt_test(tst_qparallelanimationgroup
+ SOURCES
+ tst_qparallelanimationgroup.cpp
+)
diff --git a/tests/auto/corelib/animation/qpauseanimation/CMakeLists.txt b/tests/auto/corelib/animation/qpauseanimation/CMakeLists.txt
new file mode 100644
index 0000000000..93e3f43f9b
--- /dev/null
+++ b/tests/auto/corelib/animation/qpauseanimation/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qpauseanimation.pro.
+
+#####################################################################
+## tst_qpauseanimation Test:
+#####################################################################
+
+add_qt_test(tst_qpauseanimation
+ SOURCES
+ tst_qpauseanimation.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/animation/qsequentialanimationgroup/CMakeLists.txt b/tests/auto/corelib/animation/qsequentialanimationgroup/CMakeLists.txt
new file mode 100644
index 0000000000..a3381b06b0
--- /dev/null
+++ b/tests/auto/corelib/animation/qsequentialanimationgroup/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qsequentialanimationgroup.pro.
+
+#####################################################################
+## tst_qsequentialanimationgroup Test:
+#####################################################################
+
+add_qt_test(tst_qsequentialanimationgroup
+ SOURCES
+ tst_qsequentialanimationgroup.cpp
+)
diff --git a/tests/auto/corelib/animation/qvariantanimation/CMakeLists.txt b/tests/auto/corelib/animation/qvariantanimation/CMakeLists.txt
new file mode 100644
index 0000000000..1c5f9bd03b
--- /dev/null
+++ b/tests/auto/corelib/animation/qvariantanimation/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qvariantanimation.pro.
+
+#####################################################################
+## tst_qvariantanimation Test:
+#####################################################################
+
+add_qt_test(tst_qvariantanimation
+ SOURCES
+ tst_qvariantanimation.cpp
+)
diff --git a/tests/auto/corelib/codecs/CMakeLists.txt b/tests/auto/corelib/codecs/CMakeLists.txt
new file mode 100644
index 0000000000..272b19f5f8
--- /dev/null
+++ b/tests/auto/corelib/codecs/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_subdirectory(qtextcodec)
+add_subdirectory(utf8)
+
diff --git a/tests/auto/corelib/codecs/qtextcodec/CMakeLists.txt b/tests/auto/corelib/codecs/qtextcodec/CMakeLists.txt
new file mode 100644
index 0000000000..09b46eaa1d
--- /dev/null
+++ b/tests/auto/corelib/codecs/qtextcodec/CMakeLists.txt
@@ -0,0 +1,5 @@
+add_qt_test(tst_qtextcodec SOURCES tst_qtextcodec.cpp)
+
+if(UNIX)
+ add_subdirectory(echo)
+endif()
diff --git a/tests/auto/corelib/codecs/qtextcodec/echo/CMakeLists.txt b/tests/auto/corelib/codecs/qtextcodec/echo/CMakeLists.txt
new file mode 100644
index 0000000000..fc63473cbc
--- /dev/null
+++ b/tests/auto/corelib/codecs/qtextcodec/echo/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from echo.pro.
+
+#####################################################################
+## echo_helper Binary:
+#####################################################################
+
+add_qt_test_helper(echo_helper
+ SOURCES
+ main.cpp
+)
diff --git a/tests/auto/corelib/codecs/utf8/CMakeLists.txt b/tests/auto/corelib/codecs/utf8/CMakeLists.txt
new file mode 100644
index 0000000000..1f794d63d0
--- /dev/null
+++ b/tests/auto/corelib/codecs/utf8/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from utf8.pro.
+
+#####################################################################
+## tst_utf8 Test:
+#####################################################################
+
+add_qt_test(tst_utf8
+ SOURCES
+ tst_utf8.cpp
+ utf8data.cpp
+)
diff --git a/tests/auto/corelib/global/CMakeLists.txt b/tests/auto/corelib/global/CMakeLists.txt
new file mode 100644
index 0000000000..58e083d665
--- /dev/null
+++ b/tests/auto/corelib/global/CMakeLists.txt
@@ -0,0 +1,12 @@
+add_subdirectory(q_func_info)
+add_subdirectory(qflags)
+add_subdirectory(qfloat16)
+add_subdirectory(qgetputenv)
+add_subdirectory(qglobalstatic)
+add_subdirectory(qhooks)
+add_subdirectory(qlogging)
+add_subdirectory(qnumeric)
+add_subdirectory(qrand)
+add_subdirectory(qrandomgenerator)
+add_subdirectory(qtendian)
+
diff --git a/tests/auto/corelib/global/q_func_info/CMakeLists.txt b/tests/auto/corelib/global/q_func_info/CMakeLists.txt
new file mode 100644
index 0000000000..5435c97cf8
--- /dev/null
+++ b/tests/auto/corelib/global/q_func_info/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from q_func_info.pro.
+
+#####################################################################
+## tst_q_func_info Test:
+#####################################################################
+
+add_qt_test(tst_q_func_info
+ SOURCES
+ tst_q_func_info.cpp
+)
diff --git a/tests/auto/corelib/global/qflags/CMakeLists.txt b/tests/auto/corelib/global/qflags/CMakeLists.txt
new file mode 100644
index 0000000000..f1fdb7a5f8
--- /dev/null
+++ b/tests/auto/corelib/global/qflags/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qflags.pro.
+
+#####################################################################
+## tst_qflags Test:
+#####################################################################
+
+add_qt_test(tst_qflags
+ SOURCES
+ tst_qflags.cpp
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/global/qfloat16/CMakeLists.txt b/tests/auto/corelib/global/qfloat16/CMakeLists.txt
new file mode 100644
index 0000000000..36e15d8225
--- /dev/null
+++ b/tests/auto/corelib/global/qfloat16/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qfloat16.pro.
+
+#####################################################################
+## tst_qfloat16 Test:
+#####################################################################
+
+add_qt_test(tst_qfloat16
+ SOURCES
+ tst_qfloat16.cpp
+)
diff --git a/tests/auto/corelib/global/qgetputenv/CMakeLists.txt b/tests/auto/corelib/global/qgetputenv/CMakeLists.txt
new file mode 100644
index 0000000000..c5f3a53810
--- /dev/null
+++ b/tests/auto/corelib/global/qgetputenv/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qgetputenv.pro.
+
+#####################################################################
+## tst_qgetputenv Test:
+#####################################################################
+
+add_qt_test(tst_qgetputenv
+ SOURCES
+ tst_qgetputenv.cpp
+)
diff --git a/tests/auto/corelib/global/qglobal/CMakeLists.txt b/tests/auto/corelib/global/qglobal/CMakeLists.txt
new file mode 100644
index 0000000000..1efaaa71d0
--- /dev/null
+++ b/tests/auto/corelib/global/qglobal/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qglobal.pro.
+
+#####################################################################
+## tst_qglobal Test:
+#####################################################################
+
+add_qt_test(tst_qglobal
+ SOURCES
+ qglobal.c
+ tst_qglobal.cpp
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/global/qglobalstatic/CMakeLists.txt b/tests/auto/corelib/global/qglobalstatic/CMakeLists.txt
new file mode 100644
index 0000000000..1486256a94
--- /dev/null
+++ b/tests/auto/corelib/global/qglobalstatic/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qglobalstatic.pro.
+
+#####################################################################
+## tst_qglobalstatic Test:
+#####################################################################
+
+add_qt_test(tst_qglobalstatic
+ EXCEPTIONS
+ SOURCES
+ tst_qglobalstatic.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/global/qhooks/CMakeLists.txt b/tests/auto/corelib/global/qhooks/CMakeLists.txt
new file mode 100644
index 0000000000..01b3196bd1
--- /dev/null
+++ b/tests/auto/corelib/global/qhooks/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qhooks.pro.
+
+#####################################################################
+## tst_qhooks Test:
+#####################################################################
+
+add_qt_test(tst_qhooks
+ SOURCES
+ tst_qhooks.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/global/qlogging/CMakeLists.txt b/tests/auto/corelib/global/qlogging/CMakeLists.txt
new file mode 100644
index 0000000000..bd0ab6aeca
--- /dev/null
+++ b/tests/auto/corelib/global/qlogging/CMakeLists.txt
@@ -0,0 +1,25 @@
+if(NOT WINRT)
+ add_qt_executable(qlogging_helper
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES app/main.cpp
+ DEFINES QT_MESSAGELOGCONTEXT
+ LIBRARIES Qt::Core)
+
+ #special case begin
+ # Fixes required for the backtrace stack to be correct
+ if (${CMAKE_CXX_COMPILER_ID} STREQUAL "GNU")
+ target_link_options(qlogging_helper PRIVATE -rdynamic)
+ endif()
+ set_target_properties(qlogging_helper PROPERTIES CXX_VISIBILITY_PRESET default)
+ # special case end
+endif()
+
+add_qt_test(tst_qlogging SOURCES tst_qlogging.cpp
+ DEFINES
+ QT_MESSAGELOGCONTEXT
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ HELPER_BINARY="${CMAKE_CURRENT_BINARY_DIR}/qlogging_helper" # special case
+)
+
+target_compile_definitions(tst_qlogging PRIVATE QT_CMAKE_BUILD) # special case # to fix the binary name
diff --git a/tests/auto/corelib/global/qlogging/test/test.pro b/tests/auto/corelib/global/qlogging/test/test.pro
index 91896d4494..81445247e0 100644
--- a/tests/auto/corelib/global/qlogging/test/test.pro
+++ b/tests/auto/corelib/global/qlogging/test/test.pro
@@ -19,3 +19,4 @@ SOURCES = ../tst_qlogging.cpp
DEFINES += QT_MESSAGELOGCONTEXT
DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
+DEFINES += HELPER_BINARY=\\\"helper\\\"
diff --git a/tests/auto/corelib/global/qlogging/tst_qlogging.cpp b/tests/auto/corelib/global/qlogging/tst_qlogging.cpp
index 3af637d13a..6c6f3a2168 100644
--- a/tests/auto/corelib/global/qlogging/tst_qlogging.cpp
+++ b/tests/auto/corelib/global/qlogging/tst_qlogging.cpp
@@ -792,10 +792,17 @@ void tst_qmessagehandler::qMessagePattern_data()
#define QT_NAMESPACE_STR ""
#endif
+
+#ifdef QT_CMAKE_BUILD
+#define BACKTRACE_HELPER_NAME "qlogging_helper"
+#else
+#define BACKTRACE_HELPER_NAME "helper"
+#endif
+
#ifndef QT_NO_DEBUG
QTest::newRow("backtrace") << "[%{backtrace}] %{message}" << true << (QList<QByteArray>()
// MyClass::qt_static_metacall is explicitly marked as hidden in the Q_OBJECT macro
- << "[MyClass::myFunction|MyClass::mySlot1|?helper?|" QT_NAMESPACE_STR "QMetaMethod::invoke|" QT_NAMESPACE_STR "QMetaObject::invokeMethod] from_a_function 34");
+ << "[MyClass::myFunction|MyClass::mySlot1|?" BACKTRACE_HELPER_NAME "?|" QT_NAMESPACE_STR "QMetaMethod::invoke|" QT_NAMESPACE_STR "QMetaObject::invokeMethod] from_a_function 34");
#endif
QTest::newRow("backtrace depth,separator") << "[%{backtrace depth=2 separator=\"\n\"}] %{message}" << true << (QList<QByteArray>()
@@ -820,9 +827,9 @@ void tst_qmessagehandler::qMessagePattern()
QProcess process;
#ifndef Q_OS_ANDROID
- const QString appExe(QLatin1String("helper"));
+ const QString appExe(QLatin1String(HELPER_BINARY));
#else
- const QString appExe(QCoreApplication::applicationDirPath() + QLatin1String("/libhelper.so"));
+ const QString appExe(QCoreApplication::applicationDirPath() + QLatin1String("/lib" BACKTRACE_HELPER_NAME ".so"));
#endif
//
@@ -870,7 +877,7 @@ void tst_qmessagehandler::setMessagePattern()
QProcess process;
#ifndef Q_OS_ANDROID
- const QString appExe(QLatin1String("helper"));
+ const QString appExe(QLatin1String(HELPER_BINARY));
#else
const QString appExe(QCoreApplication::applicationDirPath() + QLatin1String("/libhelper.so"));
#endif
diff --git a/tests/auto/corelib/global/qnumeric/CMakeLists.txt b/tests/auto/corelib/global/qnumeric/CMakeLists.txt
new file mode 100644
index 0000000000..f96e038c3d
--- /dev/null
+++ b/tests/auto/corelib/global/qnumeric/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from qnumeric.pro.
+
+#####################################################################
+## tst_qnumeric Test:
+#####################################################################
+
+add_qt_test(tst_qnumeric
+ SOURCES
+ tst_qnumeric.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qnumeric CONDITION ICC
+ COMPILE_OPTIONS
+ -fp-model
+ strict
+)
+
+extend_target(tst_qnumeric CONDITION intel_icl
+ COMPILE_OPTIONS
+ /fp:strict
+)
diff --git a/tests/auto/corelib/global/qrand/CMakeLists.txt b/tests/auto/corelib/global/qrand/CMakeLists.txt
new file mode 100644
index 0000000000..80e8132809
--- /dev/null
+++ b/tests/auto/corelib/global/qrand/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qrand.pro.
+
+#####################################################################
+## tst_qrand Test:
+#####################################################################
+
+add_qt_test(tst_qrand
+ SOURCES
+ tst_qrand.cpp
+)
diff --git a/tests/auto/corelib/global/qrandomgenerator/CMakeLists.txt b/tests/auto/corelib/global/qrandomgenerator/CMakeLists.txt
new file mode 100644
index 0000000000..23dd440738
--- /dev/null
+++ b/tests/auto/corelib/global/qrandomgenerator/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qrandomgenerator.pro.
+
+#####################################################################
+## tst_qrandomgenerator Test:
+#####################################################################
+
+add_qt_test(tst_qrandomgenerator
+ SOURCES
+ tst_qrandomgenerator.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/global/qtendian/CMakeLists.txt b/tests/auto/corelib/global/qtendian/CMakeLists.txt
new file mode 100644
index 0000000000..80b716f21f
--- /dev/null
+++ b/tests/auto/corelib/global/qtendian/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qtendian.pro.
+
+#####################################################################
+## tst_qtendian Test:
+#####################################################################
+
+add_qt_test(tst_qtendian
+ SOURCES
+ tst_qtendian.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/io/.prev_CMakeLists.txt b/tests/auto/corelib/io/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..5baf4c35de
--- /dev/null
+++ b/tests/auto/corelib/io/.prev_CMakeLists.txt
@@ -0,0 +1,56 @@
+# Generated from io.pro.
+
+if(QT_FEATURE_private_tests)
+ add_subdirectory(qabstractfileengine)
+ add_subdirectory(qfileinfo)
+ add_subdirectory(qipaddress)
+ add_subdirectory(qloggingregistry)
+ add_subdirectory(qurlinternal)
+endif()
+add_subdirectory(qbuffer)
+add_subdirectory(qdataurl)
+add_subdirectory(qdiriterator)
+add_subdirectory(qfile)
+add_subdirectory(largefile)
+add_subdirectory(qfileselector)
+add_subdirectory(qfilesystemmetadata)
+add_subdirectory(qloggingcategory)
+add_subdirectory(qnodebug)
+add_subdirectory(qsavefile)
+add_subdirectory(qstandardpaths)
+add_subdirectory(qtemporarydir)
+add_subdirectory(qtemporaryfile)
+add_subdirectory(qurlquery)
+if(TARGET Qt::Concurrent)
+ add_subdirectory(qdebug)
+ add_subdirectory(qlockfile)
+ add_subdirectory(qurl)
+endif()
+if(NOT ANDROID)
+ add_subdirectory(qdir)
+ add_subdirectory(qresourceengine)
+endif()
+if(QT_FEATURE_private_tests OR UNIX)
+ add_subdirectory(qfilesystementry)
+endif()
+if(QT_FEATURE_filesystemwatcher)
+ add_subdirectory(qfilesystemwatcher)
+endif()
+if(TARGET Qt::Network)
+ add_subdirectory(qiodevice)
+endif()
+if(QT_FEATURE_process AND TARGET Qt::Network AND NOT ANDROID)
+ add_subdirectory(qprocess)
+endif()
+if(QT_FEATURE_process)
+ add_subdirectory(qprocess-noapplication)
+endif()
+if(QT_FEATURE_processenvironment)
+ add_subdirectory(qprocessenvironment)
+endif()
+if(QT_FEATURE_settings AND TARGET Qt::Gui)
+ add_subdirectory(qsettings)
+endif()
+if(NOT WINRT)
+ add_subdirectory(qstorageinfo)
+endif()
diff --git a/tests/auto/corelib/io/CMakeLists.txt b/tests/auto/corelib/io/CMakeLists.txt
new file mode 100644
index 0000000000..cb1246c3a2
--- /dev/null
+++ b/tests/auto/corelib/io/CMakeLists.txt
@@ -0,0 +1,56 @@
+# Generated from io.pro.
+
+if(QT_FEATURE_private_tests)
+ add_subdirectory(qabstractfileengine)
+ add_subdirectory(qfileinfo)
+ add_subdirectory(qipaddress)
+ add_subdirectory(qloggingregistry)
+ add_subdirectory(qurlinternal)
+endif()
+add_subdirectory(qbuffer)
+add_subdirectory(qdataurl)
+add_subdirectory(qdiriterator)
+add_subdirectory(qfile)
+add_subdirectory(largefile)
+# add_subdirectory(qfileselector) # special case needs fixes
+add_subdirectory(qfilesystemmetadata)
+add_subdirectory(qloggingcategory)
+add_subdirectory(qnodebug)
+add_subdirectory(qsavefile)
+add_subdirectory(qstandardpaths)
+add_subdirectory(qtemporarydir)
+add_subdirectory(qtemporaryfile)
+add_subdirectory(qurlquery)
+if(TARGET Qt::Concurrent)
+ add_subdirectory(qdebug)
+ add_subdirectory(qlockfile)
+ add_subdirectory(qurl)
+endif()
+if(NOT ANDROID)
+ add_subdirectory(qdir)
+ # add_subdirectory(qresourceengine) # special case needs fixes
+endif()
+if(QT_FEATURE_private_tests OR UNIX)
+ add_subdirectory(qfilesystementry)
+endif()
+if(QT_FEATURE_filesystemwatcher)
+ add_subdirectory(qfilesystemwatcher)
+endif()
+if(TARGET Qt::Network)
+ add_subdirectory(qiodevice)
+endif()
+if(QT_FEATURE_process AND TARGET Qt::Network AND NOT ANDROID)
+ # add_subdirectory(qprocess) # special case needs fixes
+endif()
+if(QT_FEATURE_process)
+ add_subdirectory(qprocess-noapplication)
+endif()
+if(QT_FEATURE_processenvironment)
+ add_subdirectory(qprocessenvironment)
+endif()
+if(QT_FEATURE_settings AND TARGET Qt::Gui)
+ add_subdirectory(qsettings)
+endif()
+if(NOT WINRT)
+ add_subdirectory(qstorageinfo)
+endif()
diff --git a/tests/auto/corelib/io/largefile/CMakeLists.txt b/tests/auto/corelib/io/largefile/CMakeLists.txt
new file mode 100644
index 0000000000..cb1eba8526
--- /dev/null
+++ b/tests/auto/corelib/io/largefile/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from largefile.pro.
+
+#####################################################################
+## tst_largefile Test:
+#####################################################################
+
+add_qt_test(tst_largefile
+ SOURCES
+ ../../../../shared/emulationdetector.h
+ tst_largefile.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../shared
+)
diff --git a/tests/auto/corelib/io/qabstractfileengine/CMakeLists.txt b/tests/auto/corelib/io/qabstractfileengine/CMakeLists.txt
new file mode 100644
index 0000000000..1c1470cf51
--- /dev/null
+++ b/tests/auto/corelib/io/qabstractfileengine/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from qabstractfileengine.pro.
+
+#####################################################################
+## tst_qabstractfileengine Test:
+#####################################################################
+
+add_qt_test(tst_qabstractfileengine
+ SOURCES
+ tst_qabstractfileengine.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+# Resources:
+set(qabstractfileengine_resource_files
+ "resources/"
+)
+
+add_qt_resource(tst_qabstractfileengine "qabstractfileengine"
+ PREFIX
+ "/tst_qabstractfileengine/"
+ FILES
+ ${qabstractfileengine_resource_files}
+)
+
diff --git a/tests/auto/corelib/io/qbuffer/CMakeLists.txt b/tests/auto/corelib/io/qbuffer/CMakeLists.txt
new file mode 100644
index 0000000000..40502dd004
--- /dev/null
+++ b/tests/auto/corelib/io/qbuffer/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qbuffer.pro.
+
+#####################################################################
+## tst_qbuffer Test:
+#####################################################################
+
+add_qt_test(tst_qbuffer
+ SOURCES
+ tst_qbuffer.cpp
+)
diff --git a/tests/auto/corelib/io/qdataurl/CMakeLists.txt b/tests/auto/corelib/io/qdataurl/CMakeLists.txt
new file mode 100644
index 0000000000..84f1b5b11a
--- /dev/null
+++ b/tests/auto/corelib/io/qdataurl/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdataurl.pro.
+
+#####################################################################
+## tst_qdataurl Test:
+#####################################################################
+
+add_qt_test(tst_qdataurl
+ SOURCES
+ tst_qdataurl.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/io/qdebug/CMakeLists.txt b/tests/auto/corelib/io/qdebug/CMakeLists.txt
new file mode 100644
index 0000000000..d7fa4fb7cd
--- /dev/null
+++ b/tests/auto/corelib/io/qdebug/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdebug.pro.
+
+#####################################################################
+## tst_qdebug Test:
+#####################################################################
+
+add_qt_test(tst_qdebug
+ SOURCES
+ tst_qdebug.cpp
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
diff --git a/tests/auto/corelib/io/qdir/CMakeLists.txt b/tests/auto/corelib/io/qdir/CMakeLists.txt
new file mode 100644
index 0000000000..6ac1e5b46f
--- /dev/null
+++ b/tests/auto/corelib/io/qdir/CMakeLists.txt
@@ -0,0 +1,99 @@
+# Generated from qdir.pro.
+
+#####################################################################
+## tst_qdir Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "testdir")
+list(APPEND test_data "testData")
+list(APPEND test_data "searchdir")
+list(APPEND test_data "resources")
+list(APPEND test_data "entrylist")
+list(APPEND test_data "types")
+list(APPEND test_data "tst_qdir.cpp")
+
+add_qt_test(tst_qdir
+ SOURCES
+ tst_qdir.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ TESTDATA ${test_data}
+)
+
+# Resources:
+set(qdir_resource_files
+ "resources/entryList/"
+)
+
+add_qt_resource(tst_qdir "qdir"
+ PREFIX
+ "/tst_qdir/"
+ FILES
+ ${qdir_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:qdir.pro:APPLE_IOS:
+# QMAKE_INFO_PLIST = "Info.plist"
+
+extend_target(tst_qdir CONDITION CONFIG___contains___builtin_testdata
+ DEFINES
+ BUILTIN_TESTDATA
+)
+
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ # Resources:
+ set(android_testdata_resource_files
+ "entrylist/directory/dummy"
+ "entrylist/file"
+ "resources/entryList/file1.data"
+ "resources/entryList/file2.data"
+ "resources/entryList/file3.data"
+ "resources/entryList/file4.nothing"
+ "searchdir/subdir1/picker.png"
+ "searchdir/subdir2/picker.png"
+ "testData/empty"
+ "testdir/dir/qdir.pro"
+ "testdir/dir/qrc_qdir.cpp"
+ "testdir/dir/tmp/empty"
+ "testdir/dir/tst_qdir.cpp"
+ "testdir/spaces/foo. bar"
+ "testdir/spaces/foo.bar"
+ "tst_qdir.cpp"
+ "types/a"
+ "types/a.a"
+ "types/a.b"
+ "types/a.c"
+ "types/b"
+ "types/b.a"
+ "types/b.b"
+ "types/b.c"
+ "types/c"
+ "types/c.a"
+ "types/c.b"
+ "types/c.c"
+ "types/d.a/dummy"
+ "types/d.b/dummy"
+ "types/d.c/dummy"
+ "types/d/dummy"
+ "types/e.a/dummy"
+ "types/e.b/dummy"
+ "types/e.c/dummy"
+ "types/e/dummy"
+ "types/f.a/dummy"
+ "types/f.b/dummy"
+ "types/f.c/dummy"
+ "types/f/dummy"
+ )
+
+ add_qt_resource(tst_qdir "android_testdata"
+ PREFIX
+ "/android_testdata"
+ FILES
+ ${android_testdata_resource_files}
+ )
+endif()
diff --git a/tests/auto/corelib/io/qdir/testdir/dir/CMakeLists.txt b/tests/auto/corelib/io/qdir/testdir/dir/CMakeLists.txt
new file mode 100644
index 0000000000..e50fcb60ca
--- /dev/null
+++ b/tests/auto/corelib/io/qdir/testdir/dir/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qdir.pro.
+
+#####################################################################
+## qdir Binary:
+#####################################################################
+
+add_qt_executable(qdir
+ GUI
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/corelib/io/qdiriterator/CMakeLists.txt b/tests/auto/corelib/io/qdiriterator/CMakeLists.txt
new file mode 100644
index 0000000000..dd10eb62c3
--- /dev/null
+++ b/tests/auto/corelib/io/qdiriterator/CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from qdiriterator.pro.
+
+#####################################################################
+## tst_qdiriterator Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "entrylist")
+
+add_qt_test(tst_qdiriterator
+ SOURCES
+ tst_qdiriterator.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ TESTDATA ${test_data}
+)
+
+# Resources:
+set(qdiriterator_resource_files
+ "entrylist/directory/dummy"
+ "entrylist/file"
+)
+
+add_qt_resource(tst_qdiriterator "qdiriterator"
+ PREFIX
+ "/testdata/"
+ FILES
+ ${qdiriterator_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qdiriterator CONDITION CONFIG___contains___builtin_testdata
+ DEFINES
+ BUILTIN_TESTDATA
+)
diff --git a/tests/auto/corelib/io/qfile/.prev_CMakeLists.txt b/tests/auto/corelib/io/qfile/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..b976754629
--- /dev/null
+++ b/tests/auto/corelib/io/qfile/.prev_CMakeLists.txt
@@ -0,0 +1,89 @@
+# Generated from qfile.pro.
+
+#####################################################################
+## tst_qfile Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "BLACKLIST")
+list(APPEND test_data "dosfile.txt")
+list(APPEND test_data "noendofline.txt")
+list(APPEND test_data "testfile.txt")
+list(APPEND test_data "testlog.txt")
+list(APPEND test_data "two.dots.file")
+list(APPEND test_data "tst_qfile.cpp")
+list(APPEND test_data "Makefile")
+list(APPEND test_data "forCopying.txt")
+list(APPEND test_data "forRenaming.txt")
+list(APPEND test_data "resources/file1.ext1")
+
+add_qt_test(tst_qfile
+ SOURCES
+ ../../../../shared/emulationdetector.h
+ tst_qfile.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../shared
+ LIBRARIES
+ Qt::CorePrivate
+ TESTDATA ${test_data}
+)
+
+# Resources:
+set(qfile_resource_files
+ "resources/"
+)
+
+add_qt_resource(tst_qfile "qfile"
+ PREFIX
+ "/tst_qfileinfo/"
+ FILES
+ ${qfile_resource_files}
+)
+set(rename-fallback_resource_files
+ "rename-fallback.qrc"
+)
+
+add_qt_resource(tst_qfile "rename-fallback"
+ PREFIX
+ "/"
+ FILES
+ ${rename-fallback_resource_files}
+)
+set(copy-fallback_resource_files
+ "copy-fallback.qrc"
+)
+
+add_qt_resource(tst_qfile "copy-fallback"
+ PREFIX
+ "/"
+ FILES
+ ${copy-fallback_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qfile CONDITION TARGET Qt::Network
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+extend_target(tst_qfile CONDITION NOT TARGET Qt::Network
+ DEFINES
+ QT_NO_NETWORK
+)
+
+extend_target(tst_qfile CONDITION CONFIG___contains___builtin_testdata
+ DEFINES
+ BUILTIN_TESTDATA
+)
+
+extend_target(tst_qfile CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ ole32
+ uuid
+)
+if(NOT WINRT)
+ add_subdirectory(stdinprocess)
+endif()
diff --git a/tests/auto/corelib/io/qfile/CMakeLists.txt b/tests/auto/corelib/io/qfile/CMakeLists.txt
new file mode 100644
index 0000000000..03b648d76f
--- /dev/null
+++ b/tests/auto/corelib/io/qfile/CMakeLists.txt
@@ -0,0 +1,89 @@
+# Generated from qfile.pro.
+
+#####################################################################
+## tst_qfile Test:
+#####################################################################
+
+# Collect test data
+# list(APPEND test_data "BLACKLIST") # special case remove
+list(APPEND test_data "dosfile.txt")
+list(APPEND test_data "noendofline.txt")
+list(APPEND test_data "testfile.txt")
+list(APPEND test_data "testlog.txt")
+list(APPEND test_data "two.dots.file")
+list(APPEND test_data "tst_qfile.cpp")
+# list(APPEND test_data "Makefile") # special case remove
+list(APPEND test_data "forCopying.txt")
+list(APPEND test_data "forRenaming.txt")
+list(APPEND test_data "resources/file1.ext1")
+
+add_qt_test(tst_qfile
+ SOURCES
+ ../../../../shared/emulationdetector.h
+ tst_qfile.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../shared
+ LIBRARIES
+ Qt::CorePrivate
+ TESTDATA ${test_data}
+)
+
+# Resources:
+set(qfile_resource_files
+ "resources/"
+)
+
+add_qt_resource(tst_qfile "qfile"
+ PREFIX
+ "/tst_qfileinfo/"
+ FILES
+ ${qfile_resource_files}
+)
+set(rename-fallback_resource_files
+ "rename-fallback.qrc"
+)
+
+add_qt_resource(tst_qfile "rename-fallback"
+ PREFIX
+ "/"
+ FILES
+ ${rename-fallback_resource_files}
+)
+set(copy-fallback_resource_files
+ "copy-fallback.qrc"
+)
+
+add_qt_resource(tst_qfile "copy-fallback"
+ PREFIX
+ "/"
+ FILES
+ ${copy-fallback_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qfile CONDITION TARGET Qt::Network
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+extend_target(tst_qfile CONDITION NOT TARGET Qt::Network
+ DEFINES
+ QT_NO_NETWORK
+)
+
+extend_target(tst_qfile CONDITION CONFIG___contains___builtin_testdata
+ DEFINES
+ BUILTIN_TESTDATA
+)
+
+extend_target(tst_qfile CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ ole32
+ uuid
+)
+if(NOT WINRT)
+ add_subdirectory(stdinprocess)
+endif()
diff --git a/tests/auto/corelib/io/qfile/stdinprocess/CMakeLists.txt b/tests/auto/corelib/io/qfile/stdinprocess/CMakeLists.txt
new file mode 100644
index 0000000000..994c2fc268
--- /dev/null
+++ b/tests/auto/corelib/io/qfile/stdinprocess/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from stdinprocess.pro.
+
+#####################################################################
+## stdinprocess_helper Binary:
+#####################################################################
+
+add_qt_test_helper(stdinprocess_helper
+ SOURCES
+ main.cpp
+)
diff --git a/tests/auto/corelib/io/qfileinfo/CMakeLists.txt b/tests/auto/corelib/io/qfileinfo/CMakeLists.txt
new file mode 100644
index 0000000000..03f2e99e37
--- /dev/null
+++ b/tests/auto/corelib/io/qfileinfo/CMakeLists.txt
@@ -0,0 +1,47 @@
+# Generated from qfileinfo.pro.
+
+#####################################################################
+## tst_qfileinfo Test:
+#####################################################################
+
+add_qt_test(tst_qfileinfo
+ SOURCES
+ tst_qfileinfo.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+# Resources:
+set(qfileinfo_resource_files
+ "resources/"
+)
+
+add_qt_resource(tst_qfileinfo "qfileinfo"
+ PREFIX
+ "/tst_qfileinfo/"
+ FILES
+ ${qfileinfo_resource_files}
+)
+set(testdata_resource_files
+ "resources/file1"
+ "resources/file1.ext1"
+ "resources/file1.ext1.ext2"
+ "tst_qfileinfo.cpp"
+)
+
+add_qt_resource(tst_qfileinfo "testdata"
+ PREFIX
+ "/testdata"
+ FILES
+ ${testdata_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qfileinfo CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ advapi32
+ netapi32
+)
diff --git a/tests/auto/corelib/io/qfilesystementry/CMakeLists.txt b/tests/auto/corelib/io/qfilesystementry/CMakeLists.txt
new file mode 100644
index 0000000000..3643ca6da4
--- /dev/null
+++ b/tests/auto/corelib/io/qfilesystementry/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qfilesystementry.pro.
+
+#####################################################################
+## tst_qfilesystementry Test:
+#####################################################################
+
+add_qt_test(tst_qfilesystementry
+ SOURCES
+ ${QT_SOURCE_TREE}/src/corelib/io/qfilesystementry.cpp ${QT_SOURCE_TREE}/src/corelib/io/qfilesystementry_p.h
+ tst_qfilesystementry.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/io/qfilesystemmetadata/CMakeLists.txt b/tests/auto/corelib/io/qfilesystemmetadata/CMakeLists.txt
new file mode 100644
index 0000000000..fc89314669
--- /dev/null
+++ b/tests/auto/corelib/io/qfilesystemmetadata/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qfilesystemmetadata.pro.
+
+#####################################################################
+## tst_qfilesystemmetadata Test:
+#####################################################################
+
+add_qt_test(tst_qfilesystemmetadata
+ SOURCES
+ tst_qfilesystemmetadata.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/io/qfilesystemwatcher/CMakeLists.txt b/tests/auto/corelib/io/qfilesystemwatcher/CMakeLists.txt
new file mode 100644
index 0000000000..1dfef5acab
--- /dev/null
+++ b/tests/auto/corelib/io/qfilesystemwatcher/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qfilesystemwatcher.pro.
+
+#####################################################################
+## tst_qfilesystemwatcher Test:
+#####################################################################
+
+add_qt_test(tst_qfilesystemwatcher
+ SOURCES
+ tst_qfilesystemwatcher.cpp
+)
diff --git a/tests/auto/corelib/io/qiodevice/CMakeLists.txt b/tests/auto/corelib/io/qiodevice/CMakeLists.txt
new file mode 100644
index 0000000000..6b7833ac22
--- /dev/null
+++ b/tests/auto/corelib/io/qiodevice/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from qiodevice.pro.
+
+#####################################################################
+## tst_qiodevice Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "tst_qiodevice.cpp")
+
+add_qt_test(tst_qiodevice
+ SOURCES
+ tst_qiodevice.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ TESTDATA ${test_data}
+)
+
+#### Keys ignored in scope 1:.:.:qiodevice.pro:<TRUE>:
+# MOC_DIR = "tmp"
+
+## Scopes:
+#####################################################################
+
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ # Resources:
+ set(android_testdata_resource_files
+ "tst_qiodevice.cpp"
+ )
+
+ add_qt_resource(tst_qiodevice "android_testdata"
+ PREFIX
+ "/"
+ FILES
+ ${android_testdata_resource_files}
+ )
+endif()
diff --git a/tests/auto/corelib/io/qipaddress/CMakeLists.txt b/tests/auto/corelib/io/qipaddress/CMakeLists.txt
new file mode 100644
index 0000000000..9e0817e445
--- /dev/null
+++ b/tests/auto/corelib/io/qipaddress/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qipaddress.pro.
+
+#####################################################################
+## tst_qipaddress Test:
+#####################################################################
+
+add_qt_test(tst_qipaddress
+ SOURCES
+ tst_qipaddress.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/io/qlockfile/CMakeLists.txt b/tests/auto/corelib/io/qlockfile/CMakeLists.txt
new file mode 100644
index 0000000000..52bd7bfd8f
--- /dev/null
+++ b/tests/auto/corelib/io/qlockfile/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from qlockfile.pro.
+
+#####################################################################
+## tst_qlockfile Test:
+#####################################################################
+
+add_qt_test(tst_qlockfile
+ SOURCES
+ tst_qlockfile.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qlockfile CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ advapi32
+)
+add_subdirectory(qlockfiletesthelper)
diff --git a/tests/auto/corelib/io/qlockfile/qlockfiletesthelper/.prev_CMakeLists.txt b/tests/auto/corelib/io/qlockfile/qlockfiletesthelper/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..755dc7cf39
--- /dev/null
+++ b/tests/auto/corelib/io/qlockfile/qlockfiletesthelper/.prev_CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from qlockfile_test_helper.pro.
+
+#####################################################################
+## qlockfile_test_helper Binary:
+#####################################################################
+
+add_qt_executable(qlockfile_test_helper
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ qlockfile_test_helper.cpp
+)
diff --git a/tests/auto/corelib/io/qlockfile/qlockfiletesthelper/CMakeLists.txt b/tests/auto/corelib/io/qlockfile/qlockfiletesthelper/CMakeLists.txt
new file mode 100644
index 0000000000..b515037d56
--- /dev/null
+++ b/tests/auto/corelib/io/qlockfile/qlockfiletesthelper/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qlockfile_test_helper.pro.
+
+#####################################################################
+## qlockfile_test_helper Binary:
+#####################################################################
+
+add_qt_test_helper(qlockfile_test_helper # special case
+ OVERRIDE_OUTPUT_DIRECTORY # special case
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ qlockfile_test_helper.cpp
+)
diff --git a/tests/auto/corelib/io/qloggingcategory/CMakeLists.txt b/tests/auto/corelib/io/qloggingcategory/CMakeLists.txt
new file mode 100644
index 0000000000..ea82bc0370
--- /dev/null
+++ b/tests/auto/corelib/io/qloggingcategory/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qloggingcategory.pro.
+
+#####################################################################
+## tst_qloggingcategory Test:
+#####################################################################
+
+add_qt_test(tst_qloggingcategory
+ SOURCES
+ tst_qloggingcategory.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+#### Keys ignored in scope 1:.:.:qloggingcategory.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/auto/corelib/io/qloggingregistry/CMakeLists.txt b/tests/auto/corelib/io/qloggingregistry/CMakeLists.txt
new file mode 100644
index 0000000000..518258d77b
--- /dev/null
+++ b/tests/auto/corelib/io/qloggingregistry/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from qloggingregistry.pro.
+
+#####################################################################
+## tst_qloggingregistry Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "qtlogging.ini")
+
+add_qt_test(tst_qloggingregistry
+ SOURCES
+ tst_qloggingregistry.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ TESTDATA ${test_data}
+)
+
+#### Keys ignored in scope 1:.:.:qloggingregistry.pro:<TRUE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ # Resources:
+ set(android_testdata_resource_files
+ "qtlogging.ini"
+ )
+
+ add_qt_resource(tst_qloggingregistry "android_testdata"
+ PREFIX
+ "/"
+ FILES
+ ${android_testdata_resource_files}
+ )
+endif()
diff --git a/tests/auto/corelib/io/qnodebug/CMakeLists.txt b/tests/auto/corelib/io/qnodebug/CMakeLists.txt
new file mode 100644
index 0000000000..4d1b57e222
--- /dev/null
+++ b/tests/auto/corelib/io/qnodebug/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qnodebug.pro.
+
+#####################################################################
+## tst_qnodebug Test:
+#####################################################################
+
+add_qt_test(tst_qnodebug
+ SOURCES
+ tst_qnodebug.cpp
+)
diff --git a/tests/auto/corelib/io/qprocess-noapplication/CMakeLists.txt b/tests/auto/corelib/io/qprocess-noapplication/CMakeLists.txt
new file mode 100644
index 0000000000..ce6195fc37
--- /dev/null
+++ b/tests/auto/corelib/io/qprocess-noapplication/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qprocess-noapplication.pro.
+
+#####################################################################
+## qprocess-noapplication Test:
+#####################################################################
+
+add_qt_test(qprocess-noapplication
+ SOURCES
+ tst_qprocessnoapplication.cpp
+)
diff --git a/tests/auto/corelib/io/qprocessenvironment/CMakeLists.txt b/tests/auto/corelib/io/qprocessenvironment/CMakeLists.txt
new file mode 100644
index 0000000000..dbcd8c8172
--- /dev/null
+++ b/tests/auto/corelib/io/qprocessenvironment/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qprocessenvironment.pro.
+
+#####################################################################
+## tst_qprocessenvironment Test:
+#####################################################################
+
+add_qt_test(tst_qprocessenvironment
+ SOURCES
+ tst_qprocessenvironment.cpp
+)
diff --git a/tests/auto/corelib/io/qsavefile/CMakeLists.txt b/tests/auto/corelib/io/qsavefile/CMakeLists.txt
new file mode 100644
index 0000000000..aec5da1f99
--- /dev/null
+++ b/tests/auto/corelib/io/qsavefile/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qsavefile.pro.
+
+#####################################################################
+## tst_qsavefile Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "tst_qsavefile.cpp")
+
+add_qt_test(tst_qsavefile
+ SOURCES
+ tst_qsavefile.cpp
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/corelib/io/qsettings/CMakeLists.txt b/tests/auto/corelib/io/qsettings/CMakeLists.txt
new file mode 100644
index 0000000000..77ae908f93
--- /dev/null
+++ b/tests/auto/corelib/io/qsettings/CMakeLists.txt
@@ -0,0 +1,51 @@
+# Generated from qsettings.pro.
+
+#####################################################################
+## tst_qsettings Test:
+#####################################################################
+
+add_qt_test(tst_qsettings
+ SOURCES
+ tst_qsettings.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ INCLUDE_DIRECTORIES
+ ../../kernel/qmetatype
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set(qsettings_resource_files
+ "bom.ini"
+ "resourcefile.ini"
+ "resourcefile2.ini"
+ "resourcefile3.ini"
+ "resourcefile4.ini"
+ "resourcefile5.ini"
+ "resourcefile6.plist"
+ "withcomments.ini"
+)
+
+add_qt_resource(tst_qsettings "qsettings"
+ PREFIX
+ "/"
+ FILES
+ ${qsettings_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qsettings CONDITION MSVC
+ PUBLIC_LIBRARIES
+ advapi32
+)
+
+extend_target(tst_qsettings CONDITION APPLE
+ PUBLIC_LIBRARIES
+ ${FWCoreFoundation}
+)
diff --git a/tests/auto/corelib/io/qstandardpaths/CMakeLists.txt b/tests/auto/corelib/io/qstandardpaths/CMakeLists.txt
new file mode 100644
index 0000000000..5bceaf1d77
--- /dev/null
+++ b/tests/auto/corelib/io/qstandardpaths/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from qstandardpaths.pro.
+
+#####################################################################
+## tst_qstandardpaths Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "tst_qstandardpaths.cpp")
+list(APPEND test_data "qstandardpaths.pro")
+
+add_qt_test(tst_qstandardpaths
+ SOURCES
+ ../../../../shared/emulationdetector.h
+ tst_qstandardpaths.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../shared
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qstandardpaths CONDITION boot2qt
+ DEFINES
+ SKIP_FINDEXECUTABLE
+)
diff --git a/tests/auto/corelib/io/qstorageinfo/CMakeLists.txt b/tests/auto/corelib/io/qstorageinfo/CMakeLists.txt
new file mode 100644
index 0000000000..c3b14dc6db
--- /dev/null
+++ b/tests/auto/corelib/io/qstorageinfo/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qstorageinfo.pro.
+
+#####################################################################
+## tst_qstorageinfo Test:
+#####################################################################
+
+add_qt_test(tst_qstorageinfo
+ SOURCES
+ tst_qstorageinfo.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/io/qtemporarydir/CMakeLists.txt b/tests/auto/corelib/io/qtemporarydir/CMakeLists.txt
new file mode 100644
index 0000000000..3a106e8453
--- /dev/null
+++ b/tests/auto/corelib/io/qtemporarydir/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtemporarydir.pro.
+
+#####################################################################
+## tst_qtemporarydir Test:
+#####################################################################
+
+add_qt_test(tst_qtemporarydir
+ SOURCES
+ ../../../../shared/emulationdetector.h
+ tst_qtemporarydir.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../shared
+ LIBRARIES
+ Qt::TestPrivate
+)
diff --git a/tests/auto/corelib/io/qtemporaryfile/CMakeLists.txt b/tests/auto/corelib/io/qtemporaryfile/CMakeLists.txt
new file mode 100644
index 0000000000..693e2c674c
--- /dev/null
+++ b/tests/auto/corelib/io/qtemporaryfile/CMakeLists.txt
@@ -0,0 +1,47 @@
+# Generated from qtemporaryfile.pro.
+
+#####################################################################
+## tst_qtemporaryfile Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "tst_qtemporaryfile.cpp")
+
+add_qt_test(tst_qtemporaryfile
+ SOURCES
+ tst_qtemporaryfile.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ TESTDATA ${test_data}
+)
+
+# Resources:
+set(qtemporaryfile_resource_files
+ "resources/test.txt"
+)
+
+add_qt_resource(tst_qtemporaryfile "qtemporaryfile"
+ PREFIX
+ "/"
+ FILES
+ ${qtemporaryfile_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ # Resources:
+ set(android_testdata_resource_files
+ "resources/test.txt"
+ "tst_qtemporaryfile.cpp"
+ )
+
+ add_qt_resource(tst_qtemporaryfile "android_testdata"
+ PREFIX
+ "/android_testdata"
+ FILES
+ ${android_testdata_resource_files}
+ )
+endif()
diff --git a/tests/auto/corelib/io/qurl/CMakeLists.txt b/tests/auto/corelib/io/qurl/CMakeLists.txt
new file mode 100644
index 0000000000..c23ad27cfc
--- /dev/null
+++ b/tests/auto/corelib/io/qurl/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qurl.pro.
+
+#####################################################################
+## tst_qurl Test:
+#####################################################################
+
+add_qt_test(tst_qurl
+ SOURCES
+ tst_qurl.cpp
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qurl CONDITION APPLE
+ SOURCES
+ tst_qurl_mac.mm
+)
diff --git a/tests/auto/corelib/io/qurlinternal/CMakeLists.txt b/tests/auto/corelib/io/qurlinternal/CMakeLists.txt
new file mode 100644
index 0000000000..c941d6811c
--- /dev/null
+++ b/tests/auto/corelib/io/qurlinternal/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qurlinternal.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qurlinternal Test:
+#####################################################################
+
+add_qt_test(tst_qurlinternal
+ SOURCES
+ ../../codecs/utf8/utf8data.cpp
+ tst_qurlinternal.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+#### Keys ignored in scope 1:.:.:qurlinternal.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
diff --git a/tests/auto/corelib/io/qurlquery/CMakeLists.txt b/tests/auto/corelib/io/qurlquery/CMakeLists.txt
new file mode 100644
index 0000000000..f35ff284a7
--- /dev/null
+++ b/tests/auto/corelib/io/qurlquery/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qurlquery.pro.
+
+#####################################################################
+## tst_qurlquery Test:
+#####################################################################
+
+add_qt_test(tst_qurlquery
+ SOURCES
+ tst_qurlquery.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/itemmodels/CMakeLists.txt b/tests/auto/corelib/itemmodels/CMakeLists.txt
new file mode 100644
index 0000000000..6f52ed2600
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from itemmodels.pro.
+
+add_subdirectory(qstringlistmodel)
+if(TARGET Qt::Gui)
+ add_subdirectory(qabstractitemmodel)
+ add_subdirectory(qabstractproxymodel)
+ add_subdirectory(qconcatenatetablesproxymodel)
+ add_subdirectory(qidentityproxymodel)
+ add_subdirectory(qitemselectionmodel)
+ add_subdirectory(qsortfilterproxymodel_recursive)
+ add_subdirectory(qtransposeproxymodel)
+endif()
+if(TARGET Qt::Widgets)
+ add_subdirectory(qsortfilterproxymodel_regexp)
+ add_subdirectory(qsortfilterproxymodel_regularexpression)
+endif()
+if(TARGET Qt::Sql AND TARGET Qt::Widgets)
+ add_subdirectory(qitemmodel)
+endif()
diff --git a/tests/auto/corelib/itemmodels/qabstractitemmodel/CMakeLists.txt b/tests/auto/corelib/itemmodels/qabstractitemmodel/CMakeLists.txt
new file mode 100644
index 0000000000..edc7f4321a
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qabstractitemmodel/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qabstractitemmodel.pro.
+
+#####################################################################
+## tst_qabstractitemmodel Test:
+#####################################################################
+
+add_qt_test(tst_qabstractitemmodel
+ SOURCES
+ ../../../other/qabstractitemmodelutils/dynamictreemodel.cpp ../../../other/qabstractitemmodelutils/dynamictreemodel.h
+ tst_qabstractitemmodel.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ INCLUDE_DIRECTORIES
+ ../../../other/qabstractitemmodelutils
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/corelib/itemmodels/qabstractproxymodel/CMakeLists.txt b/tests/auto/corelib/itemmodels/qabstractproxymodel/CMakeLists.txt
new file mode 100644
index 0000000000..f6a443213c
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qabstractproxymodel/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qabstractproxymodel.pro.
+
+#####################################################################
+## tst_qabstractproxymodel Test:
+#####################################################################
+
+add_qt_test(tst_qabstractproxymodel
+ SOURCES
+ tst_qabstractproxymodel.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/corelib/itemmodels/qconcatenatetablesproxymodel/CMakeLists.txt b/tests/auto/corelib/itemmodels/qconcatenatetablesproxymodel/CMakeLists.txt
new file mode 100644
index 0000000000..90b371cb1b
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qconcatenatetablesproxymodel/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qconcatenatetablesproxymodel.pro.
+
+#####################################################################
+## tst_qconcatenatetablesproxymodel Test:
+#####################################################################
+
+add_qt_test(tst_qconcatenatetablesproxymodel
+ SOURCES
+ tst_qconcatenatetablesproxymodel.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/corelib/itemmodels/qidentityproxymodel/CMakeLists.txt b/tests/auto/corelib/itemmodels/qidentityproxymodel/CMakeLists.txt
new file mode 100644
index 0000000000..c02e7b5ad4
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qidentityproxymodel/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qidentityproxymodel.pro.
+
+#####################################################################
+## tst_qidentityproxymodel Test:
+#####################################################################
+
+add_qt_test(tst_qidentityproxymodel
+ SOURCES
+ ../../../other/qabstractitemmodelutils/dynamictreemodel.cpp ../../../other/qabstractitemmodelutils/dynamictreemodel.h
+ tst_qidentityproxymodel.cpp
+ INCLUDE_DIRECTORIES
+ ../../../other/qabstractitemmodelutils
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/corelib/itemmodels/qitemmodel/CMakeLists.txt b/tests/auto/corelib/itemmodels/qitemmodel/CMakeLists.txt
new file mode 100644
index 0000000000..3baf727cf9
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qitemmodel/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qitemmodel.pro.
+
+#####################################################################
+## tst_qitemmodel Test:
+#####################################################################
+
+add_qt_test(tst_qitemmodel
+ SOURCES
+ tst_qitemmodel.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Sql
+ Qt::Widgets
+)
diff --git a/tests/auto/corelib/itemmodels/qitemselectionmodel/CMakeLists.txt b/tests/auto/corelib/itemmodels/qitemselectionmodel/CMakeLists.txt
new file mode 100644
index 0000000000..bd79cba5e2
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qitemselectionmodel/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qitemselectionmodel.pro.
+
+#####################################################################
+## tst_qitemselectionmodel Test:
+#####################################################################
+
+add_qt_test(tst_qitemselectionmodel
+ SOURCES
+ tst_qitemselectionmodel.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/corelib/itemmodels/qsortfilterproxymodel_recursive/CMakeLists.txt b/tests/auto/corelib/itemmodels/qsortfilterproxymodel_recursive/CMakeLists.txt
new file mode 100644
index 0000000000..59f5d8ae76
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qsortfilterproxymodel_recursive/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qsortfilterproxymodel_recursive.pro.
+
+#####################################################################
+## tst_qsortfilterproxymodel_recursive Test:
+#####################################################################
+
+add_qt_test(tst_qsortfilterproxymodel_recursive
+ SOURCES
+ tst_qsortfilterproxymodel_recursive.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/corelib/itemmodels/qsortfilterproxymodel_regexp/CMakeLists.txt b/tests/auto/corelib/itemmodels/qsortfilterproxymodel_regexp/CMakeLists.txt
new file mode 100644
index 0000000000..8df14a96b1
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qsortfilterproxymodel_regexp/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qsortfilterproxymodel_regexp.pro.
+
+#####################################################################
+## tst_qsortfilterproxymodel_regexp Test:
+#####################################################################
+
+add_qt_test(tst_qsortfilterproxymodel_regexp
+ SOURCES
+ ../../../other/qabstractitemmodelutils/dynamictreemodel.cpp ../../../other/qabstractitemmodelutils/dynamictreemodel.h
+ ../qsortfilterproxymodel_common/tst_qsortfilterproxymodel.cpp ../qsortfilterproxymodel_common/tst_qsortfilterproxymodel.h
+ tst_qsortfilterproxymodel_regexp.cpp
+ INCLUDE_DIRECTORIES
+ ../../../other/qabstractitemmodelutils
+ ../qsortfilterproxymodel_common
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/corelib/itemmodels/qsortfilterproxymodel_regularexpression/CMakeLists.txt b/tests/auto/corelib/itemmodels/qsortfilterproxymodel_regularexpression/CMakeLists.txt
new file mode 100644
index 0000000000..8bc7f55f7c
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qsortfilterproxymodel_regularexpression/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qsortfilterproxymodel_regularexpression.pro.
+
+#####################################################################
+## tst_qsortfilterproxymodel_regularexpression Test:
+#####################################################################
+
+add_qt_test(tst_qsortfilterproxymodel_regularexpression
+ SOURCES
+ ../../../other/qabstractitemmodelutils/dynamictreemodel.cpp ../../../other/qabstractitemmodelutils/dynamictreemodel.h
+ ../qsortfilterproxymodel_common/tst_qsortfilterproxymodel.cpp ../qsortfilterproxymodel_common/tst_qsortfilterproxymodel.h
+ tst_qsortfilterproxymodel_regularexpression.cpp
+ INCLUDE_DIRECTORIES
+ ../../../other/qabstractitemmodelutils
+ ../qsortfilterproxymodel_common
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/corelib/itemmodels/qstringlistmodel/CMakeLists.txt b/tests/auto/corelib/itemmodels/qstringlistmodel/CMakeLists.txt
new file mode 100644
index 0000000000..53bfdbe419
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qstringlistmodel/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from qstringlistmodel.pro.
+
+#####################################################################
+## tst_qstringlistmodel Test:
+#####################################################################
+
+add_qt_test(tst_qstringlistmodel
+ SOURCES
+ qmodellistener.h
+ tst_qstringlistmodel.cpp
+)
diff --git a/tests/auto/corelib/itemmodels/qtransposeproxymodel/CMakeLists.txt b/tests/auto/corelib/itemmodels/qtransposeproxymodel/CMakeLists.txt
new file mode 100644
index 0000000000..ad1b65d348
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qtransposeproxymodel/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qtransposeproxymodel.pro.
+
+#####################################################################
+## tst_qtransposeproxymodel Test:
+#####################################################################
+
+add_qt_test(tst_qtransposeproxymodel
+ SOURCES
+ tst_qtransposeproxymodel.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/corelib/kernel/.prev_CMakeLists.txt b/tests/auto/corelib/kernel/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..5415a23a98
--- /dev/null
+++ b/tests/auto/corelib/kernel/.prev_CMakeLists.txt
@@ -0,0 +1,40 @@
+# Generated from kernel.pro.
+
+add_subdirectory(qcoreapplication)
+add_subdirectory(qdeadlinetimer)
+add_subdirectory(qelapsedtimer)
+add_subdirectory(qeventdispatcher)
+if(TARGET Qt::Network)
+ add_subdirectory(qeventloop)
+endif()
+add_subdirectory(qmath)
+add_subdirectory(qmetaobject)
+add_subdirectory(qmetaobjectbuilder)
+add_subdirectory(qmetamethod)
+add_subdirectory(qmetaproperty)
+add_subdirectory(qmetatype)
+add_subdirectory(qmetaenum)
+if(TARGET Qt::Gui)
+ add_subdirectory(qmimedata)
+endif()
+if(TARGET Qt::Network AND NOT ANDROID AND NOT APPLE_UIKIT)
+ add_subdirectory(qobject)
+endif()
+add_subdirectory(qpointer)
+if(QT_FEATURE_private_tests AND NOT ANDROID AND NOT APPLE_UIKIT)
+ add_subdirectory(qsharedmemory)
+endif()
+add_subdirectory(qsignalblocker)
+add_subdirectory(qsignalmapper)
+if(QT_FEATURE_private_tests AND TARGET Qt::Network)
+ add_subdirectory(qsocketnotifier)
+endif()
+if(QT_FEATURE_systemsemaphore AND NOT ANDROID AND NOT APPLE_UIKIT)
+ add_subdirectory(qsystemsemaphore)
+endif()
+add_subdirectory(qtimer)
+add_subdirectory(qtranslator)
+add_subdirectory(qvariant)
+if(win32_x_ AND NOT WINRT)
+ add_subdirectory(qwineventnotifier)
+endif()
diff --git a/tests/auto/corelib/kernel/CMakeLists.txt b/tests/auto/corelib/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..9fbe2b8b7a
--- /dev/null
+++ b/tests/auto/corelib/kernel/CMakeLists.txt
@@ -0,0 +1,40 @@
+# Generated from kernel.pro.
+
+# add_subdirectory(qcoreapplication) # special case
+add_subdirectory(qdeadlinetimer)
+add_subdirectory(qelapsedtimer)
+add_subdirectory(qeventdispatcher)
+if(TARGET Qt::Network)
+ add_subdirectory(qeventloop)
+endif()
+add_subdirectory(qmath)
+add_subdirectory(qmetaobject)
+add_subdirectory(qmetaobjectbuilder)
+add_subdirectory(qmetamethod)
+add_subdirectory(qmetaproperty)
+# add_subdirectory(qmetatype) # special case
+add_subdirectory(qmetaenum)
+if(TARGET Qt::Gui)
+ add_subdirectory(qmimedata)
+endif()
+if(TARGET Qt::Network AND NOT ANDROID AND NOT APPLE_UIKIT)
+ # add_subdirectory(qobject) # special case
+endif()
+add_subdirectory(qpointer)
+if(QT_FEATURE_private_tests AND NOT ANDROID AND NOT APPLE_UIKIT)
+ add_subdirectory(qsharedmemory)
+endif()
+add_subdirectory(qsignalblocker)
+add_subdirectory(qsignalmapper)
+if(QT_FEATURE_private_tests AND TARGET Qt::Network)
+ add_subdirectory(qsocketnotifier)
+endif()
+if(QT_FEATURE_systemsemaphore AND NOT ANDROID AND NOT APPLE_UIKIT)
+ add_subdirectory(qsystemsemaphore)
+endif()
+# add_subdirectory(qtimer) # special case
+add_subdirectory(qtranslator)
+add_subdirectory(qvariant)
+if(win32_x_ AND NOT WINRT)
+ add_subdirectory(qwineventnotifier)
+endif()
diff --git a/tests/auto/corelib/kernel/qdeadlinetimer/CMakeLists.txt b/tests/auto/corelib/kernel/qdeadlinetimer/CMakeLists.txt
new file mode 100644
index 0000000000..5feb9ff535
--- /dev/null
+++ b/tests/auto/corelib/kernel/qdeadlinetimer/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qdeadlinetimer.pro.
+
+#####################################################################
+## tst_qdeadlinetimer Test:
+#####################################################################
+
+add_qt_test(tst_qdeadlinetimer
+ SOURCES
+ tst_qdeadlinetimer.cpp
+)
diff --git a/tests/auto/corelib/kernel/qelapsedtimer/CMakeLists.txt b/tests/auto/corelib/kernel/qelapsedtimer/CMakeLists.txt
new file mode 100644
index 0000000000..e188c94933
--- /dev/null
+++ b/tests/auto/corelib/kernel/qelapsedtimer/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qelapsedtimer.pro.
+
+#####################################################################
+## tst_qelapsedtimer Test:
+#####################################################################
+
+add_qt_test(tst_qelapsedtimer
+ SOURCES
+ tst_qelapsedtimer.cpp
+)
diff --git a/tests/auto/corelib/kernel/qeventdispatcher/CMakeLists.txt b/tests/auto/corelib/kernel/qeventdispatcher/CMakeLists.txt
new file mode 100644
index 0000000000..4dbabc2d69
--- /dev/null
+++ b/tests/auto/corelib/kernel/qeventdispatcher/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qeventdispatcher.pro.
+
+#####################################################################
+## tst_qeventdispatcher Test:
+#####################################################################
+
+add_qt_test(tst_qeventdispatcher
+ SOURCES
+ tst_qeventdispatcher.cpp
+)
diff --git a/tests/auto/corelib/kernel/qeventloop/CMakeLists.txt b/tests/auto/corelib/kernel/qeventloop/CMakeLists.txt
new file mode 100644
index 0000000000..389fd55a9f
--- /dev/null
+++ b/tests/auto/corelib/kernel/qeventloop/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from qeventloop.pro.
+
+#####################################################################
+## tst_qeventloop Test:
+#####################################################################
+
+add_qt_test(tst_qeventloop
+ SOURCES
+ tst_qeventloop.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qeventloop CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ user32
+)
+
+extend_target(tst_qeventloop CONDITION QT_FEATURE_glib
+ DEFINES
+ HAVE_GLIB
+)
diff --git a/tests/auto/corelib/kernel/qmath/CMakeLists.txt b/tests/auto/corelib/kernel/qmath/CMakeLists.txt
new file mode 100644
index 0000000000..5e73597c67
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmath/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qmath.pro.
+
+#####################################################################
+## tst_qmath Test:
+#####################################################################
+
+add_qt_test(tst_qmath
+ SOURCES
+ tst_qmath.cpp
+)
diff --git a/tests/auto/corelib/kernel/qmetaenum/CMakeLists.txt b/tests/auto/corelib/kernel/qmetaenum/CMakeLists.txt
new file mode 100644
index 0000000000..12c9d9a8a7
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmetaenum/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qmetaenum.pro.
+
+#####################################################################
+## tst_qmetaenum Test:
+#####################################################################
+
+add_qt_test(tst_qmetaenum
+ SOURCES
+ tst_qmetaenum.cpp
+)
diff --git a/tests/auto/corelib/kernel/qmetamethod/CMakeLists.txt b/tests/auto/corelib/kernel/qmetamethod/CMakeLists.txt
new file mode 100644
index 0000000000..b16101a1a1
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmetamethod/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qmetamethod.pro.
+
+#####################################################################
+## tst_qmetamethod Test:
+#####################################################################
+
+add_qt_test(tst_qmetamethod
+ SOURCES
+ tst_qmetamethod.cpp
+)
diff --git a/tests/auto/corelib/kernel/qmetaobject/CMakeLists.txt b/tests/auto/corelib/kernel/qmetaobject/CMakeLists.txt
new file mode 100644
index 0000000000..e0e03051b4
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmetaobject/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qmetaobject.pro.
+
+#####################################################################
+## tst_qmetaobject Test:
+#####################################################################
+
+add_qt_test(tst_qmetaobject
+ SOURCES
+ tst_qmetaobject.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/kernel/qmetaobjectbuilder/CMakeLists.txt b/tests/auto/corelib/kernel/qmetaobjectbuilder/CMakeLists.txt
new file mode 100644
index 0000000000..b876807ba9
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmetaobjectbuilder/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qmetaobjectbuilder.pro.
+
+#####################################################################
+## tst_qmetaobjectbuilder Test:
+#####################################################################
+
+add_qt_test(tst_qmetaobjectbuilder
+ SOURCES
+ tst_qmetaobjectbuilder.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/kernel/qmetaproperty/CMakeLists.txt b/tests/auto/corelib/kernel/qmetaproperty/CMakeLists.txt
new file mode 100644
index 0000000000..2d657d5217
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmetaproperty/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qmetaproperty.pro.
+
+#####################################################################
+## tst_qmetaproperty Test:
+#####################################################################
+
+add_qt_test(tst_qmetaproperty
+ SOURCES
+ tst_qmetaproperty.cpp
+)
diff --git a/tests/auto/corelib/kernel/qmetatype/.prev_CMakeLists.txt b/tests/auto/corelib/kernel/qmetatype/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..1cc577fda7
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmetatype/.prev_CMakeLists.txt
@@ -0,0 +1,42 @@
+# Generated from qmetatype.pro.
+
+#####################################################################
+## tst_qmetatype Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "./typeFlags.bin")
+
+add_qt_test(tst_qmetatype
+ SOURCES
+ tst_qmetatype.cpp
+ DEFINES
+ -QT_NO_LINKED_LIST
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ INCLUDE_DIRECTORIES
+ ../../../other/qvariant_common
+ LIBRARIES
+ Qt::CorePrivate
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qmetatype CONDITION MSVC OR WINRT
+ COMPILE_OPTIONS
+ /bigobj
+)
+
+#### Keys ignored in scope 3:.:.:qmetatype.pro:WINRT:
+# QMAKE_CFLAGS_RELEASE = "--O2"
+# QMAKE_CXXFLAGS_RELEASE = "--O2"
+
+#### Keys ignored in scope 4:.:.:qmetatype.pro:CLANG:
+# QMAKE_CFLAGS_RELEASE = "--O2" "--g"
+# QMAKE_CXXFLAGS_RELEASE = "--O2" "--g"
+
+extend_target(tst_qmetatype CONDITION CLANG AND (TEST_architecture_arch STREQUAL "arm")
+ DEFINES
+ TST_QMETATYPE_BROKEN_COMPILER
+)
diff --git a/tests/auto/corelib/kernel/qmetatype/CMakeLists.txt b/tests/auto/corelib/kernel/qmetatype/CMakeLists.txt
new file mode 100644
index 0000000000..0a84d8bb0a
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmetatype/CMakeLists.txt
@@ -0,0 +1,42 @@
+# Generated from qmetatype.pro.
+
+#####################################################################
+## tst_qmetatype Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "./typeFlags.bin")
+
+add_qt_test(tst_qmetatype
+ SOURCES
+ tst_qmetatype.cpp
+ DEFINES
+ # -QT_NO_LINKED_LIST # special case remove until we fix this
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ INCLUDE_DIRECTORIES
+ ../../../other/qvariant_common
+ LIBRARIES
+ Qt::CorePrivate
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qmetatype CONDITION MSVC OR WINRT
+ COMPILE_OPTIONS
+ /bigobj
+)
+
+#### Keys ignored in scope 3:.:.:qmetatype.pro:WINRT:
+# QMAKE_CFLAGS_RELEASE = "--O2"
+# QMAKE_CXXFLAGS_RELEASE = "--O2"
+
+#### Keys ignored in scope 4:.:.:qmetatype.pro:CLANG:
+# QMAKE_CFLAGS_RELEASE = "--O2" "--g"
+# QMAKE_CXXFLAGS_RELEASE = "--O2" "--g"
+
+extend_target(tst_qmetatype CONDITION CLANG AND (TEST_architecture_arch STREQUAL "arm")
+ DEFINES
+ TST_QMETATYPE_BROKEN_COMPILER
+)
diff --git a/tests/auto/corelib/kernel/qmimedata/CMakeLists.txt b/tests/auto/corelib/kernel/qmimedata/CMakeLists.txt
new file mode 100644
index 0000000000..b4965302dd
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmimedata/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qmimedata.pro.
+
+#####################################################################
+## tst_qmimedata Test:
+#####################################################################
+
+add_qt_test(tst_qmimedata
+ SOURCES
+ tst_qmimedata.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/corelib/kernel/qobject/CMakeLists.txt b/tests/auto/corelib/kernel/qobject/CMakeLists.txt
new file mode 100644
index 0000000000..3be3287532
--- /dev/null
+++ b/tests/auto/corelib/kernel/qobject/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from qobject.pro.
+
+#####################################################################
+## tst_qobject Test:
+#####################################################################
+
+add_qt_test(tst_qobject
+ SOURCES
+ tst_qobject.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 3:.:.:test.pro:<TRUE>:
+# CONFIG = "testcase" "console"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 4:.:.:test.pro:QT_CONFIG___contains___c++1z:
+# CONFIG = "c++1z"
+
+if(NOT WINRT)
+ add_subdirectory(signalbug)
+endif()
diff --git a/tests/auto/corelib/kernel/qobject/signalbug/CMakeLists.txt b/tests/auto/corelib/kernel/qobject/signalbug/CMakeLists.txt
new file mode 100644
index 0000000000..e798028b1b
--- /dev/null
+++ b/tests/auto/corelib/kernel/qobject/signalbug/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from signalbug.pro.
+
+#####################################################################
+## signalbug_helper Binary:
+#####################################################################
+
+add_qt_test_helper(signalbug_helper
+ SOURCES
+ signalbug.cpp signalbug.h
+)
diff --git a/tests/auto/corelib/kernel/qpointer/CMakeLists.txt b/tests/auto/corelib/kernel/qpointer/CMakeLists.txt
new file mode 100644
index 0000000000..804a3a9def
--- /dev/null
+++ b/tests/auto/corelib/kernel/qpointer/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qpointer.pro.
+
+#####################################################################
+## tst_qpointer Test:
+#####################################################################
+
+add_qt_test(tst_qpointer
+ SOURCES
+ tst_qpointer.cpp
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qpointer CONDITION TARGET Qt::Widgets
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
diff --git a/tests/auto/corelib/kernel/qsharedmemory/CMakeLists.txt b/tests/auto/corelib/kernel/qsharedmemory/CMakeLists.txt
new file mode 100644
index 0000000000..366e76d034
--- /dev/null
+++ b/tests/auto/corelib/kernel/qsharedmemory/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from qsharedmemory.pro.
+
+
+if(QT_FEATURE_sharedmemory)
+ #####################################################################
+ ## tst_qsharedmemory Test:
+ #####################################################################
+
+ add_qt_test(tst_qsharedmemory
+ SOURCES
+ tst_qsharedmemory.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ )
+
+#### Keys ignored in scope 4:.:.:test.pro:<TRUE>:
+ # CONFIG = "testcase"
+
+ ## Scopes:
+ #####################################################################
+
+ extend_target(tst_qsharedmemory CONDITION LINUX
+ PUBLIC_LIBRARIES
+ rt
+ )
+
+ if(NOT WINRT)
+ add_subdirectory(producerconsumer)
+ endif()
+endif()
diff --git a/tests/auto/corelib/kernel/qsharedmemory/producerconsumer/CMakeLists.txt b/tests/auto/corelib/kernel/qsharedmemory/producerconsumer/CMakeLists.txt
new file mode 100644
index 0000000000..2e16a673b1
--- /dev/null
+++ b/tests/auto/corelib/kernel/qsharedmemory/producerconsumer/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from producerconsumer.pro.
+
+#####################################################################
+## producerconsumer_helper Binary:
+#####################################################################
+
+add_qt_test_helper(producerconsumer_helper
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/auto/corelib/kernel/qsignalblocker/CMakeLists.txt b/tests/auto/corelib/kernel/qsignalblocker/CMakeLists.txt
new file mode 100644
index 0000000000..ae86137c94
--- /dev/null
+++ b/tests/auto/corelib/kernel/qsignalblocker/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qsignalblocker.pro.
+
+#####################################################################
+## tst_qsignalblocker Test:
+#####################################################################
+
+add_qt_test(tst_qsignalblocker
+ SOURCES
+ tst_qsignalblocker.cpp
+)
diff --git a/tests/auto/corelib/kernel/qsignalmapper/CMakeLists.txt b/tests/auto/corelib/kernel/qsignalmapper/CMakeLists.txt
new file mode 100644
index 0000000000..1360e76ea1
--- /dev/null
+++ b/tests/auto/corelib/kernel/qsignalmapper/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qsignalmapper.pro.
+
+#####################################################################
+## tst_qsignalmapper Test:
+#####################################################################
+
+add_qt_test(tst_qsignalmapper
+ SOURCES
+ tst_qsignalmapper.cpp
+)
diff --git a/tests/auto/corelib/kernel/qsocketnotifier/CMakeLists.txt b/tests/auto/corelib/kernel/qsocketnotifier/CMakeLists.txt
new file mode 100644
index 0000000000..5b8acb7a64
--- /dev/null
+++ b/tests/auto/corelib/kernel/qsocketnotifier/CMakeLists.txt
@@ -0,0 +1,39 @@
+# Generated from qsocketnotifier.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qsocketnotifier Test:
+#####################################################################
+
+add_qt_test(tst_qsocketnotifier
+ SOURCES
+ tst_qsocketnotifier.cpp
+ INCLUDE_DIRECTORIES
+ ${QT_SOURCE_TREE}/src/network
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:qsocketnotifier.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qsocketnotifier CONDITION WIN32
+ PUBLIC_LIBRARIES
+ ws2_32
+)
+
+extend_target(tst_qsocketnotifier CONDITION QT_FEATURE_reduce_exports AND UNIX
+ SOURCES
+ ${QT_SOURCE_TREE}/src/network/socket/qabstractsocketengine.cpp ${QT_SOURCE_TREE}/src/network/socket/qabstractsocketengine_p.h
+ ${QT_SOURCE_TREE}/src/network/socket/qnativesocketengine.cpp ${QT_SOURCE_TREE}/src/network/socket/qnativesocketengine_p.h
+ ${QT_SOURCE_TREE}/src/network/socket/qnativesocketengine_unix.cpp
+)
diff --git a/tests/auto/corelib/kernel/qsystemsemaphore/CMakeLists.txt b/tests/auto/corelib/kernel/qsystemsemaphore/CMakeLists.txt
new file mode 100644
index 0000000000..1e6889eec0
--- /dev/null
+++ b/tests/auto/corelib/kernel/qsystemsemaphore/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qsystemsemaphore.pro.
+
+add_subdirectory(acquirerelease)
+#####################################################################
+## tst_qsystemsemaphore Test:
+#####################################################################
+
+add_qt_test(tst_qsystemsemaphore
+ SOURCES
+ tst_qsystemsemaphore.cpp
+)
+
+#### Keys ignored in scope 2:.:.:test.pro:<TRUE>:
+# CONFIG = "testcase"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:test.pro:WIN32:
+# CONFIG = "console"
diff --git a/tests/auto/corelib/kernel/qsystemsemaphore/acquirerelease/CMakeLists.txt b/tests/auto/corelib/kernel/qsystemsemaphore/acquirerelease/CMakeLists.txt
new file mode 100644
index 0000000000..ddce7297d2
--- /dev/null
+++ b/tests/auto/corelib/kernel/qsystemsemaphore/acquirerelease/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from acquirerelease.pro.
+
+#####################################################################
+## acquirerelease_helper Binary:
+#####################################################################
+
+add_qt_test_helper(acquirerelease_helper
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/auto/corelib/kernel/qtimer/CMakeLists.txt b/tests/auto/corelib/kernel/qtimer/CMakeLists.txt
new file mode 100644
index 0000000000..320f3a6705
--- /dev/null
+++ b/tests/auto/corelib/kernel/qtimer/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtimer.pro.
+
+#####################################################################
+## tst_qtimer Test:
+#####################################################################
+
+add_qt_test(tst_qtimer
+ SOURCES
+ tst_qtimer.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/kernel/qtranslator/CMakeLists.txt b/tests/auto/corelib/kernel/qtranslator/CMakeLists.txt
new file mode 100644
index 0000000000..79e44bc928
--- /dev/null
+++ b/tests/auto/corelib/kernel/qtranslator/CMakeLists.txt
@@ -0,0 +1,47 @@
+# Generated from qtranslator.pro.
+
+#####################################################################
+## tst_qtranslator Test:
+#####################################################################
+
+add_qt_test(tst_qtranslator
+ SOURCES
+ tst_qtranslator.cpp
+)
+
+# Resources:
+set(qtranslator_resource_files
+ "hellotr_empty.qm"
+ "hellotr_la.qm"
+)
+
+add_qt_resource(tst_qtranslator "qtranslator"
+ PREFIX
+ "/tst_qtranslator"
+ FILES
+ ${qtranslator_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ # Resources:
+ set(android_testdata_resource_files
+ "dependencies_la.qm"
+ "hellotr_empty.qm"
+ "hellotr_la.qm"
+ "msgfmt_from_po.qm"
+ )
+
+ add_qt_resource(tst_qtranslator "android_testdata"
+ PREFIX
+ "/android_testdata"
+ FILES
+ ${android_testdata_resource_files}
+ )
+endif()
+
+#### Keys ignored in scope 3:.:.:qtranslator.pro:else:
+# TESTDATA = "dependencies_la.qm" "hellotr_empty.qm" "hellotr_la.qm" "msgfmt_from_po.qm"
diff --git a/tests/auto/corelib/kernel/qvariant/.prev_CMakeLists.txt b/tests/auto/corelib/kernel/qvariant/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..102d847d95
--- /dev/null
+++ b/tests/auto/corelib/kernel/qvariant/.prev_CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from qvariant.pro.
+
+#####################################################################
+## tst_qvariant Test:
+#####################################################################
+
+add_qt_test(tst_qvariant
+ SOURCES
+ tst_qvariant.cpp
+ DEFINES
+ -QT_NO_LINKED_LIST
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ INCLUDE_DIRECTORIES
+ ../../../other/qvariant_common
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+# Resources:
+set(qvariant_resource_files
+ "stream/qt4.9/"
+ "stream/qt5.0/"
+)
+
+add_qt_resource(tst_qvariant "qvariant"
+ PREFIX
+ "/"
+ FILES
+ ${qvariant_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/kernel/qvariant/CMakeLists.txt b/tests/auto/corelib/kernel/qvariant/CMakeLists.txt
new file mode 100644
index 0000000000..b32b8835d4
--- /dev/null
+++ b/tests/auto/corelib/kernel/qvariant/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from qvariant.pro.
+
+#####################################################################
+## tst_qvariant Test:
+#####################################################################
+
+add_qt_test(tst_qvariant
+ SOURCES
+ tst_qvariant.cpp
+ DEFINES
+ # -QT_NO_LINKED_LIST # special case remove until we fix this
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ INCLUDE_DIRECTORIES
+ ../../../other/qvariant_common
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+# Resources:
+set(qvariant_resource_files
+ "stream/qt4.9/"
+ "stream/qt5.0/"
+)
+
+add_qt_resource(tst_qvariant "qvariant"
+ PREFIX
+ "/"
+ FILES
+ ${qvariant_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/kernel/qwineventnotifier/CMakeLists.txt b/tests/auto/corelib/kernel/qwineventnotifier/CMakeLists.txt
new file mode 100644
index 0000000000..af154db0de
--- /dev/null
+++ b/tests/auto/corelib/kernel/qwineventnotifier/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qwineventnotifier.pro.
+
+#####################################################################
+## tst_qwineventnotifier Test:
+#####################################################################
+
+add_qt_test(tst_qwineventnotifier
+ SOURCES
+ tst_qwineventnotifier.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/mimetypes/CMakeLists.txt b/tests/auto/corelib/mimetypes/CMakeLists.txt
new file mode 100644
index 0000000000..ea0463de36
--- /dev/null
+++ b/tests/auto/corelib/mimetypes/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from mimetypes.pro.
+
+# special case begin
+if(FEATURE_private_tests)
+# special case end
+ add_subdirectory(qmimetype)
+ add_subdirectory(qmimedatabase)
+# special case begin
+endif()
+# special case end
+
+if(NOT QT_FEATURE_private_tests)
+ ### remove_subdirectory("qmimetype")
+endif()
diff --git a/tests/auto/corelib/mimetypes/qmimedatabase/CMakeLists.txt b/tests/auto/corelib/mimetypes/qmimedatabase/CMakeLists.txt
new file mode 100644
index 0000000000..6661952a68
--- /dev/null
+++ b/tests/auto/corelib/mimetypes/qmimedatabase/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qmimedatabase.pro.
+
+
+if(TARGET Qt::Concurrent)
+ add_subdirectory(qmimedatabase-xml)
+
+ if(UNIX AND NOT APPLE AND NOT QNX)
+ add_subdirectory(qmimedatabase-cache)
+ endif()
+endif()
diff --git a/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-cache/.prev_CMakeLists.txt b/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-cache/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..ced7f27a19
--- /dev/null
+++ b/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-cache/.prev_CMakeLists.txt
@@ -0,0 +1,107 @@
+# Generated from qmimedatabase-cache.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qmimedatabase-cache Test:
+#####################################################################
+
+add_qt_test(tst_qmimedatabase-cache
+ SOURCES
+ ../tst_qmimedatabase.h
+ tst_qmimedatabase-cache.cpp
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
+
+# Resources:
+set_source_files_properties("/devel/qt5/qtbase/src/corelib/mimetypes/mime/packages/freedesktop.org.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "freedesktop.org.xml"
+)
+set(mimetypes_resource_files
+ "mime/packages/freedesktop.org.xml"
+)
+
+add_qt_resource(tst_qmimedatabase-cache "mimetypes"
+ PREFIX
+ "/qt-project.org/qmime/packages"
+ BASE
+ "/devel/qt5/qtbase/src/corelib/mimetypes"
+ FILES
+ ${mimetypes_resource_files}
+)
+set_source_files_properties("../invalid-magic1.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "invalid-magic1.xml"
+)
+set_source_files_properties("../invalid-magic2.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "invalid-magic2.xml"
+)
+set_source_files_properties("../invalid-magic3.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "invalid-magic3.xml"
+)
+set_source_files_properties("../magic-and-hierarchy.foo"
+ PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy.foo"
+)
+set_source_files_properties("../magic-and-hierarchy.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy.xml"
+)
+set_source_files_properties("../magic-and-hierarchy2.foo"
+ PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy2.foo"
+)
+set_source_files_properties("../qml-again.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "qml-again.xml"
+)
+set_source_files_properties("../test.qml"
+ PROPERTIES QT_RESOURCE_ALIAS "test.qml"
+)
+set_source_files_properties("../text-x-objcsrc.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "text-x-objcsrc.xml"
+)
+set_source_files_properties("../yast2-metapackage-handler-mimetypes.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "yast2-metapackage-handler-mimetypes.xml"
+)
+set(testdata_resource_files
+ "invalid-magic1.xml"
+ "invalid-magic2.xml"
+ "invalid-magic3.xml"
+ "magic-and-hierarchy.foo"
+ "magic-and-hierarchy.xml"
+ "magic-and-hierarchy2.foo"
+ "qml-again.xml"
+ "test.qml"
+ "text-x-objcsrc.xml"
+ "yast2-metapackage-handler-mimetypes.xml"
+)
+
+add_qt_resource(tst_qmimedatabase-cache "testdata"
+ PREFIX
+ "/qt-project.org/qmime"
+ BASE
+ ".."
+ FILES
+ ${testdata_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:qmimedatabase-cache.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qmimedatabase-cache CONDITION GCC
+ COMPILE_OPTIONS
+ -W
+ -Wall
+ -Wextra
+ -Wno-long-long
+ -Wnon-virtual-dtor
+ -Wshadow
+)
+
+extend_target(tst_qmimedatabase-cache CONDITION UNIX AND NOT APPLE AND NOT QNX
+ DEFINES
+ USE_XDG_DATA_DIRS
+)
diff --git a/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-cache/CMakeLists.txt b/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-cache/CMakeLists.txt
new file mode 100644
index 0000000000..7720e4d18e
--- /dev/null
+++ b/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-cache/CMakeLists.txt
@@ -0,0 +1,103 @@
+# Generated from qmimedatabase-cache.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qmimedatabase-cache Test:
+#####################################################################
+
+add_qt_test(tst_qmimedatabase-cache
+ SOURCES
+ ../tst_qmimedatabase.h
+ tst_qmimedatabase-cache.cpp
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
+
+# Resources:
+# special case begin
+# the freedesktop resources are handled manually below via mimetypes_resources.cmake
+#set(mimetypes_resource_files
+ #"mime/packages/freedesktop.org.xml"
+#)
+# special case end
+set_source_files_properties("../invalid-magic1.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "invalid-magic1.xml"
+)
+set_source_files_properties("../invalid-magic2.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "invalid-magic2.xml"
+)
+set_source_files_properties("../invalid-magic3.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "invalid-magic3.xml"
+)
+set_source_files_properties("../magic-and-hierarchy.foo"
+ PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy.foo"
+)
+set_source_files_properties("../magic-and-hierarchy.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy.xml"
+)
+set_source_files_properties("../magic-and-hierarchy2.foo"
+ PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy2.foo"
+)
+set_source_files_properties("../qml-again.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "qml-again.xml"
+)
+set_source_files_properties("../test.qml"
+ PROPERTIES QT_RESOURCE_ALIAS "test.qml"
+)
+set_source_files_properties("../text-x-objcsrc.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "text-x-objcsrc.xml"
+)
+set_source_files_properties("../yast2-metapackage-handler-mimetypes.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "yast2-metapackage-handler-mimetypes.xml"
+)
+set(testdata_resource_files
+ "invalid-magic1.xml"
+ "invalid-magic2.xml"
+ "invalid-magic3.xml"
+ "magic-and-hierarchy.foo"
+ "magic-and-hierarchy.xml"
+ "magic-and-hierarchy2.foo"
+ "qml-again.xml"
+ "test.qml"
+ "text-x-objcsrc.xml"
+ "yast2-metapackage-handler-mimetypes.xml"
+)
+
+add_qt_resource(tst_qmimedatabase-cache "testdata"
+ PREFIX
+ "/qt-project.org/qmime"
+ BASE
+ ".."
+ FILES
+ ${testdata_resource_files}
+)
+
+# special case begin
+set(corelib_source_dir ../../../../../../src/corelib)
+include(${corelib_source_dir}/mimetypes/mimetypes_resources.cmake)
+corelib_add_mimetypes_resources(tst_qmimedatabase-cache)
+# special case end
+
+#### Keys ignored in scope 1:.:.:qmimedatabase-cache.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qmimedatabase-cache CONDITION GCC
+ COMPILE_OPTIONS
+ -W
+ -Wall
+ -Wextra
+ -Wno-long-long
+ -Wnon-virtual-dtor
+ -Wshadow
+)
+
+extend_target(tst_qmimedatabase-cache CONDITION UNIX AND NOT APPLE AND NOT QNX
+ DEFINES
+ USE_XDG_DATA_DIRS
+)
diff --git a/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/.prev_CMakeLists.txt b/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..7f34b06fab
--- /dev/null
+++ b/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/.prev_CMakeLists.txt
@@ -0,0 +1,107 @@
+# Generated from qmimedatabase-xml.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qmimedatabase-xml Test:
+#####################################################################
+
+add_qt_test(tst_qmimedatabase-xml
+ SOURCES
+ ../tst_qmimedatabase.h
+ tst_qmimedatabase-xml.cpp
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
+
+# Resources:
+set_source_files_properties("/devel/qt5/qtbase/src/corelib/mimetypes/mime/packages/freedesktop.org.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "freedesktop.org.xml"
+)
+set(mimetypes_resource_files
+ "mime/packages/freedesktop.org.xml"
+)
+
+add_qt_resource(tst_qmimedatabase-xml "mimetypes"
+ PREFIX
+ "/qt-project.org/qmime/packages"
+ BASE
+ "/devel/qt5/qtbase/src/corelib/mimetypes"
+ FILES
+ ${mimetypes_resource_files}
+)
+set_source_files_properties("../invalid-magic1.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "invalid-magic1.xml"
+)
+set_source_files_properties("../invalid-magic2.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "invalid-magic2.xml"
+)
+set_source_files_properties("../invalid-magic3.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "invalid-magic3.xml"
+)
+set_source_files_properties("../magic-and-hierarchy.foo"
+ PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy.foo"
+)
+set_source_files_properties("../magic-and-hierarchy.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy.xml"
+)
+set_source_files_properties("../magic-and-hierarchy2.foo"
+ PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy2.foo"
+)
+set_source_files_properties("../qml-again.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "qml-again.xml"
+)
+set_source_files_properties("../test.qml"
+ PROPERTIES QT_RESOURCE_ALIAS "test.qml"
+)
+set_source_files_properties("../text-x-objcsrc.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "text-x-objcsrc.xml"
+)
+set_source_files_properties("../yast2-metapackage-handler-mimetypes.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "yast2-metapackage-handler-mimetypes.xml"
+)
+set(testdata_resource_files
+ "invalid-magic1.xml"
+ "invalid-magic2.xml"
+ "invalid-magic3.xml"
+ "magic-and-hierarchy.foo"
+ "magic-and-hierarchy.xml"
+ "magic-and-hierarchy2.foo"
+ "qml-again.xml"
+ "test.qml"
+ "text-x-objcsrc.xml"
+ "yast2-metapackage-handler-mimetypes.xml"
+)
+
+add_qt_resource(tst_qmimedatabase-xml "testdata"
+ PREFIX
+ "/qt-project.org/qmime"
+ BASE
+ ".."
+ FILES
+ ${testdata_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:qmimedatabase-xml.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qmimedatabase-xml CONDITION GCC
+ COMPILE_OPTIONS
+ -W
+ -Wall
+ -Wextra
+ -Wno-long-long
+ -Wnon-virtual-dtor
+ -Wshadow
+)
+
+extend_target(tst_qmimedatabase-xml CONDITION UNIX AND NOT APPLE AND NOT QNX
+ DEFINES
+ USE_XDG_DATA_DIRS
+)
diff --git a/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt b/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt
new file mode 100644
index 0000000000..cf8e349226
--- /dev/null
+++ b/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt
@@ -0,0 +1,103 @@
+# Generated from qmimedatabase-xml.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qmimedatabase-xml Test:
+#####################################################################
+
+add_qt_test(tst_qmimedatabase-xml
+ SOURCES
+ ../tst_qmimedatabase.h
+ tst_qmimedatabase-xml.cpp
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
+
+# Resources:
+# special case begin
+# the freedesktop resources are handled manually below via mimetypes_resources.cmake
+#set(mimetypes_resource_files
+ #"mime/packages/freedesktop.org.xml"
+#)
+# special case end
+set_source_files_properties("../invalid-magic1.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "invalid-magic1.xml"
+)
+set_source_files_properties("../invalid-magic2.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "invalid-magic2.xml"
+)
+set_source_files_properties("../invalid-magic3.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "invalid-magic3.xml"
+)
+set_source_files_properties("../magic-and-hierarchy.foo"
+ PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy.foo"
+)
+set_source_files_properties("../magic-and-hierarchy.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy.xml"
+)
+set_source_files_properties("../magic-and-hierarchy2.foo"
+ PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy2.foo"
+)
+set_source_files_properties("../qml-again.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "qml-again.xml"
+)
+set_source_files_properties("../test.qml"
+ PROPERTIES QT_RESOURCE_ALIAS "test.qml"
+)
+set_source_files_properties("../text-x-objcsrc.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "text-x-objcsrc.xml"
+)
+set_source_files_properties("../yast2-metapackage-handler-mimetypes.xml"
+ PROPERTIES QT_RESOURCE_ALIAS "yast2-metapackage-handler-mimetypes.xml"
+)
+set(testdata_resource_files
+ "invalid-magic1.xml"
+ "invalid-magic2.xml"
+ "invalid-magic3.xml"
+ "magic-and-hierarchy.foo"
+ "magic-and-hierarchy.xml"
+ "magic-and-hierarchy2.foo"
+ "qml-again.xml"
+ "test.qml"
+ "text-x-objcsrc.xml"
+ "yast2-metapackage-handler-mimetypes.xml"
+)
+
+add_qt_resource(tst_qmimedatabase-xml "testdata"
+ PREFIX
+ "/qt-project.org/qmime"
+ BASE
+ ".."
+ FILES
+ ${testdata_resource_files}
+)
+
+# special case begin
+set(corelib_source_dir ../../../../../../src/corelib)
+include(${corelib_source_dir}/mimetypes/mimetypes_resources.cmake)
+corelib_add_mimetypes_resources(tst_qmimedatabase-xml)
+# special case end
+
+#### Keys ignored in scope 1:.:.:qmimedatabase-xml.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qmimedatabase-xml CONDITION GCC
+ COMPILE_OPTIONS
+ -W
+ -Wall
+ -Wextra
+ -Wno-long-long
+ -Wnon-virtual-dtor
+ -Wshadow
+)
+
+extend_target(tst_qmimedatabase-xml CONDITION UNIX AND NOT APPLE AND NOT QNX
+ DEFINES
+ USE_XDG_DATA_DIRS
+)
diff --git a/tests/auto/corelib/mimetypes/qmimetype/CMakeLists.txt b/tests/auto/corelib/mimetypes/qmimetype/CMakeLists.txt
new file mode 100644
index 0000000000..ef966a6424
--- /dev/null
+++ b/tests/auto/corelib/mimetypes/qmimetype/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qmimetype.pro.
+
+#####################################################################
+## tst_qmimetype Test:
+#####################################################################
+
+add_qt_test(tst_qmimetype
+ SOURCES
+ tst_qmimetype.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/plugin/CMakeLists.txt b/tests/auto/corelib/plugin/CMakeLists.txt
new file mode 100644
index 0000000000..710d471e8a
--- /dev/null
+++ b/tests/auto/corelib/plugin/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from plugin.pro.
+
+if(QT_BUILD_SHARED_LIBS)
+ add_subdirectory(qfactoryloader)
+endif()
+add_subdirectory(quuid)
+if(QT_FEATURE_library)
+ add_subdirectory(qpluginloader)
+ add_subdirectory(qlibrary)
+endif()
+if(QT_BUILD_SHARED_LIBS AND QT_FEATURE_library)
+ add_subdirectory(qplugin)
+endif()
diff --git a/tests/auto/corelib/plugin/qfactoryloader/CMakeLists.txt b/tests/auto/corelib/plugin/qfactoryloader/CMakeLists.txt
new file mode 100644
index 0000000000..6263be15a2
--- /dev/null
+++ b/tests/auto/corelib/plugin/qfactoryloader/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from qfactoryloader.pro.
+
+add_subdirectory(plugin1)
+add_subdirectory(plugin2)
+add_subdirectory(test)
diff --git a/tests/auto/corelib/plugin/qfactoryloader/plugin1/CMakeLists.txt b/tests/auto/corelib/plugin/qfactoryloader/plugin1/CMakeLists.txt
new file mode 100644
index 0000000000..940dcc2b09
--- /dev/null
+++ b/tests/auto/corelib/plugin/qfactoryloader/plugin1/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from plugin1.pro.
+
+#####################################################################
+## plugin1 Generic Library:
+#####################################################################
+
+add_cmake_library(plugin1
+ MODULE
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qfactoryloader/bin"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../bin"
+ SOURCES
+ plugin1.cpp plugin1.h
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:plugin1.pro:<TRUE>:
+# INSTALLS = "target"
+# TEMPLATE = "lib"
+# target.path = "$$[QT_INSTALL_TESTS]/tst_qfactoryloader/bin"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 6:.:..:../winrt.pri:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug/bin"
+
+#### Keys ignored in scope 7:.:..:../winrt.pri:else:
+# DESTDIR = "../release/bin"
+
+extend_target(plugin1 CONDITION NOT QT_FEATURE_library
+ DEFINES
+ QT_STATICPLUGIN
+)
+
+qt_autogen_tools_initial_setup(plugin1)
diff --git a/tests/auto/corelib/plugin/qfactoryloader/plugin2/CMakeLists.txt b/tests/auto/corelib/plugin/qfactoryloader/plugin2/CMakeLists.txt
new file mode 100644
index 0000000000..2df999c292
--- /dev/null
+++ b/tests/auto/corelib/plugin/qfactoryloader/plugin2/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from plugin2.pro.
+
+#####################################################################
+## plugin2 Generic Library:
+#####################################################################
+
+add_cmake_library(plugin2
+ MODULE
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qfactoryloader/bin"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../bin"
+ SOURCES
+ plugin2.cpp plugin2.h
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:plugin2.pro:<TRUE>:
+# INSTALLS = "target"
+# TEMPLATE = "lib"
+# target.path = "$$[QT_INSTALL_TESTS]/tst_qfactoryloader/bin"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 6:.:..:../winrt.pri:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug/bin"
+
+#### Keys ignored in scope 7:.:..:../winrt.pri:else:
+# DESTDIR = "../release/bin"
+
+extend_target(plugin2 CONDITION NOT QT_FEATURE_library
+ DEFINES
+ QT_STATICPLUGIN
+)
+
+qt_autogen_tools_initial_setup(plugin2)
diff --git a/tests/auto/corelib/plugin/qfactoryloader/test/.prev_CMakeLists.txt b/tests/auto/corelib/plugin/qfactoryloader/test/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..b388bb65cf
--- /dev/null
+++ b/tests/auto/corelib/plugin/qfactoryloader/test/.prev_CMakeLists.txt
@@ -0,0 +1,42 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qfactoryloader Test:
+#####################################################################
+
+add_qt_test(tst_qfactoryloader
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ SOURCES
+ ../plugin1/plugininterface1.h
+ ../plugin2/plugininterface2.h
+ ../tst_qfactoryloader.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qfactoryloader CONDITION NOT QT_FEATURE_library
+ PUBLIC_LIBRARIES
+ # Remove: L
+ ../bin/
+ plugin1
+ plugin2
+)
+
+if(ANDROID)
+ # Resources:
+ set(qmake_libs_resource_files
+ ${CMAKE_CURRENT_BINARY_DIR}/../bin
+ )
+
+ add_qt_resource(tst_qfactoryloader "qmake_libs"
+ PREFIX
+ "android_test_data"
+ BASE
+ "${CMAKE_CURRENT_BINARY_DIR}/.."
+ FILES
+ ${qmake_libs_resource_files}
+ )
+endif()
diff --git a/tests/auto/corelib/plugin/qfactoryloader/test/CMakeLists.txt b/tests/auto/corelib/plugin/qfactoryloader/test/CMakeLists.txt
new file mode 100644
index 0000000000..509a88da0c
--- /dev/null
+++ b/tests/auto/corelib/plugin/qfactoryloader/test/CMakeLists.txt
@@ -0,0 +1,68 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qfactoryloader Test:
+#####################################################################
+
+add_qt_test(tst_qfactoryloader
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ SOURCES
+ ../plugin1/plugininterface1.h
+ ../plugin2/plugininterface2.h
+ ../tst_qfactoryloader.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+## Scopes:
+#####################################################################
+
+# special case begin
+if (NOT QT_FEATURE_library)
+ target_link_directories(tst_qfactoryloader PRIVATE "${CMAKE_CURRENT_BINARY_DIR}../bin")
+endif()
+# special case end
+
+extend_target(tst_qfactoryloader CONDITION NOT QT_FEATURE_library
+ PUBLIC_LIBRARIES
+ # Remove: L
+ # special case begin
+ # this part is handled as a special case above
+ # ../bin/
+ # special case end
+)
+
+if(ANDROID)
+ # special case begin
+ set_source_files_properties(
+ ${CMAKE_CURRENT_BINARY_DIR}/../bin/libplugin1.so
+ PROPERTIES QT_RESOURCE_TARGET_DEPENDENCY plugin1
+ )
+
+ set_source_files_properties(
+ ${CMAKE_CURRENT_BINARY_DIR}/../bin/libplugin2.so
+ PROPERTIES QT_RESOURCE_TARGET_DEPENDENCY plugin2
+ )
+ # Resources:
+ if (ANDROID)
+ set(qmake_libs_resource_files
+ bin/libplugin1_${CMAKE_ANDROID_ARCH_ABI}.so
+ bin/libplugin2_${CMAKE_ANDROID_ARCH_ABI}.so
+ )
+ else()
+ set(qmake_libs_resource_files
+ bin/libplugin1.so
+ bin/libplugin2.so
+ )
+ endif()
+ # special case end
+
+ add_qt_resource(tst_qfactoryloader "qmake_libs"
+ PREFIX
+ "android_test_data"
+ BASE
+ "${CMAKE_CURRENT_BINARY_DIR}/.."
+ FILES
+ ${qmake_libs_resource_files}
+ )
+endif()
diff --git a/tests/auto/corelib/plugin/qlibrary/CMakeLists.txt b/tests/auto/corelib/plugin/qlibrary/CMakeLists.txt
new file mode 100644
index 0000000000..c0faebc91d
--- /dev/null
+++ b/tests/auto/corelib/plugin/qlibrary/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from qlibrary.pro.
+
+add_subdirectory(lib)
+add_subdirectory(lib2)
+add_subdirectory(tst)
diff --git a/tests/auto/corelib/plugin/qlibrary/lib/.prev_CMakeLists.txt b/tests/auto/corelib/plugin/qlibrary/lib/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..6dbbd7a060
--- /dev/null
+++ b/tests/auto/corelib/plugin/qlibrary/lib/.prev_CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from lib.pro.
+
+#####################################################################
+## mylib Generic Library:
+#####################################################################
+
+add_cmake_library(mylib
+ SHARED
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qlibrary"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ SOURCES
+ mylib.c
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:lib.pro:<TRUE>:
+# INSTALLS = "target"
+# TEMPLATE = "lib"
+# target.path = "$$[QT_INSTALL_TESTS]/tst_qlibrary"
+
+## Scopes:
+#####################################################################
+
+extend_target(mylib CONDITION MSVC
+ DEFINES
+ WIN32_MSVC
+)
+
+#### Keys ignored in scope 4:.:.:lib.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug/"
+
+#### Keys ignored in scope 5:.:.:lib.pro:else:
+# DESTDIR = "../release/"
diff --git a/tests/auto/corelib/plugin/qlibrary/lib/CMakeLists.txt b/tests/auto/corelib/plugin/qlibrary/lib/CMakeLists.txt
new file mode 100644
index 0000000000..f2de91635a
--- /dev/null
+++ b/tests/auto/corelib/plugin/qlibrary/lib/CMakeLists.txt
@@ -0,0 +1,43 @@
+# Generated from lib.pro.
+
+#####################################################################
+## mylib Generic Library:
+#####################################################################
+
+add_cmake_library(mylib
+ SHARED
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qlibrary"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ SOURCES
+ mylib.c
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+# special case begin
+set_target_properties(mylib PROPERTIES
+ VERSION 1.0.0
+ SOVERSION 1
+ C_VISIBILITY_PRESET "default"
+ CXX_VISIBILITY_PRESET "default"
+)
+# special case end
+
+#### Keys ignored in scope 1:.:.:lib.pro:<TRUE>:
+# INSTALLS = "target"
+# TEMPLATE = "lib"
+# target.path = "$$[QT_INSTALL_TESTS]/tst_qlibrary"
+
+## Scopes:
+#####################################################################
+
+extend_target(mylib CONDITION MSVC
+ DEFINES
+ WIN32_MSVC
+)
+
+#### Keys ignored in scope 4:.:.:lib.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug/"
+
+#### Keys ignored in scope 5:.:.:lib.pro:else:
+# DESTDIR = "../release/"
diff --git a/tests/auto/corelib/plugin/qlibrary/lib2/CMakeLists.txt b/tests/auto/corelib/plugin/qlibrary/lib2/CMakeLists.txt
new file mode 100644
index 0000000000..716ad488d0
--- /dev/null
+++ b/tests/auto/corelib/plugin/qlibrary/lib2/CMakeLists.txt
@@ -0,0 +1,104 @@
+# Generated from lib2.pro.
+
+#####################################################################
+## mylib Generic Library:
+#####################################################################
+
+add_cmake_library(mylib2 # special case
+ SHARED
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}tst_qlibrary"
+ #OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../" # special case
+ SOURCES
+ mylib.c
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+# special case begin
+# This test is very "annoying" to get working with CMake as it involves having
+# two targets with the same name on the parent scope, which is not possible with
+# CMake. Furthermore, on UNIX, this version of the library should override the
+# root symlink (libmylib.so) to point to version 2.
+# Since we can't build two targets with the same name and in the same directory,
+# we build mylib2 in it's own directory and manually copy and create the
+# symlinks in the parent directory.
+# Finally we also need to create a libmylib.so2 file in the parent directory.
+#
+set_target_properties(mylib2 PROPERTIES
+ OUTPUT_NAME mylib
+)
+set_target_properties(mylib2 PROPERTIES
+ VERSION 2.0.0
+ SOVERSION 2
+ C_VISIBILITY_PRESET "default"
+ CXX_VISIBILITY_PRESET "default"
+)
+if (UNIX)
+ add_dependencies(mylib2 mylib)
+ add_custom_command(TARGET mylib2 POST_BUILD
+ COMMAND ${CMAKE_COMMAND} -E copy_if_different
+ $<TARGET_FILE:mylib2>
+ "${CMAKE_CURRENT_BINARY_DIR}/../system.qt.test.mylib.so"
+ COMMAND ${CMAKE_COMMAND} -E copy_if_different
+ $<TARGET_FILE:mylib2>
+ "${CMAKE_CURRENT_BINARY_DIR}/../libmylib.so.2.0.0"
+ COMMAND ${CMAKE_COMMAND} -E create_symlink
+ "${CMAKE_CURRENT_BINARY_DIR}/../libmylib.so.2.0.0"
+ "${CMAKE_CURRENT_BINARY_DIR}/../libmylib.so.2"
+ COMMAND ${CMAKE_COMMAND} -E remove
+ "${CMAKE_CURRENT_BINARY_DIR}/../libmylib.so"
+ COMMAND ${CMAKE_COMMAND} -E create_symlink
+ "${CMAKE_CURRENT_BINARY_DIR}/../libmylib.so.2.0.0"
+ "${CMAKE_CURRENT_BINARY_DIR}/../libmylib.so"
+ COMMAND ${CMAKE_COMMAND} -E create_symlink
+ "${CMAKE_CURRENT_BINARY_DIR}/../libmylib.so.2.0.0"
+ "${CMAKE_CURRENT_BINARY_DIR}/../libmylib.so2"
+ )
+else() #Win32
+ add_custom_command(TARGET mylib2 POST_BUILD
+ COMMAND ${CMAKE_COMMAND} -E copy_if_different
+ $<TARGET_FILE:mylib2>
+ "${CMAKE_CURRENT_BINARY_DIR}/../system.qt.test.mylib.dll"
+ COMMAND ${CMAKE_COMMAND} -E copy_if_different
+ $<TARGET_FILE:mylib2>
+ "${CMAKE_CURRENT_BINARY_DIR}/../mylib.dl2"
+ )
+endif()
+# special case end
+
+#### Keys ignored in scope 1:.:.:lib2.pro:<TRUE>:
+# INSTALLS = "target" "renamed_target"
+# QMAKE_POST_LINK = "$$member(QMAKE_POST_LINK, 0, -2)"
+# TEMPLATE = "lib"
+# VERSION = "2"
+# renamed_target.extra = "$$member(renamed_target.extra, 0, -2)"
+# renamed_target.path = "$$target.path"
+# target.path = "$$[QT_INSTALL_TESTS]$${QMAKE_DIR_SEP}tst_qlibrary"
+
+## Scopes:
+#####################################################################
+
+extend_target(mylib2 CONDITION MSVC # special case
+ DEFINES
+ WIN32_MSVC
+)
+
+#### Keys ignored in scope 3:.:.:lib2.pro:WIN32:
+# DESTDIR = "../$$BUILD_FOLDER/"
+# files = "$$BUILD_FOLDER$${QMAKE_DIR_SEP}mylib.dl2" "$$BUILD_FOLDER$${QMAKE_DIR_SEP}system.qt.test.mylib.dll"
+
+#### Keys ignored in scope 4:.:.:lib2.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# BUILD_FOLDER = "debug"
+
+#### Keys ignored in scope 5:.:.:lib2.pro:else:
+# BUILD_FOLDER = "release"
+
+#### Keys ignored in scope 6:.:.:lib2.pro:TEMPLATE___contains___vc._x_:
+# src = "$(TargetPath)"
+
+#### Keys ignored in scope 7:.:.:lib2.pro:else:
+# src = "$(DESTDIR_TARGET)"
+
+#### Keys ignored in scope 8:.:.:lib2.pro:else:
+# files = "libmylib.so2" "system.qt.test.mylib.so"
+# src = "$(DESTDIR)$(TARGET)"
diff --git a/tests/auto/corelib/plugin/qlibrary/tst/.prev_CMakeLists.txt b/tests/auto/corelib/plugin/qlibrary/tst/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..ac6515ba63
--- /dev/null
+++ b/tests/auto/corelib/plugin/qlibrary/tst/.prev_CMakeLists.txt
@@ -0,0 +1,37 @@
+# Generated from tst.pro.
+
+#####################################################################
+## tst_qlibrary Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "../library_path/invalid.so")
+
+add_qt_test(tst_qlibrary
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ SOURCES
+ ../tst_qlibrary.cpp
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+if(ANDROID)
+ # Resources:
+ set(qmake_libs_resource_files
+ ${CMAKE_CURRENT_BINARY_DIR}/../libmylib.prl
+ ${CMAKE_CURRENT_BINARY_DIR}/../libmylib.so
+ ${CMAKE_CURRENT_BINARY_DIR}/../libmylib.so2
+ ${CMAKE_CURRENT_BINARY_DIR}/../system.qt.test.mylib.so
+ )
+
+ add_qt_resource(tst_qlibrary "qmake_libs"
+ PREFIX
+ "android_test_data"
+ BASE
+ "${CMAKE_CURRENT_BINARY_DIR}/.."
+ FILES
+ ${qmake_libs_resource_files}
+ )
+endif()
diff --git a/tests/auto/corelib/plugin/qlibrary/tst/CMakeLists.txt b/tests/auto/corelib/plugin/qlibrary/tst/CMakeLists.txt
new file mode 100644
index 0000000000..e6086a982f
--- /dev/null
+++ b/tests/auto/corelib/plugin/qlibrary/tst/CMakeLists.txt
@@ -0,0 +1,50 @@
+# Generated from tst.pro.
+
+#####################################################################
+## tst_qlibrary Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "../library_path/invalid.so")
+
+add_qt_test(tst_qlibrary
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ SOURCES
+ ../tst_qlibrary.cpp
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+if(ANDROID)
+ # special case begin
+ set_source_files_properties(
+ ${CMAKE_CURRENT_BINARY_DIR}/../libmylib.so
+ PROPERTIES QT_RESOURCE_TARGET_DEPENDENCY mylib
+ )
+ set_source_files_properties(
+ ${CMAKE_CURRENT_BINARY_DIR}/../libmylib.so2
+ ${CMAKE_CURRENT_BINARY_DIR}/../system.qt.test.mylib.so
+ PROPERTIES QT_RESOURCE_TARGET_DEPENDENCY mylib2
+ )
+ # special case end
+ # Resources:
+ set(qmake_libs_resource_files
+ # special case begin
+ #libmylib.prl
+ libmylib.so
+ libmylib.so2
+ system.qt.test.mylib.so
+ # special case end
+ )
+
+ add_qt_resource(tst_qlibrary "qmake_libs"
+ PREFIX
+ "android_test_data"
+ BASE
+ "${CMAKE_CURRENT_BINARY_DIR}/.."
+ FILES
+ ${qmake_libs_resource_files}
+ )
+endif()
diff --git a/tests/auto/corelib/plugin/qplugin/.prev_CMakeLists.txt b/tests/auto/corelib/plugin/qplugin/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..7e6ccc966d
--- /dev/null
+++ b/tests/auto/corelib/plugin/qplugin/.prev_CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from qplugin.pro.
+
+add_subdirectory(invalidplugin)
diff --git a/tests/auto/corelib/plugin/qplugin/CMakeLists.txt b/tests/auto/corelib/plugin/qplugin/CMakeLists.txt
new file mode 100644
index 0000000000..efc810075a
--- /dev/null
+++ b/tests/auto/corelib/plugin/qplugin/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from qplugin.pro.
+
+add_subdirectory(invalidplugin)
+
+# special case begin
+add_subdirectory(debugplugin)
+add_subdirectory(releaseplugin)
+
+# The contents below are generated from ./tst_qplugin.pro
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ plugins/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qplugin
+ SOURCES
+ tst_qplugin.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ TESTDATA ${test_data}
+)
+
+add_dependencies(tst_qplugin invalidplugin debugplugin releaseplugin)
+# special case end
diff --git a/tests/auto/corelib/plugin/qplugin/debugplugin/CMakeLists.txt b/tests/auto/corelib/plugin/qplugin/debugplugin/CMakeLists.txt
new file mode 100644
index 0000000000..ab32e5e364
--- /dev/null
+++ b/tests/auto/corelib/plugin/qplugin/debugplugin/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from debugplugin.pro.
+
+#####################################################################
+## debugplugin Generic Library:
+#####################################################################
+
+add_cmake_library(debugplugin
+ MODULE
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../plugins"
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:debugplugin.pro:<TRUE>:
+# TEMPLATE = "lib"
+
+qt_autogen_tools_initial_setup(debugplugin)
diff --git a/tests/auto/corelib/plugin/qplugin/invalidplugin/CMakeLists.txt b/tests/auto/corelib/plugin/qplugin/invalidplugin/CMakeLists.txt
new file mode 100644
index 0000000000..c3eb37d930
--- /dev/null
+++ b/tests/auto/corelib/plugin/qplugin/invalidplugin/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from invalidplugin.pro.
+
+#####################################################################
+## invalidplugin Generic Library:
+#####################################################################
+
+add_cmake_library(invalidplugin
+ MODULE
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../plugins"
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:invalidplugin.pro:<TRUE>:
+# TEMPLATE = "lib"
+
+qt_autogen_tools_initial_setup(invalidplugin)
diff --git a/tests/auto/corelib/plugin/qplugin/releaseplugin/CMakeLists.txt b/tests/auto/corelib/plugin/qplugin/releaseplugin/CMakeLists.txt
new file mode 100644
index 0000000000..893386bc6b
--- /dev/null
+++ b/tests/auto/corelib/plugin/qplugin/releaseplugin/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from releaseplugin.pro.
+
+#####################################################################
+## releaseplugin Generic Library:
+#####################################################################
+
+add_cmake_library(releaseplugin
+ MODULE
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../plugins"
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:releaseplugin.pro:<TRUE>:
+# TEMPLATE = "lib"
+
+qt_autogen_tools_initial_setup(releaseplugin)
diff --git a/tests/auto/corelib/plugin/qpluginloader/CMakeLists.txt b/tests/auto/corelib/plugin/qpluginloader/CMakeLists.txt
new file mode 100644
index 0000000000..ba7d375e3b
--- /dev/null
+++ b/tests/auto/corelib/plugin/qpluginloader/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qpluginloader.pro.
+
+add_subdirectory(lib)
+add_subdirectory(staticplugin)
+add_subdirectory(theplugin)
+add_subdirectory(tst)
+if(UNIX AND NOT ANDROID AND NOT APPLE)
+ add_subdirectory(almostplugin)
+endif()
+if(APPLE_OSX AND QT_FEATURE_private_tests AND TARGET Qt::Gui)
+ add_subdirectory(machtest)
+endif()
diff --git a/tests/auto/corelib/plugin/qpluginloader/almostplugin/.prev_CMakeLists.txt b/tests/auto/corelib/plugin/qpluginloader/almostplugin/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..5e42a1aef0
--- /dev/null
+++ b/tests/auto/corelib/plugin/qpluginloader/almostplugin/.prev_CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from almostplugin.pro.
+
+#####################################################################
+## almostplugin Generic Library:
+#####################################################################
+
+add_cmake_library(almostplugin
+ MODULE
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qpluginloader/bin"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../bin"
+ SOURCES
+ almostplugin.cpp almostplugin.h
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:almostplugin.pro:<TRUE>:
+# INSTALLS = "target"
+# TEMPLATE = "lib"
+# target.path = "$$[QT_INSTALL_TESTS]/tst_qpluginloader/bin"
+
+## Scopes:
+#####################################################################
+
+extend_target(almostplugin CONDITION GCC
+ LINK_OPTIONS
+ "--Wl,--no-undefined"
+)
+
+qt_autogen_tools_initial_setup(almostplugin)
diff --git a/tests/auto/corelib/plugin/qpluginloader/almostplugin/CMakeLists.txt b/tests/auto/corelib/plugin/qpluginloader/almostplugin/CMakeLists.txt
new file mode 100644
index 0000000000..5208a70c9d
--- /dev/null
+++ b/tests/auto/corelib/plugin/qpluginloader/almostplugin/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from almostplugin.pro.
+
+#####################################################################
+## almostplugin Generic Library:
+#####################################################################
+
+add_cmake_library(almostplugin
+ MODULE
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qpluginloader/bin"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../bin"
+ SOURCES
+ almostplugin.cpp almostplugin.h
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:almostplugin.pro:<TRUE>:
+# INSTALLS = "target"
+# TEMPLATE = "lib"
+# target.path = "$$[QT_INSTALL_TESTS]/tst_qpluginloader/bin"
+
+## Scopes:
+#####################################################################
+
+qt_autogen_tools_initial_setup(almostplugin)
+# special case begin
+# We want the opposite of this
+#extend_target(almostplugin CONDITION GCC
+# LINK_OPTIONS
+# "--Wl,--no-undefined"
+#)
+# special case end
diff --git a/tests/auto/corelib/plugin/qpluginloader/lib/.prev_CMakeLists.txt b/tests/auto/corelib/plugin/qpluginloader/lib/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..74945fc6d8
--- /dev/null
+++ b/tests/auto/corelib/plugin/qpluginloader/lib/.prev_CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from lib.pro.
+
+#####################################################################
+## tst_qpluginloaderlib Generic Library:
+#####################################################################
+
+add_cmake_library(tst_qpluginloaderlib
+ SHARED
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qpluginloader/bin"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../bin"
+ SOURCES
+ mylib.c
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:lib.pro:<TRUE>:
+# INSTALLS = "target"
+# TEMPLATE = "lib"
+# target.path = "$$[QT_INSTALL_TESTS]/tst_qpluginloader/bin"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 6:.:..:../winrt.pri:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug/bin"
+
+#### Keys ignored in scope 7:.:..:../winrt.pri:else:
+# DESTDIR = "../release/bin"
+
+extend_target(tst_qpluginloaderlib CONDITION MSVC
+ DEFINES
+ WIN32_MSVC
+)
diff --git a/tests/auto/corelib/plugin/qpluginloader/lib/CMakeLists.txt b/tests/auto/corelib/plugin/qpluginloader/lib/CMakeLists.txt
new file mode 100644
index 0000000000..8d723cf3ce
--- /dev/null
+++ b/tests/auto/corelib/plugin/qpluginloader/lib/CMakeLists.txt
@@ -0,0 +1,41 @@
+# Generated from lib.pro.
+
+#####################################################################
+## tst_qpluginloaderlib Generic Library:
+#####################################################################
+
+add_cmake_library(tst_qpluginloaderlib
+ SHARED
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qpluginloader/bin"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../bin"
+ SOURCES
+ mylib.c
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:lib.pro:<TRUE>:
+# INSTALLS = "target"
+# TEMPLATE = "lib"
+# target.path = "$$[QT_INSTALL_TESTS]/tst_qpluginloader/bin"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 6:.:..:../winrt.pri:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug/bin"
+
+#### Keys ignored in scope 7:.:..:../winrt.pri:else:
+# DESTDIR = "../release/bin"
+
+extend_target(tst_qpluginloaderlib CONDITION MSVC
+ DEFINES
+ WIN32_MSVC
+)
+
+# special case begin
+set_target_properties(tst_qpluginloaderlib PROPERTIES
+ C_VISIBILITY_PRESET "default"
+ CXX_VISIBILITY_PRESET "default"
+)
+# special case end
diff --git a/tests/auto/corelib/plugin/qpluginloader/machtest/CMakeLists.txt b/tests/auto/corelib/plugin/qpluginloader/machtest/CMakeLists.txt
new file mode 100644
index 0000000000..05cd044aa3
--- /dev/null
+++ b/tests/auto/corelib/plugin/qpluginloader/machtest/CMakeLists.txt
@@ -0,0 +1,2 @@
+# Generated from machtest.pro.
+
diff --git a/tests/auto/corelib/plugin/qpluginloader/staticplugin/.prev_CMakeLists.txt b/tests/auto/corelib/plugin/qpluginloader/staticplugin/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..bfc30d7c1d
--- /dev/null
+++ b/tests/auto/corelib/plugin/qpluginloader/staticplugin/.prev_CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from staticplugin.pro.
+
+#####################################################################
+## staticplugin Generic Library:
+#####################################################################
+
+add_cmake_library(staticplugin
+ STATIC
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Core
+ MOC_OPTIONS
+ "-M"
+ "ExtraMetaData=StaticPlugin"
+ "-M"
+ "ExtraMetaData=foo"
+)
+
+#### Keys ignored in scope 1:.:.:staticplugin.pro:<TRUE>:
+# TEMPLATE = "lib"
+
+qt_autogen_tools_initial_setup(staticplugin)
diff --git a/tests/auto/corelib/plugin/qpluginloader/staticplugin/CMakeLists.txt b/tests/auto/corelib/plugin/qpluginloader/staticplugin/CMakeLists.txt
new file mode 100644
index 0000000000..fb9d365d74
--- /dev/null
+++ b/tests/auto/corelib/plugin/qpluginloader/staticplugin/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from staticplugin.pro.
+
+#####################################################################
+## staticplugin Generic Library:
+#####################################################################
+
+add_cmake_library(staticplugin
+ STATIC
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Core
+ MOC_OPTIONS
+ "-M"
+ "ExtraMetaData=StaticPlugin"
+ "-M"
+ "ExtraMetaData=foo"
+)
+
+#### Keys ignored in scope 1:.:.:staticplugin.pro:<TRUE>:
+# TEMPLATE = "lib"
+
+qt_autogen_tools_initial_setup(staticplugin)
+
+target_compile_definitions(staticplugin PRIVATE QT_STATICPLUGIN)
diff --git a/tests/auto/corelib/plugin/qpluginloader/theplugin/CMakeLists.txt b/tests/auto/corelib/plugin/qpluginloader/theplugin/CMakeLists.txt
new file mode 100644
index 0000000000..5389790fba
--- /dev/null
+++ b/tests/auto/corelib/plugin/qpluginloader/theplugin/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from theplugin.pro.
+
+#####################################################################
+## theplugin Generic Library:
+#####################################################################
+
+add_cmake_library(theplugin
+ MODULE
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qpluginloader/bin"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../bin"
+ SOURCES
+ theplugin.cpp theplugin.h
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:theplugin.pro:<TRUE>:
+# INSTALLS = "target"
+# TEMPLATE = "lib"
+# target.path = "$$[QT_INSTALL_TESTS]/tst_qpluginloader/bin"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 5:.:..:../winrt.pri:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug/bin"
+
+#### Keys ignored in scope 6:.:..:../winrt.pri:else:
+# DESTDIR = "../release/bin"
+
+qt_autogen_tools_initial_setup(theplugin)
diff --git a/tests/auto/corelib/plugin/qpluginloader/tst/.prev_CMakeLists.txt b/tests/auto/corelib/plugin/qpluginloader/tst/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..8bef975168
--- /dev/null
+++ b/tests/auto/corelib/plugin/qpluginloader/tst/.prev_CMakeLists.txt
@@ -0,0 +1,45 @@
+# Generated from tst.pro.
+
+#####################################################################
+## tst_qpluginloader Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "../elftest")
+list(APPEND test_data "../machtest")
+
+add_qt_test(tst_qpluginloader
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ SOURCES
+ ../fakeplugin.cpp
+ ../theplugin/plugininterface.h
+ ../tst_qpluginloader.cpp
+ PUBLIC_LIBRARIES
+ staticplugin
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qpluginloader CONDITION QT_FEATURE_private_tests
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+extend_target(tst_qpluginloader CONDITION CMAKE_BUILD_TYPE STREQUAL Debug AND WIN32 AND debug_and_release
+ PUBLIC_LIBRARIES
+ # Remove: L../staticplugin/debug
+)
+
+extend_target(tst_qpluginloader CONDITION WIN32 AND debug_and_release AND NOT CMAKE_BUILD_TYPE STREQUAL Debug
+ PUBLIC_LIBRARIES
+ # Remove: L../staticplugin/release
+)
+
+extend_target(tst_qpluginloader CONDITION UNIX OR NOT debug_and_release
+ PUBLIC_LIBRARIES
+ # Remove: L../staticplugin
+)
diff --git a/tests/auto/corelib/plugin/qpluginloader/tst/CMakeLists.txt b/tests/auto/corelib/plugin/qpluginloader/tst/CMakeLists.txt
new file mode 100644
index 0000000000..8bef975168
--- /dev/null
+++ b/tests/auto/corelib/plugin/qpluginloader/tst/CMakeLists.txt
@@ -0,0 +1,45 @@
+# Generated from tst.pro.
+
+#####################################################################
+## tst_qpluginloader Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "../elftest")
+list(APPEND test_data "../machtest")
+
+add_qt_test(tst_qpluginloader
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ SOURCES
+ ../fakeplugin.cpp
+ ../theplugin/plugininterface.h
+ ../tst_qpluginloader.cpp
+ PUBLIC_LIBRARIES
+ staticplugin
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qpluginloader CONDITION QT_FEATURE_private_tests
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+extend_target(tst_qpluginloader CONDITION CMAKE_BUILD_TYPE STREQUAL Debug AND WIN32 AND debug_and_release
+ PUBLIC_LIBRARIES
+ # Remove: L../staticplugin/debug
+)
+
+extend_target(tst_qpluginloader CONDITION WIN32 AND debug_and_release AND NOT CMAKE_BUILD_TYPE STREQUAL Debug
+ PUBLIC_LIBRARIES
+ # Remove: L../staticplugin/release
+)
+
+extend_target(tst_qpluginloader CONDITION UNIX OR NOT debug_and_release
+ PUBLIC_LIBRARIES
+ # Remove: L../staticplugin
+)
diff --git a/tests/auto/corelib/plugin/quuid/CMakeLists.txt b/tests/auto/corelib/plugin/quuid/CMakeLists.txt
new file mode 100644
index 0000000000..91e75fe0ae
--- /dev/null
+++ b/tests/auto/corelib/plugin/quuid/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from quuid.pro.
+
+add_subdirectory(testProcessUniqueness)
+add_subdirectory(test)
diff --git a/tests/auto/corelib/plugin/quuid/test/.prev_CMakeLists.txt b/tests/auto/corelib/plugin/quuid/test/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..c635f6479c
--- /dev/null
+++ b/tests/auto/corelib/plugin/quuid/test/.prev_CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_quuid Test:
+#####################################################################
+
+add_qt_test(tst_quuid
+ SOURCES
+ ../tst_quuid.cpp
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_quuid CONDITION APPLE
+ SOURCES
+ ../tst_quuid_darwin.mm
+ PUBLIC_LIBRARIES
+ ${FWFoundation}
+)
+
+#### Keys ignored in scope 4:.:.:test.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug"
+
+#### Keys ignored in scope 5:.:.:test.pro:else:
+# DESTDIR = "../release"
+
+#### Keys ignored in scope 6:.:.:test.pro:else:
+# DESTDIR = ".."
diff --git a/tests/auto/corelib/plugin/quuid/test/CMakeLists.txt b/tests/auto/corelib/plugin/quuid/test/CMakeLists.txt
new file mode 100644
index 0000000000..5707dfa5a1
--- /dev/null
+++ b/tests/auto/corelib/plugin/quuid/test/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_quuid Test:
+#####################################################################
+
+add_qt_test(tst_quuid
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../" # special case
+ SOURCES
+ ../tst_quuid.cpp
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_quuid CONDITION APPLE
+ SOURCES
+ ../tst_quuid_darwin.mm
+ PUBLIC_LIBRARIES
+ ${FWFoundation}
+)
+
+#### Keys ignored in scope 4:.:.:test.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug"
+
+#### Keys ignored in scope 5:.:.:test.pro:else:
+# DESTDIR = "../release"
+
+#### Keys ignored in scope 6:.:.:test.pro:else:
+# DESTDIR = ".."
diff --git a/tests/auto/corelib/plugin/quuid/testProcessUniqueness/CMakeLists.txt b/tests/auto/corelib/plugin/quuid/testProcessUniqueness/CMakeLists.txt
new file mode 100644
index 0000000000..39ff85c466
--- /dev/null
+++ b/tests/auto/corelib/plugin/quuid/testProcessUniqueness/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from testProcessUniqueness.pro.
+
+#####################################################################
+## testProcessUniqueness Binary:
+#####################################################################
+
+add_qt_executable(testProcessUniqueness
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_quuid/testProcessUniqueness"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ main.cpp
+)
diff --git a/tests/auto/corelib/serialization/CMakeLists.txt b/tests/auto/corelib/serialization/CMakeLists.txt
new file mode 100644
index 0000000000..f6af7fa256
--- /dev/null
+++ b/tests/auto/corelib/serialization/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from serialization.pro.
+
+add_subdirectory(json)
+add_subdirectory(qcborstreamreader)
+add_subdirectory(qcborstreamwriter)
+add_subdirectory(qcborvalue)
+add_subdirectory(qcborvalue_json)
+add_subdirectory(qdatastream_core_pixmap)
+if(TARGET Qt::Gui)
+ add_subdirectory(qdatastream)
+endif()
+if(TARGET Qt::Network)
+ add_subdirectory(qtextstream)
+endif()
+if(TARGET Qt::Network AND TARGET Qt::Xml)
+ add_subdirectory(qxmlstream)
+endif()
diff --git a/tests/auto/corelib/serialization/json/CMakeLists.txt b/tests/auto/corelib/serialization/json/CMakeLists.txt
new file mode 100644
index 0000000000..92d7210842
--- /dev/null
+++ b/tests/auto/corelib/serialization/json/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from json.pro.
+
+#####################################################################
+## tst_json Test:
+#####################################################################
+
+add_qt_test(tst_json
+ SOURCES
+ tst_qtjson.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:json.pro:NOT ANDROID:
+# TESTDATA = "bom.json" "test.json" "test.bjson" "test3.json" "test2.json"
+
+if(ANDROID)
+ # Resources:
+ set(json_resource_files
+ "bom.json"
+ "test.bjson"
+ "test.json"
+ "test2.json"
+ "test3.json"
+ )
+
+ add_qt_resource(tst_json "json"
+ PREFIX
+ "/"
+ FILES
+ ${json_resource_files}
+ )
+endif()
diff --git a/tests/auto/corelib/serialization/qcborstreamreader/CMakeLists.txt b/tests/auto/corelib/serialization/qcborstreamreader/CMakeLists.txt
new file mode 100644
index 0000000000..198cca8435
--- /dev/null
+++ b/tests/auto/corelib/serialization/qcborstreamreader/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qcborstreamreader.pro.
+
+#####################################################################
+## tst_qcborstreamreader Test:
+#####################################################################
+
+add_qt_test(tst_qcborstreamreader
+ SOURCES
+ tst_qcborstreamreader.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ INCLUDE_DIRECTORIES
+ ../../../../../src/3rdparty/tinycbor/src
+ ../../../../../src/3rdparty/tinycbor/tests/parser
+)
diff --git a/tests/auto/corelib/serialization/qcborstreamwriter/CMakeLists.txt b/tests/auto/corelib/serialization/qcborstreamwriter/CMakeLists.txt
new file mode 100644
index 0000000000..9265df415e
--- /dev/null
+++ b/tests/auto/corelib/serialization/qcborstreamwriter/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qcborstreamwriter.pro.
+
+#####################################################################
+## tst_qcborstreamwriter Test:
+#####################################################################
+
+add_qt_test(tst_qcborstreamwriter
+ SOURCES
+ tst_qcborstreamwriter.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ INCLUDE_DIRECTORIES
+ ../../../../../src/3rdparty/tinycbor/tests/encoder
+)
diff --git a/tests/auto/corelib/serialization/qcborvalue/CMakeLists.txt b/tests/auto/corelib/serialization/qcborvalue/CMakeLists.txt
new file mode 100644
index 0000000000..66cb80c56a
--- /dev/null
+++ b/tests/auto/corelib/serialization/qcborvalue/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qcborvalue.pro.
+
+#####################################################################
+## tst_qcborvalue Test:
+#####################################################################
+
+add_qt_test(tst_qcborvalue
+ SOURCES
+ tst_qcborvalue.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ INCLUDE_DIRECTORIES
+ ../../../../../src/3rdparty/tinycbor/src
+ ../../../../../src/3rdparty/tinycbor/tests/parser
+)
diff --git a/tests/auto/corelib/serialization/qcborvalue_json/CMakeLists.txt b/tests/auto/corelib/serialization/qcborvalue_json/CMakeLists.txt
new file mode 100644
index 0000000000..0346d2d0e0
--- /dev/null
+++ b/tests/auto/corelib/serialization/qcborvalue_json/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qcborvalue_json.pro.
+
+#####################################################################
+## tst_qcborvalue_json Test:
+#####################################################################
+
+add_qt_test(tst_qcborvalue_json
+ SOURCES
+ tst_qcborvalue_json.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+)
diff --git a/tests/auto/corelib/serialization/qdatastream/CMakeLists.txt b/tests/auto/corelib/serialization/qdatastream/CMakeLists.txt
new file mode 100644
index 0000000000..2bb2e842e8
--- /dev/null
+++ b/tests/auto/corelib/serialization/qdatastream/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from qdatastream.pro.
+
+#####################################################################
+## tst_qdatastream Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "datastream.q42")
+
+add_qt_test(tst_qdatastream
+ SOURCES
+ tst_qdatastream.cpp
+ DEFINES
+ # -QT_NO_LINKED_LIST # special case remove
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ # Resources:
+ set(testdata_resource_files
+ "datastream.q42"
+ )
+
+ add_qt_resource(tst_qdatastream "testdata"
+ PREFIX
+ "/"
+ FILES
+ ${testdata_resource_files}
+ )
+endif()
diff --git a/tests/auto/corelib/serialization/qdatastream_core_pixmap/CMakeLists.txt b/tests/auto/corelib/serialization/qdatastream_core_pixmap/CMakeLists.txt
new file mode 100644
index 0000000000..55e8c164e5
--- /dev/null
+++ b/tests/auto/corelib/serialization/qdatastream_core_pixmap/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdatastream_core_pixmap.pro.
+
+#####################################################################
+## tst_qdatastream_core_pixmap Test:
+#####################################################################
+
+add_qt_test(tst_qdatastream_core_pixmap
+ SOURCES
+ tst_qdatastream_core_pixmap.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/corelib/serialization/qtextstream/CMakeLists.txt b/tests/auto/corelib/serialization/qtextstream/CMakeLists.txt
new file mode 100644
index 0000000000..15798c963f
--- /dev/null
+++ b/tests/auto/corelib/serialization/qtextstream/CMakeLists.txt
@@ -0,0 +1,6 @@
+# Generated from qtextstream.pro.
+
+add_subdirectory(test)
+add_subdirectory(stdinProcess)
+add_subdirectory(readAllStdinProcess)
+add_subdirectory(readLineStdinProcess)
diff --git a/tests/auto/corelib/serialization/qtextstream/readAllStdinProcess/CMakeLists.txt b/tests/auto/corelib/serialization/qtextstream/readAllStdinProcess/CMakeLists.txt
new file mode 100644
index 0000000000..f377c97c2d
--- /dev/null
+++ b/tests/auto/corelib/serialization/qtextstream/readAllStdinProcess/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from readAllStdinProcess.pro.
+
+#####################################################################
+## readAllStdinProcess Binary:
+#####################################################################
+
+add_qt_executable(readAllStdinProcess
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qtextstream/readAllStdinProcess"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ main.cpp
+)
diff --git a/tests/auto/corelib/serialization/qtextstream/readLineStdinProcess/CMakeLists.txt b/tests/auto/corelib/serialization/qtextstream/readLineStdinProcess/CMakeLists.txt
new file mode 100644
index 0000000000..ae899e55df
--- /dev/null
+++ b/tests/auto/corelib/serialization/qtextstream/readLineStdinProcess/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from readLineStdinProcess.pro.
+
+#####################################################################
+## readLineStdinProcess Binary:
+#####################################################################
+
+add_qt_executable(readLineStdinProcess
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qtextstream/readLineStdinProcess"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ main.cpp
+)
diff --git a/tests/auto/corelib/serialization/qtextstream/stdinProcess/CMakeLists.txt b/tests/auto/corelib/serialization/qtextstream/stdinProcess/CMakeLists.txt
new file mode 100644
index 0000000000..fed74b64c2
--- /dev/null
+++ b/tests/auto/corelib/serialization/qtextstream/stdinProcess/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from stdinProcess.pro.
+
+#####################################################################
+## stdinProcess Binary:
+#####################################################################
+
+add_qt_executable(stdinProcess
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qtextstream/stdinProcess"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ main.cpp
+)
diff --git a/tests/auto/corelib/serialization/qtextstream/test/CMakeLists.txt b/tests/auto/corelib/serialization/qtextstream/test/CMakeLists.txt
new file mode 100644
index 0000000000..21ba0d47fb
--- /dev/null
+++ b/tests/auto/corelib/serialization/qtextstream/test/CMakeLists.txt
@@ -0,0 +1,56 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qtextstream Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "../rfc3261.txt")
+list(APPEND test_data "../shift-jis.txt")
+list(APPEND test_data "../task113817.txt")
+list(APPEND test_data "../qtextstream.qrc")
+list(APPEND test_data "../tst_qtextstream.cpp")
+list(APPEND test_data "../resources")
+list(APPEND test_data "../BLACKLIST")
+
+add_qt_test(tst_qtextstream
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ SOURCES
+ ../../../../../shared/emulationdetector.h
+ ../tst_qtextstream.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../../shared
+ PUBLIC_LIBRARIES
+ Qt::Network
+ TESTDATA ${test_data}
+)
+
+# Resources:
+set_source_files_properties("../resources/big_endian/"
+ PROPERTIES QT_RESOURCE_ALIAS "resources/big_endian/"
+)
+set_source_files_properties("../resources/little_endian/"
+ PROPERTIES QT_RESOURCE_ALIAS "resources/little_endian/"
+)
+set(qtextstream_resource_files
+ "resources/big_endian/"
+ "resources/little_endian/"
+)
+
+add_qt_resource(tst_qtextstream "qtextstream"
+ PREFIX
+ "/tst_textstream/"
+ BASE
+ ".."
+ FILES
+ ${qtextstream_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qtextstream CONDITION builtin_testdata
+ DEFINES
+ BUILTIN_TESTDATA
+)
diff --git a/tests/auto/corelib/serialization/qxmlstream/CMakeLists.txt b/tests/auto/corelib/serialization/qxmlstream/CMakeLists.txt
new file mode 100644
index 0000000000..0339b57c71
--- /dev/null
+++ b/tests/auto/corelib/serialization/qxmlstream/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qxmlstream.pro.
+
+#####################################################################
+## tst_qxmlstream Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "data")
+list(APPEND test_data "XML-Test-Suite")
+
+add_qt_test(tst_qxmlstream
+ SOURCES
+ tst_qxmlstream.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Xml
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/corelib/statemachine/CMakeLists.txt b/tests/auto/corelib/statemachine/CMakeLists.txt
new file mode 100644
index 0000000000..52c956cd03
--- /dev/null
+++ b/tests/auto/corelib/statemachine/CMakeLists.txt
@@ -0,0 +1,2 @@
+add_subdirectory(qstate)
+
diff --git a/tests/auto/corelib/statemachine/qstate/CMakeLists.txt b/tests/auto/corelib/statemachine/qstate/CMakeLists.txt
new file mode 100644
index 0000000000..e269f7191a
--- /dev/null
+++ b/tests/auto/corelib/statemachine/qstate/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qstate.pro.
+
+#####################################################################
+## tst_qstate Test:
+#####################################################################
+
+add_qt_test(tst_qstate
+ SOURCES
+ tst_qstate.cpp
+)
diff --git a/tests/auto/corelib/text/CMakeLists.txt b/tests/auto/corelib/text/CMakeLists.txt
new file mode 100644
index 0000000000..dd51385aa6
--- /dev/null
+++ b/tests/auto/corelib/text/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from text.pro.
+
+# add_subdirectory(qbytearray) # special case not ported
+add_subdirectory(qbytearraylist)
+# add_subdirectory(qbytearraymatcher) # special case not ported
+add_subdirectory(qbytedatabuffer)
+# add_subdirectory(qchar) # special case not ported
+# add_subdirectory(qcollator) # special case not ported
+# add_subdirectory(qlatin1string) # special case not ported
+# add_subdirectory(qlocale) # special case not ported
+add_subdirectory(qregexp)
+add_subdirectory(qregularexpression)
+# add_subdirectory(qstring) # special case not ported
+add_subdirectory(qstring_no_cast_from_bytearray)
+# add_subdirectory(qstringapisymmetry) # special case not ported
+# add_subdirectory(qstringbuilder) # special case not ported
+add_subdirectory(qstringiterator)
+add_subdirectory(qstringlist)
+add_subdirectory(qstringmatcher)
+add_subdirectory(qstringref)
+# add_subdirectory(qstringview) # special case not ported
+# add_subdirectory(qtextboundaryfinder) # special case not ported
diff --git a/tests/auto/corelib/text/qbytearraylist/CMakeLists.txt b/tests/auto/corelib/text/qbytearraylist/CMakeLists.txt
new file mode 100644
index 0000000000..780216a38c
--- /dev/null
+++ b/tests/auto/corelib/text/qbytearraylist/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qbytearraylist.pro.
+
+#####################################################################
+## tst_qbytearraylist Test:
+#####################################################################
+
+add_qt_test(tst_qbytearraylist
+ SOURCES
+ tst_qbytearraylist.cpp
+)
diff --git a/tests/auto/corelib/text/qbytedatabuffer/CMakeLists.txt b/tests/auto/corelib/text/qbytedatabuffer/CMakeLists.txt
new file mode 100644
index 0000000000..2085df02aa
--- /dev/null
+++ b/tests/auto/corelib/text/qbytedatabuffer/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qbytedatabuffer.pro.
+
+#####################################################################
+## tst_qbytedatabuffer Test:
+#####################################################################
+
+add_qt_test(tst_qbytedatabuffer
+ SOURCES
+ tst_qbytedatabuffer.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/text/qregexp/CMakeLists.txt b/tests/auto/corelib/text/qregexp/CMakeLists.txt
new file mode 100644
index 0000000000..e14979d7fe
--- /dev/null
+++ b/tests/auto/corelib/text/qregexp/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qregexp.pro.
+
+#####################################################################
+## tst_qregexp Test:
+#####################################################################
+
+add_qt_test(tst_qregexp
+ SOURCES
+ tst_qregexp.cpp
+)
diff --git a/tests/auto/corelib/text/qregularexpression/CMakeLists.txt b/tests/auto/corelib/text/qregularexpression/CMakeLists.txt
new file mode 100644
index 0000000000..b1ee1ff7de
--- /dev/null
+++ b/tests/auto/corelib/text/qregularexpression/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qregularexpression.pro.
+
+#####################################################################
+## tst_qregularexpression Test:
+#####################################################################
+
+add_qt_test(tst_qregularexpression
+ SOURCES
+ tst_qregularexpression.cpp
+)
diff --git a/tests/auto/corelib/text/qstring_no_cast_from_bytearray/CMakeLists.txt b/tests/auto/corelib/text/qstring_no_cast_from_bytearray/CMakeLists.txt
new file mode 100644
index 0000000000..d0285cce3c
--- /dev/null
+++ b/tests/auto/corelib/text/qstring_no_cast_from_bytearray/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qstring_no_cast_from_bytearray.pro.
+
+#####################################################################
+## tst_qstring_no_cast_from_bytearray Test:
+#####################################################################
+
+add_qt_test(tst_qstring_no_cast_from_bytearray
+ SOURCES
+ tst_qstring_no_cast_from_bytearray.cpp
+ DEFINES
+ QT_NO_CAST_FROM_BYTEARRAY
+)
diff --git a/tests/auto/corelib/text/qstringbuilder/qstringbuilder1/CMakeLists.txt b/tests/auto/corelib/text/qstringbuilder/qstringbuilder1/CMakeLists.txt
new file mode 100644
index 0000000000..959f04f07e
--- /dev/null
+++ b/tests/auto/corelib/text/qstringbuilder/qstringbuilder1/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qstringbuilder1.pro.
+
+#####################################################################
+## tst_qstringbuilder1 Test:
+#####################################################################
+
+add_qt_test(tst_qstringbuilder1
+ SOURCES
+ tst_qstringbuilder1.cpp
+)
diff --git a/tests/auto/corelib/text/qstringbuilder/qstringbuilder2/CMakeLists.txt b/tests/auto/corelib/text/qstringbuilder/qstringbuilder2/CMakeLists.txt
new file mode 100644
index 0000000000..ff9dfd4ce1
--- /dev/null
+++ b/tests/auto/corelib/text/qstringbuilder/qstringbuilder2/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qstringbuilder2.pro.
+
+#####################################################################
+## tst_qstringbuilder2 Test:
+#####################################################################
+
+add_qt_test(tst_qstringbuilder2
+ SOURCES
+ tst_qstringbuilder2.cpp
+)
diff --git a/tests/auto/corelib/text/qstringbuilder/qstringbuilder3/CMakeLists.txt b/tests/auto/corelib/text/qstringbuilder/qstringbuilder3/CMakeLists.txt
new file mode 100644
index 0000000000..810004cc7d
--- /dev/null
+++ b/tests/auto/corelib/text/qstringbuilder/qstringbuilder3/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qstringbuilder3.pro.
+
+#####################################################################
+## tst_qstringbuilder3 Test:
+#####################################################################
+
+add_qt_test(tst_qstringbuilder3
+ SOURCES
+ tst_qstringbuilder3.cpp
+)
diff --git a/tests/auto/corelib/text/qstringbuilder/qstringbuilder4/CMakeLists.txt b/tests/auto/corelib/text/qstringbuilder/qstringbuilder4/CMakeLists.txt
new file mode 100644
index 0000000000..1ad6d02418
--- /dev/null
+++ b/tests/auto/corelib/text/qstringbuilder/qstringbuilder4/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qstringbuilder4.pro.
+
+#####################################################################
+## tst_qstringbuilder4 Test:
+#####################################################################
+
+add_qt_test(tst_qstringbuilder4
+ SOURCES
+ tst_qstringbuilder4.cpp
+)
diff --git a/tests/auto/corelib/text/qstringiterator/CMakeLists.txt b/tests/auto/corelib/text/qstringiterator/CMakeLists.txt
new file mode 100644
index 0000000000..c74071957b
--- /dev/null
+++ b/tests/auto/corelib/text/qstringiterator/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qstringiterator.pro.
+
+#####################################################################
+## tst_qstringiterator Test:
+#####################################################################
+
+add_qt_test(tst_qstringiterator
+ SOURCES
+ tst_qstringiterator.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/text/qstringlist/CMakeLists.txt b/tests/auto/corelib/text/qstringlist/CMakeLists.txt
new file mode 100644
index 0000000000..aff8b59c15
--- /dev/null
+++ b/tests/auto/corelib/text/qstringlist/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qstringlist.pro.
+
+#####################################################################
+## tst_qstringlist Test:
+#####################################################################
+
+add_qt_test(tst_qstringlist
+ SOURCES
+ tst_qstringlist.cpp
+)
diff --git a/tests/auto/corelib/text/qstringmatcher/CMakeLists.txt b/tests/auto/corelib/text/qstringmatcher/CMakeLists.txt
new file mode 100644
index 0000000000..15616a0b13
--- /dev/null
+++ b/tests/auto/corelib/text/qstringmatcher/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qstringmatcher.pro.
+
+#####################################################################
+## tst_qstringmatcher Test:
+#####################################################################
+
+add_qt_test(tst_qstringmatcher
+ SOURCES
+ tst_qstringmatcher.cpp
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+)
diff --git a/tests/auto/corelib/text/qstringref/CMakeLists.txt b/tests/auto/corelib/text/qstringref/CMakeLists.txt
new file mode 100644
index 0000000000..961f37c93d
--- /dev/null
+++ b/tests/auto/corelib/text/qstringref/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qstringref.pro.
+
+#####################################################################
+## tst_qstringref Test:
+#####################################################################
+
+add_qt_test(tst_qstringref
+ SOURCES
+ tst_qstringref.cpp
+)
diff --git a/tests/auto/corelib/thread/CMakeLists.txt b/tests/auto/corelib/thread/CMakeLists.txt
new file mode 100644
index 0000000000..d07c583a77
--- /dev/null
+++ b/tests/auto/corelib/thread/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from thread.pro.
+
+if(QT_FEATURE_thread)
+ add_subdirectory(qatomicint)
+ add_subdirectory(qatomicinteger)
+ add_subdirectory(qatomicpointer)
+ add_subdirectory(qresultstore)
+ add_subdirectory(qfuture)
+ add_subdirectory(qfuturesynchronizer)
+ add_subdirectory(qmutex)
+ add_subdirectory(qmutexlocker)
+ add_subdirectory(qreadlocker)
+ add_subdirectory(qreadwritelock)
+ add_subdirectory(qsemaphore)
+ add_subdirectory(qthread)
+ add_subdirectory(qthreadonce)
+ add_subdirectory(qthreadpool)
+ add_subdirectory(qthreadstorage)
+ add_subdirectory(qwaitcondition)
+ add_subdirectory(qwritelocker)
+endif()
+if(TARGET Qt::Concurrent)
+ add_subdirectory(qfuturewatcher)
+endif()
diff --git a/tests/auto/corelib/thread/qatomicint/CMakeLists.txt b/tests/auto/corelib/thread/qatomicint/CMakeLists.txt
new file mode 100644
index 0000000000..1a084fb28c
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicint/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qatomicint.pro.
+
+#####################################################################
+## tst_qatomicint Test:
+#####################################################################
+
+add_qt_test(tst_qatomicint
+ SOURCES
+ tst_qatomicint.cpp
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/CMakeLists.txt
new file mode 100644
index 0000000000..8f0637a4d2
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qatomicinteger.pro.
+
+add_subdirectory(char)
+add_subdirectory(char16_t)
+add_subdirectory(char32_t)
+add_subdirectory(int)
+add_subdirectory(long)
+add_subdirectory(qlonglong)
+add_subdirectory(qptrdiff)
+add_subdirectory(quintptr)
+add_subdirectory(qulonglong)
+add_subdirectory(schar)
+add_subdirectory(short)
+add_subdirectory(uchar)
+add_subdirectory(uint)
+add_subdirectory(ulong)
+add_subdirectory(ushort)
+add_subdirectory(wchar_t)
diff --git a/tests/auto/corelib/thread/qatomicinteger/char/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/char/CMakeLists.txt
new file mode 100644
index 0000000000..6ccaf3291d
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/char/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from char.pro.
+
+#####################################################################
+## tst_qatomicinteger_char Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_char
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=char
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_char
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/char16_t/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/char16_t/CMakeLists.txt
new file mode 100644
index 0000000000..d57d4b89dc
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/char16_t/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from char16_t.pro.
+
+#####################################################################
+## tst_qatomicinteger_char16_t Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_char16_t
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=char16_t
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_char16_t
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/char32_t/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/char32_t/CMakeLists.txt
new file mode 100644
index 0000000000..7e04c7864b
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/char32_t/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from char32_t.pro.
+
+#####################################################################
+## tst_qatomicinteger_char32_t Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_char32_t
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=char32_t
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_char32_t
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/int/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/int/CMakeLists.txt
new file mode 100644
index 0000000000..16332fcf3b
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/int/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from int.pro.
+
+#####################################################################
+## tst_qatomicinteger_int Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_int
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=int
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_int
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/long/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/long/CMakeLists.txt
new file mode 100644
index 0000000000..17c2510ac2
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/long/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from long.pro.
+
+#####################################################################
+## tst_qatomicinteger_long Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_long
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=long
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_long
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/qlonglong/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/qlonglong/CMakeLists.txt
new file mode 100644
index 0000000000..021b865e67
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/qlonglong/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qlonglong.pro.
+
+#####################################################################
+## tst_qatomicinteger_qlonglong Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_qlonglong
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=qlonglong
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_qlonglong
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/qptrdiff/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/qptrdiff/CMakeLists.txt
new file mode 100644
index 0000000000..4beff29882
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/qptrdiff/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qptrdiff.pro.
+
+#####################################################################
+## tst_qatomicinteger_qptrdiff Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_qptrdiff
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=qptrdiff
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_qptrdiff
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/quintptr/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/quintptr/CMakeLists.txt
new file mode 100644
index 0000000000..a5f9b7aef3
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/quintptr/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from quintptr.pro.
+
+#####################################################################
+## tst_qatomicinteger_quintptr Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_quintptr
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=quintptr
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_quintptr
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/qulonglong/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/qulonglong/CMakeLists.txt
new file mode 100644
index 0000000000..d2e1c31856
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/qulonglong/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qulonglong.pro.
+
+#####################################################################
+## tst_qatomicinteger_qulonglong Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_qulonglong
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=qulonglong
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_qulonglong
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/schar/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/schar/CMakeLists.txt
new file mode 100644
index 0000000000..9354bbe2e2
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/schar/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from schar.pro.
+
+#####################################################################
+## tst_qatomicinteger_schar Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_schar
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=schar
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_schar
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/short/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/short/CMakeLists.txt
new file mode 100644
index 0000000000..07143ed431
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/short/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from short.pro.
+
+#####################################################################
+## tst_qatomicinteger_short Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_short
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=short
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_short
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/uchar/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/uchar/CMakeLists.txt
new file mode 100644
index 0000000000..ebc64efea5
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/uchar/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from uchar.pro.
+
+#####################################################################
+## tst_qatomicinteger_uchar Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_uchar
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=uchar
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_uchar
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/uint/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/uint/CMakeLists.txt
new file mode 100644
index 0000000000..561274da9d
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/uint/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from uint.pro.
+
+#####################################################################
+## tst_qatomicinteger_uint Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_uint
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=uint
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_uint
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/ulong/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/ulong/CMakeLists.txt
new file mode 100644
index 0000000000..c859818838
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/ulong/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from ulong.pro.
+
+#####################################################################
+## tst_qatomicinteger_ulong Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_ulong
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=ulong
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_ulong
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/ushort/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/ushort/CMakeLists.txt
new file mode 100644
index 0000000000..6608390b8e
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/ushort/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from ushort.pro.
+
+#####################################################################
+## tst_qatomicinteger_ushort Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_ushort
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=ushort
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_ushort
+)
diff --git a/tests/auto/corelib/thread/qatomicinteger/wchar_t/CMakeLists.txt b/tests/auto/corelib/thread/qatomicinteger/wchar_t/CMakeLists.txt
new file mode 100644
index 0000000000..9c7e17f1bd
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicinteger/wchar_t/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from wchar_t.pro.
+
+#####################################################################
+## tst_qatomicinteger_wchar_t Test:
+#####################################################################
+
+add_qt_test(tst_qatomicinteger_wchar_t
+ SOURCES
+ ../tst_qatomicinteger.cpp
+ DEFINES
+ QATOMIC_TEST_TYPE=wchar_t
+ tst_QAtomicIntegerXX=tst_QAtomicInteger_wchar_t
+)
diff --git a/tests/auto/corelib/thread/qatomicpointer/CMakeLists.txt b/tests/auto/corelib/thread/qatomicpointer/CMakeLists.txt
new file mode 100644
index 0000000000..f400ad7b2e
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicpointer/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qatomicpointer.pro.
+
+#####################################################################
+## tst_qatomicpointer Test:
+#####################################################################
+
+add_qt_test(tst_qatomicpointer
+ SOURCES
+ tst_qatomicpointer.cpp
+)
diff --git a/tests/auto/corelib/thread/qfuture/.prev_CMakeLists.txt b/tests/auto/corelib/thread/qfuture/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..14b7a73e6f
--- /dev/null
+++ b/tests/auto/corelib/thread/qfuture/.prev_CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qfuture.pro.
+
+#####################################################################
+## tst_qfuture Test:
+#####################################################################
+
+add_qt_test(tst_qfuture
+ SOURCES
+ tst_qfuture.cpp
+ DEFINES
+ -QT_NO_JAVA_STYLE_ITERATORS
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/thread/qfuture/CMakeLists.txt b/tests/auto/corelib/thread/qfuture/CMakeLists.txt
new file mode 100644
index 0000000000..786913cc17
--- /dev/null
+++ b/tests/auto/corelib/thread/qfuture/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qfuture.pro.
+
+#####################################################################
+## tst_qfuture Test:
+#####################################################################
+
+add_qt_test(tst_qfuture
+ SOURCES
+ tst_qfuture.cpp
+ DEFINES
+ # -QT_NO_JAVA_STYLE_ITERATORS # special case
+ QT_STRICT_ITERATORS
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/thread/qfuturesynchronizer/CMakeLists.txt b/tests/auto/corelib/thread/qfuturesynchronizer/CMakeLists.txt
new file mode 100644
index 0000000000..54e3eb861d
--- /dev/null
+++ b/tests/auto/corelib/thread/qfuturesynchronizer/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qfuturesynchronizer.pro.
+
+#####################################################################
+## tst_qfuturesynchronizer Test:
+#####################################################################
+
+add_qt_test(tst_qfuturesynchronizer
+ SOURCES
+ tst_qfuturesynchronizer.cpp
+)
diff --git a/tests/auto/corelib/thread/qfuturewatcher/CMakeLists.txt b/tests/auto/corelib/thread/qfuturewatcher/CMakeLists.txt
new file mode 100644
index 0000000000..ef2ef5a7e4
--- /dev/null
+++ b/tests/auto/corelib/thread/qfuturewatcher/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qfuturewatcher.pro.
+
+#####################################################################
+## tst_qfuturewatcher Test:
+#####################################################################
+
+add_qt_test(tst_qfuturewatcher
+ SOURCES
+ tst_qfuturewatcher.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Concurrent
+)
diff --git a/tests/auto/corelib/thread/qmutex/CMakeLists.txt b/tests/auto/corelib/thread/qmutex/CMakeLists.txt
new file mode 100644
index 0000000000..5916a33752
--- /dev/null
+++ b/tests/auto/corelib/thread/qmutex/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qmutex.pro.
+
+#####################################################################
+## tst_qmutex Test:
+#####################################################################
+
+add_qt_test(tst_qmutex
+ SOURCES
+ tst_qmutex.cpp
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qmutex CONDITION WIN32
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
diff --git a/tests/auto/corelib/thread/qmutexlocker/CMakeLists.txt b/tests/auto/corelib/thread/qmutexlocker/CMakeLists.txt
new file mode 100644
index 0000000000..a07548a494
--- /dev/null
+++ b/tests/auto/corelib/thread/qmutexlocker/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qmutexlocker.pro.
+
+#####################################################################
+## tst_qmutexlocker Test:
+#####################################################################
+
+add_qt_test(tst_qmutexlocker
+ SOURCES
+ tst_qmutexlocker.cpp
+)
diff --git a/tests/auto/corelib/thread/qreadlocker/CMakeLists.txt b/tests/auto/corelib/thread/qreadlocker/CMakeLists.txt
new file mode 100644
index 0000000000..c52bc24491
--- /dev/null
+++ b/tests/auto/corelib/thread/qreadlocker/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qreadlocker.pro.
+
+#####################################################################
+## tst_qreadlocker Test:
+#####################################################################
+
+add_qt_test(tst_qreadlocker
+ SOURCES
+ tst_qreadlocker.cpp
+)
diff --git a/tests/auto/corelib/thread/qreadwritelock/CMakeLists.txt b/tests/auto/corelib/thread/qreadwritelock/CMakeLists.txt
new file mode 100644
index 0000000000..3de89adb2d
--- /dev/null
+++ b/tests/auto/corelib/thread/qreadwritelock/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qreadwritelock.pro.
+
+#####################################################################
+## tst_qreadwritelock Test:
+#####################################################################
+
+add_qt_test(tst_qreadwritelock
+ SOURCES
+ tst_qreadwritelock.cpp
+)
diff --git a/tests/auto/corelib/thread/qresultstore/CMakeLists.txt b/tests/auto/corelib/thread/qresultstore/CMakeLists.txt
new file mode 100644
index 0000000000..de295bc129
--- /dev/null
+++ b/tests/auto/corelib/thread/qresultstore/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qresultstore.pro.
+
+#####################################################################
+## tst_qresultstore Test:
+#####################################################################
+
+add_qt_test(tst_qresultstore
+ SOURCES
+ tst_qresultstore.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/thread/qsemaphore/CMakeLists.txt b/tests/auto/corelib/thread/qsemaphore/CMakeLists.txt
new file mode 100644
index 0000000000..3aaa71423e
--- /dev/null
+++ b/tests/auto/corelib/thread/qsemaphore/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qsemaphore.pro.
+
+#####################################################################
+## tst_qsemaphore Test:
+#####################################################################
+
+add_qt_test(tst_qsemaphore
+ SOURCES
+ tst_qsemaphore.cpp
+)
diff --git a/tests/auto/corelib/thread/qthread/.prev_CMakeLists.txt b/tests/auto/corelib/thread/qthread/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..749a5e9734
--- /dev/null
+++ b/tests/auto/corelib/thread/qthread/.prev_CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qthread.pro.
+
+#####################################################################
+## tst_qthread Test:
+#####################################################################
+
+add_qt_test(tst_qthread
+ SOURCES
+ ../../../../shared/emulationdetector.h
+ tst_qthread.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../shared
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/thread/qthread/CMakeLists.txt b/tests/auto/corelib/thread/qthread/CMakeLists.txt
new file mode 100644
index 0000000000..a21e239c35
--- /dev/null
+++ b/tests/auto/corelib/thread/qthread/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qthread.pro.
+
+#####################################################################
+## tst_qthread Test:
+#####################################################################
+
+add_qt_test(tst_qthread
+ SOURCES
+ ../../../../shared/emulationdetector.h
+ tst_qthread.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../shared
+ LIBRARIES # special case
+ Threads::Threads # special case
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/thread/qthreadonce/CMakeLists.txt b/tests/auto/corelib/thread/qthreadonce/CMakeLists.txt
new file mode 100644
index 0000000000..c29b4e640a
--- /dev/null
+++ b/tests/auto/corelib/thread/qthreadonce/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from qthreadonce.pro.
+
+#####################################################################
+## tst_qthreadonce Test:
+#####################################################################
+
+add_qt_test(tst_qthreadonce
+ SOURCES
+ qthreadonce.cpp
+ tst_qthreadonce.cpp
+)
diff --git a/tests/auto/corelib/thread/qthreadpool/CMakeLists.txt b/tests/auto/corelib/thread/qthreadpool/CMakeLists.txt
new file mode 100644
index 0000000000..bc3fca1b6a
--- /dev/null
+++ b/tests/auto/corelib/thread/qthreadpool/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qthreadpool.pro.
+
+#####################################################################
+## tst_qthreadpool Test:
+#####################################################################
+
+add_qt_test(tst_qthreadpool
+ SOURCES
+ tst_qthreadpool.cpp
+)
diff --git a/tests/auto/corelib/thread/qthreadstorage/CMakeLists.txt b/tests/auto/corelib/thread/qthreadstorage/CMakeLists.txt
new file mode 100644
index 0000000000..52a928863c
--- /dev/null
+++ b/tests/auto/corelib/thread/qthreadstorage/CMakeLists.txt
@@ -0,0 +1,21 @@
+# special case skip regeneration
+# Generated from qthreadstorage.pro.
+
+#####################################################################
+## tst_qthreadstorage Test:
+#####################################################################
+
+add_qt_test(tst_qthreadstorage
+ SOURCES
+ tst_qthreadstorage.cpp
+ LIBRARIES # special case
+ Threads::Threads # special case
+
+)
+
+## Scopes:
+#####################################################################
+
+if(NOT ANDROID AND NOT WINRT)
+ add_subdirectory(crashonexit)
+endif()
diff --git a/tests/auto/corelib/thread/qthreadstorage/crashonexit/.prev_CMakeLists.txt b/tests/auto/corelib/thread/qthreadstorage/crashonexit/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..87ae29a04c
--- /dev/null
+++ b/tests/auto/corelib/thread/qthreadstorage/crashonexit/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from crashonexit.pro.
+
+#####################################################################
+## crashonexit Binary:
+#####################################################################
+
+add_qt_executable(crashonexit
+ OUTPUT_DIRECTORY "${INSTALL_TESTSDIR}/tst_qthreadstorage/crashonexit"
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qthreadstorage/crashonexit"
+ SOURCES
+ crashOnExit.cpp
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/thread/qthreadstorage/crashonexit/CMakeLists.txt b/tests/auto/corelib/thread/qthreadstorage/crashonexit/CMakeLists.txt
new file mode 100644
index 0000000000..b2bac9713a
--- /dev/null
+++ b/tests/auto/corelib/thread/qthreadstorage/crashonexit/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from crashonexit.pro.
+
+#####################################################################
+## crashonexit Binary:
+#####################################################################
+
+add_qt_executable(crashOnExit_helper
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/.." # special case
+ INSTALL_DIRECTORY "${INSTALL_TESTSDIR}/tst_qthreadstorage/crashOnExit_helper" # special case
+ SOURCES
+ crashOnExit.cpp
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/thread/qwaitcondition/CMakeLists.txt b/tests/auto/corelib/thread/qwaitcondition/CMakeLists.txt
new file mode 100644
index 0000000000..76f8b33aa4
--- /dev/null
+++ b/tests/auto/corelib/thread/qwaitcondition/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qwaitcondition.pro.
+
+#####################################################################
+## tst_qwaitcondition Test:
+#####################################################################
+
+add_qt_test(tst_qwaitcondition
+ SOURCES
+ tst_qwaitcondition.cpp
+)
diff --git a/tests/auto/corelib/thread/qwritelocker/CMakeLists.txt b/tests/auto/corelib/thread/qwritelocker/CMakeLists.txt
new file mode 100644
index 0000000000..00a9809174
--- /dev/null
+++ b/tests/auto/corelib/thread/qwritelocker/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qwritelocker.pro.
+
+#####################################################################
+## tst_qwritelocker Test:
+#####################################################################
+
+add_qt_test(tst_qwritelocker
+ SOURCES
+ tst_qwritelocker.cpp
+)
diff --git a/tests/auto/corelib/time/CMakeLists.txt b/tests/auto/corelib/time/CMakeLists.txt
new file mode 100644
index 0000000000..ed990d1979
--- /dev/null
+++ b/tests/auto/corelib/time/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from time.pro.
+
+add_subdirectory(qcalendar)
+add_subdirectory(qdate)
+add_subdirectory(qdatetime)
+add_subdirectory(qtime)
+add_subdirectory(qtimezone)
diff --git a/tests/auto/corelib/time/qcalendar/CMakeLists.txt b/tests/auto/corelib/time/qcalendar/CMakeLists.txt
new file mode 100644
index 0000000000..1e59a1f0b0
--- /dev/null
+++ b/tests/auto/corelib/time/qcalendar/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qcalendar.pro.
+
+#####################################################################
+## tst_qcalendar Test:
+#####################################################################
+
+add_qt_test(tst_qcalendar
+ SOURCES
+ tst_qcalendar.cpp
+)
diff --git a/tests/auto/corelib/time/qdate/CMakeLists.txt b/tests/auto/corelib/time/qdate/CMakeLists.txt
new file mode 100644
index 0000000000..9a90956bd6
--- /dev/null
+++ b/tests/auto/corelib/time/qdate/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdate.pro.
+
+#####################################################################
+## tst_qdate Test:
+#####################################################################
+
+add_qt_test(tst_qdate
+ SOURCES
+ tst_qdate.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/time/qdatetime/CMakeLists.txt b/tests/auto/corelib/time/qdatetime/CMakeLists.txt
new file mode 100644
index 0000000000..b215ca6efa
--- /dev/null
+++ b/tests/auto/corelib/time/qdatetime/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from qdatetime.pro.
+
+#####################################################################
+## tst_qdatetime Test:
+#####################################################################
+
+add_qt_test(tst_qdatetime
+ SOURCES
+ tst_qdatetime.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:qdatetime.pro:MSVC:
+# QMAKE_CFLAGS_RELEASE = "--O1"
+# QMAKE_CXXFLAGS_RELEASE = "--O1"
+
+extend_target(tst_qdatetime CONDITION APPLE
+ SOURCES
+ tst_qdatetime_mac.mm
+ PUBLIC_LIBRARIES
+ ${FWFoundation}
+)
diff --git a/tests/auto/corelib/time/qtime/CMakeLists.txt b/tests/auto/corelib/time/qtime/CMakeLists.txt
new file mode 100644
index 0000000000..ef224b45e3
--- /dev/null
+++ b/tests/auto/corelib/time/qtime/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qtime.pro.
+
+#####################################################################
+## tst_qtime Test:
+#####################################################################
+
+add_qt_test(tst_qtime
+ SOURCES
+ tst_qtime.cpp
+)
diff --git a/tests/auto/corelib/time/qtimezone/CMakeLists.txt b/tests/auto/corelib/time/qtimezone/CMakeLists.txt
new file mode 100644
index 0000000000..7d9a8ccc88
--- /dev/null
+++ b/tests/auto/corelib/time/qtimezone/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from qtimezone.pro.
+
+#####################################################################
+## tst_qtimezone Test:
+#####################################################################
+
+add_qt_test(tst_qtimezone
+ SOURCES
+ tst_qtimezone.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qtimezone CONDITION QT_FEATURE_icu
+ LIBRARIES
+ ICU::i18n ICU::uc ICU::data
+)
+
+extend_target(tst_qtimezone CONDITION APPLE
+ SOURCES
+ tst_qtimezone_darwin.mm
+ PUBLIC_LIBRARIES
+ ${FWFoundation}
+)
diff --git a/tests/auto/corelib/tools/CMakeLists.txt b/tests/auto/corelib/tools/CMakeLists.txt
new file mode 100644
index 0000000000..534bd7928a
--- /dev/null
+++ b/tests/auto/corelib/tools/CMakeLists.txt
@@ -0,0 +1,50 @@
+# Generated from tools.pro.
+
+# add_subdirectory(collections) # special case not ported
+# add_subdirectory(containerapisymmetry) # special case not ported
+add_subdirectory(qalgorithms)
+add_subdirectory(qarraydata)
+# add_subdirectory(qarraydata_strictiterators) # special case not ported
+add_subdirectory(qbitarray)
+add_subdirectory(qcache)
+add_subdirectory(qcommandlineparser)
+add_subdirectory(qcontiguouscache)
+# add_subdirectory(qcryptographichash) # special case not ported
+add_subdirectory(qeasingcurve)
+add_subdirectory(qexplicitlyshareddatapointer)
+# add_subdirectory(qfreelist) # special case not ported
+add_subdirectory(qhash)
+# add_subdirectory(qhash_strictiterators) # special case not ported
+add_subdirectory(qhashfunctions)
+# add_subdirectory(qline) # special case not ported
+add_subdirectory(qlinkedlist)
+# add_subdirectory(qlist) # special case no longer exists
+# add_subdirectory(qlist_strictiterators) # special case not ported
+add_subdirectory(qmakearray)
+add_subdirectory(qmap)
+# add_subdirectory(qmap_strictiterators) # special case not ported
+add_subdirectory(qmargins)
+add_subdirectory(qmessageauthenticationcode)
+# add_subdirectory(qoffsetstringarray) # special case not ported
+add_subdirectory(qpair)
+add_subdirectory(qpoint)
+add_subdirectory(qpointf)
+add_subdirectory(qqueue)
+add_subdirectory(qrect)
+add_subdirectory(qringbuffer)
+add_subdirectory(qscopedpointer)
+add_subdirectory(qscopedvaluerollback)
+add_subdirectory(qscopeguard)
+add_subdirectory(qset)
+# add_subdirectory(qsharedpointer) # special case not ported
+add_subdirectory(qsize)
+add_subdirectory(qsizef)
+add_subdirectory(qstl)
+add_subdirectory(qtimeline)
+add_subdirectory(qvarlengtharray)
+# add_subdirectory(qvector) # special case not ported
+# add_subdirectory(qvector_strictiterators) # special case not ported
+# add_subdirectory(qversionnumber) # special case not ported
+if(APPLE)
+ # add_subdirectory(qmacautoreleasepool) # special case not ported
+endif()
diff --git a/tests/auto/corelib/tools/qalgorithms/CMakeLists.txt b/tests/auto/corelib/tools/qalgorithms/CMakeLists.txt
new file mode 100644
index 0000000000..14b7c95f4b
--- /dev/null
+++ b/tests/auto/corelib/tools/qalgorithms/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qalgorithms.pro.
+
+#####################################################################
+## tst_qalgorithms Test:
+#####################################################################
+
+add_qt_test(tst_qalgorithms
+ SOURCES
+ tst_qalgorithms.cpp
+)
diff --git a/tests/auto/corelib/tools/qarraydata/CMakeLists.txt b/tests/auto/corelib/tools/qarraydata/CMakeLists.txt
new file mode 100644
index 0000000000..f68c3714aa
--- /dev/null
+++ b/tests/auto/corelib/tools/qarraydata/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from qarraydata.pro.
+
+#####################################################################
+## tst_qarraydata Test:
+#####################################################################
+
+add_qt_test(tst_qarraydata
+ SOURCES
+ simplevector.h
+ tst_qarraydata.cpp
+)
diff --git a/tests/auto/corelib/tools/qbitarray/CMakeLists.txt b/tests/auto/corelib/tools/qbitarray/CMakeLists.txt
new file mode 100644
index 0000000000..65150c02a2
--- /dev/null
+++ b/tests/auto/corelib/tools/qbitarray/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qbitarray.pro.
+
+#####################################################################
+## tst_qbitarray Test:
+#####################################################################
+
+add_qt_test(tst_qbitarray
+ SOURCES
+ tst_qbitarray.cpp
+)
diff --git a/tests/auto/corelib/tools/qcache/CMakeLists.txt b/tests/auto/corelib/tools/qcache/CMakeLists.txt
new file mode 100644
index 0000000000..50fb2372c3
--- /dev/null
+++ b/tests/auto/corelib/tools/qcache/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qcache.pro.
+
+#####################################################################
+## tst_qcache Test:
+#####################################################################
+
+add_qt_test(tst_qcache
+ SOURCES
+ tst_qcache.cpp
+)
diff --git a/tests/auto/corelib/tools/qcommandlineparser/CMakeLists.txt b/tests/auto/corelib/tools/qcommandlineparser/CMakeLists.txt
new file mode 100644
index 0000000000..2fc50a7d89
--- /dev/null
+++ b/tests/auto/corelib/tools/qcommandlineparser/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from qcommandlineparser.pro.
+
+#####################################################################
+## tst_qcommandlineparser Test:
+#####################################################################
+
+add_qt_test(tst_qcommandlineparser
+ SOURCES
+ tst_qcommandlineparser.cpp
+)
+add_subdirectory(testhelper)
diff --git a/tests/auto/corelib/tools/qcommandlineparser/testhelper/CMakeLists.txt b/tests/auto/corelib/tools/qcommandlineparser/testhelper/CMakeLists.txt
new file mode 100644
index 0000000000..3d0989d841
--- /dev/null
+++ b/tests/auto/corelib/tools/qcommandlineparser/testhelper/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from qcommandlineparser_test_helper.pro.
+
+#####################################################################
+## qcommandlineparser_test_helper Binary:
+#####################################################################
+
+add_qt_executable(qcommandlineparser_test_helper
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ qcommandlineparser_test_helper.cpp
+)
diff --git a/tests/auto/corelib/tools/qcontiguouscache/CMakeLists.txt b/tests/auto/corelib/tools/qcontiguouscache/CMakeLists.txt
new file mode 100644
index 0000000000..bce8ce11bd
--- /dev/null
+++ b/tests/auto/corelib/tools/qcontiguouscache/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qcontiguouscache.pro.
+
+#####################################################################
+## tst_qcontiguouscache Test:
+#####################################################################
+
+add_qt_test(tst_qcontiguouscache
+ SOURCES
+ tst_qcontiguouscache.cpp
+)
diff --git a/tests/auto/corelib/tools/qeasingcurve/CMakeLists.txt b/tests/auto/corelib/tools/qeasingcurve/CMakeLists.txt
new file mode 100644
index 0000000000..c2611921ab
--- /dev/null
+++ b/tests/auto/corelib/tools/qeasingcurve/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qeasingcurve.pro.
+
+#####################################################################
+## tst_qeasingcurve Test:
+#####################################################################
+
+add_qt_test(tst_qeasingcurve
+ SOURCES
+ tst_qeasingcurve.cpp
+)
diff --git a/tests/auto/corelib/tools/qexplicitlyshareddatapointer/CMakeLists.txt b/tests/auto/corelib/tools/qexplicitlyshareddatapointer/CMakeLists.txt
new file mode 100644
index 0000000000..cacc36beaa
--- /dev/null
+++ b/tests/auto/corelib/tools/qexplicitlyshareddatapointer/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qexplicitlyshareddatapointer.pro.
+
+#####################################################################
+## tst_qexplicitlyshareddatapointer Test:
+#####################################################################
+
+add_qt_test(tst_qexplicitlyshareddatapointer
+ SOURCES
+ tst_qexplicitlyshareddatapointer.cpp
+)
diff --git a/tests/auto/corelib/tools/qhash/.prev_CMakeLists.txt b/tests/auto/corelib/tools/qhash/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..5dfeedb322
--- /dev/null
+++ b/tests/auto/corelib/tools/qhash/.prev_CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qhash.pro.
+
+#####################################################################
+## tst_qhash Test:
+#####################################################################
+
+add_qt_test(tst_qhash
+ SOURCES
+ tst_qhash.cpp
+ DEFINES
+ -QT_NO_JAVA_STYLE_ITERATORS
+)
diff --git a/tests/auto/corelib/tools/qhash/CMakeLists.txt b/tests/auto/corelib/tools/qhash/CMakeLists.txt
new file mode 100644
index 0000000000..32edf72073
--- /dev/null
+++ b/tests/auto/corelib/tools/qhash/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qhash.pro.
+
+#####################################################################
+## tst_qhash Test:
+#####################################################################
+
+add_qt_test(tst_qhash
+ SOURCES
+ tst_qhash.cpp
+ DEFINES
+ #-QT_NO_JAVA_STYLE_ITERATORS # special case remove
+)
diff --git a/tests/auto/corelib/tools/qhashfunctions/CMakeLists.txt b/tests/auto/corelib/tools/qhashfunctions/CMakeLists.txt
new file mode 100644
index 0000000000..87d109f997
--- /dev/null
+++ b/tests/auto/corelib/tools/qhashfunctions/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qhashfunctions.pro.
+
+#####################################################################
+## tst_qhashfunctions Test:
+#####################################################################
+
+add_qt_test(tst_qhashfunctions
+ SOURCES
+ tst_qhashfunctions.cpp
+)
diff --git a/tests/auto/corelib/tools/qlinkedlist/.prev_CMakeLists.txt b/tests/auto/corelib/tools/qlinkedlist/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..7124e17d17
--- /dev/null
+++ b/tests/auto/corelib/tools/qlinkedlist/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qlinkedlist.pro.
+
+#####################################################################
+## tst_qlinkedlist Test:
+#####################################################################
+
+add_qt_test(tst_qlinkedlist
+ SOURCES
+ tst_qlinkedlist.cpp
+ DEFINES
+ -QT_NO_LINKED_LIST
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/tools/qlinkedlist/CMakeLists.txt b/tests/auto/corelib/tools/qlinkedlist/CMakeLists.txt
new file mode 100644
index 0000000000..2042739fa0
--- /dev/null
+++ b/tests/auto/corelib/tools/qlinkedlist/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qlinkedlist.pro.
+
+#####################################################################
+## tst_qlinkedlist Test:
+#####################################################################
+
+add_qt_test(tst_qlinkedlist
+ SOURCES
+ tst_qlinkedlist.cpp
+ #DEFINES # special case remove
+ #-QT_NO_LINKED_LIST # special case remove until fixed
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/tools/qmakearray/CMakeLists.txt b/tests/auto/corelib/tools/qmakearray/CMakeLists.txt
new file mode 100644
index 0000000000..ce7b0d0afb
--- /dev/null
+++ b/tests/auto/corelib/tools/qmakearray/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qmakearray.pro.
+
+#####################################################################
+## tst_qmakearray Test:
+#####################################################################
+
+add_qt_test(tst_qmakearray
+ SOURCES
+ tst_qmakearray.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/tools/qmap/.prev_CMakeLists.txt b/tests/auto/corelib/tools/qmap/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..96378d3278
--- /dev/null
+++ b/tests/auto/corelib/tools/qmap/.prev_CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qmap.pro.
+
+#####################################################################
+## tst_qmap Test:
+#####################################################################
+
+add_qt_test(tst_qmap
+ SOURCES
+ tst_qmap.cpp
+ DEFINES
+ -QT_NO_JAVA_STYLE_ITERATORS
+)
diff --git a/tests/auto/corelib/tools/qmap/CMakeLists.txt b/tests/auto/corelib/tools/qmap/CMakeLists.txt
new file mode 100644
index 0000000000..677159ae0d
--- /dev/null
+++ b/tests/auto/corelib/tools/qmap/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qmap.pro.
+
+#####################################################################
+## tst_qmap Test:
+#####################################################################
+
+add_qt_test(tst_qmap
+ SOURCES
+ tst_qmap.cpp
+ DEFINES
+ #-QT_NO_JAVA_STYLE_ITERATORS # special case remove
+)
diff --git a/tests/auto/corelib/tools/qmargins/CMakeLists.txt b/tests/auto/corelib/tools/qmargins/CMakeLists.txt
new file mode 100644
index 0000000000..632e5dc8d2
--- /dev/null
+++ b/tests/auto/corelib/tools/qmargins/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qmargins.pro.
+
+#####################################################################
+## tst_qmargins Test:
+#####################################################################
+
+add_qt_test(tst_qmargins
+ SOURCES
+ tst_qmargins.cpp
+)
diff --git a/tests/auto/corelib/tools/qmessageauthenticationcode/CMakeLists.txt b/tests/auto/corelib/tools/qmessageauthenticationcode/CMakeLists.txt
new file mode 100644
index 0000000000..6e142facfb
--- /dev/null
+++ b/tests/auto/corelib/tools/qmessageauthenticationcode/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qmessageauthenticationcode.pro.
+
+#####################################################################
+## tst_qmessageauthenticationcode Test:
+#####################################################################
+
+add_qt_test(tst_qmessageauthenticationcode
+ SOURCES
+ tst_qmessageauthenticationcode.cpp
+)
diff --git a/tests/auto/corelib/tools/qpair/CMakeLists.txt b/tests/auto/corelib/tools/qpair/CMakeLists.txt
new file mode 100644
index 0000000000..4c226f5a02
--- /dev/null
+++ b/tests/auto/corelib/tools/qpair/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qpair.pro.
+
+#####################################################################
+## tst_qpair Test:
+#####################################################################
+
+add_qt_test(tst_qpair
+ SOURCES
+ tst_qpair.cpp
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/tools/qpoint/CMakeLists.txt b/tests/auto/corelib/tools/qpoint/CMakeLists.txt
new file mode 100644
index 0000000000..6ef68c30cb
--- /dev/null
+++ b/tests/auto/corelib/tools/qpoint/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qpoint.pro.
+
+#####################################################################
+## tst_qpoint Test:
+#####################################################################
+
+add_qt_test(tst_qpoint
+ SOURCES
+ tst_qpoint.cpp
+)
diff --git a/tests/auto/corelib/tools/qpointf/CMakeLists.txt b/tests/auto/corelib/tools/qpointf/CMakeLists.txt
new file mode 100644
index 0000000000..b1784d999f
--- /dev/null
+++ b/tests/auto/corelib/tools/qpointf/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qpointf.pro.
+
+#####################################################################
+## tst_qpointf Test:
+#####################################################################
+
+add_qt_test(tst_qpointf
+ SOURCES
+ tst_qpointf.cpp
+)
diff --git a/tests/auto/corelib/tools/qqueue/CMakeLists.txt b/tests/auto/corelib/tools/qqueue/CMakeLists.txt
new file mode 100644
index 0000000000..6d1aeda5b2
--- /dev/null
+++ b/tests/auto/corelib/tools/qqueue/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qqueue.pro.
+
+#####################################################################
+## tst_qqueue Test:
+#####################################################################
+
+add_qt_test(tst_qqueue
+ SOURCES
+ tst_qqueue.cpp
+)
diff --git a/tests/auto/corelib/tools/qrect/CMakeLists.txt b/tests/auto/corelib/tools/qrect/CMakeLists.txt
new file mode 100644
index 0000000000..47b8aced46
--- /dev/null
+++ b/tests/auto/corelib/tools/qrect/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qrect.pro.
+
+#####################################################################
+## tst_qrect Test:
+#####################################################################
+
+add_qt_test(tst_qrect
+ SOURCES
+ tst_qrect.cpp
+)
diff --git a/tests/auto/corelib/tools/qringbuffer/CMakeLists.txt b/tests/auto/corelib/tools/qringbuffer/CMakeLists.txt
new file mode 100644
index 0000000000..f9eccf72ff
--- /dev/null
+++ b/tests/auto/corelib/tools/qringbuffer/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qringbuffer.pro.
+
+#####################################################################
+## tst_qringbuffer Test:
+#####################################################################
+
+add_qt_test(tst_qringbuffer
+ SOURCES
+ tst_qringbuffer.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/corelib/tools/qscopedpointer/CMakeLists.txt b/tests/auto/corelib/tools/qscopedpointer/CMakeLists.txt
new file mode 100644
index 0000000000..141bab267b
--- /dev/null
+++ b/tests/auto/corelib/tools/qscopedpointer/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qscopedpointer.pro.
+
+#####################################################################
+## tst_qscopedpointer Test:
+#####################################################################
+
+add_qt_test(tst_qscopedpointer
+ SOURCES
+ tst_qscopedpointer.cpp
+)
diff --git a/tests/auto/corelib/tools/qscopedvaluerollback/CMakeLists.txt b/tests/auto/corelib/tools/qscopedvaluerollback/CMakeLists.txt
new file mode 100644
index 0000000000..e23a4d55f9
--- /dev/null
+++ b/tests/auto/corelib/tools/qscopedvaluerollback/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qscopedvaluerollback.pro.
+
+#####################################################################
+## tst_qscopedvaluerollback Test:
+#####################################################################
+
+add_qt_test(tst_qscopedvaluerollback
+ SOURCES
+ tst_qscopedvaluerollback.cpp
+)
diff --git a/tests/auto/corelib/tools/qscopeguard/CMakeLists.txt b/tests/auto/corelib/tools/qscopeguard/CMakeLists.txt
new file mode 100644
index 0000000000..243efdd0b2
--- /dev/null
+++ b/tests/auto/corelib/tools/qscopeguard/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qscopeguard.pro.
+
+#####################################################################
+## tst_qscopeguard Test:
+#####################################################################
+
+add_qt_test(tst_qscopeguard
+ SOURCES
+ tst_qscopeguard.cpp
+)
diff --git a/tests/auto/corelib/tools/qset/.prev_CMakeLists.txt b/tests/auto/corelib/tools/qset/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..68a8f64822
--- /dev/null
+++ b/tests/auto/corelib/tools/qset/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qset.pro.
+
+#####################################################################
+## tst_qset Test:
+#####################################################################
+
+add_qt_test(tst_qset
+ SOURCES
+ tst_qset.cpp
+ DEFINES
+ -QT_NO_JAVA_STYLE_ITERATORS
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/tools/qset/CMakeLists.txt b/tests/auto/corelib/tools/qset/CMakeLists.txt
new file mode 100644
index 0000000000..a423e4aa23
--- /dev/null
+++ b/tests/auto/corelib/tools/qset/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qset.pro.
+
+#####################################################################
+## tst_qset Test:
+#####################################################################
+
+add_qt_test(tst_qset
+ SOURCES
+ tst_qset.cpp
+ #DEFINES # special case remove
+ #-QT_NO_JAVA_STYLE_ITERATORS # special case remove
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/corelib/tools/qsize/CMakeLists.txt b/tests/auto/corelib/tools/qsize/CMakeLists.txt
new file mode 100644
index 0000000000..f516941180
--- /dev/null
+++ b/tests/auto/corelib/tools/qsize/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qsize.pro.
+
+#####################################################################
+## tst_qsize Test:
+#####################################################################
+
+add_qt_test(tst_qsize
+ SOURCES
+ tst_qsize.cpp
+)
diff --git a/tests/auto/corelib/tools/qsizef/CMakeLists.txt b/tests/auto/corelib/tools/qsizef/CMakeLists.txt
new file mode 100644
index 0000000000..d767ca92d7
--- /dev/null
+++ b/tests/auto/corelib/tools/qsizef/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qsizef.pro.
+
+#####################################################################
+## tst_qsizef Test:
+#####################################################################
+
+add_qt_test(tst_qsizef
+ SOURCES
+ tst_qsizef.cpp
+)
diff --git a/tests/auto/corelib/tools/qstl/CMakeLists.txt b/tests/auto/corelib/tools/qstl/CMakeLists.txt
new file mode 100644
index 0000000000..975ddfe0b5
--- /dev/null
+++ b/tests/auto/corelib/tools/qstl/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qstl.pro.
+
+#####################################################################
+## tst_qstl Test:
+#####################################################################
+
+add_qt_test(tst_qstl
+ SOURCES
+ tst_qstl.cpp
+)
diff --git a/tests/auto/corelib/tools/qtimeline/CMakeLists.txt b/tests/auto/corelib/tools/qtimeline/CMakeLists.txt
new file mode 100644
index 0000000000..802cd56305
--- /dev/null
+++ b/tests/auto/corelib/tools/qtimeline/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qtimeline.pro.
+
+#####################################################################
+## tst_qtimeline Test:
+#####################################################################
+
+add_qt_test(tst_qtimeline
+ SOURCES
+ tst_qtimeline.cpp
+)
diff --git a/tests/auto/corelib/tools/qvarlengtharray/CMakeLists.txt b/tests/auto/corelib/tools/qvarlengtharray/CMakeLists.txt
new file mode 100644
index 0000000000..17989ae31d
--- /dev/null
+++ b/tests/auto/corelib/tools/qvarlengtharray/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qvarlengtharray.pro.
+
+#####################################################################
+## tst_qvarlengtharray Test:
+#####################################################################
+
+add_qt_test(tst_qvarlengtharray
+ SOURCES
+ tst_qvarlengtharray.cpp
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/dbus/CMakeLists.txt b/tests/auto/dbus/CMakeLists.txt
new file mode 100644
index 0000000000..1b5022454a
--- /dev/null
+++ b/tests/auto/dbus/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from dbus.pro.
+
+add_subdirectory(qdbusconnection_delayed)
+add_subdirectory(qdbusconnection)
+add_subdirectory(qdbusconnection_no_app)
+add_subdirectory(qdbusconnection_no_bus)
+add_subdirectory(qdbusconnection_no_libdbus)
+add_subdirectory(qdbusconnection_spyhook)
+add_subdirectory(qdbuscontext)
+add_subdirectory(qdbuslocalcalls)
+add_subdirectory(qdbusmetaobject)
+add_subdirectory(qdbusmetatype)
+add_subdirectory(qdbuspendingcall)
+add_subdirectory(qdbuspendingreply)
+add_subdirectory(qdbusreply)
+add_subdirectory(qdbusservicewatcher)
+add_subdirectory(qdbustype)
+add_subdirectory(qdbusthreading)
+if(QT_FEATURE_process)
+ add_subdirectory(qdbusabstractadaptor)
+ add_subdirectory(qdbusabstractinterface)
+ add_subdirectory(qdbusinterface)
+endif()
+if(QT_FEATURE_private_tests AND QT_FEATURE_process)
+ add_subdirectory(qdbusmarshall)
+endif()
+if(TARGET Qt::Xml)
+ add_subdirectory(qdbusxmlparser)
+endif()
diff --git a/tests/auto/dbus/qdbusabstractadaptor/CMakeLists.txt b/tests/auto/dbus/qdbusabstractadaptor/CMakeLists.txt
new file mode 100644
index 0000000000..a97accb925
--- /dev/null
+++ b/tests/auto/dbus/qdbusabstractadaptor/CMakeLists.txt
@@ -0,0 +1,14 @@
+
+# Generated from qdbusabstractadaptor.pro.
+
+add_subdirectory(qmyserver)
+
+add_qt_test(tst_qdbusabstractadaptor
+ SOURCES
+ myobject.h
+ tst_qdbusabstractadaptor.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBus
+)
+
diff --git a/tests/auto/dbus/qdbusabstractadaptor/qmyserver/.prev_CMakeLists.txt b/tests/auto/dbus/qdbusabstractadaptor/qmyserver/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..caea7b1e64
--- /dev/null
+++ b/tests/auto/dbus/qdbusabstractadaptor/qmyserver/.prev_CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qmyserver.pro.
+
+#####################################################################
+## qmyserver Binary:
+#####################################################################
+
+add_qt_executable(qmyserver
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ ../myobject.h
+ qmyserver.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusabstractadaptor/qmyserver/CMakeLists.txt b/tests/auto/dbus/qdbusabstractadaptor/qmyserver/CMakeLists.txt
new file mode 100644
index 0000000000..839b952591
--- /dev/null
+++ b/tests/auto/dbus/qdbusabstractadaptor/qmyserver/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qmyserver.pro.
+
+#####################################################################
+## qmyserver Binary:
+#####################################################################
+
+add_qt_executable(qmyserver
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ NO_INSTALL # special case
+ SOURCES
+ ../myobject.h
+ qmyserver.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusabstractinterface/CMakeLists.txt b/tests/auto/dbus/qdbusabstractinterface/CMakeLists.txt
new file mode 100644
index 0000000000..facac1a7fc
--- /dev/null
+++ b/tests/auto/dbus/qdbusabstractinterface/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from qdbusabstractinterface.pro.
+
+add_subdirectory(qpinger)
+
+add_qt_test(tst_qdbusabstractinterface
+ SOURCES
+ interface.cpp
+ tst_qdbusabstractinterface.cpp
+ LIBRARIES
+ Qt::Core
+ Qt::DBus
+)
+
+extend_target(tst_qdbusabstractinterface
+ DBUS_INTERFACE_SOURCES
+ org.qtproject.QtDBus.Pinger.xml
+ DBUS_INTERFACE_BASENAME
+ pinger_interface
+ DBUS_INTERFACE_FLAGS
+ -i interface.h
+)
diff --git a/tests/auto/dbus/qdbusabstractinterface/qdbusabstractinterface/.prev_CMakeLists.txt b/tests/auto/dbus/qdbusabstractinterface/qdbusabstractinterface/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..83d9899b36
--- /dev/null
+++ b/tests/auto/dbus/qdbusabstractinterface/qdbusabstractinterface/.prev_CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qdbusabstractinterface.pro.
+
+#####################################################################
+## tst_qdbusabstractinterface Test:
+#####################################################################
+
+add_qt_test(tst_qdbusabstractinterface
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ ../interface.cpp ../interface.h
+ ../tst_qdbusabstractinterface.cpp
+ DBUS_INTERFACE_SOURCES
+ ../org.qtproject.QtDBus.Pinger.xml
+ DBUS_INTERFACE_FLAGS
+ "-i" "../interface.h"
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusabstractinterface/qdbusabstractinterface/CMakeLists.txt b/tests/auto/dbus/qdbusabstractinterface/qdbusabstractinterface/CMakeLists.txt
new file mode 100644
index 0000000000..3df1ff8177
--- /dev/null
+++ b/tests/auto/dbus/qdbusabstractinterface/qdbusabstractinterface/CMakeLists.txt
@@ -0,0 +1,9 @@
+# Generated from qdbusabstractinterface.pro.
+
+#####################################################################
+## tst_qdbusabstractinterface Test:
+#####################################################################
+# special case begin
+# this test can not be generated here. It needs to be set up in the
+# parent directory
+# special case end
diff --git a/tests/auto/dbus/qdbusabstractinterface/qpinger/.prev_CMakeLists.txt b/tests/auto/dbus/qdbusabstractinterface/qpinger/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..4e2b5fe567
--- /dev/null
+++ b/tests/auto/dbus/qdbusabstractinterface/qpinger/.prev_CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qpinger.pro.
+
+#####################################################################
+## qpinger Binary:
+#####################################################################
+
+add_qt_executable(qpinger
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ ../interface.cpp ../interface.h
+ qpinger.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusabstractinterface/qpinger/CMakeLists.txt b/tests/auto/dbus/qdbusabstractinterface/qpinger/CMakeLists.txt
new file mode 100644
index 0000000000..47e3cfbb69
--- /dev/null
+++ b/tests/auto/dbus/qdbusabstractinterface/qpinger/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qpinger.pro.
+
+#####################################################################
+## qpinger Binary:
+#####################################################################
+
+add_qt_executable(qpinger
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ NO_INSTALL # special case
+ SOURCES
+ ../interface.cpp ../interface.h
+ qpinger.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusconnection/CMakeLists.txt b/tests/auto/dbus/qdbusconnection/CMakeLists.txt
new file mode 100644
index 0000000000..b1927e5d10
--- /dev/null
+++ b/tests/auto/dbus/qdbusconnection/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdbusconnection.pro.
+
+#####################################################################
+## tst_qdbusconnection Test:
+#####################################################################
+
+add_qt_test(tst_qdbusconnection
+ SOURCES
+ tst_qdbusconnection.cpp tst_qdbusconnection.h
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusconnection_delayed/CMakeLists.txt b/tests/auto/dbus/qdbusconnection_delayed/CMakeLists.txt
new file mode 100644
index 0000000000..0602c67fbb
--- /dev/null
+++ b/tests/auto/dbus/qdbusconnection_delayed/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qdbusconnection_delayed.pro.
+
+#####################################################################
+## tst_qdbusconnection_delayed Test:
+#####################################################################
+
+add_qt_test(tst_qdbusconnection_delayed
+ SOURCES
+ tst_qdbusconnection_delayed.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusconnection_no_app/CMakeLists.txt b/tests/auto/dbus/qdbusconnection_no_app/CMakeLists.txt
new file mode 100644
index 0000000000..061c59579d
--- /dev/null
+++ b/tests/auto/dbus/qdbusconnection_no_app/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qdbusconnection_no_app.pro.
+
+#####################################################################
+## tst_qdbusconnection_no_app Test:
+#####################################################################
+
+add_qt_test(tst_qdbusconnection_no_app
+ SOURCES
+ ../qdbusconnection/tst_qdbusconnection.h
+ tst_qdbusconnection_no_app.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ tst_QDBusConnection=tst_QDBusConnection_NoApplication
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusconnection_no_bus/CMakeLists.txt b/tests/auto/dbus/qdbusconnection_no_bus/CMakeLists.txt
new file mode 100644
index 0000000000..b05ac03b2d
--- /dev/null
+++ b/tests/auto/dbus/qdbusconnection_no_bus/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdbusconnection_no_bus.pro.
+
+#####################################################################
+## tst_qdbusconnection_no_bus Test:
+#####################################################################
+
+add_qt_test(tst_qdbusconnection_no_bus
+ SOURCES
+ tst_qdbusconnection_no_bus.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusconnection_no_libdbus/CMakeLists.txt b/tests/auto/dbus/qdbusconnection_no_libdbus/CMakeLists.txt
new file mode 100644
index 0000000000..c372f16d12
--- /dev/null
+++ b/tests/auto/dbus/qdbusconnection_no_libdbus/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qdbusconnection_no_libdbus.pro.
+
+#####################################################################
+## tst_qdbusconnection_no_libdbus Test:
+#####################################################################
+
+add_qt_test(tst_qdbusconnection_no_libdbus
+ SOURCES
+ ../qdbusconnection_no_bus/tst_qdbusconnection_no_bus.cpp
+ DEFINES
+ SIMULATE_LOAD_FAIL
+ tst_QDBusConnectionNoBus=tst_QDBusConnectionNoLibDBus1
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusconnection_no_libdbus/tst_qdbusconnection_no_libdbus.cpp b/tests/auto/dbus/qdbusconnection_no_libdbus/tst_qdbusconnection_no_libdbus.cpp
new file mode 100644
index 0000000000..e93b8aa609
--- /dev/null
+++ b/tests/auto/dbus/qdbusconnection_no_libdbus/tst_qdbusconnection_no_libdbus.cpp
@@ -0,0 +1,73 @@
+/****************************************************************************
+**
+** Copyright (C) 2016 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:GPL-EXCEPT$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see https://www.qt.io/terms-conditions. For further
+** information use the contact form at https://www.qt.io/contact-us.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3 as published by the Free Software
+** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+** included in the packaging of this file. Please review the following
+** information to ensure the GNU General Public License requirements will
+** be met: https://www.gnu.org/licenses/gpl-3.0.html.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+#include <qcoreapplication.h>
+#include <qdebug.h>
+
+#include <QtTest/QtTest>
+#include <QtDBus/QtDBus>
+
+#include <stdlib.h>
+
+/* This test uses an appless main, to ensure that no D-Bus stuff is implicitly done
+ It also sets the magic "QT_SIMULATE_DBUS_LIBFAIL" env variable, that is only available
+ in developer builds. That env variable simulates a D-Bus library load fail.
+
+ In no case should the QDBus module crash because D-Bus libs couldn't be loaded */
+
+class tst_QDBusConnectionNoBus : public QObject
+{
+ Q_OBJECT
+
+public:
+ tst_QDBusConnectionNoBus()
+ {
+ qputenv("DBUS_SESSION_BUS_ADDRESS", "unix:abstract=/tmp/does_not_exist");
+#ifdef SIMULATE_LOAD_FAIL
+ qputenv("QT_SIMULATE_DBUS_LIBFAIL", "1");
+#endif
+ }
+
+private slots:
+ void connectToBus();
+};
+
+
+void tst_QDBusConnectionNoBus::connectToBus()
+{
+ int argc = 0;
+ QCoreApplication app(argc, 0);
+
+ QDBusConnection con = QDBusConnection::sessionBus();
+
+ QVERIFY(!con.isConnected()); // if we didn't crash here, the test passed :)
+}
+
+QTEST_APPLESS_MAIN(tst_QDBusConnectionNoBus)
+
+#include "tst_qdbusconnection_no_libdbus.moc"
+
diff --git a/tests/auto/dbus/qdbusconnection_spyhook/CMakeLists.txt b/tests/auto/dbus/qdbusconnection_spyhook/CMakeLists.txt
new file mode 100644
index 0000000000..0005c36c36
--- /dev/null
+++ b/tests/auto/dbus/qdbusconnection_spyhook/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qdbusconnection_spyhook.pro.
+
+#####################################################################
+## tst_qdbusconnection_spyhook Test:
+#####################################################################
+
+add_qt_test(tst_qdbusconnection_spyhook
+ SOURCES
+ ../qdbusconnection/tst_qdbusconnection.h
+ tst_qdbusconnection_spyhook.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ tst_QDBusConnection=tst_QDBusConnection_SpyHook
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbuscontext/CMakeLists.txt b/tests/auto/dbus/qdbuscontext/CMakeLists.txt
new file mode 100644
index 0000000000..d8adf50bd2
--- /dev/null
+++ b/tests/auto/dbus/qdbuscontext/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdbuscontext.pro.
+
+#####################################################################
+## tst_qdbuscontext Test:
+#####################################################################
+
+add_qt_test(tst_qdbuscontext
+ SOURCES
+ tst_qdbuscontext.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusinterface/CMakeLists.txt b/tests/auto/dbus/qdbusinterface/CMakeLists.txt
new file mode 100644
index 0000000000..c96944cd56
--- /dev/null
+++ b/tests/auto/dbus/qdbusinterface/CMakeLists.txt
@@ -0,0 +1,41 @@
+# Generated from qdbusinterface.pro.
+
+# special case begin
+add_subdirectory(qmyserver)
+
+#####################################################################
+## ../tst_qdbusinterface Test:
+#####################################################################
+
+add_qt_test(tst_qdbusinterface
+ SOURCES
+ myobject.h
+ tst_qdbusinterface.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBusPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::DBus
+)
+
+#### Keys ignored in scope 1:.:.:qdbusinterface.pro:<TRUE>:
+# CONFIG = "testcase"
+# DESTDIR = "./"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qdbusinterface CONDITION QT_FEATURE_dbus_linked
+ DEFINES
+ QT_LINKED_LIBDBUS
+ PUBLIC_LIBRARIES
+ dbus-1
+)
+
+extend_target(tst_qdbusinterface CONDITION NOT QT_FEATURE_dbus_linked
+ SOURCES
+ ../../../../src/dbus/qdbus_symbols.cpp
+)
+
+# special case end
diff --git a/tests/auto/dbus/qdbusinterface/qmyserver/.prev_CMakeLists.txt b/tests/auto/dbus/qdbusinterface/qmyserver/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..671403999b
--- /dev/null
+++ b/tests/auto/dbus/qdbusinterface/qmyserver/.prev_CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qmyserver.pro.
+
+#####################################################################
+## qmyserver_qdbusinterface Binary:
+#####################################################################
+
+add_qt_executable(qmyserver_qdbusinterface
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ ../myobject.h
+ qmyserver.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusinterface/qmyserver/CMakeLists.txt b/tests/auto/dbus/qdbusinterface/qmyserver/CMakeLists.txt
new file mode 100644
index 0000000000..de633f2aa9
--- /dev/null
+++ b/tests/auto/dbus/qdbusinterface/qmyserver/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qmyserver.pro.
+
+#####################################################################
+## qmyserver_qdbusinterface Binary:
+#####################################################################
+
+add_qt_executable(qmyserver_qdbusinterface
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ NO_INSTALL # special case
+ SOURCES
+ ../myobject.h
+ qmyserver.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusinterface/qmyserver/qmyserver.pro b/tests/auto/dbus/qdbusinterface/qmyserver/qmyserver.pro
index 8f2d261899..406f3d7d36 100644
--- a/tests/auto/dbus/qdbusinterface/qmyserver/qmyserver.pro
+++ b/tests/auto/dbus/qdbusinterface/qmyserver/qmyserver.pro
@@ -1,6 +1,6 @@
SOURCES = qmyserver.cpp
HEADERS = ../myobject.h
-TARGET = qmyserver
+TARGET = qmyserver_qdbusinterface
DESTDIR = ./
QT = core dbus
CONFIG -= app_bundle
diff --git a/tests/auto/dbus/qdbusinterface/tst_qdbusinterface.cpp b/tests/auto/dbus/qdbusinterface/tst_qdbusinterface.cpp
index 5453d9de61..e416266b5f 100644
--- a/tests/auto/dbus/qdbusinterface/tst_qdbusinterface.cpp
+++ b/tests/auto/dbus/qdbusinterface/tst_qdbusinterface.cpp
@@ -271,7 +271,7 @@ void tst_QDBusInterface::initTestCase()
# define EXE ""
#endif
proc.setProcessChannelMode(QProcess::ForwardedErrorChannel);
- proc.start(QFINDTESTDATA("qmyserver/qmyserver" EXE));
+ proc.start(QFINDTESTDATA("qmyserver/qmyserver_qdbusinterface" EXE)); // FIXME CMake: This is most probably wrong now since the binary ends up in bin/ not in the build tree
QVERIFY2(proc.waitForStarted(), qPrintable(proc.errorString()));
QVERIFY(proc.waitForReadyRead());
diff --git a/tests/auto/dbus/qdbuslocalcalls/CMakeLists.txt b/tests/auto/dbus/qdbuslocalcalls/CMakeLists.txt
new file mode 100644
index 0000000000..c65b48f948
--- /dev/null
+++ b/tests/auto/dbus/qdbuslocalcalls/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdbuslocalcalls.pro.
+
+#####################################################################
+## tst_qdbuslocalcalls Test:
+#####################################################################
+
+add_qt_test(tst_qdbuslocalcalls
+ SOURCES
+ tst_qdbuslocalcalls.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusmarshall/CMakeLists.txt b/tests/auto/dbus/qdbusmarshall/CMakeLists.txt
new file mode 100644
index 0000000000..aabeae0f4a
--- /dev/null
+++ b/tests/auto/dbus/qdbusmarshall/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from qdbusmarshall.pro.
+
+add_subdirectory(qpong)
+add_subdirectory(qdbusmarshall)
diff --git a/tests/auto/dbus/qdbusmarshall/qdbusmarshall/.prev_CMakeLists.txt b/tests/auto/dbus/qdbusmarshall/qdbusmarshall/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..6f8a6804e1
--- /dev/null
+++ b/tests/auto/dbus/qdbusmarshall/qdbusmarshall/.prev_CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from qdbusmarshall.pro.
+
+#####################################################################
+## tst_qdbusmarshall Test:
+#####################################################################
+
+add_qt_test(tst_qdbusmarshall
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ ../tst_qdbusmarshall.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBusPrivate
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qdbusmarshall CONDITION QT_FEATURE_dbus_linked
+ DEFINES
+ QT_LINKED_LIBDBUS
+ PUBLIC_LIBRARIES
+ dbus-1
+)
+
+extend_target(tst_qdbusmarshall CONDITION NOT QT_FEATURE_dbus_linked
+ SOURCES
+ ../../../../../src/dbus/qdbus_symbols.cpp
+)
diff --git a/tests/auto/dbus/qdbusmarshall/qdbusmarshall/CMakeLists.txt b/tests/auto/dbus/qdbusmarshall/qdbusmarshall/CMakeLists.txt
new file mode 100644
index 0000000000..84976ee923
--- /dev/null
+++ b/tests/auto/dbus/qdbusmarshall/qdbusmarshall/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from qdbusmarshall.pro.
+
+#####################################################################
+## tst_qdbusmarshall Test:
+#####################################################################
+
+add_qt_test(tst_qdbusmarshall
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ SOURCES
+ ../tst_qdbusmarshall.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBusPrivate
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
+
+## Scopes:
+#####################################################################
+
+# special case begin
+# This test case interacts with dbus code directly via the private
+# headers. The include path is also not exposed via Qt:DBus.
+# special case end
+extend_target(tst_qdbusmarshall CONDITION QT_FEATURE_dbus_linked
+ DEFINES
+ QT_LINKED_LIBDBUS
+ PUBLIC_LIBRARIES
+ dbus-1
+)
+
+extend_target(tst_qdbusmarshall CONDITION NOT QT_FEATURE_dbus_linked
+ SOURCES
+ ../../../../../src/dbus/qdbus_symbols.cpp
+)
diff --git a/tests/auto/dbus/qdbusmarshall/qpong/CMakeLists.txt b/tests/auto/dbus/qdbusmarshall/qpong/CMakeLists.txt
new file mode 100644
index 0000000000..e53c11aabe
--- /dev/null
+++ b/tests/auto/dbus/qdbusmarshall/qpong/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qpong.pro.
+
+#####################################################################
+## qpong Binary:
+#####################################################################
+
+add_qt_executable(qpong
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ qpong.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusmetaobject/CMakeLists.txt b/tests/auto/dbus/qdbusmetaobject/CMakeLists.txt
new file mode 100644
index 0000000000..1ffd6944d1
--- /dev/null
+++ b/tests/auto/dbus/qdbusmetaobject/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qdbusmetaobject.pro.
+
+#####################################################################
+## tst_qdbusmetaobject Test:
+#####################################################################
+
+add_qt_test(tst_qdbusmetaobject
+ SOURCES
+ tst_qdbusmetaobject.cpp
+ LIBRARIES
+ Qt::DBusPrivate
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusmetatype/CMakeLists.txt b/tests/auto/dbus/qdbusmetatype/CMakeLists.txt
new file mode 100644
index 0000000000..1bc7871f8c
--- /dev/null
+++ b/tests/auto/dbus/qdbusmetatype/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdbusmetatype.pro.
+
+#####################################################################
+## tst_qdbusmetatype Test:
+#####################################################################
+
+add_qt_test(tst_qdbusmetatype
+ SOURCES
+ tst_qdbusmetatype.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbuspendingcall/CMakeLists.txt b/tests/auto/dbus/qdbuspendingcall/CMakeLists.txt
new file mode 100644
index 0000000000..d432fd3f6c
--- /dev/null
+++ b/tests/auto/dbus/qdbuspendingcall/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdbuspendingcall.pro.
+
+#####################################################################
+## tst_qdbuspendingcall Test:
+#####################################################################
+
+add_qt_test(tst_qdbuspendingcall
+ SOURCES
+ tst_qdbuspendingcall.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbuspendingreply/CMakeLists.txt b/tests/auto/dbus/qdbuspendingreply/CMakeLists.txt
new file mode 100644
index 0000000000..f6ff6afe8c
--- /dev/null
+++ b/tests/auto/dbus/qdbuspendingreply/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdbuspendingreply.pro.
+
+#####################################################################
+## tst_qdbuspendingreply Test:
+#####################################################################
+
+add_qt_test(tst_qdbuspendingreply
+ SOURCES
+ tst_qdbuspendingreply.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusreply/CMakeLists.txt b/tests/auto/dbus/qdbusreply/CMakeLists.txt
new file mode 100644
index 0000000000..11770e16d5
--- /dev/null
+++ b/tests/auto/dbus/qdbusreply/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdbusreply.pro.
+
+#####################################################################
+## tst_qdbusreply Test:
+#####################################################################
+
+add_qt_test(tst_qdbusreply
+ SOURCES
+ tst_qdbusreply.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusservicewatcher/CMakeLists.txt b/tests/auto/dbus/qdbusservicewatcher/CMakeLists.txt
new file mode 100644
index 0000000000..436629ab80
--- /dev/null
+++ b/tests/auto/dbus/qdbusservicewatcher/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdbusservicewatcher.pro.
+
+#####################################################################
+## tst_qdbusservicewatcher Test:
+#####################################################################
+
+add_qt_test(tst_qdbusservicewatcher
+ SOURCES
+ tst_qdbusservicewatcher.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusthreading/CMakeLists.txt b/tests/auto/dbus/qdbusthreading/CMakeLists.txt
new file mode 100644
index 0000000000..1c8f8a6053
--- /dev/null
+++ b/tests/auto/dbus/qdbusthreading/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdbusthreading.pro.
+
+#####################################################################
+## tst_qdbusthreading Test:
+#####################################################################
+
+add_qt_test(tst_qdbusthreading
+ SOURCES
+ tst_qdbusthreading.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbustype/CMakeLists.txt b/tests/auto/dbus/qdbustype/CMakeLists.txt
new file mode 100644
index 0000000000..37ba25e017
--- /dev/null
+++ b/tests/auto/dbus/qdbustype/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from qdbustype.pro.
+
+#####################################################################
+## tst_qdbustype Test:
+#####################################################################
+
+add_qt_test(tst_qdbustype
+ SOURCES
+ tst_qdbustype.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBusPrivate
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qdbustype CONDITION QT_FEATURE_dbus_linked
+ DEFINES
+ QT_LINKED_LIBDBUS
+ PUBLIC_LIBRARIES
+ dbus-1
+)
+
+extend_target(tst_qdbustype CONDITION NOT QT_FEATURE_dbus_linked
+ SOURCES
+ ../../../../src/dbus/qdbus_symbols.cpp
+)
diff --git a/tests/auto/dbus/qdbusxmlparser/CMakeLists.txt b/tests/auto/dbus/qdbusxmlparser/CMakeLists.txt
new file mode 100644
index 0000000000..71b223bdc6
--- /dev/null
+++ b/tests/auto/dbus/qdbusxmlparser/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qdbusxmlparser.pro.
+
+#####################################################################
+## tst_qdbusxmlparser Test:
+#####################################################################
+
+add_qt_test(tst_qdbusxmlparser
+ SOURCES
+ tst_qdbusxmlparser.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBusPrivate
+ PUBLIC_LIBRARIES
+ Qt::DBus
+ Qt::Xml
+)
diff --git a/tests/auto/gui/.prev_CMakeLists.txt b/tests/auto/gui/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..8cbfa78aad
--- /dev/null
+++ b/tests/auto/gui/.prev_CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from gui.pro.
+
+add_subdirectory(kernel)
+if(NOT APPLE_UIKIT)
+ add_subdirectory(image)
+ add_subdirectory(math3d)
+ add_subdirectory(painting)
+ add_subdirectory(text)
+ add_subdirectory(util)
+ add_subdirectory(itemmodels)
+ add_subdirectory(rhi)
+endif()
+if(QT_FEATURE_opengl AND NOT APPLE_UIKIT AND NOT WINRT)
+ add_subdirectory(qopenglconfig)
+ add_subdirectory(qopengl)
+endif()
+if(QT_FEATURE_vulkan AND NOT APPLE_UIKIT)
+ add_subdirectory(qvulkan)
+endif()
diff --git a/tests/auto/gui/CMakeLists.txt b/tests/auto/gui/CMakeLists.txt
new file mode 100644
index 0000000000..9a1312bd48
--- /dev/null
+++ b/tests/auto/gui/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from gui.pro.
+
+add_subdirectory(kernel)
+if(NOT APPLE_UIKIT)
+ add_subdirectory(image)
+ add_subdirectory(math3d)
+ add_subdirectory(painting)
+ add_subdirectory(text)
+ add_subdirectory(util)
+ add_subdirectory(itemmodels)
+ add_subdirectory(rhi)
+endif()
+if(QT_FEATURE_opengl AND NOT APPLE_UIKIT AND NOT WINRT)
+ add_subdirectory(qopenglconfig)
+ add_subdirectory(qopengl)
+endif()
+if(QT_FEATURE_vulkan AND NOT APPLE_UIKIT)
+ add_subdirectory(qvulkan)
+endif()
diff --git a/tests/auto/gui/image/CMakeLists.txt b/tests/auto/gui/image/CMakeLists.txt
new file mode 100644
index 0000000000..8ae016a8f8
--- /dev/null
+++ b/tests/auto/gui/image/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from image.pro.
+
+if(TARGET Qt::Network)
+ add_subdirectory(qimagereader)
+endif()
+add_subdirectory(qicoimageformat)
+add_subdirectory(qpixmap)
+add_subdirectory(qimage)
+add_subdirectory(qimageiohandler)
+add_subdirectory(qimagewriter)
+add_subdirectory(qmovie)
+add_subdirectory(qpicture)
+add_subdirectory(qicon)
+add_subdirectory(qiconhighdpi)
+if(QT_FEATURE_private_tests)
+ add_subdirectory(qpixmapcache)
+endif()
diff --git a/tests/auto/gui/image/qicoimageformat/CMakeLists.txt b/tests/auto/gui/image/qicoimageformat/CMakeLists.txt
new file mode 100644
index 0000000000..0c8393631a
--- /dev/null
+++ b/tests/auto/gui/image/qicoimageformat/CMakeLists.txt
@@ -0,0 +1,49 @@
+# Generated from qicoimageformat.pro.
+
+#####################################################################
+## tst_qicoimageformat Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ icons/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qicoimageformat
+ SOURCES
+ tst_qicoimageformat.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+if(ANDROID)
+ # Resources:
+ set(qicoimageformat_resource_files
+ "icons/invalid/35floppy.ico"
+ "icons/valid/35FLOPPY.ICO"
+ "icons/valid/AddPerfMon.ico"
+ "icons/valid/App.ico"
+ "icons/valid/Obj_N2_Internal_Mem.ico"
+ "icons/valid/Qt.ico"
+ "icons/valid/Status_Play.ico"
+ "icons/valid/TIMER01.ICO"
+ "icons/valid/WORLD.ico"
+ "icons/valid/WORLDH.ico"
+ "icons/valid/abcardWindow.ico"
+ "icons/valid/semitransparent.ico"
+ "icons/valid/trolltechlogo_tiny.ico"
+ "icons/valid/yellow.cur"
+ )
+
+ add_qt_resource(tst_qicoimageformat "qicoimageformat"
+ PREFIX
+ "/"
+ FILES
+ ${qicoimageformat_resource_files}
+ )
+endif()
diff --git a/tests/auto/gui/image/qicon/CMakeLists.txt b/tests/auto/gui/image/qicon/CMakeLists.txt
new file mode 100644
index 0000000000..81f5390d79
--- /dev/null
+++ b/tests/auto/gui/image/qicon/CMakeLists.txt
@@ -0,0 +1,94 @@
+# Generated from qicon.pro.
+
+#####################################################################
+## tst_qicon Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ icons/*)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ second_icons/*)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ fallback_icons/*)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ *.png)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ *.svg)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ *.svgz)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qicon
+ SOURCES
+ tst_qicon.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
+
+# Resources:
+set(tst_qicon_resource_files
+ "./fallback_icons/red.png"
+ "./icons/testtheme/16x16/actions/appointment-new.png"
+ "./icons/testtheme/22x22/actions/appointment-new.png"
+ "./icons/testtheme/index.theme"
+ "./icons/testtheme/scalable/actions/svg-only.svg"
+ "./icons/themeparent/16x16/actions/address-book-new.png"
+ "./icons/themeparent/16x16/actions/appointment-new.png"
+ "./icons/themeparent/22x22/actions/address-book-new.png"
+ "./icons/themeparent/22x22/actions/appointment-new.png"
+ "./icons/themeparent/32x32/actions/address-book-new.png"
+ "./icons/themeparent/32x32/actions/appointment-new.png"
+ "./icons/themeparent/icon-theme.cache"
+ "./icons/themeparent/index.theme"
+ "./icons/themeparent/scalable/actions/address-book-new.svg"
+ "./icons/themeparent/scalable/actions/appointment-new.svg"
+ "./second_icons/testtheme/32x32/actions/appointment-new.png"
+ "./styles/commonstyle/images/standardbutton-open-128.png"
+ "./styles/commonstyle/images/standardbutton-open-16.png"
+ "./styles/commonstyle/images/standardbutton-open-32.png"
+ "./styles/commonstyle/images/standardbutton-save-128.png"
+ "./styles/commonstyle/images/standardbutton-save-16.png"
+ "./styles/commonstyle/images/standardbutton-save-32.png"
+ "image.png"
+ "rect.png"
+ "tst_qicon.cpp"
+)
+
+add_qt_resource(tst_qicon "tst_qicon"
+ PREFIX
+ "/"
+ FILES
+ ${tst_qicon_resource_files}
+)
+set(qmake_immediate_resource_files
+ "tst_qicon.cpp"
+)
+
+add_qt_resource(tst_qicon "qmake_immediate"
+ PREFIX
+ "/"
+ FILES
+ ${qmake_immediate_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qicon CONDITION TARGET Qt::Widgets
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
diff --git a/tests/auto/gui/image/qiconhighdpi/CMakeLists.txt b/tests/auto/gui/image/qiconhighdpi/CMakeLists.txt
new file mode 100644
index 0000000000..6f6aaedca5
--- /dev/null
+++ b/tests/auto/gui/image/qiconhighdpi/CMakeLists.txt
@@ -0,0 +1,37 @@
+# Generated from qiconhighdpi.pro.
+
+#####################################################################
+## tst_qiconhighdpi Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ icons/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qiconhighdpi
+ SOURCES
+ tst_qiconhighdpi.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
+
+# Resources:
+set(tst_qiconhighdpi_resource_files
+ "icons/misc/button.9.png"
+ "icons/misc/button@2x.9.png"
+ "icons/testtheme/16x16/actions/appointment-new.png"
+ "icons/testtheme/22x22/actions/appointment-new.png"
+ "icons/testtheme/22x22@2/actions/appointment-new.png"
+ "icons/testtheme/index.theme"
+)
+
+add_qt_resource(tst_qiconhighdpi "tst_qiconhighdpi"
+ PREFIX
+ "/"
+ FILES
+ ${tst_qiconhighdpi_resource_files}
+)
+
diff --git a/tests/auto/gui/image/qimage/CMakeLists.txt b/tests/auto/gui/image/qimage/CMakeLists.txt
new file mode 100644
index 0000000000..6951f9a703
--- /dev/null
+++ b/tests/auto/gui/image/qimage/CMakeLists.txt
@@ -0,0 +1,67 @@
+# Generated from qimage.pro.
+
+#####################################################################
+## tst_qimage Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ images/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qimage
+ SOURCES
+ tst_qimage.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ # Resources:
+ set(qimage_resource_files
+ "images/image.bmp"
+ "images/image.gif"
+ "images/image.ico"
+ "images/image.jpg"
+ "images/image.pbm"
+ "images/image.pgm"
+ "images/image.png"
+ "images/image.ppm"
+ "images/image.xbm"
+ "images/image.xpm"
+ "images/jpeg_exif_orientation_value_1.jpg"
+ "images/jpeg_exif_orientation_value_2.jpg"
+ "images/jpeg_exif_orientation_value_3.jpg"
+ "images/jpeg_exif_orientation_value_4.jpg"
+ "images/jpeg_exif_orientation_value_5.jpg"
+ "images/jpeg_exif_orientation_value_6.jpg"
+ "images/jpeg_exif_orientation_value_7.jpg"
+ "images/jpeg_exif_orientation_value_8.jpg"
+ )
+
+ add_qt_resource(tst_qimage "qimage"
+ PREFIX
+ "/"
+ FILES
+ ${qimage_resource_files}
+ )
+endif()
+
+extend_target(tst_qimage CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ gdi32
+ user32
+)
+
+extend_target(tst_qimage CONDITION APPLE
+ PUBLIC_LIBRARIES
+ ${FWCoreGraphics}
+)
diff --git a/tests/auto/gui/image/qimageiohandler/CMakeLists.txt b/tests/auto/gui/image/qimageiohandler/CMakeLists.txt
new file mode 100644
index 0000000000..23e5e98b16
--- /dev/null
+++ b/tests/auto/gui/image/qimageiohandler/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qimageiohandler.pro.
+
+#####################################################################
+## tst_qimageiohandler Test:
+#####################################################################
+
+add_qt_test(tst_qimageiohandler
+ SOURCES
+ tst_qimageiohandler.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/image/qimagereader/CMakeLists.txt b/tests/auto/gui/image/qimagereader/CMakeLists.txt
new file mode 100644
index 0000000000..93bf709c20
--- /dev/null
+++ b/tests/auto/gui/image/qimagereader/CMakeLists.txt
@@ -0,0 +1,66 @@
+# Generated from qimagereader.pro.
+
+#####################################################################
+## tst_qimagereader Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ images/*)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ baseline/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qimagereader
+ SOURCES
+ tst_qimagereader.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Network
+ TESTDATA ${test_data}
+)
+
+file(GLOB resource_glob_0 RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" "images/*")
+foreach(file IN LISTS resource_glob_0)
+ set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/${file}" PROPERTIES QT_RESOURCE_ALIAS "${file}")
+endforeach()
+
+# Resources:
+set(qmake_immediate_resource_files
+ ${resource_glob_0}
+)
+
+add_qt_resource(tst_qimagereader "qmake_immediate"
+ PREFIX
+ "/"
+ FILES
+ ${qmake_immediate_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:qimagereader.pro:<TRUE>:
+# MOC_DIR = "tmp"
+
+## Scopes:
+#####################################################################
+
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ # Resources:
+ set(android_testdata_resource_files
+ "images/kollada-noext"
+ "images/trans.gif"
+ )
+
+ add_qt_resource(tst_qimagereader "android_testdata"
+ PREFIX
+ "/"
+ FILES
+ ${android_testdata_resource_files}
+ )
+endif()
diff --git a/tests/auto/gui/image/qimagewriter/CMakeLists.txt b/tests/auto/gui/image/qimagewriter/CMakeLists.txt
new file mode 100644
index 0000000000..1a04dfbce0
--- /dev/null
+++ b/tests/auto/gui/image/qimagewriter/CMakeLists.txt
@@ -0,0 +1,50 @@
+# Generated from qimagewriter.pro.
+
+#####################################################################
+## tst_qimagewriter Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ images/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qimagewriter
+ SOURCES
+ tst_qimagewriter.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
+
+#### Keys ignored in scope 1:.:.:qimagewriter.pro:<TRUE>:
+# MOC_DIR = "tmp"
+
+## Scopes:
+#####################################################################
+
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ # Resources:
+ set(qimagewriter_resource_files
+ "images/YCbCr_cmyk.jpg"
+ "images/YCbCr_rgb.jpg"
+ "images/beavis.jpg"
+ "images/colorful.bmp"
+ "images/earth.gif"
+ "images/font.bmp"
+ "images/gnus.xbm"
+ "images/kollada.png"
+ "images/marble.xpm"
+ "images/ship63.pbm"
+ "images/teapot.ppm"
+ "images/trolltech.gif"
+ )
+
+ add_qt_resource(tst_qimagewriter "qimagewriter"
+ PREFIX
+ "/"
+ FILES
+ ${qimagewriter_resource_files}
+ )
+endif()
diff --git a/tests/auto/gui/image/qmovie/CMakeLists.txt b/tests/auto/gui/image/qmovie/CMakeLists.txt
new file mode 100644
index 0000000000..bc841b5d29
--- /dev/null
+++ b/tests/auto/gui/image/qmovie/CMakeLists.txt
@@ -0,0 +1,56 @@
+# Generated from qmovie.pro.
+
+#####################################################################
+## tst_qmovie Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ animations/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qmovie
+ SOURCES
+ tst_qmovie.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
+
+# Resources:
+set(resources_resource_files
+ "animations/comicsecard.gif"
+ "animations/corrupt.gif"
+ "animations/trolltech.gif"
+)
+
+add_qt_resource(tst_qmovie "resources"
+ PREFIX
+ "/"
+ FILES
+ ${resources_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:qmovie.pro:<TRUE>:
+# MOC_DIR = "tmp"
+# QT_FOR_CONFIG = "gui-private"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qmovie CONDITION TARGET Qt::Widgets
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
+
+extend_target(tst_qmovie CONDITION QT_FEATURE_gif
+ DEFINES
+ QTEST_HAVE_GIF
+)
+
+extend_target(tst_qmovie CONDITION QT_FEATURE_jpeg
+ DEFINES
+ QTEST_HAVE_JPEG
+)
diff --git a/tests/auto/gui/image/qpicture/CMakeLists.txt b/tests/auto/gui/image/qpicture/CMakeLists.txt
new file mode 100644
index 0000000000..625d19b3a5
--- /dev/null
+++ b/tests/auto/gui/image/qpicture/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qpicture.pro.
+
+#####################################################################
+## tst_qpicture Test:
+#####################################################################
+
+add_qt_test(tst_qpicture
+ SOURCES
+ tst_qpicture.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/image/qpixmap/CMakeLists.txt b/tests/auto/gui/image/qpixmap/CMakeLists.txt
new file mode 100644
index 0000000000..32c60e95c3
--- /dev/null
+++ b/tests/auto/gui/image/qpixmap/CMakeLists.txt
@@ -0,0 +1,109 @@
+# Generated from qpixmap.pro.
+
+#####################################################################
+## tst_qpixmap Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ convertFromImage/*)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ convertFromToHICON/*)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ loadFromData/*)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ images/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qpixmap
+ SOURCES
+ tst_qpixmap.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
+
+# Resources:
+set(qpixmap_resource_files
+ "convertFromImage/task31722_0/img1.png"
+ "convertFromImage/task31722_0/img2.png"
+ "convertFromImage/task31722_1/img1.png"
+ "convertFromImage/task31722_1/img2.png"
+ "convertFromToHICON/icon_32bpp.ico"
+ "convertFromToHICON/icon_32bpp_16x16.png"
+ "convertFromToHICON/icon_32bpp_256x256.png"
+ "convertFromToHICON/icon_32bpp_32x32.png"
+ "convertFromToHICON/icon_32bpp_48x48.png"
+ "convertFromToHICON/icon_8bpp.ico"
+ "convertFromToHICON/icon_8bpp_16x16.png"
+ "convertFromToHICON/icon_8bpp_32x32.png"
+ "convertFromToHICON/icon_8bpp_48x48.png"
+ "images/designer.png"
+ "images/dx_-10_dy_-10_50_50_100_100.png"
+ "images/dx_-10_dy_-10_x_y_w_h.png"
+ "images/dx_-10_dy_0_50_50_100_100.png"
+ "images/dx_-10_dy_0_x_y_w_h.png"
+ "images/dx_-128_dy_-128_x_y_w_h.png"
+ "images/dx_-128_dy_0_x_y_w_h.png"
+ "images/dx_0_dy_-10_50_50_100_100.png"
+ "images/dx_0_dy_-10_x_y_w_h.png"
+ "images/dx_0_dy_-128_x_y_w_h.png"
+ "images/dx_0_dy_0_50_50_100_100.png"
+ "images/dx_0_dy_0_null.png"
+ "images/dx_0_dy_0_x_y_w_h.png"
+ "images/dx_0_dy_10_50_50_100_100.png"
+ "images/dx_0_dy_10_x_y_w_h.png"
+ "images/dx_0_dy_128_x_y_w_h.png"
+ "images/dx_0_dy_1_null.png"
+ "images/dx_10_dy_0_50_50_100_100.png"
+ "images/dx_10_dy_0_x_y_w_h.png"
+ "images/dx_10_dy_10_50_50_100_100.png"
+ "images/dx_10_dy_10_x_y_w_h.png"
+ "images/dx_128_dy_0_x_y_w_h.png"
+ "images/dx_128_dy_128_64_64_128_128.png"
+ "images/dx_128_dy_128_x_y_w_h.png"
+ "images/dx_1_dy_0_null.png"
+ "loadFromData/designer_argb32.png"
+ "loadFromData/designer_indexed8_no_alpha.gif"
+ "loadFromData/designer_indexed8_no_alpha.png"
+ "loadFromData/designer_indexed8_no_alpha_animated.gif"
+ "loadFromData/designer_indexed8_with_alpha.gif"
+ "loadFromData/designer_indexed8_with_alpha.png"
+ "loadFromData/designer_indexed8_with_alpha_animated.gif"
+ "loadFromData/designer_rgb32.jpg"
+ "loadFromData/designer_rgb32.png"
+)
+
+add_qt_resource(tst_qpixmap "qpixmap"
+ PREFIX
+ "/"
+ FILES
+ ${qpixmap_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qpixmap CONDITION TARGET Qt::Widgets
+ LIBRARIES
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
+
+extend_target(tst_qpixmap CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ gdi32
+ user32
+)
diff --git a/tests/auto/gui/image/qpixmapcache/CMakeLists.txt b/tests/auto/gui/image/qpixmapcache/CMakeLists.txt
new file mode 100644
index 0000000000..584e77c986
--- /dev/null
+++ b/tests/auto/gui/image/qpixmapcache/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qpixmapcache.pro.
+
+#####################################################################
+## tst_qpixmapcache Test:
+#####################################################################
+
+add_qt_test(tst_qpixmapcache
+ SOURCES
+ tst_qpixmapcache.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/itemmodels/CMakeLists.txt b/tests/auto/gui/itemmodels/CMakeLists.txt
new file mode 100644
index 0000000000..196168b1b2
--- /dev/null
+++ b/tests/auto/gui/itemmodels/CMakeLists.txt
@@ -0,0 +1,4 @@
+add_subdirectory("qstandarditem")
+if (QT_FEATURE_widgets)
+# add_subdirectory("qstandarditemmodel")
+endif()
diff --git a/tests/auto/gui/itemmodels/qstandarditem/CMakeLists.txt b/tests/auto/gui/itemmodels/qstandarditem/CMakeLists.txt
new file mode 100644
index 0000000000..8a19f6afaf
--- /dev/null
+++ b/tests/auto/gui/itemmodels/qstandarditem/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qstandarditem.pro.
+
+#####################################################################
+## tst_qstandarditem Test:
+#####################################################################
+
+add_qt_test(tst_qstandarditem
+ SOURCES
+ tst_qstandarditem.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/CMakeLists.txt b/tests/auto/gui/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..b2397bed19
--- /dev/null
+++ b/tests/auto/gui/kernel/CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from kernel.pro.
+
+add_subdirectory(qbackingstore)
+add_subdirectory(qcursor)
+add_subdirectory(qdrag)
+add_subdirectory(qevent)
+add_subdirectory(qfileopenevent)
+add_subdirectory(qguieventdispatcher)
+add_subdirectory(qguimetatype)
+add_subdirectory(qguitimer)
+add_subdirectory(qguivariant)
+add_subdirectory(qinputmethod)
+add_subdirectory(qkeyevent)
+add_subdirectory(qkeysequence)
+add_subdirectory(qmouseevent)
+add_subdirectory(qpalette)
+add_subdirectory(qscreen)
+add_subdirectory(qsurfaceformat)
+add_subdirectory(qwindow)
+add_subdirectory(qguiapplication)
+add_subdirectory(qpixelformat)
+add_subdirectory(qrasterwindow)
+if(NOT ANDROID AND NOT APPLE_UIKIT)
+ add_subdirectory(qclipboard)
+endif()
+if(TARGET Qt::Network)
+ add_subdirectory(qguieventloop)
+endif()
+if(TARGET Qt::Widgets)
+ add_subdirectory(qmouseevent_modal)
+ add_subdirectory(qtouchevent)
+endif()
+if(QT_FEATURE_opengl)
+ add_subdirectory(qopenglwindow)
+endif()
+if(TARGET Qt::Network AND WIN32 AND NOT WINRT)
+ add_subdirectory(noqteventloop)
+endif()
diff --git a/tests/auto/gui/kernel/noqteventloop/CMakeLists.txt b/tests/auto/gui/kernel/noqteventloop/CMakeLists.txt
new file mode 100644
index 0000000000..7161c47db1
--- /dev/null
+++ b/tests/auto/gui/kernel/noqteventloop/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from noqteventloop.pro.
+
+#####################################################################
+## tst_noqteventloop Test:
+#####################################################################
+
+add_qt_test(tst_noqteventloop
+ SOURCES
+ tst_noqteventloop.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_noqteventloop CONDITION QT_FEATURE_dynamicgl AND WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ user32
+)
diff --git a/tests/auto/gui/kernel/qbackingstore/CMakeLists.txt b/tests/auto/gui/kernel/qbackingstore/CMakeLists.txt
new file mode 100644
index 0000000000..d657196113
--- /dev/null
+++ b/tests/auto/gui/kernel/qbackingstore/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qbackingstore.pro.
+
+#####################################################################
+## tst_qbackingstore Test:
+#####################################################################
+
+add_qt_test(tst_qbackingstore
+ SOURCES
+ tst_qbackingstore.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qclipboard/CMakeLists.txt b/tests/auto/gui/kernel/qclipboard/CMakeLists.txt
new file mode 100644
index 0000000000..b795d32520
--- /dev/null
+++ b/tests/auto/gui/kernel/qclipboard/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from qclipboard.pro.
+
+add_subdirectory(test)
+if(NOT WINRT)
+ add_subdirectory(copier)
+ add_subdirectory(paster)
+endif()
diff --git a/tests/auto/gui/kernel/qclipboard/copier/CMakeLists.txt b/tests/auto/gui/kernel/qclipboard/copier/CMakeLists.txt
new file mode 100644
index 0000000000..30990c1387
--- /dev/null
+++ b/tests/auto/gui/kernel/qclipboard/copier/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from copier.pro.
+
+#####################################################################
+## copier Binary:
+#####################################################################
+
+add_qt_executable(copier
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:copier.pro:WIN32:
+# DESTDIR = "../copier"
diff --git a/tests/auto/gui/kernel/qclipboard/paster/CMakeLists.txt b/tests/auto/gui/kernel/qclipboard/paster/CMakeLists.txt
new file mode 100644
index 0000000000..2c90c1530f
--- /dev/null
+++ b/tests/auto/gui/kernel/qclipboard/paster/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from paster.pro.
+
+#####################################################################
+## paster Binary:
+#####################################################################
+
+add_qt_executable(paster
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:paster.pro:WIN32:
+# DESTDIR = "../paster"
diff --git a/tests/auto/gui/kernel/qclipboard/test/.prev_CMakeLists.txt b/tests/auto/gui/kernel/qclipboard/test/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..620ef96a5b
--- /dev/null
+++ b/tests/auto/gui/kernel/qclipboard/test/.prev_CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qclipboard Test:
+#####################################################################
+
+add_qt_test(tst_qclipboard
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ SOURCES
+ ../tst_qclipboard.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qclipboard CONDITION APPLE_OSX
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+)
+
+#### Keys ignored in scope 6:.:.:test.pro:NOT ANDROID AND NOT WINRT:
+# TEST_HELPER_INSTALLS = "../copier/copier" "../paster/paster"
diff --git a/tests/auto/gui/kernel/qclipboard/test/CMakeLists.txt b/tests/auto/gui/kernel/qclipboard/test/CMakeLists.txt
new file mode 100644
index 0000000000..620ef96a5b
--- /dev/null
+++ b/tests/auto/gui/kernel/qclipboard/test/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qclipboard Test:
+#####################################################################
+
+add_qt_test(tst_qclipboard
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ SOURCES
+ ../tst_qclipboard.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qclipboard CONDITION APPLE_OSX
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+)
+
+#### Keys ignored in scope 6:.:.:test.pro:NOT ANDROID AND NOT WINRT:
+# TEST_HELPER_INSTALLS = "../copier/copier" "../paster/paster"
diff --git a/tests/auto/gui/kernel/qcursor/CMakeLists.txt b/tests/auto/gui/kernel/qcursor/CMakeLists.txt
new file mode 100644
index 0000000000..8f4062a42a
--- /dev/null
+++ b/tests/auto/gui/kernel/qcursor/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qcursor.pro.
+
+#####################################################################
+## tst_qcursor Test:
+#####################################################################
+
+add_qt_test(tst_qcursor
+ SOURCES
+ tst_qcursor.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qdrag/CMakeLists.txt b/tests/auto/gui/kernel/qdrag/CMakeLists.txt
new file mode 100644
index 0000000000..84bceaf0de
--- /dev/null
+++ b/tests/auto/gui/kernel/qdrag/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdrag.pro.
+
+#####################################################################
+## tst_qdrag Test:
+#####################################################################
+
+add_qt_test(tst_qdrag
+ SOURCES
+ tst_qdrag.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qevent/CMakeLists.txt b/tests/auto/gui/kernel/qevent/CMakeLists.txt
new file mode 100644
index 0000000000..01d6db7225
--- /dev/null
+++ b/tests/auto/gui/kernel/qevent/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qevent.pro.
+
+#####################################################################
+## tst_qevent Test:
+#####################################################################
+
+add_qt_test(tst_qevent
+ SOURCES
+ tst_qevent.cpp
+)
diff --git a/tests/auto/gui/kernel/qfileopenevent/CMakeLists.txt b/tests/auto/gui/kernel/qfileopenevent/CMakeLists.txt
new file mode 100644
index 0000000000..2404833737
--- /dev/null
+++ b/tests/auto/gui/kernel/qfileopenevent/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from qfileopenevent.pro.
+
+add_subdirectory(test)
+add_subdirectory(qfileopeneventexternal)
diff --git a/tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/CMakeLists.txt b/tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/CMakeLists.txt
new file mode 100644
index 0000000000..0c50f7ff56
--- /dev/null
+++ b/tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qfileopeneventexternal.pro.
+
+#####################################################################
+## qfileopeneventexternal Binary:
+#####################################################################
+
+add_qt_executable(qfileopeneventexternal
+ GUI
+ SOURCES
+ qfileopeneventexternal.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:qfileopeneventexternal.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/auto/gui/kernel/qfileopenevent/test/CMakeLists.txt b/tests/auto/gui/kernel/qfileopenevent/test/CMakeLists.txt
new file mode 100644
index 0000000000..6695ef42b3
--- /dev/null
+++ b/tests/auto/gui/kernel/qfileopenevent/test/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qfileopenevent Test:
+#####################################################################
+
+add_qt_test(tst_qfileopenevent
+ SOURCES
+ tst_qfileopenevent.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qguiapplication/.prev_CMakeLists.txt b/tests/auto/gui/kernel/qguiapplication/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..1874a33794
--- /dev/null
+++ b/tests/auto/gui/kernel/qguiapplication/.prev_CMakeLists.txt
@@ -0,0 +1,47 @@
+# Generated from qguiapplication.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qguiapplication Test:
+#####################################################################
+
+add_qt_test(tst_qguiapplication
+ SOURCES
+ tst_qcoreapplication.cpp tst_qcoreapplication.h
+ tst_qguiapplication.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0x050E00
+ INCLUDE_DIRECTORIES
+ ../../../corelib/kernel/qcoreapplication
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set(tst_qguiapplication_resource_files
+ "icons/appicon.png"
+ "icons/usericon.png"
+)
+
+add_qt_resource(tst_qguiapplication "tst_qguiapplication"
+ PREFIX
+ "/"
+ FILES
+ ${tst_qguiapplication_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:../../../corelib/kernel/qcoreapplication:../../../corelib/kernel/qcoreapplication/qcoreapplication.pro:WIN32:
+# VERSION = "1.2.3.4"
+
+#### Keys ignored in scope 4:.:../../../corelib/kernel/qcoreapplication:../../../corelib/kernel/qcoreapplication/qcoreapplication.pro:else:
+# VERSION = "1.2.3"
diff --git a/tests/auto/gui/kernel/qguiapplication/CMakeLists.txt b/tests/auto/gui/kernel/qguiapplication/CMakeLists.txt
new file mode 100644
index 0000000000..09498e2a39
--- /dev/null
+++ b/tests/auto/gui/kernel/qguiapplication/CMakeLists.txt
@@ -0,0 +1,48 @@
+# Generated from qguiapplication.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qguiapplication Test:
+#####################################################################
+
+add_qt_test(tst_qguiapplication
+ SOURCES
+ ../../../corelib/kernel/qcoreapplication/tst_qcoreapplication.cpp ../../../corelib/kernel/qcoreapplication/tst_qcoreapplication.h # special case
+ tst_qguiapplication.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0x050E00
+ INCLUDE_DIRECTORIES
+ ../../../corelib/kernel/qcoreapplication
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Threads::Threads # special case
+)
+
+# Resources:
+set(tst_qguiapplication_resource_files
+ "icons/appicon.png"
+ "icons/usericon.png"
+)
+
+add_qt_resource(tst_qguiapplication "tst_qguiapplication"
+ PREFIX
+ "/"
+ FILES
+ ${tst_qguiapplication_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:../../../corelib/kernel/qcoreapplication:../../../corelib/kernel/qcoreapplication/qcoreapplication.pro:WIN32:
+# VERSION = "1.2.3.4"
+
+#### Keys ignored in scope 4:.:../../../corelib/kernel/qcoreapplication:../../../corelib/kernel/qcoreapplication/qcoreapplication.pro:else:
+# VERSION = "1.2.3"
diff --git a/tests/auto/gui/kernel/qguieventdispatcher/CMakeLists.txt b/tests/auto/gui/kernel/qguieventdispatcher/CMakeLists.txt
new file mode 100644
index 0000000000..eb36e0ece7
--- /dev/null
+++ b/tests/auto/gui/kernel/qguieventdispatcher/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qguieventdispatcher.pro.
+
+#####################################################################
+## tst_qguieventdispatcher Test:
+#####################################################################
+
+add_qt_test(tst_qguieventdispatcher
+ SOURCES
+ ../../../corelib/kernel/qeventdispatcher/tst_qeventdispatcher.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qguieventloop/.prev_CMakeLists.txt b/tests/auto/gui/kernel/qguieventloop/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..c4daa5a310
--- /dev/null
+++ b/tests/auto/gui/kernel/qguieventloop/.prev_CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from qguieventloop.pro.
+
+#####################################################################
+## tst_qguieventloop Test:
+#####################################################################
+
+add_qt_test(tst_qguieventloop
+ SOURCES
+ ../../../corelib/kernel/qeventloop/tst_qeventloop.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qguieventloop CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ user32
+)
+
+extend_target(tst_qguieventloop CONDITION QT_FEATURE_glib
+ DEFINES
+ HAVE_GLIB
+)
diff --git a/tests/auto/gui/kernel/qguieventloop/CMakeLists.txt b/tests/auto/gui/kernel/qguieventloop/CMakeLists.txt
new file mode 100644
index 0000000000..c4daa5a310
--- /dev/null
+++ b/tests/auto/gui/kernel/qguieventloop/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from qguieventloop.pro.
+
+#####################################################################
+## tst_qguieventloop Test:
+#####################################################################
+
+add_qt_test(tst_qguieventloop
+ SOURCES
+ ../../../corelib/kernel/qeventloop/tst_qeventloop.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qguieventloop CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ user32
+)
+
+extend_target(tst_qguieventloop CONDITION QT_FEATURE_glib
+ DEFINES
+ HAVE_GLIB
+)
diff --git a/tests/auto/gui/kernel/qguimetatype/CMakeLists.txt b/tests/auto/gui/kernel/qguimetatype/CMakeLists.txt
new file mode 100644
index 0000000000..3701b3983a
--- /dev/null
+++ b/tests/auto/gui/kernel/qguimetatype/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qguimetatype.pro.
+
+#####################################################################
+## tst_qguimetatype Test:
+#####################################################################
+
+add_qt_test(tst_qguimetatype
+ SOURCES
+ tst_qguimetatype.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qguitimer/.prev_CMakeLists.txt b/tests/auto/gui/kernel/qguitimer/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..6d0f3cbbee
--- /dev/null
+++ b/tests/auto/gui/kernel/qguitimer/.prev_CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qguitimer.pro.
+
+#####################################################################
+## tst_qguitimer Test:
+#####################################################################
+
+add_qt_test(tst_qguitimer
+ SOURCES
+ ../../../corelib/kernel/qtimer/tst_qtimer.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qguitimer/CMakeLists.txt b/tests/auto/gui/kernel/qguitimer/CMakeLists.txt
new file mode 100644
index 0000000000..5f255d49e4
--- /dev/null
+++ b/tests/auto/gui/kernel/qguitimer/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qguitimer.pro.
+
+#####################################################################
+## tst_qguitimer Test:
+#####################################################################
+
+add_qt_test(tst_qguitimer
+ SOURCES
+ ../../../corelib/kernel/qtimer/tst_qtimer.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Threads::Threads # special case
+)
diff --git a/tests/auto/gui/kernel/qguivariant/CMakeLists.txt b/tests/auto/gui/kernel/qguivariant/CMakeLists.txt
new file mode 100644
index 0000000000..3a0adab6e3
--- /dev/null
+++ b/tests/auto/gui/kernel/qguivariant/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from qguivariant.pro.
+
+add_subdirectory(test)
+add_subdirectory(no_application)
diff --git a/tests/auto/gui/kernel/qguivariant/no_application/CMakeLists.txt b/tests/auto/gui/kernel/qguivariant/no_application/CMakeLists.txt
new file mode 100644
index 0000000000..8261212801
--- /dev/null
+++ b/tests/auto/gui/kernel/qguivariant/no_application/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from no_application.pro.
+
+#####################################################################
+## no_application Test:
+#####################################################################
+
+add_qt_test(no_application
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qguivariant/test/CMakeLists.txt b/tests/auto/gui/kernel/qguivariant/test/CMakeLists.txt
new file mode 100644
index 0000000000..af2cea60e6
--- /dev/null
+++ b/tests/auto/gui/kernel/qguivariant/test/CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qguivariant Test:
+#####################################################################
+
+add_qt_test(tst_qguivariant
+ SOURCES
+ tst_qguivariant.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../other/qvariant_common
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set(tst_qguivariant_resource_files
+ "black.png"
+ "black2.png"
+)
+
+add_qt_resource(tst_qguivariant "tst_qguivariant"
+ PREFIX
+ "/"
+ FILES
+ ${tst_qguivariant_resource_files}
+)
+set(qguivariant_resource_files
+ "data"
+)
+
+add_qt_resource(tst_qguivariant "qguivariant"
+ PREFIX
+ "/"
+ FILES
+ ${qguivariant_resource_files}
+)
+
diff --git a/tests/auto/gui/kernel/qinputmethod/CMakeLists.txt b/tests/auto/gui/kernel/qinputmethod/CMakeLists.txt
new file mode 100644
index 0000000000..f0f09818e5
--- /dev/null
+++ b/tests/auto/gui/kernel/qinputmethod/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qinputmethod.pro.
+
+#####################################################################
+## tst_qinputmethod Test:
+#####################################################################
+
+add_qt_test(tst_qinputmethod
+ SOURCES
+ tst_qinputmethod.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qkeyevent/CMakeLists.txt b/tests/auto/gui/kernel/qkeyevent/CMakeLists.txt
new file mode 100644
index 0000000000..2e36795375
--- /dev/null
+++ b/tests/auto/gui/kernel/qkeyevent/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qkeyevent.pro.
+
+#####################################################################
+## tst_qkeyevent Test:
+#####################################################################
+
+add_qt_test(tst_qkeyevent
+ SOURCES
+ tst_qkeyevent.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qkeysequence/CMakeLists.txt b/tests/auto/gui/kernel/qkeysequence/CMakeLists.txt
new file mode 100644
index 0000000000..01f03fac76
--- /dev/null
+++ b/tests/auto/gui/kernel/qkeysequence/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from qkeysequence.pro.
+
+#####################################################################
+## tst_qkeysequence Test:
+#####################################################################
+
+add_qt_test(tst_qkeysequence
+ SOURCES
+ tst_qkeysequence.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set(qkeysequence_resource_files
+ "keys_de.qm"
+ "qt_de.qm"
+)
+
+add_qt_resource(tst_qkeysequence "qkeysequence"
+ PREFIX
+ "/"
+ FILES
+ ${qkeysequence_resource_files}
+)
+
diff --git a/tests/auto/gui/kernel/qmouseevent/CMakeLists.txt b/tests/auto/gui/kernel/qmouseevent/CMakeLists.txt
new file mode 100644
index 0000000000..4e1081c6ad
--- /dev/null
+++ b/tests/auto/gui/kernel/qmouseevent/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qmouseevent.pro.
+
+#####################################################################
+## tst_qmouseevent Test:
+#####################################################################
+
+add_qt_test(tst_qmouseevent
+ SOURCES
+ tst_qmouseevent.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qmouseevent_modal/CMakeLists.txt b/tests/auto/gui/kernel/qmouseevent_modal/CMakeLists.txt
new file mode 100644
index 0000000000..c7f447ffeb
--- /dev/null
+++ b/tests/auto/gui/kernel/qmouseevent_modal/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qmouseevent_modal.pro.
+
+#####################################################################
+## tst_qmouseevent_modal Test:
+#####################################################################
+
+add_qt_test(tst_qmouseevent_modal
+ SOURCES
+ tst_qmouseevent_modal.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/gui/kernel/qopenglwindow/CMakeLists.txt b/tests/auto/gui/kernel/qopenglwindow/CMakeLists.txt
new file mode 100644
index 0000000000..1915f28a18
--- /dev/null
+++ b/tests/auto/gui/kernel/qopenglwindow/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qopenglwindow.pro.
+
+#####################################################################
+## tst_qopenglwindow Test:
+#####################################################################
+
+add_qt_test(tst_qopenglwindow
+ SOURCES
+ tst_qopenglwindow.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qpalette/CMakeLists.txt b/tests/auto/gui/kernel/qpalette/CMakeLists.txt
new file mode 100644
index 0000000000..4bd2ce7cc5
--- /dev/null
+++ b/tests/auto/gui/kernel/qpalette/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qpalette.pro.
+
+#####################################################################
+## tst_qpalette Test:
+#####################################################################
+
+add_qt_test(tst_qpalette
+ SOURCES
+ tst_qpalette.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qpixelformat/CMakeLists.txt b/tests/auto/gui/kernel/qpixelformat/CMakeLists.txt
new file mode 100644
index 0000000000..43deb02af1
--- /dev/null
+++ b/tests/auto/gui/kernel/qpixelformat/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qpixelformat.pro.
+
+#####################################################################
+## tst_qpixelformat Test:
+#####################################################################
+
+add_qt_test(tst_qpixelformat
+ SOURCES
+ tst_qpixelformat.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qrasterwindow/CMakeLists.txt b/tests/auto/gui/kernel/qrasterwindow/CMakeLists.txt
new file mode 100644
index 0000000000..61e1be44fd
--- /dev/null
+++ b/tests/auto/gui/kernel/qrasterwindow/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qrasterwindow.pro.
+
+#####################################################################
+## tst_qrasterwindow Test:
+#####################################################################
+
+add_qt_test(tst_qrasterwindow
+ SOURCES
+ tst_qrasterwindow.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qscreen/CMakeLists.txt b/tests/auto/gui/kernel/qscreen/CMakeLists.txt
new file mode 100644
index 0000000000..2e2a04f969
--- /dev/null
+++ b/tests/auto/gui/kernel/qscreen/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qscreen.pro.
+
+#####################################################################
+## tst_qscreen Test:
+#####################################################################
+
+add_qt_test(tst_qscreen
+ SOURCES
+ tst_qscreen.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qsurfaceformat/CMakeLists.txt b/tests/auto/gui/kernel/qsurfaceformat/CMakeLists.txt
new file mode 100644
index 0000000000..148ab2be8d
--- /dev/null
+++ b/tests/auto/gui/kernel/qsurfaceformat/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qsurfaceformat.pro.
+
+#####################################################################
+## tst_qsurfaceformat Test:
+#####################################################################
+
+add_qt_test(tst_qsurfaceformat
+ SOURCES
+ tst_qsurfaceformat.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/kernel/qtouchevent/CMakeLists.txt b/tests/auto/gui/kernel/qtouchevent/CMakeLists.txt
new file mode 100644
index 0000000000..2a74918f8a
--- /dev/null
+++ b/tests/auto/gui/kernel/qtouchevent/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtouchevent.pro.
+
+#####################################################################
+## tst_qtouchevent Test:
+#####################################################################
+
+add_qt_test(tst_qtouchevent
+ SOURCES
+ tst_qtouchevent.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/gui/kernel/qwindow/CMakeLists.txt b/tests/auto/gui/kernel/qwindow/CMakeLists.txt
new file mode 100644
index 0000000000..c5a56a5a06
--- /dev/null
+++ b/tests/auto/gui/kernel/qwindow/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from qwindow.pro.
+
+#####################################################################
+## tst_qwindow Test:
+#####################################################################
+
+add_qt_test(tst_qwindow
+ SOURCES
+ tst_qwindow.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qwindow CONDITION QT_FEATURE_dynamicgl AND WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ user32
+)
diff --git a/tests/auto/gui/math3d/CMakeLists.txt b/tests/auto/gui/math3d/CMakeLists.txt
new file mode 100644
index 0000000000..91e59874b7
--- /dev/null
+++ b/tests/auto/gui/math3d/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_subdirectory("qquaternion")
+add_subdirectory("qvectornd")
+add_subdirectory("qmatrixnxn")
diff --git a/tests/auto/gui/math3d/qmatrixnxn/CMakeLists.txt b/tests/auto/gui/math3d/qmatrixnxn/CMakeLists.txt
new file mode 100644
index 0000000000..71daeba361
--- /dev/null
+++ b/tests/auto/gui/math3d/qmatrixnxn/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qmatrixnxn.pro.
+
+#####################################################################
+## tst_qmatrixnxn Test:
+#####################################################################
+
+add_qt_test(tst_qmatrixnxn
+ SOURCES
+ tst_qmatrixnxn.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/math3d/qquaternion/CMakeLists.txt b/tests/auto/gui/math3d/qquaternion/CMakeLists.txt
new file mode 100644
index 0000000000..77d035cbf9
--- /dev/null
+++ b/tests/auto/gui/math3d/qquaternion/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qquaternion.pro.
+
+#####################################################################
+## tst_qquaternion Test:
+#####################################################################
+
+add_qt_test(tst_qquaternion
+ SOURCES
+ tst_qquaternion.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/math3d/qvectornd/CMakeLists.txt b/tests/auto/gui/math3d/qvectornd/CMakeLists.txt
new file mode 100644
index 0000000000..5d8a373234
--- /dev/null
+++ b/tests/auto/gui/math3d/qvectornd/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qvectornd.pro.
+
+#####################################################################
+## tst_qvectornd Test:
+#####################################################################
+
+add_qt_test(tst_qvectornd
+ SOURCES
+ tst_qvectornd.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/painting/CMakeLists.txt b/tests/auto/gui/painting/CMakeLists.txt
new file mode 100644
index 0000000000..e13679e282
--- /dev/null
+++ b/tests/auto/gui/painting/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from painting.pro.
+
+add_subdirectory("qpainterpath")
+add_subdirectory("qpainterpathstroker")
+# add_subdirectory("qcolor")
+# add_subdirectory("qbrush")
+# add_subdirectory("qregion")
+# add_subdirectory("qpagelayout")
+add_subdirectory("qpagesize")
+# add_subdirectory("qpainter")
+if (QT_FEATURE_private_tests)
+ # not converted yet
+ #add_subdirectory("qpathclipper")
+endif()
+# add_subdirectory("qpdfwriter")
+add_subdirectory("qpen")
+add_subdirectory("qpaintengine")
+# add_subdirectory("qtransform")
+# add_subdirectory("qwmatrix")
+# add_subdirectory("qpolygon")
diff --git a/tests/auto/gui/painting/qpagesize/CMakeLists.txt b/tests/auto/gui/painting/qpagesize/CMakeLists.txt
new file mode 100644
index 0000000000..260abfbc0f
--- /dev/null
+++ b/tests/auto/gui/painting/qpagesize/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qpagesize.pro.
+
+#####################################################################
+## tst_qpagesize Test:
+#####################################################################
+
+add_qt_test(tst_qpagesize
+ SOURCES
+ tst_qpagesize.cpp
+ DEFINES
+ QT_USE_USING_NAMESPACE
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/painting/qpaintengine/CMakeLists.txt b/tests/auto/gui/painting/qpaintengine/CMakeLists.txt
new file mode 100644
index 0000000000..8125a98d3e
--- /dev/null
+++ b/tests/auto/gui/painting/qpaintengine/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qpaintengine.pro.
+
+#####################################################################
+## tst_qpaintengine Test:
+#####################################################################
+
+add_qt_test(tst_qpaintengine
+ SOURCES
+ tst_qpaintengine.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/painting/qpainterpath/CMakeLists.txt b/tests/auto/gui/painting/qpainterpath/CMakeLists.txt
new file mode 100644
index 0000000000..c2c88cc258
--- /dev/null
+++ b/tests/auto/gui/painting/qpainterpath/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qpainterpath.pro.
+
+#####################################################################
+## tst_qpainterpath Test:
+#####################################################################
+
+add_qt_test(tst_qpainterpath
+ SOURCES
+ tst_qpainterpath.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/painting/qpainterpathstroker/CMakeLists.txt b/tests/auto/gui/painting/qpainterpathstroker/CMakeLists.txt
new file mode 100644
index 0000000000..a1c5f6547f
--- /dev/null
+++ b/tests/auto/gui/painting/qpainterpathstroker/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qpainterpathstroker.pro.
+
+#####################################################################
+## tst_qpainterpathstroker Test:
+#####################################################################
+
+add_qt_test(tst_qpainterpathstroker
+ SOURCES
+ tst_qpainterpathstroker.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/painting/qpen/CMakeLists.txt b/tests/auto/gui/painting/qpen/CMakeLists.txt
new file mode 100644
index 0000000000..d096f7a6ce
--- /dev/null
+++ b/tests/auto/gui/painting/qpen/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qpen.pro.
+
+#####################################################################
+## tst_qpen Test:
+#####################################################################
+
+add_qt_test(tst_qpen
+ SOURCES
+ tst_qpen.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/qopengl/CMakeLists.txt b/tests/auto/gui/qopengl/CMakeLists.txt
new file mode 100644
index 0000000000..d488c808f9
--- /dev/null
+++ b/tests/auto/gui/qopengl/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from qopengl.pro.
+
+#####################################################################
+## tst_qopengl Test:
+#####################################################################
+
+add_qt_test(tst_qopengl
+ SOURCES
+ tst_qopengl.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qopengl CONDITION LINUX AND QT_FEATURE_xcb AND QT_FEATURE_xcb_glx_plugin
+ DEFINES
+ USE_GLX
+)
diff --git a/tests/auto/gui/qopenglconfig/CMakeLists.txt b/tests/auto/gui/qopenglconfig/CMakeLists.txt
new file mode 100644
index 0000000000..bcac684cf9
--- /dev/null
+++ b/tests/auto/gui/qopenglconfig/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qopenglconfig.pro.
+
+#####################################################################
+## tst_qopenglconfig Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "buglist.json")
+
+add_qt_test(tst_qopenglconfig
+ SOURCES
+ tst_qopenglconfig.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/gui/qvulkan/CMakeLists.txt b/tests/auto/gui/qvulkan/CMakeLists.txt
new file mode 100644
index 0000000000..ad8a9f9e67
--- /dev/null
+++ b/tests/auto/gui/qvulkan/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qvulkan.pro.
+
+#####################################################################
+## tst_qvulkan Test:
+#####################################################################
+
+add_qt_test(tst_qvulkan
+ SOURCES
+ tst_qvulkan.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/rhi/CMakeLists.txt b/tests/auto/gui/rhi/CMakeLists.txt
new file mode 100644
index 0000000000..786e121f00
--- /dev/null
+++ b/tests/auto/gui/rhi/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from rhi.pro.
+
+add_subdirectory(qshader)
+add_subdirectory(qrhi)
diff --git a/tests/auto/gui/rhi/qrhi/CMakeLists.txt b/tests/auto/gui/rhi/qrhi/CMakeLists.txt
new file mode 100644
index 0000000000..27c8a731e7
--- /dev/null
+++ b/tests/auto/gui/rhi/qrhi/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from qrhi.pro.
+
+#####################################################################
+## tst_qrhi Test:
+#####################################################################
+
+add_qt_test(tst_qrhi
+ SOURCES
+ tst_qrhi.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set(qrhi_resource_files
+ "data"
+)
+
+add_qt_resource(tst_qrhi "qrhi"
+ PREFIX
+ "/"
+ FILES
+ ${qrhi_resource_files}
+)
+
diff --git a/tests/auto/gui/rhi/qshader/CMakeLists.txt b/tests/auto/gui/rhi/qshader/CMakeLists.txt
new file mode 100644
index 0000000000..9d9352ef1e
--- /dev/null
+++ b/tests/auto/gui/rhi/qshader/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from qshader.pro.
+
+#####################################################################
+## tst_qshader Test:
+#####################################################################
+
+add_qt_test(tst_qshader
+ SOURCES
+ tst_qshader.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set(qshader_resource_files
+ "data"
+)
+
+add_qt_resource(tst_qshader "qshader"
+ PREFIX
+ "/"
+ FILES
+ ${qshader_resource_files}
+)
+
diff --git a/tests/auto/gui/text/CMakeLists.txt b/tests/auto/gui/text/CMakeLists.txt
new file mode 100644
index 0000000000..8326190831
--- /dev/null
+++ b/tests/auto/gui/text/CMakeLists.txt
@@ -0,0 +1,41 @@
+# Generated from text.pro.
+
+add_subdirectory(qabstracttextdocumentlayout)
+add_subdirectory(qfont)
+add_subdirectory(qfontdatabase)
+add_subdirectory(qfontmetrics)
+add_subdirectory(qglyphrun)
+add_subdirectory(qrawfont)
+add_subdirectory(qstatictext)
+add_subdirectory(qsyntaxhighlighter)
+add_subdirectory(qtextblock)
+add_subdirectory(qtextcursor)
+add_subdirectory(qtextdocumentfragment)
+add_subdirectory(qtextdocumentlayout)
+add_subdirectory(qtextformat)
+add_subdirectory(qtextlist)
+add_subdirectory(qtextobject)
+add_subdirectory(qtextscriptengine)
+add_subdirectory(qtexttable)
+add_subdirectory(qinputcontrol)
+if(QT_FEATURE_private_tests AND TARGET Qt::Xml)
+ add_subdirectory(qcssparser)
+endif()
+if(QT_FEATURE_private_tests)
+ add_subdirectory(qfontcache)
+ add_subdirectory(qtextlayout)
+ add_subdirectory(qzip)
+ add_subdirectory(qtextodfwriter)
+endif()
+if(TARGET Qt::Xml)
+ add_subdirectory(qtextdocument)
+endif()
+if(QT_FEATURE_private_tests AND UNIX)
+ add_subdirectory(qtextpiecetable)
+endif()
+if(QT_FEATURE_textmarkdownreader)
+ add_subdirectory(qtextmarkdownimporter)
+endif()
+if(QT_FEATURE_private_tests AND QT_FEATURE_textmarkdownwriter)
+ add_subdirectory(qtextmarkdownwriter)
+endif()
diff --git a/tests/auto/gui/text/qabstracttextdocumentlayout/CMakeLists.txt b/tests/auto/gui/text/qabstracttextdocumentlayout/CMakeLists.txt
new file mode 100644
index 0000000000..62d4ce9d32
--- /dev/null
+++ b/tests/auto/gui/text/qabstracttextdocumentlayout/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qabstracttextdocumentlayout.pro.
+
+#####################################################################
+## tst_qabstracttextdocumentlayout Test:
+#####################################################################
+
+add_qt_test(tst_qabstracttextdocumentlayout
+ SOURCES
+ tst_qabstracttextdocumentlayout.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/text/qcssparser/CMakeLists.txt b/tests/auto/gui/text/qcssparser/CMakeLists.txt
new file mode 100644
index 0000000000..869eebbf95
--- /dev/null
+++ b/tests/auto/gui/text/qcssparser/CMakeLists.txt
@@ -0,0 +1,58 @@
+# Generated from qcssparser.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qcssparser Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "testdata")
+
+add_qt_test(tst_qcssparser
+ SOURCES
+ tst_qcssparser.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}\\\"
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Xml
+ TESTDATA ${test_data}
+)
+
+#### Keys ignored in scope 1:.:.:qcssparser.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
+
+## Scopes:
+#####################################################################
+
+if(ANDROID)
+ # Resources:
+ set(testdata_resource_files
+ "testdata/scanner/comments/input"
+ "testdata/scanner/comments/output"
+ "testdata/scanner/comments2/input"
+ "testdata/scanner/comments2/output"
+ "testdata/scanner/comments3/input"
+ "testdata/scanner/comments3/output"
+ "testdata/scanner/comments4/input"
+ "testdata/scanner/comments4/output"
+ "testdata/scanner/quotedstring/input"
+ "testdata/scanner/quotedstring/output"
+ "testdata/scanner/simple/input"
+ "testdata/scanner/simple/output"
+ "testdata/scanner/unicode/input"
+ "testdata/scanner/unicode/output"
+ )
+
+ add_qt_resource(tst_qcssparser "testdata"
+ PREFIX
+ "/"
+ FILES
+ ${testdata_resource_files}
+ )
+endif()
diff --git a/tests/auto/gui/text/qfont/CMakeLists.txt b/tests/auto/gui/text/qfont/CMakeLists.txt
new file mode 100644
index 0000000000..1f063ab8b2
--- /dev/null
+++ b/tests/auto/gui/text/qfont/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from qfont.pro.
+
+#####################################################################
+## tst_qfont Test:
+#####################################################################
+
+add_qt_test(tst_qfont
+ SOURCES
+ tst_qfont.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set(testfont_resource_files
+ "weirdfont.otf"
+)
+
+add_qt_resource(tst_qfont "testfont"
+ PREFIX
+ "/"
+ FILES
+ ${testfont_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qfont CONDITION TARGET Qt::Widgets
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
diff --git a/tests/auto/gui/text/qfontcache/CMakeLists.txt b/tests/auto/gui/text/qfontcache/CMakeLists.txt
new file mode 100644
index 0000000000..dc5e76c91d
--- /dev/null
+++ b/tests/auto/gui/text/qfontcache/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qfontcache.pro.
+
+#####################################################################
+## tst_qfontcache Test:
+#####################################################################
+
+add_qt_test(tst_qfontcache
+ SOURCES
+ tst_qfontcache.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/text/qfontdatabase/CMakeLists.txt b/tests/auto/gui/text/qfontdatabase/CMakeLists.txt
new file mode 100644
index 0000000000..641a2475f0
--- /dev/null
+++ b/tests/auto/gui/text/qfontdatabase/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from qfontdatabase.pro.
+
+#####################################################################
+## tst_qfontdatabase Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "LED_REAL.TTF")
+
+add_qt_test(tst_qfontdatabase
+ SOURCES
+ tst_qfontdatabase.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
+
+# Resources:
+set_source_files_properties("../../../shared/resources/testfont.ttf"
+ PROPERTIES QT_RESOURCE_ALIAS "testfont.ttf"
+)
+set_source_files_properties("../../../shared/resources/testfont_condensed.ttf"
+ PROPERTIES QT_RESOURCE_ALIAS "testfont_condensed.ttf"
+)
+set_source_files_properties("../../../shared/resources/testfont_italic.ttf"
+ PROPERTIES QT_RESOURCE_ALIAS "testfont_italic.ttf"
+)
+set(testdata_resource_files
+ "../../../shared/resources/testfont.ttf"
+ "../../../shared/resources/testfont_condensed.ttf"
+ "../../../shared/resources/testfont_italic.ttf"
+ "LED_REAL.TTF"
+)
+
+add_qt_resource(tst_qfontdatabase "testdata"
+ PREFIX
+ "/"
+ FILES
+ ${testdata_resource_files}
+)
+
diff --git a/tests/auto/gui/text/qfontmetrics/CMakeLists.txt b/tests/auto/gui/text/qfontmetrics/CMakeLists.txt
new file mode 100644
index 0000000000..10ba5dd791
--- /dev/null
+++ b/tests/auto/gui/text/qfontmetrics/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from qfontmetrics.pro.
+
+#####################################################################
+## tst_qfontmetrics Test:
+#####################################################################
+
+add_qt_test(tst_qfontmetrics
+ SOURCES
+ tst_qfontmetrics.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../../../shared/resources/testfont.ttf"
+ PROPERTIES QT_RESOURCE_ALIAS "testfont.ttf"
+)
+set(testfont_resource_files
+ "../../../shared/resources/testfont.ttf"
+ "ucs4font.ttf"
+)
+
+add_qt_resource(tst_qfontmetrics "testfont"
+ PREFIX
+ "/fonts"
+ FILES
+ ${testfont_resource_files}
+)
+
diff --git a/tests/auto/gui/text/qglyphrun/CMakeLists.txt b/tests/auto/gui/text/qglyphrun/CMakeLists.txt
new file mode 100644
index 0000000000..8efcfc0cf9
--- /dev/null
+++ b/tests/auto/gui/text/qglyphrun/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from qglyphrun.pro.
+
+#####################################################################
+## tst_qglyphrun Test:
+#####################################################################
+
+add_qt_test(tst_qglyphrun
+ SOURCES
+ tst_qglyphrun.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../../../shared/resources/test.ttf"
+ PROPERTIES QT_RESOURCE_ALIAS "test.ttf"
+)
+set(testdata_resource_files
+ "../../../shared/resources/test.ttf"
+)
+
+add_qt_resource(tst_qglyphrun "testdata"
+ PREFIX
+ "/"
+ FILES
+ ${testdata_resource_files}
+)
+
diff --git a/tests/auto/gui/text/qinputcontrol/CMakeLists.txt b/tests/auto/gui/text/qinputcontrol/CMakeLists.txt
new file mode 100644
index 0000000000..8c379bffc3
--- /dev/null
+++ b/tests/auto/gui/text/qinputcontrol/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qinputcontrol.pro.
+
+#####################################################################
+## tst_qinputcontrol Test:
+#####################################################################
+
+add_qt_test(tst_qinputcontrol
+ SOURCES
+ tst_qinputcontrol.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/text/qrawfont/CMakeLists.txt b/tests/auto/gui/text/qrawfont/CMakeLists.txt
new file mode 100644
index 0000000000..41093ee603
--- /dev/null
+++ b/tests/auto/gui/text/qrawfont/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from qrawfont.pro.
+
+#####################################################################
+## tst_qrawfont Test:
+#####################################################################
+
+add_qt_test(tst_qrawfont
+ SOURCES
+ tst_qrawfont.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../../../shared/resources/testfont.ttf"
+ PROPERTIES QT_RESOURCE_ALIAS "testfont.ttf"
+)
+set(testdata_resource_files
+ "../../../shared/resources/testfont.ttf"
+ "testfont_bold_italic.ttf"
+ "testfont_os2_v1.ttf"
+)
+
+add_qt_resource(tst_qrawfont "testdata"
+ PREFIX
+ "/"
+ FILES
+ ${testdata_resource_files}
+)
+
diff --git a/tests/auto/gui/text/qstatictext/CMakeLists.txt b/tests/auto/gui/text/qstatictext/CMakeLists.txt
new file mode 100644
index 0000000000..c2b53e731c
--- /dev/null
+++ b/tests/auto/gui/text/qstatictext/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from qstatictext.pro.
+
+#####################################################################
+## tst_qstatictext Test:
+#####################################################################
+
+add_qt_test(tst_qstatictext
+ SOURCES
+ tst_qstatictext.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qstatictext CONDITION QT_FEATURE_private_tests
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Gui
+)
diff --git a/tests/auto/gui/text/qsyntaxhighlighter/CMakeLists.txt b/tests/auto/gui/text/qsyntaxhighlighter/CMakeLists.txt
new file mode 100644
index 0000000000..c4ea8b4a1e
--- /dev/null
+++ b/tests/auto/gui/text/qsyntaxhighlighter/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qsyntaxhighlighter.pro.
+
+#####################################################################
+## tst_qsyntaxhighlighter Test:
+#####################################################################
+
+add_qt_test(tst_qsyntaxhighlighter
+ SOURCES
+ tst_qsyntaxhighlighter.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qsyntaxhighlighter CONDITION TARGET Qt::Widgets
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
diff --git a/tests/auto/gui/text/qtextblock/CMakeLists.txt b/tests/auto/gui/text/qtextblock/CMakeLists.txt
new file mode 100644
index 0000000000..ca461a37d5
--- /dev/null
+++ b/tests/auto/gui/text/qtextblock/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtextblock.pro.
+
+#####################################################################
+## tst_qtextblock Test:
+#####################################################################
+
+add_qt_test(tst_qtextblock
+ SOURCES
+ tst_qtextblock.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/text/qtextcursor/CMakeLists.txt b/tests/auto/gui/text/qtextcursor/CMakeLists.txt
new file mode 100644
index 0000000000..2e129d0262
--- /dev/null
+++ b/tests/auto/gui/text/qtextcursor/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtextcursor.pro.
+
+#####################################################################
+## tst_qtextcursor Test:
+#####################################################################
+
+add_qt_test(tst_qtextcursor
+ SOURCES
+ tst_qtextcursor.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/text/qtextdocument/CMakeLists.txt b/tests/auto/gui/text/qtextdocument/CMakeLists.txt
new file mode 100644
index 0000000000..5ac40ee8b6
--- /dev/null
+++ b/tests/auto/gui/text/qtextdocument/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qtextdocument.pro.
+
+#####################################################################
+## tst_qtextdocument Test:
+#####################################################################
+
+add_qt_test(tst_qtextdocument
+ SOURCES
+ common.h
+ tst_qtextdocument.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Xml
+)
diff --git a/tests/auto/gui/text/qtextdocumentfragment/CMakeLists.txt b/tests/auto/gui/text/qtextdocumentfragment/CMakeLists.txt
new file mode 100644
index 0000000000..09469b7c7f
--- /dev/null
+++ b/tests/auto/gui/text/qtextdocumentfragment/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtextdocumentfragment.pro.
+
+#####################################################################
+## tst_qtextdocumentfragment Test:
+#####################################################################
+
+add_qt_test(tst_qtextdocumentfragment
+ SOURCES
+ tst_qtextdocumentfragment.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/text/qtextdocumentlayout/CMakeLists.txt b/tests/auto/gui/text/qtextdocumentlayout/CMakeLists.txt
new file mode 100644
index 0000000000..c7212209ee
--- /dev/null
+++ b/tests/auto/gui/text/qtextdocumentlayout/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qtextdocumentlayout.pro.
+
+#####################################################################
+## tst_qtextdocumentlayout Test:
+#####################################################################
+
+add_qt_test(tst_qtextdocumentlayout
+ SOURCES
+ tst_qtextdocumentlayout.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qtextdocumentlayout CONDITION TARGET Qt::Widgets
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
diff --git a/tests/auto/gui/text/qtextformat/CMakeLists.txt b/tests/auto/gui/text/qtextformat/CMakeLists.txt
new file mode 100644
index 0000000000..5635141476
--- /dev/null
+++ b/tests/auto/gui/text/qtextformat/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtextformat.pro.
+
+#####################################################################
+## tst_qtextformat Test:
+#####################################################################
+
+add_qt_test(tst_qtextformat
+ SOURCES
+ tst_qtextformat.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/text/qtextlayout/CMakeLists.txt b/tests/auto/gui/text/qtextlayout/CMakeLists.txt
new file mode 100644
index 0000000000..b43c009b99
--- /dev/null
+++ b/tests/auto/gui/text/qtextlayout/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtextlayout.pro.
+
+#####################################################################
+## tst_qtextlayout Test:
+#####################################################################
+
+add_qt_test(tst_qtextlayout
+ SOURCES
+ tst_qtextlayout.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/text/qtextlist/CMakeLists.txt b/tests/auto/gui/text/qtextlist/CMakeLists.txt
new file mode 100644
index 0000000000..80e4623ce5
--- /dev/null
+++ b/tests/auto/gui/text/qtextlist/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qtextlist.pro.
+
+#####################################################################
+## tst_qtextlist Test:
+#####################################################################
+
+add_qt_test(tst_qtextlist
+ SOURCES
+ ../qtextdocument/common.h
+ tst_qtextlist.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/text/qtextmarkdownimporter/CMakeLists.txt b/tests/auto/gui/text/qtextmarkdownimporter/CMakeLists.txt
new file mode 100644
index 0000000000..4e1f54a117
--- /dev/null
+++ b/tests/auto/gui/text/qtextmarkdownimporter/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from qtextmarkdownimporter.pro.
+
+#####################################################################
+## tst_qtextmarkdownimporter Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "data/thematicBreaks.md")
+list(APPEND test_data "data/headingBulletsContinuations.md")
+
+add_qt_test(tst_qtextmarkdownimporter
+ SOURCES
+ tst_qtextmarkdownimporter.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}\\\"
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/gui/text/qtextmarkdownwriter/CMakeLists.txt b/tests/auto/gui/text/qtextmarkdownwriter/CMakeLists.txt
new file mode 100644
index 0000000000..c7695bff97
--- /dev/null
+++ b/tests/auto/gui/text/qtextmarkdownwriter/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from qtextmarkdownwriter.pro.
+
+#####################################################################
+## tst_qtextmarkdownwriter Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "data/example.md")
+list(APPEND test_data "data/blockquotes.md")
+
+add_qt_test(tst_qtextmarkdownwriter
+ SOURCES
+ tst_qtextmarkdownwriter.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}\\\"
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/gui/text/qtextobject/CMakeLists.txt b/tests/auto/gui/text/qtextobject/CMakeLists.txt
new file mode 100644
index 0000000000..b8d7f7b548
--- /dev/null
+++ b/tests/auto/gui/text/qtextobject/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qtextobject.pro.
+
+#####################################################################
+## tst_qtextobject Test:
+#####################################################################
+
+add_qt_test(tst_qtextobject
+ SOURCES
+ tst_qtextobject.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qtextobject CONDITION TARGET Qt::Widgets
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
diff --git a/tests/auto/gui/text/qtextodfwriter/CMakeLists.txt b/tests/auto/gui/text/qtextodfwriter/CMakeLists.txt
new file mode 100644
index 0000000000..f21648cfc7
--- /dev/null
+++ b/tests/auto/gui/text/qtextodfwriter/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qtextodfwriter.pro.
+
+#####################################################################
+## tst_qtextodfwriter Test:
+#####################################################################
+
+add_qt_test(tst_qtextodfwriter
+ SOURCES
+ tst_qtextodfwriter.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}\\\"
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/text/qtextpiecetable/CMakeLists.txt b/tests/auto/gui/text/qtextpiecetable/CMakeLists.txt
new file mode 100644
index 0000000000..a1caa47e4e
--- /dev/null
+++ b/tests/auto/gui/text/qtextpiecetable/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from qtextpiecetable.pro.
+
+if(WIN32)
+ return()
+endif()
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qtextpiecetable Test:
+#####################################################################
+
+add_qt_test(tst_qtextpiecetable
+ SOURCES
+ ../qtextdocument/common.h
+ tst_qtextpiecetable.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:qtextpiecetable.pro:<TRUE>:
+# _REQUIREMENTS = "!win32" "qtConfig(private_tests)"
diff --git a/tests/auto/gui/text/qtextscriptengine/CMakeLists.txt b/tests/auto/gui/text/qtextscriptengine/CMakeLists.txt
new file mode 100644
index 0000000000..1a3b8cfa92
--- /dev/null
+++ b/tests/auto/gui/text/qtextscriptengine/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtextscriptengine.pro.
+
+#####################################################################
+## tst_qtextscriptengine Test:
+#####################################################################
+
+add_qt_test(tst_qtextscriptengine
+ SOURCES
+ tst_qtextscriptengine.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/text/qtextscriptengine/generate/CMakeLists.txt b/tests/auto/gui/text/qtextscriptengine/generate/CMakeLists.txt
new file mode 100644
index 0000000000..bdda60149c
--- /dev/null
+++ b/tests/auto/gui/text/qtextscriptengine/generate/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from generate.pro.
+
+#####################################################################
+## generate Binary:
+#####################################################################
+
+add_qt_executable(generate
+ GUI
+ SOURCES
+ main.cpp
+ INCLUDE_DIRECTORIES
+ .
+ /usr/include/freetype2
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/text/qtexttable/CMakeLists.txt b/tests/auto/gui/text/qtexttable/CMakeLists.txt
new file mode 100644
index 0000000000..219a868953
--- /dev/null
+++ b/tests/auto/gui/text/qtexttable/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from qtexttable.pro.
+
+#####################################################################
+## tst_qtexttable Test:
+#####################################################################
+
+add_qt_test(tst_qtexttable
+ SOURCES
+ tst_qtexttable.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qtexttable CONDITION TARGET Qt::Widgets
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
diff --git a/tests/auto/gui/text/qzip/CMakeLists.txt b/tests/auto/gui/text/qzip/CMakeLists.txt
new file mode 100644
index 0000000000..034e52e1fd
--- /dev/null
+++ b/tests/auto/gui/text/qzip/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from qzip.pro.
+
+#####################################################################
+## tst_qzip Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "testdata")
+
+add_qt_test(tst_qzip
+ SOURCES
+ tst_qzip.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+if(ANDROID)
+ # Resources:
+ set(testdata_resource_files
+ "testdata/symlink.zip"
+ "testdata/test.zip"
+ )
+
+ add_qt_resource(tst_qzip "testdata"
+ PREFIX
+ "/"
+ FILES
+ ${testdata_resource_files}
+ )
+endif()
diff --git a/tests/auto/gui/util/CMakeLists.txt b/tests/auto/gui/util/CMakeLists.txt
new file mode 100644
index 0000000000..4e0a6b7e25
--- /dev/null
+++ b/tests/auto/gui/util/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from util.pro.
+
+add_subdirectory(qdesktopservices)
+add_subdirectory(qdoublevalidator)
+add_subdirectory(qintvalidator)
+add_subdirectory(qregexpvalidator)
+add_subdirectory(qregularexpressionvalidator)
+add_subdirectory(qshadergenerator)
+add_subdirectory(qshadergraph)
+add_subdirectory(qshadergraphloader)
+add_subdirectory(qshadernodes)
+add_subdirectory(qshadernodesloader)
+add_subdirectory(qtexturefilereader)
diff --git a/tests/auto/gui/util/qdesktopservices/.prev_CMakeLists.txt b/tests/auto/gui/util/qdesktopservices/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..8163ec80b6
--- /dev/null
+++ b/tests/auto/gui/util/qdesktopservices/.prev_CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qdesktopservices.pro.
+
+#####################################################################
+## tst_qdesktopservices Test:
+#####################################################################
+
+add_qt_test(tst_qdesktopservices
+ SOURCES
+ tst_qdesktopservices.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/util/qdesktopservices/CMakeLists.txt b/tests/auto/gui/util/qdesktopservices/CMakeLists.txt
new file mode 100644
index 0000000000..c62cecac30
--- /dev/null
+++ b/tests/auto/gui/util/qdesktopservices/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qdesktopservices.pro.
+
+#####################################################################
+## tst_qdesktopservices Test:
+#####################################################################
+
+add_qt_test(tst_qdesktopservices
+ SOURCES
+ tst_qdesktopservices.cpp
+ DEFINES
+ # QT_DISABLE_DEPRECATED_BEFORE=0 # special case
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/util/qdoublevalidator/CMakeLists.txt b/tests/auto/gui/util/qdoublevalidator/CMakeLists.txt
new file mode 100644
index 0000000000..6cccd082a9
--- /dev/null
+++ b/tests/auto/gui/util/qdoublevalidator/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdoublevalidator.pro.
+
+#####################################################################
+## tst_qdoublevalidator Test:
+#####################################################################
+
+add_qt_test(tst_qdoublevalidator
+ SOURCES
+ tst_qdoublevalidator.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/util/qintvalidator/CMakeLists.txt b/tests/auto/gui/util/qintvalidator/CMakeLists.txt
new file mode 100644
index 0000000000..69a5503d8e
--- /dev/null
+++ b/tests/auto/gui/util/qintvalidator/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qintvalidator.pro.
+
+#####################################################################
+## tst_qintvalidator Test:
+#####################################################################
+
+add_qt_test(tst_qintvalidator
+ SOURCES
+ tst_qintvalidator.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/util/qregexpvalidator/CMakeLists.txt b/tests/auto/gui/util/qregexpvalidator/CMakeLists.txt
new file mode 100644
index 0000000000..4f7d7da0c2
--- /dev/null
+++ b/tests/auto/gui/util/qregexpvalidator/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qregexpvalidator.pro.
+
+#####################################################################
+## tst_qregexpvalidator Test:
+#####################################################################
+
+add_qt_test(tst_qregexpvalidator
+ SOURCES
+ tst_qregexpvalidator.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/util/qregularexpressionvalidator/CMakeLists.txt b/tests/auto/gui/util/qregularexpressionvalidator/CMakeLists.txt
new file mode 100644
index 0000000000..8633a171e5
--- /dev/null
+++ b/tests/auto/gui/util/qregularexpressionvalidator/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qregularexpressionvalidator.pro.
+
+#####################################################################
+## tst_qregularexpressionvalidator Test:
+#####################################################################
+
+add_qt_test(tst_qregularexpressionvalidator
+ SOURCES
+ tst_qregularexpressionvalidator.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/util/qshadergenerator/CMakeLists.txt b/tests/auto/gui/util/qshadergenerator/CMakeLists.txt
new file mode 100644
index 0000000000..a12cabbf84
--- /dev/null
+++ b/tests/auto/gui/util/qshadergenerator/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qshadergenerator.pro.
+
+#####################################################################
+## tst_qshadergenerator Test:
+#####################################################################
+
+add_qt_test(tst_qshadergenerator
+ SOURCES
+ tst_qshadergenerator.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/util/qshadergraph/CMakeLists.txt b/tests/auto/gui/util/qshadergraph/CMakeLists.txt
new file mode 100644
index 0000000000..0e5eef8dd5
--- /dev/null
+++ b/tests/auto/gui/util/qshadergraph/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qshadergraph.pro.
+
+#####################################################################
+## tst_qshadergraph Test:
+#####################################################################
+
+add_qt_test(tst_qshadergraph
+ SOURCES
+ tst_qshadergraph.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/util/qshadergraphloader/CMakeLists.txt b/tests/auto/gui/util/qshadergraphloader/CMakeLists.txt
new file mode 100644
index 0000000000..683df0029f
--- /dev/null
+++ b/tests/auto/gui/util/qshadergraphloader/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qshadergraphloader.pro.
+
+#####################################################################
+## tst_qshadergraphloader Test:
+#####################################################################
+
+add_qt_test(tst_qshadergraphloader
+ SOURCES
+ tst_qshadergraphloader.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/util/qshadernodes/CMakeLists.txt b/tests/auto/gui/util/qshadernodes/CMakeLists.txt
new file mode 100644
index 0000000000..e70c36e8f8
--- /dev/null
+++ b/tests/auto/gui/util/qshadernodes/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qshadernodes.pro.
+
+#####################################################################
+## tst_qshadernodes Test:
+#####################################################################
+
+add_qt_test(tst_qshadernodes
+ SOURCES
+ tst_qshadernodes.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/util/qshadernodesloader/CMakeLists.txt b/tests/auto/gui/util/qshadernodesloader/CMakeLists.txt
new file mode 100644
index 0000000000..226eac25a3
--- /dev/null
+++ b/tests/auto/gui/util/qshadernodesloader/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qshadernodesloader.pro.
+
+#####################################################################
+## tst_qshadernodesloader Test:
+#####################################################################
+
+add_qt_test(tst_qshadernodesloader
+ SOURCES
+ tst_qshadernodesloader.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/gui/util/qtexturefilereader/CMakeLists.txt b/tests/auto/gui/util/qtexturefilereader/CMakeLists.txt
new file mode 100644
index 0000000000..abb48884d3
--- /dev/null
+++ b/tests/auto/gui/util/qtexturefilereader/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from qtexturefilereader.pro.
+
+#####################################################################
+## tst_qtexturefilereader Test:
+#####################################################################
+
+add_qt_test(tst_qtexturefilereader
+ SOURCES
+ tst_qtexturefilereader.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set(qtexturefilereader_resource_files
+ "texturefiles/car.ktx"
+ "texturefiles/car_mips.ktx"
+ "texturefiles/newlogo.astc"
+ "texturefiles/newlogo_srgb.astc"
+ "texturefiles/pattern.pkm"
+)
+
+add_qt_resource(tst_qtexturefilereader "qtexturefilereader"
+ PREFIX
+ "/"
+ FILES
+ ${qtexturefilereader_resource_files}
+)
+
diff --git a/tests/auto/network/CMakeLists.txt b/tests/auto/network/CMakeLists.txt
new file mode 100644
index 0000000000..b7ba3de688
--- /dev/null
+++ b/tests/auto/network/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from network.pro.
+# special case begin
+# SSL library include path is not propagated with private tests which results in
+# test not being able to find the ssl header when they are not in the standard
+# include paths
+if (QT_FEATURE_private_tests)
+ if (QT_FEATURE_openssl AND QT_FEATURE_openssl_linked AND QT_FEATURE_ssl)
+ include_directories($<TARGET_PROPERTY:OpenSSL::SSL,INTERFACE_INCLUDE_DIRECTORIES>)
+ endif()
+
+ if (QT_FEATURE_openssl AND QT_FEATURE_ssl AND NOT QT_FEATURE_openssl_linked)
+ include_directories($<TARGET_PROPERTY:${INSTALL_CMAKE_NAMESPACE}::SSL_nolink,INTERFACE_INCLUDE_DIRECTORIES>)
+ endif()
+endif()
+# special case end
+
+add_subdirectory(access)
+add_subdirectory(bearer)
+add_subdirectory(kernel)
+add_subdirectory(ssl)
+add_subdirectory(socket)
diff --git a/tests/auto/network/access/CMakeLists.txt b/tests/auto/network/access/CMakeLists.txt
new file mode 100644
index 0000000000..6d4b2b7263
--- /dev/null
+++ b/tests/auto/network/access/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from access.pro.
+
+add_subdirectory(qnetworkdiskcache)
+add_subdirectory(qnetworkcookiejar)
+add_subdirectory(qnetworkaccessmanager)
+add_subdirectory(qnetworkcookie)
+add_subdirectory(qnetworkrequest)
+add_subdirectory(qnetworkreply)
+add_subdirectory(qnetworkcachemetadata)
+add_subdirectory(qabstractnetworkcache)
+
+
+if(QT_FEATURE_private_tests)
+ add_subdirectory(qhttpnetworkconnection)
+ add_subdirectory(qhttpnetworkreply)
+ add_subdirectory(qftp)
+ add_subdirectory(hpack)
+ add_subdirectory(http2)
+ add_subdirectory(hsts)
+endif()
diff --git a/tests/auto/network/access/hpack/CMakeLists.txt b/tests/auto/network/access/hpack/CMakeLists.txt
new file mode 100644
index 0000000000..531246ecf0
--- /dev/null
+++ b/tests/auto/network/access/hpack/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from hpack.pro.
+
+#####################################################################
+## tst_hpack Test:
+#####################################################################
+
+add_qt_test(tst_hpack
+ SOURCES
+ tst_hpack.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:hpack.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/auto/network/access/hsts/CMakeLists.txt b/tests/auto/network/access/hsts/CMakeLists.txt
new file mode 100644
index 0000000000..f2d09a6395
--- /dev/null
+++ b/tests/auto/network/access/hsts/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from hsts.pro.
+
+#####################################################################
+## tst_qhsts Test:
+#####################################################################
+
+add_qt_test(tst_qhsts
+ SOURCES
+ tst_qhsts.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:hsts.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/auto/network/access/http2/CMakeLists.txt b/tests/auto/network/access/http2/CMakeLists.txt
new file mode 100644
index 0000000000..082da570e7
--- /dev/null
+++ b/tests/auto/network/access/http2/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from http2.pro.
+
+#####################################################################
+## tst_http2 Test:
+#####################################################################
+
+add_qt_test(tst_http2
+ SOURCES
+ ../../../../shared/emulationdetector.h
+ http2srv.cpp http2srv.h
+ tst_http2.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ INCLUDE_DIRECTORIES
+ ../../../../shared
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/access/qabstractnetworkcache/CMakeLists.txt b/tests/auto/network/access/qabstractnetworkcache/CMakeLists.txt
new file mode 100644
index 0000000000..07128e40bb
--- /dev/null
+++ b/tests/auto/network/access/qabstractnetworkcache/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from qabstractnetworkcache.pro.
+
+#####################################################################
+## tst_qabstractnetworkcache Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ tests/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qabstractnetworkcache
+ SOURCES
+ tst_qabstractnetworkcache.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ TESTDATA ${test_data}
+)
+
+#### Keys ignored in scope 1:.:.:qabstractnetworkcache.pro:<TRUE>:
+# QT_TEST_SERVER_LIST = "apache2"
diff --git a/tests/auto/network/access/qftp/CMakeLists.txt b/tests/auto/network/access/qftp/CMakeLists.txt
new file mode 100644
index 0000000000..4c706febdd
--- /dev/null
+++ b/tests/auto/network/access/qftp/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from qftp.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qftp Test:
+#####################################################################
+
+add_qt_test(tst_qftp
+ SOURCES
+ tst_qftp.cpp
+ LIBRARIES
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:qftp.pro:<TRUE>:
+# QT_TEST_SERVER_LIST = "vsftpd" "ftp-proxy" "squid" "danted"
+# _REQUIREMENTS = "qtConfig(private_tests)"
diff --git a/tests/auto/network/access/qhttpnetworkconnection/CMakeLists.txt b/tests/auto/network/access/qhttpnetworkconnection/CMakeLists.txt
new file mode 100644
index 0000000000..b1b2059952
--- /dev/null
+++ b/tests/auto/network/access/qhttpnetworkconnection/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from qhttpnetworkconnection.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qhttpnetworkconnection Test:
+#####################################################################
+
+add_qt_test(tst_qhttpnetworkconnection
+ SOURCES
+ tst_qhttpnetworkconnection.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:qhttpnetworkconnection.pro:<TRUE>:
+# QT_TEST_SERVER_LIST = "apache2"
+# _REQUIREMENTS = "qtConfig(private_tests)"
diff --git a/tests/auto/network/access/qhttpnetworkreply/CMakeLists.txt b/tests/auto/network/access/qhttpnetworkreply/CMakeLists.txt
new file mode 100644
index 0000000000..c381ec7b3b
--- /dev/null
+++ b/tests/auto/network/access/qhttpnetworkreply/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from qhttpnetworkreply.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qhttpnetworkreply Test:
+#####################################################################
+
+add_qt_test(tst_qhttpnetworkreply
+ SOURCES
+ tst_qhttpnetworkreply.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:qhttpnetworkreply.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
diff --git a/tests/auto/network/access/qnetworkaccessmanager/CMakeLists.txt b/tests/auto/network/access/qnetworkaccessmanager/CMakeLists.txt
new file mode 100644
index 0000000000..4b58c449c6
--- /dev/null
+++ b/tests/auto/network/access/qnetworkaccessmanager/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qnetworkaccessmanager.pro.
+
+#####################################################################
+## tst_qnetworkaccessmanager Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkaccessmanager
+ SOURCES
+ tst_qnetworkaccessmanager.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/access/qnetworkcachemetadata/CMakeLists.txt b/tests/auto/network/access/qnetworkcachemetadata/CMakeLists.txt
new file mode 100644
index 0000000000..08e80d8e0d
--- /dev/null
+++ b/tests/auto/network/access/qnetworkcachemetadata/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qnetworkcachemetadata.pro.
+
+#####################################################################
+## tst_qnetworkcachemetadata Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkcachemetadata
+ SOURCES
+ tst_qnetworkcachemetadata.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/access/qnetworkcookie/CMakeLists.txt b/tests/auto/network/access/qnetworkcookie/CMakeLists.txt
new file mode 100644
index 0000000000..ab90a61bb3
--- /dev/null
+++ b/tests/auto/network/access/qnetworkcookie/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qnetworkcookie.pro.
+
+#####################################################################
+## tst_qnetworkcookie Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkcookie
+ SOURCES
+ tst_qnetworkcookie.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/access/qnetworkcookiejar/CMakeLists.txt b/tests/auto/network/access/qnetworkcookiejar/CMakeLists.txt
new file mode 100644
index 0000000000..a9296cf3f0
--- /dev/null
+++ b/tests/auto/network/access/qnetworkcookiejar/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qnetworkcookiejar.pro.
+
+#####################################################################
+## tst_qnetworkcookiejar Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "parser.json")
+
+add_qt_test(tst_qnetworkcookiejar
+ SOURCES
+ tst_qnetworkcookiejar.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/network/access/qnetworkdiskcache/CMakeLists.txt b/tests/auto/network/access/qnetworkdiskcache/CMakeLists.txt
new file mode 100644
index 0000000000..b206686139
--- /dev/null
+++ b/tests/auto/network/access/qnetworkdiskcache/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qnetworkdiskcache.pro.
+
+#####################################################################
+## tst_qnetworkdiskcache Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkdiskcache
+ SOURCES
+ tst_qnetworkdiskcache.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/access/qnetworkreply/CMakeLists.txt b/tests/auto/network/access/qnetworkreply/CMakeLists.txt
new file mode 100644
index 0000000000..f7efa8f7f3
--- /dev/null
+++ b/tests/auto/network/access/qnetworkreply/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from qnetworkreply.pro.
+
+add_subdirectory(test)
+
+if(NOT WINRT)
+ add_subdirectory(echo)
+endif()
diff --git a/tests/auto/network/access/qnetworkreply/echo/.prev_CMakeLists.txt b/tests/auto/network/access/qnetworkreply/echo/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..e43272d7e8
--- /dev/null
+++ b/tests/auto/network/access/qnetworkreply/echo/.prev_CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from echo.pro.
+
+#####################################################################
+## echo Binary:
+#####################################################################
+
+add_qt_executable(echo
+ SOURCES
+ main.cpp
+)
diff --git a/tests/auto/network/access/qnetworkreply/echo/CMakeLists.txt b/tests/auto/network/access/qnetworkreply/echo/CMakeLists.txt
new file mode 100644
index 0000000000..f260b97b8d
--- /dev/null
+++ b/tests/auto/network/access/qnetworkreply/echo/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from echo.pro.
+
+#####################################################################
+## echo Binary:
+#####################################################################
+
+add_qt_executable(echo
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ main.cpp
+)
diff --git a/tests/auto/network/access/qnetworkreply/test/CMakeLists.txt b/tests/auto/network/access/qnetworkreply/test/CMakeLists.txt
new file mode 100644
index 0000000000..97d0da3d34
--- /dev/null
+++ b/tests/auto/network/access/qnetworkreply/test/CMakeLists.txt
@@ -0,0 +1,61 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qnetworkreply Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "../empty")
+list(APPEND test_data "../rfc3252.txt")
+list(APPEND test_data "../resource")
+list(APPEND test_data "../bigfile")
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ ../*.jpg)
+list(APPEND test_data ${test_data_glob})
+list(APPEND test_data "../certs")
+list(APPEND test_data "../index.html")
+list(APPEND test_data "../smb-file.txt")
+
+add_qt_test(tst_qnetworkreply
+ SOURCES
+ ../../../../../shared/emulationdetector.h
+ ../tst_qnetworkreply.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../../shared
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ TESTDATA ${test_data}
+)
+
+# Resources:
+set_source_files_properties("../resource"
+ PROPERTIES QT_RESOURCE_ALIAS "resource"
+)
+set(qnetworkreply_resource_files
+ "resource"
+)
+
+add_qt_resource(tst_qnetworkreply "qnetworkreply"
+ PREFIX
+ "/"
+ BASE
+ ".."
+ FILES
+ ${qnetworkreply_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:test.pro:<TRUE>:
+# QT_FOR_CONFIG = "gui-private"
+# QT_TEST_SERVER_LIST = "vsftpd" "apache2" "ftp-proxy" "danted" "squid"
+# testcase.timeout = "600"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:test.pro:NOT ANDROID AND NOT WINRT:
+# TEST_HELPER_INSTALLS = "../echo/echo"
diff --git a/tests/auto/network/access/qnetworkreply/test/test.pro b/tests/auto/network/access/qnetworkreply/test/test.pro
index 4cc1f6431e..d3385c1929 100644
--- a/tests/auto/network/access/qnetworkreply/test/test.pro
+++ b/tests/auto/network/access/qnetworkreply/test/test.pro
@@ -4,7 +4,7 @@ CONFIG -= debug_and_release_target
INCLUDEPATH += ../../../../../shared/
HEADERS += ../../../../../shared/emulationdetector.h
SOURCES += ../tst_qnetworkreply.cpp
-TARGET = ../tst_qnetworkreply
+TARGET = tst_qnetworkreply
QT = core-private network-private testlib
QT_FOR_CONFIG += gui-private
diff --git a/tests/auto/network/access/qnetworkrequest/CMakeLists.txt b/tests/auto/network/access/qnetworkrequest/CMakeLists.txt
new file mode 100644
index 0000000000..f089c5a43e
--- /dev/null
+++ b/tests/auto/network/access/qnetworkrequest/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qnetworkrequest.pro.
+
+#####################################################################
+## tst_qnetworkrequest Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkrequest
+ SOURCES
+ tst_qnetworkrequest.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/bearer/CMakeLists.txt b/tests/auto/network/bearer/CMakeLists.txt
new file mode 100644
index 0000000000..4b593aab0a
--- /dev/null
+++ b/tests/auto/network/bearer/CMakeLists.txt
@@ -0,0 +1,6 @@
+# Generated from bearer.pro.
+
+add_subdirectory(qnetworkconfiguration)
+add_subdirectory(qnetworkconfigurationmanager)
+add_subdirectory(qnetworkconfigurationmanagerqappless)
+add_subdirectory(qnetworksession)
diff --git a/tests/auto/network/bearer/qnetworkconfiguration/CMakeLists.txt b/tests/auto/network/bearer/qnetworkconfiguration/CMakeLists.txt
new file mode 100644
index 0000000000..1db8bb1e6b
--- /dev/null
+++ b/tests/auto/network/bearer/qnetworkconfiguration/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qnetworkconfiguration.pro.
+
+#####################################################################
+## tst_qnetworkconfiguration Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkconfiguration
+ SOURCES
+ ../qbearertestcommon.h
+ tst_qnetworkconfiguration.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/bearer/qnetworkconfigurationmanager/CMakeLists.txt b/tests/auto/network/bearer/qnetworkconfigurationmanager/CMakeLists.txt
new file mode 100644
index 0000000000..355bd4898a
--- /dev/null
+++ b/tests/auto/network/bearer/qnetworkconfigurationmanager/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qnetworkconfigurationmanager.pro.
+
+#####################################################################
+## tst_qnetworkconfigurationmanager Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkconfigurationmanager
+ SOURCES
+ ../qbearertestcommon.h
+ tst_qnetworkconfigurationmanager.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/bearer/qnetworkconfigurationmanagerqappless/CMakeLists.txt b/tests/auto/network/bearer/qnetworkconfigurationmanagerqappless/CMakeLists.txt
new file mode 100644
index 0000000000..dcf18785bf
--- /dev/null
+++ b/tests/auto/network/bearer/qnetworkconfigurationmanagerqappless/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qnetworkconfigurationmanagerqappless.pro.
+
+#####################################################################
+## tst_qnetworkconfigurationmanagerqappless Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkconfigurationmanagerqappless
+ SOURCES
+ ../qbearertestcommon.h
+ tst_qnetworkconfigurationmanagerqappless.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/bearer/qnetworksession/CMakeLists.txt b/tests/auto/network/bearer/qnetworksession/CMakeLists.txt
new file mode 100644
index 0000000000..99c3483e6c
--- /dev/null
+++ b/tests/auto/network/bearer/qnetworksession/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from qnetworksession.pro.
+
+add_subdirectory(test)
+
+if(NOT WINRT)
+ add_subdirectory(lackey)
+endif()
diff --git a/tests/auto/network/bearer/qnetworksession/lackey/CMakeLists.txt b/tests/auto/network/bearer/qnetworksession/lackey/CMakeLists.txt
new file mode 100644
index 0000000000..c2d0d59d57
--- /dev/null
+++ b/tests/auto/network/bearer/qnetworksession/lackey/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from lackey.pro.
+
+#####################################################################
+## lackey Binary:
+#####################################################################
+
+add_qt_executable(lackey
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/bearer/qnetworksession/test/.prev_CMakeLists.txt b/tests/auto/network/bearer/qnetworksession/test/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..0df7ce71da
--- /dev/null
+++ b/tests/auto/network/bearer/qnetworksession/test/.prev_CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qnetworksession Test:
+#####################################################################
+
+add_qt_test(tst_qnetworksession
+ SOURCES
+ ../../qbearertestcommon.h
+ tst_qnetworksession.cpp
+ LIBRARIES
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:test.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug"
+
+#### Keys ignored in scope 4:.:.:test.pro:else:
+# DESTDIR = "../release"
+
+#### Keys ignored in scope 5:.:.:test.pro:else:
+# DESTDIR = ".."
+
+#### Keys ignored in scope 6:.:.:test.pro:NOT ANDROID AND NOT WINRT:
+# TEST_HELPER_INSTALLS = "../lackey/lackey"
diff --git a/tests/auto/network/bearer/qnetworksession/test/CMakeLists.txt b/tests/auto/network/bearer/qnetworksession/test/CMakeLists.txt
new file mode 100644
index 0000000000..cbc6348d4d
--- /dev/null
+++ b/tests/auto/network/bearer/qnetworksession/test/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qnetworksession Test:
+#####################################################################
+
+add_qt_test(tst_qnetworksession
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../" # special case
+ SOURCES
+ ../../qbearertestcommon.h
+ tst_qnetworksession.cpp
+ LIBRARIES
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:test.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug"
+
+#### Keys ignored in scope 4:.:.:test.pro:else:
+# DESTDIR = "../release"
+
+#### Keys ignored in scope 5:.:.:test.pro:else:
+# DESTDIR = ".."
+
+#### Keys ignored in scope 6:.:.:test.pro:NOT ANDROID AND NOT WINRT:
+# TEST_HELPER_INSTALLS = "../lackey/lackey"
diff --git a/tests/auto/network/kernel/CMakeLists.txt b/tests/auto/network/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..c1082f60b7
--- /dev/null
+++ b/tests/auto/network/kernel/CMakeLists.txt
@@ -0,0 +1,19 @@
+add_subdirectory(qdnslookup)
+add_subdirectory(qdnslookup_appless)
+add_subdirectory(qnetworkinterface)
+add_subdirectory(qnetworkdatagram)
+add_subdirectory(qnetworkaddressentry)
+add_subdirectory(qhostaddress)
+
+if(NOT WINRT)
+ add_subdirectory(qnetworkproxy)
+ add_subdirectory(qnetworkproxyfactory)
+endif()
+
+if(QT_FEATURE_private_tests)
+ add_subdirectory(qauthenticator)
+
+ if(NOT APPLE_OSX)
+ add_subdirectory(qhostinfo)
+ endif()
+endif()
diff --git a/tests/auto/network/kernel/qauthenticator/CMakeLists.txt b/tests/auto/network/kernel/qauthenticator/CMakeLists.txt
new file mode 100644
index 0000000000..80d6667a21
--- /dev/null
+++ b/tests/auto/network/kernel/qauthenticator/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from qauthenticator.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qauthenticator Test:
+#####################################################################
+
+add_qt_test(tst_qauthenticator
+ SOURCES
+ tst_qauthenticator.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ LIBRARIES
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:qauthenticator.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
diff --git a/tests/auto/network/kernel/qdnslookup/CMakeLists.txt b/tests/auto/network/kernel/qdnslookup/CMakeLists.txt
new file mode 100644
index 0000000000..896b4431d8
--- /dev/null
+++ b/tests/auto/network/kernel/qdnslookup/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdnslookup.pro.
+
+#####################################################################
+## tst_qdnslookup Test:
+#####################################################################
+
+add_qt_test(tst_qdnslookup
+ SOURCES
+ tst_qdnslookup.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/kernel/qdnslookup_appless/CMakeLists.txt b/tests/auto/network/kernel/qdnslookup_appless/CMakeLists.txt
new file mode 100644
index 0000000000..847e1a6d90
--- /dev/null
+++ b/tests/auto/network/kernel/qdnslookup_appless/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdnslookup_appless.pro.
+
+#####################################################################
+## tst_qdnslookup_appless Test:
+#####################################################################
+
+add_qt_test(tst_qdnslookup_appless
+ SOURCES
+ tst_qdnslookup_appless.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/kernel/qhostaddress/CMakeLists.txt b/tests/auto/network/kernel/qhostaddress/CMakeLists.txt
new file mode 100644
index 0000000000..51de80402f
--- /dev/null
+++ b/tests/auto/network/kernel/qhostaddress/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from qhostaddress.pro.
+
+#####################################################################
+## tst_qhostaddress Test:
+#####################################################################
+
+add_qt_test(tst_qhostaddress
+ SOURCES
+ tst_qhostaddress.cpp
+ LIBRARIES
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qhostaddress CONDITION WIN32
+ PUBLIC_LIBRARIES
+ ws2_32
+)
diff --git a/tests/auto/network/kernel/qhostinfo/CMakeLists.txt b/tests/auto/network/kernel/qhostinfo/CMakeLists.txt
new file mode 100644
index 0000000000..60077d0021
--- /dev/null
+++ b/tests/auto/network/kernel/qhostinfo/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from qhostinfo.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qhostinfo Test:
+#####################################################################
+
+add_qt_test(tst_qhostinfo
+ SOURCES
+ tst_qhostinfo.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:qhostinfo.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qhostinfo CONDITION WIN32
+ PUBLIC_LIBRARIES
+ ws2_32
+)
+
+#### Keys ignored in scope 3:.:.:qhostinfo.pro:WINRT:
+# WINRT_MANIFEST.capabilities = "internetClientServer"
diff --git a/tests/auto/network/kernel/qnetworkaddressentry/CMakeLists.txt b/tests/auto/network/kernel/qnetworkaddressentry/CMakeLists.txt
new file mode 100644
index 0000000000..5a72d4e4a5
--- /dev/null
+++ b/tests/auto/network/kernel/qnetworkaddressentry/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qnetworkaddressentry.pro.
+
+#####################################################################
+## tst_qnetworkaddressentry Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkaddressentry
+ SOURCES
+ tst_qnetworkaddressentry.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/kernel/qnetworkdatagram/CMakeLists.txt b/tests/auto/network/kernel/qnetworkdatagram/CMakeLists.txt
new file mode 100644
index 0000000000..ae24d32917
--- /dev/null
+++ b/tests/auto/network/kernel/qnetworkdatagram/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qnetworkdatagram.pro.
+
+#####################################################################
+## tst_qnetworkdatagram Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkdatagram
+ SOURCES
+ tst_qnetworkdatagram.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/kernel/qnetworkinterface/CMakeLists.txt b/tests/auto/network/kernel/qnetworkinterface/CMakeLists.txt
new file mode 100644
index 0000000000..f23a17f077
--- /dev/null
+++ b/tests/auto/network/kernel/qnetworkinterface/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qnetworkinterface.pro.
+
+#####################################################################
+## tst_qnetworkinterface Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkinterface
+ SOURCES
+ ../../../../shared/emulationdetector.h
+ tst_qnetworkinterface.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../shared
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/kernel/qnetworkproxy/CMakeLists.txt b/tests/auto/network/kernel/qnetworkproxy/CMakeLists.txt
new file mode 100644
index 0000000000..e0cbe133af
--- /dev/null
+++ b/tests/auto/network/kernel/qnetworkproxy/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qnetworkproxy.pro.
+
+#####################################################################
+## tst_qnetworkproxy Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkproxy
+ SOURCES
+ tst_qnetworkproxy.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/kernel/qnetworkproxyfactory/CMakeLists.txt b/tests/auto/network/kernel/qnetworkproxyfactory/CMakeLists.txt
new file mode 100644
index 0000000000..3fd139b93e
--- /dev/null
+++ b/tests/auto/network/kernel/qnetworkproxyfactory/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qnetworkproxyfactory.pro.
+
+#####################################################################
+## tst_qnetworkproxyfactory Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkproxyfactory
+ SOURCES
+ tst_qnetworkproxyfactory.cpp
+ LIBRARIES
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/socket/CMakeLists.txt b/tests/auto/network/socket/CMakeLists.txt
new file mode 100644
index 0000000000..5019e47140
--- /dev/null
+++ b/tests/auto/network/socket/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from socket.pro.
+
+add_subdirectory(qudpsocket)
+### add_subdirectory(qlocalsocket)
+add_subdirectory(qtcpserver)
+add_subdirectory(qabstractsocket)
+
+if(QT_FEATURE_private_tests)
+ add_subdirectory(platformsocketengine)
+ add_subdirectory(qtcpsocket)
+
+ if(NOT WINRT)
+ add_subdirectory(qhttpsocketengine)
+ add_subdirectory(qsocks5socketengine)
+ endif()
+endif()
+
+if(QT_FEATURE_sctp)
+ add_subdirectory(qsctpsocket)
+endif()
diff --git a/tests/auto/network/socket/platformsocketengine/CMakeLists.txt b/tests/auto/network/socket/platformsocketengine/CMakeLists.txt
new file mode 100644
index 0000000000..bb681d9e2f
--- /dev/null
+++ b/tests/auto/network/socket/platformsocketengine/CMakeLists.txt
@@ -0,0 +1,40 @@
+# Generated from platformsocketengine.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_platformsocketengine Test:
+#####################################################################
+
+add_qt_test(tst_platformsocketengine
+ SOURCES
+ tst_platformsocketengine.cpp
+ INCLUDE_DIRECTORIES
+ ${QT_SOURCE_TREE}/src/network
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:platformsocketengine.pro:<TRUE>:
+# MOC_DIR = "tmp"
+# _REQUIREMENTS = "qtConfig(private_tests)"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_platformsocketengine CONDITION WIN32
+ PUBLIC_LIBRARIES
+ ws2_32
+)
+
+extend_target(tst_platformsocketengine CONDITION QT_FEATURE_reduce_exports AND UNIX
+ SOURCES
+ ${QT_SOURCE_TREE}/src/network/socket/qabstractsocketengine.cpp ${QT_SOURCE_TREE}/src/network/socket/qabstractsocketengine_p.h
+ ${QT_SOURCE_TREE}/src/network/socket/qnativesocketengine.cpp ${QT_SOURCE_TREE}/src/network/socket/qnativesocketengine_p.h
+ ${QT_SOURCE_TREE}/src/network/socket/qnativesocketengine_unix.cpp
+)
diff --git a/tests/auto/network/socket/platformsocketengine/platformsocketengine.pri b/tests/auto/network/socket/platformsocketengine/platformsocketengine.pri
index 868439de6a..df43a60065 100644
--- a/tests/auto/network/socket/platformsocketengine/platformsocketengine.pri
+++ b/tests/auto/network/socket/platformsocketengine/platformsocketengine.pri
@@ -9,5 +9,7 @@ win32: QMAKE_USE += ws2_32
unix:qtConfig(reduce_exports) {
SOURCES += $$QNETWORK_SRC/socket/qnativesocketengine_unix.cpp
SOURCES += $$QNETWORK_SRC/socket/qnativesocketengine.cpp
+ HEADERS += $$QNETWORK_SRC/socket/qnativesocketengine_p.h
SOURCES += $$QNETWORK_SRC/socket/qabstractsocketengine.cpp
+ HEADERS += $$QNETWORK_SRC/socket/qabstractsocketengine_p.h
}
diff --git a/tests/auto/network/socket/qabstractsocket/CMakeLists.txt b/tests/auto/network/socket/qabstractsocket/CMakeLists.txt
new file mode 100644
index 0000000000..ca7d64a2ff
--- /dev/null
+++ b/tests/auto/network/socket/qabstractsocket/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qabstractsocket.pro.
+
+#####################################################################
+## tst_qabstractsocket Test:
+#####################################################################
+
+add_qt_test(tst_qabstractsocket
+ SOURCES
+ tst_qabstractsocket.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/socket/qhttpsocketengine/CMakeLists.txt b/tests/auto/network/socket/qhttpsocketengine/CMakeLists.txt
new file mode 100644
index 0000000000..8dfa61c5ac
--- /dev/null
+++ b/tests/auto/network/socket/qhttpsocketengine/CMakeLists.txt
@@ -0,0 +1,43 @@
+# Generated from qhttpsocketengine.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qhttpsocketengine Test:
+#####################################################################
+
+add_qt_test(tst_qhttpsocketengine
+ SOURCES
+ tst_qhttpsocketengine.cpp
+ INCLUDE_DIRECTORIES
+ ${QT_SOURCE_TREE}/src/network
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:qhttpsocketengine.pro:<TRUE>:
+# MOC_DIR = "tmp"
+# _REQUIREMENTS = "qtConfig(private_tests)"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:qhttpsocketengine.pro:LINUX:
+# QT_TEST_SERVER_LIST = "squid" "danted" "cyrus" "apache2"
+
+extend_target(tst_qhttpsocketengine CONDITION WIN32
+ PUBLIC_LIBRARIES
+ ws2_32
+)
+
+extend_target(tst_qhttpsocketengine CONDITION QT_FEATURE_reduce_exports AND UNIX
+ SOURCES
+ ${QT_SOURCE_TREE}/src/network/socket/qabstractsocketengine.cpp ${QT_SOURCE_TREE}/src/network/socket/qabstractsocketengine_p.h
+ ${QT_SOURCE_TREE}/src/network/socket/qnativesocketengine.cpp ${QT_SOURCE_TREE}/src/network/socket/qnativesocketengine_p.h
+ ${QT_SOURCE_TREE}/src/network/socket/qnativesocketengine_unix.cpp
+)
diff --git a/tests/auto/network/socket/qlocalsocket/CMakeLists.txt b/tests/auto/network/socket/qlocalsocket/CMakeLists.txt
new file mode 100644
index 0000000000..97466174f9
--- /dev/null
+++ b/tests/auto/network/socket/qlocalsocket/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from qlocalsocket.pro.
+
+add_subdirectory(test)
+add_subdirectory(socketprocess)
diff --git a/tests/auto/network/socket/qlocalsocket/socketprocess/CMakeLists.txt b/tests/auto/network/socket/qlocalsocket/socketprocess/CMakeLists.txt
new file mode 100644
index 0000000000..cb339eb2fa
--- /dev/null
+++ b/tests/auto/network/socket/qlocalsocket/socketprocess/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from socketprocess.pro.
+
+#####################################################################
+## socketprocess Binary:
+#####################################################################
+
+add_qt_executable(socketprocess
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
diff --git a/tests/auto/network/socket/qlocalsocket/test/CMakeLists.txt b/tests/auto/network/socket/qlocalsocket/test/CMakeLists.txt
new file mode 100644
index 0000000000..eb427796ae
--- /dev/null
+++ b/tests/auto/network/socket/qlocalsocket/test/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qlocalsocket Test:
+#####################################################################
+
+add_qt_test(tst_qlocalsocket
+ SOURCES
+ ../tst_qlocalsocket.cpp
+ DEFINES
+ QLOCALSERVER_DEBUG
+ QLOCALSOCKET_DEBUG
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/../\\\"
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:test.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug"
+
+#### Keys ignored in scope 4:.:.:test.pro:else:
+# DESTDIR = "../release"
+
+#### Keys ignored in scope 5:.:.:test.pro:else:
+# DESTDIR = ".."
diff --git a/tests/auto/network/socket/qsctpsocket/CMakeLists.txt b/tests/auto/network/socket/qsctpsocket/CMakeLists.txt
new file mode 100644
index 0000000000..d272d018b6
--- /dev/null
+++ b/tests/auto/network/socket/qsctpsocket/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qsctpsocket.pro.
+
+#####################################################################
+## tst_qsctpsocket Test:
+#####################################################################
+
+add_qt_test(tst_qsctpsocket
+ SOURCES
+ tst_qsctpsocket.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/socket/qsocks5socketengine/CMakeLists.txt b/tests/auto/network/socket/qsocks5socketengine/CMakeLists.txt
new file mode 100644
index 0000000000..41a958a36e
--- /dev/null
+++ b/tests/auto/network/socket/qsocks5socketengine/CMakeLists.txt
@@ -0,0 +1,43 @@
+# Generated from qsocks5socketengine.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qsocks5socketengine Test:
+#####################################################################
+
+add_qt_test(tst_qsocks5socketengine
+ SOURCES
+ tst_qsocks5socketengine.cpp
+ INCLUDE_DIRECTORIES
+ ${QT_SOURCE_TREE}/src/network
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:qsocks5socketengine.pro:<TRUE>:
+# MOC_DIR = "tmp"
+# _REQUIREMENTS = "qtConfig(private_tests)"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:qsocks5socketengine.pro:LINUX:
+# QT_TEST_SERVER_LIST = "danted" "apache2" "cyrus"
+
+extend_target(tst_qsocks5socketengine CONDITION WIN32
+ PUBLIC_LIBRARIES
+ ws2_32
+)
+
+extend_target(tst_qsocks5socketengine CONDITION QT_FEATURE_reduce_exports AND UNIX
+ SOURCES
+ ${QT_SOURCE_TREE}/src/network/socket/qabstractsocketengine.cpp ${QT_SOURCE_TREE}/src/network/socket/qabstractsocketengine_p.h
+ ${QT_SOURCE_TREE}/src/network/socket/qnativesocketengine.cpp ${QT_SOURCE_TREE}/src/network/socket/qnativesocketengine_p.h
+ ${QT_SOURCE_TREE}/src/network/socket/qnativesocketengine_unix.cpp
+)
diff --git a/tests/auto/network/socket/qtcpserver/CMakeLists.txt b/tests/auto/network/socket/qtcpserver/CMakeLists.txt
new file mode 100644
index 0000000000..01f6c8b672
--- /dev/null
+++ b/tests/auto/network/socket/qtcpserver/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from qtcpserver.pro.
+
+add_subdirectory(test)
+add_subdirectory(crashingServer)
diff --git a/tests/auto/network/socket/qtcpserver/crashingServer/CMakeLists.txt b/tests/auto/network/socket/qtcpserver/crashingServer/CMakeLists.txt
new file mode 100644
index 0000000000..ad291f2ad8
--- /dev/null
+++ b/tests/auto/network/socket/qtcpserver/crashingServer/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from crashingServer.pro.
+
+#####################################################################
+## crashingServer Binary:
+#####################################################################
+
+add_qt_executable(crashingServer
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/network/socket/qtcpserver/test/CMakeLists.txt b/tests/auto/network/socket/qtcpserver/test/CMakeLists.txt
new file mode 100644
index 0000000000..df05c5012b
--- /dev/null
+++ b/tests/auto/network/socket/qtcpserver/test/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qtcpserver Test:
+#####################################################################
+
+add_qt_test(tst_qtcpserver
+ SOURCES
+ ../tst_qtcpserver.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:test.pro:<TRUE>:
+# MOC_DIR = "tmp"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qtcpserver CONDITION WIN32
+ PUBLIC_LIBRARIES
+ ws2_32
+)
+
+#### Keys ignored in scope 6:.:.:test.pro:LINUX:
+# QT_TEST_SERVER_LIST = "danted" "cyrus" "squid" "ftp-proxy"
diff --git a/tests/auto/network/socket/qtcpserver/test/test.pro b/tests/auto/network/socket/qtcpserver/test/test.pro
index 7e2e60a1e3..491ff28cdc 100644
--- a/tests/auto/network/socket/qtcpserver/test/test.pro
+++ b/tests/auto/network/socket/qtcpserver/test/test.pro
@@ -3,13 +3,13 @@ SOURCES += ../tst_qtcpserver.cpp
win32: QMAKE_USE += ws2_32
-TARGET = ../tst_qtcpserver
+TARGET = tst_qtcpserver
win32 {
CONFIG(debug, debug|release) {
- TARGET = ../../debug/tst_qtcpserver
+ TARGET = ../debug/tst_qtcpserver
} else {
- TARGET = ../../release/tst_qtcpserver
+ TARGET = ../release/tst_qtcpserver
}
}
diff --git a/tests/auto/network/socket/qtcpsocket/CMakeLists.txt b/tests/auto/network/socket/qtcpsocket/CMakeLists.txt
new file mode 100644
index 0000000000..b3ad79cba9
--- /dev/null
+++ b/tests/auto/network/socket/qtcpsocket/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from qtcpsocket.pro.
+
+add_subdirectory(test)
+
+if(NOT VXWORKS)
+ add_subdirectory(stressTest)
+endif()
diff --git a/tests/auto/network/socket/qtcpsocket/stressTest/CMakeLists.txt b/tests/auto/network/socket/qtcpsocket/stressTest/CMakeLists.txt
new file mode 100644
index 0000000000..da9d3a324f
--- /dev/null
+++ b/tests/auto/network/socket/qtcpsocket/stressTest/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from stressTest.pro.
+
+#####################################################################
+## stressTest Binary:
+#####################################################################
+
+add_qt_executable(stressTest
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ Test.cpp Test.h
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:stressTest.pro:<TRUE>:
+# MOC_DIR = ".moc/"
+# TMP_DIR = ".tmp/"
diff --git a/tests/auto/network/socket/qtcpsocket/test/.prev_CMakeLists.txt b/tests/auto/network/socket/qtcpsocket/test/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..238c6b9931
--- /dev/null
+++ b/tests/auto/network/socket/qtcpsocket/test/.prev_CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qtcpsocket Test:
+#####################################################################
+
+add_qt_test(tst_qtcpsocket
+ SOURCES
+ ../tst_qtcpsocket.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qtcpsocket CONDITION WIN32
+ PUBLIC_LIBRARIES
+ ws2_32
+)
+
+#### Keys ignored in scope 4:.:.:test.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug"
+
+#### Keys ignored in scope 5:.:.:test.pro:else:
+# DESTDIR = "../release"
+
+#### Keys ignored in scope 6:.:.:test.pro:else:
+# DESTDIR = "../"
+
+#### Keys ignored in scope 7:.:.:test.pro:LINUX:
+# QT_TEST_SERVER_LIST = "danted" "squid" "apache2" "ftp-proxy" "vsftpd" "iptables" "cyrus"
diff --git a/tests/auto/network/socket/qtcpsocket/test/CMakeLists.txt b/tests/auto/network/socket/qtcpsocket/test/CMakeLists.txt
new file mode 100644
index 0000000000..9523830a15
--- /dev/null
+++ b/tests/auto/network/socket/qtcpsocket/test/CMakeLists.txt
@@ -0,0 +1,41 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qtcpsocket Test:
+#####################################################################
+
+add_qt_test(tst_qtcpsocket
+ SOURCES
+ ../tst_qtcpsocket.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qtcpsocket CONDITION WIN32
+ PUBLIC_LIBRARIES
+ ws2_32
+)
+
+# special case begin
+set(THREADS_PREFER_PTHREAD_FLAG 1)
+find_package(Threads)
+target_link_libraries(tst_qtcpsocket PRIVATE Threads::Threads)
+# special case end
+
+#### Keys ignored in scope 4:.:.:test.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug"
+
+#### Keys ignored in scope 5:.:.:test.pro:else:
+# DESTDIR = "../release"
+
+#### Keys ignored in scope 6:.:.:test.pro:else:
+# DESTDIR = "../"
+
+#### Keys ignored in scope 7:.:.:test.pro:LINUX:
+# QT_TEST_SERVER_LIST = "danted" "squid" "apache2" "ftp-proxy" "vsftpd" "iptables" "cyrus"
diff --git a/tests/auto/network/socket/qudpsocket/CMakeLists.txt b/tests/auto/network/socket/qudpsocket/CMakeLists.txt
new file mode 100644
index 0000000000..b9d0646e58
--- /dev/null
+++ b/tests/auto/network/socket/qudpsocket/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from qudpsocket.pro.
+
+add_subdirectory(test)
+add_subdirectory(clientserver)
diff --git a/tests/auto/network/socket/qudpsocket/clientserver/CMakeLists.txt b/tests/auto/network/socket/qudpsocket/clientserver/CMakeLists.txt
new file mode 100644
index 0000000000..8b594c6913
--- /dev/null
+++ b/tests/auto/network/socket/qudpsocket/clientserver/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from clientserver.pro.
+
+#####################################################################
+## clientserver Binary:
+#####################################################################
+
+add_qt_executable(clientserver
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/socket/qudpsocket/test/CMakeLists.txt b/tests/auto/network/socket/qudpsocket/test/CMakeLists.txt
new file mode 100644
index 0000000000..f5ec5f50ce
--- /dev/null
+++ b/tests/auto/network/socket/qudpsocket/test/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qudpsocket Test:
+#####################################################################
+
+add_qt_test(tst_qudpsocket
+ SOURCES
+ ../tst_qudpsocket.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../../shared
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:test.pro:<TRUE>:
+# MOC_DIR = "tmp"
+# testcase.timeout = "800"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:test.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "../debug"
+
+#### Keys ignored in scope 4:.:.:test.pro:else:
+# DESTDIR = "../release"
+
+#### Keys ignored in scope 5:.:.:test.pro:else:
+# DESTDIR = "../"
+
+#### Keys ignored in scope 6:.:.:test.pro:LINUX:
+# QT_TEST_SERVER_LIST = "danted" "echo"
diff --git a/tests/auto/network/socket/qudpsocket/udpServer/.prev_CMakeLists.txt b/tests/auto/network/socket/qudpsocket/udpServer/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..be9819466f
--- /dev/null
+++ b/tests/auto/network/socket/qudpsocket/udpServer/.prev_CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from udpServer.pro.
+
+#####################################################################
+## udpServer Binary:
+#####################################################################
+
+add_qt_executable(udpServer
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/socket/qudpsocket/udpServer/CMakeLists.txt b/tests/auto/network/socket/qudpsocket/udpServer/CMakeLists.txt
new file mode 100644
index 0000000000..d9da87126f
--- /dev/null
+++ b/tests/auto/network/socket/qudpsocket/udpServer/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from udpServer.pro.
+
+#####################################################################
+## udpServer Binary:
+#####################################################################
+
+add_qt_executable(udpServer
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/./" # special case
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/ssl/CMakeLists.txt b/tests/auto/network/ssl/CMakeLists.txt
new file mode 100644
index 0000000000..c10cfabbf4
--- /dev/null
+++ b/tests/auto/network/ssl/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from ssl.pro.
+
+add_subdirectory(qpassworddigestor)
+add_subdirectory(qsslcertificate)
+add_subdirectory(qsslcipher)
+add_subdirectory(qsslellipticcurve)
+add_subdirectory(qsslerror)
+add_subdirectory(qsslkey)
+
+if(QT_FEATURE_ssl)
+
+ if(QT_FEATURE_private_tests)
+ add_subdirectory(qsslsocket)
+ if(NOT WINRT)
+ add_subdirectory(qsslsocket_onDemandCertificates_member)
+ add_subdirectory(qsslsocket_onDemandCertificates_static)
+ endif()
+
+ if(QT_FEATURE_dtls)
+ add_subdirectory(qdtlscookie)
+ add_subdirectory(qdtls)
+ endif()
+
+ if(QT_FEATURE_ocsp)
+ add_subdirectory(qocsp)
+ endif()
+ endif()
+endif()
+
+if(QT_FEATURE_ssl)
+
+ if(QT_FEATURE_private_tests)
+ add_subdirectory(qasn1element)
+ add_subdirectory(qssldiffiehellmanparameters)
+ endif()
+endif()
diff --git a/tests/auto/network/ssl/qasn1element/CMakeLists.txt b/tests/auto/network/ssl/qasn1element/CMakeLists.txt
new file mode 100644
index 0000000000..70738d6525
--- /dev/null
+++ b/tests/auto/network/ssl/qasn1element/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qasn1element.pro.
+
+#####################################################################
+## tst_qasn1element Test:
+#####################################################################
+
+add_qt_test(tst_qasn1element
+ SOURCES
+ tst_qasn1element.cpp
+ LIBRARIES
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/ssl/qdtls/CMakeLists.txt b/tests/auto/network/ssl/qdtls/CMakeLists.txt
new file mode 100644
index 0000000000..ce0f029f05
--- /dev/null
+++ b/tests/auto/network/ssl/qdtls/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from qdtls.pro.
+
+#####################################################################
+## tst_qdtls Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "certs")
+
+add_qt_test(tst_qdtls
+ SOURCES
+ tst_qdtls.cpp
+ LIBRARIES
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:qdtls.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "debug"
+
+#### Keys ignored in scope 4:.:.:qdtls.pro:else:
+# DESTDIR = "release"
diff --git a/tests/auto/network/ssl/qdtlscookie/CMakeLists.txt b/tests/auto/network/ssl/qdtlscookie/CMakeLists.txt
new file mode 100644
index 0000000000..1df4de743d
--- /dev/null
+++ b/tests/auto/network/ssl/qdtlscookie/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from qdtlscookie.pro.
+
+#####################################################################
+## tst_qdtlscookie Test:
+#####################################################################
+
+add_qt_test(tst_qdtlscookie
+ SOURCES
+ tst_qdtlscookie.cpp
+ LIBRARIES
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:qdtlscookie.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "debug"
+
+#### Keys ignored in scope 4:.:.:qdtlscookie.pro:else:
+# DESTDIR = "release"
diff --git a/tests/auto/network/ssl/qocsp/CMakeLists.txt b/tests/auto/network/ssl/qocsp/CMakeLists.txt
new file mode 100644
index 0000000000..4bace58e44
--- /dev/null
+++ b/tests/auto/network/ssl/qocsp/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from qocsp.pro.
+
+#####################################################################
+## tst_qocsp Test:
+#####################################################################
+
+add_qt_test(tst_qocsp
+ SOURCES
+ tst_qocsp.cpp
+ LIBRARIES
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:qocsp.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "debug"
+
+#### Keys ignored in scope 4:.:.:qocsp.pro:else:
+# DESTDIR = "release"
diff --git a/tests/auto/network/ssl/qpassworddigestor/CMakeLists.txt b/tests/auto/network/ssl/qpassworddigestor/CMakeLists.txt
new file mode 100644
index 0000000000..e0997fc26e
--- /dev/null
+++ b/tests/auto/network/ssl/qpassworddigestor/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qpassworddigestor.pro.
+
+#####################################################################
+## tst_qpassworddigestor Test:
+#####################################################################
+
+add_qt_test(tst_qpassworddigestor
+ SOURCES
+ tst_qpassworddigestor.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/ssl/qsslcertificate/CMakeLists.txt b/tests/auto/network/ssl/qsslcertificate/CMakeLists.txt
new file mode 100644
index 0000000000..1509c2e809
--- /dev/null
+++ b/tests/auto/network/ssl/qsslcertificate/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from qsslcertificate.pro.
+
+#####################################################################
+## tst_qsslcertificate Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ certificates/*)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ more-certificates/*)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ verify-certs/*)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ pkcs12/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qsslcertificate
+ SOURCES
+ tst_qsslcertificate.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/network/ssl/qsslcipher/CMakeLists.txt b/tests/auto/network/ssl/qsslcipher/CMakeLists.txt
new file mode 100644
index 0000000000..44e0e78220
--- /dev/null
+++ b/tests/auto/network/ssl/qsslcipher/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from qsslcipher.pro.
+
+#####################################################################
+## tst_qsslcipher Test:
+#####################################################################
+
+add_qt_test(tst_qsslcipher
+ SOURCES
+ tst_qsslcipher.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:qsslcipher.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "debug"
+
+#### Keys ignored in scope 4:.:.:qsslcipher.pro:else:
+# DESTDIR = "release"
diff --git a/tests/auto/network/ssl/qssldiffiehellmanparameters/CMakeLists.txt b/tests/auto/network/ssl/qssldiffiehellmanparameters/CMakeLists.txt
new file mode 100644
index 0000000000..f6785a6736
--- /dev/null
+++ b/tests/auto/network/ssl/qssldiffiehellmanparameters/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qssldiffiehellmanparameters.pro.
+
+#####################################################################
+## tst_qssldiffiehellmanparameters Test:
+#####################################################################
+
+add_qt_test(tst_qssldiffiehellmanparameters
+ SOURCES
+ tst_qssldiffiehellmanparameters.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/ssl/qsslellipticcurve/CMakeLists.txt b/tests/auto/network/ssl/qsslellipticcurve/CMakeLists.txt
new file mode 100644
index 0000000000..4df88ff305
--- /dev/null
+++ b/tests/auto/network/ssl/qsslellipticcurve/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qsslellipticcurve.pro.
+
+#####################################################################
+## tst_qsslellipticcurve Test:
+#####################################################################
+
+add_qt_test(tst_qsslellipticcurve
+ SOURCES
+ tst_qsslellipticcurve.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/network/ssl/qsslerror/CMakeLists.txt b/tests/auto/network/ssl/qsslerror/CMakeLists.txt
new file mode 100644
index 0000000000..e8b07ab049
--- /dev/null
+++ b/tests/auto/network/ssl/qsslerror/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from qsslerror.pro.
+
+#####################################################################
+## tst_qsslerror Test:
+#####################################################################
+
+add_qt_test(tst_qsslerror
+ SOURCES
+ tst_qsslerror.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:qsslerror.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "debug"
+
+#### Keys ignored in scope 4:.:.:qsslerror.pro:else:
+# DESTDIR = "release"
diff --git a/tests/auto/network/ssl/qsslkey/CMakeLists.txt b/tests/auto/network/ssl/qsslkey/CMakeLists.txt
new file mode 100644
index 0000000000..8b16325559
--- /dev/null
+++ b/tests/auto/network/ssl/qsslkey/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from qsslkey.pro.
+
+#####################################################################
+## tst_qsslkey Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ keys/*)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ rsa-*.pem)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qsslkey
+ SOURCES
+ tst_qsslkey.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qsslkey CONDITION QT_FEATURE_private_tests
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::Network
+)
diff --git a/tests/auto/network/ssl/qsslsocket/CMakeLists.txt b/tests/auto/network/ssl/qsslsocket/CMakeLists.txt
new file mode 100644
index 0000000000..601165d55d
--- /dev/null
+++ b/tests/auto/network/ssl/qsslsocket/CMakeLists.txt
@@ -0,0 +1,40 @@
+# Generated from qsslsocket.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qsslsocket Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "certs")
+
+add_qt_test(tst_qsslsocket
+ SOURCES
+ tst_qsslsocket.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ TESTDATA ${test_data}
+)
+
+#### Keys ignored in scope 1:.:.:qsslsocket.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:qsslsocket.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "debug"
+
+#### Keys ignored in scope 4:.:.:qsslsocket.pro:else:
+# DESTDIR = "release"
+
+#### Keys ignored in scope 5:.:.:qsslsocket.pro:LINUX:
+# QT_TEST_SERVER_LIST = "squid" "danted" "cyrus" "apache2" "echo"
diff --git a/tests/auto/network/ssl/qsslsocket_onDemandCertificates_member/CMakeLists.txt b/tests/auto/network/ssl/qsslsocket_onDemandCertificates_member/CMakeLists.txt
new file mode 100644
index 0000000000..b3d8626da9
--- /dev/null
+++ b/tests/auto/network/ssl/qsslsocket_onDemandCertificates_member/CMakeLists.txt
@@ -0,0 +1,37 @@
+# Generated from qsslsocket_onDemandCertificates_member.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qsslsocket_onDemandCertificates_member Test:
+#####################################################################
+
+add_qt_test(tst_qsslsocket_onDemandCertificates_member
+ SOURCES
+ tst_qsslsocket_onDemandCertificates_member.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:qsslsocket_onDemandCertificates_member.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
+# testcase.timeout = "300"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:qsslsocket_onDemandCertificates_member.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "debug"
+
+#### Keys ignored in scope 4:.:.:qsslsocket_onDemandCertificates_member.pro:else:
+# DESTDIR = "release"
+
+#### Keys ignored in scope 5:.:.:qsslsocket_onDemandCertificates_member.pro:LINUX:
+# QT_TEST_SERVER_LIST = "squid" "danted"
diff --git a/tests/auto/network/ssl/qsslsocket_onDemandCertificates_static/CMakeLists.txt b/tests/auto/network/ssl/qsslsocket_onDemandCertificates_static/CMakeLists.txt
new file mode 100644
index 0000000000..b71d0a4f8b
--- /dev/null
+++ b/tests/auto/network/ssl/qsslsocket_onDemandCertificates_static/CMakeLists.txt
@@ -0,0 +1,36 @@
+# Generated from qsslsocket_onDemandCertificates_static.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qsslsocket_onDemandCertificates_static Test:
+#####################################################################
+
+add_qt_test(tst_qsslsocket_onDemandCertificates_static
+ SOURCES
+ tst_qsslsocket_onDemandCertificates_static.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:qsslsocket_onDemandCertificates_static.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:.:qsslsocket_onDemandCertificates_static.pro:(CMAKE_BUILD_TYPE STREQUAL Debug):
+# DESTDIR = "debug"
+
+#### Keys ignored in scope 4:.:.:qsslsocket_onDemandCertificates_static.pro:else:
+# DESTDIR = "release"
+
+#### Keys ignored in scope 5:.:.:qsslsocket_onDemandCertificates_static.pro:LINUX:
+# QT_TEST_SERVER_LIST = "squid" "danted"
diff --git a/tests/auto/opengl/CMakeLists.txt b/tests/auto/opengl/CMakeLists.txt
new file mode 100644
index 0000000000..54238c1fa6
--- /dev/null
+++ b/tests/auto/opengl/CMakeLists.txt
@@ -0,0 +1,6 @@
+# Generated from opengl.pro.
+
+add_subdirectory(qgl)
+add_subdirectory(qglbuffer)
+add_subdirectory(qglfunctions)
+add_subdirectory(qglthreads)
diff --git a/tests/auto/opengl/qgl/CMakeLists.txt b/tests/auto/opengl/qgl/CMakeLists.txt
new file mode 100644
index 0000000000..6af8834473
--- /dev/null
+++ b/tests/auto/opengl/qgl/CMakeLists.txt
@@ -0,0 +1,42 @@
+# Generated from qgl.pro.
+
+if(NOT TARGET Qt::OpenGL)
+ return()
+endif()
+
+#####################################################################
+## tst_qgl Test:
+#####################################################################
+
+add_qt_test(tst_qgl
+ SOURCES
+ tst_qgl.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::OpenGLPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::OpenGL
+ Qt::Widgets
+)
+
+# Resources:
+set_source_files_properties("../../gui/image/qpixmap/images/designer.png"
+ PROPERTIES QT_RESOURCE_ALIAS "designer.png"
+)
+set(qgl_resource_files
+ "../../gui/image/qpixmap/images/designer.png"
+)
+
+add_qt_resource(tst_qgl "qgl"
+ PREFIX
+ "/"
+ FILES
+ ${qgl_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:qgl.pro:<TRUE>:
+# _REQUIREMENTS = "qtHaveModule(opengl)"
diff --git a/tests/auto/opengl/qglbuffer/CMakeLists.txt b/tests/auto/opengl/qglbuffer/CMakeLists.txt
new file mode 100644
index 0000000000..f494115638
--- /dev/null
+++ b/tests/auto/opengl/qglbuffer/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from qglbuffer.pro.
+
+if(NOT TARGET Qt::OpenGL)
+ return()
+endif()
+
+#####################################################################
+## tst_qglbuffer Test:
+#####################################################################
+
+add_qt_test(tst_qglbuffer
+ SOURCES
+ tst_qglbuffer.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::OpenGL
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qglbuffer.pro:<TRUE>:
+# _REQUIREMENTS = "qtHaveModule(opengl)"
diff --git a/tests/auto/opengl/qglfunctions/CMakeLists.txt b/tests/auto/opengl/qglfunctions/CMakeLists.txt
new file mode 100644
index 0000000000..8eb344a8d6
--- /dev/null
+++ b/tests/auto/opengl/qglfunctions/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from qglfunctions.pro.
+
+if(NOT TARGET Qt::OpenGL)
+ return()
+endif()
+
+#####################################################################
+## tst_qglfunctions Test:
+#####################################################################
+
+add_qt_test(tst_qglfunctions
+ SOURCES
+ tst_qglfunctions.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::OpenGL
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qglfunctions.pro:<TRUE>:
+# _REQUIREMENTS = "qtHaveModule(opengl)"
diff --git a/tests/auto/other/CMakeLists.txt b/tests/auto/other/CMakeLists.txt
new file mode 100644
index 0000000000..e1d3c0e839
--- /dev/null
+++ b/tests/auto/other/CMakeLists.txt
@@ -0,0 +1,49 @@
+# Generated from other.pro.
+
+if(NOT cross_compile)
+ add_subdirectory(compiler)
+ # add_subdirectory(atwrapper) <- does not exist # special case
+endif()
+if(TARGET Qt::Widgets)
+ add_subdirectory(gestures)
+ add_subdirectory(languagechange)
+ add_subdirectory(qfocusevent)
+ add_subdirectory(qsharedpointer_and_qwidget)
+ # add_subdirectory(windowsmobile) <- does not exist # special case
+endif()
+if(TARGET Qt::Network AND TARGET Qt::Widgets AND NOT WINRT)
+ add_subdirectory(lancelot)
+ add_subdirectory(qnetworkaccessmanager_and_qprogressdialog)
+endif()
+if(APPLE_OSX AND TARGET Qt::Gui AND TARGET Qt::Widgets)
+ add_subdirectory(macgui)
+ add_subdirectory(macplist)
+ add_subdirectory(qaccessibilitymac)
+endif()
+if(TARGET Qt::Gui)
+ add_subdirectory(qcomplextext)
+endif()
+if(QT_FEATURE_process AND TARGET Qt::Gui)
+ add_subdirectory(qprocess_and_guieventloop)
+endif()
+if(QT_FEATURE_accessibility AND TARGET Qt::Gui AND TARGET Qt::Widgets AND NOT WINRT)
+ add_subdirectory(qaccessibility)
+endif()
+if(QT_FEATURE_accessibility_atspi_bridge AND TARGET Qt::Gui AND TARGET Qt::Widgets)
+ #add_subdirectory(qaccessibilitylinux) # special case # This test is broken
+endif()
+if(TARGET Qt::Network AND NOT WINRT)
+ add_subdirectory(networkselftest)
+endif()
+if(APPLE_OSX AND TARGET Qt::Gui)
+ add_subdirectory(macnativeevents)
+endif()
+if(embedded)
+ add_subdirectory(qdirectpainter)
+endif()
+if(ANDROID)
+ add_subdirectory(android)
+endif()
+if(QT_FEATURE_xkbcommon)
+ add_subdirectory(xkbkeyboard)
+endif()
diff --git a/tests/auto/other/android/CMakeLists.txt b/tests/auto/other/android/CMakeLists.txt
new file mode 100644
index 0000000000..e59111bb40
--- /dev/null
+++ b/tests/auto/other/android/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from android.pro.
+
+#####################################################################
+## tst_android Test:
+#####################################################################
+
+add_qt_test(tst_android
+ SOURCES
+ tst_android.cpp
+)
+
+if(ANDROID)
+ set_property(TARGET tst_android APPEND PROPERTY QT_ANDROID_PACKAGE_SOURCE_DIR
+ ${CMAKE_CURRENT_SOURCE_DIR}/testdata
+ )
+endif()
+
+#### Keys ignored in scope 1:.:.:android.pro:<TRUE>:
+# DISTFILES = "testdata/assets/test.txt"
diff --git a/tests/auto/other/compiler/.prev_CMakeLists.txt b/tests/auto/other/compiler/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..6824640d93
--- /dev/null
+++ b/tests/auto/other/compiler/.prev_CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from compiler.pro.
+
+#####################################################################
+## tst_compiler Test:
+#####################################################################
+
+add_qt_test(tst_compiler
+ SOURCES
+ baseclass.cpp baseclass.h
+ derivedclass.cpp derivedclass.h
+ othersource.cpp
+ tst_compiler.cpp
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/other/compiler/CMakeLists.txt b/tests/auto/other/compiler/CMakeLists.txt
new file mode 100644
index 0000000000..1849b7ec2c
--- /dev/null
+++ b/tests/auto/other/compiler/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from compiler.pro.
+
+#####################################################################
+## tst_compiler Test:
+#####################################################################
+
+add_qt_test(tst_compiler
+ EXCEPTIONS # special case
+ SOURCES
+ baseclass.cpp baseclass.h
+ derivedclass.cpp derivedclass.h
+ othersource.cpp
+ tst_compiler.cpp
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/other/gestures/CMakeLists.txt b/tests/auto/other/gestures/CMakeLists.txt
new file mode 100644
index 0000000000..b1a07e6cb3
--- /dev/null
+++ b/tests/auto/other/gestures/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from gestures.pro.
+
+#####################################################################
+## tst_gestures Test:
+#####################################################################
+
+add_qt_test(tst_gestures
+ SOURCES
+ tst_gestures.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/other/lancelot/CMakeLists.txt b/tests/auto/other/lancelot/CMakeLists.txt
new file mode 100644
index 0000000000..974112a5ad
--- /dev/null
+++ b/tests/auto/other/lancelot/CMakeLists.txt
@@ -0,0 +1,80 @@
+# Generated from lancelot.pro.
+
+#####################################################################
+## tst_lancelot Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ scripts/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_lancelot
+ SOURCES
+ ../../../baselineserver/shared/baselineprotocol.cpp ../../../baselineserver/shared/baselineprotocol.h
+ ../../../baselineserver/shared/lookup3.cpp
+ ../../../baselineserver/shared/qbaselinetest.cpp ../../../baselineserver/shared/qbaselinetest.h
+ paintcommands.cpp paintcommands.h
+ tst_lancelot.cpp
+ DEFINES
+ QMAKESPEC=\\\"\\\"
+ INCLUDE_DIRECTORIES
+ ../../../baselineserver/shared
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Network
+ TESTDATA ${test_data}
+)
+
+# Resources:
+set(images_resource_files
+ "images/alpha.png"
+ "images/alpha2x2.png"
+ "images/bitmap.png"
+ "images/border.png"
+ "images/borderimage.png"
+ "images/dome_argb32.png"
+ "images/dome_indexed.png"
+ "images/dome_indexed_mask.png"
+ "images/dome_mono.png"
+ "images/dome_mono_128.png"
+ "images/dome_mono_palette.png"
+ "images/dome_rgb32.png"
+ "images/dot.png"
+ "images/face.png"
+ "images/gam030.png"
+ "images/gam045.png"
+ "images/gam056.png"
+ "images/gam100.png"
+ "images/gam200.png"
+ "images/image.png"
+ "images/mask.png"
+ "images/mask_100.png"
+ "images/masked.png"
+ "images/sign.png"
+ "images/solid.png"
+ "images/solid2x2.png"
+ "images/struct-image-01.jpg"
+ "images/struct-image-01.png"
+ "images/zebra.png"
+)
+
+add_qt_resource(tst_lancelot "images"
+ PREFIX
+ "/"
+ FILES
+ ${images_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:../../../baselineserver/shared:../../../baselineserver/shared/qbaselinetest.pri:WIN32:
+# MKSPEC = "$$replace(QMAKESPEC, \\\\, /)"
+
+#### Keys ignored in scope 4:.:../../../baselineserver/shared:../../../baselineserver/shared/qbaselinetest.pri:else:
+# MKSPEC = "$$QMAKESPEC"
diff --git a/tests/auto/other/languagechange/CMakeLists.txt b/tests/auto/other/languagechange/CMakeLists.txt
new file mode 100644
index 0000000000..d93808848b
--- /dev/null
+++ b/tests/auto/other/languagechange/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from languagechange.pro.
+
+#####################################################################
+## tst_languagechange Test:
+#####################################################################
+
+add_qt_test(tst_languagechange
+ SOURCES
+ tst_languagechange.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:languagechange.pro:WIN32:
+# testcase.timeout = "1800"
diff --git a/tests/auto/other/macgui/.prev_CMakeLists.txt b/tests/auto/other/macgui/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..316d8f7232
--- /dev/null
+++ b/tests/auto/other/macgui/.prev_CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from macgui.pro.
+
+if(NOT APPLE)
+ return()
+endif()
+if(NOT widgets)
+ return()
+endif()
+
+#####################################################################
+## tst_macgui Test:
+#####################################################################
+
+add_qt_test(tst_macgui
+ SOURCES
+ guitest.cpp guitest.h
+ tst_macgui.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:macgui.pro:<TRUE>:
+# _REQUIREMENTS = "mac" "widgets"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_macgui CONDITION APPLE_OSX
+ PUBLIC_LIBRARIES
+ ${FWApplicationServices}
+)
diff --git a/tests/auto/other/macgui/CMakeLists.txt b/tests/auto/other/macgui/CMakeLists.txt
new file mode 100644
index 0000000000..898abf16f4
--- /dev/null
+++ b/tests/auto/other/macgui/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from macgui.pro.
+
+if(NOT APPLE)
+ return()
+endif()
+if(NOT TARGET Qt::Widgets) # special case
+ return()
+endif()
+
+#####################################################################
+## tst_macgui Test:
+#####################################################################
+
+add_qt_test(tst_macgui
+ SOURCES
+ guitest.cpp guitest.h
+ tst_macgui.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:macgui.pro:<TRUE>:
+# _REQUIREMENTS = "mac" "widgets"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_macgui CONDITION APPLE_OSX
+ PUBLIC_LIBRARIES
+ ${FWApplicationServices}
+)
diff --git a/tests/auto/other/macnativeevents/CMakeLists.txt b/tests/auto/other/macnativeevents/CMakeLists.txt
new file mode 100644
index 0000000000..167e46055a
--- /dev/null
+++ b/tests/auto/other/macnativeevents/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from macnativeevents.pro.
+
+if(NOT APPLE)
+ return()
+endif()
+
+#####################################################################
+## tst_macnativeevents Test:
+#####################################################################
+
+add_qt_test(tst_macnativeevents
+ SOURCES
+ expectedeventlist.cpp expectedeventlist.h
+ nativeeventlist.cpp nativeeventlist.h
+ qnativeevents.cpp qnativeevents.h
+ qnativeevents_mac.cpp
+ tst_macnativeevents.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:macnativeevents.pro:<TRUE>:
+# _REQUIREMENTS = "mac"
diff --git a/tests/auto/other/macplist/CMakeLists.txt b/tests/auto/other/macplist/CMakeLists.txt
new file mode 100644
index 0000000000..7ebb9d732c
--- /dev/null
+++ b/tests/auto/other/macplist/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from macplist.pro.
+
+if(NOT TARGET Qt::Widgets) # special case
+ return()
+endif()
+add_subdirectory(app)
+add_subdirectory(test)
diff --git a/tests/auto/other/macplist/app/.prev_CMakeLists.txt b/tests/auto/other/macplist/app/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..f04afb4311
--- /dev/null
+++ b/tests/auto/other/macplist/app/.prev_CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from app.pro.
+
+#####################################################################
+## app Binary:
+#####################################################################
+
+add_qt_executable(app
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/other/macplist/app/CMakeLists.txt b/tests/auto/other/macplist/app/CMakeLists.txt
new file mode 100644
index 0000000000..2effb2aa34
--- /dev/null
+++ b/tests/auto/other/macplist/app/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from app.pro.
+
+#####################################################################
+## app Binary:
+#####################################################################
+
+add_qt_executable(app
+ GUI
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/other/macplist/test/CMakeLists.txt b/tests/auto/other/macplist/test/CMakeLists.txt
new file mode 100644
index 0000000000..3cb8066adf
--- /dev/null
+++ b/tests/auto/other/macplist/test/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_macplist Test:
+#####################################################################
+
+add_qt_test(tst_macplist
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"
+ SOURCES
+ ../tst_macplist.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/other/networkselftest/CMakeLists.txt b/tests/auto/other/networkselftest/CMakeLists.txt
new file mode 100644
index 0000000000..49a5664ded
--- /dev/null
+++ b/tests/auto/other/networkselftest/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from networkselftest.pro.
+
+#####################################################################
+## tst_networkselftest Test:
+#####################################################################
+
+add_qt_test(tst_networkselftest
+ SOURCES
+ tst_networkselftest.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/auto/other/qaccessibility/.prev_CMakeLists.txt b/tests/auto/other/qaccessibility/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..85d938e100
--- /dev/null
+++ b/tests/auto/other/qaccessibility/.prev_CMakeLists.txt
@@ -0,0 +1,49 @@
+# Generated from qaccessibility.pro.
+
+if(NOT QT_FEATURE_accessibility)
+ return()
+endif()
+
+#####################################################################
+## tst_qaccessibility Test:
+#####################################################################
+
+add_qt_test(tst_qaccessibility
+ SOURCES
+ accessiblewidgets.h
+ tst_qaccessibility.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qaccessibility.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(accessibility)"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qaccessibility CONDITION UNIX AND NOT APPLE AND NOT HAIKU AND NOT integity
+ PUBLIC_LIBRARIES
+ m
+)
+
+extend_target(tst_qaccessibility CONDITION WIN32
+ PUBLIC_LIBRARIES
+ ole32
+ oleacc
+ oleaut32
+ uuid
+)
+
+extend_target(tst_qaccessibility CONDITION WIN32 AND NOT WINRT
+ LIBRARIES
+ Qt::WindowsUIAutomationSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::WindowsUIAutomationSupport
+)
diff --git a/tests/auto/other/qaccessibility/CMakeLists.txt b/tests/auto/other/qaccessibility/CMakeLists.txt
new file mode 100644
index 0000000000..0b98cae5f9
--- /dev/null
+++ b/tests/auto/other/qaccessibility/CMakeLists.txt
@@ -0,0 +1,55 @@
+# Generated from qaccessibility.pro.
+
+if(NOT QT_FEATURE_accessibility)
+ return()
+endif()
+
+# special case begin
+if (WIN32 AND NOT TARGET Qt::WindowsUIAutomationSupport)
+ return()
+endif()
+# special case end
+
+#####################################################################
+## tst_qaccessibility Test:
+#####################################################################
+
+add_qt_test(tst_qaccessibility
+ SOURCES
+ accessiblewidgets.h
+ tst_qaccessibility.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qaccessibility.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(accessibility)"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qaccessibility CONDITION UNIX AND NOT APPLE AND NOT HAIKU AND NOT integity
+ PUBLIC_LIBRARIES
+ m
+)
+
+extend_target(tst_qaccessibility CONDITION WIN32
+ PUBLIC_LIBRARIES
+ ole32
+ oleacc
+ oleaut32
+ uuid
+)
+
+extend_target(tst_qaccessibility CONDITION WIN32 AND NOT WINRT
+ LIBRARIES
+ Qt::WindowsUIAutomationSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::WindowsUIAutomationSupport
+)
diff --git a/tests/auto/other/qaccessibilitylinux/.prev_CMakeLists.txt b/tests/auto/other/qaccessibilitylinux/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..adfb7e5a83
--- /dev/null
+++ b/tests/auto/other/qaccessibilitylinux/.prev_CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from qaccessibilitylinux.pro.
+
+#####################################################################
+## tst_qaccessibilitylinux Test:
+#####################################################################
+
+add_qt_test(tst_qaccessibilitylinux
+ SOURCES
+ tst_qaccessibilitylinux.cpp
+ DBUS_INTERFACE_SOURCES
+ ../../../../src/platformsupport/linuxaccessibility/dbusxml/Bus.xml
+ LIBRARIES
+ Qt::AccessibilitySupportPrivate
+ Qt::GuiPrivate
+ Qt::LinuxAccessibilitySupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::AccessibilitySupport
+ Qt::DBus
+ Qt::Gui
+ Qt::LinuxAccessibilitySupport
+ Qt::Widgets
+)
diff --git a/tests/auto/other/qaccessibilitylinux/CMakeLists.txt b/tests/auto/other/qaccessibilitylinux/CMakeLists.txt
new file mode 100644
index 0000000000..905e68edc4
--- /dev/null
+++ b/tests/auto/other/qaccessibilitylinux/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from qaccessibilitylinux.pro.
+# special case begin
+if (NOT QT_FEATURE_accessibility OR NOT TARGET Qt::LinuxAccessibilitySupportPrivate
+ OR (QT_BUILD_STANDALONE_TESTS AND QT_WILL_INSTALL))
+ return()
+endif()
+# special case end
+
+#####################################################################
+## tst_qaccessibilitylinux Test:
+#####################################################################
+
+add_qt_test(tst_qaccessibilitylinux
+ SOURCES
+ tst_qaccessibilitylinux.cpp
+ DBUS_INTERFACE_SOURCES
+ ../../../../src/platformsupport/linuxaccessibility/dbusxml/Bus.xml
+ LIBRARIES
+ Qt::AccessibilitySupportPrivate
+ Qt::GuiPrivate
+ Qt::LinuxAccessibilitySupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::AccessibilitySupport
+ Qt::DBus
+ Qt::Gui
+ Qt::LinuxAccessibilitySupport
+ Qt::Widgets
+)
+
+# special case begin
+# require for struct_marshallers_p.h which is included dbus_interface.h
+target_include_directories(tst_qaccessibilitylinux PRIVATE
+ ../../../../src/platformsupport/linuxaccessibility
+)
+# special case end
diff --git a/tests/auto/other/qaccessibilitymac/CMakeLists.txt b/tests/auto/other/qaccessibilitymac/CMakeLists.txt
new file mode 100644
index 0000000000..ab8b9fcb9b
--- /dev/null
+++ b/tests/auto/other/qaccessibilitymac/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from qaccessibilitymac.pro.
+
+if(NOT APPLE)
+ return()
+endif()
+
+#####################################################################
+## tst_qaccessibilitymac Test:
+#####################################################################
+
+add_qt_test(tst_qaccessibilitymac
+ SOURCES
+ tst_qaccessibilitymac.cpp
+ tst_qaccessibilitymac_helpers.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qaccessibilitymac.pro:<TRUE>:
+# _REQUIREMENTS = "mac"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qaccessibilitymac CONDITION APPLE
+ SOURCES
+ tst_qaccessibilitymac_helpers.mm
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+ ${FWApplicationServices}
+ ${FWSecurity}
+)
diff --git a/tests/auto/other/qcomplextext/CMakeLists.txt b/tests/auto/other/qcomplextext/CMakeLists.txt
new file mode 100644
index 0000000000..883fabe01a
--- /dev/null
+++ b/tests/auto/other/qcomplextext/CMakeLists.txt
@@ -0,0 +1,42 @@
+# Generated from qcomplextext.pro.
+
+#####################################################################
+## tst_qcomplextext Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "data")
+
+add_qt_test(tst_qcomplextext
+ SOURCES
+ tst_qcomplextext.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+if(ANDROID)
+ # Resources:
+ set(android_testdata_resource_files
+ "data/BidiCharacterTest.txt"
+ "data/BidiTest.txt"
+ )
+
+ add_qt_resource(tst_qcomplextext "android_testdata"
+ PREFIX
+ "/android_testdata"
+ FILES
+ ${android_testdata_resource_files}
+ )
+endif()
+
+extend_target(tst_qcomplextext CONDITION builtin_testdata
+ DEFINES
+ BUILTIN_TESTDATA
+)
diff --git a/tests/auto/other/qfocusevent/CMakeLists.txt b/tests/auto/other/qfocusevent/CMakeLists.txt
new file mode 100644
index 0000000000..044b176555
--- /dev/null
+++ b/tests/auto/other/qfocusevent/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qfocusevent.pro.
+
+#####################################################################
+## tst_qfocusevent Test:
+#####################################################################
+
+add_qt_test(tst_qfocusevent
+ SOURCES
+ tst_qfocusevent.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/other/qnetworkaccessmanager_and_qprogressdialog/CMakeLists.txt b/tests/auto/other/qnetworkaccessmanager_and_qprogressdialog/CMakeLists.txt
new file mode 100644
index 0000000000..c4b9b186a1
--- /dev/null
+++ b/tests/auto/other/qnetworkaccessmanager_and_qprogressdialog/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qnetworkaccessmanager_and_qprogressdialog.pro.
+
+#####################################################################
+## tst_qnetworkaccessmanager_and_qprogressdialog Test:
+#####################################################################
+
+add_qt_test(tst_qnetworkaccessmanager_and_qprogressdialog
+ SOURCES
+ tst_qnetworkaccessmanager_and_qprogressdialog.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/tests/auto/other/qobjectrace/CMakeLists.txt b/tests/auto/other/qobjectrace/CMakeLists.txt
new file mode 100644
index 0000000000..972fdcfcac
--- /dev/null
+++ b/tests/auto/other/qobjectrace/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qobjectrace.pro.
+
+#####################################################################
+## qobjectrace Test:
+#####################################################################
+
+add_qt_test(qobjectrace
+ SOURCES
+ ../../../shared/emulationdetector.h
+ tst_qobjectrace.cpp
+ INCLUDE_DIRECTORIES
+ ../../../shared
+)
diff --git a/tests/auto/other/qprocess_and_guieventloop/CMakeLists.txt b/tests/auto/other/qprocess_and_guieventloop/CMakeLists.txt
new file mode 100644
index 0000000000..ccc2c55c13
--- /dev/null
+++ b/tests/auto/other/qprocess_and_guieventloop/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qprocess_and_guieventloop.pro.
+
+#####################################################################
+## tst_qprocess_and_guieventloop Test:
+#####################################################################
+
+add_qt_test(tst_qprocess_and_guieventloop
+ SOURCES
+ tst_qprocess_and_guieventloop.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+add_subdirectory(write-read-write)
diff --git a/tests/auto/other/qprocess_and_guieventloop/write-read-write/CMakeLists.txt b/tests/auto/other/qprocess_and_guieventloop/write-read-write/CMakeLists.txt
new file mode 100644
index 0000000000..dfea85f3e3
--- /dev/null
+++ b/tests/auto/other/qprocess_and_guieventloop/write-read-write/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from write-read-write.pro.
+
+#####################################################################
+## write-read-write Binary:
+#####################################################################
+
+add_qt_executable(write-read-write
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/other/qsharedpointer_and_qwidget/CMakeLists.txt b/tests/auto/other/qsharedpointer_and_qwidget/CMakeLists.txt
new file mode 100644
index 0000000000..5175bb68fe
--- /dev/null
+++ b/tests/auto/other/qsharedpointer_and_qwidget/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qsharedpointer_and_qwidget.pro.
+
+#####################################################################
+## tst_qsharedpointer_and_qwidget Test:
+#####################################################################
+
+add_qt_test(tst_qsharedpointer_and_qwidget
+ SOURCES
+ tst_qsharedpointer_and_qwidget.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/other/qtokenautomaton/CMakeLists.txt b/tests/auto/other/qtokenautomaton/CMakeLists.txt
new file mode 100644
index 0000000000..f495ddb1c6
--- /dev/null
+++ b/tests/auto/other/qtokenautomaton/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qtokenautomaton.pro.
+
+#####################################################################
+## tst_qtokenautomaton Test:
+#####################################################################
+
+add_qt_test(tst_qtokenautomaton
+ SOURCES
+ tokenizers/basic/basic.cpp tokenizers/basic/basic.h
+ tokenizers/basicNamespace/basicNamespace.cpp tokenizers/basicNamespace/basicNamespace.h
+ tokenizers/boilerplate/boilerplate.cpp tokenizers/boilerplate/boilerplate.h
+ tokenizers/noNamespace/noNamespace.cpp tokenizers/noNamespace/noNamespace.h
+ tokenizers/noToString/noToString.cpp tokenizers/noToString/noToString.h
+ tokenizers/withNamespace/withNamespace.cpp tokenizers/withNamespace/withNamespace.h
+ tst_qtokenautomaton.cpp
+)
diff --git a/tests/auto/other/toolsupport/CMakeLists.txt b/tests/auto/other/toolsupport/CMakeLists.txt
new file mode 100644
index 0000000000..ee170b3a77
--- /dev/null
+++ b/tests/auto/other/toolsupport/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from toolsupport.pro.
+
+#####################################################################
+## tst_toolsupport Test:
+#####################################################################
+
+add_qt_test(tst_toolsupport
+ SOURCES
+ tst_toolsupport.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/auto/other/xkbkeyboard/CMakeLists.txt b/tests/auto/other/xkbkeyboard/CMakeLists.txt
new file mode 100644
index 0000000000..fbbe5c67bb
--- /dev/null
+++ b/tests/auto/other/xkbkeyboard/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from xkbkeyboard.pro.
+
+#####################################################################
+## tst_xkbkeyboard Test:
+#####################################################################
+
+add_qt_test(tst_xkbkeyboard
+ SOURCES
+ tst_xkbkeyboard.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/printsupport/CMakeLists.txt b/tests/auto/printsupport/CMakeLists.txt
new file mode 100644
index 0000000000..633c7d5e71
--- /dev/null
+++ b/tests/auto/printsupport/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from printsupport.pro.
+
+add_subdirectory(dialogs)
+add_subdirectory(kernel)
diff --git a/tests/auto/printsupport/dialogs/CMakeLists.txt b/tests/auto/printsupport/dialogs/CMakeLists.txt
new file mode 100644
index 0000000000..548ddc8577
--- /dev/null
+++ b/tests/auto/printsupport/dialogs/CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from dialogs.pro.
+
+add_subdirectory(qabstractprintdialog)
diff --git a/tests/auto/printsupport/dialogs/qabstractprintdialog/CMakeLists.txt b/tests/auto/printsupport/dialogs/qabstractprintdialog/CMakeLists.txt
new file mode 100644
index 0000000000..91b699f648
--- /dev/null
+++ b/tests/auto/printsupport/dialogs/qabstractprintdialog/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qabstractprintdialog.pro.
+
+#####################################################################
+## tst_qabstractprintdialog Test:
+#####################################################################
+
+add_qt_test(tst_qabstractprintdialog
+ SOURCES
+ tst_qabstractprintdialog.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::PrintSupport
+ Qt::Widgets
+)
diff --git a/tests/auto/printsupport/kernel/CMakeLists.txt b/tests/auto/printsupport/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..8154d5e868
--- /dev/null
+++ b/tests/auto/printsupport/kernel/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from kernel.pro.
+
+add_subdirectory(qprintdevice)
+add_subdirectory(qprinter)
+add_subdirectory(qprinterinfo)
diff --git a/tests/auto/printsupport/kernel/qprintdevice/CMakeLists.txt b/tests/auto/printsupport/kernel/qprintdevice/CMakeLists.txt
new file mode 100644
index 0000000000..60a6016328
--- /dev/null
+++ b/tests/auto/printsupport/kernel/qprintdevice/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qprintdevice.pro.
+
+#####################################################################
+## tst_qprintdevice Test:
+#####################################################################
+
+add_qt_test(tst_qprintdevice
+ SOURCES
+ tst_qprintdevice.cpp
+ DEFINES
+ QT_USE_USING_NAMESPACE
+ LIBRARIES
+ Qt::PrintSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::PrintSupport
+)
diff --git a/tests/auto/printsupport/kernel/qprinter/CMakeLists.txt b/tests/auto/printsupport/kernel/qprinter/CMakeLists.txt
new file mode 100644
index 0000000000..6d15bab349
--- /dev/null
+++ b/tests/auto/printsupport/kernel/qprinter/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qprinter.pro.
+
+#####################################################################
+## tst_qprinter Test:
+#####################################################################
+
+add_qt_test(tst_qprinter
+ SOURCES
+ tst_qprinter.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::PrintSupport
+ Qt::Widgets
+)
diff --git a/tests/auto/printsupport/kernel/qprinterinfo/CMakeLists.txt b/tests/auto/printsupport/kernel/qprinterinfo/CMakeLists.txt
new file mode 100644
index 0000000000..5923d57ef5
--- /dev/null
+++ b/tests/auto/printsupport/kernel/qprinterinfo/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qprinterinfo.pro.
+
+#####################################################################
+## tst_qprinterinfo Test:
+#####################################################################
+
+add_qt_test(tst_qprinterinfo
+ SOURCES
+ tst_qprinterinfo.cpp
+ DEFINES
+ QT_USE_USING_NAMESPACE
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::PrintSupport
+)
diff --git a/tests/auto/sql/CMakeLists.txt b/tests/auto/sql/CMakeLists.txt
new file mode 100644
index 0000000000..415d7598ae
--- /dev/null
+++ b/tests/auto/sql/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from sql.pro.
+
+add_subdirectory(kernel)
+add_subdirectory(models)
diff --git a/tests/auto/sql/kernel/CMakeLists.txt b/tests/auto/sql/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..8d3f0b6bc5
--- /dev/null
+++ b/tests/auto/sql/kernel/CMakeLists.txt
@@ -0,0 +1,9 @@
+add_subdirectory(qsqlfield)
+add_subdirectory(qsqldatabase)
+add_subdirectory(qsqlerror)
+add_subdirectory(qsqldriver)
+add_subdirectory(qsqlquery)
+add_subdirectory(qsqlrecord)
+add_subdirectory(qsqlthread)
+add_subdirectory(qsql)
+add_subdirectory(qsqlresult)
diff --git a/tests/auto/sql/kernel/qsql/CMakeLists.txt b/tests/auto/sql/kernel/qsql/CMakeLists.txt
new file mode 100644
index 0000000000..88c2d9ee3c
--- /dev/null
+++ b/tests/auto/sql/kernel/qsql/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qsql.pro.
+
+#####################################################################
+## tst_qsql Test:
+#####################################################################
+
+add_qt_test(tst_qsql
+ SOURCES
+ tst_qsql.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Qt::Sql
+)
diff --git a/tests/auto/sql/kernel/qsqldatabase/CMakeLists.txt b/tests/auto/sql/kernel/qsqldatabase/CMakeLists.txt
new file mode 100644
index 0000000000..ad0cefa460
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqldatabase/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qsqldatabase.pro.
+
+#####################################################################
+## tst_qsqldatabase Test:
+#####################################################################
+
+add_qt_test(tst_qsqldatabase
+ SOURCES
+ tst_qsqldatabase.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Qt::Sql
+)
diff --git a/tests/auto/sql/kernel/qsqldriver/CMakeLists.txt b/tests/auto/sql/kernel/qsqldriver/CMakeLists.txt
new file mode 100644
index 0000000000..a59ee08ea7
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqldriver/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qsqldriver.pro.
+
+#####################################################################
+## tst_qsqldriver Test:
+#####################################################################
+
+add_qt_test(tst_qsqldriver
+ SOURCES
+ tst_qsqldriver.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Qt::Sql
+)
diff --git a/tests/auto/sql/kernel/qsqlerror/CMakeLists.txt b/tests/auto/sql/kernel/qsqlerror/CMakeLists.txt
new file mode 100644
index 0000000000..45e7bb383b
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqlerror/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qsqlerror.pro.
+
+#####################################################################
+## tst_qsqlerror Test:
+#####################################################################
+
+add_qt_test(tst_qsqlerror
+ SOURCES
+ tst_qsqlerror.cpp
+ PUBLIC_LIBRARIES
+ Qt::Sql
+)
diff --git a/tests/auto/sql/kernel/qsqlfield/CMakeLists.txt b/tests/auto/sql/kernel/qsqlfield/CMakeLists.txt
new file mode 100644
index 0000000000..0a570ed1f2
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqlfield/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qsqlfield.pro.
+
+#####################################################################
+## tst_qsqlfield Test:
+#####################################################################
+
+add_qt_test(tst_qsqlfield
+ SOURCES
+ tst_qsqlfield.cpp
+ PUBLIC_LIBRARIES
+ Qt::Sql
+)
diff --git a/tests/auto/sql/kernel/qsqlquery/CMakeLists.txt b/tests/auto/sql/kernel/qsqlquery/CMakeLists.txt
new file mode 100644
index 0000000000..dd7703b401
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqlquery/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qsqlquery.pro.
+
+#####################################################################
+## tst_qsqlquery Test:
+#####################################################################
+
+add_qt_test(tst_qsqlquery
+ SOURCES
+ tst_qsqlquery.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Qt::Sql
+)
diff --git a/tests/auto/sql/kernel/qsqlrecord/CMakeLists.txt b/tests/auto/sql/kernel/qsqlrecord/CMakeLists.txt
new file mode 100644
index 0000000000..743dc27e9d
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqlrecord/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qsqlrecord.pro.
+
+#####################################################################
+## tst_qsqlrecord Test:
+#####################################################################
+
+add_qt_test(tst_qsqlrecord
+ SOURCES
+ tst_qsqlrecord.cpp
+ PUBLIC_LIBRARIES
+ Qt::Sql
+)
diff --git a/tests/auto/sql/kernel/qsqlresult/CMakeLists.txt b/tests/auto/sql/kernel/qsqlresult/CMakeLists.txt
new file mode 100644
index 0000000000..91762a0f6c
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqlresult/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qsqlresult.pro.
+
+#####################################################################
+## tst_qsqlresult Test:
+#####################################################################
+
+add_qt_test(tst_qsqlresult
+ SOURCES
+ testsqldriver.h
+ tst_qsqlresult.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Qt::Sql
+)
diff --git a/tests/auto/sql/kernel/qsqlthread/CMakeLists.txt b/tests/auto/sql/kernel/qsqlthread/CMakeLists.txt
new file mode 100644
index 0000000000..793e8c7fd5
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqlthread/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qsqlthread.pro.
+
+#####################################################################
+## tst_qsqlthread Test:
+#####################################################################
+
+add_qt_test(tst_qsqlthread
+ SOURCES
+ tst_qsqlthread.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Qt::Sql
+)
diff --git a/tests/auto/sql/models/CMakeLists.txt b/tests/auto/sql/models/CMakeLists.txt
new file mode 100644
index 0000000000..df530443c4
--- /dev/null
+++ b/tests/auto/sql/models/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_subdirectory(qsqlrelationaltablemodel)
+add_subdirectory(qsqltablemodel)
+
+if(TARGET Qt::Widgets)
+ add_subdirectory(qsqlquerymodel)
+endif()
diff --git a/tests/auto/sql/models/qsqlquerymodel/CMakeLists.txt b/tests/auto/sql/models/qsqlquerymodel/CMakeLists.txt
new file mode 100644
index 0000000000..1c8a2372b6
--- /dev/null
+++ b/tests/auto/sql/models/qsqlquerymodel/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qsqlquerymodel.pro.
+
+#####################################################################
+## tst_qsqlquerymodel Test:
+#####################################################################
+
+add_qt_test(tst_qsqlquerymodel
+ SOURCES
+ tst_qsqlquerymodel.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Sql
+ Qt::Widgets
+)
diff --git a/tests/auto/sql/models/qsqlrelationaldelegate/CMakeLists.txt b/tests/auto/sql/models/qsqlrelationaldelegate/CMakeLists.txt
new file mode 100644
index 0000000000..979d3a4f43
--- /dev/null
+++ b/tests/auto/sql/models/qsqlrelationaldelegate/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qsqlrelationaldelegate.pro.
+
+#####################################################################
+## tst_qsqlrelationaldelegate Test:
+#####################################################################
+
+add_qt_test(tst_qsqlrelationaldelegate
+ SOURCES
+ tst_qsqlrelationaldelegate.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Qt::Sql
+ Qt::Widgets
+)
diff --git a/tests/auto/sql/models/qsqlrelationaltablemodel/CMakeLists.txt b/tests/auto/sql/models/qsqlrelationaltablemodel/CMakeLists.txt
new file mode 100644
index 0000000000..2dea59b79d
--- /dev/null
+++ b/tests/auto/sql/models/qsqlrelationaltablemodel/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qsqlrelationaltablemodel.pro.
+
+#####################################################################
+## tst_qsqlrelationaltablemodel Test:
+#####################################################################
+
+add_qt_test(tst_qsqlrelationaltablemodel
+ SOURCES
+ tst_qsqlrelationaltablemodel.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Qt::Sql
+)
diff --git a/tests/auto/sql/models/qsqltablemodel/CMakeLists.txt b/tests/auto/sql/models/qsqltablemodel/CMakeLists.txt
new file mode 100644
index 0000000000..a251847181
--- /dev/null
+++ b/tests/auto/sql/models/qsqltablemodel/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qsqltablemodel.pro.
+
+#####################################################################
+## tst_qsqltablemodel Test:
+#####################################################################
+
+add_qt_test(tst_qsqltablemodel
+ SOURCES
+ tst_qsqltablemodel.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Qt::Sql
+)
diff --git a/tests/auto/testlib/.prev_CMakeLists.txt b/tests/auto/testlib/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..194852f91c
--- /dev/null
+++ b/tests/auto/testlib/.prev_CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from testlib.pro.
+
+add_subdirectory(outformat)
+add_subdirectory(qsignalspy)
+add_subdirectory(selftests)
+if(TARGET Qt::Widgets)
+ add_subdirectory(qabstractitemmodeltester)
+endif()
diff --git a/tests/auto/testlib/CMakeLists.txt b/tests/auto/testlib/CMakeLists.txt
new file mode 100644
index 0000000000..fe80927327
--- /dev/null
+++ b/tests/auto/testlib/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from testlib.pro.
+
+# add_subdirectory(outformat) # special case missing project
+add_subdirectory(qsignalspy)
+add_subdirectory(selftests)
+if(TARGET Qt::Widgets)
+ add_subdirectory(qabstractitemmodeltester)
+endif()
diff --git a/tests/auto/testlib/qabstractitemmodeltester/CMakeLists.txt b/tests/auto/testlib/qabstractitemmodeltester/CMakeLists.txt
new file mode 100644
index 0000000000..c4c9b7d044
--- /dev/null
+++ b/tests/auto/testlib/qabstractitemmodeltester/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qabstractitemmodeltester.pro.
+
+#####################################################################
+## qabstractitemmodeltester Test:
+#####################################################################
+
+add_qt_test(qabstractitemmodeltester
+ SOURCES
+ ../../other/qabstractitemmodelutils/dynamictreemodel.cpp ../../other/qabstractitemmodelutils/dynamictreemodel.h
+ tst_qabstractitemmodeltester.cpp
+ INCLUDE_DIRECTORIES
+ ../../other/qabstractitemmodelutils
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/testlib/qsignalspy/CMakeLists.txt b/tests/auto/testlib/qsignalspy/CMakeLists.txt
new file mode 100644
index 0000000000..b3832d44fa
--- /dev/null
+++ b/tests/auto/testlib/qsignalspy/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qsignalspy.pro.
+
+#####################################################################
+## tst_qsignalspy Test:
+#####################################################################
+
+add_qt_test(tst_qsignalspy
+ SOURCES
+ tst_qsignalspy.cpp
+)
diff --git a/tests/auto/testlib/selftests/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..124d2a60a0
--- /dev/null
+++ b/tests/auto/testlib/selftests/.prev_CMakeLists.txt
@@ -0,0 +1,9 @@
+# Generated from selftests.pro.
+
+add_subdirectory(test)
+
+if(NOT WINRT)
+
+ if(TARGET Qt::Gui)
+ endif()
+endif()
diff --git a/tests/auto/testlib/selftests/CMakeLists.txt b/tests/auto/testlib/selftests/CMakeLists.txt
new file mode 100644
index 0000000000..6b7fdb0d53
--- /dev/null
+++ b/tests/auto/testlib/selftests/CMakeLists.txt
@@ -0,0 +1,411 @@
+# Generated from selftests.pro.
+
+# special case begin
+# The whole file is written manually.
+
+if(NOT WINRT)
+ add_subdirectory(assert)
+ add_subdirectory(badxml)
+ add_subdirectory(benchlibcallgrind)
+ add_subdirectory(benchlibcounting)
+ add_subdirectory(benchlibeventcounter)
+ add_subdirectory(benchliboptions)
+ add_subdirectory(benchlibtickcounter)
+ add_subdirectory(benchlibwalltime)
+ add_subdirectory(blacklisted)
+ add_subdirectory(cmptest)
+ add_subdirectory(commandlinedata)
+ add_subdirectory(counting)
+ add_subdirectory(crashes)
+ add_subdirectory(datatable)
+ add_subdirectory(datetime)
+ add_subdirectory(deleteLater)
+ add_subdirectory(deleteLater_noApp)
+ add_subdirectory(differentexec)
+ add_subdirectory(exceptionthrow)
+ add_subdirectory(expectfail)
+ add_subdirectory(failcleanup)
+ add_subdirectory(faildatatype)
+ add_subdirectory(failfetchtype)
+ add_subdirectory(failinit)
+ add_subdirectory(failinitdata)
+ add_subdirectory(fetchbogus)
+ add_subdirectory(findtestdata)
+ add_subdirectory(float)
+ add_subdirectory(globaldata)
+ add_subdirectory(longstring)
+ add_subdirectory(maxwarnings)
+ add_subdirectory(multiexec)
+ add_subdirectory(pairdiagnostics)
+ add_subdirectory(printdatatags)
+ add_subdirectory(printdatatagswithglobaltags)
+ add_subdirectory(qexecstringlist)
+ add_subdirectory(silent)
+ add_subdirectory(signaldumper)
+ add_subdirectory(singleskip)
+ add_subdirectory(skip)
+ add_subdirectory(skipcleanup)
+ add_subdirectory(skipinit)
+ add_subdirectory(skipinitdata)
+ add_subdirectory(sleep)
+ add_subdirectory(strcmp)
+ add_subdirectory(subtest)
+ add_subdirectory(testlib)
+ add_subdirectory(tuplediagnostics)
+ add_subdirectory(verbose1)
+ add_subdirectory(verbose2)
+ add_subdirectory(verifyexceptionthrown)
+ add_subdirectory(warnings)
+ add_subdirectory(watchdog)
+ add_subdirectory(xunit)
+
+ if(TARGET Qt::Gui)
+ add_subdirectory(keyboard)
+ add_subdirectory(mouse)
+ endif()
+endif()
+
+#####################################################################
+## tst_selftests Test:
+#####################################################################
+
+add_qt_test(tst_selftests
+ SOURCES
+ ../../../shared/emulationdetector.h
+ tst_selftests.cpp
+ INCLUDE_DIRECTORIES
+ ../../../shared
+ LIBRARIES
+ Qt::TestPrivate
+)
+
+add_qt_resource(tst_selftests "expected_files" PREFIX "/" FILES
+ expected_assert.lightxml
+ expected_assert.tap
+ expected_assert.teamcity
+ expected_assert.txt
+ expected_assert.xml
+ expected_assert.xunitxml
+ expected_badxml.lightxml
+ expected_badxml.tap
+ expected_badxml.teamcity
+ expected_badxml.txt
+ expected_badxml.xml
+ expected_badxml.xunitxml
+ expected_benchlibcallgrind_0.txt
+ expected_benchlibcallgrind_1.txt
+ expected_benchlibcallgrind.csv
+ expected_benchlibcallgrind.lightxml
+ expected_benchlibcallgrind.tap
+ expected_benchlibcallgrind.teamcity
+ expected_benchlibcallgrind.xml
+ expected_benchlibcallgrind.xunitxml
+ expected_benchlibcounting.csv
+ expected_benchlibcounting.lightxml
+ expected_benchlibcounting.tap
+ expected_benchlibcounting.teamcity
+ expected_benchlibcounting.txt
+ expected_benchlibcounting.xml
+ expected_benchlibcounting.xunitxml
+ expected_benchlibeventcounter.csv
+ expected_benchlibeventcounter.lightxml
+ expected_benchlibeventcounter.tap
+ expected_benchlibeventcounter.teamcity
+ expected_benchlibeventcounter.txt
+ expected_benchlibeventcounter.xml
+ expected_benchlibeventcounter.xunitxml
+ expected_benchliboptions.csv
+ expected_benchliboptions.lightxml
+ expected_benchliboptions.tap
+ expected_benchliboptions.teamcity
+ expected_benchliboptions.txt
+ expected_benchliboptions.xml
+ expected_benchliboptions.xunitxml
+ expected_benchlibtickcounter.csv
+ expected_benchlibtickcounter.lightxml
+ expected_benchlibtickcounter.tap
+ expected_benchlibtickcounter.teamcity
+ expected_benchlibtickcounter.txt
+ expected_benchlibtickcounter.xml
+ expected_benchlibtickcounter.xunitxml
+ expected_benchlibwalltime.csv
+ expected_benchlibwalltime.lightxml
+ expected_benchlibwalltime.tap
+ expected_benchlibwalltime.teamcity
+ expected_benchlibwalltime.txt
+ expected_benchlibwalltime.xml
+ expected_benchlibwalltime.xunitxml
+ expected_blacklisted.lightxml
+ expected_blacklisted.tap
+ expected_blacklisted.teamcity
+ expected_blacklisted.txt
+ expected_blacklisted.xml
+ expected_blacklisted.xunitxml
+ expected_cmptest.lightxml
+ expected_cmptest.tap
+ expected_cmptest.teamcity
+ expected_cmptest.txt
+ expected_cmptest.xml
+ expected_cmptest.xunitxml
+ expected_commandlinedata.lightxml
+ expected_commandlinedata.tap
+ expected_commandlinedata.teamcity
+ expected_commandlinedata.txt
+ expected_commandlinedata.xml
+ expected_commandlinedata.xunitxml
+ expected_counting.lightxml
+ expected_counting.tap
+ expected_counting.teamcity
+ expected_counting.txt
+ expected_counting.xml
+ expected_counting.xunitxml
+ expected_crashes_1.txt
+ expected_crashes_2.txt
+ expected_crashes_3.txt
+ expected_crashes_4.txt
+ expected_crashes_5.txt
+ expected_datatable.lightxml
+ expected_datatable.tap
+ expected_datatable.teamcity
+ expected_datatable.txt
+ expected_datatable.xml
+ expected_datatable.xunitxml
+ expected_datetime.lightxml
+ expected_datetime.tap
+ expected_datetime.teamcity
+ expected_datetime.txt
+ expected_datetime.xml
+ expected_datetime.xunitxml
+ expected_differentexec.lightxml
+ expected_differentexec.tap
+ expected_differentexec.teamcity
+ expected_differentexec.txt
+ expected_differentexec.xml
+ expected_differentexec.xunitxml
+ expected_exceptionthrow.lightxml
+ expected_exceptionthrow.tap
+ expected_exceptionthrow.teamcity
+ expected_exceptionthrow.txt
+ expected_exceptionthrow.xml
+ expected_exceptionthrow.xunitxml
+ expected_expectfail.lightxml
+ expected_expectfail.tap
+ expected_expectfail.teamcity
+ expected_expectfail.txt
+ expected_expectfail.xml
+ expected_expectfail.xunitxml
+ expected_failcleanup.lightxml
+ expected_failcleanup.tap
+ expected_failcleanup.teamcity
+ expected_failcleanup.txt
+ expected_failcleanup.xml
+ expected_failcleanup.xunitxml
+ expected_faildatatype.lightxml
+ expected_faildatatype.tap
+ expected_faildatatype.teamcity
+ expected_faildatatype.txt
+ expected_faildatatype.xml
+ expected_faildatatype.xunitxml
+ expected_failfetchtype.lightxml
+ expected_failfetchtype.tap
+ expected_failfetchtype.teamcity
+ expected_failfetchtype.txt
+ expected_failfetchtype.xml
+ expected_failfetchtype.xunitxml
+ expected_failinitdata.lightxml
+ expected_failinitdata.tap
+ expected_failinitdata.teamcity
+ expected_failinitdata.txt
+ expected_failinitdata.xml
+ expected_failinitdata.xunitxml
+ expected_failinit.lightxml
+ expected_failinit.tap
+ expected_failinit.teamcity
+ expected_failinit.txt
+ expected_failinit.xml
+ expected_failinit.xunitxml
+ expected_fetchbogus.lightxml
+ expected_fetchbogus.tap
+ expected_fetchbogus.teamcity
+ expected_fetchbogus.txt
+ expected_fetchbogus.xml
+ expected_fetchbogus.xunitxml
+ expected_findtestdata.lightxml
+ expected_findtestdata.tap
+ expected_findtestdata.teamcity
+ expected_findtestdata.txt
+ expected_findtestdata.xml
+ expected_findtestdata.xunitxml
+ expected_float.lightxml
+ expected_float.tap
+ expected_float.teamcity
+ expected_float.txt
+ expected_float.xml
+ expected_float.xunitxml
+ expected_globaldata.lightxml
+ expected_globaldata.tap
+ expected_globaldata.teamcity
+ expected_globaldata.txt
+ expected_globaldata.xml
+ expected_globaldata.xunitxml
+ expected_keyboard.lightxml
+ expected_keyboard.tap
+ expected_keyboard.teamcity
+ expected_keyboard.txt
+ expected_keyboard.xml
+ expected_keyboard.xunitxml
+ expected_longstring.lightxml
+ expected_longstring.tap
+ expected_longstring.teamcity
+ expected_longstring.txt
+ expected_longstring.xml
+ expected_longstring.xunitxml
+ expected_maxwarnings.lightxml
+ expected_maxwarnings.tap
+ expected_maxwarnings.teamcity
+ expected_maxwarnings.txt
+ expected_maxwarnings.xml
+ expected_maxwarnings.xunitxml
+ expected_multiexec.lightxml
+ expected_multiexec.tap
+ expected_multiexec.teamcity
+ expected_multiexec.txt
+ expected_multiexec.xml
+ expected_multiexec.xunitxml
+ expected_pairdiagnostics.lightxml
+ expected_pairdiagnostics.tap
+ expected_pairdiagnostics.teamcity
+ expected_pairdiagnostics.txt
+ expected_pairdiagnostics.xml
+ expected_pairdiagnostics.xunitxml
+ expected_printdatatags.txt
+ expected_printdatatagswithglobaltags.txt
+ expected_qexecstringlist.lightxml
+ expected_qexecstringlist.tap
+ expected_qexecstringlist.teamcity
+ expected_qexecstringlist.txt
+ expected_qexecstringlist.xml
+ expected_qexecstringlist.xunitxml
+ expected_signaldumper.lightxml
+ expected_signaldumper.tap
+ expected_signaldumper.teamcity
+ expected_signaldumper.txt
+ expected_signaldumper.xml
+ expected_signaldumper.xunitxml
+ expected_silent.lightxml
+ expected_silent.tap
+ expected_silent.teamcity
+ expected_silent.txt
+ expected_silent.xml
+ expected_silent.xunitxml
+ expected_singleskip.lightxml
+ expected_singleskip.tap
+ expected_singleskip.teamcity
+ expected_singleskip.txt
+ expected_singleskip.xml
+ expected_singleskip.xunitxml
+ expected_skipcleanup.lightxml
+ expected_skipcleanup.tap
+ expected_skipcleanup.teamcity
+ expected_skipcleanup.txt
+ expected_skipcleanup.xml
+ expected_skipcleanup.xunitxml
+ expected_skipinitdata.lightxml
+ expected_skipinitdata.tap
+ expected_skipinitdata.teamcity
+ expected_skipinitdata.txt
+ expected_skipinitdata.xml
+ expected_skipinitdata.xunitxml
+ expected_skipinit.lightxml
+ expected_skipinit.tap
+ expected_skipinit.teamcity
+ expected_skipinit.txt
+ expected_skipinit.xml
+ expected_skipinit.xunitxml
+ expected_skip.lightxml
+ expected_skip.tap
+ expected_skip.teamcity
+ expected_skip.txt
+ expected_skip.xml
+ expected_skip.xunitxml
+ expected_sleep.lightxml
+ expected_sleep.tap
+ expected_sleep.teamcity
+ expected_sleep.txt
+ expected_sleep.xml
+ expected_sleep.xunitxml
+ expected_strcmp.lightxml
+ expected_strcmp.tap
+ expected_strcmp.teamcity
+ expected_strcmp.txt
+ expected_strcmp.xml
+ expected_strcmp.xunitxml
+ expected_subtest.lightxml
+ expected_subtest.tap
+ expected_subtest.teamcity
+ expected_subtest.txt
+ expected_subtest.xml
+ expected_subtest.xunitxml
+ expected_testlib.lightxml
+ expected_testlib.tap
+ expected_testlib.teamcity
+ expected_testlib.txt
+ expected_testlib.xml
+ expected_testlib.xunitxml
+ expected_tuplediagnostics.lightxml
+ expected_tuplediagnostics.tap
+ expected_tuplediagnostics.teamcity
+ expected_tuplediagnostics.txt
+ expected_tuplediagnostics.xml
+ expected_tuplediagnostics.xunitxml
+ expected_verbose1.lightxml
+ expected_verbose1.tap
+ expected_verbose1.teamcity
+ expected_verbose1.txt
+ expected_verbose1.xml
+ expected_verbose1.xunitxml
+ expected_verbose2.lightxml
+ expected_verbose2.tap
+ expected_verbose2.teamcity
+ expected_verbose2.txt
+ expected_verbose2.xml
+ expected_verbose2.xunitxml
+ expected_verifyexceptionthrown.lightxml
+ expected_verifyexceptionthrown.tap
+ expected_verifyexceptionthrown.teamcity
+ expected_verifyexceptionthrown.txt
+ expected_verifyexceptionthrown.xml
+ expected_verifyexceptionthrown.xunitxml
+ expected_warnings.lightxml
+ expected_warnings.tap
+ expected_warnings.teamcity
+ expected_warnings.txt
+ expected_warnings.xml
+ expected_warnings.xunitxml
+ expected_watchdog.lightxml
+ expected_watchdog.tap
+ expected_watchdog.teamcity
+ expected_watchdog.txt
+ expected_watchdog.xml
+ expected_watchdog.xunitxml
+ expected_xunit.lightxml
+ expected_xunit.tap
+ expected_xunit.teamcity
+ expected_xunit.txt
+ expected_xunit.xml
+ expected_xunit.xunitxml
+)
+
+
+#### Keys ignored in scope 1:.:.:test.pro:<TRUE>:
+# CONFIG = "testcase"
+# expected_files.base = "$$PWD/.."
+# expected_files.files = "$$files$$PWD/../expected_*"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 5:.:.:test.pro:NOT ANDROID AND NOT WINRT AND for(file,SUBPROGRAMS):
+# TEST_HELPER_INSTALLS = "../$${file}/$${file}"
+
+# special case end
diff --git a/tests/auto/testlib/selftests/assert/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/assert/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..65ef6ac126
--- /dev/null
+++ b/tests/auto/testlib/selftests/assert/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from assert.pro.
+
+#####################################################################
+## assert Binary:
+#####################################################################
+
+add_qt_executable(assert
+ SOURCES
+ tst_assert.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/assert/CMakeLists.txt b/tests/auto/testlib/selftests/assert/CMakeLists.txt
new file mode 100644
index 0000000000..a2904beb96
--- /dev/null
+++ b/tests/auto/testlib/selftests/assert/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from assert.pro.
+
+#####################################################################
+## assert Binary:
+#####################################################################
+
+add_qt_executable(assert
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_assert.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/badxml/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/badxml/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..7840ba51ba
--- /dev/null
+++ b/tests/auto/testlib/selftests/badxml/.prev_CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from badxml.pro.
+
+#####################################################################
+## badxml Binary:
+#####################################################################
+
+add_qt_executable(badxml
+ SOURCES
+ tst_badxml.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/badxml/CMakeLists.txt b/tests/auto/testlib/selftests/badxml/CMakeLists.txt
new file mode 100644
index 0000000000..c26edd4d08
--- /dev/null
+++ b/tests/auto/testlib/selftests/badxml/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from badxml.pro.
+
+#####################################################################
+## badxml Binary:
+#####################################################################
+
+add_qt_executable(badxml
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_badxml.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/benchlibcallgrind/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/benchlibcallgrind/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..d6f35cd1de
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibcallgrind/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from benchlibcallgrind.pro.
+
+#####################################################################
+## benchlibcallgrind Binary:
+#####################################################################
+
+add_qt_executable(benchlibcallgrind
+ SOURCES
+ tst_benchlibcallgrind.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/benchlibcallgrind/CMakeLists.txt b/tests/auto/testlib/selftests/benchlibcallgrind/CMakeLists.txt
new file mode 100644
index 0000000000..230d11e391
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibcallgrind/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from benchlibcallgrind.pro.
+
+#####################################################################
+## benchlibcallgrind Binary:
+#####################################################################
+
+add_qt_executable(benchlibcallgrind
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_benchlibcallgrind.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/benchlibcounting/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/benchlibcounting/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..6b592f7515
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibcounting/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from benchlibcounting.pro.
+
+#####################################################################
+## benchlibcounting Binary:
+#####################################################################
+
+add_qt_executable(benchlibcounting
+ SOURCES
+ tst_benchlibcounting.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/benchlibcounting/CMakeLists.txt b/tests/auto/testlib/selftests/benchlibcounting/CMakeLists.txt
new file mode 100644
index 0000000000..d89d5d8447
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibcounting/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from benchlibcounting.pro.
+
+#####################################################################
+## benchlibcounting Binary:
+#####################################################################
+
+add_qt_executable(benchlibcounting
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_benchlibcounting.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/benchlibeventcounter/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/benchlibeventcounter/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..a1c6d6711b
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibeventcounter/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from benchlibeventcounter.pro.
+
+#####################################################################
+## benchlibeventcounter Binary:
+#####################################################################
+
+add_qt_executable(benchlibeventcounter
+ SOURCES
+ tst_benchlibeventcounter.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/benchlibeventcounter/CMakeLists.txt b/tests/auto/testlib/selftests/benchlibeventcounter/CMakeLists.txt
new file mode 100644
index 0000000000..701d3f12fb
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibeventcounter/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from benchlibeventcounter.pro.
+
+#####################################################################
+## benchlibeventcounter Binary:
+#####################################################################
+
+add_qt_executable(benchlibeventcounter
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_benchlibeventcounter.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/benchliboptions/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/benchliboptions/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..d38392c896
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchliboptions/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from benchliboptions.pro.
+
+#####################################################################
+## benchliboptions Binary:
+#####################################################################
+
+add_qt_executable(benchliboptions
+ SOURCES
+ tst_benchliboptions.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/benchliboptions/CMakeLists.txt b/tests/auto/testlib/selftests/benchliboptions/CMakeLists.txt
new file mode 100644
index 0000000000..b2a704cc28
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchliboptions/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from benchliboptions.pro.
+
+#####################################################################
+## benchliboptions Binary:
+#####################################################################
+
+add_qt_executable(benchliboptions
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_benchliboptions.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/benchlibtickcounter/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/benchlibtickcounter/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..285f614f4a
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibtickcounter/.prev_CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from benchlibtickcounter.pro.
+
+#####################################################################
+## benchlibtickcounter Binary:
+#####################################################################
+
+add_qt_executable(benchlibtickcounter
+ GUI
+ SOURCES
+ tst_benchlibtickcounter.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/benchlibtickcounter/CMakeLists.txt b/tests/auto/testlib/selftests/benchlibtickcounter/CMakeLists.txt
new file mode 100644
index 0000000000..9aba4104ac
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibtickcounter/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from benchlibtickcounter.pro.
+
+#####################################################################
+## benchlibtickcounter Binary:
+#####################################################################
+
+add_qt_executable(benchlibtickcounter
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ GUI
+ SOURCES
+ tst_benchlibtickcounter.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/benchlibwalltime/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/benchlibwalltime/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..0e098ace32
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibwalltime/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from benchlibwalltime.pro.
+
+#####################################################################
+## benchlibwalltime Binary:
+#####################################################################
+
+add_qt_executable(benchlibwalltime
+ SOURCES
+ tst_benchlibwalltime.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/benchlibwalltime/CMakeLists.txt b/tests/auto/testlib/selftests/benchlibwalltime/CMakeLists.txt
new file mode 100644
index 0000000000..7debe80c67
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibwalltime/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from benchlibwalltime.pro.
+
+#####################################################################
+## benchlibwalltime Binary:
+#####################################################################
+
+add_qt_executable(benchlibwalltime
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_benchlibwalltime.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/blacklisted/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/blacklisted/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..322b85fd08
--- /dev/null
+++ b/tests/auto/testlib/selftests/blacklisted/.prev_CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from blacklisted.pro.
+
+#####################################################################
+## blacklisted Binary:
+#####################################################################
+
+add_qt_executable(blacklisted
+ GUI
+ SOURCES
+ tst_blacklisted.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/blacklisted/CMakeLists.txt b/tests/auto/testlib/selftests/blacklisted/CMakeLists.txt
new file mode 100644
index 0000000000..a828d628ba
--- /dev/null
+++ b/tests/auto/testlib/selftests/blacklisted/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from blacklisted.pro.
+
+#####################################################################
+## blacklisted Binary:
+#####################################################################
+
+add_qt_executable(blacklisted
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ GUI
+ SOURCES
+ tst_blacklisted.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/cmptest/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/cmptest/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..417b99571d
--- /dev/null
+++ b/tests/auto/testlib/selftests/cmptest/.prev_CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from cmptest.pro.
+
+#####################################################################
+## cmptest Binary:
+#####################################################################
+
+add_qt_executable(cmptest
+ SOURCES
+ tst_cmptest.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(cmptest CONDITION TARGET Qt::Gui
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/testlib/selftests/cmptest/CMakeLists.txt b/tests/auto/testlib/selftests/cmptest/CMakeLists.txt
new file mode 100644
index 0000000000..b7698c78f7
--- /dev/null
+++ b/tests/auto/testlib/selftests/cmptest/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from cmptest.pro.
+
+#####################################################################
+## cmptest Binary:
+#####################################################################
+
+add_qt_executable(cmptest
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_cmptest.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(cmptest CONDITION TARGET Qt::Gui
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/auto/testlib/selftests/commandlinedata/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/commandlinedata/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..a49902c26b
--- /dev/null
+++ b/tests/auto/testlib/selftests/commandlinedata/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from commandlinedata.pro.
+
+#####################################################################
+## commandlinedata Binary:
+#####################################################################
+
+add_qt_executable(commandlinedata
+ SOURCES
+ tst_commandlinedata.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/commandlinedata/CMakeLists.txt b/tests/auto/testlib/selftests/commandlinedata/CMakeLists.txt
new file mode 100644
index 0000000000..76ce86c9a0
--- /dev/null
+++ b/tests/auto/testlib/selftests/commandlinedata/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from commandlinedata.pro.
+
+#####################################################################
+## commandlinedata Binary:
+#####################################################################
+
+add_qt_executable(commandlinedata
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_commandlinedata.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/counting/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/counting/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..8ad3c38e88
--- /dev/null
+++ b/tests/auto/testlib/selftests/counting/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from counting.pro.
+
+#####################################################################
+## counting Binary:
+#####################################################################
+
+add_qt_executable(counting
+ SOURCES
+ tst_counting.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/counting/CMakeLists.txt b/tests/auto/testlib/selftests/counting/CMakeLists.txt
new file mode 100644
index 0000000000..5afeab937b
--- /dev/null
+++ b/tests/auto/testlib/selftests/counting/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from counting.pro.
+
+#####################################################################
+## counting Binary:
+#####################################################################
+
+add_qt_executable(counting
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_counting.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/crashes/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/crashes/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..2e54976ebc
--- /dev/null
+++ b/tests/auto/testlib/selftests/crashes/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from crashes.pro.
+
+#####################################################################
+## crashes Binary:
+#####################################################################
+
+add_qt_executable(crashes
+ SOURCES
+ tst_crashes.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/crashes/CMakeLists.txt b/tests/auto/testlib/selftests/crashes/CMakeLists.txt
new file mode 100644
index 0000000000..d1eeffd23c
--- /dev/null
+++ b/tests/auto/testlib/selftests/crashes/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from crashes.pro.
+
+#####################################################################
+## crashes Binary:
+#####################################################################
+
+add_qt_executable(crashes
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_crashes.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/datatable/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/datatable/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..fbe3bfca40
--- /dev/null
+++ b/tests/auto/testlib/selftests/datatable/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from datatable.pro.
+
+#####################################################################
+## datatable Binary:
+#####################################################################
+
+add_qt_executable(datatable
+ SOURCES
+ tst_datatable.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/datatable/CMakeLists.txt b/tests/auto/testlib/selftests/datatable/CMakeLists.txt
new file mode 100644
index 0000000000..cab1fed123
--- /dev/null
+++ b/tests/auto/testlib/selftests/datatable/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from datatable.pro.
+
+#####################################################################
+## datatable Binary:
+#####################################################################
+
+add_qt_executable(datatable
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_datatable.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/datetime/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/datetime/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..8f0bca0d89
--- /dev/null
+++ b/tests/auto/testlib/selftests/datetime/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from datetime.pro.
+
+#####################################################################
+## datetime Binary:
+#####################################################################
+
+add_qt_executable(datetime
+ SOURCES
+ tst_datetime.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/datetime/CMakeLists.txt b/tests/auto/testlib/selftests/datetime/CMakeLists.txt
new file mode 100644
index 0000000000..9c04c6f0b8
--- /dev/null
+++ b/tests/auto/testlib/selftests/datetime/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from datetime.pro.
+
+#####################################################################
+## datetime Binary:
+#####################################################################
+
+add_qt_executable(datetime
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_datetime.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/deleteLater/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/deleteLater/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..ce2187af0b
--- /dev/null
+++ b/tests/auto/testlib/selftests/deleteLater/.prev_CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from deleteLater.pro.
+
+#####################################################################
+## tst_deleteLater Binary:
+#####################################################################
+
+add_qt_executable(tst_deleteLater
+ SOURCES
+ tst_deleteLater.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/auto/testlib/selftests/deleteLater/CMakeLists.txt b/tests/auto/testlib/selftests/deleteLater/CMakeLists.txt
new file mode 100644
index 0000000000..78876a9dbb
--- /dev/null
+++ b/tests/auto/testlib/selftests/deleteLater/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from deleteLater.pro.
+
+#####################################################################
+## tst_deleteLater Binary:
+#####################################################################
+
+add_qt_executable(tst_deleteLater
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_deleteLater.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/auto/testlib/selftests/deleteLater_noApp/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/deleteLater_noApp/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..48be681cbd
--- /dev/null
+++ b/tests/auto/testlib/selftests/deleteLater_noApp/.prev_CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from deleteLater_noApp.pro.
+
+#####################################################################
+## tst_deleteLater_noApp Binary:
+#####################################################################
+
+add_qt_executable(tst_deleteLater_noApp
+ SOURCES
+ tst_deleteLater_noApp.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/auto/testlib/selftests/deleteLater_noApp/CMakeLists.txt b/tests/auto/testlib/selftests/deleteLater_noApp/CMakeLists.txt
new file mode 100644
index 0000000000..ddcd19e8e3
--- /dev/null
+++ b/tests/auto/testlib/selftests/deleteLater_noApp/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from deleteLater_noApp.pro.
+
+#####################################################################
+## tst_deleteLater_noApp Binary:
+#####################################################################
+
+add_qt_executable(tst_deleteLater_noApp
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_deleteLater_noApp.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/auto/testlib/selftests/differentexec/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/differentexec/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..9cab4de93b
--- /dev/null
+++ b/tests/auto/testlib/selftests/differentexec/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from differentexec.pro.
+
+#####################################################################
+## differentexec Binary:
+#####################################################################
+
+add_qt_executable(differentexec
+ SOURCES
+ tst_differentexec.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/differentexec/CMakeLists.txt b/tests/auto/testlib/selftests/differentexec/CMakeLists.txt
new file mode 100644
index 0000000000..e5f19c2677
--- /dev/null
+++ b/tests/auto/testlib/selftests/differentexec/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from differentexec.pro.
+
+#####################################################################
+## differentexec Binary:
+#####################################################################
+
+add_qt_executable(differentexec
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_differentexec.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/exceptionthrow/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/exceptionthrow/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..fdd95e0805
--- /dev/null
+++ b/tests/auto/testlib/selftests/exceptionthrow/.prev_CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from exceptionthrow.pro.
+
+#####################################################################
+## exceptionthrow Binary:
+#####################################################################
+
+add_qt_executable(exceptionthrow
+ EXCEPTIONS
+ SOURCES
+ tst_exceptionthrow.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/exceptionthrow/CMakeLists.txt b/tests/auto/testlib/selftests/exceptionthrow/CMakeLists.txt
new file mode 100644
index 0000000000..659e2e2ff3
--- /dev/null
+++ b/tests/auto/testlib/selftests/exceptionthrow/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from exceptionthrow.pro.
+
+#####################################################################
+## exceptionthrow Binary:
+#####################################################################
+
+add_qt_executable(exceptionthrow
+ EXCEPTIONS
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_exceptionthrow.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/expectfail/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/expectfail/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..175bd8129a
--- /dev/null
+++ b/tests/auto/testlib/selftests/expectfail/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from expectfail.pro.
+
+#####################################################################
+## expectfail Binary:
+#####################################################################
+
+add_qt_executable(expectfail
+ SOURCES
+ tst_expectfail.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/expectfail/CMakeLists.txt b/tests/auto/testlib/selftests/expectfail/CMakeLists.txt
new file mode 100644
index 0000000000..96de8c7a52
--- /dev/null
+++ b/tests/auto/testlib/selftests/expectfail/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from expectfail.pro.
+
+#####################################################################
+## expectfail Binary:
+#####################################################################
+
+add_qt_executable(expectfail
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_expectfail.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/failcleanup/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/failcleanup/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..6369874983
--- /dev/null
+++ b/tests/auto/testlib/selftests/failcleanup/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from failcleanup.pro.
+
+#####################################################################
+## failcleanup Binary:
+#####################################################################
+
+add_qt_executable(failcleanup
+ SOURCES
+ tst_failcleanup.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/failcleanup/CMakeLists.txt b/tests/auto/testlib/selftests/failcleanup/CMakeLists.txt
new file mode 100644
index 0000000000..6994b454b4
--- /dev/null
+++ b/tests/auto/testlib/selftests/failcleanup/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from failcleanup.pro.
+
+#####################################################################
+## failcleanup Binary:
+#####################################################################
+
+add_qt_executable(failcleanup
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_failcleanup.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/faildatatype/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/faildatatype/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..e03a4333bd
--- /dev/null
+++ b/tests/auto/testlib/selftests/faildatatype/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from faildatatype.pro.
+
+#####################################################################
+## faildatatype Binary:
+#####################################################################
+
+add_qt_executable(faildatatype
+ SOURCES
+ tst_faildatatype.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/faildatatype/CMakeLists.txt b/tests/auto/testlib/selftests/faildatatype/CMakeLists.txt
new file mode 100644
index 0000000000..0bcf274a89
--- /dev/null
+++ b/tests/auto/testlib/selftests/faildatatype/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from faildatatype.pro.
+
+#####################################################################
+## faildatatype Binary:
+#####################################################################
+
+add_qt_executable(faildatatype
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_faildatatype.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/failfetchtype/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/failfetchtype/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..6ab21d845f
--- /dev/null
+++ b/tests/auto/testlib/selftests/failfetchtype/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from failfetchtype.pro.
+
+#####################################################################
+## failfetchtype Binary:
+#####################################################################
+
+add_qt_executable(failfetchtype
+ SOURCES
+ tst_failfetchtype.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/failfetchtype/CMakeLists.txt b/tests/auto/testlib/selftests/failfetchtype/CMakeLists.txt
new file mode 100644
index 0000000000..f0d2657be1
--- /dev/null
+++ b/tests/auto/testlib/selftests/failfetchtype/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from failfetchtype.pro.
+
+#####################################################################
+## failfetchtype Binary:
+#####################################################################
+
+add_qt_executable(failfetchtype
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_failfetchtype.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/failinit/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/failinit/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..22817fa186
--- /dev/null
+++ b/tests/auto/testlib/selftests/failinit/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from failinit.pro.
+
+#####################################################################
+## failinit Binary:
+#####################################################################
+
+add_qt_executable(failinit
+ SOURCES
+ tst_failinit.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/failinit/CMakeLists.txt b/tests/auto/testlib/selftests/failinit/CMakeLists.txt
new file mode 100644
index 0000000000..8eeaa38d20
--- /dev/null
+++ b/tests/auto/testlib/selftests/failinit/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from failinit.pro.
+
+#####################################################################
+## failinit Binary:
+#####################################################################
+
+add_qt_executable(failinit
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_failinit.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/failinitdata/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/failinitdata/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..5d519c9196
--- /dev/null
+++ b/tests/auto/testlib/selftests/failinitdata/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from failinitdata.pro.
+
+#####################################################################
+## failinitdata Binary:
+#####################################################################
+
+add_qt_executable(failinitdata
+ SOURCES
+ tst_failinitdata.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/failinitdata/CMakeLists.txt b/tests/auto/testlib/selftests/failinitdata/CMakeLists.txt
new file mode 100644
index 0000000000..1d62d62234
--- /dev/null
+++ b/tests/auto/testlib/selftests/failinitdata/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from failinitdata.pro.
+
+#####################################################################
+## failinitdata Binary:
+#####################################################################
+
+add_qt_executable(failinitdata
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_failinitdata.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/fetchbogus/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/fetchbogus/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..af1ea19d32
--- /dev/null
+++ b/tests/auto/testlib/selftests/fetchbogus/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from fetchbogus.pro.
+
+#####################################################################
+## fetchbogus Binary:
+#####################################################################
+
+add_qt_executable(fetchbogus
+ SOURCES
+ tst_fetchbogus.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/fetchbogus/CMakeLists.txt b/tests/auto/testlib/selftests/fetchbogus/CMakeLists.txt
new file mode 100644
index 0000000000..60c06b3410
--- /dev/null
+++ b/tests/auto/testlib/selftests/fetchbogus/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from fetchbogus.pro.
+
+#####################################################################
+## fetchbogus Binary:
+#####################################################################
+
+add_qt_executable(fetchbogus
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_fetchbogus.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/findtestdata/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/findtestdata/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..dc21a4d25f
--- /dev/null
+++ b/tests/auto/testlib/selftests/findtestdata/.prev_CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from findtestdata.pro.
+
+#####################################################################
+## findtestdata Binary:
+#####################################################################
+
+add_qt_executable(findtestdata
+ SOURCES
+ findtestdata.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+# Resources:
+set(findtestdata_resource_files
+ "qt.conf"
+)
+
+add_qt_resource(findtestdata "findtestdata"
+ PREFIX
+ "/qt/etc/"
+ FILES
+ ${findtestdata_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/findtestdata/CMakeLists.txt b/tests/auto/testlib/selftests/findtestdata/CMakeLists.txt
new file mode 100644
index 0000000000..f4987f88a3
--- /dev/null
+++ b/tests/auto/testlib/selftests/findtestdata/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from findtestdata.pro.
+
+#####################################################################
+## findtestdata Binary:
+#####################################################################
+
+add_qt_executable(findtestdata
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ findtestdata.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+# Resources:
+set(findtestdata_resource_files
+ "qt.conf"
+)
+
+add_qt_resource(findtestdata "findtestdata"
+ PREFIX
+ "/qt/etc/"
+ FILES
+ ${findtestdata_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/float/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/float/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..c037179b74
--- /dev/null
+++ b/tests/auto/testlib/selftests/float/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from float.pro.
+
+#####################################################################
+## float Binary:
+#####################################################################
+
+add_qt_executable(float
+ SOURCES
+ tst_float.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/float/CMakeLists.txt b/tests/auto/testlib/selftests/float/CMakeLists.txt
new file mode 100644
index 0000000000..8a2ee4b76d
--- /dev/null
+++ b/tests/auto/testlib/selftests/float/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from float.pro.
+
+#####################################################################
+## float Binary:
+#####################################################################
+
+add_qt_executable(float
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_float.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/globaldata/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/globaldata/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..1cff8f1b27
--- /dev/null
+++ b/tests/auto/testlib/selftests/globaldata/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from globaldata.pro.
+
+#####################################################################
+## globaldata Binary:
+#####################################################################
+
+add_qt_executable(globaldata
+ SOURCES
+ tst_globaldata.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/globaldata/CMakeLists.txt b/tests/auto/testlib/selftests/globaldata/CMakeLists.txt
new file mode 100644
index 0000000000..868a637588
--- /dev/null
+++ b/tests/auto/testlib/selftests/globaldata/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from globaldata.pro.
+
+#####################################################################
+## globaldata Binary:
+#####################################################################
+
+add_qt_executable(globaldata
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_globaldata.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/keyboard/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/keyboard/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..e45839faee
--- /dev/null
+++ b/tests/auto/testlib/selftests/keyboard/.prev_CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from keyboard.pro.
+
+#####################################################################
+## keyboard Binary:
+#####################################################################
+
+add_qt_executable(keyboard
+ SOURCES
+ tst_keyboard.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/keyboard/CMakeLists.txt b/tests/auto/testlib/selftests/keyboard/CMakeLists.txt
new file mode 100644
index 0000000000..4b98a88253
--- /dev/null
+++ b/tests/auto/testlib/selftests/keyboard/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from keyboard.pro.
+
+#####################################################################
+## keyboard Binary:
+#####################################################################
+
+add_qt_executable(keyboard
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_keyboard.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/longstring/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/longstring/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..9f1c6bc8ad
--- /dev/null
+++ b/tests/auto/testlib/selftests/longstring/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from longstring.pro.
+
+#####################################################################
+## longstring Binary:
+#####################################################################
+
+add_qt_executable(longstring
+ SOURCES
+ tst_longstring.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/longstring/CMakeLists.txt b/tests/auto/testlib/selftests/longstring/CMakeLists.txt
new file mode 100644
index 0000000000..08002fd20d
--- /dev/null
+++ b/tests/auto/testlib/selftests/longstring/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from longstring.pro.
+
+#####################################################################
+## longstring Binary:
+#####################################################################
+
+add_qt_executable(longstring
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_longstring.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/maxwarnings/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/maxwarnings/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..a05c9afb13
--- /dev/null
+++ b/tests/auto/testlib/selftests/maxwarnings/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from maxwarnings.pro.
+
+#####################################################################
+## maxwarnings Binary:
+#####################################################################
+
+add_qt_executable(maxwarnings
+ SOURCES
+ maxwarnings.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/maxwarnings/CMakeLists.txt b/tests/auto/testlib/selftests/maxwarnings/CMakeLists.txt
new file mode 100644
index 0000000000..23eaa62629
--- /dev/null
+++ b/tests/auto/testlib/selftests/maxwarnings/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from maxwarnings.pro.
+
+#####################################################################
+## maxwarnings Binary:
+#####################################################################
+
+add_qt_executable(maxwarnings
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ maxwarnings.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/mouse/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/mouse/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..0ba47c3b97
--- /dev/null
+++ b/tests/auto/testlib/selftests/mouse/.prev_CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from mouse.pro.
+
+#####################################################################
+## mouse Binary:
+#####################################################################
+
+add_qt_executable(mouse
+ SOURCES
+ tst_mouse.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/mouse/CMakeLists.txt b/tests/auto/testlib/selftests/mouse/CMakeLists.txt
new file mode 100644
index 0000000000..441569bd91
--- /dev/null
+++ b/tests/auto/testlib/selftests/mouse/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from mouse.pro.
+
+#####################################################################
+## mouse Binary:
+#####################################################################
+
+add_qt_executable(mouse
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_mouse.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/multiexec/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/multiexec/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..6c237edd05
--- /dev/null
+++ b/tests/auto/testlib/selftests/multiexec/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from multiexec.pro.
+
+#####################################################################
+## multiexec Binary:
+#####################################################################
+
+add_qt_executable(multiexec
+ SOURCES
+ tst_multiexec.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/multiexec/CMakeLists.txt b/tests/auto/testlib/selftests/multiexec/CMakeLists.txt
new file mode 100644
index 0000000000..a1174908e5
--- /dev/null
+++ b/tests/auto/testlib/selftests/multiexec/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from multiexec.pro.
+
+#####################################################################
+## multiexec Binary:
+#####################################################################
+
+add_qt_executable(multiexec
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_multiexec.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/pairdiagnostics/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/pairdiagnostics/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..05e8518413
--- /dev/null
+++ b/tests/auto/testlib/selftests/pairdiagnostics/.prev_CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from pairdiagnostics.pro.
+
+#####################################################################
+## pairdiagnostics Binary:
+#####################################################################
+
+add_qt_executable(pairdiagnostics
+ SOURCES
+ tst_pairdiagnostics.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/auto/testlib/selftests/pairdiagnostics/CMakeLists.txt b/tests/auto/testlib/selftests/pairdiagnostics/CMakeLists.txt
new file mode 100644
index 0000000000..a9a48fb3f2
--- /dev/null
+++ b/tests/auto/testlib/selftests/pairdiagnostics/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from pairdiagnostics.pro.
+
+#####################################################################
+## pairdiagnostics Binary:
+#####################################################################
+
+add_qt_executable(pairdiagnostics
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_pairdiagnostics.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/auto/testlib/selftests/printdatatags/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/printdatatags/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..8c9174ca44
--- /dev/null
+++ b/tests/auto/testlib/selftests/printdatatags/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from printdatatags.pro.
+
+#####################################################################
+## printdatatags Binary:
+#####################################################################
+
+add_qt_executable(printdatatags
+ SOURCES
+ tst_printdatatags.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/printdatatags/CMakeLists.txt b/tests/auto/testlib/selftests/printdatatags/CMakeLists.txt
new file mode 100644
index 0000000000..7eef1bce09
--- /dev/null
+++ b/tests/auto/testlib/selftests/printdatatags/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from printdatatags.pro.
+
+#####################################################################
+## printdatatags Binary:
+#####################################################################
+
+add_qt_executable(printdatatags
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_printdatatags.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/printdatatagswithglobaltags/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/printdatatagswithglobaltags/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..161051cec4
--- /dev/null
+++ b/tests/auto/testlib/selftests/printdatatagswithglobaltags/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from printdatatagswithglobaltags.pro.
+
+#####################################################################
+## printdatatagswithglobaltags Binary:
+#####################################################################
+
+add_qt_executable(printdatatagswithglobaltags
+ SOURCES
+ tst_printdatatagswithglobaltags.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/printdatatagswithglobaltags/CMakeLists.txt b/tests/auto/testlib/selftests/printdatatagswithglobaltags/CMakeLists.txt
new file mode 100644
index 0000000000..9baefbaabf
--- /dev/null
+++ b/tests/auto/testlib/selftests/printdatatagswithglobaltags/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from printdatatagswithglobaltags.pro.
+
+#####################################################################
+## printdatatagswithglobaltags Binary:
+#####################################################################
+
+add_qt_executable(printdatatagswithglobaltags
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_printdatatagswithglobaltags.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/qexecstringlist/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/qexecstringlist/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..2a33f2dc4d
--- /dev/null
+++ b/tests/auto/testlib/selftests/qexecstringlist/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qexecstringlist.pro.
+
+#####################################################################
+## qexecstringlist Binary:
+#####################################################################
+
+add_qt_executable(qexecstringlist
+ SOURCES
+ tst_qexecstringlist.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/qexecstringlist/CMakeLists.txt b/tests/auto/testlib/selftests/qexecstringlist/CMakeLists.txt
new file mode 100644
index 0000000000..a4aac7f924
--- /dev/null
+++ b/tests/auto/testlib/selftests/qexecstringlist/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qexecstringlist.pro.
+
+#####################################################################
+## qexecstringlist Binary:
+#####################################################################
+
+add_qt_executable(qexecstringlist
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_qexecstringlist.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/signaldumper/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/signaldumper/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..d7c26b804d
--- /dev/null
+++ b/tests/auto/testlib/selftests/signaldumper/.prev_CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from signaldumper.pro.
+
+#####################################################################
+## signaldumper Binary:
+#####################################################################
+
+add_qt_executable(signaldumper
+ GUI
+ SOURCES
+ tst_signaldumper.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/signaldumper/CMakeLists.txt b/tests/auto/testlib/selftests/signaldumper/CMakeLists.txt
new file mode 100644
index 0000000000..b431875722
--- /dev/null
+++ b/tests/auto/testlib/selftests/signaldumper/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from signaldumper.pro.
+
+#####################################################################
+## signaldumper Binary:
+#####################################################################
+
+add_qt_executable(signaldumper
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ GUI
+ SOURCES
+ tst_signaldumper.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/silent/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/silent/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..ec645eee97
--- /dev/null
+++ b/tests/auto/testlib/selftests/silent/.prev_CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from silent.pro.
+
+#####################################################################
+## silent Binary:
+#####################################################################
+
+add_qt_executable(silent
+ GUI
+ SOURCES
+ tst_silent.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/silent/CMakeLists.txt b/tests/auto/testlib/selftests/silent/CMakeLists.txt
new file mode 100644
index 0000000000..f02e38b75d
--- /dev/null
+++ b/tests/auto/testlib/selftests/silent/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from silent.pro.
+
+#####################################################################
+## silent Binary:
+#####################################################################
+
+add_qt_executable(silent
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ GUI
+ SOURCES
+ tst_silent.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/singleskip/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/singleskip/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..60d4984df8
--- /dev/null
+++ b/tests/auto/testlib/selftests/singleskip/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from singleskip.pro.
+
+#####################################################################
+## singleskip Binary:
+#####################################################################
+
+add_qt_executable(singleskip
+ SOURCES
+ tst_singleskip.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/singleskip/CMakeLists.txt b/tests/auto/testlib/selftests/singleskip/CMakeLists.txt
new file mode 100644
index 0000000000..c3e70ddf72
--- /dev/null
+++ b/tests/auto/testlib/selftests/singleskip/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from singleskip.pro.
+
+#####################################################################
+## singleskip Binary:
+#####################################################################
+
+add_qt_executable(singleskip
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_singleskip.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/skip/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/skip/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..2eaac745a8
--- /dev/null
+++ b/tests/auto/testlib/selftests/skip/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from skip.pro.
+
+#####################################################################
+## skip Binary:
+#####################################################################
+
+add_qt_executable(skip
+ SOURCES
+ tst_skip.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/skip/CMakeLists.txt b/tests/auto/testlib/selftests/skip/CMakeLists.txt
new file mode 100644
index 0000000000..f282c3e6a3
--- /dev/null
+++ b/tests/auto/testlib/selftests/skip/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from skip.pro.
+
+#####################################################################
+## skip Binary:
+#####################################################################
+
+add_qt_executable(skip
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_skip.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/skipcleanup/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/skipcleanup/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..77673004b2
--- /dev/null
+++ b/tests/auto/testlib/selftests/skipcleanup/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from skipcleanup.pro.
+
+#####################################################################
+## skipcleanup Binary:
+#####################################################################
+
+add_qt_executable(skipcleanup
+ SOURCES
+ tst_skipcleanup.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/skipcleanup/CMakeLists.txt b/tests/auto/testlib/selftests/skipcleanup/CMakeLists.txt
new file mode 100644
index 0000000000..09fef0967b
--- /dev/null
+++ b/tests/auto/testlib/selftests/skipcleanup/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from skipcleanup.pro.
+
+#####################################################################
+## skipcleanup Binary:
+#####################################################################
+
+add_qt_executable(skipcleanup
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_skipcleanup.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/skipinit/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/skipinit/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..4a36d0fa1c
--- /dev/null
+++ b/tests/auto/testlib/selftests/skipinit/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from skipinit.pro.
+
+#####################################################################
+## skipinit Binary:
+#####################################################################
+
+add_qt_executable(skipinit
+ SOURCES
+ tst_skipinit.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/skipinit/CMakeLists.txt b/tests/auto/testlib/selftests/skipinit/CMakeLists.txt
new file mode 100644
index 0000000000..47c437d3b7
--- /dev/null
+++ b/tests/auto/testlib/selftests/skipinit/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from skipinit.pro.
+
+#####################################################################
+## skipinit Binary:
+#####################################################################
+
+add_qt_executable(skipinit
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_skipinit.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/skipinitdata/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/skipinitdata/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..7f7773c87c
--- /dev/null
+++ b/tests/auto/testlib/selftests/skipinitdata/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from skipinitdata.pro.
+
+#####################################################################
+## skipinitdata Binary:
+#####################################################################
+
+add_qt_executable(skipinitdata
+ SOURCES
+ tst_skipinitdata.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/skipinitdata/CMakeLists.txt b/tests/auto/testlib/selftests/skipinitdata/CMakeLists.txt
new file mode 100644
index 0000000000..edbf6c1389
--- /dev/null
+++ b/tests/auto/testlib/selftests/skipinitdata/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from skipinitdata.pro.
+
+#####################################################################
+## skipinitdata Binary:
+#####################################################################
+
+add_qt_executable(skipinitdata
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_skipinitdata.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/sleep/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/sleep/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..c176681068
--- /dev/null
+++ b/tests/auto/testlib/selftests/sleep/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from sleep.pro.
+
+#####################################################################
+## sleep Binary:
+#####################################################################
+
+add_qt_executable(sleep
+ SOURCES
+ tst_sleep.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/sleep/CMakeLists.txt b/tests/auto/testlib/selftests/sleep/CMakeLists.txt
new file mode 100644
index 0000000000..ea85b03cc1
--- /dev/null
+++ b/tests/auto/testlib/selftests/sleep/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from sleep.pro.
+
+#####################################################################
+## sleep Binary:
+#####################################################################
+
+add_qt_executable(sleep
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_sleep.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/strcmp/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/strcmp/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..ff5b402328
--- /dev/null
+++ b/tests/auto/testlib/selftests/strcmp/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from strcmp.pro.
+
+#####################################################################
+## strcmp Binary:
+#####################################################################
+
+add_qt_executable(strcmp
+ SOURCES
+ tst_strcmp.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/strcmp/CMakeLists.txt b/tests/auto/testlib/selftests/strcmp/CMakeLists.txt
new file mode 100644
index 0000000000..70a6ccf33d
--- /dev/null
+++ b/tests/auto/testlib/selftests/strcmp/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from strcmp.pro.
+
+#####################################################################
+## strcmp Binary:
+#####################################################################
+
+add_qt_executable(strcmp
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_strcmp.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/subtest/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/subtest/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..dd4ad850c6
--- /dev/null
+++ b/tests/auto/testlib/selftests/subtest/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from subtest.pro.
+
+#####################################################################
+## subtest Binary:
+#####################################################################
+
+add_qt_executable(subtest
+ SOURCES
+ tst_subtest.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/subtest/CMakeLists.txt b/tests/auto/testlib/selftests/subtest/CMakeLists.txt
new file mode 100644
index 0000000000..c532f7f77c
--- /dev/null
+++ b/tests/auto/testlib/selftests/subtest/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from subtest.pro.
+
+#####################################################################
+## subtest Binary:
+#####################################################################
+
+add_qt_executable(subtest
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_subtest.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/testlib/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/testlib/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..14a5175693
--- /dev/null
+++ b/tests/auto/testlib/selftests/testlib/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from testlib.pro.
+
+#####################################################################
+## testlib Binary:
+#####################################################################
+
+add_qt_executable(testlib
+ SOURCES
+ tst_testlib.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/testlib/CMakeLists.txt b/tests/auto/testlib/selftests/testlib/CMakeLists.txt
new file mode 100644
index 0000000000..8f23f114bc
--- /dev/null
+++ b/tests/auto/testlib/selftests/testlib/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from testlib.pro.
+
+#####################################################################
+## testlib Binary:
+#####################################################################
+
+add_qt_executable(testlib
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_testlib.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/tuplediagnostics/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/tuplediagnostics/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..7b6b107dff
--- /dev/null
+++ b/tests/auto/testlib/selftests/tuplediagnostics/.prev_CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from tuplediagnostics.pro.
+
+#####################################################################
+## tuplediagnostics Binary:
+#####################################################################
+
+add_qt_executable(tuplediagnostics
+ SOURCES
+ tst_tuplediagnostics.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/auto/testlib/selftests/tuplediagnostics/CMakeLists.txt b/tests/auto/testlib/selftests/tuplediagnostics/CMakeLists.txt
new file mode 100644
index 0000000000..d43bcbfc07
--- /dev/null
+++ b/tests/auto/testlib/selftests/tuplediagnostics/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from tuplediagnostics.pro.
+
+#####################################################################
+## tuplediagnostics Binary:
+#####################################################################
+
+add_qt_executable(tuplediagnostics
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_tuplediagnostics.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/auto/testlib/selftests/verbose1/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/verbose1/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..9faa977236
--- /dev/null
+++ b/tests/auto/testlib/selftests/verbose1/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from verbose1.pro.
+
+#####################################################################
+## verbose1 Binary:
+#####################################################################
+
+add_qt_executable(verbose1
+ SOURCES
+ ../counting/tst_counting.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/verbose1/CMakeLists.txt b/tests/auto/testlib/selftests/verbose1/CMakeLists.txt
new file mode 100644
index 0000000000..10f79d2d22
--- /dev/null
+++ b/tests/auto/testlib/selftests/verbose1/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from verbose1.pro.
+
+#####################################################################
+## verbose1 Binary:
+#####################################################################
+
+add_qt_executable(verbose1
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ ../counting/tst_counting.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/verbose2/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/verbose2/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..7b43fc0085
--- /dev/null
+++ b/tests/auto/testlib/selftests/verbose2/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from verbose2.pro.
+
+#####################################################################
+## verbose2 Binary:
+#####################################################################
+
+add_qt_executable(verbose2
+ SOURCES
+ ../counting/tst_counting.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/verbose2/CMakeLists.txt b/tests/auto/testlib/selftests/verbose2/CMakeLists.txt
new file mode 100644
index 0000000000..138f343178
--- /dev/null
+++ b/tests/auto/testlib/selftests/verbose2/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from verbose2.pro.
+
+#####################################################################
+## verbose2 Binary:
+#####################################################################
+
+add_qt_executable(verbose2
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ ../counting/tst_counting.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/verifyexceptionthrown/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/verifyexceptionthrown/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..f4e20fcfc6
--- /dev/null
+++ b/tests/auto/testlib/selftests/verifyexceptionthrown/.prev_CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from verifyexceptionthrown.pro.
+
+#####################################################################
+## verifyexceptionthrown Binary:
+#####################################################################
+
+add_qt_executable(verifyexceptionthrown
+ EXCEPTIONS
+ SOURCES
+ tst_verifyexceptionthrown.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/verifyexceptionthrown/CMakeLists.txt b/tests/auto/testlib/selftests/verifyexceptionthrown/CMakeLists.txt
new file mode 100644
index 0000000000..def296ed7b
--- /dev/null
+++ b/tests/auto/testlib/selftests/verifyexceptionthrown/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from verifyexceptionthrown.pro.
+
+#####################################################################
+## verifyexceptionthrown Binary:
+#####################################################################
+
+add_qt_executable(verifyexceptionthrown
+ EXCEPTIONS
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_verifyexceptionthrown.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/warnings/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/warnings/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..11fb5098d6
--- /dev/null
+++ b/tests/auto/testlib/selftests/warnings/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from warnings.pro.
+
+#####################################################################
+## warnings Binary:
+#####################################################################
+
+add_qt_executable(warnings
+ SOURCES
+ tst_warnings.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/warnings/CMakeLists.txt b/tests/auto/testlib/selftests/warnings/CMakeLists.txt
new file mode 100644
index 0000000000..32e3bfe68f
--- /dev/null
+++ b/tests/auto/testlib/selftests/warnings/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from warnings.pro.
+
+#####################################################################
+## warnings Binary:
+#####################################################################
+
+add_qt_executable(warnings
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_warnings.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/watchdog/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/watchdog/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..1ea502875e
--- /dev/null
+++ b/tests/auto/testlib/selftests/watchdog/.prev_CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from watchdog.pro.
+
+#####################################################################
+## watchdog Binary:
+#####################################################################
+
+add_qt_executable(watchdog
+ SOURCES
+ tst_watchdog.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:watchdog.pro:<TRUE>:
+# QT_TOOL_ENV = "checkenv"
+# checkenv.name = "QTEST_FUNCTION_TIMEOUT"
+# checkenv.value = "100"
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/watchdog/CMakeLists.txt b/tests/auto/testlib/selftests/watchdog/CMakeLists.txt
new file mode 100644
index 0000000000..84236e2b5e
--- /dev/null
+++ b/tests/auto/testlib/selftests/watchdog/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from watchdog.pro.
+
+#####################################################################
+## watchdog Binary:
+#####################################################################
+
+add_qt_executable(watchdog
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_watchdog.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:watchdog.pro:<TRUE>:
+# QT_TOOL_ENV = "checkenv"
+# checkenv.name = "QTEST_FUNCTION_TIMEOUT"
+# checkenv.value = "100"
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/xunit/.prev_CMakeLists.txt b/tests/auto/testlib/selftests/xunit/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..6a55c59e00
--- /dev/null
+++ b/tests/auto/testlib/selftests/xunit/.prev_CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from xunit.pro.
+
+#####################################################################
+## xunit Binary:
+#####################################################################
+
+add_qt_executable(xunit
+ SOURCES
+ tst_xunit.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/testlib/selftests/xunit/CMakeLists.txt b/tests/auto/testlib/selftests/xunit/CMakeLists.txt
new file mode 100644
index 0000000000..d47d479bdf
--- /dev/null
+++ b/tests/auto/testlib/selftests/xunit/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from xunit.pro.
+
+#####################################################################
+## xunit Binary:
+#####################################################################
+
+add_qt_executable(xunit
+ NO_INSTALL # special case
+ OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} # special case
+ SOURCES
+ tst_xunit.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/tools/CMakeLists.txt b/tests/auto/tools/CMakeLists.txt
new file mode 100644
index 0000000000..aa45587993
--- /dev/null
+++ b/tests/auto/tools/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from tools.pro.
+
+add_subdirectory(qmakelib)
+# special case begin
+if(NOT WIN32) # @todo: this is broken, see QTBUG-78449
+ add_subdirectory(qmake)
+endif()
+# special case end
+#add_subdirectory(moc)
+#add_subdirectory(rcc)
+if(TARGET Qt::Widgets)
+ add_subdirectory(uic)
+endif()
+if(TARGET Qt::DBus)
+ add_subdirectory(qdbuscpp2xml)
+ add_subdirectory(qdbusxml2cpp)
+endif()
diff --git a/tests/auto/tools/qdbuscpp2xml/CMakeLists.txt b/tests/auto/tools/qdbuscpp2xml/CMakeLists.txt
new file mode 100644
index 0000000000..eaceac37b3
--- /dev/null
+++ b/tests/auto/tools/qdbuscpp2xml/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from qdbuscpp2xml.pro.
+
+#####################################################################
+## tst_qdbuscpp2xml Test:
+#####################################################################
+
+add_qt_test(tst_qdbuscpp2xml
+ SOURCES
+ test1.h
+ tst_qdbuscpp2xml.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
+
+# Resources:
+set(qdbuscpp2xml_resource_files
+ "test1.h"
+)
+
+add_qt_resource(tst_qdbuscpp2xml "qdbuscpp2xml"
+ PREFIX
+ "/tst_qdbuscpp2xml/"
+ FILES
+ ${qdbuscpp2xml_resource_files}
+)
+
diff --git a/tests/auto/tools/qdbusxml2cpp/CMakeLists.txt b/tests/auto/tools/qdbusxml2cpp/CMakeLists.txt
new file mode 100644
index 0000000000..8095421637
--- /dev/null
+++ b/tests/auto/tools/qdbusxml2cpp/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qdbusxml2cpp.pro.
+
+#####################################################################
+## tst_qdbusxml2cpp Test:
+#####################################################################
+
+add_qt_test(tst_qdbusxml2cpp
+ SOURCES
+ tst_qdbusxml2cpp.cpp
+)
diff --git a/tests/auto/tools/qmake/.prev_CMakeLists.txt b/tests/auto/tools/qmake/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..c1367ec18f
--- /dev/null
+++ b/tests/auto/tools/qmake/.prev_CMakeLists.txt
@@ -0,0 +1,39 @@
+# Generated from qmake.pro.
+
+#####################################################################
+## tst_qmake Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ testdata/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qmake
+ SOURCES
+ testcompiler.cpp testcompiler.h
+ tst_qmake.cpp
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:qmake.pro:WIN32:
+# testcase.timeout = "900"
+
+extend_target(tst_qmake CONDITION CMAKE_CROSSCOMPILING
+ DEFINES
+ QMAKE_CROSS_COMPILED
+)
+
+extend_target(tst_qmake CONDITION CMAKE_BUILD_TYPE STREQUAL Debug AND debug_and_release
+ DEFINES
+ DEBUG_BUILD
+)
+
+extend_target(tst_qmake CONDITION debug_and_release AND NOT CMAKE_BUILD_TYPE STREQUAL Debug
+ DEFINES
+ RELEASE_BUILD
+)
diff --git a/tests/auto/tools/qmake/CMakeLists.txt b/tests/auto/tools/qmake/CMakeLists.txt
new file mode 100644
index 0000000000..994d5d47d1
--- /dev/null
+++ b/tests/auto/tools/qmake/CMakeLists.txt
@@ -0,0 +1,42 @@
+# Generated from qmake.pro.
+
+#####################################################################
+## tst_qmake Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ testdata/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qmake
+ SOURCES
+ testcompiler.cpp testcompiler.h
+ tst_qmake.cpp
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:qmake.pro:WIN32:
+# testcase.timeout = "900"
+
+extend_target(tst_qmake CONDITION CMAKE_CROSSCOMPILING
+ DEFINES
+ QMAKE_CROSS_COMPILED
+)
+
+# special case begin
+# remove this because it's not needed
+#extend_target(tst_qmake CONDITION CMAKE_BUILD_TYPE STREQUAL Debug AND debug_and_release
+ #DEFINES
+ #DEBUG_BUILD
+#)
+
+#extend_target(tst_qmake CONDITION debug_and_release AND NOT CMAKE_BUILD_TYPE STREQUAL Debug
+ #DEFINES
+ #RELEASE_BUILD
+#)
+# special case end
diff --git a/tests/auto/tools/qmake/tst_qmake.cpp b/tests/auto/tools/qmake/tst_qmake.cpp
index 9b434a7b5b..7f98a0f5a0 100644
--- a/tests/auto/tools/qmake/tst_qmake.cpp
+++ b/tests/auto/tools/qmake/tst_qmake.cpp
@@ -318,6 +318,9 @@ void tst_qmake::subdirs()
void tst_qmake::subdir_via_pro_file_extra_target()
{
+ if (QProcessEnvironment::systemEnvironment().contains(QStringLiteral("QT_TEST_RUNNING_IN_CTEST")))
+ QSKIP("This test does not run properly when invoked from CTest.");
+
QString workDir = base_path + "/testdata/subdir_via_pro_file_extra_target";
QDir D;
diff --git a/tests/auto/tools/qmakelib/CMakeLists.txt b/tests/auto/tools/qmakelib/CMakeLists.txt
new file mode 100644
index 0000000000..1e56c81e77
--- /dev/null
+++ b/tests/auto/tools/qmakelib/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from qmakelib.pro.
+
+#####################################################################
+## tst_qmakelib Test:
+#####################################################################
+
+add_qt_test(tst_qmakelib
+ SOURCES
+ ../../../../qmake/library/ioutils.cpp
+ ../../../../qmake/library/proitems.cpp
+ ../../../../qmake/library/qmakebuiltins.cpp
+ ../../../../qmake/library/qmakeevaluator.cpp
+ ../../../../qmake/library/qmakeglobals.cpp
+ ../../../../qmake/library/qmakeparser.cpp
+ ../../../../qmake/library/qmakevfs.cpp
+ ../../../../qmake/library/registry.cpp
+ evaltest.cpp
+ parsertest.cpp
+ tst_qmakelib.cpp tst_qmakelib.h
+ DEFINES
+ PROEVALUATOR_FULL
+ PROEVALUATOR_SETENV
+ PROPARSER_DEBUG
+ INCLUDE_DIRECTORIES
+ ../../../../qmake/library
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qmakelib CONDITION WIN32
+ PUBLIC_LIBRARIES
+ advapi32
+)
diff --git a/tests/auto/tools/uic/CMakeLists.txt b/tests/auto/tools/uic/CMakeLists.txt
new file mode 100644
index 0000000000..f7d91dccbe
--- /dev/null
+++ b/tests/auto/tools/uic/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from uic.pro.
+
+#####################################################################
+## tst_uic Test:
+#####################################################################
+
+add_qt_test(tst_uic
+ SOURCES
+ tst_uic.cpp
+)
diff --git a/tests/auto/widgets/CMakeLists.txt b/tests/auto/widgets/CMakeLists.txt
new file mode 100644
index 0000000000..5870f28db0
--- /dev/null
+++ b/tests/auto/widgets/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from widgets.pro.
+
+add_subdirectory(dialogs)
+add_subdirectory(effects)
+add_subdirectory(graphicsview)
+add_subdirectory(itemviews)
+add_subdirectory(kernel)
+add_subdirectory(styles)
+add_subdirectory(util)
+add_subdirectory(widgets)
diff --git a/tests/auto/widgets/dialogs/CMakeLists.txt b/tests/auto/widgets/dialogs/CMakeLists.txt
new file mode 100644
index 0000000000..508093e7ad
--- /dev/null
+++ b/tests/auto/widgets/dialogs/CMakeLists.txt
@@ -0,0 +1,19 @@
+add_subdirectory(qcolordialog)
+add_subdirectory(qdialog)
+add_subdirectory(qerrormessage)
+if (NOT WINRT)
+ add_subdirectory(qfiledialog)
+ add_subdirectory(qfiledialog2)
+ add_subdirectory(qmessagebox)
+endif()
+if (NOT CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR NOT WIN32)
+ add_subdirectory(qfilesystemmodel)
+endif()
+add_subdirectory(qfontdialog)
+add_subdirectory(qinputdialog)
+add_subdirectory(qprogressdialog)
+if (QT_FEATURE_private_tests)
+ add_subdirectory(qsidebar)
+endif()
+add_subdirectory(qwizard)
+
diff --git a/tests/auto/widgets/dialogs/qcolordialog/CMakeLists.txt b/tests/auto/widgets/dialogs/qcolordialog/CMakeLists.txt
new file mode 100644
index 0000000000..81ffdeff90
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qcolordialog/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qcolordialog.pro.
+
+#####################################################################
+## tst_qcolordialog Test:
+#####################################################################
+
+add_qt_test(tst_qcolordialog
+ SOURCES
+ tst_qcolordialog.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/dialogs/qdialog/CMakeLists.txt b/tests/auto/widgets/dialogs/qdialog/CMakeLists.txt
new file mode 100644
index 0000000000..13201d2384
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qdialog/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qdialog.pro.
+
+#####################################################################
+## tst_qdialog Test:
+#####################################################################
+
+add_qt_test(tst_qdialog
+ SOURCES
+ tst_qdialog.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/dialogs/qerrormessage/CMakeLists.txt b/tests/auto/widgets/dialogs/qerrormessage/CMakeLists.txt
new file mode 100644
index 0000000000..9463020c66
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qerrormessage/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qerrormessage.pro.
+
+#####################################################################
+## tst_qerrormessage Test:
+#####################################################################
+
+add_qt_test(tst_qerrormessage
+ SOURCES
+ tst_qerrormessage.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qerrormessage.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/auto/widgets/dialogs/qfiledialog/CMakeLists.txt b/tests/auto/widgets/dialogs/qfiledialog/CMakeLists.txt
new file mode 100644
index 0000000000..745e65b332
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qfiledialog/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qfiledialog.pro.
+
+#####################################################################
+## tst_qfiledialog Test:
+#####################################################################
+
+add_qt_test(tst_qfiledialog
+ SOURCES
+ tst_qfiledialog.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/dialogs/qfiledialog2/CMakeLists.txt b/tests/auto/widgets/dialogs/qfiledialog2/CMakeLists.txt
new file mode 100644
index 0000000000..4989c312c9
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qfiledialog2/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qfiledialog2.pro.
+
+#####################################################################
+## tst_qfiledialog2 Test:
+#####################################################################
+
+add_qt_test(tst_qfiledialog2
+ SOURCES
+ tst_qfiledialog2.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/dialogs/qfilesystemmodel/CMakeLists.txt b/tests/auto/widgets/dialogs/qfilesystemmodel/CMakeLists.txt
new file mode 100644
index 0000000000..c4baa3fc12
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qfilesystemmodel/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from qfilesystemmodel.pro.
+
+#####################################################################
+## tst_qfilesystemmodel Test:
+#####################################################################
+
+add_qt_test(tst_qfilesystemmodel
+ SOURCES
+ ../../../../shared/emulationdetector.h
+ tst_qfilesystemmodel.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../shared
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:qfilesystemmodel.pro:WIN32:
+# testcase.timeout = "900"
+
+#### Keys ignored in scope 3:.:.:qfilesystemmodel.pro:APPLE_OSX:
+# testcase.timeout = "900"
diff --git a/tests/auto/widgets/dialogs/qfontdialog/CMakeLists.txt b/tests/auto/widgets/dialogs/qfontdialog/CMakeLists.txt
new file mode 100644
index 0000000000..345822ac79
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qfontdialog/CMakeLists.txt
@@ -0,0 +1,40 @@
+# Generated from qfontdialog.pro.
+
+#####################################################################
+## tst_qfontdialog Test:
+#####################################################################
+
+add_qt_test(tst_qfontdialog
+ SOURCES
+ tst_qfontdialog.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set_source_files_properties("../../../shared/resources/test.ttf"
+ PROPERTIES QT_RESOURCE_ALIAS "test.ttf"
+)
+set_source_files_properties("../../../shared/resources/testfont.ttf"
+ PROPERTIES QT_RESOURCE_ALIAS "testfont.ttf"
+)
+set(testfonts_resource_files
+ "../../../shared/resources/test.ttf"
+ "../../../shared/resources/testfont.ttf"
+)
+
+add_qt_resource(tst_qfontdialog "testfonts"
+ PREFIX
+ "/"
+ FILES
+ ${testfonts_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/widgets/dialogs/qinputdialog/CMakeLists.txt b/tests/auto/widgets/dialogs/qinputdialog/CMakeLists.txt
new file mode 100644
index 0000000000..b9d9ef04a1
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qinputdialog/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qinputdialog.pro.
+
+#####################################################################
+## tst_qinputdialog Test:
+#####################################################################
+
+add_qt_test(tst_qinputdialog
+ SOURCES
+ tst_qinputdialog.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/dialogs/qmessagebox/CMakeLists.txt b/tests/auto/widgets/dialogs/qmessagebox/CMakeLists.txt
new file mode 100644
index 0000000000..882cc143e1
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qmessagebox/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qmessagebox.pro.
+
+#####################################################################
+## tst_qmessagebox Test:
+#####################################################################
+
+add_qt_test(tst_qmessagebox
+ SOURCES
+ tst_qmessagebox.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qmessagebox.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/auto/widgets/dialogs/qprogressdialog/CMakeLists.txt b/tests/auto/widgets/dialogs/qprogressdialog/CMakeLists.txt
new file mode 100644
index 0000000000..2f20ff0d81
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qprogressdialog/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qprogressdialog.pro.
+
+#####################################################################
+## tst_qprogressdialog Test:
+#####################################################################
+
+add_qt_test(tst_qprogressdialog
+ SOURCES
+ tst_qprogressdialog.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/dialogs/qsidebar/CMakeLists.txt b/tests/auto/widgets/dialogs/qsidebar/CMakeLists.txt
new file mode 100644
index 0000000000..bc7d9f26ed
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qsidebar/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qsidebar.pro.
+
+#####################################################################
+## tst_qsidebar Test:
+#####################################################################
+
+add_qt_test(tst_qsidebar
+ SOURCES
+ tst_qsidebar.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/dialogs/qwizard/CMakeLists.txt b/tests/auto/widgets/dialogs/qwizard/CMakeLists.txt
new file mode 100644
index 0000000000..bbe7bddd9d
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qwizard/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from qwizard.pro.
+
+#####################################################################
+## tst_qwizard Test:
+#####################################################################
+
+add_qt_test(tst_qwizard
+ SOURCES
+ tst_qwizard.cpp
+ tst_qwizard_2.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set(qwizard_resource_files
+ "images/background.png"
+ "images/banner.png"
+ "images/logo.png"
+ "images/watermark.png"
+)
+
+add_qt_resource(tst_qwizard "qwizard"
+ PREFIX
+ "/"
+ FILES
+ ${qwizard_resource_files}
+)
+
diff --git a/tests/auto/widgets/effects/CMakeLists.txt b/tests/auto/widgets/effects/CMakeLists.txt
new file mode 100644
index 0000000000..2e2045e33e
--- /dev/null
+++ b/tests/auto/widgets/effects/CMakeLists.txt
@@ -0,0 +1,2 @@
+add_subdirectory(qgraphicseffect)
+add_subdirectory(qpixmapfilter)
diff --git a/tests/auto/widgets/effects/qgraphicseffect/CMakeLists.txt b/tests/auto/widgets/effects/qgraphicseffect/CMakeLists.txt
new file mode 100644
index 0000000000..b6cd4fa934
--- /dev/null
+++ b/tests/auto/widgets/effects/qgraphicseffect/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qgraphicseffect.pro.
+
+#####################################################################
+## tst_qgraphicseffect Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicseffect
+ SOURCES
+ tst_qgraphicseffect.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/effects/qpixmapfilter/CMakeLists.txt b/tests/auto/widgets/effects/qpixmapfilter/CMakeLists.txt
new file mode 100644
index 0000000000..31dbe56907
--- /dev/null
+++ b/tests/auto/widgets/effects/qpixmapfilter/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qpixmapfilter.pro.
+
+#####################################################################
+## tst_qpixmapfilter Test:
+#####################################################################
+
+add_qt_test(tst_qpixmapfilter
+ SOURCES
+ tst_qpixmapfilter.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/CMakeLists.txt b/tests/auto/widgets/graphicsview/CMakeLists.txt
new file mode 100644
index 0000000000..5d6650db4a
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/CMakeLists.txt
@@ -0,0 +1,25 @@
+if (QT_FEATURE_private_tests)
+ add_subdirectory(qgraphicsanchorlayout)
+ add_subdirectory(qgraphicsanchorlayout1)
+ add_subdirectory(qgraphicsitem)
+ add_subdirectory(qgraphicsscene)
+ add_subdirectory(qgraphicssceneindex)
+endif()
+add_subdirectory(qgraphicseffectsource)
+add_subdirectory(qgraphicsgridlayout)
+add_subdirectory(qgraphicsitemanimation)
+add_subdirectory(qgraphicslayout)
+add_subdirectory(qgraphicslayoutitem)
+add_subdirectory(qgraphicslinearlayout)
+add_subdirectory(qgraphicsobject)
+add_subdirectory(qgraphicspixmapitem)
+add_subdirectory(qgraphicspolygonitem)
+add_subdirectory(qgraphicstransform)
+if (NOT WINRT)
+ add_subdirectory(qgraphicsview)
+endif()
+
+if(QT_FEATURE_style_fusion)
+ add_subdirectory(qgraphicsproxywidget)
+ add_subdirectory(qgraphicswidget)
+endif()
diff --git a/tests/auto/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt
new file mode 100644
index 0000000000..6c213bc209
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qgraphicsanchorlayout.pro.
+
+#####################################################################
+## tst_qgraphicsanchorlayout Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicsanchorlayout
+ SOURCES
+ tst_qgraphicsanchorlayout.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicsanchorlayout1/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicsanchorlayout1/CMakeLists.txt
new file mode 100644
index 0000000000..a6739093b4
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsanchorlayout1/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qgraphicsanchorlayout1.pro.
+
+#####################################################################
+## tst_qgraphicsanchorlayout1 Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicsanchorlayout1
+ SOURCES
+ tst_qgraphicsanchorlayout1.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicseffectsource/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicseffectsource/CMakeLists.txt
new file mode 100644
index 0000000000..6becd124bf
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicseffectsource/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qgraphicseffectsource.pro.
+
+#####################################################################
+## tst_qgraphicseffectsource Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicseffectsource
+ SOURCES
+ tst_qgraphicseffectsource.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicsgridlayout/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicsgridlayout/CMakeLists.txt
new file mode 100644
index 0000000000..c02f142182
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsgridlayout/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qgraphicsgridlayout.pro.
+
+#####################################################################
+## tst_qgraphicsgridlayout Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicsgridlayout
+ SOURCES
+ tst_qgraphicsgridlayout.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicsitem/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicsitem/CMakeLists.txt
new file mode 100644
index 0000000000..b500ec487a
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsitem/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from qgraphicsitem.pro.
+
+#####################################################################
+## tst_qgraphicsitem Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicsitem
+ SOURCES
+ tst_qgraphicsitem.cpp
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qgraphicsitem CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ user32
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicsitemanimation/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicsitemanimation/CMakeLists.txt
new file mode 100644
index 0000000000..179b6c8497
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsitemanimation/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qgraphicsitemanimation.pro.
+
+#####################################################################
+## tst_qgraphicsitemanimation Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicsitemanimation
+ SOURCES
+ tst_qgraphicsitemanimation.cpp
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicslayout/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicslayout/CMakeLists.txt
new file mode 100644
index 0000000000..9a149f9df1
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicslayout/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qgraphicslayout.pro.
+
+#####################################################################
+## tst_qgraphicslayout Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicslayout
+ SOURCES
+ tst_qgraphicslayout.cpp
+ DEFINES
+ QT_USE_USING_NAMESPACE
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicslayoutitem/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicslayoutitem/CMakeLists.txt
new file mode 100644
index 0000000000..56b9f73127
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicslayoutitem/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qgraphicslayoutitem.pro.
+
+#####################################################################
+## tst_qgraphicslayoutitem Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicslayoutitem
+ SOURCES
+ tst_qgraphicslayoutitem.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt
new file mode 100644
index 0000000000..1a44be75a1
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qgraphicslinearlayout.pro.
+
+#####################################################################
+## tst_qgraphicslinearlayout Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicslinearlayout
+ SOURCES
+ tst_qgraphicslinearlayout.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicsobject/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicsobject/CMakeLists.txt
new file mode 100644
index 0000000000..6fd8273708
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsobject/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qgraphicsobject.pro.
+
+#####################################################################
+## tst_qgraphicsobject Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicsobject
+ SOURCES
+ tst_qgraphicsobject.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicspixmapitem/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicspixmapitem/CMakeLists.txt
new file mode 100644
index 0000000000..cca35623e8
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicspixmapitem/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qgraphicspixmapitem.pro.
+
+#####################################################################
+## tst_qgraphicspixmapitem Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicspixmapitem
+ SOURCES
+ tst_qgraphicspixmapitem.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicspolygonitem/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicspolygonitem/CMakeLists.txt
new file mode 100644
index 0000000000..86c6965756
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicspolygonitem/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qgraphicspolygonitem.pro.
+
+#####################################################################
+## tst_qgraphicspolygonitem Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicspolygonitem
+ SOURCES
+ tst_qgraphicspolygonitem.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicsproxywidget/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicsproxywidget/CMakeLists.txt
new file mode 100644
index 0000000000..77af1c5a83
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsproxywidget/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qgraphicsproxywidget.pro.
+
+#####################################################################
+## tst_qgraphicsproxywidget Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicsproxywidget
+ SOURCES
+ tst_qgraphicsproxywidget.cpp
+ DEFINES
+ QTEST_QPA_MOUSE_HANDLING
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicsscene/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicsscene/CMakeLists.txt
new file mode 100644
index 0000000000..ddc377799f
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsscene/CMakeLists.txt
@@ -0,0 +1,78 @@
+# Generated from qgraphicsscene.pro.
+
+#####################################################################
+## tst_qgraphicsscene Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicsscene
+ SOURCES
+ tst_qgraphicsscene.cpp
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}\\\"
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set(images_resource_files
+ "Ash_European.jpg"
+)
+
+add_qt_resource(tst_qgraphicsscene "images"
+ PREFIX
+ "/"
+ FILES
+ ${images_resource_files}
+)
+set(testdata_resource_files
+ "testData/render/all-all-45-deg-left.png"
+ "testData/render/all-all-45-deg-right.png"
+ "testData/render/all-all-scale-2x.png"
+ "testData/render/all-all-translate-0-50.png"
+ "testData/render/all-all-translate-50-0.png"
+ "testData/render/all-all-untransformed-clip-ellipse.png"
+ "testData/render/all-all-untransformed-clip-rect.png"
+ "testData/render/all-all-untransformed.png"
+ "testData/render/all-bottomleft-untransformed.png"
+ "testData/render/all-bottomright-untransformed.png"
+ "testData/render/all-topleft-untransformed.png"
+ "testData/render/all-topright-untransformed.png"
+ "testData/render/bottom-bottomright-untransformed.png"
+ "testData/render/bottom-topleft-untransformed.png"
+ "testData/render/bottomleft-all-untransformed.png"
+ "testData/render/bottomleft-topleft-untransformed.png"
+ "testData/render/bottomright-all-untransformed.png"
+ "testData/render/bottomright-topleft-untransformed.png"
+ "testData/render/left-bottomright-untransformed.png"
+ "testData/render/left-topleft-untransformed.png"
+ "testData/render/right-bottomright-untransformed.png"
+ "testData/render/right-topleft-untransformed.png"
+ "testData/render/top-bottomright-untransformed.png"
+ "testData/render/top-topleft-untransformed.png"
+ "testData/render/topleft-all-untransformed.png"
+ "testData/render/topleft-topleft-untransformed.png"
+ "testData/render/topright-all-untransformed.png"
+ "testData/render/topright-topleft-untransformed.png"
+)
+
+add_qt_resource(tst_qgraphicsscene "testdata"
+ PREFIX
+ "/"
+ FILES
+ ${testdata_resource_files}
+)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qgraphicsscene CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ user32
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicssceneindex/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicssceneindex/CMakeLists.txt
new file mode 100644
index 0000000000..b8a5fcd905
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicssceneindex/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from qgraphicssceneindex.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qgraphicssceneindex Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicssceneindex
+ SOURCES
+ tst_qgraphicssceneindex.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qgraphicssceneindex.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
diff --git a/tests/auto/widgets/graphicsview/qgraphicstransform/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicstransform/CMakeLists.txt
new file mode 100644
index 0000000000..450c0269f3
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicstransform/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qgraphicstransform.pro.
+
+#####################################################################
+## tst_qgraphicstransform Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicstransform
+ SOURCES
+ tst_qgraphicstransform.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicsview/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicsview/CMakeLists.txt
new file mode 100644
index 0000000000..22354b9c5e
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsview/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from qgraphicsview.pro.
+
+#####################################################################
+## tst_qgraphicsview Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicsview
+ SOURCES
+ tst_qgraphicsview.cpp tst_qgraphicsview.h
+ tst_qgraphicsview_2.cpp
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qgraphicsview.pro:<TRUE>:
+# testcase.timeout = "500"
diff --git a/tests/auto/widgets/graphicsview/qgraphicswidget/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicswidget/CMakeLists.txt
new file mode 100644
index 0000000000..9c49a957c0
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicswidget/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qgraphicswidget.pro.
+
+#####################################################################
+## tst_qgraphicswidget Test:
+#####################################################################
+
+add_qt_test(tst_qgraphicswidget
+ SOURCES
+ tst_qgraphicswidget.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/itemviews/CMakeLists.txt b/tests/auto/widgets/itemviews/CMakeLists.txt
new file mode 100644
index 0000000000..e7dc78b18c
--- /dev/null
+++ b/tests/auto/widgets/itemviews/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from itemviews.pro.
+
+add_subdirectory(qabstractitemview)
+add_subdirectory(qdatawidgetmapper)
+add_subdirectory(qdirmodel)
+add_subdirectory(qfileiconprovider)
+add_subdirectory(qheaderview)
+add_subdirectory(qitemdelegate)
+add_subdirectory(qitemeditorfactory)
+add_subdirectory(qitemview)
+add_subdirectory(qlistview)
+add_subdirectory(qtableview)
+add_subdirectory(qtablewidget)
+add_subdirectory(qtreeview)
+add_subdirectory(qtreewidget)
+add_subdirectory(qtreewidgetitemiterator)
+
+if(QT_FEATURE_private_tests)
+ add_subdirectory(qcolumnview)
+ add_subdirectory(qlistwidget)
+endif()
diff --git a/tests/auto/widgets/itemviews/qabstractitemview/CMakeLists.txt b/tests/auto/widgets/itemviews/qabstractitemview/CMakeLists.txt
new file mode 100644
index 0000000000..02c52ed42d
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qabstractitemview/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qabstractitemview.pro.
+
+#####################################################################
+## tst_qabstractitemview Test:
+#####################################################################
+
+add_qt_test(tst_qabstractitemview
+ SOURCES
+ tst_qabstractitemview.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/itemviews/qcolumnview/CMakeLists.txt b/tests/auto/widgets/itemviews/qcolumnview/CMakeLists.txt
new file mode 100644
index 0000000000..47e6a1ee35
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qcolumnview/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qcolumnview.pro.
+
+#####################################################################
+## tst_qcolumnview Test:
+#####################################################################
+
+add_qt_test(tst_qcolumnview
+ SOURCES
+ ../../../../shared/fakedirmodel.h
+ tst_qcolumnview.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/itemviews/qdatawidgetmapper/CMakeLists.txt b/tests/auto/widgets/itemviews/qdatawidgetmapper/CMakeLists.txt
new file mode 100644
index 0000000000..f3e4af0c23
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qdatawidgetmapper/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qdatawidgetmapper.pro.
+
+#####################################################################
+## tst_qdatawidgetmapper Test:
+#####################################################################
+
+add_qt_test(tst_qdatawidgetmapper
+ SOURCES
+ tst_qdatawidgetmapper.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/itemviews/qdirmodel/CMakeLists.txt b/tests/auto/widgets/itemviews/qdirmodel/CMakeLists.txt
new file mode 100644
index 0000000000..d47cc3457d
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qdirmodel/CMakeLists.txt
@@ -0,0 +1,49 @@
+# Generated from qdirmodel.pro.
+
+#####################################################################
+## tst_qdirmodel Test:
+#####################################################################
+
+add_qt_test(tst_qdirmodel
+ SOURCES
+ ../../../../shared/emulationdetector.h
+ tst_qdirmodel.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../shared
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qdirmodel CONDITION ANDROID
+ DEFINES
+ SRCDIR=\\\"./\\\"
+)
+
+extend_target(tst_qdirmodel CONDITION NOT ANDROID
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+)
+
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ # Resources:
+ set(testdata_resource_files
+ "dirtest/test1/dummy"
+ "dirtest/test1/test"
+ "test/file01.tst"
+ "test/file02.tst"
+ "test/file03.tst"
+ "test/file04.tst"
+ "tst_qdirmodel.cpp"
+ )
+
+ add_qt_resource(tst_qdirmodel "testdata"
+ PREFIX
+ "/android_testdata"
+ FILES
+ ${testdata_resource_files}
+ )
+endif()
diff --git a/tests/auto/widgets/itemviews/qfileiconprovider/CMakeLists.txt b/tests/auto/widgets/itemviews/qfileiconprovider/CMakeLists.txt
new file mode 100644
index 0000000000..024519ad9c
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qfileiconprovider/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qfileiconprovider.pro.
+
+#####################################################################
+## tst_qfileiconprovider Test:
+#####################################################################
+
+add_qt_test(tst_qfileiconprovider
+ SOURCES
+ tst_qfileiconprovider.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/itemviews/qheaderview/CMakeLists.txt b/tests/auto/widgets/itemviews/qheaderview/CMakeLists.txt
new file mode 100644
index 0000000000..8a4cebe7d5
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qheaderview/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qheaderview.pro.
+
+#####################################################################
+## tst_qheaderview Test:
+#####################################################################
+
+add_qt_test(tst_qheaderview
+ SOURCES
+ tst_qheaderview.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/itemviews/qitemdelegate/CMakeLists.txt b/tests/auto/widgets/itemviews/qitemdelegate/CMakeLists.txt
new file mode 100644
index 0000000000..f97940b28a
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qitemdelegate/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from qitemdelegate.pro.
+
+#####################################################################
+## tst_qitemdelegate Test:
+#####################################################################
+
+add_qt_test(tst_qitemdelegate
+ SOURCES
+ tst_qitemdelegate.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qitemdelegate CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ user32
+)
diff --git a/tests/auto/widgets/itemviews/qitemeditorfactory/CMakeLists.txt b/tests/auto/widgets/itemviews/qitemeditorfactory/CMakeLists.txt
new file mode 100644
index 0000000000..4dfb46ff4d
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qitemeditorfactory/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qitemeditorfactory.pro.
+
+#####################################################################
+## tst_qitemeditorfactory Test:
+#####################################################################
+
+add_qt_test(tst_qitemeditorfactory
+ SOURCES
+ tst_qitemeditorfactory.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/itemviews/qitemview/CMakeLists.txt b/tests/auto/widgets/itemviews/qitemview/CMakeLists.txt
new file mode 100644
index 0000000000..b27f456246
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qitemview/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qitemview.pro.
+
+#####################################################################
+## tst_qitemview Test:
+#####################################################################
+
+add_qt_test(tst_qitemview
+ SOURCES
+ tst_qitemview.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/itemviews/qlistview/CMakeLists.txt b/tests/auto/widgets/itemviews/qlistview/CMakeLists.txt
new file mode 100644
index 0000000000..1c7c5ae7fe
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qlistview/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from qlistview.pro.
+
+#####################################################################
+## tst_qlistview Test:
+#####################################################################
+
+add_qt_test(tst_qlistview
+ SOURCES
+ tst_qlistview.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qlistview CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ user32
+)
diff --git a/tests/auto/widgets/itemviews/qlistwidget/CMakeLists.txt b/tests/auto/widgets/itemviews/qlistwidget/CMakeLists.txt
new file mode 100644
index 0000000000..853b463893
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qlistwidget/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qlistwidget.pro.
+
+#####################################################################
+## tst_qlistwidget Test:
+#####################################################################
+
+add_qt_test(tst_qlistwidget
+ SOURCES
+ tst_qlistwidget.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/itemviews/qtableview/CMakeLists.txt b/tests/auto/widgets/itemviews/qtableview/CMakeLists.txt
new file mode 100644
index 0000000000..0906f4c5a1
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qtableview/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qtableview.pro.
+
+#####################################################################
+## tst_qtableview Test:
+#####################################################################
+
+add_qt_test(tst_qtableview
+ SOURCES
+ tst_qtableview.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/itemviews/qtablewidget/CMakeLists.txt b/tests/auto/widgets/itemviews/qtablewidget/CMakeLists.txt
new file mode 100644
index 0000000000..66344e9d32
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qtablewidget/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qtablewidget.pro.
+
+#####################################################################
+## tst_qtablewidget Test:
+#####################################################################
+
+add_qt_test(tst_qtablewidget
+ SOURCES
+ tst_qtablewidget.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/itemviews/qtreeview/CMakeLists.txt b/tests/auto/widgets/itemviews/qtreeview/CMakeLists.txt
new file mode 100644
index 0000000000..4914f705ab
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qtreeview/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qtreeview.pro.
+
+#####################################################################
+## tst_qtreeview Test:
+#####################################################################
+
+add_qt_test(tst_qtreeview
+ SOURCES
+ ../../../../shared/fakedirmodel.h
+ tst_qtreeview.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/itemviews/qtreewidget/CMakeLists.txt b/tests/auto/widgets/itemviews/qtreewidget/CMakeLists.txt
new file mode 100644
index 0000000000..dde2e9d4ab
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qtreewidget/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qtreewidget.pro.
+
+#####################################################################
+## tst_qtreewidget Test:
+#####################################################################
+
+add_qt_test(tst_qtreewidget
+ SOURCES
+ tst_qtreewidget.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/itemviews/qtreewidgetitemiterator/CMakeLists.txt b/tests/auto/widgets/itemviews/qtreewidgetitemiterator/CMakeLists.txt
new file mode 100644
index 0000000000..65ac8cda8b
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qtreewidgetitemiterator/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qtreewidgetitemiterator.pro.
+
+#####################################################################
+## tst_qtreewidgetitemiterator Test:
+#####################################################################
+
+add_qt_test(tst_qtreewidgetitemiterator
+ SOURCES
+ tst_qtreewidgetitemiterator.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/CMakeLists.txt b/tests/auto/widgets/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..51759264b2
--- /dev/null
+++ b/tests/auto/widgets/kernel/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from kernel.pro.
+
+add_subdirectory(qaction)
+add_subdirectory(qactiongroup)
+add_subdirectory(qapplication)
+add_subdirectory(qboxlayout)
+add_subdirectory(qdesktopwidget)
+add_subdirectory(qformlayout)
+add_subdirectory(qgridlayout)
+add_subdirectory(qlayout)
+add_subdirectory(qstackedlayout)
+add_subdirectory(qtooltip)
+add_subdirectory(qwidget)
+add_subdirectory(qwidget_window)
+add_subdirectory(qwidgetaction)
+add_subdirectory(qwidgetmetatype)
+add_subdirectory(qwidgetsvariant)
+add_subdirectory(qwindowcontainer)
+add_subdirectory(qshortcut)
+add_subdirectory(qsizepolicy)
+if(NOT APPLE)
+ add_subdirectory(qgesturerecognizer)
+endif()
diff --git a/tests/auto/widgets/kernel/kernel.pro b/tests/auto/widgets/kernel/kernel.pro
index 9d0bf58b03..9cd666ca4f 100644
--- a/tests/auto/widgets/kernel/kernel.pro
+++ b/tests/auto/widgets/kernel/kernel.pro
@@ -17,7 +17,7 @@ SUBDIRS=\
qshortcut \
qsizepolicy
-darwin:SUBDIRS -= \ # Uses native recognizers
+darwin:SUBDIRS -= \
qgesturerecognizer \
!qtConfig(action):SUBDIRS -= \
diff --git a/tests/auto/widgets/kernel/qaction/CMakeLists.txt b/tests/auto/widgets/kernel/qaction/CMakeLists.txt
new file mode 100644
index 0000000000..67f98382f1
--- /dev/null
+++ b/tests/auto/widgets/kernel/qaction/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qaction.pro.
+
+#####################################################################
+## tst_qaction Test:
+#####################################################################
+
+add_qt_test(tst_qaction
+ SOURCES
+ tst_qaction.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/qactiongroup/CMakeLists.txt b/tests/auto/widgets/kernel/qactiongroup/CMakeLists.txt
new file mode 100644
index 0000000000..a55acf2efb
--- /dev/null
+++ b/tests/auto/widgets/kernel/qactiongroup/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qactiongroup.pro.
+
+#####################################################################
+## tst_qactiongroup Test:
+#####################################################################
+
+add_qt_test(tst_qactiongroup
+ SOURCES
+ tst_qactiongroup.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/qapplication/CMakeLists.txt b/tests/auto/widgets/kernel/qapplication/CMakeLists.txt
new file mode 100644
index 0000000000..8e68089f5e
--- /dev/null
+++ b/tests/auto/widgets/kernel/qapplication/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from qapplication.pro.
+
+add_subdirectory(test)
+if(NOT WINRT)
+ add_subdirectory(desktopsettingsaware)
+ add_subdirectory(modal)
+endif()
diff --git a/tests/auto/widgets/kernel/qapplication/desktopsettingsaware/.prev_CMakeLists.txt b/tests/auto/widgets/kernel/qapplication/desktopsettingsaware/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..df5f5f4e6c
--- /dev/null
+++ b/tests/auto/widgets/kernel/qapplication/desktopsettingsaware/.prev_CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from desktopsettingsaware.pro.
+
+#####################################################################
+## desktopsettingsaware Binary:
+#####################################################################
+
+add_qt_executable(desktopsettingsaware
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/widgets/kernel/qapplication/desktopsettingsaware/CMakeLists.txt b/tests/auto/widgets/kernel/qapplication/desktopsettingsaware/CMakeLists.txt
new file mode 100644
index 0000000000..98a38da7c0
--- /dev/null
+++ b/tests/auto/widgets/kernel/qapplication/desktopsettingsaware/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from desktopsettingsaware.pro.
+
+#####################################################################
+## desktopsettingsaware Binary:
+#####################################################################
+
+add_qt_executable(desktopsettingsaware_helper # special case
+ SOURCES
+ main.cpp
+ OUTPUT_DIRECTORY # special case
+ ${CMAKE_CURRENT_BINARY_DIR}/.. # special case
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/widgets/kernel/qapplication/modal/.prev_CMakeLists.txt b/tests/auto/widgets/kernel/qapplication/modal/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..fc990e790e
--- /dev/null
+++ b/tests/auto/widgets/kernel/qapplication/modal/.prev_CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from modal.pro.
+
+#####################################################################
+## modal Binary:
+#####################################################################
+
+add_qt_executable(modal
+ SOURCES
+ base.cpp base.h
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/widgets/kernel/qapplication/modal/CMakeLists.txt b/tests/auto/widgets/kernel/qapplication/modal/CMakeLists.txt
new file mode 100644
index 0000000000..c598ca600a
--- /dev/null
+++ b/tests/auto/widgets/kernel/qapplication/modal/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from modal.pro.
+
+#####################################################################
+## modal Binary:
+#####################################################################
+
+add_qt_executable(modal_helper # special case
+ SOURCES
+ base.cpp base.h
+ main.cpp
+ OUTPUT_DIRECTORY # special case
+ ${CMAKE_CURRENT_BINARY_DIR}/.. # special case
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/widgets/kernel/qapplication/test/.prev_CMakeLists.txt b/tests/auto/widgets/kernel/qapplication/test/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..af5138c756
--- /dev/null
+++ b/tests/auto/widgets/kernel/qapplication/test/.prev_CMakeLists.txt
@@ -0,0 +1,43 @@
+# Generated from test.pro.
+
+#####################################################################
+## test Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "../test/test.pro")
+list(APPEND test_data "../tmp/README")
+list(APPEND test_data "../modal")
+
+add_qt_test(test
+ SOURCES
+ ../tst_qapplication.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(test CONDITION builtin_testdata
+ DEFINES
+ BUILTIN_TESTDATA
+)
+
+#### Keys ignored in scope 3:.:.:test.pro:NOT ANDROID AND NOT WINRT:
+# SUBPROGRAMS = "desktopsettingsaware" "modal"
+
+#### Keys ignored in scope 6:.:.:test.pro:NOT ANDROID AND NOT WINRT:
+# TEST_HELPER_INSTALLS = "../debug/helper"
+
+#### Keys ignored in scope 8:.:.:test.pro:NOT ANDROID AND NOT WINRT:
+# TEST_HELPER_INSTALLS = "../release/helper"
+
+#### Keys ignored in scope 10:.:.:test.pro:NOT ANDROID AND NOT WINRT:
+# TEST_HELPER_INSTALLS = "../helper"
diff --git a/tests/auto/widgets/kernel/qapplication/test/CMakeLists.txt b/tests/auto/widgets/kernel/qapplication/test/CMakeLists.txt
new file mode 100644
index 0000000000..bc2ef1000f
--- /dev/null
+++ b/tests/auto/widgets/kernel/qapplication/test/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from test.pro.
+
+#####################################################################
+## test Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "../test/test.pro")
+list(APPEND test_data "../tmp/README")
+list(APPEND test_data "../modal")
+
+add_qt_test(tst_qapplication # special case
+ SOURCES
+ ../tst_qapplication.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ TESTDATA ${test_data}
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/.." # special case
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qapplication CONDITION builtin_testdata # special case
+ DEFINES
+ BUILTIN_TESTDATA
+)
+
+#### Keys ignored in scope 3:.:.:test.pro:NOT ANDROID AND NOT WINRT:
+# SUBPROGRAMS = "desktopsettingsaware" "modal"
+
+#### Keys ignored in scope 6:.:.:test.pro:NOT ANDROID AND NOT WINRT:
+# TEST_HELPER_INSTALLS = "../debug/helper"
+
+#### Keys ignored in scope 8:.:.:test.pro:NOT ANDROID AND NOT WINRT:
+# TEST_HELPER_INSTALLS = "../release/helper"
+
+#### Keys ignored in scope 10:.:.:test.pro:NOT ANDROID AND NOT WINRT:
+# TEST_HELPER_INSTALLS = "../helper"
diff --git a/tests/auto/widgets/kernel/qboxlayout/CMakeLists.txt b/tests/auto/widgets/kernel/qboxlayout/CMakeLists.txt
new file mode 100644
index 0000000000..dca063e2f0
--- /dev/null
+++ b/tests/auto/widgets/kernel/qboxlayout/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qboxlayout.pro.
+
+#####################################################################
+## tst_qboxlayout Test:
+#####################################################################
+
+add_qt_test(tst_qboxlayout
+ SOURCES
+ tst_qboxlayout.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/qdesktopwidget/CMakeLists.txt b/tests/auto/widgets/kernel/qdesktopwidget/CMakeLists.txt
new file mode 100644
index 0000000000..79790049fe
--- /dev/null
+++ b/tests/auto/widgets/kernel/qdesktopwidget/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qdesktopwidget.pro.
+
+#####################################################################
+## tst_qdesktopwidget Test:
+#####################################################################
+
+add_qt_test(tst_qdesktopwidget
+ SOURCES
+ tst_qdesktopwidget.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/qformlayout/CMakeLists.txt b/tests/auto/widgets/kernel/qformlayout/CMakeLists.txt
new file mode 100644
index 0000000000..48e1431a35
--- /dev/null
+++ b/tests/auto/widgets/kernel/qformlayout/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qformlayout.pro.
+
+#####################################################################
+## tst_qformlayout Test:
+#####################################################################
+
+add_qt_test(tst_qformlayout
+ SOURCES
+ tst_qformlayout.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/qgesturerecognizer/CMakeLists.txt b/tests/auto/widgets/kernel/qgesturerecognizer/CMakeLists.txt
new file mode 100644
index 0000000000..7041320dd0
--- /dev/null
+++ b/tests/auto/widgets/kernel/qgesturerecognizer/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qgesturerecognizer.pro.
+
+#####################################################################
+## tst_qgesturerecognizer Test:
+#####################################################################
+
+add_qt_test(tst_qgesturerecognizer
+ SOURCES
+ tst_qgesturerecognizer.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/qgridlayout/CMakeLists.txt b/tests/auto/widgets/kernel/qgridlayout/CMakeLists.txt
new file mode 100644
index 0000000000..86661e505a
--- /dev/null
+++ b/tests/auto/widgets/kernel/qgridlayout/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from qgridlayout.pro.
+
+#####################################################################
+## tst_qgridlayout Test:
+#####################################################################
+
+add_qt_test(tst_qgridlayout
+ SOURCES
+ sortdialog.ui
+ tst_qgridlayout.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
diff --git a/tests/auto/widgets/kernel/qlayout/CMakeLists.txt b/tests/auto/widgets/kernel/qlayout/CMakeLists.txt
new file mode 100644
index 0000000000..2a3526722e
--- /dev/null
+++ b/tests/auto/widgets/kernel/qlayout/CMakeLists.txt
@@ -0,0 +1,40 @@
+# Generated from qlayout.pro.
+
+#####################################################################
+## tst_qlayout Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ baseline/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qlayout
+ SOURCES
+ tst_qlayout.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+if(ANDROID AND NOT ANDROID_EMBEDDED)
+ # Resources:
+ set(testdata_resource_files
+ "baseline/smartmaxsize"
+ )
+
+ add_qt_resource(tst_qlayout "testdata"
+ PREFIX
+ "/"
+ FILES
+ ${testdata_resource_files}
+ )
+endif()
diff --git a/tests/auto/widgets/kernel/qshortcut/CMakeLists.txt b/tests/auto/widgets/kernel/qshortcut/CMakeLists.txt
new file mode 100644
index 0000000000..5d077c87ec
--- /dev/null
+++ b/tests/auto/widgets/kernel/qshortcut/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qshortcut.pro.
+
+#####################################################################
+## tst_qshortcut Test:
+#####################################################################
+
+add_qt_test(tst_qshortcut
+ SOURCES
+ tst_qshortcut.cpp
+ INCLUDE_DIRECTORIES
+ ..
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/qsizepolicy/CMakeLists.txt b/tests/auto/widgets/kernel/qsizepolicy/CMakeLists.txt
new file mode 100644
index 0000000000..440421a3ea
--- /dev/null
+++ b/tests/auto/widgets/kernel/qsizepolicy/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qsizepolicy.pro.
+
+#####################################################################
+## tst_qsizepolicy Test:
+#####################################################################
+
+add_qt_test(tst_qsizepolicy
+ SOURCES
+ tst_qsizepolicy.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/auto/widgets/kernel/qstackedlayout/CMakeLists.txt b/tests/auto/widgets/kernel/qstackedlayout/CMakeLists.txt
new file mode 100644
index 0000000000..a41957c9a6
--- /dev/null
+++ b/tests/auto/widgets/kernel/qstackedlayout/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qstackedlayout.pro.
+
+#####################################################################
+## tst_qstackedlayout Test:
+#####################################################################
+
+add_qt_test(tst_qstackedlayout
+ SOURCES
+ tst_qstackedlayout.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/qtooltip/CMakeLists.txt b/tests/auto/widgets/kernel/qtooltip/CMakeLists.txt
new file mode 100644
index 0000000000..f63b6e63cd
--- /dev/null
+++ b/tests/auto/widgets/kernel/qtooltip/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qtooltip.pro.
+
+#####################################################################
+## tst_qtooltip Test:
+#####################################################################
+
+add_qt_test(tst_qtooltip
+ SOURCES
+ tst_qtooltip.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/qwidget/CMakeLists.txt b/tests/auto/widgets/kernel/qwidget/CMakeLists.txt
new file mode 100644
index 0000000000..df2056476b
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwidget/CMakeLists.txt
@@ -0,0 +1,58 @@
+# Generated from qwidget.pro.
+
+#####################################################################
+## tst_qwidget Test:
+#####################################################################
+
+add_qt_test(tst_qwidget
+ SOURCES
+ tst_qwidget.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set(qwidget_resource_files
+ "geometry-fullscreen.dat"
+ "geometry-maximized.dat"
+ "geometry.dat"
+)
+
+add_qt_resource(tst_qwidget "qwidget"
+ PREFIX
+ "/"
+ FILES
+ ${qwidget_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:qwidget.pro:<TRUE>:
+# testcase.timeout = "600"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qwidget CONDITION AIX
+ COMPILE_OPTIONS
+ -fpermissive
+)
+
+extend_target(tst_qwidget CONDITION APPLE
+ SOURCES
+ tst_qwidget_mac_helpers.mm
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+ ${FWSecurity}
+)
+
+extend_target(tst_qwidget CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ gdi32
+ user32
+)
diff --git a/tests/auto/widgets/kernel/qwidget_window/CMakeLists.txt b/tests/auto/widgets/kernel/qwidget_window/CMakeLists.txt
new file mode 100644
index 0000000000..c3fc672c17
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwidget_window/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qwidget_window.pro.
+
+#####################################################################
+## tst_qwidget_window Test:
+#####################################################################
+
+add_qt_test(tst_qwidget_window
+ SOURCES
+ tst_qwidget_window.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/qwidgetaction/CMakeLists.txt b/tests/auto/widgets/kernel/qwidgetaction/CMakeLists.txt
new file mode 100644
index 0000000000..887ecda4af
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwidgetaction/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qwidgetaction.pro.
+
+#####################################################################
+## tst_qwidgetaction Test:
+#####################################################################
+
+add_qt_test(tst_qwidgetaction
+ SOURCES
+ tst_qwidgetaction.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/qwidgetmetatype/CMakeLists.txt b/tests/auto/widgets/kernel/qwidgetmetatype/CMakeLists.txt
new file mode 100644
index 0000000000..dd935fdbd7
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwidgetmetatype/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qwidgetmetatype.pro.
+
+#####################################################################
+## tst_qwidgetmetatype Test:
+#####################################################################
+
+add_qt_test(tst_qwidgetmetatype
+ SOURCES
+ tst_qwidgetmetatype.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/qwidgetsvariant/CMakeLists.txt b/tests/auto/widgets/kernel/qwidgetsvariant/CMakeLists.txt
new file mode 100644
index 0000000000..076f66cd78
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwidgetsvariant/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qwidgetsvariant.pro.
+
+#####################################################################
+## tst_qwidgetsvariant Test:
+#####################################################################
+
+add_qt_test(tst_qwidgetsvariant
+ SOURCES
+ tst_qwidgetsvariant.cpp
+ INCLUDE_DIRECTORIES
+ ../../../other/qvariant_common
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/kernel/qwindowcontainer/CMakeLists.txt b/tests/auto/widgets/kernel/qwindowcontainer/CMakeLists.txt
new file mode 100644
index 0000000000..63b8b44e6f
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwindowcontainer/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qwindowcontainer.pro.
+
+#####################################################################
+## tst_qwindowcontainer Test:
+#####################################################################
+
+add_qt_test(tst_qwindowcontainer
+ SOURCES
+ tst_qwindowcontainer.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/styles/CMakeLists.txt b/tests/auto/widgets/styles/CMakeLists.txt
new file mode 100644
index 0000000000..4fc260fe39
--- /dev/null
+++ b/tests/auto/widgets/styles/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from styles.pro.
+
+if (APPLE_OSX)
+ add_subdirectory(qmacstyle)
+endif()
+add_subdirectory(qstyle)
+if (NOT APPLE_UIKIT AND NOT ANDROID AND NOT QNX)
+ add_subdirectory(qstyleoption)
+endif()
+if (QT_FEATURE_private_tests)
+ add_subdirectory(qstylesheetstyle)
+endif()
diff --git a/tests/auto/widgets/styles/qmacstyle/CMakeLists.txt b/tests/auto/widgets/styles/qmacstyle/CMakeLists.txt
new file mode 100644
index 0000000000..59d33b9589
--- /dev/null
+++ b/tests/auto/widgets/styles/qmacstyle/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qmacstyle.pro.
+
+#####################################################################
+## tst_qmacstyle Test:
+#####################################################################
+
+add_qt_test(tst_qmacstyle
+ SOURCES
+ tst_qmacstyle.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/styles/qstyle/CMakeLists.txt b/tests/auto/widgets/styles/qstyle/CMakeLists.txt
new file mode 100644
index 0000000000..1400c94633
--- /dev/null
+++ b/tests/auto/widgets/styles/qstyle/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qstyle.pro.
+
+#####################################################################
+## tst_qstyle Test:
+#####################################################################
+
+add_qt_test(tst_qstyle
+ SOURCES
+ tst_qstyle.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/styles/qstyleoption/CMakeLists.txt b/tests/auto/widgets/styles/qstyleoption/CMakeLists.txt
new file mode 100644
index 0000000000..e174057cbb
--- /dev/null
+++ b/tests/auto/widgets/styles/qstyleoption/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qstyleoption.pro.
+
+#####################################################################
+## tst_qstyleoption Test:
+#####################################################################
+
+add_qt_test(tst_qstyleoption
+ SOURCES
+ tst_qstyleoption.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qstyleoption.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/auto/widgets/styles/qstylesheetstyle/CMakeLists.txt b/tests/auto/widgets/styles/qstylesheetstyle/CMakeLists.txt
new file mode 100644
index 0000000000..ca1a2ee062
--- /dev/null
+++ b/tests/auto/widgets/styles/qstylesheetstyle/CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from qstylesheetstyle.pro.
+
+if(NOT QT_FEATURE_private_tests)
+ return()
+endif()
+
+#####################################################################
+## tst_qstylesheetstyle Test:
+#####################################################################
+
+add_qt_test(tst_qstylesheetstyle
+ SOURCES
+ tst_qstylesheetstyle.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set(resources_resource_files
+ "images/testimage.png"
+ "images/testimage@2x.png"
+)
+
+add_qt_resource(tst_qstylesheetstyle "resources"
+ PREFIX
+ "/"
+ FILES
+ ${resources_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:qstylesheetstyle.pro:<TRUE>:
+# _REQUIREMENTS = "qtConfig(private_tests)"
diff --git a/tests/auto/widgets/util/CMakeLists.txt b/tests/auto/widgets/util/CMakeLists.txt
new file mode 100644
index 0000000000..0372282e7b
--- /dev/null
+++ b/tests/auto/widgets/util/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from util.pro.
+
+add_subdirectory(qcompleter)
+add_subdirectory(qscroller)
+add_subdirectory(qsystemtrayicon)
+add_subdirectory(qundogroup)
+add_subdirectory(qundostack)
diff --git a/tests/auto/widgets/util/qcompleter/CMakeLists.txt b/tests/auto/widgets/util/qcompleter/CMakeLists.txt
new file mode 100644
index 0000000000..ffc47a8319
--- /dev/null
+++ b/tests/auto/widgets/util/qcompleter/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qcompleter.pro.
+
+#####################################################################
+## tst_qcompleter Test:
+#####################################################################
+
+add_qt_test(tst_qcompleter
+ SOURCES
+ tst_qcompleter.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qcompleter.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/auto/widgets/util/qscroller/CMakeLists.txt b/tests/auto/widgets/util/qscroller/CMakeLists.txt
new file mode 100644
index 0000000000..2a1e0dc427
--- /dev/null
+++ b/tests/auto/widgets/util/qscroller/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qscroller.pro.
+
+#####################################################################
+## tst_qscroller Test:
+#####################################################################
+
+add_qt_test(tst_qscroller
+ SOURCES
+ tst_qscroller.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/util/qsystemtrayicon/CMakeLists.txt b/tests/auto/widgets/util/qsystemtrayicon/CMakeLists.txt
new file mode 100644
index 0000000000..df6efa7281
--- /dev/null
+++ b/tests/auto/widgets/util/qsystemtrayicon/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qsystemtrayicon.pro.
+
+#####################################################################
+## tst_qsystemtrayicon Test:
+#####################################################################
+
+add_qt_test(tst_qsystemtrayicon
+ SOURCES
+ tst_qsystemtrayicon.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/util/qundogroup/CMakeLists.txt b/tests/auto/widgets/util/qundogroup/CMakeLists.txt
new file mode 100644
index 0000000000..600a7d7da1
--- /dev/null
+++ b/tests/auto/widgets/util/qundogroup/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qundogroup.pro.
+
+#####################################################################
+## tst_qundogroup Test:
+#####################################################################
+
+add_qt_test(tst_qundogroup
+ SOURCES
+ tst_qundogroup.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/util/qundostack/CMakeLists.txt b/tests/auto/widgets/util/qundostack/CMakeLists.txt
new file mode 100644
index 0000000000..5fc049991f
--- /dev/null
+++ b/tests/auto/widgets/util/qundostack/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qundostack.pro.
+
+#####################################################################
+## tst_qundostack Test:
+#####################################################################
+
+add_qt_test(tst_qundostack
+ SOURCES
+ tst_qundostack.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/CMakeLists.txt b/tests/auto/widgets/widgets/CMakeLists.txt
new file mode 100644
index 0000000000..60776f5da2
--- /dev/null
+++ b/tests/auto/widgets/widgets/CMakeLists.txt
@@ -0,0 +1,55 @@
+# Generated from widgets.pro.
+
+add_subdirectory(qabstractbutton)
+add_subdirectory(qabstractscrollarea)
+add_subdirectory(qabstractslider)
+add_subdirectory(qbuttongroup)
+add_subdirectory(qcalendarwidget)
+add_subdirectory(qcheckbox)
+add_subdirectory(qcommandlinkbutton)
+add_subdirectory(qdatetimeedit)
+add_subdirectory(qdial)
+add_subdirectory(qdialogbuttonbox)
+add_subdirectory(qdockwidget)
+add_subdirectory(qdoublespinbox)
+add_subdirectory(qfocusframe)
+add_subdirectory(qfontcombobox)
+add_subdirectory(qframe)
+add_subdirectory(qgroupbox)
+add_subdirectory(qkeysequenceedit)
+add_subdirectory(qlabel)
+add_subdirectory(qlcdnumber)
+add_subdirectory(qlineedit)
+add_subdirectory(qmdiarea)
+add_subdirectory(qmdisubwindow)
+add_subdirectory(qmenu)
+add_subdirectory(qmenubar)
+add_subdirectory(qplaintextedit)
+add_subdirectory(qprogressbar)
+add_subdirectory(qpushbutton)
+add_subdirectory(qradiobutton)
+add_subdirectory(qscrollarea)
+add_subdirectory(qscrollbar)
+add_subdirectory(qsizegrip)
+add_subdirectory(qslider)
+add_subdirectory(qspinbox)
+add_subdirectory(qsplitter)
+add_subdirectory(qstackedwidget)
+add_subdirectory(qstatusbar)
+add_subdirectory(qtabbar)
+add_subdirectory(qtabwidget)
+add_subdirectory(qtextbrowser)
+add_subdirectory(qtoolbox)
+add_subdirectory(qtoolbutton)
+
+if(QT_FEATURE_private_tests)
+ add_subdirectory(qabstractspinbox)
+ add_subdirectory(qcombobox)
+ add_subdirectory(qmainwindow)
+ add_subdirectory(qtextedit)
+ add_subdirectory(qtoolbar)
+endif()
+
+if(NOT WINRT AND QT_FEATURE_opengl)
+ add_subdirectory(qopenglwidget)
+endif()
diff --git a/tests/auto/widgets/widgets/qabstractbutton/CMakeLists.txt b/tests/auto/widgets/widgets/qabstractbutton/CMakeLists.txt
new file mode 100644
index 0000000000..c00064446b
--- /dev/null
+++ b/tests/auto/widgets/widgets/qabstractbutton/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qabstractbutton.pro.
+
+#####################################################################
+## tst_qabstractbutton Test:
+#####################################################################
+
+add_qt_test(tst_qabstractbutton
+ SOURCES
+ tst_qabstractbutton.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qabstractscrollarea/CMakeLists.txt b/tests/auto/widgets/widgets/qabstractscrollarea/CMakeLists.txt
new file mode 100644
index 0000000000..cb1b2aa936
--- /dev/null
+++ b/tests/auto/widgets/widgets/qabstractscrollarea/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qabstractscrollarea.pro.
+
+#####################################################################
+## tst_qabstractscrollarea Test:
+#####################################################################
+
+add_qt_test(tst_qabstractscrollarea
+ SOURCES
+ tst_qabstractscrollarea.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qabstractslider/CMakeLists.txt b/tests/auto/widgets/widgets/qabstractslider/CMakeLists.txt
new file mode 100644
index 0000000000..275f80db95
--- /dev/null
+++ b/tests/auto/widgets/widgets/qabstractslider/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qabstractslider.pro.
+
+#####################################################################
+## tst_qabstractslider Test:
+#####################################################################
+
+add_qt_test(tst_qabstractslider
+ SOURCES
+ tst_qabstractslider.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qabstractspinbox/CMakeLists.txt b/tests/auto/widgets/widgets/qabstractspinbox/CMakeLists.txt
new file mode 100644
index 0000000000..ecfe26fb5c
--- /dev/null
+++ b/tests/auto/widgets/widgets/qabstractspinbox/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qabstractspinbox.pro.
+
+#####################################################################
+## tst_qabstractspinbox Test:
+#####################################################################
+
+add_qt_test(tst_qabstractspinbox
+ SOURCES
+ tst_qabstractspinbox.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qbuttongroup/CMakeLists.txt b/tests/auto/widgets/widgets/qbuttongroup/CMakeLists.txt
new file mode 100644
index 0000000000..92d04e0c26
--- /dev/null
+++ b/tests/auto/widgets/widgets/qbuttongroup/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qbuttongroup.pro.
+
+#####################################################################
+## tst_qbuttongroup Test:
+#####################################################################
+
+add_qt_test(tst_qbuttongroup
+ SOURCES
+ tst_qbuttongroup.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qcalendarwidget/CMakeLists.txt b/tests/auto/widgets/widgets/qcalendarwidget/CMakeLists.txt
new file mode 100644
index 0000000000..10e24a1016
--- /dev/null
+++ b/tests/auto/widgets/widgets/qcalendarwidget/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qcalendarwidget.pro.
+
+#####################################################################
+## tst_qcalendarwidget Test:
+#####################################################################
+
+add_qt_test(tst_qcalendarwidget
+ SOURCES
+ tst_qcalendarwidget.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qcheckbox/CMakeLists.txt b/tests/auto/widgets/widgets/qcheckbox/CMakeLists.txt
new file mode 100644
index 0000000000..2418791e5d
--- /dev/null
+++ b/tests/auto/widgets/widgets/qcheckbox/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qcheckbox.pro.
+
+#####################################################################
+## tst_qcheckbox Test:
+#####################################################################
+
+add_qt_test(tst_qcheckbox
+ SOURCES
+ tst_qcheckbox.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qcombobox/CMakeLists.txt b/tests/auto/widgets/widgets/qcombobox/CMakeLists.txt
new file mode 100644
index 0000000000..ba12840211
--- /dev/null
+++ b/tests/auto/widgets/widgets/qcombobox/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from qcombobox.pro.
+
+#####################################################################
+## tst_qcombobox Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "qtlogo.png")
+list(APPEND test_data "qtlogoinverted.png")
+
+add_qt_test(tst_qcombobox
+ SOURCES
+ tst_qcombobox.cpp
+ DEFINES
+ QTEST_QPA_MOUSE_HANDLING
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/widgets/widgets/qcommandlinkbutton/CMakeLists.txt b/tests/auto/widgets/widgets/qcommandlinkbutton/CMakeLists.txt
new file mode 100644
index 0000000000..59ba375358
--- /dev/null
+++ b/tests/auto/widgets/widgets/qcommandlinkbutton/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qcommandlinkbutton.pro.
+
+#####################################################################
+## tst_qcommandlinkbutton Test:
+#####################################################################
+
+add_qt_test(tst_qcommandlinkbutton
+ SOURCES
+ tst_qcommandlinkbutton.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qdatetimeedit/CMakeLists.txt b/tests/auto/widgets/widgets/qdatetimeedit/CMakeLists.txt
new file mode 100644
index 0000000000..9d9f641f92
--- /dev/null
+++ b/tests/auto/widgets/widgets/qdatetimeedit/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qdatetimeedit.pro.
+
+#####################################################################
+## tst_qdatetimeedit Test:
+#####################################################################
+
+add_qt_test(tst_qdatetimeedit
+ SOURCES
+ tst_qdatetimeedit.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qdial/CMakeLists.txt b/tests/auto/widgets/widgets/qdial/CMakeLists.txt
new file mode 100644
index 0000000000..e725edacb6
--- /dev/null
+++ b/tests/auto/widgets/widgets/qdial/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qdial.pro.
+
+#####################################################################
+## tst_qdial Test:
+#####################################################################
+
+add_qt_test(tst_qdial
+ SOURCES
+ tst_qdial.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qdialogbuttonbox/CMakeLists.txt b/tests/auto/widgets/widgets/qdialogbuttonbox/CMakeLists.txt
new file mode 100644
index 0000000000..c4961f13a1
--- /dev/null
+++ b/tests/auto/widgets/widgets/qdialogbuttonbox/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qdialogbuttonbox.pro.
+
+#####################################################################
+## tst_qdialogbuttonbox Test:
+#####################################################################
+
+add_qt_test(tst_qdialogbuttonbox
+ SOURCES
+ tst_qdialogbuttonbox.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qdockwidget/CMakeLists.txt b/tests/auto/widgets/widgets/qdockwidget/CMakeLists.txt
new file mode 100644
index 0000000000..415498c649
--- /dev/null
+++ b/tests/auto/widgets/widgets/qdockwidget/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qdockwidget.pro.
+
+#####################################################################
+## tst_qdockwidget Test:
+#####################################################################
+
+add_qt_test(tst_qdockwidget
+ SOURCES
+ tst_qdockwidget.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qdoublespinbox/CMakeLists.txt b/tests/auto/widgets/widgets/qdoublespinbox/CMakeLists.txt
new file mode 100644
index 0000000000..b639289db8
--- /dev/null
+++ b/tests/auto/widgets/widgets/qdoublespinbox/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qdoublespinbox.pro.
+
+#####################################################################
+## tst_qdoublespinbox Test:
+#####################################################################
+
+add_qt_test(tst_qdoublespinbox
+ SOURCES
+ tst_qdoublespinbox.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qfocusframe/CMakeLists.txt b/tests/auto/widgets/widgets/qfocusframe/CMakeLists.txt
new file mode 100644
index 0000000000..85160faed7
--- /dev/null
+++ b/tests/auto/widgets/widgets/qfocusframe/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qfocusframe.pro.
+
+#####################################################################
+## tst_qfocusframe Test:
+#####################################################################
+
+add_qt_test(tst_qfocusframe
+ SOURCES
+ tst_qfocusframe.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qfontcombobox/CMakeLists.txt b/tests/auto/widgets/widgets/qfontcombobox/CMakeLists.txt
new file mode 100644
index 0000000000..777abc48c5
--- /dev/null
+++ b/tests/auto/widgets/widgets/qfontcombobox/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qfontcombobox.pro.
+
+#####################################################################
+## tst_qfontcombobox Test:
+#####################################################################
+
+add_qt_test(tst_qfontcombobox
+ SOURCES
+ tst_qfontcombobox.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qframe/CMakeLists.txt b/tests/auto/widgets/widgets/qframe/CMakeLists.txt
new file mode 100644
index 0000000000..ae23555fa5
--- /dev/null
+++ b/tests/auto/widgets/widgets/qframe/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qframe.pro.
+
+#####################################################################
+## tst_qframe Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ images/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qframe
+ SOURCES
+ tst_qframe.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/widgets/widgets/qgroupbox/CMakeLists.txt b/tests/auto/widgets/widgets/qgroupbox/CMakeLists.txt
new file mode 100644
index 0000000000..09d4623cd9
--- /dev/null
+++ b/tests/auto/widgets/widgets/qgroupbox/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qgroupbox.pro.
+
+#####################################################################
+## tst_qgroupbox Test:
+#####################################################################
+
+add_qt_test(tst_qgroupbox
+ SOURCES
+ tst_qgroupbox.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qkeysequenceedit/CMakeLists.txt b/tests/auto/widgets/widgets/qkeysequenceedit/CMakeLists.txt
new file mode 100644
index 0000000000..c57f8b5c0a
--- /dev/null
+++ b/tests/auto/widgets/widgets/qkeysequenceedit/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qkeysequenceedit.pro.
+
+#####################################################################
+## tst_qkeysequenceedit Test:
+#####################################################################
+
+add_qt_test(tst_qkeysequenceedit
+ SOURCES
+ tst_qkeysequenceedit.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qlabel/CMakeLists.txt b/tests/auto/widgets/widgets/qlabel/CMakeLists.txt
new file mode 100644
index 0000000000..3d6d055fed
--- /dev/null
+++ b/tests/auto/widgets/widgets/qlabel/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from qlabel.pro.
+
+#####################################################################
+## tst_qlabel Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ testdata/*)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ *.png)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qlabel
+ SOURCES
+ tst_qlabel.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/widgets/widgets/qlcdnumber/CMakeLists.txt b/tests/auto/widgets/widgets/qlcdnumber/CMakeLists.txt
new file mode 100644
index 0000000000..fbd9ff5913
--- /dev/null
+++ b/tests/auto/widgets/widgets/qlcdnumber/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qlcdnumber.pro.
+
+#####################################################################
+## tst_qlcdnumber Test:
+#####################################################################
+
+add_qt_test(tst_qlcdnumber
+ SOURCES
+ tst_qlcdnumber.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qlineedit/CMakeLists.txt b/tests/auto/widgets/widgets/qlineedit/CMakeLists.txt
new file mode 100644
index 0000000000..6e9d80ee66
--- /dev/null
+++ b/tests/auto/widgets/widgets/qlineedit/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from qlineedit.pro.
+
+#####################################################################
+## tst_qlineedit Test:
+#####################################################################
+
+add_qt_test(tst_qlineedit
+ SOURCES
+ tst_qlineedit.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qlineedit CONDITION APPLE_OSX
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+)
diff --git a/tests/auto/widgets/widgets/qmainwindow/CMakeLists.txt b/tests/auto/widgets/widgets/qmainwindow/CMakeLists.txt
new file mode 100644
index 0000000000..292ab5aeb1
--- /dev/null
+++ b/tests/auto/widgets/widgets/qmainwindow/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qmainwindow.pro.
+
+#####################################################################
+## tst_qmainwindow Test:
+#####################################################################
+
+add_qt_test(tst_qmainwindow
+ SOURCES
+ tst_qmainwindow.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qmdiarea/CMakeLists.txt b/tests/auto/widgets/widgets/qmdiarea/CMakeLists.txt
new file mode 100644
index 0000000000..d796baf93d
--- /dev/null
+++ b/tests/auto/widgets/widgets/qmdiarea/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from qmdiarea.pro.
+
+#####################################################################
+## tst_qmdiarea Test:
+#####################################################################
+
+add_qt_test(tst_qmdiarea
+ SOURCES
+ tst_qmdiarea.cpp
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ INCLUDE_DIRECTORIES
+ .
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qmdiarea CONDITION TARGET Qt::OpenGL
+ PUBLIC_LIBRARIES
+ Qt::OpenGL
+)
+
+extend_target(tst_qmdiarea CONDITION APPLE
+ PUBLIC_LIBRARIES
+ ${FWSecurity}
+)
diff --git a/tests/auto/widgets/widgets/qmdisubwindow/CMakeLists.txt b/tests/auto/widgets/widgets/qmdisubwindow/CMakeLists.txt
new file mode 100644
index 0000000000..9844b9192f
--- /dev/null
+++ b/tests/auto/widgets/widgets/qmdisubwindow/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qmdisubwindow.pro.
+
+#####################################################################
+## tst_qmdisubwindow Test:
+#####################################################################
+
+add_qt_test(tst_qmdisubwindow
+ SOURCES
+ tst_qmdisubwindow.cpp
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_CAST_TO_ASCII
+ INCLUDE_DIRECTORIES
+ .
+ LIBRARIES
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qmenu/CMakeLists.txt b/tests/auto/widgets/widgets/qmenu/CMakeLists.txt
new file mode 100644
index 0000000000..4c1863d9ef
--- /dev/null
+++ b/tests/auto/widgets/widgets/qmenu/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from qmenu.pro.
+
+#####################################################################
+## tst_qmenu Test:
+#####################################################################
+
+add_qt_test(tst_qmenu
+ SOURCES
+ tst_qmenu.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qmenu CONDITION APPLE_OSX
+ SOURCES
+ tst_qmenu_mac.mm
+ PUBLIC_LIBRARIES
+ objc
+)
+
+extend_target(tst_qmenu CONDITION NOT APPLE_OSX
+ DEFINES
+ QTEST_QPA_MOUSE_HANDLING
+)
diff --git a/tests/auto/widgets/widgets/qmenubar/CMakeLists.txt b/tests/auto/widgets/widgets/qmenubar/CMakeLists.txt
new file mode 100644
index 0000000000..cc1ce337ea
--- /dev/null
+++ b/tests/auto/widgets/widgets/qmenubar/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from qmenubar.pro.
+
+#####################################################################
+## tst_qmenubar Test:
+#####################################################################
+
+add_qt_test(tst_qmenubar
+ SOURCES
+ tst_qmenubar.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qmenubar CONDITION APPLE_OSX
+ SOURCES
+ tst_qmenubar_mac.mm
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+)
diff --git a/tests/auto/widgets/widgets/qopenglwidget/CMakeLists.txt b/tests/auto/widgets/widgets/qopenglwidget/CMakeLists.txt
new file mode 100644
index 0000000000..01f44ef78e
--- /dev/null
+++ b/tests/auto/widgets/widgets/qopenglwidget/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qopenglwidget.pro.
+
+#####################################################################
+## tst_qopenglwidget Test:
+#####################################################################
+
+add_qt_test(tst_qopenglwidget
+ SOURCES
+ tst_qopenglwidget.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qplaintextedit/CMakeLists.txt b/tests/auto/widgets/widgets/qplaintextedit/CMakeLists.txt
new file mode 100644
index 0000000000..0774967c8c
--- /dev/null
+++ b/tests/auto/widgets/widgets/qplaintextedit/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from qplaintextedit.pro.
+
+#####################################################################
+## tst_qplaintextedit Test:
+#####################################################################
+
+add_qt_test(tst_qplaintextedit
+ SOURCES
+ tst_qplaintextedit.cpp
+ INCLUDE_DIRECTORIES
+ ..
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qplaintextedit CONDITION APPLE_OSX
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+)
diff --git a/tests/auto/widgets/widgets/qprogressbar/CMakeLists.txt b/tests/auto/widgets/widgets/qprogressbar/CMakeLists.txt
new file mode 100644
index 0000000000..f8b3ac38d9
--- /dev/null
+++ b/tests/auto/widgets/widgets/qprogressbar/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qprogressbar.pro.
+
+#####################################################################
+## tst_qprogressbar Test:
+#####################################################################
+
+add_qt_test(tst_qprogressbar
+ SOURCES
+ tst_qprogressbar.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qpushbutton/CMakeLists.txt b/tests/auto/widgets/widgets/qpushbutton/CMakeLists.txt
new file mode 100644
index 0000000000..8d1300de79
--- /dev/null
+++ b/tests/auto/widgets/widgets/qpushbutton/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qpushbutton.pro.
+
+#####################################################################
+## tst_qpushbutton Test:
+#####################################################################
+
+add_qt_test(tst_qpushbutton
+ SOURCES
+ tst_qpushbutton.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qradiobutton/CMakeLists.txt b/tests/auto/widgets/widgets/qradiobutton/CMakeLists.txt
new file mode 100644
index 0000000000..10db8a2db8
--- /dev/null
+++ b/tests/auto/widgets/widgets/qradiobutton/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qradiobutton.pro.
+
+#####################################################################
+## tst_qradiobutton Test:
+#####################################################################
+
+add_qt_test(tst_qradiobutton
+ SOURCES
+ tst_qradiobutton.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qscrollarea/CMakeLists.txt b/tests/auto/widgets/widgets/qscrollarea/CMakeLists.txt
new file mode 100644
index 0000000000..cdfb32e0a2
--- /dev/null
+++ b/tests/auto/widgets/widgets/qscrollarea/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qscrollarea.pro.
+
+#####################################################################
+## tst_qscrollarea Test:
+#####################################################################
+
+add_qt_test(tst_qscrollarea
+ SOURCES
+ tst_qscrollarea.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qscrollbar/CMakeLists.txt b/tests/auto/widgets/widgets/qscrollbar/CMakeLists.txt
new file mode 100644
index 0000000000..92b8049ef6
--- /dev/null
+++ b/tests/auto/widgets/widgets/qscrollbar/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qscrollbar.pro.
+
+#####################################################################
+## tst_qscrollbar Test:
+#####################################################################
+
+add_qt_test(tst_qscrollbar
+ SOURCES
+ tst_qscrollbar.cpp
+ LIBRARIES
+ Qt::TestPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qsizegrip/CMakeLists.txt b/tests/auto/widgets/widgets/qsizegrip/CMakeLists.txt
new file mode 100644
index 0000000000..d3b28797f2
--- /dev/null
+++ b/tests/auto/widgets/widgets/qsizegrip/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qsizegrip.pro.
+
+#####################################################################
+## tst_qsizegrip Test:
+#####################################################################
+
+add_qt_test(tst_qsizegrip
+ SOURCES
+ tst_qsizegrip.cpp
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qslider/CMakeLists.txt b/tests/auto/widgets/widgets/qslider/CMakeLists.txt
new file mode 100644
index 0000000000..583f12a1fb
--- /dev/null
+++ b/tests/auto/widgets/widgets/qslider/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qslider.pro.
+
+#####################################################################
+## tst_qslider Test:
+#####################################################################
+
+add_qt_test(tst_qslider
+ SOURCES
+ tst_qslider.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qspinbox/CMakeLists.txt b/tests/auto/widgets/widgets/qspinbox/CMakeLists.txt
new file mode 100644
index 0000000000..826de28cb4
--- /dev/null
+++ b/tests/auto/widgets/widgets/qspinbox/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qspinbox.pro.
+
+#####################################################################
+## tst_qspinbox Test:
+#####################################################################
+
+add_qt_test(tst_qspinbox
+ SOURCES
+ tst_qspinbox.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qsplashscreen/CMakeLists.txt b/tests/auto/widgets/widgets/qsplashscreen/CMakeLists.txt
new file mode 100644
index 0000000000..babe84f43e
--- /dev/null
+++ b/tests/auto/widgets/widgets/qsplashscreen/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qsplashscreen.pro.
+
+#####################################################################
+## tst_qsplashscreen Test:
+#####################################################################
+
+add_qt_test(tst_qsplashscreen
+ SOURCES
+ tst_qsplashscreen.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qsplitter/CMakeLists.txt b/tests/auto/widgets/widgets/qsplitter/CMakeLists.txt
new file mode 100644
index 0000000000..98c165f034
--- /dev/null
+++ b/tests/auto/widgets/widgets/qsplitter/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qsplitter.pro.
+
+#####################################################################
+## tst_qsplitter Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "extradata.txt")
+list(APPEND test_data "setSizes3.dat")
+
+add_qt_test(tst_qsplitter
+ SOURCES
+ tst_qsplitter.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/widgets/widgets/qstackedwidget/CMakeLists.txt b/tests/auto/widgets/widgets/qstackedwidget/CMakeLists.txt
new file mode 100644
index 0000000000..37807eb73a
--- /dev/null
+++ b/tests/auto/widgets/widgets/qstackedwidget/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qstackedwidget.pro.
+
+#####################################################################
+## tst_qstackedwidget Test:
+#####################################################################
+
+add_qt_test(tst_qstackedwidget
+ SOURCES
+ tst_qstackedwidget.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qstatusbar/CMakeLists.txt b/tests/auto/widgets/widgets/qstatusbar/CMakeLists.txt
new file mode 100644
index 0000000000..56f3c960fd
--- /dev/null
+++ b/tests/auto/widgets/widgets/qstatusbar/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qstatusbar.pro.
+
+#####################################################################
+## tst_qstatusbar Test:
+#####################################################################
+
+add_qt_test(tst_qstatusbar
+ SOURCES
+ tst_qstatusbar.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qtabbar/CMakeLists.txt b/tests/auto/widgets/widgets/qtabbar/CMakeLists.txt
new file mode 100644
index 0000000000..d23d23d88f
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtabbar/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qtabbar.pro.
+
+#####################################################################
+## tst_qtabbar Test:
+#####################################################################
+
+add_qt_test(tst_qtabbar
+ SOURCES
+ tst_qtabbar.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qtabwidget/CMakeLists.txt b/tests/auto/widgets/widgets/qtabwidget/CMakeLists.txt
new file mode 100644
index 0000000000..5cf53d1be5
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtabwidget/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from qtabwidget.pro.
+
+#####################################################################
+## tst_qtabwidget Test:
+#####################################################################
+
+add_qt_test(tst_qtabwidget
+ SOURCES
+ tst_qtabwidget.cpp
+ INCLUDE_DIRECTORIES
+ ..
+ LIBRARIES
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qtabwidget CONDITION WIN32 AND NOT WINRT
+ PUBLIC_LIBRARIES
+ user32
+)
diff --git a/tests/auto/widgets/widgets/qtextbrowser/CMakeLists.txt b/tests/auto/widgets/widgets/qtextbrowser/CMakeLists.txt
new file mode 100644
index 0000000000..503dc32a83
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtextbrowser/CMakeLists.txt
@@ -0,0 +1,37 @@
+# Generated from qtextbrowser.pro.
+
+#####################################################################
+## tst_qtextbrowser Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ *.html)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ *.md)
+list(APPEND test_data ${test_data_glob})
+list(APPEND test_data "markdown.really")
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ subdir/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qtextbrowser
+ SOURCES
+ tst_qtextbrowser.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qtextbrowser CONDITION builtin_testdata
+ DEFINES
+ BUILTIN_TESTDATA
+)
diff --git a/tests/auto/widgets/widgets/qtextedit/CMakeLists.txt b/tests/auto/widgets/widgets/qtextedit/CMakeLists.txt
new file mode 100644
index 0000000000..db077d6354
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtextedit/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from qtextedit.pro.
+
+#####################################################################
+## tst_qtextedit Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "fullWidthSelection")
+
+add_qt_test(tst_qtextedit
+ SOURCES
+ tst_qtextedit.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ TESTDATA ${test_data}
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qtextedit CONDITION APPLE_OSX
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+)
diff --git a/tests/auto/widgets/widgets/qtoolbar/CMakeLists.txt b/tests/auto/widgets/widgets/qtoolbar/CMakeLists.txt
new file mode 100644
index 0000000000..43803ccdff
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtoolbar/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qtoolbar.pro.
+
+#####################################################################
+## tst_qtoolbar Test:
+#####################################################################
+
+add_qt_test(tst_qtoolbar
+ SOURCES
+ tst_qtoolbar.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qtoolbox/CMakeLists.txt b/tests/auto/widgets/widgets/qtoolbox/CMakeLists.txt
new file mode 100644
index 0000000000..dc3e5d016c
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtoolbox/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qtoolbox.pro.
+
+#####################################################################
+## tst_qtoolbox Test:
+#####################################################################
+
+add_qt_test(tst_qtoolbox
+ SOURCES
+ tst_qtoolbox.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/widgets/qtoolbutton/CMakeLists.txt b/tests/auto/widgets/widgets/qtoolbutton/CMakeLists.txt
new file mode 100644
index 0000000000..ae36488341
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtoolbutton/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qtoolbutton.pro.
+
+#####################################################################
+## tst_qtoolbutton Test:
+#####################################################################
+
+add_qt_test(tst_qtoolbutton
+ SOURCES
+ tst_qtoolbutton.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/auto/xml/CMakeLists.txt b/tests/auto/xml/CMakeLists.txt
new file mode 100644
index 0000000000..703cba344d
--- /dev/null
+++ b/tests/auto/xml/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from xml.pro.
+
+add_subdirectory(dom)
+add_subdirectory(sax)
diff --git a/tests/auto/xml/dom/CMakeLists.txt b/tests/auto/xml/dom/CMakeLists.txt
new file mode 100644
index 0000000000..08a7621e88
--- /dev/null
+++ b/tests/auto/xml/dom/CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from dom.pro.
+
+add_subdirectory(qdom)
diff --git a/tests/auto/xml/dom/qdom/CMakeLists.txt b/tests/auto/xml/dom/qdom/CMakeLists.txt
new file mode 100644
index 0000000000..be70ec08cc
--- /dev/null
+++ b/tests/auto/xml/dom/qdom/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from qdom.pro.
+
+#####################################################################
+## tst_qdom Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ testdata/*)
+list(APPEND test_data ${test_data_glob})
+list(APPEND test_data "doubleNamespaces.xml")
+list(APPEND test_data "umlaut.xml")
+
+add_qt_test(tst_qdom
+ SOURCES
+ tst_qdom.cpp
+ PUBLIC_LIBRARIES
+ Qt::Xml
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/xml/sax/CMakeLists.txt b/tests/auto/xml/sax/CMakeLists.txt
new file mode 100644
index 0000000000..dd826d5e4f
--- /dev/null
+++ b/tests/auto/xml/sax/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from sax.pro.
+
+add_subdirectory(qxml)
+if(TARGET Qt::Network)
+ add_subdirectory(qxmlinputsource)
+ add_subdirectory(qxmlsimplereader)
+endif()
diff --git a/tests/auto/xml/sax/qxml/CMakeLists.txt b/tests/auto/xml/sax/qxml/CMakeLists.txt
new file mode 100644
index 0000000000..bfbf7fe979
--- /dev/null
+++ b/tests/auto/xml/sax/qxml/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qxml.pro.
+
+#####################################################################
+## tst_qxml Test:
+#####################################################################
+
+# Collect test data
+list(APPEND test_data "0x010D.xml")
+
+add_qt_test(tst_qxml
+ SOURCES
+ tst_qxml.cpp
+ PUBLIC_LIBRARIES
+ Qt::Xml
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/xml/sax/qxmlinputsource/CMakeLists.txt b/tests/auto/xml/sax/qxmlinputsource/CMakeLists.txt
new file mode 100644
index 0000000000..48ba5f6e3f
--- /dev/null
+++ b/tests/auto/xml/sax/qxmlinputsource/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qxmlinputsource.pro.
+
+#####################################################################
+## tst_qxmlinputsource Test:
+#####################################################################
+
+add_qt_test(tst_qxmlinputsource
+ SOURCES
+ tst_qxmlinputsource.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Xml
+)
diff --git a/tests/auto/xml/sax/qxmlsimplereader/CMakeLists.txt b/tests/auto/xml/sax/qxmlsimplereader/CMakeLists.txt
new file mode 100644
index 0000000000..19fa0a002f
--- /dev/null
+++ b/tests/auto/xml/sax/qxmlsimplereader/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from qxmlsimplereader.pro.
+
+#####################################################################
+## tst_qxmlsimplereader Test:
+#####################################################################
+
+# Collect test data
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ encodings/*)
+list(APPEND test_data ${test_data_glob})
+file(GLOB_RECURSE test_data_glob
+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
+ xmldocs/*)
+list(APPEND test_data ${test_data_glob})
+
+add_qt_test(tst_qxmlsimplereader
+ SOURCES
+ parser/parser.cpp parser/parser.h
+ tst_qxmlsimplereader.cpp
+ INCLUDE_DIRECTORIES
+ parser
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Xml
+ TESTDATA ${test_data}
+)
diff --git a/tests/auto/xml/sax/qxmlsimplereader/parser/CMakeLists.txt b/tests/auto/xml/sax/qxmlsimplereader/parser/CMakeLists.txt
new file mode 100644
index 0000000000..6ffb17ac0f
--- /dev/null
+++ b/tests/auto/xml/sax/qxmlsimplereader/parser/CMakeLists.txt
@@ -0,0 +1,19 @@
+# special case skip regeneration
+
+cmake_minimum_required(VERSION 3.14.0)
+
+project(Parser CXX)
+find_package(Qt6 REQUIRED COMPONENTS Core Gui Xml)
+
+add_executable(parser)
+
+target_sources(parser PRIVATE
+ main.cpp
+ parser.cpp
+ parser.h
+)
+
+target_link_libraries(parser PRIVATE
+ Qt::Gui
+ Qt::Xml
+)
diff --git a/tests/benchmarks/CMakeLists.txt b/tests/benchmarks/CMakeLists.txt
new file mode 100644
index 0000000000..a59ba35e50
--- /dev/null
+++ b/tests/benchmarks/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from benchmarks.pro.
+
+add_subdirectory(corelib)
+add_subdirectory(sql)
+if(TARGET Qt::DBus)
+ add_subdirectory(dbus)
+endif()
+if(TARGET Qt::Gui)
+ add_subdirectory(gui)
+endif()
+if(TARGET Qt::Network)
+ add_subdirectory(network)
+endif()
+if(TARGET Qt::Test)
+ add_subdirectory(testlib)
+endif()
+if(TARGET Qt::Widgets)
+ add_subdirectory(widgets)
+endif()
diff --git a/tests/benchmarks/corelib/CMakeLists.txt b/tests/benchmarks/corelib/CMakeLists.txt
new file mode 100644
index 0000000000..3414c39ef8
--- /dev/null
+++ b/tests/benchmarks/corelib/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from corelib.pro.
+
+add_subdirectory(io)
+add_subdirectory(json)
+add_subdirectory(mimetypes)
+add_subdirectory(kernel)
+add_subdirectory(text)
+add_subdirectory(thread)
+add_subdirectory(time)
+add_subdirectory(tools)
+add_subdirectory(codecs)
+add_subdirectory(plugin)
diff --git a/tests/benchmarks/corelib/codecs/CMakeLists.txt b/tests/benchmarks/corelib/codecs/CMakeLists.txt
new file mode 100644
index 0000000000..56f8edcc9e
--- /dev/null
+++ b/tests/benchmarks/corelib/codecs/CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from codecs.pro.
+
+add_subdirectory(qtextcodec)
diff --git a/tests/benchmarks/corelib/codecs/qtextcodec/CMakeLists.txt b/tests/benchmarks/corelib/codecs/qtextcodec/CMakeLists.txt
new file mode 100644
index 0000000000..ea6ed8519b
--- /dev/null
+++ b/tests/benchmarks/corelib/codecs/qtextcodec/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtextcodec.pro.
+
+#####################################################################
+## tst_bench_qtextcodec Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qtextcodec
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qtextcodec.pro:<TRUE>:
+# TESTDATA = "utf-8.txt"
diff --git a/tests/benchmarks/corelib/io/CMakeLists.txt b/tests/benchmarks/corelib/io/CMakeLists.txt
new file mode 100644
index 0000000000..3419c4a28c
--- /dev/null
+++ b/tests/benchmarks/corelib/io/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from io.pro.
+
+add_subdirectory(qdir)
+add_subdirectory(qdiriterator)
+add_subdirectory(qfile)
+add_subdirectory(qfileinfo)
+add_subdirectory(qiodevice)
+add_subdirectory(qtemporaryfile)
+add_subdirectory(qtextstream)
+if(QT_FEATURE_process)
+ add_subdirectory(qprocess)
+endif()
diff --git a/tests/benchmarks/corelib/io/qdir/10000/CMakeLists.txt b/tests/benchmarks/corelib/io/qdir/10000/CMakeLists.txt
new file mode 100644
index 0000000000..51f603b595
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qdir/10000/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from 10000.pro.
+
+#####################################################################
+## tst_bench_qdir_10000 Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qdir_10000
+ SOURCES
+ bench_qdir_10000.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:10000.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/io/qdir/CMakeLists.txt b/tests/benchmarks/corelib/io/qdir/CMakeLists.txt
new file mode 100644
index 0000000000..10185014fa
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qdir/CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from qdir.pro.
+
+add_subdirectory(10000)
diff --git a/tests/benchmarks/corelib/io/qdir/tree/CMakeLists.txt b/tests/benchmarks/corelib/io/qdir/tree/CMakeLists.txt
new file mode 100644
index 0000000000..e3102a3389
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qdir/tree/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from tree.pro.
+
+#####################################################################
+## bench_qdir_tree Binary:
+#####################################################################
+
+add_qt_benchmark(bench_qdir_tree
+ SOURCES
+ bench_qdir_tree.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+# Resources:
+set(bench_qdir_tree_resource_files
+ "4.6.0-list.txt"
+)
+
+add_qt_resource(bench_qdir_tree "bench_qdir_tree"
+ PREFIX
+ "/"
+ FILES
+ ${bench_qdir_tree_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:tree.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/io/qdiriterator/CMakeLists.txt b/tests/benchmarks/corelib/io/qdiriterator/CMakeLists.txt
new file mode 100644
index 0000000000..f107377dfd
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qdiriterator/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qdiriterator.pro.
+
+#####################################################################
+## tst_bench_qdiriterator Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qdiriterator
+ SOURCES
+ main.cpp
+ qfilesystemiterator.cpp qfilesystemiterator.h
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
diff --git a/tests/benchmarks/corelib/io/qfile/CMakeLists.txt b/tests/benchmarks/corelib/io/qfile/CMakeLists.txt
new file mode 100644
index 0000000000..f69f7cfca7
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qfile/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from qfile.pro.
+
+#####################################################################
+## tst_bench_qfile Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qfile
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qfile.pro:<TRUE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_bench_qfile CONDITION WIN32
+ DEFINES
+ _CRT_SECURE_NO_WARNINGS
+)
diff --git a/tests/benchmarks/corelib/io/qfileinfo/CMakeLists.txt b/tests/benchmarks/corelib/io/qfileinfo/CMakeLists.txt
new file mode 100644
index 0000000000..f0c93f3b55
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qfileinfo/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qfileinfo.pro.
+
+#####################################################################
+## tst_bench_qfileinfo Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qfileinfo
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qfileinfo.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/io/qiodevice/CMakeLists.txt b/tests/benchmarks/corelib/io/qiodevice/CMakeLists.txt
new file mode 100644
index 0000000000..7663bdb99d
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qiodevice/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qiodevice.pro.
+
+#####################################################################
+## tst_bench_qiodevice Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qiodevice
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qiodevice.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/io/qprocess/CMakeLists.txt b/tests/benchmarks/corelib/io/qprocess/CMakeLists.txt
new file mode 100644
index 0000000000..d599539142
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qprocess/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from qprocess.pro.
+
+add_subdirectory(testProcessLoopback)
+add_subdirectory(test)
diff --git a/tests/benchmarks/corelib/io/qprocess/test/CMakeLists.txt b/tests/benchmarks/corelib/io/qprocess/test/CMakeLists.txt
new file mode 100644
index 0000000000..90a9960f68
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qprocess/test/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_bench_qprocess Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qprocess
+ SOURCES
+ ../tst_bench_qprocess.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/io/qprocess/testProcessLoopback/CMakeLists.txt b/tests/benchmarks/corelib/io/qprocess/testProcessLoopback/CMakeLists.txt
new file mode 100644
index 0000000000..44b18a4826
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qprocess/testProcessLoopback/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from testProcessLoopback.pro.
+
+#####################################################################
+## testProcessLoopback Binary:
+#####################################################################
+
+add_qt_benchmark(testProcessLoopback
+ OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/"
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(testProcessLoopback CONDITION WINRT
+ LINK_OPTIONS
+ "/ENTRY:mainCRTStartup"
+)
diff --git a/tests/benchmarks/corelib/io/qtemporaryfile/CMakeLists.txt b/tests/benchmarks/corelib/io/qtemporaryfile/CMakeLists.txt
new file mode 100644
index 0000000000..82b885bb17
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qtemporaryfile/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtemporaryfile.pro.
+
+#####################################################################
+## tst_bench_qtemporaryfile Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qtemporaryfile
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qtemporaryfile.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/io/qtextstream/CMakeLists.txt b/tests/benchmarks/corelib/io/qtextstream/CMakeLists.txt
new file mode 100644
index 0000000000..6dd11f1bbb
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qtextstream/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qtextstream.pro.
+
+#####################################################################
+## tst_bench_qtextstream Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qtextstream
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qtextstream.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/io/qurl/CMakeLists.txt b/tests/benchmarks/corelib/io/qurl/CMakeLists.txt
new file mode 100644
index 0000000000..26d98b7eb4
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qurl/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from qurl.pro.
+
+#####################################################################
+## tst_qurl Binary:
+#####################################################################
+
+add_qt_benchmark(tst_qurl
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qurl.pro:<TRUE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qurl CONDITION WIN32
+ DEFINES
+ _CRT_SECURE_NO_WARNINGS
+)
diff --git a/tests/benchmarks/corelib/json/CMakeLists.txt b/tests/benchmarks/corelib/json/CMakeLists.txt
new file mode 100644
index 0000000000..312cae8a45
--- /dev/null
+++ b/tests/benchmarks/corelib/json/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from json.pro.
+
+#####################################################################
+## tst_bench_qtbinaryjson Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qtbinaryjson
+ SOURCES
+ tst_bench_qtbinaryjson.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:json.pro:<TRUE>:
+# TESTDATA = "numbers.json" "test.json"
diff --git a/tests/benchmarks/corelib/kernel/CMakeLists.txt b/tests/benchmarks/corelib/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..2b41ea30f7
--- /dev/null
+++ b/tests/benchmarks/corelib/kernel/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from kernel.pro.
+
+add_subdirectory(events)
+add_subdirectory(qmetatype)
+add_subdirectory(qvariant)
+add_subdirectory(qcoreapplication)
+add_subdirectory(qtimer_vs_qmetaobject)
+if(TARGET Qt::Widgets)
+ add_subdirectory(qmetaobject)
+ add_subdirectory(qobject)
+endif()
diff --git a/tests/benchmarks/corelib/kernel/events/CMakeLists.txt b/tests/benchmarks/corelib/kernel/events/CMakeLists.txt
new file mode 100644
index 0000000000..1e35891126
--- /dev/null
+++ b/tests/benchmarks/corelib/kernel/events/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from events.pro.
+
+#####################################################################
+## tst_bench_events Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_events
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:events.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/kernel/qcoreapplication/CMakeLists.txt b/tests/benchmarks/corelib/kernel/qcoreapplication/CMakeLists.txt
new file mode 100644
index 0000000000..173b3b9077
--- /dev/null
+++ b/tests/benchmarks/corelib/kernel/qcoreapplication/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qcoreapplication.pro.
+
+#####################################################################
+## tst_bench_qcoreapplication Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qcoreapplication
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qcoreapplication.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/kernel/qmetaobject/CMakeLists.txt b/tests/benchmarks/corelib/kernel/qmetaobject/CMakeLists.txt
new file mode 100644
index 0000000000..e6da0721d3
--- /dev/null
+++ b/tests/benchmarks/corelib/kernel/qmetaobject/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qmetaobject.pro.
+
+#####################################################################
+## tst_bench_qmetaobject Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qmetaobject
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qmetaobject.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/kernel/qmetatype/CMakeLists.txt b/tests/benchmarks/corelib/kernel/qmetatype/CMakeLists.txt
new file mode 100644
index 0000000000..00ca47aadc
--- /dev/null
+++ b/tests/benchmarks/corelib/kernel/qmetatype/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qmetatype.pro.
+
+#####################################################################
+## tst_bench_qmetatype Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qmetatype
+ SOURCES
+ tst_qmetatype.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qmetatype.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/kernel/qobject/CMakeLists.txt b/tests/benchmarks/corelib/kernel/qobject/CMakeLists.txt
new file mode 100644
index 0000000000..4644708b54
--- /dev/null
+++ b/tests/benchmarks/corelib/kernel/qobject/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qobject.pro.
+
+#####################################################################
+## tst_bench_qobject Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qobject
+ SOURCES
+ main.cpp
+ object.cpp object.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qobject.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/kernel/qtimer_vs_qmetaobject/.prev_CMakeLists.txt b/tests/benchmarks/corelib/kernel/qtimer_vs_qmetaobject/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..4160fe7e36
--- /dev/null
+++ b/tests/benchmarks/corelib/kernel/qtimer_vs_qmetaobject/.prev_CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qtimer_vs_qmetaobject.pro.
+
+#####################################################################
+## qtimer_vs_qmetaobject Binary:
+#####################################################################
+
+add_qt_benchmark(qtimer_vs_qmetaobject
+ SOURCES
+ tst_qtimer_vs_qmetaobject.cpp
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qtimer_vs_qmetaobject.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/kernel/qtimer_vs_qmetaobject/CMakeLists.txt b/tests/benchmarks/corelib/kernel/qtimer_vs_qmetaobject/CMakeLists.txt
new file mode 100644
index 0000000000..c76c4dca18
--- /dev/null
+++ b/tests/benchmarks/corelib/kernel/qtimer_vs_qmetaobject/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qtimer_vs_qmetaobject.pro.
+
+#####################################################################
+## qtimer_vs_qmetaobject Binary:
+#####################################################################
+
+add_qt_benchmark(qtimer_vs_qmetaobject
+ SOURCES
+ tst_qtimer_vs_qmetaobject.cpp
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ Qt::Test
+ Threads::Threads # special case
+)
+
+#### Keys ignored in scope 1:.:.:qtimer_vs_qmetaobject.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/kernel/qvariant/CMakeLists.txt b/tests/benchmarks/corelib/kernel/qvariant/CMakeLists.txt
new file mode 100644
index 0000000000..5e5230566d
--- /dev/null
+++ b/tests/benchmarks/corelib/kernel/qvariant/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from qvariant.pro.
+
+#####################################################################
+## tst_bench_qvariant Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qvariant
+ SOURCES
+ tst_qvariant.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_bench_qvariant CONDITION NOT TARGET Qt::Gui
+ PUBLIC_LIBRARIES
+ # Remove: gui
+)
diff --git a/tests/benchmarks/corelib/mimetypes/CMakeLists.txt b/tests/benchmarks/corelib/mimetypes/CMakeLists.txt
new file mode 100644
index 0000000000..c825780e69
--- /dev/null
+++ b/tests/benchmarks/corelib/mimetypes/CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from mimetypes.pro.
+
+add_subdirectory(qmimedatabase)
diff --git a/tests/benchmarks/corelib/mimetypes/qmimedatabase/CMakeLists.txt b/tests/benchmarks/corelib/mimetypes/qmimedatabase/CMakeLists.txt
new file mode 100644
index 0000000000..7d6b6dc4f8
--- /dev/null
+++ b/tests/benchmarks/corelib/mimetypes/qmimedatabase/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qmimedatabase.pro.
+
+#####################################################################
+## tst_bench_qmimedatabase Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qmimedatabase
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/plugin/CMakeLists.txt b/tests/benchmarks/corelib/plugin/CMakeLists.txt
new file mode 100644
index 0000000000..3ae12b23f5
--- /dev/null
+++ b/tests/benchmarks/corelib/plugin/CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from plugin.pro.
+
+add_subdirectory(quuid)
diff --git a/tests/benchmarks/corelib/plugin/quuid/CMakeLists.txt b/tests/benchmarks/corelib/plugin/quuid/CMakeLists.txt
new file mode 100644
index 0000000000..2251914957
--- /dev/null
+++ b/tests/benchmarks/corelib/plugin/quuid/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from quuid.pro.
+
+#####################################################################
+## tst_bench_quuid Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_quuid
+ SOURCES
+ tst_quuid.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:quuid.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/text/CMakeLists.txt b/tests/benchmarks/corelib/text/CMakeLists.txt
new file mode 100644
index 0000000000..8319d1bf3b
--- /dev/null
+++ b/tests/benchmarks/corelib/text/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from text.pro.
+
+add_subdirectory(qbytearray)
+add_subdirectory(qchar)
+add_subdirectory(qlocale)
+add_subdirectory(qstringbuilder)
+add_subdirectory(qstringlist)
+if(GCC)
+ add_subdirectory(qstring)
+endif()
diff --git a/tests/benchmarks/corelib/text/qbytearray/CMakeLists.txt b/tests/benchmarks/corelib/text/qbytearray/CMakeLists.txt
new file mode 100644
index 0000000000..9c7fae62eb
--- /dev/null
+++ b/tests/benchmarks/corelib/text/qbytearray/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qbytearray.pro.
+
+#####################################################################
+## tst_bench_qbytearray Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qbytearray
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qbytearray.pro:<TRUE>:
+# TEMPLATE = "app"
+# TESTDATA = "main.cpp"
diff --git a/tests/benchmarks/corelib/text/qchar/CMakeLists.txt b/tests/benchmarks/corelib/text/qchar/CMakeLists.txt
new file mode 100644
index 0000000000..ba99813d2b
--- /dev/null
+++ b/tests/benchmarks/corelib/text/qchar/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qchar.pro.
+
+#####################################################################
+## tst_bench_qchar Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qchar
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/text/qlocale/CMakeLists.txt b/tests/benchmarks/corelib/text/qlocale/CMakeLists.txt
new file mode 100644
index 0000000000..7e67472013
--- /dev/null
+++ b/tests/benchmarks/corelib/text/qlocale/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qlocale.pro.
+
+#####################################################################
+## tst_bench_qlocale Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qlocale
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/text/qregexp/CMakeLists.txt b/tests/benchmarks/corelib/text/qregexp/CMakeLists.txt
new file mode 100644
index 0000000000..e1dcd5c131
--- /dev/null
+++ b/tests/benchmarks/corelib/text/qregexp/CMakeLists.txt
@@ -0,0 +1,46 @@
+# Generated from qregexp.pro.
+
+#####################################################################
+## tst_bench_qregexp Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qregexp
+ EXCEPTIONS
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+# Resources:
+set(qregexp_resource_files
+ "main.cpp"
+)
+
+add_qt_resource(tst_bench_qregexp "qregexp"
+ PREFIX
+ "/"
+ FILES
+ ${qregexp_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:qregexp.pro:<TRUE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_bench_qregexp CONDITION TARGET Qt::Script AND NOT pcre
+ DEFINES
+ HAVE_JSC
+ PUBLIC_LIBRARIES
+ Qt::Script
+)
+
+extend_target(tst_bench_qregexp CONDITION (NOT QNX) AND (EXISTS _ss_[QT_SYSROOT]/usr/include/boost/regex.hpp)
+ DEFINES
+ HAVE_BOOST
+ PUBLIC_LIBRARIES
+ boost_regex
+)
diff --git a/tests/benchmarks/corelib/text/qstring/CMakeLists.txt b/tests/benchmarks/corelib/text/qstring/CMakeLists.txt
new file mode 100644
index 0000000000..2999cb4682
--- /dev/null
+++ b/tests/benchmarks/corelib/text/qstring/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qstring.pro.
+
+#####################################################################
+## tst_bench_qstring Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qstring
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/text/qstringbuilder/CMakeLists.txt b/tests/benchmarks/corelib/text/qstringbuilder/CMakeLists.txt
new file mode 100644
index 0000000000..e326414d7a
--- /dev/null
+++ b/tests/benchmarks/corelib/text/qstringbuilder/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qstringbuilder.pro.
+
+#####################################################################
+## tst_bench_qstringbuilder Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qstringbuilder
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+ COMPILE_OPTIONS
+ -g
+)
+
+#### Keys ignored in scope 1:.:.:qstringbuilder.pro:<TRUE>:
+# QMAKE_CFLAGS = "-g"
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/text/qstringlist/CMakeLists.txt b/tests/benchmarks/corelib/text/qstringlist/CMakeLists.txt
new file mode 100644
index 0000000000..a341f1aaa8
--- /dev/null
+++ b/tests/benchmarks/corelib/text/qstringlist/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qstringlist.pro.
+
+#####################################################################
+## tst_bench_qstringlist Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qstringlist
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/thread/CMakeLists.txt b/tests/benchmarks/corelib/thread/CMakeLists.txt
new file mode 100644
index 0000000000..dc257262a3
--- /dev/null
+++ b/tests/benchmarks/corelib/thread/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from thread.pro.
+
+add_subdirectory(qmutex)
+add_subdirectory(qreadwritelock)
+add_subdirectory(qthreadstorage)
+add_subdirectory(qthreadpool)
+add_subdirectory(qwaitcondition)
diff --git a/tests/benchmarks/corelib/thread/qmutex/CMakeLists.txt b/tests/benchmarks/corelib/thread/qmutex/CMakeLists.txt
new file mode 100644
index 0000000000..71226282ab
--- /dev/null
+++ b/tests/benchmarks/corelib/thread/qmutex/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qmutex.pro.
+
+#####################################################################
+## tst_bench_qmutex Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qmutex
+ SOURCES
+ tst_qmutex.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qmutex.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/thread/qreadwritelock/CMakeLists.txt b/tests/benchmarks/corelib/thread/qreadwritelock/CMakeLists.txt
new file mode 100644
index 0000000000..c85020606a
--- /dev/null
+++ b/tests/benchmarks/corelib/thread/qreadwritelock/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qreadwritelock.pro.
+
+#####################################################################
+## tst_bench_qreadwritelock Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qreadwritelock
+ SOURCES
+ tst_qreadwritelock.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qreadwritelock.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/thread/qthreadpool/CMakeLists.txt b/tests/benchmarks/corelib/thread/qthreadpool/CMakeLists.txt
new file mode 100644
index 0000000000..00dbc9c298
--- /dev/null
+++ b/tests/benchmarks/corelib/thread/qthreadpool/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qthreadpool.pro.
+
+#####################################################################
+## tst_bench_qthreadpool Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qthreadpool
+ SOURCES
+ tst_qthreadpool.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qthreadpool.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/thread/qthreadstorage/CMakeLists.txt b/tests/benchmarks/corelib/thread/qthreadstorage/CMakeLists.txt
new file mode 100644
index 0000000000..ed60ec4495
--- /dev/null
+++ b/tests/benchmarks/corelib/thread/qthreadstorage/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qthreadstorage.pro.
+
+#####################################################################
+## tst_bench_qthreadstorage Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qthreadstorage
+ SOURCES
+ tst_qthreadstorage.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qthreadstorage.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/thread/qwaitcondition/CMakeLists.txt b/tests/benchmarks/corelib/thread/qwaitcondition/CMakeLists.txt
new file mode 100644
index 0000000000..4de82d7cc9
--- /dev/null
+++ b/tests/benchmarks/corelib/thread/qwaitcondition/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qwaitcondition.pro.
+
+#####################################################################
+## tst_bench_qwaitcondition Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qwaitcondition
+ SOURCES
+ tst_qwaitcondition.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qwaitcondition.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/time/CMakeLists.txt b/tests/benchmarks/corelib/time/CMakeLists.txt
new file mode 100644
index 0000000000..086650edb6
--- /dev/null
+++ b/tests/benchmarks/corelib/time/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from time.pro.
+
+add_subdirectory(qdate)
+add_subdirectory(qdatetime)
+add_subdirectory(qtimezone)
diff --git a/tests/benchmarks/corelib/time/qdate/CMakeLists.txt b/tests/benchmarks/corelib/time/qdate/CMakeLists.txt
new file mode 100644
index 0000000000..7ae18a42f5
--- /dev/null
+++ b/tests/benchmarks/corelib/time/qdate/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdate.pro.
+
+#####################################################################
+## tst_bench_qdate Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qdate
+ SOURCES
+ tst_bench_qdate.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/time/qdatetime/CMakeLists.txt b/tests/benchmarks/corelib/time/qdatetime/CMakeLists.txt
new file mode 100644
index 0000000000..b44f1a5bfc
--- /dev/null
+++ b/tests/benchmarks/corelib/time/qdatetime/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdatetime.pro.
+
+#####################################################################
+## tst_bench_qdatetime Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qdatetime
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/time/qtimezone/CMakeLists.txt b/tests/benchmarks/corelib/time/qtimezone/CMakeLists.txt
new file mode 100644
index 0000000000..60e8ceba13
--- /dev/null
+++ b/tests/benchmarks/corelib/time/qtimezone/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qtimezone.pro.
+
+#####################################################################
+## tst_bench_qtimezone Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qtimezone
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/tools/CMakeLists.txt b/tests/benchmarks/corelib/tools/CMakeLists.txt
new file mode 100644
index 0000000000..6aed3d0f90
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from tools.pro.
+
+add_subdirectory(containers-associative)
+add_subdirectory(containers-sequential)
+add_subdirectory(qcontiguouscache)
+add_subdirectory(qcryptographichash)
+add_subdirectory(qlist)
+add_subdirectory(qmap)
+add_subdirectory(qrect)
+add_subdirectory(qringbuffer)
+add_subdirectory(qstack)
+add_subdirectory(qvector)
+add_subdirectory(qalgorithms)
diff --git a/tests/benchmarks/corelib/tools/containers-associative/CMakeLists.txt b/tests/benchmarks/corelib/tools/containers-associative/CMakeLists.txt
new file mode 100644
index 0000000000..0e2dace380
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/containers-associative/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from containers-associative.pro.
+
+#####################################################################
+## tst_bench_containers-associative Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_containers-associative
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:containers-associative.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/tools/containers-sequential/CMakeLists.txt b/tests/benchmarks/corelib/tools/containers-sequential/CMakeLists.txt
new file mode 100644
index 0000000000..40f455752e
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/containers-sequential/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from containers-sequential.pro.
+
+#####################################################################
+## tst_bench_containers-sequential Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_containers-sequential
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:containers-sequential.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/tools/qalgorithms/CMakeLists.txt b/tests/benchmarks/corelib/tools/qalgorithms/CMakeLists.txt
new file mode 100644
index 0000000000..99c6a7061d
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qalgorithms/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qalgorithms.pro.
+
+#####################################################################
+## tst_bench_qalgorithms Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qalgorithms
+ SOURCES
+ tst_qalgorithms.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/tools/qchar/CMakeLists.txt b/tests/benchmarks/corelib/tools/qchar/CMakeLists.txt
new file mode 100644
index 0000000000..c51e2a0059
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qchar/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qchar SOURCES main.cpp)
diff --git a/tests/benchmarks/corelib/tools/qcontiguouscache/CMakeLists.txt b/tests/benchmarks/corelib/tools/qcontiguouscache/CMakeLists.txt
new file mode 100644
index 0000000000..126c0e7a50
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qcontiguouscache/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qcontiguouscache.pro.
+
+#####################################################################
+## tst_bench_qcontiguouscache Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qcontiguouscache
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/tools/qcryptographichash/CMakeLists.txt b/tests/benchmarks/corelib/tools/qcryptographichash/CMakeLists.txt
new file mode 100644
index 0000000000..1400027c1f
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qcryptographichash/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qcryptographichash.pro.
+
+#####################################################################
+## tst_bench_qcryptographichash Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qcryptographichash
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/tools/qdatetime/CMakeLists.txt b/tests/benchmarks/corelib/tools/qdatetime/CMakeLists.txt
new file mode 100644
index 0000000000..6875fdd613
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qdatetime/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qdatetime SOURCES main.cpp)
diff --git a/tests/benchmarks/corelib/tools/qhash/CMakeLists.txt b/tests/benchmarks/corelib/tools/qhash/CMakeLists.txt
new file mode 100644
index 0000000000..5b3a0fe5f5
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qhash/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qhash.pro.
+
+#####################################################################
+## tst_hash Binary:
+#####################################################################
+
+add_qt_benchmark(tst_hash
+ SOURCES
+ main.cpp
+ outofline.cpp
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/tools/qlist/CMakeLists.txt b/tests/benchmarks/corelib/tools/qlist/CMakeLists.txt
new file mode 100644
index 0000000000..ba40760910
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qlist/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qlist.pro.
+
+#####################################################################
+## tst_bench_qlist Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qlist
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/tools/qlocale/CMakeLists.txt b/tests/benchmarks/corelib/tools/qlocale/CMakeLists.txt
new file mode 100644
index 0000000000..b8a23bc757
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qlocale/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qlocale SOURCES main.cpp)
diff --git a/tests/benchmarks/corelib/tools/qmap/CMakeLists.txt b/tests/benchmarks/corelib/tools/qmap/CMakeLists.txt
new file mode 100644
index 0000000000..a98c7d7157
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qmap/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qmap.pro.
+
+#####################################################################
+## tst_bench_qmap Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qmap
+ SOURCES
+ main.cpp
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/tools/qrect/CMakeLists.txt b/tests/benchmarks/corelib/tools/qrect/CMakeLists.txt
new file mode 100644
index 0000000000..4218092a88
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qrect/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qrect.pro.
+
+#####################################################################
+## tst_bench_qrect Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qrect
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qrect.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/tools/qringbuffer/CMakeLists.txt b/tests/benchmarks/corelib/tools/qringbuffer/CMakeLists.txt
new file mode 100644
index 0000000000..dade4273fa
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qringbuffer/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qringbuffer.pro.
+
+#####################################################################
+## tst_bench_qringbuffer Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qringbuffer
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qringbuffer.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/corelib/tools/qset/CMakeLists.txt b/tests/benchmarks/corelib/tools/qset/CMakeLists.txt
new file mode 100644
index 0000000000..40ee622f89
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qset/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qset.pro.
+
+#####################################################################
+## tst_qset Binary:
+#####################################################################
+
+add_qt_benchmark(tst_qset
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/tools/qstack/CMakeLists.txt b/tests/benchmarks/corelib/tools/qstack/CMakeLists.txt
new file mode 100644
index 0000000000..75ac16cad6
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qstack/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qstack.pro.
+
+#####################################################################
+## tst_bench_stack Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_stack
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/corelib/tools/qstring/CMakeLists.txt b/tests/benchmarks/corelib/tools/qstring/CMakeLists.txt
new file mode 100644
index 0000000000..1dd6678e8e
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qstring/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qstring SOURCES main.cpp)
diff --git a/tests/benchmarks/corelib/tools/qtimezone/CMakeLists.txt b/tests/benchmarks/corelib/tools/qtimezone/CMakeLists.txt
new file mode 100644
index 0000000000..3947ae1c5e
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qtimezone/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qtimezone SOURCES main.cpp)
diff --git a/tests/benchmarks/corelib/tools/qvector/CMakeLists.txt b/tests/benchmarks/corelib/tools/qvector/CMakeLists.txt
new file mode 100644
index 0000000000..19575872bc
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qvector/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qvector.pro.
+
+#####################################################################
+## tst_bench_vector Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_vector
+ SOURCES
+ main.cpp
+ outofline.cpp
+ INCLUDE_DIRECTORIES
+ .
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/dbus/CMakeLists.txt b/tests/benchmarks/dbus/CMakeLists.txt
new file mode 100644
index 0000000000..cd246922a1
--- /dev/null
+++ b/tests/benchmarks/dbus/CMakeLists.txt
@@ -0,0 +1,6 @@
+# Generated from dbus.pro.
+
+add_subdirectory(qdbustype)
+if(QT_FEATURE_process)
+ add_subdirectory(qdbusperformance)
+endif()
diff --git a/tests/benchmarks/dbus/qdbusperformance/CMakeLists.txt b/tests/benchmarks/dbus/qdbusperformance/CMakeLists.txt
new file mode 100644
index 0000000000..5d79f36090
--- /dev/null
+++ b/tests/benchmarks/dbus/qdbusperformance/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from qdbusperformance.pro.
+
+add_subdirectory(server)
+add_subdirectory(test)
diff --git a/tests/benchmarks/dbus/qdbusperformance/server/CMakeLists.txt b/tests/benchmarks/dbus/qdbusperformance/server/CMakeLists.txt
new file mode 100644
index 0000000000..a3b5e98d4a
--- /dev/null
+++ b/tests/benchmarks/dbus/qdbusperformance/server/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from server.pro.
+
+#####################################################################
+## server Binary:
+#####################################################################
+
+add_qt_benchmark(server
+ GUI
+ OUTPUT_DIRECTORY "."
+ SOURCES
+ ../serverobject.h
+ server.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+)
diff --git a/tests/benchmarks/dbus/qdbusperformance/test/CMakeLists.txt b/tests/benchmarks/dbus/qdbusperformance/test/CMakeLists.txt
new file mode 100644
index 0000000000..dadca9412c
--- /dev/null
+++ b/tests/benchmarks/dbus/qdbusperformance/test/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from test.pro.
+
+#####################################################################
+## tst_qdbusperformance Binary:
+#####################################################################
+
+add_qt_benchmark(tst_qdbusperformance
+ SOURCES
+ ../serverobject.h
+ ../tst_qdbusperformance.cpp
+ PUBLIC_LIBRARIES
+ Qt::DBus
+ Qt::Test
+)
diff --git a/tests/benchmarks/dbus/qdbustype/CMakeLists.txt b/tests/benchmarks/dbus/qdbustype/CMakeLists.txt
new file mode 100644
index 0000000000..1b663ac19f
--- /dev/null
+++ b/tests/benchmarks/dbus/qdbustype/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from qdbustype.pro.
+
+#####################################################################
+## tst_bench_qdbustype Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qdbustype
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBusPrivate
+ PUBLIC_LIBRARIES
+ Qt::DBus
+ Qt::Test
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_bench_qdbustype CONDITION QT_FEATURE_dbus_linked
+ DEFINES
+ QT_LINKED_LIBDBUS
+ PUBLIC_LIBRARIES
+ dbus-1
+)
+
+extend_target(tst_bench_qdbustype CONDITION NOT QT_FEATURE_dbus_linked
+ SOURCES
+ ../../../../src/dbus/qdbus_symbols.cpp
+)
diff --git a/tests/benchmarks/gui/CMakeLists.txt b/tests/benchmarks/gui/CMakeLists.txt
new file mode 100644
index 0000000000..6af9d8e224
--- /dev/null
+++ b/tests/benchmarks/gui/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from gui.pro.
+
+add_subdirectory(animation)
+add_subdirectory(image)
+add_subdirectory(kernel)
+add_subdirectory(math3d)
+add_subdirectory(painting)
+add_subdirectory(text)
diff --git a/tests/benchmarks/gui/animation/CMakeLists.txt b/tests/benchmarks/gui/animation/CMakeLists.txt
new file mode 100644
index 0000000000..6190f29a65
--- /dev/null
+++ b/tests/benchmarks/gui/animation/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from animation.pro.
+
+if(TARGET Qt::Widgets)
+ add_subdirectory(qanimation)
+endif()
diff --git a/tests/benchmarks/gui/animation/qanimation/CMakeLists.txt b/tests/benchmarks/gui/animation/qanimation/CMakeLists.txt
new file mode 100644
index 0000000000..38b4c50db8
--- /dev/null
+++ b/tests/benchmarks/gui/animation/qanimation/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qanimation.pro.
+
+#####################################################################
+## tst_bench_qanimation Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qanimation
+ SOURCES
+ dummyanimation.cpp dummyanimation.h
+ dummyobject.cpp dummyobject.h
+ main.cpp
+ rectanimation.cpp rectanimation.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
diff --git a/tests/benchmarks/gui/image/CMakeLists.txt b/tests/benchmarks/gui/image/CMakeLists.txt
new file mode 100644
index 0000000000..77cfeedc3e
--- /dev/null
+++ b/tests/benchmarks/gui/image/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from image.pro.
+
+add_subdirectory(blendbench)
+add_subdirectory(qimageconversion)
+add_subdirectory(qimagereader)
+add_subdirectory(qimagescale)
+add_subdirectory(qpixmap)
+add_subdirectory(qpixmapcache)
diff --git a/tests/benchmarks/gui/image/blendbench/CMakeLists.txt b/tests/benchmarks/gui/image/blendbench/CMakeLists.txt
new file mode 100644
index 0000000000..3599a51371
--- /dev/null
+++ b/tests/benchmarks/gui/image/blendbench/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from blendbench.pro.
+
+#####################################################################
+## tst_bench_blendbench Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_blendbench
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:blendbench.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/image/qimageconversion/CMakeLists.txt b/tests/benchmarks/gui/image/qimageconversion/CMakeLists.txt
new file mode 100644
index 0000000000..d9b481ca46
--- /dev/null
+++ b/tests/benchmarks/gui/image/qimageconversion/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from qimageconversion.pro.
+
+#####################################################################
+## tst_bench_imageConversion Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_imageConversion
+ SOURCES
+ tst_qimageconversion.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qimageconversion.pro:<TRUE>:
+# QT_FOR_CONFIG = "gui-private"
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_bench_imageConversion CONDITION QT_FEATURE_gif
+ DEFINES
+ QTEST_HAVE_GIF
+)
+
+extend_target(tst_bench_imageConversion CONDITION QT_FEATURE_jpeg
+ DEFINES
+ QTEST_HAVE_JPEG
+)
diff --git a/tests/benchmarks/gui/image/qimagereader/CMakeLists.txt b/tests/benchmarks/gui/image/qimagereader/CMakeLists.txt
new file mode 100644
index 0000000000..be72a44187
--- /dev/null
+++ b/tests/benchmarks/gui/image/qimagereader/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from qimagereader.pro.
+
+#####################################################################
+## tst_bench_qimagereader Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qimagereader
+ SOURCES
+ tst_qimagereader.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qimagereader.pro:<TRUE>:
+# QT_FOR_CONFIG = "gui-private"
+# TEMPLATE = "app"
+# TESTDATA = "images/*"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_bench_qimagereader CONDITION QT_FEATURE_gif
+ DEFINES
+ QTEST_HAVE_GIF
+)
+
+extend_target(tst_bench_qimagereader CONDITION QT_FEATURE_jpeg
+ DEFINES
+ QTEST_HAVE_JPEG
+)
diff --git a/tests/benchmarks/gui/image/qimagescale/CMakeLists.txt b/tests/benchmarks/gui/image/qimagescale/CMakeLists.txt
new file mode 100644
index 0000000000..cbf3e5459b
--- /dev/null
+++ b/tests/benchmarks/gui/image/qimagescale/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qimagescale.pro.
+
+#####################################################################
+## tst_bench_imageScale Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_imageScale
+ SOURCES
+ tst_qimagescale.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qimagescale.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/image/qpixmap/CMakeLists.txt b/tests/benchmarks/gui/image/qpixmap/CMakeLists.txt
new file mode 100644
index 0000000000..2798fe4dbb
--- /dev/null
+++ b/tests/benchmarks/gui/image/qpixmap/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qpixmap.pro.
+
+#####################################################################
+## tst_bench_qpixmap Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qpixmap
+ SOURCES
+ tst_qpixmap.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qpixmap.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/image/qpixmapcache/CMakeLists.txt b/tests/benchmarks/gui/image/qpixmapcache/CMakeLists.txt
new file mode 100644
index 0000000000..46347ef94a
--- /dev/null
+++ b/tests/benchmarks/gui/image/qpixmapcache/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qpixmapcache.pro.
+
+#####################################################################
+## tst_bench_qpixmapcache Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qpixmapcache
+ SOURCES
+ tst_qpixmapcache.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qpixmapcache.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/kernel/CMakeLists.txt b/tests/benchmarks/gui/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..451b12388d
--- /dev/null
+++ b/tests/benchmarks/gui/kernel/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from kernel.pro.
+
+add_subdirectory(qguimetatype)
+add_subdirectory(qguivariant)
diff --git a/tests/benchmarks/gui/kernel/qguimetatype/CMakeLists.txt b/tests/benchmarks/gui/kernel/qguimetatype/CMakeLists.txt
new file mode 100644
index 0000000000..cf250cdaf6
--- /dev/null
+++ b/tests/benchmarks/gui/kernel/qguimetatype/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qguimetatype.pro.
+
+#####################################################################
+## tst_bench_qguimetatype Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qguimetatype
+ SOURCES
+ tst_qguimetatype.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qguimetatype.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/kernel/qguivariant/CMakeLists.txt b/tests/benchmarks/gui/kernel/qguivariant/CMakeLists.txt
new file mode 100644
index 0000000000..0a6ddda456
--- /dev/null
+++ b/tests/benchmarks/gui/kernel/qguivariant/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qguivariant.pro.
+
+#####################################################################
+## tst_bench_qguivariant Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qguivariant
+ SOURCES
+ tst_qguivariant.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qguivariant.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/math3d/CMakeLists.txt b/tests/benchmarks/gui/math3d/CMakeLists.txt
new file mode 100644
index 0000000000..53e56a83a3
--- /dev/null
+++ b/tests/benchmarks/gui/math3d/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from math3d.pro.
+
+add_subdirectory(qmatrix4x4)
+add_subdirectory(qquaternion)
diff --git a/tests/benchmarks/gui/math3d/qmatrix4x4/CMakeLists.txt b/tests/benchmarks/gui/math3d/qmatrix4x4/CMakeLists.txt
new file mode 100644
index 0000000000..8d594ef1e7
--- /dev/null
+++ b/tests/benchmarks/gui/math3d/qmatrix4x4/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qmatrix4x4.pro.
+
+#####################################################################
+## tst_bench_qmatrix4x4 Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qmatrix4x4
+ SOURCES
+ tst_qmatrix4x4.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qmatrix4x4.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/math3d/qquaternion/CMakeLists.txt b/tests/benchmarks/gui/math3d/qquaternion/CMakeLists.txt
new file mode 100644
index 0000000000..2409a6c43a
--- /dev/null
+++ b/tests/benchmarks/gui/math3d/qquaternion/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qquaternion.pro.
+
+#####################################################################
+## tst_bench_qquaternion Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qquaternion
+ SOURCES
+ tst_qquaternion.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qquaternion.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/painting/CMakeLists.txt b/tests/benchmarks/gui/painting/CMakeLists.txt
new file mode 100644
index 0000000000..080fe582f2
--- /dev/null
+++ b/tests/benchmarks/gui/painting/CMakeLists.txt
@@ -0,0 +1,11 @@
+# Generated from painting.pro.
+
+add_subdirectory(drawtexture)
+add_subdirectory(qcolor)
+add_subdirectory(qregion)
+add_subdirectory(qtransform)
+add_subdirectory(lancebench)
+if(TARGET Qt::Widgets)
+ add_subdirectory(qpainter)
+ add_subdirectory(qtbench)
+endif()
diff --git a/tests/benchmarks/gui/painting/drawtexture/CMakeLists.txt b/tests/benchmarks/gui/painting/drawtexture/CMakeLists.txt
new file mode 100644
index 0000000000..b108753c93
--- /dev/null
+++ b/tests/benchmarks/gui/painting/drawtexture/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from drawtexture.pro.
+
+#####################################################################
+## tst_bench_drawtexture Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_drawtexture
+ SOURCES
+ tst_drawtexture.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:drawtexture.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/painting/lancebench/CMakeLists.txt b/tests/benchmarks/gui/painting/lancebench/CMakeLists.txt
new file mode 100644
index 0000000000..e3b60c0827
--- /dev/null
+++ b/tests/benchmarks/gui/painting/lancebench/CMakeLists.txt
@@ -0,0 +1,150 @@
+# Generated from lancebench.pro.
+
+#####################################################################
+## tst_bench_lancebench Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_lancebench
+ SOURCES
+ ../../../../auto/other/lancelot/paintcommands.cpp ../../../../auto/other/lancelot/paintcommands.h
+ tst_lancebench.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+# Resources:
+set_source_files_properties("../../../../auto/other/lancelot/images/alpha.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/alpha.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/alpha2x2.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/alpha2x2.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/bitmap.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/bitmap.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/border.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/border.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/borderimage.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/borderimage.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/dome_argb32.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_argb32.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/dome_indexed.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_indexed.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/dome_indexed_mask.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_indexed_mask.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/dome_mono.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_mono.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/dome_mono_128.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_mono_128.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/dome_mono_palette.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_mono_palette.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/dome_rgb32.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_rgb32.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/dot.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dot.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/face.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/face.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/gam030.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/gam030.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/gam045.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/gam045.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/gam056.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/gam056.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/gam100.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/gam100.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/gam200.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/gam200.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/image.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/image.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/mask.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/mask.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/mask_100.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/mask_100.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/masked.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/masked.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/sign.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/sign.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/solid.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/solid.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/solid2x2.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/solid2x2.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/struct-image-01.jpg"
+ PROPERTIES QT_RESOURCE_ALIAS "images/struct-image-01.jpg"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/struct-image-01.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/struct-image-01.png"
+)
+set_source_files_properties("../../../../auto/other/lancelot/images/zebra.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/zebra.png"
+)
+set(images_resource_files
+ "images/alpha.png"
+ "images/alpha2x2.png"
+ "images/bitmap.png"
+ "images/border.png"
+ "images/borderimage.png"
+ "images/dome_argb32.png"
+ "images/dome_indexed.png"
+ "images/dome_indexed_mask.png"
+ "images/dome_mono.png"
+ "images/dome_mono_128.png"
+ "images/dome_mono_palette.png"
+ "images/dome_rgb32.png"
+ "images/dot.png"
+ "images/face.png"
+ "images/gam030.png"
+ "images/gam045.png"
+ "images/gam056.png"
+ "images/gam100.png"
+ "images/gam200.png"
+ "images/image.png"
+ "images/mask.png"
+ "images/mask_100.png"
+ "images/masked.png"
+ "images/sign.png"
+ "images/solid.png"
+ "images/solid2x2.png"
+ "images/struct-image-01.jpg"
+ "images/struct-image-01.png"
+ "images/zebra.png"
+)
+
+add_qt_resource(tst_bench_lancebench "images"
+ PREFIX
+ "/"
+ BASE
+ "../../../../auto/other/lancelot"
+ FILES
+ ${images_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:lancebench.pro:<TRUE>:
+# TEMPLATE = "app"
+# TESTDATA = "../../../../auto/other/lancelot/scripts/*"
diff --git a/tests/benchmarks/gui/painting/qcolor/CMakeLists.txt b/tests/benchmarks/gui/painting/qcolor/CMakeLists.txt
new file mode 100644
index 0000000000..2e365678e9
--- /dev/null
+++ b/tests/benchmarks/gui/painting/qcolor/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qcolor.pro.
+
+#####################################################################
+## tst_bench_qcolor Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qcolor
+ SOURCES
+ tst_qcolor.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qcolor.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/painting/qpainter/CMakeLists.txt b/tests/benchmarks/gui/painting/qpainter/CMakeLists.txt
new file mode 100644
index 0000000000..926af40a2e
--- /dev/null
+++ b/tests/benchmarks/gui/painting/qpainter/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qpainter.pro.
+
+#####################################################################
+## tst_bench_qpainter Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qpainter
+ SOURCES
+ tst_qpainter.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qpainter.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/painting/qregion/CMakeLists.txt b/tests/benchmarks/gui/painting/qregion/CMakeLists.txt
new file mode 100644
index 0000000000..e864a1f61d
--- /dev/null
+++ b/tests/benchmarks/gui/painting/qregion/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qregion.pro.
+
+#####################################################################
+## tst_bench_qregion Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qregion
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qregion.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/painting/qtbench/CMakeLists.txt b/tests/benchmarks/gui/painting/qtbench/CMakeLists.txt
new file mode 100644
index 0000000000..009deeb528
--- /dev/null
+++ b/tests/benchmarks/gui/painting/qtbench/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qtbench.pro.
+
+#####################################################################
+## tst_bench_qtbench Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qtbench
+ SOURCES
+ tst_qtbench.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qtbench.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/painting/qtransform/CMakeLists.txt b/tests/benchmarks/gui/painting/qtransform/CMakeLists.txt
new file mode 100644
index 0000000000..aa24b4a19e
--- /dev/null
+++ b/tests/benchmarks/gui/painting/qtransform/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qtransform.pro.
+
+#####################################################################
+## tst_bench_qtransform Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qtransform
+ SOURCES
+ tst_qtransform.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qtransform.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/text/CMakeLists.txt b/tests/benchmarks/gui/text/CMakeLists.txt
new file mode 100644
index 0000000000..630f01091d
--- /dev/null
+++ b/tests/benchmarks/gui/text/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from text.pro.
+
+add_subdirectory(qfontmetrics)
+add_subdirectory(qtext)
+add_subdirectory(qtextdocument)
diff --git a/tests/benchmarks/gui/text/qfontmetrics/CMakeLists.txt b/tests/benchmarks/gui/text/qfontmetrics/CMakeLists.txt
new file mode 100644
index 0000000000..af42a93d27
--- /dev/null
+++ b/tests/benchmarks/gui/text/qfontmetrics/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qfontmetrics.pro.
+
+#####################################################################
+## tst_bench_QFontMetrics Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_QFontMetrics
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qfontmetrics.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/gui/text/qtext/CMakeLists.txt b/tests/benchmarks/gui/text/qtext/CMakeLists.txt
new file mode 100644
index 0000000000..a6d4952eba
--- /dev/null
+++ b/tests/benchmarks/gui/text/qtext/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qtext.pro.
+
+#####################################################################
+## tst_bench_QText Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_QText
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qtext.pro:<TRUE>:
+# TEMPLATE = "app"
+# TESTDATA = "bidi.txt"
diff --git a/tests/benchmarks/gui/text/qtextdocument/CMakeLists.txt b/tests/benchmarks/gui/text/qtextdocument/CMakeLists.txt
new file mode 100644
index 0000000000..1b956b459b
--- /dev/null
+++ b/tests/benchmarks/gui/text/qtextdocument/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qtextdocument.pro.
+
+#####################################################################
+## tst_bench_QTextDocument Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_QTextDocument
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qtextdocument.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/network/CMakeLists.txt b/tests/benchmarks/network/CMakeLists.txt
new file mode 100644
index 0000000000..8b1a7ac1ff
--- /dev/null
+++ b/tests/benchmarks/network/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from network.pro.
+
+add_subdirectory(access)
+add_subdirectory(kernel)
+add_subdirectory(socket)
+if(QT_FEATURE_openssl)
+ add_subdirectory(ssl)
+endif()
diff --git a/tests/benchmarks/network/access/CMakeLists.txt b/tests/benchmarks/network/access/CMakeLists.txt
new file mode 100644
index 0000000000..58f72cd248
--- /dev/null
+++ b/tests/benchmarks/network/access/CMakeLists.txt
@@ -0,0 +1,6 @@
+# Generated from access.pro.
+
+add_subdirectory(qfile_vs_qnetworkaccessmanager)
+add_subdirectory(qnetworkreply)
+add_subdirectory(qnetworkreply_from_cache)
+add_subdirectory(qnetworkdiskcache)
diff --git a/tests/benchmarks/network/access/qfile_vs_qnetworkaccessmanager/CMakeLists.txt b/tests/benchmarks/network/access/qfile_vs_qnetworkaccessmanager/CMakeLists.txt
new file mode 100644
index 0000000000..abfb0206d3
--- /dev/null
+++ b/tests/benchmarks/network/access/qfile_vs_qnetworkaccessmanager/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qfile_vs_qnetworkaccessmanager.pro.
+
+#####################################################################
+## tst_bench_qfile_vs_qnetworkaccessmanager Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qfile_vs_qnetworkaccessmanager
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qfile_vs_qnetworkaccessmanager.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/network/access/qnetworkdiskcache/CMakeLists.txt b/tests/benchmarks/network/access/qnetworkdiskcache/CMakeLists.txt
new file mode 100644
index 0000000000..d70d2756a9
--- /dev/null
+++ b/tests/benchmarks/network/access/qnetworkdiskcache/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qnetworkdiskcache.pro.
+
+#####################################################################
+## tst_bench_qnetworkdiskcache Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qnetworkdiskcache
+ SOURCES
+ tst_qnetworkdiskcache.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qnetworkdiskcache.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/network/access/qnetworkreply/CMakeLists.txt b/tests/benchmarks/network/access/qnetworkreply/CMakeLists.txt
new file mode 100644
index 0000000000..19c62103d8
--- /dev/null
+++ b/tests/benchmarks/network/access/qnetworkreply/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qnetworkreply.pro.
+
+#####################################################################
+## tst_bench_qnetworkreply Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qnetworkreply
+ SOURCES
+ tst_qnetworkreply.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qnetworkreply.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/network/access/qnetworkreply_from_cache/CMakeLists.txt b/tests/benchmarks/network/access/qnetworkreply_from_cache/CMakeLists.txt
new file mode 100644
index 0000000000..57cfebb1ff
--- /dev/null
+++ b/tests/benchmarks/network/access/qnetworkreply_from_cache/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qnetworkreply_from_cache.pro.
+
+#####################################################################
+## tst_bench_qnetworkreply_from_cache Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qnetworkreply_from_cache
+ SOURCES
+ tst_qnetworkreply_from_cache.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
diff --git a/tests/benchmarks/network/kernel/CMakeLists.txt b/tests/benchmarks/network/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..13a7caecdb
--- /dev/null
+++ b/tests/benchmarks/network/kernel/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from kernel.pro.
+
+if(QT_FEATURE_private_tests)
+ add_subdirectory(qhostinfo)
+endif()
diff --git a/tests/benchmarks/network/kernel/qhostinfo/CMakeLists.txt b/tests/benchmarks/network/kernel/qhostinfo/CMakeLists.txt
new file mode 100644
index 0000000000..5133fdc608
--- /dev/null
+++ b/tests/benchmarks/network/kernel/qhostinfo/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qhostinfo.pro.
+
+#####################################################################
+## tst_bench_qhostinfo Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qhostinfo
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qhostinfo.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/network/socket/CMakeLists.txt b/tests/benchmarks/network/socket/CMakeLists.txt
new file mode 100644
index 0000000000..6d54bc05f5
--- /dev/null
+++ b/tests/benchmarks/network/socket/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from socket.pro.
+
+add_subdirectory(qtcpserver)
+add_subdirectory(qudpsocket)
diff --git a/tests/benchmarks/network/socket/qtcpserver/CMakeLists.txt b/tests/benchmarks/network/socket/qtcpserver/CMakeLists.txt
new file mode 100644
index 0000000000..7e1eab88a9
--- /dev/null
+++ b/tests/benchmarks/network/socket/qtcpserver/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qtcpserver.pro.
+
+#####################################################################
+## tst_bench_qtcpserver Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qtcpserver
+ SOURCES
+ tst_qtcpserver.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qtcpserver.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/network/socket/qudpsocket/CMakeLists.txt b/tests/benchmarks/network/socket/qudpsocket/CMakeLists.txt
new file mode 100644
index 0000000000..58b4ab17d4
--- /dev/null
+++ b/tests/benchmarks/network/socket/qudpsocket/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qudpsocket.pro.
+
+#####################################################################
+## tst_bench_qudpsocket Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qudpsocket
+ SOURCES
+ tst_qudpsocket.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qudpsocket.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/network/ssl/CMakeLists.txt b/tests/benchmarks/network/ssl/CMakeLists.txt
new file mode 100644
index 0000000000..bc469359f1
--- /dev/null
+++ b/tests/benchmarks/network/ssl/CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from ssl.pro.
+
+add_subdirectory(qsslsocket)
diff --git a/tests/benchmarks/network/ssl/qsslsocket/CMakeLists.txt b/tests/benchmarks/network/ssl/qsslsocket/CMakeLists.txt
new file mode 100644
index 0000000000..7a127b071d
--- /dev/null
+++ b/tests/benchmarks/network/ssl/qsslsocket/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qsslsocket.pro.
+
+#####################################################################
+## tst_bench_qsslsocket Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qsslsocket
+ SOURCES
+ tst_qsslsocket.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qsslsocket.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/opengl/CMakeLists.txt b/tests/benchmarks/opengl/CMakeLists.txt
new file mode 100644
index 0000000000..070916cc9b
--- /dev/null
+++ b/tests/benchmarks/opengl/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from opengl.pro.
+
+#####################################################################
+## tst_bench_opengl Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_opengl
+ SOURCES
+ main.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::OpenGLPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::OpenGL
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:opengl.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/plugins/imageformats/jpeg/CMakeLists.txt b/tests/benchmarks/plugins/imageformats/jpeg/CMakeLists.txt
new file mode 100644
index 0000000000..63262d19ce
--- /dev/null
+++ b/tests/benchmarks/plugins/imageformats/jpeg/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from jpeg.pro.
+
+#####################################################################
+## jpeg Binary:
+#####################################################################
+
+add_qt_benchmark(jpeg
+ SOURCES
+ jpeg.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:jpeg.pro:<TRUE>:
+# TEMPLATE = "app"
+# TESTDATA = "n900.jpeg"
diff --git a/tests/benchmarks/sql/CMakeLists.txt b/tests/benchmarks/sql/CMakeLists.txt
new file mode 100644
index 0000000000..c4d96e338d
--- /dev/null
+++ b/tests/benchmarks/sql/CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from sql.pro.
+
+add_subdirectory(kernel)
diff --git a/tests/benchmarks/sql/kernel/CMakeLists.txt b/tests/benchmarks/sql/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..86108db75d
--- /dev/null
+++ b/tests/benchmarks/sql/kernel/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from kernel.pro.
+
+add_subdirectory(qsqlquery)
+add_subdirectory(qsqlrecord)
diff --git a/tests/benchmarks/sql/kernel/qsqlquery/CMakeLists.txt b/tests/benchmarks/sql/kernel/qsqlquery/CMakeLists.txt
new file mode 100644
index 0000000000..ed0ae90461
--- /dev/null
+++ b/tests/benchmarks/sql/kernel/qsqlquery/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qsqlquery.pro.
+
+#####################################################################
+## tst_bench_qsqlquery Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qsqlquery
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Qt::Sql
+ Qt::Test
+)
diff --git a/tests/benchmarks/sql/kernel/qsqlrecord/CMakeLists.txt b/tests/benchmarks/sql/kernel/qsqlrecord/CMakeLists.txt
new file mode 100644
index 0000000000..ea9acba088
--- /dev/null
+++ b/tests/benchmarks/sql/kernel/qsqlrecord/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qsqlrecord.pro.
+
+#####################################################################
+## tst_bench_qsqlrecord Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qsqlrecord
+ SOURCES
+ tst_qsqlrecord.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ PUBLIC_LIBRARIES
+ Qt::Sql
+ Qt::Test
+)
diff --git a/tests/benchmarks/testlib/CMakeLists.txt b/tests/benchmarks/testlib/CMakeLists.txt
new file mode 100644
index 0000000000..e7bd29b564
--- /dev/null
+++ b/tests/benchmarks/testlib/CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from testlib.pro.
+
+add_subdirectory(tostring)
diff --git a/tests/benchmarks/testlib/tostring/CMakeLists.txt b/tests/benchmarks/testlib/tostring/CMakeLists.txt
new file mode 100644
index 0000000000..76c0f1db1c
--- /dev/null
+++ b/tests/benchmarks/testlib/tostring/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from tostring.pro.
+
+#####################################################################
+## tst_bench_tostring Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_tostring
+ SOURCES
+ tst_tostring.cpp
+ PUBLIC_LIBRARIES
+ Qt::Test
+)
diff --git a/tests/benchmarks/widgets/CMakeLists.txt b/tests/benchmarks/widgets/CMakeLists.txt
new file mode 100644
index 0000000000..bf543e664d
--- /dev/null
+++ b/tests/benchmarks/widgets/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from widgets.pro.
+
+add_subdirectory(graphicsview)
+add_subdirectory(itemviews)
+add_subdirectory(kernel)
+add_subdirectory(styles)
+add_subdirectory(widgets)
diff --git a/tests/benchmarks/widgets/graphicsview/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/CMakeLists.txt
new file mode 100644
index 0000000000..3928328a98
--- /dev/null
+++ b/tests/benchmarks/widgets/graphicsview/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from graphicsview.pro.
+
+add_subdirectory(functional)
+add_subdirectory(qgraphicsanchorlayout)
+add_subdirectory(qgraphicsitem)
+add_subdirectory(qgraphicslayout)
+add_subdirectory(qgraphicslinearlayout)
+add_subdirectory(qgraphicsscene)
+add_subdirectory(qgraphicsview)
+add_subdirectory(qgraphicswidget)
diff --git a/tests/benchmarks/widgets/graphicsview/functional/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/functional/CMakeLists.txt
new file mode 100644
index 0000000000..20e4286a6e
--- /dev/null
+++ b/tests/benchmarks/widgets/graphicsview/functional/CMakeLists.txt
@@ -0,0 +1,2 @@
+# Generated from functional.pro.
+
diff --git a/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/CMakeLists.txt
new file mode 100644
index 0000000000..8fac5c3497
--- /dev/null
+++ b/tests/benchmarks/widgets/graphicsview/functional/GraphicsViewBenchmark/CMakeLists.txt
@@ -0,0 +1,367 @@
+# Generated from GraphicsViewBenchmark.pro.
+
+#####################################################################
+## tst_GraphicsViewBenchmark Binary:
+#####################################################################
+
+add_qt_benchmark(tst_GraphicsViewBenchmark
+ SOURCES
+ main.cpp
+ widgets/abstractitemcontainer.cpp widgets/abstractitemcontainer.h
+ widgets/abstractitemview.cpp widgets/abstractitemview.h
+ widgets/abstractscrollarea.cpp widgets/abstractscrollarea.h
+ widgets/abstractviewitem.cpp widgets/abstractviewitem.h
+ widgets/backgrounditem.cpp widgets/backgrounditem.h
+ widgets/button.cpp widgets/button.h
+ widgets/commandline.cpp widgets/commandline.h
+ widgets/dummydatagen.cpp widgets/dummydatagen.h
+ widgets/gvbwidget.cpp widgets/gvbwidget.h
+ widgets/iconitem.cpp widgets/iconitem.h
+ widgets/itemrecyclinglist.cpp widgets/itemrecyclinglist.h
+ widgets/itemrecyclinglistview.cpp widgets/itemrecyclinglistview.h
+ widgets/label.cpp widgets/label.h
+ widgets/listitem.cpp widgets/listitem.h
+ widgets/listitemcache.cpp widgets/listitemcache.h
+ widgets/listitemcontainer.cpp widgets/listitemcontainer.h
+ widgets/listmodel.cpp widgets/listmodel.h
+ widgets/listwidget.cpp widgets/listwidget.h
+ widgets/mainview.cpp widgets/mainview.h
+ widgets/menu.cpp widgets/menu.h
+ widgets/recycledlistitem.cpp widgets/recycledlistitem.h
+ widgets/scrollbar.cpp widgets/scrollbar.h
+ widgets/scroller.cpp widgets/scroller.h widgets/scroller_p.h
+ widgets/settings.cpp widgets/settings.h
+ widgets/simplelist.cpp widgets/simplelist.h
+ widgets/simplelistview.cpp widgets/simplelistview.h
+ widgets/theme.cpp widgets/theme.h
+ widgets/themeevent.cpp widgets/themeevent.h
+ widgets/topbar.cpp widgets/topbar.h
+ INCLUDE_DIRECTORIES
+ widgets
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Svg
+ Qt::Test
+)
+
+# Resources:
+set_source_files_properties("resources/blue_SVG/blue_background_360x640px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "background.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_background_horisontal_640x360px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "background_horisontal.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_contact_default_icon_52x52px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "contact_default_icon.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_contact_list_divider_360x76px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "contact_list_divider.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_contact_list_highlighter_360x76px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "contact_list_highlighter.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_contact_status_idle_33x33px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "contact_status_idle.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_contact_status_offline_33x33px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "contact_status_offline.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_contact_status_online_33x33px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "contact_status_online.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_scroll_16x80px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "scroll.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_scrollbar_7x14px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "scrollbar.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_status_field_left_14x24px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "status_field_left.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_status_field_middle_14x24px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "status_field_middle.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_status_field_right_14x24px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "status_field_right.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_topbar_356x96px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "topbar.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_topbar_horisontal_636x96px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "topbar_horisontal.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_user_default_icon_68x68px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "user_default_icon.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_user_status_idle_38x38px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "user_status_idle.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_user_status_offline_38x38px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "user_status_offline.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_user_status_online_38x38px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "user_status_online.svg"
+)
+set(GraphicsViewBenchmark_resource_files
+ "resources/blue_SVG/blue_background_360x640px.svg"
+ "resources/blue_SVG/blue_background_horisontal_640x360px.svg"
+ "resources/blue_SVG/blue_contact_default_icon_52x52px.svg"
+ "resources/blue_SVG/blue_contact_list_divider_360x76px.svg"
+ "resources/blue_SVG/blue_contact_list_highlighter_360x76px.svg"
+ "resources/blue_SVG/blue_contact_status_idle_33x33px.svg"
+ "resources/blue_SVG/blue_contact_status_offline_33x33px.svg"
+ "resources/blue_SVG/blue_contact_status_online_33x33px.svg"
+ "resources/blue_SVG/blue_scroll_16x80px.svg"
+ "resources/blue_SVG/blue_scrollbar_7x14px.svg"
+ "resources/blue_SVG/blue_status_field_left_14x24px.svg"
+ "resources/blue_SVG/blue_status_field_middle_14x24px.svg"
+ "resources/blue_SVG/blue_status_field_right_14x24px.svg"
+ "resources/blue_SVG/blue_topbar_356x96px.svg"
+ "resources/blue_SVG/blue_topbar_horisontal_636x96px.svg"
+ "resources/blue_SVG/blue_user_default_icon_68x68px.svg"
+ "resources/blue_SVG/blue_user_status_idle_38x38px.svg"
+ "resources/blue_SVG/blue_user_status_offline_38x38px.svg"
+ "resources/blue_SVG/blue_user_status_online_38x38px.svg"
+)
+
+add_qt_resource(tst_GraphicsViewBenchmark "GraphicsViewBenchmark"
+ PREFIX
+ "/themes/blue"
+ FILES
+ ${GraphicsViewBenchmark_resource_files}
+)
+set_source_files_properties("resources/blue_SVG/blue_contact_status_idle_33x33px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "contact_status_idle.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_contact_status_offline_33x33px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "contact_status_offline.svg"
+)
+set_source_files_properties("resources/blue_SVG/blue_contact_status_online_33x33px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "contact_status_online.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_background_360x640px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "background.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_background_horisontal_640x360px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "background_horisontal.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_contact_default_icon_53x53px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "contact_default_icon.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_contact_default_icon_highlight_53x53px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "contact_default_icon_highlight.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_contact_list_divider_360x76px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "contact_list_divider.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_contact_list_highlighter_357x80px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "contact_list_highlighter.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_scroll_5x80px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "scroll.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_scrollbar_5x14px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "scrollbar.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_status_field_left_14x24px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "status_field_left.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_status_field_middle_10x24px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "status_field_middle.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_status_field_right_14x24px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "status_field_right.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_topbar_356x96px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "topbar.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_topbar_horisontal_636x96px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "topbar_horisontal.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_user_default_icon_84x68px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "user_default_icon.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_user_status_idle_24x24px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "user_status_idle.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_user_status_offline_24x24px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "user_status_offline.svg"
+)
+set_source_files_properties("resources/lime_SVG/lime_user_status_online_24x24px.svg"
+ PROPERTIES QT_RESOURCE_ALIAS "user_status_online.svg"
+)
+set(GraphicsViewBenchmark1_resource_files
+ "resources/blue_SVG/blue_contact_status_idle_33x33px.svg"
+ "resources/blue_SVG/blue_contact_status_offline_33x33px.svg"
+ "resources/blue_SVG/blue_contact_status_online_33x33px.svg"
+ "resources/lime_SVG/lime_background_360x640px.svg"
+ "resources/lime_SVG/lime_background_horisontal_640x360px.svg"
+ "resources/lime_SVG/lime_contact_default_icon_53x53px.svg"
+ "resources/lime_SVG/lime_contact_default_icon_highlight_53x53px.svg"
+ "resources/lime_SVG/lime_contact_list_divider_360x76px.svg"
+ "resources/lime_SVG/lime_contact_list_highlighter_357x80px.svg"
+ "resources/lime_SVG/lime_scroll_5x80px.svg"
+ "resources/lime_SVG/lime_scrollbar_5x14px.svg"
+ "resources/lime_SVG/lime_status_field_left_14x24px.svg"
+ "resources/lime_SVG/lime_status_field_middle_10x24px.svg"
+ "resources/lime_SVG/lime_status_field_right_14x24px.svg"
+ "resources/lime_SVG/lime_topbar_356x96px.svg"
+ "resources/lime_SVG/lime_topbar_horisontal_636x96px.svg"
+ "resources/lime_SVG/lime_user_default_icon_84x68px.svg"
+ "resources/lime_SVG/lime_user_status_idle_24x24px.svg"
+ "resources/lime_SVG/lime_user_status_offline_24x24px.svg"
+ "resources/lime_SVG/lime_user_status_online_24x24px.svg"
+)
+
+add_qt_resource(tst_GraphicsViewBenchmark "GraphicsViewBenchmark1"
+ PREFIX
+ "/themes/lime"
+ FILES
+ ${GraphicsViewBenchmark1_resource_files}
+)
+set_source_files_properties("resources/avatars/avatar_man_001_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_001.png"
+)
+set_source_files_properties("resources/avatars/avatar_man_002_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_002.png"
+)
+set_source_files_properties("resources/avatars/avatar_man_003_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_003.png"
+)
+set_source_files_properties("resources/avatars/avatar_man_004_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_004.png"
+)
+set_source_files_properties("resources/avatars/avatar_man_005_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_005.png"
+)
+set_source_files_properties("resources/avatars/avatar_man_006_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_006.png"
+)
+set_source_files_properties("resources/avatars/avatar_man_007_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_007.png"
+)
+set_source_files_properties("resources/avatars/avatar_man_008_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_008.png"
+)
+set_source_files_properties("resources/avatars/avatar_man_009_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_009.png"
+)
+set_source_files_properties("resources/avatars/avatar_man_010_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_010.png"
+)
+set_source_files_properties("resources/avatars/avatar_picture_001_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_011.png"
+)
+set_source_files_properties("resources/avatars/avatar_picture_002_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_012.png"
+)
+set_source_files_properties("resources/avatars/avatar_picture_003_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_013.png"
+)
+set_source_files_properties("resources/avatars/avatar_picture_004_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_014.png"
+)
+set_source_files_properties("resources/avatars/avatar_picture_005_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_015.png"
+)
+set_source_files_properties("resources/avatars/avatar_woman_001_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_016.png"
+)
+set_source_files_properties("resources/avatars/avatar_woman_002_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_017.png"
+)
+set_source_files_properties("resources/avatars/avatar_woman_003_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_018.png"
+)
+set_source_files_properties("resources/avatars/avatar_woman_004_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_019.png"
+)
+set_source_files_properties("resources/avatars/avatar_woman_005_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_020.png"
+)
+set_source_files_properties("resources/avatars/avatar_woman_006_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_021.png"
+)
+set_source_files_properties("resources/avatars/avatar_woman_007_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_022.png"
+)
+set_source_files_properties("resources/avatars/avatar_woman_008_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_023.png"
+)
+set_source_files_properties("resources/avatars/avatar_woman_009_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_024.png"
+)
+set_source_files_properties("resources/avatars/avatar_woman_010_58x58.png"
+ PROPERTIES QT_RESOURCE_ALIAS "avatar_025.png"
+)
+set(GraphicsViewBenchmark2_resource_files
+ "resources/avatars/avatar_man_001_58x58.png"
+ "resources/avatars/avatar_man_002_58x58.png"
+ "resources/avatars/avatar_man_003_58x58.png"
+ "resources/avatars/avatar_man_004_58x58.png"
+ "resources/avatars/avatar_man_005_58x58.png"
+ "resources/avatars/avatar_man_006_58x58.png"
+ "resources/avatars/avatar_man_007_58x58.png"
+ "resources/avatars/avatar_man_008_58x58.png"
+ "resources/avatars/avatar_man_009_58x58.png"
+ "resources/avatars/avatar_man_010_58x58.png"
+ "resources/avatars/avatar_picture_001_58x58.png"
+ "resources/avatars/avatar_picture_002_58x58.png"
+ "resources/avatars/avatar_picture_003_58x58.png"
+ "resources/avatars/avatar_picture_004_58x58.png"
+ "resources/avatars/avatar_picture_005_58x58.png"
+ "resources/avatars/avatar_woman_001_58x58.png"
+ "resources/avatars/avatar_woman_002_58x58.png"
+ "resources/avatars/avatar_woman_003_58x58.png"
+ "resources/avatars/avatar_woman_004_58x58.png"
+ "resources/avatars/avatar_woman_005_58x58.png"
+ "resources/avatars/avatar_woman_006_58x58.png"
+ "resources/avatars/avatar_woman_007_58x58.png"
+ "resources/avatars/avatar_woman_008_58x58.png"
+ "resources/avatars/avatar_woman_009_58x58.png"
+ "resources/avatars/avatar_woman_010_58x58.png"
+)
+
+add_qt_resource(tst_GraphicsViewBenchmark "GraphicsViewBenchmark2"
+ PREFIX
+ "/avatars"
+ FILES
+ ${GraphicsViewBenchmark2_resource_files}
+)
+set_source_files_properties("resources/contacts/areacodes.txt"
+ PROPERTIES QT_RESOURCE_ALIAS "areacodes.txt"
+)
+set_source_files_properties("resources/contacts/firstnamesF.txt"
+ PROPERTIES QT_RESOURCE_ALIAS "firstnamesF.txt"
+)
+set_source_files_properties("resources/contacts/firstnamesM.txt"
+ PROPERTIES QT_RESOURCE_ALIAS "firstnamesM.txt"
+)
+set_source_files_properties("resources/contacts/lastnames.txt"
+ PROPERTIES QT_RESOURCE_ALIAS "lastnames.txt"
+)
+set(GraphicsViewBenchmark3_resource_files
+ "resources/contacts/areacodes.txt"
+ "resources/contacts/firstnamesF.txt"
+ "resources/contacts/firstnamesM.txt"
+ "resources/contacts/lastnames.txt"
+)
+
+add_qt_resource(tst_GraphicsViewBenchmark "GraphicsViewBenchmark3"
+ PREFIX
+ "/contact"
+ FILES
+ ${GraphicsViewBenchmark3_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:GraphicsViewBenchmark.pro:<TRUE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_GraphicsViewBenchmark CONDITION TARGET Qt::OpenGL
+ PUBLIC_LIBRARIES
+ Qt::OpenGL
+)
diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt
new file mode 100644
index 0000000000..4f526cc7b1
--- /dev/null
+++ b/tests/benchmarks/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qgraphicsanchorlayout.pro.
+
+#####################################################################
+## tst_bench_qgraphicsanchorlayout Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qgraphicsanchorlayout
+ SOURCES
+ tst_qgraphicsanchorlayout.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qgraphicsanchorlayout.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsitem/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsitem/CMakeLists.txt
new file mode 100644
index 0000000000..a63c37e323
--- /dev/null
+++ b/tests/benchmarks/widgets/graphicsview/qgraphicsitem/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qgraphicsitem.pro.
+
+#####################################################################
+## tst_bench_qgraphicsitem Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qgraphicsitem
+ SOURCES
+ tst_qgraphicsitem.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qgraphicsitem.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicslayout/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicslayout/CMakeLists.txt
new file mode 100644
index 0000000000..84f277df1b
--- /dev/null
+++ b/tests/benchmarks/widgets/graphicsview/qgraphicslayout/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qgraphicslayout.pro.
+
+#####################################################################
+## tst_bench_qgraphicslayout Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qgraphicslayout
+ SOURCES
+ tst_qgraphicslayout.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qgraphicslayout.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt
new file mode 100644
index 0000000000..ab88de5bec
--- /dev/null
+++ b/tests/benchmarks/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qgraphicslinearlayout.pro.
+
+#####################################################################
+## tst_bench_qgraphicslinearlayout Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qgraphicslinearlayout
+ SOURCES
+ tst_qgraphicslinearlayout.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qgraphicslinearlayout.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsscene/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsscene/CMakeLists.txt
new file mode 100644
index 0000000000..0c72479efd
--- /dev/null
+++ b/tests/benchmarks/widgets/graphicsview/qgraphicsscene/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qgraphicsscene.pro.
+
+#####################################################################
+## tst_bench_qgraphicsscene Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qgraphicsscene
+ SOURCES
+ tst_qgraphicsscene.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qgraphicsscene.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsview/CMakeLists.txt
new file mode 100644
index 0000000000..d98e3dba19
--- /dev/null
+++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/CMakeLists.txt
@@ -0,0 +1,55 @@
+# Generated from qgraphicsview.pro.
+
+#####################################################################
+## tst_bench_qgraphicsview Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qgraphicsview
+ SOURCES
+ chiptester/chip.cpp chiptester/chip.h
+ chiptester/chiptester.cpp chiptester/chiptester.h
+ tst_qgraphicsview.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+# Resources:
+set(qgraphicsview_resource_files
+ "images/designer.png"
+ "images/wine-big.jpeg"
+ "images/wine.jpeg"
+ "random.data"
+)
+
+add_qt_resource(tst_bench_qgraphicsview "qgraphicsview"
+ PREFIX
+ "/"
+ FILES
+ ${qgraphicsview_resource_files}
+)
+set(images_resource_files
+ "qt4logo.png"
+)
+
+add_qt_resource(tst_bench_qgraphicsview "images"
+ PREFIX
+ "/"
+ BASE
+ "chiptester"
+ FILES
+ ${images_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:qgraphicsview.pro:<TRUE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_bench_qgraphicsview CONDITION TARGET Qt::OpenGL
+ PUBLIC_LIBRARIES
+ Qt::OpenGL
+)
diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/CMakeLists.txt
new file mode 100644
index 0000000000..e5e01a8434
--- /dev/null
+++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/chipTest/CMakeLists.txt
@@ -0,0 +1,48 @@
+# Generated from chip.pro.
+
+#####################################################################
+## chip Binary:
+#####################################################################
+
+add_qt_benchmark(chip
+ GUI
+ SOURCES
+ chip.cpp chip.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ view.cpp view.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set(images_resource_files
+ "fileprint.png"
+ "qt4logo.png"
+ "rotateleft.png"
+ "rotateright.png"
+ "zoomin.png"
+ "zoomout.png"
+)
+
+add_qt_resource(chip "images"
+ PREFIX
+ "/"
+ FILES
+ ${images_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:chip.pro:<TRUE>:
+# INSTALLS = "target" "sources"
+# sources.files = "$$SOURCES" "$$HEADERS" "$$RESOURCES" "*.png" "*.pro" "*.html" "*.doc" "images"
+# sources.path = "$$[QT_INSTALL_EXAMPLES]/graphicsview/chip"
+# target.path = "$$[QT_INSTALL_EXAMPLES]/graphicsview/chip"
+
+## Scopes:
+#####################################################################
+
+extend_target(chip CONDITION TARGET Qt::OpenGL
+ PUBLIC_LIBRARIES
+ Qt::OpenGL
+)
diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/CMakeLists.txt
new file mode 100644
index 0000000000..ce86e56722
--- /dev/null
+++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/moveItems/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from moveItems.pro.
+
+#####################################################################
+## moveItems Binary:
+#####################################################################
+
+add_qt_benchmark(moveItems
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/CMakeLists.txt
new file mode 100644
index 0000000000..310fcd0622
--- /dev/null
+++ b/tests/benchmarks/widgets/graphicsview/qgraphicsview/benchapps/scrolltest/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from scrolltest.pro.
+
+#####################################################################
+## scrolltest Binary:
+#####################################################################
+
+add_qt_benchmark(scrolltest
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
diff --git a/tests/benchmarks/widgets/graphicsview/qgraphicswidget/CMakeLists.txt b/tests/benchmarks/widgets/graphicsview/qgraphicswidget/CMakeLists.txt
new file mode 100644
index 0000000000..ab16f7081e
--- /dev/null
+++ b/tests/benchmarks/widgets/graphicsview/qgraphicswidget/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qgraphicswidget.pro.
+
+#####################################################################
+## tst_bench_qgraphicswidget Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qgraphicswidget
+ SOURCES
+ tst_qgraphicswidget.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qgraphicswidget.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/widgets/itemviews/CMakeLists.txt b/tests/benchmarks/widgets/itemviews/CMakeLists.txt
new file mode 100644
index 0000000000..76747b527d
--- /dev/null
+++ b/tests/benchmarks/widgets/itemviews/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from itemviews.pro.
+
+add_subdirectory(qtableview)
+add_subdirectory(qheaderview)
+add_subdirectory(qlistview)
diff --git a/tests/benchmarks/widgets/itemviews/qheaderview/CMakeLists.txt b/tests/benchmarks/widgets/itemviews/qheaderview/CMakeLists.txt
new file mode 100644
index 0000000000..6d616d2579
--- /dev/null
+++ b/tests/benchmarks/widgets/itemviews/qheaderview/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qheaderview.pro.
+
+#####################################################################
+## tst_bench_qheaderview Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qheaderview
+ SOURCES
+ qheaderviewbench.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qheaderview.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/widgets/itemviews/qlistview/CMakeLists.txt b/tests/benchmarks/widgets/itemviews/qlistview/CMakeLists.txt
new file mode 100644
index 0000000000..58062db6c0
--- /dev/null
+++ b/tests/benchmarks/widgets/itemviews/qlistview/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qlistview.pro.
+
+#####################################################################
+## tst_bench_qlistview Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qlistview
+ SOURCES
+ tst_qlistview.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qlistview.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/widgets/itemviews/qtableview/CMakeLists.txt b/tests/benchmarks/widgets/itemviews/qtableview/CMakeLists.txt
new file mode 100644
index 0000000000..f0b47692d8
--- /dev/null
+++ b/tests/benchmarks/widgets/itemviews/qtableview/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qtableview.pro.
+
+#####################################################################
+## tst_bench_qtableview Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qtableview
+ SOURCES
+ tst_qtableview.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qtableview.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/widgets/kernel/CMakeLists.txt b/tests/benchmarks/widgets/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..b55b31fe67
--- /dev/null
+++ b/tests/benchmarks/widgets/kernel/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from kernel.pro.
+
+add_subdirectory(qapplication)
+add_subdirectory(qwidget)
diff --git a/tests/benchmarks/widgets/kernel/qapplication/CMakeLists.txt b/tests/benchmarks/widgets/kernel/qapplication/CMakeLists.txt
new file mode 100644
index 0000000000..05bc480302
--- /dev/null
+++ b/tests/benchmarks/widgets/kernel/qapplication/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qapplication.pro.
+
+#####################################################################
+## tst_bench_qapplication Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qapplication
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qapplication.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/widgets/kernel/qwidget/CMakeLists.txt b/tests/benchmarks/widgets/kernel/qwidget/CMakeLists.txt
new file mode 100644
index 0000000000..6165cba25a
--- /dev/null
+++ b/tests/benchmarks/widgets/kernel/qwidget/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qwidget.pro.
+
+#####################################################################
+## tst_bench_qwidget Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qwidget
+ SOURCES
+ tst_qwidget.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
diff --git a/tests/benchmarks/widgets/styles/CMakeLists.txt b/tests/benchmarks/widgets/styles/CMakeLists.txt
new file mode 100644
index 0000000000..74e57c5731
--- /dev/null
+++ b/tests/benchmarks/widgets/styles/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from styles.pro.
+
+if(TARGET Qt::Widgets)
+ add_subdirectory(qstylesheetstyle)
+endif()
diff --git a/tests/benchmarks/widgets/styles/qstylesheetstyle/CMakeLists.txt b/tests/benchmarks/widgets/styles/qstylesheetstyle/CMakeLists.txt
new file mode 100644
index 0000000000..13aa6a1f62
--- /dev/null
+++ b/tests/benchmarks/widgets/styles/qstylesheetstyle/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qstylesheetstyle.pro.
+
+#####################################################################
+## tst_bench_qstylesheetstyle Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_qstylesheetstyle
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qstylesheetstyle.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/benchmarks/widgets/widgets/CMakeLists.txt b/tests/benchmarks/widgets/widgets/CMakeLists.txt
new file mode 100644
index 0000000000..81a8fccc05
--- /dev/null
+++ b/tests/benchmarks/widgets/widgets/CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from widgets.pro.
+
+add_subdirectory(qtextbrowser)
diff --git a/tests/benchmarks/widgets/widgets/qtextbrowser/CMakeLists.txt b/tests/benchmarks/widgets/widgets/qtextbrowser/CMakeLists.txt
new file mode 100644
index 0000000000..983d255787
--- /dev/null
+++ b/tests/benchmarks/widgets/widgets/qtextbrowser/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qtextbrowser.pro.
+
+#####################################################################
+## tst_bench_QTextBrowser Binary:
+#####################################################################
+
+add_qt_benchmark(tst_bench_QTextBrowser
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qtextbrowser.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/CMakeLists.txt b/tests/manual/CMakeLists.txt
new file mode 100644
index 0000000000..9d5a3effaa
--- /dev/null
+++ b/tests/manual/CMakeLists.txt
@@ -0,0 +1,82 @@
+# Generated from manual.pro.
+
+# special case begn
+# Don't build manual tests when targeting iOS.
+if(APPLE_UIKIT)
+ return()
+endif()
+# special case end
+
+add_subdirectory(bearerex)
+add_subdirectory(filetest)
+add_subdirectory(embeddedintoforeignwindow)
+add_subdirectory(foreignwindows)
+add_subdirectory(gestures)
+add_subdirectory(highdpi)
+add_subdirectory(inputmethodhints)
+add_subdirectory(keypadnavigation)
+add_subdirectory(lance)
+add_subdirectory(qcursor)
+add_subdirectory(qdesktopservices)
+add_subdirectory(qdesktopwidget)
+add_subdirectory(qgraphicsitem)
+add_subdirectory(qgraphicsitemgroup)
+add_subdirectory(qgraphicslayout/flicker)
+add_subdirectory(qhttpnetworkconnection)
+add_subdirectory(qimagereader)
+add_subdirectory(qlayout)
+add_subdirectory(qlocale)
+add_subdirectory(qmimedatabase)
+add_subdirectory(qnetconmonitor)
+add_subdirectory(qnetworkaccessmanager/qget)
+add_subdirectory(qnetworkconfigurationmanager)
+add_subdirectory(qnetworkconfiguration)
+#special case begin
+if (QT_FEATURE_openssl AND UNIX)
+ add_subdirectory(qnetworkreply)
+endif()
+#special case end
+add_subdirectory(qstorageinfo)
+add_subdirectory(qscreen)
+add_subdirectory(qsslsocket)
+add_subdirectory(qsysinfo)
+add_subdirectory(qtabletevent)
+add_subdirectory(qtexteditlist)
+add_subdirectory(qtexttableborders)
+add_subdirectory(qtbug-8933)
+add_subdirectory(qtbug-52641)
+add_subdirectory(qtouchevent)
+add_subdirectory(touch)
+add_subdirectory(qwidget_zorder)
+add_subdirectory(repaint)
+add_subdirectory(socketengine)
+add_subdirectory(textrendering)
+add_subdirectory(widgets)
+add_subdirectory(windowflags)
+add_subdirectory(windowgeometry)
+add_subdirectory(windowmodality)
+add_subdirectory(widgetgrab)
+add_subdirectory(xembed-raster)
+add_subdirectory(xembed-widgets)
+add_subdirectory(shortcuts)
+add_subdirectory(dialogs)
+add_subdirectory(windowtransparency)
+add_subdirectory(unc)
+add_subdirectory(qtabbar)
+add_subdirectory(rhi)
+if(UNIX)
+ add_subdirectory(network_remote_stresstest)
+ add_subdirectory(network_stresstest)
+endif()
+if(QT_FEATURE_openssl)
+ add_subdirectory(qssloptions)
+endif()
+if(QT_FEATURE_opengl)
+ add_subdirectory(qopengltextureblitter)
+endif()
+if(QT_FEATURE_egl AND QT_FEATURE_opengl)
+ add_subdirectory(qopenglcontext)
+endif()
+if(QT_FEATURE_vulkan)
+ add_subdirectory(qvulkaninstance)
+endif()
diff --git a/tests/manual/bearerex/CMakeLists.txt b/tests/manual/bearerex/CMakeLists.txt
new file mode 100644
index 0000000000..3a09ac5358
--- /dev/null
+++ b/tests/manual/bearerex/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from bearerex.pro.
+
+#####################################################################
+## BearerEx Binary:
+#####################################################################
+
+add_qt_manual_test(BearerEx
+ GUI
+ SOURCES
+ bearerex.cpp bearerex.h bearerex.ui
+ datatransferer.cpp datatransferer.h
+ detailedinfodialog.ui
+ main.cpp
+ sessiondialog.ui
+ xqlistwidget.cpp xqlistwidget.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Network
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+#### Keys ignored in scope 1:.:.:bearerex.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/cocoa/appicon/CMakeLists.txt b/tests/manual/cocoa/appicon/CMakeLists.txt
new file mode 100644
index 0000000000..5cb97d7c6a
--- /dev/null
+++ b/tests/manual/cocoa/appicon/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from appicon.pro.
+
+#####################################################################
+## appicon Binary:
+#####################################################################
+
+add_qt_manual_test(appicon
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:appicon.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/cocoa/menurama/CMakeLists.txt b/tests/manual/cocoa/menurama/CMakeLists.txt
new file mode 100644
index 0000000000..1c39a59fc3
--- /dev/null
+++ b/tests/manual/cocoa/menurama/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from menurama.pro.
+
+#####################################################################
+## Menurama Binary:
+#####################################################################
+
+add_qt_manual_test(Menurama
+ GUI
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ menuramaapplication.cpp menuramaapplication.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+#### Keys ignored in scope 1:.:.:menurama.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/cocoa/menus/CMakeLists.txt b/tests/manual/cocoa/menus/CMakeLists.txt
new file mode 100644
index 0000000000..a3fa70ba5d
--- /dev/null
+++ b/tests/manual/cocoa/menus/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from menus.pro.
+
+#####################################################################
+## menus Binary:
+#####################################################################
+
+add_qt_manual_test(menus
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:menus.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/cocoa/nativewidgets/CMakeLists.txt b/tests/manual/cocoa/nativewidgets/CMakeLists.txt
new file mode 100644
index 0000000000..cab2da5421
--- /dev/null
+++ b/tests/manual/cocoa/nativewidgets/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from nativewigets.pro.
+
+#####################################################################
+## nativewigets Binary:
+#####################################################################
+
+add_qt_manual_test(nativewigets
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:nativewigets.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/cocoa/popups/CMakeLists.txt b/tests/manual/cocoa/popups/CMakeLists.txt
new file mode 100644
index 0000000000..53468edc7c
--- /dev/null
+++ b/tests/manual/cocoa/popups/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from popups.pro.
+
+#####################################################################
+## popups Binary:
+#####################################################################
+
+add_qt_manual_test(popups
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/cocoa/qmaccocoaviewcontainer/CMakeLists.txt b/tests/manual/cocoa/qmaccocoaviewcontainer/CMakeLists.txt
new file mode 100644
index 0000000000..95317c520e
--- /dev/null
+++ b/tests/manual/cocoa/qmaccocoaviewcontainer/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from qmaccocoaviewcontainer.pro.
+
+#####################################################################
+## qmaccocoaviewcontainer Binary:
+#####################################################################
+
+add_qt_manual_test(qmaccocoaviewcontainer
+ GUI
+ SOURCES
+ TestMouseMovedNSView.h TestMouseMovedNSView.m
+ main.mm
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qmaccocoaviewcontainer.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/cocoa/qsystemtrayicon/CMakeLists.txt b/tests/manual/cocoa/qsystemtrayicon/CMakeLists.txt
new file mode 100644
index 0000000000..73c3157b89
--- /dev/null
+++ b/tests/manual/cocoa/qsystemtrayicon/CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from qsystemtrayicon.pro.
+
+#####################################################################
+## qsystemtrayicon Binary:
+#####################################################################
+
+add_qt_manual_test(qsystemtrayicon
+ GUI
+ SOURCES
+ main.cpp
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set(icons_resource_files
+ "macsystray16x16.png"
+ "macsystray18x18.png"
+ "macsystray25x15.png"
+ "macsystray32x32.png"
+ "macsystray36x36.png"
+ "macsystray50x30.png"
+ "macsystray64x64.png"
+)
+
+add_qt_resource(qsystemtrayicon "icons"
+ PREFIX
+ "/"
+ FILES
+ ${icons_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:qsystemtrayicon.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/cocoa/qt_on_cocoa/CMakeLists.txt b/tests/manual/cocoa/qt_on_cocoa/CMakeLists.txt
new file mode 100644
index 0000000000..066eefa313
--- /dev/null
+++ b/tests/manual/cocoa/qt_on_cocoa/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from qt_on_cocoa.pro.
+
+#####################################################################
+## qt_on_cocoa Binary:
+#####################################################################
+
+add_qt_manual_test(qt_on_cocoa
+ GUI
+ SOURCES
+ main.mm
+ rasterwindow.cpp rasterwindow.h
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+ Qt::Gui
+ Qt::Quick
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qt_on_cocoa.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/cocoa/wheelevent/CMakeLists.txt b/tests/manual/cocoa/wheelevent/CMakeLists.txt
new file mode 100644
index 0000000000..b3c1a10226
--- /dev/null
+++ b/tests/manual/cocoa/wheelevent/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from wheelevent.pro.
+
+#####################################################################
+## wheelevent Binary:
+#####################################################################
+
+add_qt_manual_test(wheelevent
+ GUI
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:wheelevent.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/diaglib/nativewindowdump_win.cpp b/tests/manual/diaglib/nativewindowdump_win.cpp
index d91e673d1c..6334fcfedd 100644
--- a/tests/manual/diaglib/nativewindowdump_win.cpp
+++ b/tests/manual/diaglib/nativewindowdump_win.cpp
@@ -41,6 +41,8 @@
# define WS_EX_NOREDIRECTIONBITMAP 0x00200000L
#endif
+using namespace Qt;
+
namespace QtDiag {
struct DumpContext {
diff --git a/tests/manual/dialogs/CMakeLists.txt b/tests/manual/dialogs/CMakeLists.txt
new file mode 100644
index 0000000000..ef000529a5
--- /dev/null
+++ b/tests/manual/dialogs/CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from dialogs.pro.
+
+#####################################################################
+## dialogs Binary:
+#####################################################################
+
+add_qt_manual_test(dialogs
+ GUI
+ SOURCES
+ colordialogpanel.cpp colordialogpanel.h
+ filedialogpanel.cpp filedialogpanel.h
+ fontdialogpanel.cpp fontdialogpanel.h
+ main.cpp
+ messageboxpanel.cpp messageboxpanel.h
+ utils.cpp utils.h
+ wizardpanel.cpp wizardpanel.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:dialogs.pro:<TRUE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(dialogs CONDITION TARGET Qt::PrintSupport
+ PUBLIC_LIBRARIES
+ Qt::PrintSupport
+)
+
+extend_target(dialogs CONDITION NOT (QT_FEATURE_printer EQUAL FALSE)
+ SOURCES
+ printdialogpanel.cpp printdialogpanel.h printdialogpanel.ui
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
diff --git a/tests/manual/embeddedintoforeignwindow/CMakeLists.txt b/tests/manual/embeddedintoforeignwindow/CMakeLists.txt
new file mode 100644
index 0000000000..a40a655f4d
--- /dev/null
+++ b/tests/manual/embeddedintoforeignwindow/CMakeLists.txt
@@ -0,0 +1,60 @@
+# Generated from embeddedintoforeignwindow.pro.
+
+#####################################################################
+## embeddedintoforeignwindow Binary:
+#####################################################################
+
+add_qt_manual_test(embeddedintoforeignwindow
+ SOURCES
+ ../diaglib/eventfilter.cpp ../diaglib/eventfilter.h
+ ../diaglib/nativewindowdump.h
+ ../diaglib/qwindowdump.cpp ../diaglib/qwindowdump.h
+ ../diaglib/textdump.cpp ../diaglib/textdump.h
+ itemwindow.cpp itemwindow.h
+ main.cpp
+ DEFINES
+ QT_DIAG_LIB
+ INCLUDE_DIRECTORIES
+ ../diaglib
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:embeddedintoforeignwindow.pro:<TRUE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(embeddedintoforeignwindow CONDITION WIN32 AND NOT WINRT
+ SOURCES
+ ../diaglib/nativewindowdump_win.cpp
+ PUBLIC_LIBRARIES
+ user32
+)
+
+extend_target(embeddedintoforeignwindow CONDITION UNIX OR WINRT
+ SOURCES
+ ../diaglib/nativewindowdump.cpp
+)
+
+extend_target(embeddedintoforeignwindow CONDITION QT_FEATURE_widgets
+ SOURCES
+ ../diaglib/debugproxystyle.cpp ../diaglib/debugproxystyle.h
+ ../diaglib/logwidget.cpp ../diaglib/logwidget.h
+ ../diaglib/qwidgetdump.cpp ../diaglib/qwidgetdump.h
+ LIBRARIES
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
+
+extend_target(embeddedintoforeignwindow CONDITION QT_FEATURE_opengl
+ SOURCES
+ ../diaglib/glinfo.cpp ../diaglib/glinfo.h
+ PUBLIC_LIBRARIES
+ Qt::OpenGL
+)
diff --git a/tests/manual/filetest/CMakeLists.txt b/tests/manual/filetest/CMakeLists.txt
new file mode 100644
index 0000000000..efefc262ef
--- /dev/null
+++ b/tests/manual/filetest/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from filetest.pro.
+
+#####################################################################
+## filetest Binary:
+#####################################################################
+
+add_qt_manual_test(filetest
+ SOURCES
+ main.cpp
+)
+
+#### Keys ignored in scope 1:.:.:filetest.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/foreignwindows/CMakeLists.txt b/tests/manual/foreignwindows/CMakeLists.txt
new file mode 100644
index 0000000000..707d7e7056
--- /dev/null
+++ b/tests/manual/foreignwindows/CMakeLists.txt
@@ -0,0 +1,60 @@
+# Generated from foreignwindows.pro.
+
+#####################################################################
+## foreignwindows Binary:
+#####################################################################
+
+add_qt_manual_test(foreignwindows
+ SOURCES
+ ../diaglib/eventfilter.cpp ../diaglib/eventfilter.h
+ ../diaglib/nativewindowdump.h
+ ../diaglib/qwindowdump.cpp ../diaglib/qwindowdump.h
+ ../diaglib/textdump.cpp ../diaglib/textdump.h
+ main.cpp
+ DEFINES
+ QT_DIAG_LIB
+ INCLUDE_DIRECTORIES
+ ../diaglib
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:foreignwindows.pro:<TRUE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(foreignwindows CONDITION WIN32 AND NOT WINRT
+ SOURCES
+ ../diaglib/nativewindowdump_win.cpp
+ PUBLIC_LIBRARIES
+ user32
+)
+
+extend_target(foreignwindows CONDITION UNIX OR WINRT
+ SOURCES
+ ../diaglib/nativewindowdump.cpp
+)
+
+extend_target(foreignwindows CONDITION QT_FEATURE_widgets
+ SOURCES
+ ../diaglib/debugproxystyle.cpp ../diaglib/debugproxystyle.h
+ ../diaglib/logwidget.cpp ../diaglib/logwidget.h
+ ../diaglib/qwidgetdump.cpp ../diaglib/qwidgetdump.h
+ LIBRARIES
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
+
+extend_target(foreignwindows CONDITION QT_FEATURE_opengl
+ SOURCES
+ ../diaglib/glinfo.cpp ../diaglib/glinfo.h
+ PUBLIC_LIBRARIES
+ Qt::OpenGL
+)
diff --git a/tests/manual/gestures/CMakeLists.txt b/tests/manual/gestures/CMakeLists.txt
new file mode 100644
index 0000000000..7011d3221d
--- /dev/null
+++ b/tests/manual/gestures/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from gestures.pro.
+
+add_subdirectory(graphicsview)
+add_subdirectory(scrollarea)
diff --git a/tests/manual/gestures/graphicsview/CMakeLists.txt b/tests/manual/gestures/graphicsview/CMakeLists.txt
new file mode 100644
index 0000000000..81dc1931aa
--- /dev/null
+++ b/tests/manual/gestures/graphicsview/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from graphicsview.pro.
+
+#####################################################################
+## tst_manual_graphicsview Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_graphicsview
+ GUI
+ SOURCES
+ gestures.cpp gestures.h
+ imageitem.cpp imageitem.h
+ main.cpp
+ mousepangesturerecognizer.cpp mousepangesturerecognizer.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/gestures/scrollarea/CMakeLists.txt b/tests/manual/gestures/scrollarea/CMakeLists.txt
new file mode 100644
index 0000000000..c521c8e2df
--- /dev/null
+++ b/tests/manual/gestures/scrollarea/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from scrollarea.pro.
+
+#####################################################################
+## scrollarea Binary:
+#####################################################################
+
+add_qt_manual_test(scrollarea
+ GUI
+ SOURCES
+ main.cpp
+ mousepangesturerecognizer.cpp mousepangesturerecognizer.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/highdpi/CMakeLists.txt b/tests/manual/highdpi/CMakeLists.txt
new file mode 100644
index 0000000000..b1983ff00a
--- /dev/null
+++ b/tests/manual/highdpi/CMakeLists.txt
@@ -0,0 +1,41 @@
+# Generated from highdpi.pro.
+
+#####################################################################
+## highdpi Binary:
+#####################################################################
+
+add_qt_manual_test(highdpi
+ SOURCES
+ dragwidget.cpp dragwidget.h
+ main.cpp
+ DEFINES
+ HAVE_SCREEN_BASE_DPI
+ INCLUDE_DIRECTORIES
+ .
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set(highdpi_resource_files
+ "qticon16.png"
+ "qticon16@2x.png"
+ "qticon16@3x.png"
+ "qticon32.png"
+ "qticon32@2x.png"
+ "qticon64.png"
+)
+
+add_qt_resource(highdpi "highdpi"
+ PREFIX
+ "/"
+ FILES
+ ${highdpi_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:highdpi.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/inputmethodhints/CMakeLists.txt b/tests/manual/inputmethodhints/CMakeLists.txt
new file mode 100644
index 0000000000..1bbf7caef8
--- /dev/null
+++ b/tests/manual/inputmethodhints/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from inputmethodhints.pro.
+
+#####################################################################
+## tst_inputmethodhints Binary:
+#####################################################################
+
+add_qt_manual_test(tst_inputmethodhints
+ GUI
+ SOURCES
+ inputmethodhints.cpp inputmethodhints.h inputmethodhints.ui
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+#### Keys ignored in scope 1:.:.:inputmethodhints.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/keypadnavigation/CMakeLists.txt b/tests/manual/keypadnavigation/CMakeLists.txt
new file mode 100644
index 0000000000..8f11ad711c
--- /dev/null
+++ b/tests/manual/keypadnavigation/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from keypadnavigation.pro.
+
+#####################################################################
+## keypadnavigation Binary:
+#####################################################################
+
+add_qt_manual_test(keypadnavigation
+ GUI
+ SOURCES
+ keypadnavigation.ui
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
diff --git a/tests/manual/lance/CMakeLists.txt b/tests/manual/lance/CMakeLists.txt
new file mode 100644
index 0000000000..bf4021f60f
--- /dev/null
+++ b/tests/manual/lance/CMakeLists.txt
@@ -0,0 +1,175 @@
+# Generated from lance.pro.
+
+#####################################################################
+## lance Binary:
+#####################################################################
+
+add_qt_manual_test(lance
+ SOURCES
+ ../../auto/other/lancelot/paintcommands.cpp ../../auto/other/lancelot/paintcommands.h
+ interactivewidget.cpp interactivewidget.h
+ main.cpp
+ widgets.h
+ INCLUDE_DIRECTORIES
+ .
+ ../../auto/other/lancelot
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::PrintSupport
+ Qt::Widgets
+)
+
+# Resources:
+set(icons_resource_files
+ "enum.png"
+ "tools.png"
+)
+
+add_qt_resource(lance "icons"
+ PREFIX
+ "/icons"
+ FILES
+ ${icons_resource_files}
+)
+set_source_files_properties("../../auto/other/lancelot/images/alpha.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/alpha.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/alpha2x2.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/alpha2x2.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/bitmap.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/bitmap.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/border.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/border.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/borderimage.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/borderimage.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/dome_argb32.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_argb32.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/dome_indexed.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_indexed.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/dome_indexed_mask.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_indexed_mask.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/dome_mono.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_mono.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/dome_mono_128.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_mono_128.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/dome_mono_palette.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_mono_palette.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/dome_rgb32.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dome_rgb32.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/dot.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/dot.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/face.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/face.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/gam030.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/gam030.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/gam045.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/gam045.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/gam056.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/gam056.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/gam100.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/gam100.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/gam200.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/gam200.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/image.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/image.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/mask.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/mask.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/mask_100.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/mask_100.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/masked.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/masked.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/sign.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/sign.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/solid.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/solid.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/solid2x2.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/solid2x2.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/struct-image-01.jpg"
+ PROPERTIES QT_RESOURCE_ALIAS "images/struct-image-01.jpg"
+)
+set_source_files_properties("../../auto/other/lancelot/images/struct-image-01.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/struct-image-01.png"
+)
+set_source_files_properties("../../auto/other/lancelot/images/zebra.png"
+ PROPERTIES QT_RESOURCE_ALIAS "images/zebra.png"
+)
+set(images_resource_files
+ "images/alpha.png"
+ "images/alpha2x2.png"
+ "images/bitmap.png"
+ "images/border.png"
+ "images/borderimage.png"
+ "images/dome_argb32.png"
+ "images/dome_indexed.png"
+ "images/dome_indexed_mask.png"
+ "images/dome_mono.png"
+ "images/dome_mono_128.png"
+ "images/dome_mono_palette.png"
+ "images/dome_rgb32.png"
+ "images/dot.png"
+ "images/face.png"
+ "images/gam030.png"
+ "images/gam045.png"
+ "images/gam056.png"
+ "images/gam100.png"
+ "images/gam200.png"
+ "images/image.png"
+ "images/mask.png"
+ "images/mask_100.png"
+ "images/masked.png"
+ "images/sign.png"
+ "images/solid.png"
+ "images/solid2x2.png"
+ "images/struct-image-01.jpg"
+ "images/struct-image-01.png"
+ "images/zebra.png"
+)
+
+add_qt_resource(lance "images"
+ PREFIX
+ "/"
+ BASE
+ "../../auto/other/lancelot"
+ FILES
+ ${images_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:lance.pro:<TRUE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(lance CONDITION TARGET Qt::OpenGL
+ PUBLIC_LIBRARIES
+ Qt::OpenGL
+)
diff --git a/tests/manual/markdown/CMakeLists.txt b/tests/manual/markdown/CMakeLists.txt
new file mode 100644
index 0000000000..f6e5284eea
--- /dev/null
+++ b/tests/manual/markdown/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from html2md.pro.
+
+#####################################################################
+## html2md Binary:
+#####################################################################
+
+add_qt_manual_test(html2md
+ GUI
+ SOURCES
+ html2md.cpp
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:html2md.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/network_remote_stresstest/CMakeLists.txt b/tests/manual/network_remote_stresstest/CMakeLists.txt
new file mode 100644
index 0000000000..4293925a8f
--- /dev/null
+++ b/tests/manual/network_remote_stresstest/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from network_remote_stresstest.pro.
+
+#####################################################################
+## tst_network_remote_stresstest Binary:
+#####################################################################
+
+add_qt_manual_test(tst_network_remote_stresstest
+ SOURCES
+ tst_network_remote_stresstest.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+# Resources:
+set(url-list_resource_files
+ "url-list.txt"
+)
+
+add_qt_resource(tst_network_remote_stresstest "url-list"
+ PREFIX
+ "/"
+ FILES
+ ${url-list_resource_files}
+)
+
diff --git a/tests/manual/network_stresstest/CMakeLists.txt b/tests/manual/network_stresstest/CMakeLists.txt
new file mode 100644
index 0000000000..a8ba9e29b6
--- /dev/null
+++ b/tests/manual/network_stresstest/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from network_stresstest.pro.
+
+#####################################################################
+## tst_network_stresstest Binary:
+#####################################################################
+
+add_qt_manual_test(tst_network_stresstest
+ SOURCES
+ minihttpserver.cpp minihttpserver.h
+ tst_network_stresstest.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+# Resources:
+set(wwwfiles_resource_files
+ "qtest"
+)
+
+add_qt_resource(tst_network_stresstest "wwwfiles"
+ PREFIX
+ "/"
+ FILES
+ ${wwwfiles_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:network_stresstest.pro:<TRUE>:
+# QMAKE_RESOURCE_FLAGS = "-no-compress"
diff --git a/tests/manual/qcursor/CMakeLists.txt b/tests/manual/qcursor/CMakeLists.txt
new file mode 100644
index 0000000000..1824c0c1a4
--- /dev/null
+++ b/tests/manual/qcursor/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from qcursor.pro.
+
+add_subdirectory(allcursors)
+add_subdirectory(childwidget)
+add_subdirectory(childwindow)
+add_subdirectory(childwindowcontainer)
+add_subdirectory(grab_override)
+add_subdirectory(qcursorhighdpi)
diff --git a/tests/manual/qcursor/allcursors/CMakeLists.txt b/tests/manual/qcursor/allcursors/CMakeLists.txt
new file mode 100644
index 0000000000..0452653b86
--- /dev/null
+++ b/tests/manual/qcursor/allcursors/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from allcursors.pro.
+
+#####################################################################
+## tst_allcursors Binary:
+#####################################################################
+
+add_qt_manual_test(tst_allcursors
+ GUI
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+#### Keys ignored in scope 1:.:.:allcursors.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qcursor/childwidget/CMakeLists.txt b/tests/manual/qcursor/childwidget/CMakeLists.txt
new file mode 100644
index 0000000000..5992cdaf73
--- /dev/null
+++ b/tests/manual/qcursor/childwidget/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from childwidget.pro.
+
+#####################################################################
+## tst_manual_childwidget Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_childwidget
+ GUI
+ SOURCES
+ main.cpp
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:childwidget.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qcursor/childwindow/CMakeLists.txt b/tests/manual/qcursor/childwindow/CMakeLists.txt
new file mode 100644
index 0000000000..de2a8dae6d
--- /dev/null
+++ b/tests/manual/qcursor/childwindow/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from childwindow.pro.
+
+#####################################################################
+## childwindow Binary:
+#####################################################################
+
+add_qt_manual_test(childwindow
+ GUI
+ SOURCES
+ main.cpp
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:childwindow.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qcursor/childwindowcontainer/CMakeLists.txt b/tests/manual/qcursor/childwindowcontainer/CMakeLists.txt
new file mode 100644
index 0000000000..70c2bb7431
--- /dev/null
+++ b/tests/manual/qcursor/childwindowcontainer/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from childwindowcontainer.pro.
+
+#####################################################################
+## childwindowcontainer Binary:
+#####################################################################
+
+add_qt_manual_test(childwindowcontainer
+ GUI
+ SOURCES
+ main.cpp
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:childwindowcontainer.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qcursor/grab_override/CMakeLists.txt b/tests/manual/qcursor/grab_override/CMakeLists.txt
new file mode 100644
index 0000000000..d3ea88de65
--- /dev/null
+++ b/tests/manual/qcursor/grab_override/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from grab_override.pro.
+
+#####################################################################
+## t_cursors Binary:
+#####################################################################
+
+add_qt_manual_test(t_cursors
+ GUI
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+# Resources:
+set(images_resource_files
+ "data/monkey_on_64x64.png"
+)
+
+add_qt_resource(t_cursors "images"
+ PREFIX
+ "/"
+ FILES
+ ${images_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:grab_override.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qcursor/qcursorhighdpi/CMakeLists.txt b/tests/manual/qcursor/qcursorhighdpi/CMakeLists.txt
new file mode 100644
index 0000000000..30594c8e0b
--- /dev/null
+++ b/tests/manual/qcursor/qcursorhighdpi/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from qcursorhighdpi.pro.
+
+#####################################################################
+## qcursorhighdpi Binary:
+#####################################################################
+
+add_qt_manual_test(qcursorhighdpi
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qcursorhighdpi.pro:<TRUE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(qcursorhighdpi CONDITION WIN32
+ PUBLIC_LIBRARIES
+ User32
+)
diff --git a/tests/manual/qdesktopservices/CMakeLists.txt b/tests/manual/qdesktopservices/CMakeLists.txt
new file mode 100644
index 0000000000..5d880fcf65
--- /dev/null
+++ b/tests/manual/qdesktopservices/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qdesktopservices.pro.
+
+#####################################################################
+## tst_manual_qdesktopservices Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_qdesktopservices
+ SOURCES
+ tst_qdesktopservices.cpp
+ DEFINES
+ SRCDIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/\\\"
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qdesktopservices.pro:<TRUE>:
+# OTHER_FILES = "test.txt"
+# TEMPLATE = "app"
diff --git a/tests/manual/qdesktopwidget/CMakeLists.txt b/tests/manual/qdesktopwidget/CMakeLists.txt
new file mode 100644
index 0000000000..2034e3c368
--- /dev/null
+++ b/tests/manual/qdesktopwidget/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qdesktopwidget.pro.
+
+#####################################################################
+## qdesktopwidget Binary:
+#####################################################################
+
+add_qt_manual_test(qdesktopwidget
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qdesktopwidget.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qgraphicsitem/CMakeLists.txt b/tests/manual/qgraphicsitem/CMakeLists.txt
new file mode 100644
index 0000000000..a75b436e74
--- /dev/null
+++ b/tests/manual/qgraphicsitem/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qgraphicsitem.pro.
+
+#####################################################################
+## qgraphicsitem Binary:
+#####################################################################
+
+add_qt_manual_test(qgraphicsitem
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/qgraphicsitemgroup/CMakeLists.txt b/tests/manual/qgraphicsitemgroup/CMakeLists.txt
new file mode 100644
index 0000000000..8658c933b3
--- /dev/null
+++ b/tests/manual/qgraphicsitemgroup/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from qgraphicsitemgroup.pro.
+
+#####################################################################
+## qgraphicsitemgroup Binary:
+#####################################################################
+
+add_qt_manual_test(qgraphicsitemgroup
+ GUI
+ SOURCES
+ customitem.cpp customitem.h
+ main.cpp
+ widget.cpp widget.h widget.ui
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+#### Keys ignored in scope 1:.:.:qgraphicsitemgroup.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qgraphicslayout/flicker/CMakeLists.txt b/tests/manual/qgraphicslayout/flicker/CMakeLists.txt
new file mode 100644
index 0000000000..0d7fcce687
--- /dev/null
+++ b/tests/manual/qgraphicslayout/flicker/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from flicker.pro.
+
+#####################################################################
+## flicker Binary:
+#####################################################################
+
+add_qt_manual_test(flicker
+ GUI
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/qhttpnetworkconnection/CMakeLists.txt b/tests/manual/qhttpnetworkconnection/CMakeLists.txt
new file mode 100644
index 0000000000..7331bf4611
--- /dev/null
+++ b/tests/manual/qhttpnetworkconnection/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qhttpnetworkconnection.pro.
+
+#####################################################################
+## tst_manual_qhttpnetworkconnection Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_qhttpnetworkconnection
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qhttpnetworkconnection.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qimagereader/CMakeLists.txt b/tests/manual/qimagereader/CMakeLists.txt
new file mode 100644
index 0000000000..9e5869063b
--- /dev/null
+++ b/tests/manual/qimagereader/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qimagereader.pro.
+
+#####################################################################
+## qimagereader Binary:
+#####################################################################
+
+add_qt_manual_test(qimagereader
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/qlayout/CMakeLists.txt b/tests/manual/qlayout/CMakeLists.txt
new file mode 100644
index 0000000000..541dc18857
--- /dev/null
+++ b/tests/manual/qlayout/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from qlayout.pro.
+
+#####################################################################
+## qlayout Binary:
+#####################################################################
+
+add_qt_manual_test(qlayout
+ GUI
+ SOURCES
+ gridwidget.cpp gridwidget.h
+ hbwidget.cpp hbwidget.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ vbwidget.cpp vbwidget.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qlayout.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qlocale/CMakeLists.txt b/tests/manual/qlocale/CMakeLists.txt
new file mode 100644
index 0000000000..60519da9a1
--- /dev/null
+++ b/tests/manual/qlocale/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from qlocale.pro.
+
+#####################################################################
+## qlocale Binary:
+#####################################################################
+
+add_qt_manual_test(qlocale
+ GUI
+ SOURCES
+ calendar.cpp calendar.h
+ currency.cpp currency.h
+ dateformats.cpp dateformats.h
+ info.cpp info.h
+ languages.cpp languages.h
+ main.cpp
+ miscellaneous.cpp miscellaneous.h
+ numberformats.cpp numberformats.h
+ window.cpp window.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/qmetatype/CMakeLists.txt b/tests/manual/qmetatype/CMakeLists.txt
new file mode 100644
index 0000000000..bb5f75092a
--- /dev/null
+++ b/tests/manual/qmetatype/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qmetatype.pro.
+
+#####################################################################
+## tst_qmetatype_expect_fail Test:
+#####################################################################
+
+add_qt_test(tst_qmetatype_expect_fail
+ GUI
+ SOURCES
+ declare_metatype_noninline.cpp declare_metatype_noninline.h
+ tst_qmetatype.cpp
+)
diff --git a/tests/manual/qmimedatabase/CMakeLists.txt b/tests/manual/qmimedatabase/CMakeLists.txt
new file mode 100644
index 0000000000..038f784ac2
--- /dev/null
+++ b/tests/manual/qmimedatabase/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qmimedatabase.pro.
+
+#####################################################################
+## qmimedatabase Binary:
+#####################################################################
+
+add_qt_manual_test(qmimedatabase
+ SOURCES
+ main.cpp
+)
+
+#### Keys ignored in scope 1:.:.:qmimedatabase.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qnetconmonitor/.prev_CMakeLists.txt b/tests/manual/qnetconmonitor/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..ac9e963905
--- /dev/null
+++ b/tests/manual/qnetconmonitor/.prev_CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qnetconmonitor.pro.
+
+#####################################################################
+## qnetconmonitor Binary:
+#####################################################################
+
+add_qt_manual_test(qnetconmonitor
+ SOURCES
+ tst_qnetconmonitor.cpp
+ LIBRARIES
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qnetconmonitor.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qnetconmonitor/CMakeLists.txt b/tests/manual/qnetconmonitor/CMakeLists.txt
new file mode 100644
index 0000000000..21aee91c1d
--- /dev/null
+++ b/tests/manual/qnetconmonitor/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from qnetconmonitor.pro.
+
+#####################################################################
+## qnetconmonitor Binary:
+#####################################################################
+
+# special case begin
+if (NOT QT_FEATURE_private_tests)
+ return()
+endif()
+# special case end
+
+add_qt_manual_test(qnetconmonitor
+ SOURCES
+ tst_qnetconmonitor.cpp
+ LIBRARIES
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qnetconmonitor.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qnetworkaccessmanager/qget/CMakeLists.txt b/tests/manual/qnetworkaccessmanager/qget/CMakeLists.txt
new file mode 100644
index 0000000000..1d4ffa4b36
--- /dev/null
+++ b/tests/manual/qnetworkaccessmanager/qget/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qget.pro.
+
+#####################################################################
+## qget Binary:
+#####################################################################
+
+add_qt_manual_test(qget
+ SOURCES
+ downloadmanager.cpp
+ qget.cpp qget.h
+ transferitem.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:.:qget.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qnetworkconfiguration/CMakeLists.txt b/tests/manual/qnetworkconfiguration/CMakeLists.txt
new file mode 100644
index 0000000000..f843446888
--- /dev/null
+++ b/tests/manual/qnetworkconfiguration/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qnetworkconfiguration.pro.
+
+#####################################################################
+## tst_manual_qnetworkconfiguration Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_qnetworkconfiguration
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qnetworkconfiguration.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qnetworkconfigurationmanager/CMakeLists.txt b/tests/manual/qnetworkconfigurationmanager/CMakeLists.txt
new file mode 100644
index 0000000000..4bea8449ff
--- /dev/null
+++ b/tests/manual/qnetworkconfigurationmanager/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qnetworkconfigurationmanager.pro.
+
+#####################################################################
+## tst_manual_qnetworkconfigurationmanager Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_qnetworkconfigurationmanager
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qnetworkconfigurationmanager.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qnetworkreply/.prev_CMakeLists.txt b/tests/manual/qnetworkreply/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..f291a6aac2
--- /dev/null
+++ b/tests/manual/qnetworkreply/.prev_CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qnetworkreply.pro.
+
+#####################################################################
+## tst_manual_qnetworkreply Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_qnetworkreply
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qnetworkreply.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qnetworkreply/CMakeLists.txt b/tests/manual/qnetworkreply/CMakeLists.txt
new file mode 100644
index 0000000000..9cad41bf58
--- /dev/null
+++ b/tests/manual/qnetworkreply/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from qnetworkreply.pro.
+
+#####################################################################
+## tst_manual_qnetworkreply Binary:
+#####################################################################
+
+# special case begin
+if (NOT QT_FEATURE_private_tests)
+ return()
+endif()
+# special case end
+
+add_qt_manual_test(tst_manual_qnetworkreply
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:qnetworkreply.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qopenglcontext/CMakeLists.txt b/tests/manual/qopenglcontext/CMakeLists.txt
new file mode 100644
index 0000000000..fc5d4e28d4
--- /dev/null
+++ b/tests/manual/qopenglcontext/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from qopenglcontext.pro.
+
+#####################################################################
+## qopenglcontext Binary:
+#####################################################################
+
+add_qt_manual_test(qopenglcontext
+ GUI
+ SOURCES
+ main.cpp
+ qopenglcontextwindow.cpp qopenglcontextwindow.h
+ LIBRARIES
+ Qt::EglSupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::EglSupport
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:qopenglcontext.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qopengltextureblitter/CMakeLists.txt b/tests/manual/qopengltextureblitter/CMakeLists.txt
new file mode 100644
index 0000000000..14d702dc7f
--- /dev/null
+++ b/tests/manual/qopengltextureblitter/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from qopengltextureblitter.pro.
+
+#####################################################################
+## qopengltextureblitter Binary:
+#####################################################################
+
+add_qt_manual_test(qopengltextureblitter
+ GUI
+ SOURCES
+ main.cpp
+ qopengltextureblitwindow.cpp qopengltextureblitwindow.h
+ INCLUDE_DIRECTORIES
+ .
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:qopengltextureblitter.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qopenglwidget/openglwidget/CMakeLists.txt b/tests/manual/qopenglwidget/openglwidget/CMakeLists.txt
new file mode 100644
index 0000000000..ddc48339b3
--- /dev/null
+++ b/tests/manual/qopenglwidget/openglwidget/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from openglwidget.pro.
+
+#####################################################################
+## openglwidget Binary:
+#####################################################################
+
+add_qt_manual_test(openglwidget
+ GUI
+ SOURCES
+ main.cpp
+ openglwidget.cpp openglwidget.h
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:openglwidget.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qopenglwindow/multiwindow/CMakeLists.txt b/tests/manual/qopenglwindow/multiwindow/CMakeLists.txt
new file mode 100644
index 0000000000..82acac6aff
--- /dev/null
+++ b/tests/manual/qopenglwindow/multiwindow/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from multiwindow.pro.
+
+#####################################################################
+## multiwindow Binary:
+#####################################################################
+
+add_qt_manual_test(multiwindow
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:multiwindow.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qprintdevice_dump/CMakeLists.txt b/tests/manual/qprintdevice_dump/CMakeLists.txt
new file mode 100644
index 0000000000..3725ec062b
--- /dev/null
+++ b/tests/manual/qprintdevice_dump/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qprintdevice_dump.pro.
+
+#####################################################################
+## qprintdevice_dump Binary:
+#####################################################################
+
+add_qt_manual_test(qprintdevice_dump
+ GUI
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::PrintSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::PrintSupport
+)
+
+#### Keys ignored in scope 1:.:.:qprintdevice_dump.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qscreen/CMakeLists.txt b/tests/manual/qscreen/CMakeLists.txt
new file mode 100644
index 0000000000..53b431c548
--- /dev/null
+++ b/tests/manual/qscreen/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qscreen.pro.
+
+#####################################################################
+## qscreen Binary:
+#####################################################################
+
+add_qt_manual_test(qscreen
+ SOURCES
+ main.cpp
+ propertyfield.cpp propertyfield.h
+ propertywatcher.cpp propertywatcher.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qscreen.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qssloptions/CMakeLists.txt b/tests/manual/qssloptions/CMakeLists.txt
new file mode 100644
index 0000000000..1fe53b9e50
--- /dev/null
+++ b/tests/manual/qssloptions/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qssloptions.pro.
+
+#####################################################################
+## tst_qssloptions Binary:
+#####################################################################
+
+add_qt_manual_test(tst_qssloptions
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
diff --git a/tests/manual/qsslsocket/CMakeLists.txt b/tests/manual/qsslsocket/CMakeLists.txt
new file mode 100644
index 0000000000..bd7c9fc569
--- /dev/null
+++ b/tests/manual/qsslsocket/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qsslsocket.pro.
+
+#####################################################################
+## tst_manual_qsslsocket Test:
+#####################################################################
+
+add_qt_test(tst_manual_qsslsocket
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/manual/qstorageinfo/CMakeLists.txt b/tests/manual/qstorageinfo/CMakeLists.txt
new file mode 100644
index 0000000000..fab2da606b
--- /dev/null
+++ b/tests/manual/qstorageinfo/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from qstorageinfo.pro.
+
+#####################################################################
+## qstorageinfo Binary:
+#####################################################################
+
+add_qt_manual_test(qstorageinfo
+ SOURCES
+ main.cpp
+)
diff --git a/tests/manual/qsysinfo/CMakeLists.txt b/tests/manual/qsysinfo/CMakeLists.txt
new file mode 100644
index 0000000000..cd668a5bf2
--- /dev/null
+++ b/tests/manual/qsysinfo/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qsysinfo.pro.
+
+#####################################################################
+## qsysinfo Binary:
+#####################################################################
+
+add_qt_manual_test(qsysinfo
+ SOURCES
+ main.cpp
+)
+
+#### Keys ignored in scope 1:.:.:qsysinfo.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qt_poll/CMakeLists.txt b/tests/manual/qt_poll/CMakeLists.txt
new file mode 100644
index 0000000000..5445a7a2ec
--- /dev/null
+++ b/tests/manual/qt_poll/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qt_poll.pro.
+
+#####################################################################
+## tst_qt_poll Test:
+#####################################################################
+
+add_qt_test(tst_qt_poll
+ SOURCES
+ ../../../src/corelib/kernel/qpoll.cpp
+ tst_qt_poll.cpp
+ INCLUDE_DIRECTORIES
+ ../../../src/corelib/kernel
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+)
diff --git a/tests/manual/qtabbar/CMakeLists.txt b/tests/manual/qtabbar/CMakeLists.txt
new file mode 100644
index 0000000000..a44b6a331a
--- /dev/null
+++ b/tests/manual/qtabbar/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qtabbar.pro.
+
+#####################################################################
+## qtabbar Binary:
+#####################################################################
+
+add_qt_manual_test(qtabbar
+ GUI
+ SOURCES
+ main.cpp
+ tabbarform.cpp tabbarform.h tabbarform.ui
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+#### Keys ignored in scope 1:.:.:qtabbar.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qtabletevent/CMakeLists.txt b/tests/manual/qtabletevent/CMakeLists.txt
new file mode 100644
index 0000000000..06a0bab2d8
--- /dev/null
+++ b/tests/manual/qtabletevent/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from qtabletevent.pro.
+
+add_subdirectory(device_information)
+add_subdirectory(event_compression)
+add_subdirectory(regular_widgets)
diff --git a/tests/manual/qtabletevent/device_information/CMakeLists.txt b/tests/manual/qtabletevent/device_information/CMakeLists.txt
new file mode 100644
index 0000000000..d0e12fac0a
--- /dev/null
+++ b/tests/manual/qtabletevent/device_information/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from device_information.pro.
+
+#####################################################################
+## device_information Binary:
+#####################################################################
+
+add_qt_manual_test(device_information
+ GUI
+ SOURCES
+ main.cpp
+ tabletwidget.cpp tabletwidget.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/qtabletevent/event_compression/CMakeLists.txt b/tests/manual/qtabletevent/event_compression/CMakeLists.txt
new file mode 100644
index 0000000000..b6cc8032e5
--- /dev/null
+++ b/tests/manual/qtabletevent/event_compression/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from event_compression.pro.
+
+#####################################################################
+## event_compression Binary:
+#####################################################################
+
+add_qt_manual_test(event_compression
+ SOURCES
+ main.cpp
+ mousestatwidget.cpp mousestatwidget.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
diff --git a/tests/manual/qtabletevent/regular_widgets/CMakeLists.txt b/tests/manual/qtabletevent/regular_widgets/CMakeLists.txt
new file mode 100644
index 0000000000..7937aa5d90
--- /dev/null
+++ b/tests/manual/qtabletevent/regular_widgets/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from regular_widgets.pro.
+
+#####################################################################
+## regular_widgets Binary:
+#####################################################################
+
+add_qt_manual_test(regular_widgets
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:regular_widgets.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qtbug-52641/CMakeLists.txt b/tests/manual/qtbug-52641/CMakeLists.txt
new file mode 100644
index 0000000000..7f96b66eaa
--- /dev/null
+++ b/tests/manual/qtbug-52641/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qtbug-52641.pro.
+
+#####################################################################
+## qtbug-52641 Binary:
+#####################################################################
+
+add_qt_manual_test(qtbug-52641
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qtbug-52641.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qtbug-8933/CMakeLists.txt b/tests/manual/qtbug-8933/CMakeLists.txt
new file mode 100644
index 0000000000..a5de7687cb
--- /dev/null
+++ b/tests/manual/qtbug-8933/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qtbug-8933.pro.
+
+#####################################################################
+## qtbug-8933 Binary:
+#####################################################################
+
+add_qt_manual_test(qtbug-8933
+ GUI
+ SOURCES
+ main.cpp
+ widget.cpp widget.h widget.ui
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+#### Keys ignored in scope 1:.:.:qtbug-8933.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qtexteditlist/CMakeLists.txt b/tests/manual/qtexteditlist/CMakeLists.txt
new file mode 100644
index 0000000000..963ffa5441
--- /dev/null
+++ b/tests/manual/qtexteditlist/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qtexteditlist.pro.
+
+#####################################################################
+## qtexteditlist Binary:
+#####################################################################
+
+add_qt_manual_test(qtexteditlist
+ GUI
+ SOURCES
+ main.cpp
+ widget.cpp widget.h widget.ui
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+#### Keys ignored in scope 1:.:.:qtexteditlist.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qtexttableborders/CMakeLists.txt b/tests/manual/qtexttableborders/CMakeLists.txt
new file mode 100644
index 0000000000..c273b3aeb2
--- /dev/null
+++ b/tests/manual/qtexttableborders/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from qtexttableborders.pro.
+
+#####################################################################
+## qtexttableborders Binary:
+#####################################################################
+
+add_qt_manual_test(qtexttableborders
+ GUI
+ SOURCES
+ main.cpp
+ widget.cpp widget.h widget.ui
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::PrintSupport
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+# Resources:
+set(resources_resource_files
+ "table-border-test-header.html"
+ "table-border-test.html"
+)
+
+add_qt_resource(qtexttableborders "resources"
+ PREFIX
+ "/"
+ FILES
+ ${resources_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:qtexttableborders.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qtouchevent/CMakeLists.txt b/tests/manual/qtouchevent/CMakeLists.txt
new file mode 100644
index 0000000000..8cee742ca1
--- /dev/null
+++ b/tests/manual/qtouchevent/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qtouchevent.pro.
+
+#####################################################################
+## qtouchevent Binary:
+#####################################################################
+
+add_qt_manual_test(qtouchevent
+ SOURCES
+ form.ui
+ main.cpp
+ touchwidget.cpp touchwidget.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
diff --git a/tests/manual/qvulkaninstance/CMakeLists.txt b/tests/manual/qvulkaninstance/CMakeLists.txt
new file mode 100644
index 0000000000..74d0dab594
--- /dev/null
+++ b/tests/manual/qvulkaninstance/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qvulkaninstance.pro.
+
+#####################################################################
+## qvulkaninstance Binary:
+#####################################################################
+
+add_qt_manual_test(qvulkaninstance
+ GUI
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:qvulkaninstance.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/qwidget_zorder/CMakeLists.txt b/tests/manual/qwidget_zorder/CMakeLists.txt
new file mode 100644
index 0000000000..2ae52decac
--- /dev/null
+++ b/tests/manual/qwidget_zorder/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qwidget_zorder.pro.
+
+#####################################################################
+## qwidget_zorder Binary:
+#####################################################################
+
+add_qt_manual_test(qwidget_zorder
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/repaint/CMakeLists.txt b/tests/manual/repaint/CMakeLists.txt
new file mode 100644
index 0000000000..fd579a76a2
--- /dev/null
+++ b/tests/manual/repaint/CMakeLists.txt
@@ -0,0 +1,9 @@
+# Generated from repaint.pro.
+
+add_subdirectory(mainwindow)
+add_subdirectory(scrollarea)
+add_subdirectory(splitter)
+add_subdirectory(tableview)
+add_subdirectory(task141091)
+add_subdirectory(toplevel)
+add_subdirectory(widget)
diff --git a/tests/manual/repaint/mainwindow/CMakeLists.txt b/tests/manual/repaint/mainwindow/CMakeLists.txt
new file mode 100644
index 0000000000..f71b5ddf6c
--- /dev/null
+++ b/tests/manual/repaint/mainwindow/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from mainwindow.pro.
+
+#####################################################################
+## tst_manual_mainwindow Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_mainwindow
+ GUI
+ SOURCES
+ ../shared/shared.h
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/repaint/scrollarea/CMakeLists.txt b/tests/manual/repaint/scrollarea/CMakeLists.txt
new file mode 100644
index 0000000000..9d2d52fd65
--- /dev/null
+++ b/tests/manual/repaint/scrollarea/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from scrollarea.pro.
+
+#####################################################################
+## tst_manual_scrollarea Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_scrollarea
+ GUI
+ SOURCES
+ ../shared/shared.h
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/repaint/splitter/CMakeLists.txt b/tests/manual/repaint/splitter/CMakeLists.txt
new file mode 100644
index 0000000000..cb1d7aab0b
--- /dev/null
+++ b/tests/manual/repaint/splitter/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from splitter.pro.
+
+#####################################################################
+## splitter Binary:
+#####################################################################
+
+add_qt_manual_test(splitter
+ GUI
+ SOURCES
+ ../shared/shared.h
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/repaint/tableview/CMakeLists.txt b/tests/manual/repaint/tableview/CMakeLists.txt
new file mode 100644
index 0000000000..5c9634db88
--- /dev/null
+++ b/tests/manual/repaint/tableview/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from tableview.pro.
+
+#####################################################################
+## tableview Binary:
+#####################################################################
+
+add_qt_manual_test(tableview
+ GUI
+ SOURCES
+ ../shared/shared.h
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/repaint/task141091/CMakeLists.txt b/tests/manual/repaint/task141091/CMakeLists.txt
new file mode 100644
index 0000000000..3a74ef58de
--- /dev/null
+++ b/tests/manual/repaint/task141091/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from task141091.pro.
+
+#####################################################################
+## task141091 Binary:
+#####################################################################
+
+add_qt_manual_test(task141091
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/repaint/toplevel/CMakeLists.txt b/tests/manual/repaint/toplevel/CMakeLists.txt
new file mode 100644
index 0000000000..6b5a3c83a9
--- /dev/null
+++ b/tests/manual/repaint/toplevel/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from toplevel.pro.
+
+#####################################################################
+## tst_manual_toplevel Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_toplevel
+ SOURCES
+ ../shared/shared.h
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/repaint/widget/CMakeLists.txt b/tests/manual/repaint/widget/CMakeLists.txt
new file mode 100644
index 0000000000..f58c49c9fb
--- /dev/null
+++ b/tests/manual/repaint/widget/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from widget.pro.
+
+#####################################################################
+## widget Binary:
+#####################################################################
+
+add_qt_manual_test(widget
+ GUI
+ SOURCES
+ ../shared/shared.h
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/rhi/CMakeLists.txt b/tests/manual/rhi/CMakeLists.txt
new file mode 100644
index 0000000000..621a307304
--- /dev/null
+++ b/tests/manual/rhi/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from rhi.pro.
+
+add_subdirectory(hellominimalcrossgfxtriangle)
+add_subdirectory(compressedtexture_bc1)
+add_subdirectory(compressedtexture_bc1_subupload)
+add_subdirectory(texuploads)
+add_subdirectory(msaatexture)
+add_subdirectory(msaarenderbuffer)
+add_subdirectory(cubemap)
+add_subdirectory(cubemap_scissor)
+add_subdirectory(multiwindow)
+add_subdirectory(multiwindow_threaded)
+add_subdirectory(triquadcube)
+add_subdirectory(offscreen)
+add_subdirectory(floattexture)
+add_subdirectory(mrt)
+add_subdirectory(shadowmap)
+add_subdirectory(computebuffer)
+add_subdirectory(computeimage)
+add_subdirectory(instancing)
+if(QT_FEATURE_widgets)
+ add_subdirectory(qrhiprof)
+endif()
diff --git a/tests/manual/rhi/compressedtexture_bc1/CMakeLists.txt b/tests/manual/rhi/compressedtexture_bc1/CMakeLists.txt
new file mode 100644
index 0000000000..a3754c7d75
--- /dev/null
+++ b/tests/manual/rhi/compressedtexture_bc1/CMakeLists.txt
@@ -0,0 +1,42 @@
+# Generated from compressedtexture_bc1.pro.
+
+#####################################################################
+## compressedtexture_bc1 Binary:
+#####################################################################
+
+add_qt_manual_test(compressedtexture_bc1
+ GUI
+ SOURCES
+ compressedtexture_bc1.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../shared/qt256_bc1_9mips.dds"
+ PROPERTIES QT_RESOURCE_ALIAS "qt256_bc1_9mips.dds"
+)
+set_source_files_properties("../shared/texture.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.frag.qsb"
+)
+set_source_files_properties("../shared/texture.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.vert.qsb"
+)
+set(compressedtexture_bc1_resource_files
+ "../shared/qt256_bc1_9mips.dds"
+ "../shared/texture.frag.qsb"
+ "../shared/texture.vert.qsb"
+)
+
+add_qt_resource(compressedtexture_bc1 "compressedtexture_bc1"
+ PREFIX
+ "/"
+ FILES
+ ${compressedtexture_bc1_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:compressedtexture_bc1.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/compressedtexture_bc1_subupload/CMakeLists.txt b/tests/manual/rhi/compressedtexture_bc1_subupload/CMakeLists.txt
new file mode 100644
index 0000000000..c3c2147eb8
--- /dev/null
+++ b/tests/manual/rhi/compressedtexture_bc1_subupload/CMakeLists.txt
@@ -0,0 +1,46 @@
+# Generated from compressedtexture_bc1_subupload.pro.
+
+#####################################################################
+## compressedtexture_bc1_subupload Binary:
+#####################################################################
+
+add_qt_manual_test(compressedtexture_bc1_subupload
+ GUI
+ SOURCES
+ compressedtexture_bc1_subupload.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../shared/bwqt224_64_nomips.dds"
+ PROPERTIES QT_RESOURCE_ALIAS "bwqt224_64_nomips.dds"
+)
+set_source_files_properties("../shared/qt256_bc1_9mips.dds"
+ PROPERTIES QT_RESOURCE_ALIAS "qt256_bc1_9mips.dds"
+)
+set_source_files_properties("../shared/texture.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.frag.qsb"
+)
+set_source_files_properties("../shared/texture.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.vert.qsb"
+)
+set(compressedtexture_bc1_subupload_resource_files
+ "../shared/bwqt224_64_nomips.dds"
+ "../shared/qt256_bc1_9mips.dds"
+ "../shared/texture.frag.qsb"
+ "../shared/texture.vert.qsb"
+)
+
+add_qt_resource(compressedtexture_bc1_subupload "compressedtexture_bc1_subupload"
+ PREFIX
+ "/"
+ FILES
+ ${compressedtexture_bc1_subupload_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:compressedtexture_bc1_subupload.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/computebuffer/CMakeLists.txt b/tests/manual/rhi/computebuffer/CMakeLists.txt
new file mode 100644
index 0000000000..41d46fcc56
--- /dev/null
+++ b/tests/manual/rhi/computebuffer/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from computebuffer.pro.
+
+#####################################################################
+## computebuffer Binary:
+#####################################################################
+
+add_qt_manual_test(computebuffer
+ GUI
+ SOURCES
+ computebuffer.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set(computebuffer_resource_files
+ "buffer.comp.qsb"
+ "main.frag.qsb"
+ "main.vert.qsb"
+)
+
+add_qt_resource(computebuffer "computebuffer"
+ PREFIX
+ "/"
+ FILES
+ ${computebuffer_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:computebuffer.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/computeimage/CMakeLists.txt b/tests/manual/rhi/computeimage/CMakeLists.txt
new file mode 100644
index 0000000000..ffb99b8d1c
--- /dev/null
+++ b/tests/manual/rhi/computeimage/CMakeLists.txt
@@ -0,0 +1,43 @@
+# Generated from computeimage.pro.
+
+#####################################################################
+## computeimage Binary:
+#####################################################################
+
+add_qt_manual_test(computeimage
+ GUI
+ SOURCES
+ computeimage.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../shared/qt256.png"
+ PROPERTIES QT_RESOURCE_ALIAS "qt256.png"
+)
+set_source_files_properties("../shared/texture.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.frag.qsb"
+)
+set_source_files_properties("../shared/texture.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.vert.qsb"
+)
+set(computeimage_resource_files
+ "../shared/qt256.png"
+ "../shared/texture.frag.qsb"
+ "../shared/texture.vert.qsb"
+ "image.comp.qsb"
+)
+
+add_qt_resource(computeimage "computeimage"
+ PREFIX
+ "/"
+ FILES
+ ${computeimage_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:computeimage.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/cubemap/CMakeLists.txt b/tests/manual/rhi/cubemap/CMakeLists.txt
new file mode 100644
index 0000000000..5886b40138
--- /dev/null
+++ b/tests/manual/rhi/cubemap/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from cubemap.pro.
+
+#####################################################################
+## cubemap Binary:
+#####################################################################
+
+add_qt_manual_test(cubemap
+ GUI
+ SOURCES
+ cubemap.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set(cubemap_resource_files
+ "c.png"
+ "cubemap.frag.qsb"
+ "cubemap.vert.qsb"
+)
+
+add_qt_resource(cubemap "cubemap"
+ PREFIX
+ "/"
+ FILES
+ ${cubemap_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:cubemap.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/cubemap_scissor/CMakeLists.txt b/tests/manual/rhi/cubemap_scissor/CMakeLists.txt
new file mode 100644
index 0000000000..038209c448
--- /dev/null
+++ b/tests/manual/rhi/cubemap_scissor/CMakeLists.txt
@@ -0,0 +1,42 @@
+# Generated from cubemap_scissor.pro.
+
+#####################################################################
+## cubemap_scissor Binary:
+#####################################################################
+
+add_qt_manual_test(cubemap_scissor
+ GUI
+ SOURCES
+ cubemap_scissor.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../cubemap/c.png"
+ PROPERTIES QT_RESOURCE_ALIAS "c.png"
+)
+set_source_files_properties("../cubemap/cubemap.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "cubemap.frag.qsb"
+)
+set_source_files_properties("../cubemap/cubemap.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "cubemap.vert.qsb"
+)
+set(cubemap_scissor_resource_files
+ "../cubemap/c.png"
+ "../cubemap/cubemap.frag.qsb"
+ "../cubemap/cubemap.vert.qsb"
+)
+
+add_qt_resource(cubemap_scissor "cubemap_scissor"
+ PREFIX
+ "/"
+ FILES
+ ${cubemap_scissor_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:cubemap_scissor.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/floattexture/CMakeLists.txt b/tests/manual/rhi/floattexture/CMakeLists.txt
new file mode 100644
index 0000000000..b87ddabab8
--- /dev/null
+++ b/tests/manual/rhi/floattexture/CMakeLists.txt
@@ -0,0 +1,42 @@
+# Generated from floattexture.pro.
+
+#####################################################################
+## floattexture Binary:
+#####################################################################
+
+add_qt_manual_test(floattexture
+ GUI
+ SOURCES
+ floattexture.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../shared/OpenfootageNET_fieldairport-512.hdr"
+ PROPERTIES QT_RESOURCE_ALIAS "OpenfootageNET_fieldairport-512.hdr"
+)
+set_source_files_properties("../shared/texture.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.frag.qsb"
+)
+set_source_files_properties("../shared/texture.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.vert.qsb"
+)
+set(floattexture_resource_files
+ "../shared/OpenfootageNET_fieldairport-512.hdr"
+ "../shared/texture.frag.qsb"
+ "../shared/texture.vert.qsb"
+)
+
+add_qt_resource(floattexture "floattexture"
+ PREFIX
+ "/"
+ FILES
+ ${floattexture_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:floattexture.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/hellominimalcrossgfxtriangle/CMakeLists.txt b/tests/manual/rhi/hellominimalcrossgfxtriangle/CMakeLists.txt
new file mode 100644
index 0000000000..d933d8ae88
--- /dev/null
+++ b/tests/manual/rhi/hellominimalcrossgfxtriangle/CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from hellominimalcrossgfxtriangle.pro.
+
+#####################################################################
+## hellominimalcrossgfxtriangle Binary:
+#####################################################################
+
+add_qt_manual_test(hellominimalcrossgfxtriangle
+ GUI
+ SOURCES
+ hellominimalcrossgfxtriangle.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../shared/color.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "color.frag.qsb"
+)
+set_source_files_properties("../shared/color.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "color.vert.qsb"
+)
+set(hellominimalcrossgfxtriangle_resource_files
+ "../shared/color.frag.qsb"
+ "../shared/color.vert.qsb"
+)
+
+add_qt_resource(hellominimalcrossgfxtriangle "hellominimalcrossgfxtriangle"
+ PREFIX
+ "/"
+ FILES
+ ${hellominimalcrossgfxtriangle_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:hellominimalcrossgfxtriangle.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/instancing/CMakeLists.txt b/tests/manual/rhi/instancing/CMakeLists.txt
new file mode 100644
index 0000000000..f744daf900
--- /dev/null
+++ b/tests/manual/rhi/instancing/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from instancing.pro.
+
+#####################################################################
+## instancing Binary:
+#####################################################################
+
+add_qt_manual_test(instancing
+ GUI
+ SOURCES
+ instancing.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set(instancing_resource_files
+ "inst.frag.qsb"
+ "inst.vert.qsb"
+)
+
+add_qt_resource(instancing "instancing"
+ PREFIX
+ "/"
+ FILES
+ ${instancing_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:instancing.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/mrt/CMakeLists.txt b/tests/manual/rhi/mrt/CMakeLists.txt
new file mode 100644
index 0000000000..74fd026166
--- /dev/null
+++ b/tests/manual/rhi/mrt/CMakeLists.txt
@@ -0,0 +1,40 @@
+# Generated from mrt.pro.
+
+#####################################################################
+## mrt Binary:
+#####################################################################
+
+add_qt_manual_test(mrt
+ GUI
+ SOURCES
+ mrt.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../shared/texture.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.frag.qsb"
+)
+set_source_files_properties("../shared/texture.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.vert.qsb"
+)
+set(mrt_resource_files
+ "../shared/texture.frag.qsb"
+ "../shared/texture.vert.qsb"
+ "mrt.frag.qsb"
+ "mrt.vert.qsb"
+)
+
+add_qt_resource(mrt "mrt"
+ PREFIX
+ "/"
+ FILES
+ ${mrt_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:mrt.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/msaarenderbuffer/CMakeLists.txt b/tests/manual/rhi/msaarenderbuffer/CMakeLists.txt
new file mode 100644
index 0000000000..65a0388f80
--- /dev/null
+++ b/tests/manual/rhi/msaarenderbuffer/CMakeLists.txt
@@ -0,0 +1,46 @@
+# Generated from msaarenderbuffer.pro.
+
+#####################################################################
+## msaarenderbuffer Binary:
+#####################################################################
+
+add_qt_manual_test(msaarenderbuffer
+ GUI
+ SOURCES
+ msaarenderbuffer.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../shared/color.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "color.frag.qsb"
+)
+set_source_files_properties("../shared/color.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "color.vert.qsb"
+)
+set_source_files_properties("../shared/texture.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.frag.qsb"
+)
+set_source_files_properties("../shared/texture.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.vert.qsb"
+)
+set(msaarenderbuffer_resource_files
+ "../shared/color.frag.qsb"
+ "../shared/color.vert.qsb"
+ "../shared/texture.frag.qsb"
+ "../shared/texture.vert.qsb"
+)
+
+add_qt_resource(msaarenderbuffer "msaarenderbuffer"
+ PREFIX
+ "/"
+ FILES
+ ${msaarenderbuffer_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:msaarenderbuffer.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/msaatexture/CMakeLists.txt b/tests/manual/rhi/msaatexture/CMakeLists.txt
new file mode 100644
index 0000000000..79dc9d6168
--- /dev/null
+++ b/tests/manual/rhi/msaatexture/CMakeLists.txt
@@ -0,0 +1,50 @@
+# Generated from msaatexture.pro.
+
+#####################################################################
+## msaatexture Binary:
+#####################################################################
+
+add_qt_manual_test(msaatexture
+ GUI
+ SOURCES
+ msaatexture.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../shared/color.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "color.frag.qsb"
+)
+set_source_files_properties("../shared/color.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "color.vert.qsb"
+)
+set_source_files_properties("../shared/texture.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.frag.qsb"
+)
+set_source_files_properties("../shared/texture.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.vert.qsb"
+)
+set_source_files_properties("../shared/texture_ms4.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture_ms4.frag.qsb"
+)
+set(msaatexture_resource_files
+ "../shared/color.frag.qsb"
+ "../shared/color.vert.qsb"
+ "../shared/texture.frag.qsb"
+ "../shared/texture.vert.qsb"
+ "../shared/texture_ms4.frag.qsb"
+)
+
+add_qt_resource(msaatexture "msaatexture"
+ PREFIX
+ "/"
+ FILES
+ ${msaatexture_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:msaatexture.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/multiwindow/CMakeLists.txt b/tests/manual/rhi/multiwindow/CMakeLists.txt
new file mode 100644
index 0000000000..67bd6d82be
--- /dev/null
+++ b/tests/manual/rhi/multiwindow/CMakeLists.txt
@@ -0,0 +1,39 @@
+# Generated from multiwindow.pro.
+
+#####################################################################
+## multiwindow Binary:
+#####################################################################
+
+add_qt_manual_test(multiwindow
+ GUI
+ SOURCES
+ multiwindow.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set_source_files_properties("../shared/color.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "color.frag.qsb"
+)
+set_source_files_properties("../shared/color.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "color.vert.qsb"
+)
+set(multiwindow_resource_files
+ "../shared/color.frag.qsb"
+ "../shared/color.vert.qsb"
+)
+
+add_qt_resource(multiwindow "multiwindow"
+ PREFIX
+ "/"
+ FILES
+ ${multiwindow_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:multiwindow.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/multiwindow_threaded/CMakeLists.txt b/tests/manual/rhi/multiwindow_threaded/CMakeLists.txt
new file mode 100644
index 0000000000..39224ef40c
--- /dev/null
+++ b/tests/manual/rhi/multiwindow_threaded/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from multiwindow_threaded.pro.
+
+#####################################################################
+## multiwindow_threaded Binary:
+#####################################################################
+
+add_qt_manual_test(multiwindow_threaded
+ GUI
+ SOURCES
+ multiwindow_threaded.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+# Resources:
+set_source_files_properties("../shared/qt256.png"
+ PROPERTIES QT_RESOURCE_ALIAS "qt256.png"
+)
+set_source_files_properties("../shared/texture.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.frag.qsb"
+)
+set_source_files_properties("../shared/texture.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.vert.qsb"
+)
+set(multiwindow_threaded_resource_files
+ "../shared/qt256.png"
+ "../shared/texture.frag.qsb"
+ "../shared/texture.vert.qsb"
+)
+
+add_qt_resource(multiwindow_threaded "multiwindow_threaded"
+ PREFIX
+ "/"
+ FILES
+ ${multiwindow_threaded_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:multiwindow_threaded.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/offscreen/CMakeLists.txt b/tests/manual/rhi/offscreen/CMakeLists.txt
new file mode 100644
index 0000000000..ceefc4c0d6
--- /dev/null
+++ b/tests/manual/rhi/offscreen/CMakeLists.txt
@@ -0,0 +1,37 @@
+# Generated from offscreen.pro.
+
+#####################################################################
+## offscreen Binary:
+#####################################################################
+
+add_qt_manual_test(offscreen
+ SOURCES
+ offscreen.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../shared/color.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "color.frag.qsb"
+)
+set_source_files_properties("../shared/color.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "color.vert.qsb"
+)
+set(offscreen_resource_files
+ "../shared/color.frag.qsb"
+ "../shared/color.vert.qsb"
+)
+
+add_qt_resource(offscreen "offscreen"
+ PREFIX
+ "/"
+ FILES
+ ${offscreen_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:offscreen.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/qrhiprof/CMakeLists.txt b/tests/manual/rhi/qrhiprof/CMakeLists.txt
new file mode 100644
index 0000000000..d0a11e94b3
--- /dev/null
+++ b/tests/manual/rhi/qrhiprof/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qrhiprof.pro.
+
+#####################################################################
+## qrhiprof Binary:
+#####################################################################
+
+add_qt_manual_test(qrhiprof
+ GUI
+ SOURCES
+ qrhiprof.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Network
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qrhiprof.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/shadowmap/CMakeLists.txt b/tests/manual/rhi/shadowmap/CMakeLists.txt
new file mode 100644
index 0000000000..2f80d0209d
--- /dev/null
+++ b/tests/manual/rhi/shadowmap/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from shadowmap.pro.
+
+#####################################################################
+## shadowmap Binary:
+#####################################################################
+
+add_qt_manual_test(shadowmap
+ GUI
+ SOURCES
+ shadowmap.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set(shadowmap_resource_files
+ "main.frag.qsb"
+ "main.vert.qsb"
+ "shadowmap.frag.qsb"
+ "shadowmap.vert.qsb"
+)
+
+add_qt_resource(shadowmap "shadowmap"
+ PREFIX
+ "/"
+ FILES
+ ${shadowmap_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:shadowmap.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/texuploads/CMakeLists.txt b/tests/manual/rhi/texuploads/CMakeLists.txt
new file mode 100644
index 0000000000..c2efd3a1ea
--- /dev/null
+++ b/tests/manual/rhi/texuploads/CMakeLists.txt
@@ -0,0 +1,42 @@
+# Generated from texuploads.pro.
+
+#####################################################################
+## texuploads Binary:
+#####################################################################
+
+add_qt_manual_test(texuploads
+ GUI
+ SOURCES
+ texuploads.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../shared/qt256.png"
+ PROPERTIES QT_RESOURCE_ALIAS "qt256.png"
+)
+set_source_files_properties("../shared/texture.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.frag.qsb"
+)
+set_source_files_properties("../shared/texture.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.vert.qsb"
+)
+set(texuploads_resource_files
+ "../shared/qt256.png"
+ "../shared/texture.frag.qsb"
+ "../shared/texture.vert.qsb"
+)
+
+add_qt_resource(texuploads "texuploads"
+ PREFIX
+ "/"
+ FILES
+ ${texuploads_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:texuploads.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/rhi/triquadcube/CMakeLists.txt b/tests/manual/rhi/triquadcube/CMakeLists.txt
new file mode 100644
index 0000000000..584f9aa4c7
--- /dev/null
+++ b/tests/manual/rhi/triquadcube/CMakeLists.txt
@@ -0,0 +1,54 @@
+# Generated from triquadcube.pro.
+
+#####################################################################
+## triquadcube Binary:
+#####################################################################
+
+add_qt_manual_test(triquadcube
+ GUI
+ SOURCES
+ quadrenderer.cpp quadrenderer.h
+ texturedcuberenderer.cpp texturedcuberenderer.h
+ triangleoncuberenderer.cpp triangleoncuberenderer.h
+ trianglerenderer.cpp trianglerenderer.h
+ triquadcube.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+# Resources:
+set_source_files_properties("../shared/color.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "color.frag.qsb"
+)
+set_source_files_properties("../shared/color.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "color.vert.qsb"
+)
+set_source_files_properties("../shared/qt256.png"
+ PROPERTIES QT_RESOURCE_ALIAS "qt256.png"
+)
+set_source_files_properties("../shared/texture.frag.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.frag.qsb"
+)
+set_source_files_properties("../shared/texture.vert.qsb"
+ PROPERTIES QT_RESOURCE_ALIAS "texture.vert.qsb"
+)
+set(triquadcube_resource_files
+ "../shared/color.frag.qsb"
+ "../shared/color.vert.qsb"
+ "../shared/qt256.png"
+ "../shared/texture.frag.qsb"
+ "../shared/texture.vert.qsb"
+)
+
+add_qt_resource(triquadcube "triquadcube"
+ PREFIX
+ "/"
+ FILES
+ ${triquadcube_resource_files}
+)
+
+
+#### Keys ignored in scope 1:.:.:triquadcube.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/shortcuts/CMakeLists.txt b/tests/manual/shortcuts/CMakeLists.txt
new file mode 100644
index 0000000000..c4ac6b040b
--- /dev/null
+++ b/tests/manual/shortcuts/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from shortcuts.pro.
+
+#####################################################################
+## shortcuts Binary:
+#####################################################################
+
+add_qt_manual_test(shortcuts
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:shortcuts.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/socketengine/.prev_CMakeLists.txt b/tests/manual/socketengine/.prev_CMakeLists.txt
new file mode 100644
index 0000000000..1540a1f552
--- /dev/null
+++ b/tests/manual/socketengine/.prev_CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from socketengine.pro.
+
+#####################################################################
+## tst_socketengine Binary:
+#####################################################################
+
+add_qt_manual_test(tst_socketengine
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:socketengine.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/socketengine/CMakeLists.txt b/tests/manual/socketengine/CMakeLists.txt
new file mode 100644
index 0000000000..4ac94fd180
--- /dev/null
+++ b/tests/manual/socketengine/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from socketengine.pro.
+
+#####################################################################
+## tst_socketengine Binary:
+#####################################################################
+
+# special case begin
+if (NOT QT_FEATURE_private_tests)
+ return()
+endif()
+# special case end
+
+add_qt_manual_test(tst_socketengine
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+ PUBLIC_LIBRARIES
+ Qt::Network
+ Qt::Test
+)
+
+#### Keys ignored in scope 1:.:.:socketengine.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/textrendering/CMakeLists.txt b/tests/manual/textrendering/CMakeLists.txt
new file mode 100644
index 0000000000..788f9fc34f
--- /dev/null
+++ b/tests/manual/textrendering/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from textrendering.pro.
+
+add_subdirectory(glyphshaping)
+add_subdirectory(textperformance)
+add_subdirectory(nativetext)
diff --git a/tests/manual/textrendering/glyphshaping/CMakeLists.txt b/tests/manual/textrendering/glyphshaping/CMakeLists.txt
new file mode 100644
index 0000000000..891503dea1
--- /dev/null
+++ b/tests/manual/textrendering/glyphshaping/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from glyphshaping.pro.
+
+#####################################################################
+## glyphshaping Binary:
+#####################################################################
+
+add_qt_manual_test(glyphshaping
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:glyphshaping.pro:<TRUE>:
+# DEPLOYMENT = "glyphshaping_data"
+# glyphshaping_data.files = "$$PWD/glyphshaping_data.xml"
+# glyphshaping_data.path = "."
diff --git a/tests/manual/textrendering/nativetext/CMakeLists.txt b/tests/manual/textrendering/nativetext/CMakeLists.txt
new file mode 100644
index 0000000000..c7d50f2a6f
--- /dev/null
+++ b/tests/manual/textrendering/nativetext/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from nativetext.pro.
+
+#####################################################################
+## nativetext Binary:
+#####################################################################
+
+add_qt_manual_test(nativetext
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(nativetext CONDITION APPLE
+ PUBLIC_LIBRARIES
+ ${FWAppKit}
+ ${FWCoreGraphics}
+ ${FWFoundation}
+ COMPILE_OPTIONS
+ -x
+ objective-c++
+)
diff --git a/tests/manual/textrendering/textperformance/CMakeLists.txt b/tests/manual/textrendering/textperformance/CMakeLists.txt
new file mode 100644
index 0000000000..cf21b4ecac
--- /dev/null
+++ b/tests/manual/textrendering/textperformance/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from textperformance.pro.
+
+#####################################################################
+## textperformance Binary:
+#####################################################################
+
+add_qt_manual_test(textperformance
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/touch/CMakeLists.txt b/tests/manual/touch/CMakeLists.txt
new file mode 100644
index 0000000000..5f7e9ec286
--- /dev/null
+++ b/tests/manual/touch/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from touch.pro.
+
+#####################################################################
+## touch Binary:
+#####################################################################
+
+add_qt_manual_test(touch
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:touch.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/touchGraphicsItem/CMakeLists.txt b/tests/manual/touchGraphicsItem/CMakeLists.txt
new file mode 100644
index 0000000000..cc02dcdab2
--- /dev/null
+++ b/tests/manual/touchGraphicsItem/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from touchGraphicsItem.pro.
+
+#####################################################################
+## touchGraphicsItem Binary:
+#####################################################################
+
+add_qt_manual_test(touchGraphicsItem
+ GUI
+ SOURCES
+ main.cpp
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:touchGraphicsItem.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/transientwindow/CMakeLists.txt b/tests/manual/transientwindow/CMakeLists.txt
new file mode 100644
index 0000000000..0356bdcd02
--- /dev/null
+++ b/tests/manual/transientwindow/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from transientwindow.pro.
+
+#####################################################################
+## transientwindow Binary:
+#####################################################################
+
+add_qt_manual_test(transientwindow
+ GUI
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:transientwindow.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/triangulator/CMakeLists.txt b/tests/manual/triangulator/CMakeLists.txt
new file mode 100644
index 0000000000..8c6e8eb021
--- /dev/null
+++ b/tests/manual/triangulator/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from triangulator.pro.
+
+#####################################################################
+## triangulator Binary:
+#####################################################################
+
+add_qt_manual_test(triangulator
+ GUI
+ SOURCES
+ main.cpp
+ triviswidget.cpp triviswidget.h
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:triangulator.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/unc/CMakeLists.txt b/tests/manual/unc/CMakeLists.txt
new file mode 100644
index 0000000000..f63ffe34ad
--- /dev/null
+++ b/tests/manual/unc/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from unc.pro.
+
+#####################################################################
+## unc Binary:
+#####################################################################
+
+add_qt_manual_test(unc
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:unc.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgetgrab/CMakeLists.txt b/tests/manual/widgetgrab/CMakeLists.txt
new file mode 100644
index 0000000000..a556388207
--- /dev/null
+++ b/tests/manual/widgetgrab/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from widgetgrab.pro.
+
+#####################################################################
+## widgetgrab Binary:
+#####################################################################
+
+add_qt_manual_test(widgetgrab
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:widgetgrab.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/CMakeLists.txt b/tests/manual/widgets/CMakeLists.txt
new file mode 100644
index 0000000000..ac50f6c1ae
--- /dev/null
+++ b/tests/manual/widgets/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from widgets.pro.
+
+add_subdirectory(itemviews)
+add_subdirectory(qgraphicsview)
+add_subdirectory(kernel)
+add_subdirectory(widgets)
+add_subdirectory(styles)
diff --git a/tests/manual/widgets/itemviews/CMakeLists.txt b/tests/manual/widgets/itemviews/CMakeLists.txt
new file mode 100644
index 0000000000..2e6a7e563b
--- /dev/null
+++ b/tests/manual/widgets/itemviews/CMakeLists.txt
@@ -0,0 +1,8 @@
+# Generated from itemviews.pro.
+
+add_subdirectory(delegate)
+add_subdirectory(qconcatenatetablesproxymodel)
+add_subdirectory(qheaderview)
+add_subdirectory(qtreeview)
+add_subdirectory(qtreewidget)
+add_subdirectory(tableview-span-navigation)
diff --git a/tests/manual/widgets/itemviews/autoResizePrecision/tablehorz/CMakeLists.txt b/tests/manual/widgets/itemviews/autoResizePrecision/tablehorz/CMakeLists.txt
new file mode 100644
index 0000000000..8d5730267d
--- /dev/null
+++ b/tests/manual/widgets/itemviews/autoResizePrecision/tablehorz/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from testtable1.pro.
+
+#####################################################################
+## testtable1 Binary:
+#####################################################################
+
+add_qt_manual_test(testtable1
+ GUI
+ SOURCES
+ testtable1.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/widgets/itemviews/autoResizePrecision/tablevert/CMakeLists.txt b/tests/manual/widgets/itemviews/autoResizePrecision/tablevert/CMakeLists.txt
new file mode 100644
index 0000000000..ed9f5c98eb
--- /dev/null
+++ b/tests/manual/widgets/itemviews/autoResizePrecision/tablevert/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from testtable2.pro.
+
+#####################################################################
+## testtable2 Binary:
+#####################################################################
+
+add_qt_manual_test(testtable2
+ GUI
+ SOURCES
+ testtable2.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/widgets/itemviews/autoResizePrecision/treeview/CMakeLists.txt b/tests/manual/widgets/itemviews/autoResizePrecision/treeview/CMakeLists.txt
new file mode 100644
index 0000000000..33073d3a42
--- /dev/null
+++ b/tests/manual/widgets/itemviews/autoResizePrecision/treeview/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from testtree.pro.
+
+#####################################################################
+## testtree Binary:
+#####################################################################
+
+add_qt_manual_test(testtree
+ GUI
+ SOURCES
+ testtree.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/widgets/itemviews/delegate/CMakeLists.txt b/tests/manual/widgets/itemviews/delegate/CMakeLists.txt
new file mode 100644
index 0000000000..533cf4913e
--- /dev/null
+++ b/tests/manual/widgets/itemviews/delegate/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from delegate.pro.
+
+#####################################################################
+## delegate Binary:
+#####################################################################
+
+add_qt_manual_test(delegate
+ GUI
+ SOURCES
+ example.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:delegate.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/itemviews/qconcatenatetablesproxymodel/CMakeLists.txt b/tests/manual/widgets/itemviews/qconcatenatetablesproxymodel/CMakeLists.txt
new file mode 100644
index 0000000000..21c7ed431e
--- /dev/null
+++ b/tests/manual/widgets/itemviews/qconcatenatetablesproxymodel/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qconcatenatetablesproxymodel.pro.
+
+#####################################################################
+## qconcatenatetablesproxymodel Binary:
+#####################################################################
+
+add_qt_manual_test(qconcatenatetablesproxymodel
+ GUI
+ SOURCES
+ main.cpp
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qconcatenatetablesproxymodel.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/itemviews/qheaderview/CMakeLists.txt b/tests/manual/widgets/itemviews/qheaderview/CMakeLists.txt
new file mode 100644
index 0000000000..eeb9913126
--- /dev/null
+++ b/tests/manual/widgets/itemviews/qheaderview/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qheaderview.pro.
+
+#####################################################################
+## qheaderview Binary:
+#####################################################################
+
+add_qt_manual_test(qheaderview
+ GUI
+ SOURCES
+ qheaderviewtest1.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qheaderview.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/itemviews/qtreeview/CMakeLists.txt b/tests/manual/widgets/itemviews/qtreeview/CMakeLists.txt
new file mode 100644
index 0000000000..ff69f09cf0
--- /dev/null
+++ b/tests/manual/widgets/itemviews/qtreeview/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qtreeview.pro.
+
+#####################################################################
+## qtreeview Binary:
+#####################################################################
+
+add_qt_manual_test(qtreeview
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qtreeview.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/itemviews/qtreewidget/CMakeLists.txt b/tests/manual/widgets/itemviews/qtreewidget/CMakeLists.txt
new file mode 100644
index 0000000000..c9e100714a
--- /dev/null
+++ b/tests/manual/widgets/itemviews/qtreewidget/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qtreewidget.pro.
+
+#####################################################################
+## qtreewidget Binary:
+#####################################################################
+
+add_qt_manual_test(qtreewidget
+ GUI
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qtreewidget.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/itemviews/tableview-span-navigation/CMakeLists.txt b/tests/manual/widgets/itemviews/tableview-span-navigation/CMakeLists.txt
new file mode 100644
index 0000000000..f9efb5373d
--- /dev/null
+++ b/tests/manual/widgets/itemviews/tableview-span-navigation/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from tableview-span-navigation.pro.
+
+#####################################################################
+## tableview-span-navigation Binary:
+#####################################################################
+
+add_qt_manual_test(tableview-span-navigation
+ GUI
+ SOURCES
+ main.cpp
+ INCLUDE_DIRECTORIES
+ .
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:tableview-span-navigation.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/kernel/CMakeLists.txt b/tests/manual/widgets/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..0c03aec319
--- /dev/null
+++ b/tests/manual/widgets/kernel/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from kernel.pro.
+
+add_subdirectory(qtooltip)
+add_subdirectory(sizeonhide)
+add_subdirectory(layoutreplace)
diff --git a/tests/manual/widgets/kernel/layoutreplace/CMakeLists.txt b/tests/manual/widgets/kernel/layoutreplace/CMakeLists.txt
new file mode 100644
index 0000000000..04b36ee4e3
--- /dev/null
+++ b/tests/manual/widgets/kernel/layoutreplace/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from layoutreplace.pro.
+
+#####################################################################
+## layoutreplace Binary:
+#####################################################################
+
+add_qt_manual_test(layoutreplace
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/widgets/kernel/qtooltip/CMakeLists.txt b/tests/manual/widgets/kernel/qtooltip/CMakeLists.txt
new file mode 100644
index 0000000000..2b30e5eeec
--- /dev/null
+++ b/tests/manual/widgets/kernel/qtooltip/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qtooltip.pro.
+
+#####################################################################
+## qtooltip Binary:
+#####################################################################
+
+add_qt_manual_test(qtooltip
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Test
+ Qt::Widgets
+)
diff --git a/tests/manual/widgets/kernel/sizeonhide/CMakeLists.txt b/tests/manual/widgets/kernel/sizeonhide/CMakeLists.txt
new file mode 100644
index 0000000000..046153464b
--- /dev/null
+++ b/tests/manual/widgets/kernel/sizeonhide/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from sizeonhide.pro.
+
+#####################################################################
+## sizeonhide Binary:
+#####################################################################
+
+add_qt_manual_test(sizeonhide
+ GUI
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:sizeonhide.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/qgraphicsview/CMakeLists.txt b/tests/manual/widgets/qgraphicsview/CMakeLists.txt
new file mode 100644
index 0000000000..5fd7e47ccd
--- /dev/null
+++ b/tests/manual/widgets/qgraphicsview/CMakeLists.txt
@@ -0,0 +1,3 @@
+# Generated from qgraphicsview.pro.
+
+add_subdirectory(rubberband)
diff --git a/tests/manual/widgets/qgraphicsview/rubberband/CMakeLists.txt b/tests/manual/widgets/qgraphicsview/rubberband/CMakeLists.txt
new file mode 100644
index 0000000000..726404679e
--- /dev/null
+++ b/tests/manual/widgets/qgraphicsview/rubberband/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from rubberband.pro.
+
+#####################################################################
+## rubberband Binary:
+#####################################################################
+
+add_qt_manual_test(rubberband
+ GUI
+ SOURCES
+ rubberbandtest.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:rubberband.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/styles/CMakeLists.txt b/tests/manual/widgets/styles/CMakeLists.txt
new file mode 100644
index 0000000000..26fa8317cc
--- /dev/null
+++ b/tests/manual/widgets/styles/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from styles.pro.
+
+#####################################################################
+## tst_manual_styles Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_styles
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:styles.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/widgets/CMakeLists.txt b/tests/manual/widgets/widgets/CMakeLists.txt
new file mode 100644
index 0000000000..d760abdd59
--- /dev/null
+++ b/tests/manual/widgets/widgets/CMakeLists.txt
@@ -0,0 +1,6 @@
+# Generated from widgets.pro.
+
+add_subdirectory(bigmenucreator)
+add_subdirectory(defaultUpMenuBar)
+add_subdirectory(multiscreen-menus)
+add_subdirectory(qtoolbutton/menuOnMultiScreens)
diff --git a/tests/manual/widgets/widgets/bigmenucreator/CMakeLists.txt b/tests/manual/widgets/widgets/bigmenucreator/CMakeLists.txt
new file mode 100644
index 0000000000..f0161997c0
--- /dev/null
+++ b/tests/manual/widgets/widgets/bigmenucreator/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from bigmenucreator.pro.
+
+#####################################################################
+## BigMenuCreator Binary:
+#####################################################################
+
+add_qt_manual_test(BigMenuCreator
+ GUI
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ DEFINES
+ QT_DEPRECATED_WARNINGS
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+#### Keys ignored in scope 1:.:.:bigmenucreator.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/widgets/defaultUpMenuBar/CMakeLists.txt b/tests/manual/widgets/widgets/defaultUpMenuBar/CMakeLists.txt
new file mode 100644
index 0000000000..8d86672327
--- /dev/null
+++ b/tests/manual/widgets/widgets/defaultUpMenuBar/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from defaultUpMenuBar.pro.
+
+#####################################################################
+## defaultUpMenuBar Binary:
+#####################################################################
+
+add_qt_manual_test(defaultUpMenuBar
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:defaultUpMenuBar.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/widgets/multiscreen-menus/CMakeLists.txt b/tests/manual/widgets/widgets/multiscreen-menus/CMakeLists.txt
new file mode 100644
index 0000000000..b750431d58
--- /dev/null
+++ b/tests/manual/widgets/widgets/multiscreen-menus/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from multiscreen-menus.pro.
+
+#####################################################################
+## multiscreen-menus Binary:
+#####################################################################
+
+add_qt_manual_test(multiscreen-menus
+ GUI
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
+
+#### Keys ignored in scope 1:.:.:multiscreen-menus.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/widgets/qmainwindow/saveStateSize/CMakeLists.txt b/tests/manual/widgets/widgets/qmainwindow/saveStateSize/CMakeLists.txt
new file mode 100644
index 0000000000..461b595a68
--- /dev/null
+++ b/tests/manual/widgets/widgets/qmainwindow/saveStateSize/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from saveStateSize.pro.
+
+#####################################################################
+## saveStateSize Binary:
+#####################################################################
+
+add_qt_manual_test(saveStateSize
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:saveStateSize.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/widgets/widgets/qtoolbutton/menuOnMultiScreens/CMakeLists.txt b/tests/manual/widgets/widgets/qtoolbutton/menuOnMultiScreens/CMakeLists.txt
new file mode 100644
index 0000000000..f49d630de7
--- /dev/null
+++ b/tests/manual/widgets/widgets/qtoolbutton/menuOnMultiScreens/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from menuOnMultiScreens.pro.
+
+#####################################################################
+## menuOnMultiScreens Binary:
+#####################################################################
+
+add_qt_manual_test(menuOnMultiScreens
+ GUI
+ SOURCES
+ main.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:menuOnMultiScreens.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/windowchildgeometry/CMakeLists.txt b/tests/manual/windowchildgeometry/CMakeLists.txt
new file mode 100644
index 0000000000..e6f7c232a3
--- /dev/null
+++ b/tests/manual/windowchildgeometry/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from windowchildgeometry.pro.
+
+#####################################################################
+## windowchildgeometry Binary:
+#####################################################################
+
+add_qt_manual_test(windowchildgeometry
+ GUI
+ SOURCES
+ ../windowflags/controls.cpp ../windowflags/controls.h
+ controllerwidget.cpp controllerwidget.h
+ main.cpp
+ DEFINES
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ INCLUDE_DIRECTORIES
+ ../windowflags
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:windowchildgeometry.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/windowflags/CMakeLists.txt b/tests/manual/windowflags/CMakeLists.txt
new file mode 100644
index 0000000000..1aba06d9a1
--- /dev/null
+++ b/tests/manual/windowflags/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from windowflags.pro.
+
+#####################################################################
+## tst_manual_windowflags Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_windowflags
+ GUI
+ SOURCES
+ controllerwindow.cpp controllerwindow.h
+ controls.cpp controls.h
+ main.cpp
+ previewwindow.cpp previewwindow.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/windowgeometry/CMakeLists.txt b/tests/manual/windowgeometry/CMakeLists.txt
new file mode 100644
index 0000000000..adeae599fc
--- /dev/null
+++ b/tests/manual/windowgeometry/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from windowgeometry.pro.
+
+#####################################################################
+## windowgeometry Binary:
+#####################################################################
+
+add_qt_manual_test(windowgeometry
+ GUI
+ SOURCES
+ ../windowflags/controls.cpp ../windowflags/controls.h
+ controllerwidget.cpp controllerwidget.h
+ main.cpp
+ INCLUDE_DIRECTORIES
+ ../windowflags
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:windowgeometry.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/windowmodality/CMakeLists.txt b/tests/manual/windowmodality/CMakeLists.txt
new file mode 100644
index 0000000000..67e6071add
--- /dev/null
+++ b/tests/manual/windowmodality/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from windowmodality.pro.
+
+#####################################################################
+## windowmodality Binary:
+#####################################################################
+
+add_qt_manual_test(windowmodality
+ GUI
+ SOURCES
+ dialog.ui
+ main.cpp
+ widget.ui
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::PrintSupport
+ Qt::Widgets
+ ENABLE_AUTOGEN_TOOLS
+ uic
+)
diff --git a/tests/manual/windowtransparency/CMakeLists.txt b/tests/manual/windowtransparency/CMakeLists.txt
new file mode 100644
index 0000000000..42de6d67c6
--- /dev/null
+++ b/tests/manual/windowtransparency/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from windowtransparency.pro.
+
+#####################################################################
+## windowtransparency Binary:
+#####################################################################
+
+add_qt_manual_test(windowtransparency
+ SOURCES
+ windowtransparency.cpp
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
diff --git a/tests/manual/xcb_gl_integration/CMakeLists.txt b/tests/manual/xcb_gl_integration/CMakeLists.txt
new file mode 100644
index 0000000000..ac532a7c61
--- /dev/null
+++ b/tests/manual/xcb_gl_integration/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from xcb_gl_integration.pro.
+
+#####################################################################
+## xcb_gl_integration Binary:
+#####################################################################
+
+add_qt_manual_test(xcb_gl_integration
+ GUI
+ SOURCES
+ main.cpp
+ INCLUDE_DIRECTORIES
+ .
+ LIBRARIES
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:xcb_gl_integration.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/xembed-raster/CMakeLists.txt b/tests/manual/xembed-raster/CMakeLists.txt
new file mode 100644
index 0000000000..6c8996e9c1
--- /dev/null
+++ b/tests/manual/xembed-raster/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from xembed-raster.pro.
+
+#####################################################################
+## tst_manual_rasterwindow Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_rasterwindow
+ GUI
+ SOURCES
+ main.cpp
+ rasterwindow.cpp rasterwindow.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:.:xembed-raster.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/tests/manual/xembed-widgets/CMakeLists.txt b/tests/manual/xembed-widgets/CMakeLists.txt
new file mode 100644
index 0000000000..ed8c5355a9
--- /dev/null
+++ b/tests/manual/xembed-widgets/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from xembed-widgets.pro.
+
+#####################################################################
+## tst_manual_lineedits Binary:
+#####################################################################
+
+add_qt_manual_test(tst_manual_lineedits
+ GUI
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ PUBLIC_LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:xembed-widgets.pro:<TRUE>:
+# TEMPLATE = "app"
diff --git a/util/cmake/Makefile b/util/cmake/Makefile
new file mode 100644
index 0000000000..2243ad111e
--- /dev/null
+++ b/util/cmake/Makefile
@@ -0,0 +1,20 @@
+
+test: flake8 mypy pytest black_format_check
+
+coverage:
+ pytest --cov .
+
+format:
+ black *.py --line-length 100
+
+black_format_check:
+ black *.py --line-length 100 --check
+
+flake8:
+ flake8 *.py --ignore=E501,E266,E203,W503
+
+pytest:
+ pytest
+
+mypy:
+ mypy --pretty *.py
diff --git a/util/cmake/Pipfile b/util/cmake/Pipfile
new file mode 100644
index 0000000000..21c18f4743
--- /dev/null
+++ b/util/cmake/Pipfile
@@ -0,0 +1,18 @@
+[[source]]
+url = "https://pypi.org/simple"
+verify_ssl = true
+name = "pypi"
+
+[packages]
+pyparsing = "*"
+sympy = "*"
+mypy = "*"
+pytest = "*"
+pytest-cov = "*"
+flake8 = "*"
+portalocker = "*"
+
+[dev-packages]
+
+[requires]
+python_version = "3.7"
diff --git a/util/cmake/README.md b/util/cmake/README.md
new file mode 100644
index 0000000000..e1699d5283
--- /dev/null
+++ b/util/cmake/README.md
@@ -0,0 +1,54 @@
+# CMake Utils
+
+This directory holds scripts to help the porting process from `qmake` to `cmake` for Qt6.
+
+# Requirements
+
+* [Python 3.7](https://www.python.org/downloads/),
+* `pipenv` or `pip` to manage the modules.
+
+## Python modules
+
+Since Python has many ways of handling projects, you have a couple of options to
+install the dependencies of the scripts:
+
+### Using `pipenv`
+
+The dependencies are specified on the `Pipfile`, so you just need to run
+`pipenv install` and that will automatically create a virtual environment
+that you can activate with a `pipenv shell`.
+
+### Using `pip`
+
+It's highly recommended to use a [virtualenvironment](https://virtualenv.pypa.io/en/latest/)
+to avoid conflict with other packages that are already installed: `pip install virtualenv`.
+
+* Create an environment: `virtualenv env`,
+* Activate the environment: `source env/bin/activate`
+ (on Windows: `source env\Scripts\activate.bat`)
+* Install the requirements: `pip install -r requirements.txt`
+
+# Contributing to the scripts
+
+You can verify if the styling of a script complaint with PEP8, with a couple of exceptions:
+
+Install [flake8](http://flake8.pycqa.org/en/latest/) (`pip install flake8`) and run it
+on the script you want to test:
+
+```
+flake8 <file>.py --ignore=E501,E266,W503
+```
+
+* `E501`: Line too long (82>79 characters),
+* `E266`: Too many leading '#' for block comment,
+* `W503`: Line break occurred before a binary operator)
+
+You can also modify the file with an automatic formatter,
+like [black](https://black.readthedocs.io/en/stable/) (`pip install black`),
+and execute it:
+
+```
+black -l 100 <file>.py
+```
+
+Using Qt's maximum line length, 100.
diff --git a/util/cmake/cmakeconversionrate.py b/util/cmake/cmakeconversionrate.py
new file mode 100755
index 0000000000..b87957df6c
--- /dev/null
+++ b/util/cmake/cmakeconversionrate.py
@@ -0,0 +1,141 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2018 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+from argparse import ArgumentParser
+
+import os
+import re
+import subprocess
+import typing
+
+
+def _parse_commandline():
+ parser = ArgumentParser(description="Calculate the conversion rate to cmake.")
+ parser.add_argument("--debug", dest="debug", action="store_true", help="Turn on debug output")
+ parser.add_argument(
+ "source_directory",
+ metavar="<Source Directory>",
+ type=str,
+ help="The Qt module source directory",
+ )
+ parser.add_argument(
+ "binary_directory",
+ metavar="<CMake build direcotry>",
+ type=str,
+ help="The CMake build directory (might be empty)",
+ )
+
+ return parser.parse_args()
+
+
+def calculate_baseline(source_directory: str, *, debug: bool = False) -> int:
+ if debug:
+ print(f'Scanning "{source_directory}" for qmake-based tests.')
+ result = subprocess.run(
+ '/usr/bin/git grep -E "^\\s*CONFIG\\s*\\+?=.*\\btestcase\\b" | sort -u | wc -l',
+ shell=True,
+ capture_output=True,
+ cwd=source_directory,
+ )
+ return int(result.stdout)
+
+
+def build(source_directory: str, binary_directory: str, *, debug=False) -> None:
+ abs_source = os.path.abspath(source_directory)
+ if not os.path.isdir(binary_directory):
+ os.makedirs(binary_directory)
+ if not os.path.exists(os.path.join(binary_directory, "CMakeCache.txt")):
+
+ if debug:
+ print(f'Running cmake in "{binary_directory}"')
+ result = subprocess.run(["/usr/bin/cmake", "-GNinja", abs_source], cwd=binary_directory)
+ if debug:
+ print(f"CMake return code: {result.returncode}.")
+
+ assert result.returncode == 0
+
+ if debug:
+ print(f'Running ninja in "{binary_directory}".')
+ result = subprocess.run("/usr/bin/ninja", cwd=binary_directory)
+ if debug:
+ print(f"Ninja return code: {result.returncode}.")
+
+ assert result.returncode == 0
+
+
+def test(binary_directory: str, *, debug=False) -> typing.Tuple[int, int]:
+ if debug:
+ print(f'Running ctest in "{binary_directory}".')
+ result = subprocess.run(
+ '/usr/bin/ctest -j 250 | grep "tests passed, "',
+ shell=True,
+ capture_output=True,
+ cwd=binary_directory,
+ )
+ summary = result.stdout.decode("utf-8").replace("\n", "")
+ if debug:
+ print(f"Test summary: {summary} ({result.returncode}).")
+
+ matches = re.fullmatch(r"\d+% tests passed, (\d+) tests failed out of (\d+)", summary)
+ if matches:
+ if debug:
+ print(f"Matches: failed {matches.group(1)}, total {matches.group(2)}.")
+ return (int(matches.group(2)), int(matches.group(2)) - int(matches.group(1)))
+
+ return (0, 0)
+
+
+def main() -> int:
+ args = _parse_commandline()
+
+ base_line = calculate_baseline(args.source_directory, debug=args.debug)
+ if base_line <= 0:
+ print(f"Could not find the qmake baseline in {args.source_directory}.")
+ return 1
+
+ if args.debug:
+ print(f"qmake baseline: {base_line} test binaries.")
+
+ cmake_total = 0
+ cmake_success = 0
+ try:
+ build(args.source_directory, args.binary_directory, debug=args.debug)
+ (cmake_total, cmake_success) = test(args.binary_directory, debug=args.debug)
+ finally:
+ if cmake_total == 0:
+ print("\n\n\nCould not calculate the cmake state.")
+ return 2
+ else:
+ print(f"\n\n\nCMake test conversion rate: {cmake_total/base_line:.2f}.")
+ print(f"CMake test success rate : {cmake_success/base_line:.2f}.")
+ return 0
+
+
+if __name__ == "__main__":
+ main()
diff --git a/util/cmake/condition_simplifier.py b/util/cmake/condition_simplifier.py
new file mode 100644
index 0000000000..d02e70e489
--- /dev/null
+++ b/util/cmake/condition_simplifier.py
@@ -0,0 +1,237 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2019 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+
+import re
+from sympy import simplify_logic, And, Or, Not, SympifyError # type: ignore
+from condition_simplifier_cache import simplify_condition_memoize
+
+
+def _iterate_expr_tree(expr, op, matches):
+ assert expr.func == op
+ keepers = ()
+ for arg in expr.args:
+ if arg in matches:
+ matches = tuple(x for x in matches if x != arg)
+ elif arg == op:
+ (matches, extra_keepers) = _iterate_expr_tree(arg, op, matches)
+ keepers = (*keepers, *extra_keepers)
+ else:
+ keepers = (*keepers, arg)
+ return matches, keepers
+
+
+def _simplify_expressions(expr, op, matches, replacement):
+ for arg in expr.args:
+ expr = expr.subs(arg, _simplify_expressions(arg, op, matches, replacement))
+
+ if expr.func == op:
+ (to_match, keepers) = tuple(_iterate_expr_tree(expr, op, matches))
+ if len(to_match) == 0:
+ # build expression with keepers and replacement:
+ if keepers:
+ start = replacement
+ current_expr = None
+ last_expr = keepers[-1]
+ for repl_arg in keepers[:-1]:
+ current_expr = op(start, repl_arg)
+ start = current_expr
+ top_expr = op(start, last_expr)
+ else:
+ top_expr = replacement
+
+ expr = expr.subs(expr, top_expr)
+
+ return expr
+
+
+def _simplify_flavors_in_condition(base: str, flavors, expr):
+ """ Simplify conditions based on the knowledge of which flavors
+ belong to which OS. """
+ base_expr = simplify_logic(base)
+ false_expr = simplify_logic("false")
+ for flavor in flavors:
+ flavor_expr = simplify_logic(flavor)
+ expr = _simplify_expressions(expr, And, (base_expr, flavor_expr), flavor_expr)
+ expr = _simplify_expressions(expr, Or, (base_expr, flavor_expr), base_expr)
+ expr = _simplify_expressions(expr, And, (Not(base_expr), flavor_expr), false_expr)
+ return expr
+
+
+def _simplify_os_families(expr, family_members, other_family_members):
+ for family in family_members:
+ for other in other_family_members:
+ if other in family_members:
+ continue # skip those in the sub-family
+
+ f_expr = simplify_logic(family)
+ o_expr = simplify_logic(other)
+
+ expr = _simplify_expressions(expr, And, (f_expr, Not(o_expr)), f_expr)
+ expr = _simplify_expressions(expr, And, (Not(f_expr), o_expr), o_expr)
+ expr = _simplify_expressions(expr, And, (f_expr, o_expr), simplify_logic("false"))
+ return expr
+
+
+def _recursive_simplify(expr):
+ """ Simplify the expression as much as possible based on
+ domain knowledge. """
+ input_expr = expr
+
+ # Simplify even further, based on domain knowledge:
+ # windowses = ('WIN32', 'WINRT')
+ apples = ("APPLE_OSX", "APPLE_UIKIT", "APPLE_IOS", "APPLE_TVOS", "APPLE_WATCHOS")
+ bsds = ("FREEBSD", "OPENBSD", "NETBSD")
+ androids = ("ANDROID", "ANDROID_EMBEDDED")
+ unixes = (
+ "APPLE",
+ *apples,
+ "BSD",
+ *bsds,
+ "LINUX",
+ *androids,
+ "HAIKU",
+ "INTEGRITY",
+ "VXWORKS",
+ "QNX",
+ "WASM",
+ )
+
+ unix_expr = simplify_logic("UNIX")
+ win_expr = simplify_logic("WIN32")
+ false_expr = simplify_logic("false")
+ true_expr = simplify_logic("true")
+
+ expr = expr.subs(Not(unix_expr), win_expr) # NOT UNIX -> WIN32
+ expr = expr.subs(Not(win_expr), unix_expr) # NOT WIN32 -> UNIX
+
+ # UNIX [OR foo ]OR WIN32 -> ON [OR foo]
+ expr = _simplify_expressions(expr, Or, (unix_expr, win_expr), true_expr)
+ # UNIX [AND foo ]AND WIN32 -> OFF [AND foo]
+ expr = _simplify_expressions(expr, And, (unix_expr, win_expr), false_expr)
+
+ expr = _simplify_flavors_in_condition("WIN32", ("WINRT",), expr)
+ expr = _simplify_flavors_in_condition("APPLE", apples, expr)
+ expr = _simplify_flavors_in_condition("BSD", bsds, expr)
+ expr = _simplify_flavors_in_condition("UNIX", unixes, expr)
+ expr = _simplify_flavors_in_condition("ANDROID", ("ANDROID_EMBEDDED",), expr)
+
+ # Simplify families of OSes against other families:
+ expr = _simplify_os_families(expr, ("WIN32", "WINRT"), unixes)
+ expr = _simplify_os_families(expr, androids, unixes)
+ expr = _simplify_os_families(expr, ("BSD", *bsds), unixes)
+
+ for family in ("HAIKU", "QNX", "INTEGRITY", "LINUX", "VXWORKS"):
+ expr = _simplify_os_families(expr, (family,), unixes)
+
+ # Now simplify further:
+ expr = simplify_logic(expr)
+
+ while expr != input_expr:
+ input_expr = expr
+ expr = _recursive_simplify(expr)
+
+ return expr
+
+
+@simplify_condition_memoize
+def simplify_condition(condition: str) -> str:
+ input_condition = condition.strip()
+
+ # Map to sympy syntax:
+ condition = " " + input_condition + " "
+ condition = condition.replace("(", " ( ")
+ condition = condition.replace(")", " ) ")
+
+ tmp = ""
+ while tmp != condition:
+ tmp = condition
+
+ condition = condition.replace(" NOT ", " ~ ")
+ condition = condition.replace(" AND ", " & ")
+ condition = condition.replace(" OR ", " | ")
+ condition = condition.replace(" ON ", " true ")
+ condition = condition.replace(" OFF ", " false ")
+ # Replace dashes with a token
+ condition = condition.replace("-", "_dash_")
+
+ # SymPy chokes on expressions that contain two tokens one next to
+ # the other delimited by a space, which are not an operation.
+ # So a CMake condition like "TARGET Foo::Bar" fails the whole
+ # expression simplifying process.
+ # Turn these conditions into a single token so that SymPy can parse
+ # the expression, and thus simplify it.
+ # Do this by replacing and keeping a map of conditions to single
+ # token symbols.
+ # Support both target names without double colons, and with double
+ # colons.
+ pattern = re.compile(r"(TARGET [a-zA-Z]+(?:::[a-zA-Z]+)?)")
+ target_symbol_mapping = {}
+ all_target_conditions = re.findall(pattern, condition)
+ for target_condition in all_target_conditions:
+ # Replace spaces and colons with underscores.
+ target_condition_symbol_name = re.sub("[ :]", "_", target_condition)
+ target_symbol_mapping[target_condition_symbol_name] = target_condition
+ condition = re.sub(target_condition, target_condition_symbol_name, condition)
+
+ # Do similar token mapping for comparison operators.
+ pattern = re.compile(r"([a-zA-Z_0-9]+ (?:STRLESS|STREQUAL|STRGREATER) [a-zA-Z_0-9]+)")
+ comparison_symbol_mapping = {}
+ all_comparisons = re.findall(pattern, condition)
+ for comparison in all_comparisons:
+ # Replace spaces and colons with underscores.
+ comparison_symbol_name = re.sub("[ ]", "_", comparison)
+ comparison_symbol_mapping[comparison_symbol_name] = comparison
+ condition = re.sub(comparison, comparison_symbol_name, condition)
+
+ try:
+ # Generate and simplify condition using sympy:
+ condition_expr = simplify_logic(condition)
+ condition = str(_recursive_simplify(condition_expr))
+
+ # Restore the target conditions.
+ for symbol_name in target_symbol_mapping:
+ condition = re.sub(symbol_name, target_symbol_mapping[symbol_name], condition)
+
+ # Restore comparisons.
+ for comparison in comparison_symbol_mapping:
+ condition = re.sub(comparison, comparison_symbol_mapping[comparison], condition)
+
+ # Map back to CMake syntax:
+ condition = condition.replace("~", "NOT ")
+ condition = condition.replace("&", "AND")
+ condition = condition.replace("|", "OR")
+ condition = condition.replace("True", "ON")
+ condition = condition.replace("False", "OFF")
+ condition = condition.replace("_dash_", "-")
+ except (SympifyError, TypeError, AttributeError):
+ # sympy did not like our input, so leave this condition alone:
+ condition = input_condition
+
+ return condition or "ON"
diff --git a/util/cmake/condition_simplifier_cache.py b/util/cmake/condition_simplifier_cache.py
new file mode 100644
index 0000000000..58cd5b88c5
--- /dev/null
+++ b/util/cmake/condition_simplifier_cache.py
@@ -0,0 +1,183 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2018 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+
+import atexit
+import hashlib
+import json
+import os
+import sys
+import time
+
+from typing import Any, Callable, Dict
+
+condition_simplifier_cache_enabled = True
+
+
+def set_condition_simplified_cache_enabled(value: bool):
+ global condition_simplifier_cache_enabled
+ condition_simplifier_cache_enabled = value
+
+
+def get_current_file_path() -> str:
+ try:
+ this_file = __file__
+ except NameError:
+ this_file = sys.argv[0]
+ this_file = os.path.abspath(this_file)
+ return this_file
+
+
+def get_cache_location() -> str:
+ this_file = get_current_file_path()
+ dir_path = os.path.dirname(this_file)
+ cache_path = os.path.join(dir_path, ".pro2cmake_cache", "cache.json")
+ return cache_path
+
+
+def get_file_checksum(file_path: str) -> str:
+ try:
+ with open(file_path, "r") as content_file:
+ content = content_file.read()
+ except IOError:
+ content = str(time.time())
+ checksum = hashlib.md5(content.encode("utf-8")).hexdigest()
+ return checksum
+
+
+def get_condition_simplifier_checksum() -> str:
+ current_file_path = get_current_file_path()
+ dir_name = os.path.dirname(current_file_path)
+ condition_simplifier_path = os.path.join(dir_name, "condition_simplifier.py")
+ return get_file_checksum(condition_simplifier_path)
+
+
+def init_cache_dict():
+ return {
+ "checksum": get_condition_simplifier_checksum(),
+ "schema_version": "1",
+ "cache": {"conditions": {}},
+ }
+
+
+def merge_dicts_recursive(a: Dict[str, Any], other: Dict[str, Any]) -> Dict[str, Any]:
+ """Merges values of "other" into "a", mutates a."""
+ for key in other:
+ if key in a:
+ if isinstance(a[key], dict) and isinstance(other[key], dict):
+ merge_dicts_recursive(a[key], other[key])
+ elif a[key] == other[key]:
+ pass
+ else:
+ a[key] = other[key]
+ return a
+
+
+def open_file_safe(file_path: str, mode: str = "r+"):
+ # Use portalocker package for file locking if available,
+ # otherwise print a message to install the package.
+ try:
+ import portalocker # type: ignore
+
+ file_open_func = portalocker.Lock
+ file_open_args = [file_path]
+ file_open_kwargs = {"mode": mode, "flags": portalocker.LOCK_EX}
+ file_handle = file_open_func(*file_open_args, **file_open_kwargs)
+ return file_handle
+ except ImportError:
+ print(
+ "The conversion script is missing a required package: portalocker. Please run "
+ "python -m pip install -r requirements.txt to install the missing dependency."
+ )
+ exit(1)
+
+
+def simplify_condition_memoize(f: Callable[[str], str]):
+ cache_path = get_cache_location()
+ cache_file_content: Dict[str, Any] = {}
+
+ if os.path.exists(cache_path):
+ try:
+ with open_file_safe(cache_path, mode="r") as cache_file:
+ cache_file_content = json.load(cache_file)
+ except (IOError, ValueError):
+ print(f"Invalid pro2cmake cache file found at: {cache_path}. Removing it.")
+ os.remove(cache_path)
+
+ if not cache_file_content:
+ cache_file_content = init_cache_dict()
+
+ current_checksum = get_condition_simplifier_checksum()
+ if cache_file_content["checksum"] != current_checksum:
+ cache_file_content = init_cache_dict()
+
+ def update_cache_file():
+ if not os.path.exists(cache_path):
+ os.makedirs(os.path.dirname(cache_path), exist_ok=True)
+ # Create the file if it doesn't exist, but don't override
+ # it.
+ with open(cache_path, "a"):
+ pass
+
+ updated_cache = cache_file_content
+
+ with open_file_safe(cache_path, "r+") as cache_file_write_handle:
+ # Read any existing cache content, and truncate the file.
+ cache_file_existing_content = cache_file_write_handle.read()
+ cache_file_write_handle.seek(0)
+ cache_file_write_handle.truncate()
+
+ # Merge the new cache into the old cache if it exists.
+ if cache_file_existing_content:
+ possible_cache = json.loads(cache_file_existing_content)
+ if (
+ "checksum" in possible_cache
+ and "schema_version" in possible_cache
+ and possible_cache["checksum"] == cache_file_content["checksum"]
+ and possible_cache["schema_version"] == cache_file_content["schema_version"]
+ ):
+ updated_cache = merge_dicts_recursive(dict(possible_cache), updated_cache)
+
+ json.dump(updated_cache, cache_file_write_handle, indent=4)
+
+ # Flush any buffered writes.
+ cache_file_write_handle.flush()
+ os.fsync(cache_file_write_handle.fileno())
+
+ atexit.register(update_cache_file)
+
+ def helper(condition: str) -> str:
+ if (
+ condition not in cache_file_content["cache"]["conditions"]
+ or not condition_simplifier_cache_enabled
+ ):
+ cache_file_content["cache"]["conditions"][condition] = f(condition)
+ return cache_file_content["cache"]["conditions"][condition]
+
+ return helper
diff --git a/util/cmake/configurejson2cmake.py b/util/cmake/configurejson2cmake.py
new file mode 100755
index 0000000000..9f93ecafa6
--- /dev/null
+++ b/util/cmake/configurejson2cmake.py
@@ -0,0 +1,1105 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2018 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+import json_parser
+import posixpath
+import re
+import sys
+from typing import Optional, Set
+from textwrap import dedent
+
+from helper import (
+ map_qt_library,
+ featureName,
+ map_platform,
+ find_3rd_party_library_mapping,
+ generate_find_package_info,
+)
+
+knownTests = set() # type: Set[str]
+
+
+class LibraryMapping:
+ def __init__(self, package: str, resultVariable: str, appendFoundSuffix: bool = True) -> None:
+ self.package = package
+ self.resultVariable = resultVariable
+ self.appendFoundSuffix = appendFoundSuffix
+
+
+def map_tests(test: str) -> Optional[str]:
+ testmap = {
+ "c99": "c_std_99 IN_LIST CMAKE_C_COMPILE_FEATURES",
+ "c11": "c_std_11 IN_LIST CMAKE_C_COMPILE_FEATURES",
+ "x86SimdAlways": "ON", # FIXME: Make this actually do a compile test.
+ "aesni": "TEST_subarch_aes",
+ "avx": "TEST_subarch_avx",
+ "avx2": "TEST_subarch_avx2",
+ "avx512f": "TEST_subarch_avx512f",
+ "avx512cd": "TEST_subarch_avx512cd",
+ "avx512dq": "TEST_subarch_avx512dq",
+ "avx512bw": "TEST_subarch_avx512bw",
+ "avx512er": "TEST_subarch_avx512er",
+ "avx512pf": "TEST_subarch_avx512pf",
+ "avx512vl": "TEST_subarch_avx512vl",
+ "avx512ifma": "TEST_subarch_avx512ifma",
+ "avx512vbmi": "TEST_subarch_avx512vbmi",
+ "avx512vbmi2": "TEST_subarch_avx512vbmi2",
+ "avx512vpopcntdq": "TEST_subarch_avx512vpopcntdq",
+ "avx5124fmaps": "TEST_subarch_avx5124fmaps",
+ "avx5124vnniw": "TEST_subarch_avx5124vnniw",
+ "bmi": "TEST_subarch_bmi",
+ "bmi2": "TEST_subarch_bmi2",
+ "cx16": "TEST_subarch_cx16",
+ "f16c": "TEST_subarch_f16c",
+ "fma": "TEST_subarch_fma",
+ "fma4": "TEST_subarch_fma4",
+ "fsgsbase": "TEST_subarch_fsgsbase",
+ "gfni": "TEST_subarch_gfni",
+ "ibt": "TEST_subarch_ibt",
+ "libclang": "TEST_libclang",
+ "lwp": "TEST_subarch_lwp",
+ "lzcnt": "TEST_subarch_lzcnt",
+ "mmx": "TEST_subarch_mmx",
+ "movbe": "TEST_subarch_movbe",
+ "mpx": "TEST_subarch_mpx",
+ "no-sahf": "TEST_subarch_no_shaf",
+ "pclmul": "TEST_subarch_pclmul",
+ "popcnt": "TEST_subarch_popcnt",
+ "prefetchwt1": "TEST_subarch_prefetchwt1",
+ "prfchw": "TEST_subarch_prfchw",
+ "pdpid": "TEST_subarch_rdpid",
+ "rdpid": "TEST_subarch_rdpid",
+ "rdseed": "TEST_subarch_rdseed",
+ "rdrnd": "TEST_subarch_rdseed", # FIXME: Is this the right thing?
+ "rtm": "TEST_subarch_rtm",
+ "shani": "TEST_subarch_sha",
+ "shstk": "TEST_subarch_shstk",
+ "sse2": "TEST_subarch_sse2",
+ "sse3": "TEST_subarch_sse3",
+ "ssse3": "TEST_subarch_ssse3",
+ "sse4a": "TEST_subarch_sse4a",
+ "sse4_1": "TEST_subarch_sse4_1",
+ "sse4_2": "TEST_subarch_sse4_2",
+ "tbm": "TEST_subarch_tbm",
+ "xop": "TEST_subarch_xop",
+ "neon": "TEST_subarch_neon",
+ "iwmmxt": "TEST_subarch_iwmmxt",
+ "crc32": "TEST_subarch_crc32",
+ "vis": "TEST_subarch_vis",
+ "vis2": "TEST_subarch_vis2",
+ "vis3": "TEST_subarch_vis3",
+ "dsp": "TEST_subarch_dsp",
+ "dspr2": "TEST_subarch_dspr2",
+ "altivec": "TEST_subarch_altivec",
+ "spe": "TEST_subarch_spe",
+ "vsx": "TEST_subarch_vsx",
+ "posix-iconv": "TEST_posix_iconv",
+ "sun-iconv": "TEST_sun_iconv",
+ "openssl11": '(OPENSSL_VERSION VERSION_GREATER_EQUAL "1.1.0")',
+ "reduce_exports": "CMAKE_CXX_COMPILE_OPTIONS_VISIBILITY",
+ "libinput_axis_api": "ON",
+ "xlib": "X11_FOUND",
+ "wayland-scanner": "WaylandScanner_FOUND",
+ }
+ if test in testmap:
+ return testmap.get(test, None)
+ if test in knownTests:
+ return f"TEST_{featureName(test)}"
+ return None
+
+
+def cm(ctx, *output):
+ txt = ctx["output"]
+ if txt != "" and not txt.endswith("\n"):
+ txt += "\n"
+ txt += "\n".join(output)
+
+ ctx["output"] = txt
+ return ctx
+
+
+def readJsonFromDir(path: str) -> str:
+ path = posixpath.join(path, "configure.json")
+
+ print(f"Reading {path}...")
+ assert posixpath.exists(path)
+
+ parser = json_parser.QMakeSpecificJSONParser()
+ return parser.parse(path)
+
+
+def processFiles(ctx, data):
+ print(" files:")
+ if "files" in data:
+ for (k, v) in data["files"].items():
+ ctx[k] = v
+ return ctx
+
+
+def parseLib(ctx, lib, data, cm_fh, cmake_find_packages_set):
+ newlib = find_3rd_party_library_mapping(lib)
+ if not newlib:
+ print(f' XXXX Unknown library "{lib}".')
+ return
+
+ if newlib.packageName is None:
+ print(f' **** Skipping library "{lib}" -- was masked.')
+ return
+
+ print(f" mapped library {lib} to {newlib.targetName}.")
+
+ # Avoid duplicate find_package calls.
+ if newlib.targetName in cmake_find_packages_set:
+ return
+
+ # If certain libraries are used within a feature, but the feature
+ # is only emitted conditionally with a simple condition (like
+ # 'on Windows' or 'on Linux'), we should enclose the find_package
+ # call for the library into the same condition.
+ emit_if = newlib.emit_if
+
+ # Only look through features if a custom emit_if wasn't provided.
+ if not emit_if:
+ for feature in data["features"]:
+ feature_data = data["features"][feature]
+ if (
+ "condition" in feature_data
+ and f"libs.{lib}" in feature_data["condition"]
+ and "emitIf" in feature_data
+ and "config." in feature_data["emitIf"]
+ ):
+ emit_if = feature_data["emitIf"]
+ break
+
+ if emit_if:
+ emit_if = map_condition(emit_if)
+
+ cmake_find_packages_set.add(newlib.targetName)
+
+ cm_fh.write(generate_find_package_info(newlib, emit_if=emit_if))
+
+
+def lineify(label, value, quote=True):
+ if value:
+ if quote:
+ escaped_value = value.replace('"', '\\"')
+ return f' {label} "{escaped_value}"\n'
+ return f" {label} {value}\n"
+ return ""
+
+
+def map_condition(condition):
+ # Handle NOT:
+ if isinstance(condition, list):
+ condition = "(" + ") AND (".join(condition) + ")"
+ if isinstance(condition, bool):
+ if condition:
+ return "ON"
+ else:
+ return "OFF"
+ assert isinstance(condition, str)
+
+ mapped_features = {
+ "gbm": "gbm_FOUND",
+ "system-xcb": "ON",
+ "system-freetype": "ON",
+ "system-pcre2": "ON",
+ }
+
+ # Turn foo != "bar" into (NOT foo STREQUAL 'bar')
+ condition = re.sub(r"(.+)\s*!=\s*('.+')", "(! \\1 == \\2)", condition)
+
+ condition = condition.replace("!", "NOT ")
+ condition = condition.replace("&&", " AND ")
+ condition = condition.replace("||", " OR ")
+ condition = condition.replace("==", " STREQUAL ")
+
+ # explicitly handle input.sdk == '':
+ condition = re.sub(r"input\.sdk\s*==\s*''", "NOT INPUT_SDK", condition)
+
+ last_pos = 0
+ mapped_condition = ""
+ has_failed = False
+ for match in re.finditer(r"([a-zA-Z0-9_]+)\.([a-zA-Z0-9_+-]+)", condition):
+ substitution = None
+ # appendFoundSuffix = True
+ if match.group(1) == "libs":
+ libmapping = find_3rd_party_library_mapping(match.group(2))
+
+ if libmapping and libmapping.packageName:
+ substitution = libmapping.packageName
+ if libmapping.resultVariable:
+ substitution = libmapping.resultVariable
+ if libmapping.appendFoundSuffix:
+ substitution += "_FOUND"
+
+ elif match.group(1) == "features":
+ feature = match.group(2)
+ if feature in mapped_features:
+ substitution = mapped_features.get(feature)
+ else:
+ substitution = f"QT_FEATURE_{featureName(match.group(2))}"
+
+ elif match.group(1) == "subarch":
+ substitution = f"TEST_arch_{'${TEST_architecture_arch}'}_subarch_{match.group(2)}"
+
+ elif match.group(1) == "call":
+ if match.group(2) == "crossCompile":
+ substitution = "CMAKE_CROSSCOMPILING"
+
+ elif match.group(1) == "tests":
+ substitution = map_tests(match.group(2))
+
+ elif match.group(1) == "input":
+ substitution = f"INPUT_{featureName(match.group(2))}"
+
+ elif match.group(1) == "config":
+ substitution = map_platform(match.group(2))
+ elif match.group(1) == "module":
+ substitution = f"TARGET {map_qt_library(match.group(2))}"
+
+ elif match.group(1) == "arch":
+ if match.group(2) == "i386":
+ # FIXME: Does this make sense?
+ substitution = "(TEST_architecture_arch STREQUAL i386)"
+ elif match.group(2) == "x86_64":
+ substitution = "(TEST_architecture_arch STREQUAL x86_64)"
+ elif match.group(2) == "arm":
+ # FIXME: Does this make sense?
+ substitution = "(TEST_architecture_arch STREQUAL arm)"
+ elif match.group(2) == "arm64":
+ # FIXME: Does this make sense?
+ substitution = "(TEST_architecture_arch STREQUAL arm64)"
+ elif match.group(2) == "mips":
+ # FIXME: Does this make sense?
+ substitution = "(TEST_architecture_arch STREQUAL mips)"
+
+ if substitution is None:
+ print(f' XXXX Unknown condition "{match.group(0)}"')
+ has_failed = True
+ else:
+ mapped_condition += condition[last_pos : match.start(1)] + substitution
+ last_pos = match.end(2)
+
+ mapped_condition += condition[last_pos:]
+
+ # Space out '(' and ')':
+ mapped_condition = mapped_condition.replace("(", " ( ")
+ mapped_condition = mapped_condition.replace(")", " ) ")
+
+ # Prettify:
+ condition = re.sub("\\s+", " ", mapped_condition)
+ condition = condition.strip()
+
+ # Special case for WrapLibClang in qttools
+ condition = condition.replace("TEST_libclang.has_clangcpp", "TEST_libclang")
+
+ if has_failed:
+ condition += " OR FIXME"
+
+ return condition
+
+
+def parseInput(ctx, sinput, data, cm_fh):
+ skip_inputs = {
+ "prefix",
+ "hostprefix",
+ "extprefix",
+ "archdatadir",
+ "bindir",
+ "datadir",
+ "docdir",
+ "examplesdir",
+ "external-hostbindir",
+ "headerdir",
+ "hostbindir",
+ "hostdatadir",
+ "hostlibdir",
+ "importdir",
+ "libdir",
+ "libexecdir",
+ "plugindir",
+ "qmldir",
+ "settingsdir",
+ "sysconfdir",
+ "testsdir",
+ "translationdir",
+ "android-arch",
+ "android-ndk",
+ "android-ndk-host",
+ "android-ndk-platform",
+ "android-sdk",
+ "android-toolchain-version",
+ "android-style-assets",
+ "appstore-compliant",
+ "avx",
+ "avx2",
+ "avx512",
+ "c++std",
+ "ccache",
+ "commercial",
+ "compile-examples",
+ "confirm-license",
+ "dbus",
+ "dbus-runtime",
+ "debug",
+ "debug-and-release",
+ "developer-build",
+ "device",
+ "device-option",
+ "f16c",
+ "force-asserts",
+ "force-debug-info",
+ "force-pkg-config",
+ "framework",
+ "gc-binaries",
+ "gdb-index",
+ "gcc-sysroot",
+ "gcov",
+ "gnumake",
+ "gui",
+ "harfbuzz",
+ "headersclean",
+ "incredibuild-xge",
+ "libudev",
+ "ltcg",
+ "make",
+ "make-tool",
+ "mips_dsp",
+ "mips_dspr2",
+ "mp",
+ "nomake",
+ "opensource",
+ "optimize-debug",
+ "optimize-size",
+ "optimized-qmake",
+ "optimized-tools",
+ "pch",
+ "pkg-config",
+ "platform",
+ "plugin-manifests",
+ "profile",
+ "qreal",
+ "reduce-exports",
+ "reduce-relocations",
+ "release",
+ "rpath",
+ "sanitize",
+ "sdk",
+ "separate-debug-info",
+ "shared",
+ "silent",
+ "qdbus",
+ "sse2",
+ "sse3",
+ "sse4.1",
+ "sse4.2",
+ "ssse3",
+ "static",
+ "static-runtime",
+ "strip",
+ "syncqt",
+ "sysroot",
+ "testcocoon",
+ "use-gold-linker",
+ "warnings-are-errors",
+ "Werror",
+ "widgets",
+ "xplatform",
+ "zlib",
+ "doubleconversion",
+ "eventfd",
+ "glib",
+ "icu",
+ "inotify",
+ "journald",
+ "pcre",
+ "posix-ipc",
+ "pps",
+ "slog2",
+ "syslog",
+ "sqlite",
+ }
+
+ if sinput in skip_inputs:
+ print(f" **** Skipping input {sinput}: masked.")
+ return
+
+ dtype = data
+ if isinstance(data, dict):
+ dtype = data["type"]
+
+ if dtype == "boolean":
+ print(f" **** Skipping boolean input {sinput}: masked.")
+ return
+
+ if dtype == "enum":
+ values_line = " ".join(data["values"])
+ cm_fh.write(f"# input {sinput}\n")
+ cm_fh.write(f'set(INPUT_{featureName(sinput)} "undefined" CACHE STRING "")\n')
+ cm_fh.write(
+ f"set_property(CACHE INPUT_{featureName(sinput)} PROPERTY STRINGS undefined {values_line})\n\n"
+ )
+ return
+
+ print(f" XXXX UNHANDLED INPUT TYPE {dtype} in input description")
+ return
+
+
+# "tests": {
+# "cxx11_future": {
+# "label": "C++11 <future>",
+# "type": "compile",
+# "test": {
+# "include": "future",
+# "main": [
+# "std::future<int> f = std::async([]() { return 42; });",
+# "(void)f.get();"
+# ],
+# "qmake": "unix:LIBS += -lpthread"
+# }
+# },
+def parseTest(ctx, test, data, cm_fh):
+ skip_tests = {
+ "c11",
+ "c99",
+ "gc_binaries",
+ "posix-iconv",
+ "sun-iconv",
+ "precomile_header",
+ "reduce_exports",
+ "separate_debug_info", # FIXME: see if cmake can do this
+ "gc_binaries",
+ "libinput_axis_api",
+ "wayland-scanner",
+ "xlib",
+ }
+
+ if test in skip_tests:
+ print(f" **** Skipping features {test}: masked.")
+ return
+
+ if data["type"] == "compile":
+ knownTests.add(test)
+
+ details = data["test"]
+
+ if isinstance(details, str):
+ if not ctx["test_dir"]:
+ print(f" XXXX UNHANDLED TEST SUB-TYPE {details} in test description")
+ return
+
+ cm_fh.write(
+ f"""
+if(EXISTS "${{CMAKE_CURRENT_SOURCE_DIR}}/{ctx['test_dir']}/{data['test']}/CMakeLists.txt")
+ qt_config_compile_test("{data['test']}"
+ LABEL "{data['label']}"
+ PROJECT_PATH "${{CMAKE_CURRENT_SOURCE_DIR}}/{ctx['test_dir']}/{data['test']}")
+endif()
+"""
+ )
+ return
+
+ head = details.get("head", "")
+ if isinstance(head, list):
+ head = "\n".join(head)
+
+ sourceCode = head + "\n"
+
+ include = details.get("include", "")
+ if isinstance(include, list):
+ include = "#include <" + ">\n#include <".join(include) + ">"
+ elif include:
+ include = f"#include <{include}>"
+
+ sourceCode += include + "\n"
+
+ tail = details.get("tail", "")
+ if isinstance(tail, list):
+ tail = "\n".join(tail)
+
+ sourceCode += tail + "\n"
+
+ sourceCode += "int main(int argc, char **argv)\n"
+ sourceCode += "{\n"
+ sourceCode += " (void)argc; (void)argv;\n"
+ sourceCode += " /* BEGIN TEST: */\n"
+
+ main = details.get("main", "")
+ if isinstance(main, list):
+ main = "\n".join(main)
+
+ sourceCode += main + "\n"
+
+ sourceCode += " /* END TEST: */\n"
+ sourceCode += " return 0;\n"
+ sourceCode += "}\n"
+
+ sourceCode = sourceCode.replace('"', '\\"')
+
+ librariesCmakeName = ""
+ languageStandard = ""
+ qmakeFixme = ""
+
+ cm_fh.write(f"# {test}\n")
+ if "qmake" in details: # We don't really have many so we can just enumerate them all
+ if details["qmake"] == "unix:LIBS += -lpthread":
+ librariesCmakeName = format(featureName(test)) + "_TEST_LIBRARIES"
+ cm_fh.write("if (UNIX)\n")
+ cm_fh.write(" set(" + librariesCmakeName + " pthread)\n")
+ cm_fh.write("endif()\n")
+ elif details["qmake"] == "linux: LIBS += -lpthread -lrt":
+ librariesCmakeName = format(featureName(test)) + "_TEST_LIBRARIES"
+ cm_fh.write("if (LINUX)\n")
+ cm_fh.write(" set(" + librariesCmakeName + " pthread rt)\n")
+ cm_fh.write("endif()\n")
+ elif details["qmake"] == "!winrt: LIBS += runtimeobject.lib":
+ librariesCmakeName = format(featureName(test)) + "_TEST_LIBRARIES"
+ cm_fh.write("if (NOT WINRT)\n")
+ cm_fh.write(" set(" + librariesCmakeName + " runtimeobject)\n")
+ cm_fh.write("endif()\n")
+ elif details["qmake"] == "CONFIG += c++11":
+ # do nothing we're always in c++11 mode
+ pass
+ elif details["qmake"] == "CONFIG += c++11 c++14":
+ languageStandard = "CXX_STANDARD 14"
+ elif details["qmake"] == "CONFIG += c++11 c++14 c++17":
+ languageStandard = "CXX_STANDARD 17"
+ elif details["qmake"] == "CONFIG += c++11 c++14 c++17 c++2a":
+ languageStandard = "CXX_STANDARD 20"
+ else:
+ qmakeFixme = f"# FIXME: qmake: {details['qmake']}\n"
+
+ library_list = []
+ if "use" in data:
+ for library in data["use"].split(" "):
+ if len(library) == 0:
+ continue
+
+ mapped_library = find_3rd_party_library_mapping(library)
+ if not mapped_library:
+ qmakeFixme += f"# FIXME: use: unmapped library: {library}\n"
+ continue
+ library_list.append(mapped_library.targetName)
+
+ cm_fh.write(f"qt_config_compile_test({featureName(test)}\n")
+ cm_fh.write(lineify("LABEL", data.get("label", "")))
+ if librariesCmakeName != "" or len(library_list) != 0:
+ cm_fh.write(" LIBRARIES\n")
+ if librariesCmakeName != "":
+ cm_fh.write(lineify("", "${" + librariesCmakeName + "}"))
+ if len(library_list) != 0:
+ cm_fh.write(" ")
+ cm_fh.write("\n ".join(library_list))
+ cm_fh.write("\n")
+ cm_fh.write(" CODE\n")
+ cm_fh.write('"' + sourceCode + '"')
+ if qmakeFixme != "":
+ cm_fh.write(qmakeFixme)
+ if languageStandard != "":
+ cm_fh.write(f"\n {languageStandard}\n")
+ cm_fh.write(")\n\n")
+
+ elif data["type"] == "libclang":
+ knownTests.add(test)
+
+ cm_fh.write(f"# {test}\n")
+ lib_clang_lib = find_3rd_party_library_mapping("libclang")
+ cm_fh.write(generate_find_package_info(lib_clang_lib))
+ cm_fh.write(
+ dedent(
+ """
+ if(TARGET WrapLibClang::WrapLibClang)
+ set(TEST_libclang "ON" CACHE BOOL "Required libclang version found." FORCE)
+ endif()
+ """
+ )
+ )
+ cm_fh.write("\n")
+
+ elif data["type"] == "x86Simd":
+ knownTests.add(test)
+
+ label = data["label"]
+
+ cm_fh.write(f"# {test}\n")
+ cm_fh.write(f'qt_config_compile_test_x86simd({test} "{label}")\n')
+ cm_fh.write("\n")
+
+ # "features": {
+ # "android-style-assets": {
+ # "label": "Android Style Assets",
+ # "condition": "config.android",
+ # "output": [ "privateFeature" ],
+ # "comment": "This belongs into gui, but the license check needs it here already."
+ # },
+ else:
+ print(f" XXXX UNHANDLED TEST TYPE {data['type']} in test description")
+
+
+def parseFeature(ctx, feature, data, cm_fh):
+ # This is *before* the feature name gets normalized! So keep - and + chars, etc.
+ feature_mapping = {
+ "alloc_h": None, # handled by alloc target
+ "alloc_malloc_h": None,
+ "alloc_stdlib_h": None,
+ "build_all": None,
+ "c11": None,
+ "c89": None,
+ "c99": None,
+ "ccache": None,
+ "compiler-flags": None,
+ "cross_compile": None,
+ "debug_and_release": None,
+ "debug": None,
+ "dlopen": {"condition": "UNIX"},
+ "doubleconversion": None,
+ "enable_gdb_index": None,
+ "enable_new_dtags": None,
+ "force_debug_info": None,
+ "framework": {"condition": "APPLE AND BUILD_SHARED_LIBS"},
+ "gc_binaries": None,
+ "gcc-sysroot": None,
+ "gcov": None,
+ "gnu-libiconv": {
+ "condition": "NOT WIN32 AND NOT QNX AND NOT ANDROID AND NOT APPLE AND TEST_posix_iconv AND NOT TEST_iconv_needlib",
+ "enable": "TEST_posix_iconv AND NOT TEST_iconv_needlib",
+ "disable": "NOT TEST_posix_iconv OR TEST_iconv_needlib",
+ },
+ "GNUmake": None,
+ "harfbuzz": {"condition": "harfbuzz_FOUND"},
+ "host-dbus": None,
+ "iconv": {
+ "condition": "NOT QT_FEATURE_icu AND QT_FEATURE_textcodec AND ( TEST_posix_iconv OR TEST_sun_iconv )"
+ },
+ "incredibuild_xge": None,
+ "jpeg": {"condition": "QT_FEATURE_imageformatplugin AND JPEG_FOUND"},
+ "ltcg": None,
+ "msvc_mp": None,
+ "optimize_debug": None,
+ "optimize_size": None,
+ # special case to enable implicit feature on WIN32, until ANGLE is ported
+ "opengl-desktop": {"autoDetect": ""},
+ # special case to disable implicit feature on WIN32, until ANGLE is ported
+ "opengl-dynamic": {"autoDetect": "OFF"},
+ "opengles2": { # special case to disable implicit feature on WIN32, until ANGLE is ported
+ "condition": "NOT WIN32 AND ( NOT APPLE_WATCHOS AND NOT QT_FEATURE_opengl_desktop AND GLESv2_FOUND )"
+ },
+ "simulator_and_device": {"condition": "APPLE_UIKIT AND NOT QT_UIKIT_SDK"},
+ "pkg-config": None,
+ "posix_fallocate": None, # Only needed for sqlite, which we do not want to build
+ "posix-libiconv": {
+ "condition": "NOT WIN32 AND NOT QNX AND NOT ANDROID AND NOT APPLE AND TEST_posix_iconv AND TEST_iconv_needlib",
+ "enable": "TEST_posix_iconv AND TEST_iconv_needlib",
+ "disable": "NOT TEST_posix_iconv OR NOT TEST_iconv_needlib",
+ },
+ "precompile_header": None,
+ "profile": None,
+ "qmakeargs": None,
+ "qpa_default_platform": None, # Not a bool!
+ "reduce_relocations": None,
+ "release": None,
+ "release_tools": None,
+ "rpath_dir": None, # rpath related
+ "rpath": None,
+ "sanitize_address": None, # sanitizer
+ "sanitize_memory": None,
+ "sanitizer": None,
+ "sanitize_thread": None,
+ "sanitize_undefined": None,
+ "separate_debug_info": None,
+ "shared": None,
+ "silent": None,
+ "sql-sqlite": {"condition": "QT_FEATURE_datestring AND SQLite3_FOUND"},
+ "stack-protector-strong": None,
+ "static": None,
+ "static_runtime": None,
+ "stl": None, # Do we really need to test for this in 2018?!
+ "strip": None,
+ "sun-libiconv": {
+ "condition": "NOT WIN32 AND NOT QNX AND NOT ANDROID AND NOT APPLE AND TEST_sun_iconv",
+ "enable": "TEST_sun_iconv",
+ "disable": "NOT TEST_sun_iconv",
+ },
+ "system-doubleconversion": None, # No system libraries anymore!
+ "system-freetype": None,
+ "system-harfbuzz": None,
+ "system-jpeg": None,
+ "system-pcre2": None,
+ "system-png": None,
+ "system-sqlite": None,
+ "system-xcb": None,
+ "system-zlib": None,
+ "tiff": {"condition": "QT_FEATURE_imageformatplugin AND TIFF_FOUND"},
+ "use_gold_linker": None,
+ "verifyspec": None, # qmake specific...
+ "warnings_are_errors": None, # FIXME: Do we need these?
+ "webp": {"condition": "QT_FEATURE_imageformatplugin AND WrapWebP_FOUND"},
+ "xkbcommon-system": None, # another system library, just named a bit different from the rest
+ }
+
+ mapping = feature_mapping.get(feature, {})
+
+ if mapping is None:
+ print(f" **** Skipping features {feature}: masked.")
+ return
+
+ handled = {
+ "autoDetect",
+ "comment",
+ "condition",
+ "description",
+ "disable",
+ "emitIf",
+ "enable",
+ "label",
+ "output",
+ "purpose",
+ "section",
+ }
+ label = mapping.get("label", data.get("label", ""))
+ purpose = mapping.get("purpose", data.get("purpose", data.get("description", label)))
+ autoDetect = map_condition(mapping.get("autoDetect", data.get("autoDetect", "")))
+ condition = map_condition(mapping.get("condition", data.get("condition", "")))
+ output = mapping.get("output", data.get("output", []))
+ comment = mapping.get("comment", data.get("comment", ""))
+ section = mapping.get("section", data.get("section", ""))
+ enable = map_condition(mapping.get("enable", data.get("enable", "")))
+ disable = map_condition(mapping.get("disable", data.get("disable", "")))
+ emitIf = map_condition(mapping.get("emitIf", data.get("emitIf", "")))
+
+ for k in [k for k in data.keys() if k not in handled]:
+ print(f" XXXX UNHANDLED KEY {k} in feature description")
+
+ if not output:
+ # feature that is only used in the conditions of other features
+ output = ["internalFeature"]
+
+ publicFeature = False # #define QT_FEATURE_featurename in public header
+ privateFeature = False # #define QT_FEATURE_featurename in private header
+ negativeFeature = False # #define QT_NO_featurename in public header
+ internalFeature = False # No custom or QT_FEATURE_ defines
+ publicDefine = False # #define MY_CUSTOM_DEFINE in public header
+ publicConfig = False # add to CONFIG in public pri file
+ privateConfig = False # add to CONFIG in private pri file
+ publicQtConfig = False # add to QT_CONFIG in public pri file
+
+ for o in output:
+ outputType = o
+ if isinstance(o, dict):
+ outputType = o["type"]
+
+ if outputType in ["varAssign", "varAppend", "varRemove"]:
+ continue
+ elif outputType == "define":
+ publicDefine = True
+ elif outputType == "feature":
+ negativeFeature = True
+ elif outputType == "publicFeature":
+ publicFeature = True
+ elif outputType == "privateFeature":
+ privateFeature = True
+ elif outputType == "internalFeature":
+ internalFeature = True
+ elif outputType == "publicConfig":
+ publicConfig = True
+ elif outputType == "privateConfig":
+ privateConfig = True
+ elif outputType == "publicQtConfig":
+ publicQtConfig = True
+ else:
+ print(f" XXXX UNHANDLED OUTPUT TYPE {outputType} in feature {feature}.")
+ continue
+
+ if not any(
+ [
+ publicFeature,
+ privateFeature,
+ internalFeature,
+ publicDefine,
+ negativeFeature,
+ publicConfig,
+ privateConfig,
+ publicQtConfig,
+ ]
+ ):
+ print(f" **** Skipping feature {feature}: Not relevant for C++.")
+ return
+
+ normalized_feature_name = featureName(feature)
+
+ def writeFeature(
+ name,
+ publicFeature=False,
+ privateFeature=False,
+ labelAppend="",
+ superFeature=None,
+ autoDetect="",
+ ):
+ if comment:
+ cm_fh.write(f"# {comment}\n")
+
+ cm_fh.write(f'qt_feature("{name}"')
+ if publicFeature:
+ cm_fh.write(" PUBLIC")
+ if privateFeature:
+ cm_fh.write(" PRIVATE")
+ cm_fh.write("\n")
+
+ cm_fh.write(lineify("SECTION", section))
+ cm_fh.write(lineify("LABEL", label + labelAppend))
+ if purpose != label:
+ cm_fh.write(lineify("PURPOSE", purpose))
+ cm_fh.write(lineify("AUTODETECT", autoDetect, quote=False))
+ if superFeature:
+ feature_condition = f"QT_FEATURE_{superFeature}"
+ else:
+ feature_condition = condition
+ cm_fh.write(lineify("CONDITION", feature_condition, quote=False))
+ cm_fh.write(lineify("ENABLE", enable, quote=False))
+ cm_fh.write(lineify("DISABLE", disable, quote=False))
+ cm_fh.write(lineify("EMIT_IF", emitIf, quote=False))
+ cm_fh.write(")\n")
+
+ # Write qt_feature() calls before any qt_feature_definition() calls
+
+ # Default internal feature case.
+ featureCalls = {}
+ featureCalls[feature] = {"name": feature, "labelAppend": "", "autoDetect": autoDetect}
+
+ # Go over all outputs to compute the number of features that have to be declared
+ for o in output:
+ outputType = o
+ name = feature
+
+ # The label append is to provide a unique label for features that have more than one output
+ # with different names.
+ labelAppend = ""
+
+ if isinstance(o, dict):
+ outputType = o["type"]
+ if "name" in o:
+ name = o["name"]
+ labelAppend = f": {o['name']}"
+
+ if outputType not in ["feature", "publicFeature", "privateFeature"]:
+ continue
+ if name not in featureCalls:
+ featureCalls[name] = {"name": name, "labelAppend": labelAppend}
+
+ if name != feature:
+ featureCalls[name]["superFeature"] = normalized_feature_name
+
+ if outputType in ["feature", "publicFeature"]:
+ featureCalls[name]["publicFeature"] = True
+ elif outputType == "privateFeature":
+ featureCalls[name]["privateFeature"] = True
+ elif outputType == "publicConfig":
+ featureCalls[name]["publicConfig"] = True
+ elif outputType == "privateConfig":
+ featureCalls[name]["privateConfig"] = True
+ elif outputType == "publicQtConfig":
+ featureCalls[name]["publicQtConfig"] = True
+
+ # Write the qt_feature() calls from the computed feature map
+ for _, args in featureCalls.items():
+ writeFeature(**args)
+
+ # Write qt_feature_definition() calls
+ for o in output:
+ outputType = o
+ outputArgs = {}
+ if isinstance(o, dict):
+ outputType = o["type"]
+ outputArgs = o
+
+ # Map negative feature to define:
+ if outputType == "feature":
+ outputType = "define"
+ outputArgs = {
+ "name": f"QT_NO_{normalized_feature_name.upper()}",
+ "negative": True,
+ "value": 1,
+ "type": "define",
+ }
+
+ if outputType != "define":
+ continue
+
+ if outputArgs.get("name") is None:
+ print(f" XXXX DEFINE output without name in feature {feature}.")
+ continue
+
+ out_name = outputArgs.get("name")
+ cm_fh.write(f'qt_feature_definition("{feature}" "{out_name}"')
+ if outputArgs.get("negative", False):
+ cm_fh.write(" NEGATE")
+ if outputArgs.get("value") is not None:
+ cm_fh.write(f' VALUE "{outputArgs.get("value")}"')
+ cm_fh.write(")\n")
+
+ # Write qt_feature_config() calls
+ for o in output:
+ outputType = o
+ name = feature
+ modified_name = name
+
+ outputArgs = {}
+ if isinstance(o, dict):
+ outputType = o["type"]
+ outputArgs = o
+ if "name" in o:
+ modified_name = o["name"]
+
+ if outputType not in ["publicConfig", "privateConfig", "publicQtConfig"]:
+ continue
+
+ config_type = ""
+ if outputType == "publicConfig":
+ config_type = "QMAKE_PUBLIC_CONFIG"
+ elif outputType == "privateConfig":
+ config_type = "QMAKE_PRIVATE_CONFIG"
+ elif outputType == "publicQtConfig":
+ config_type = "QMAKE_PUBLIC_QT_CONFIG"
+
+ if not config_type:
+ print(" XXXX config output without type in feature {}.".format(feature))
+ continue
+
+ cm_fh.write('qt_feature_config("{}" {}'.format(name, config_type))
+ if outputArgs.get("negative", False):
+ cm_fh.write("\n NEGATE")
+ if modified_name != name:
+ cm_fh.write("\n")
+ cm_fh.write(lineify("NAME", modified_name, quote=True))
+
+ cm_fh.write(")\n")
+
+
+def processInputs(ctx, data, cm_fh):
+ print(" inputs:")
+ if "commandline" not in data:
+ return
+
+ commandLine = data["commandline"]
+ if "options" not in commandLine:
+ return
+
+ for input_option in commandLine["options"]:
+ parseInput(ctx, input_option, commandLine["options"][input_option], cm_fh)
+
+
+def processTests(ctx, data, cm_fh):
+ print(" tests:")
+ if "tests" not in data:
+ return
+
+ for test in data["tests"]:
+ parseTest(ctx, test, data["tests"][test], cm_fh)
+
+
+def processFeatures(ctx, data, cm_fh):
+ print(" features:")
+ if "features" not in data:
+ return
+
+ for feature in data["features"]:
+ parseFeature(ctx, feature, data["features"][feature], cm_fh)
+
+
+def processLibraries(ctx, data, cm_fh):
+ cmake_find_packages_set = set()
+ print(" libraries:")
+ if "libraries" not in data:
+ return
+
+ for lib in data["libraries"]:
+ parseLib(ctx, lib, data, cm_fh, cmake_find_packages_set)
+
+
+def processSubconfigs(path, ctx, data):
+ assert ctx is not None
+ if "subconfigs" in data:
+ for subconf in data["subconfigs"]:
+ subconfDir = posixpath.join(path, subconf)
+ subconfData = readJsonFromDir(subconfDir)
+ subconfCtx = ctx
+ processJson(subconfDir, subconfCtx, subconfData)
+
+
+def processJson(path, ctx, data):
+ ctx["module"] = data.get("module", "global")
+ ctx["test_dir"] = data.get("testDir", "")
+
+ ctx = processFiles(ctx, data)
+
+ with open(posixpath.join(path, "configure.cmake"), "w") as cm_fh:
+ cm_fh.write("\n\n#### Inputs\n\n")
+
+ processInputs(ctx, data, cm_fh)
+
+ cm_fh.write("\n\n#### Libraries\n\n")
+
+ processLibraries(ctx, data, cm_fh)
+
+ cm_fh.write("\n\n#### Tests\n\n")
+
+ processTests(ctx, data, cm_fh)
+
+ cm_fh.write("\n\n#### Features\n\n")
+
+ processFeatures(ctx, data, cm_fh)
+
+ if ctx.get("module") == "global":
+ cm_fh.write(
+ '\nqt_extra_definition("QT_VERSION_STR" "\\"${PROJECT_VERSION}\\"" PUBLIC)\n'
+ )
+ cm_fh.write('qt_extra_definition("QT_VERSION_MAJOR" ${PROJECT_VERSION_MAJOR} PUBLIC)\n')
+ cm_fh.write('qt_extra_definition("QT_VERSION_MINOR" ${PROJECT_VERSION_MINOR} PUBLIC)\n')
+ cm_fh.write('qt_extra_definition("QT_VERSION_PATCH" ${PROJECT_VERSION_PATCH} PUBLIC)\n')
+
+ # do this late:
+ processSubconfigs(path, ctx, data)
+
+
+def main():
+ if len(sys.argv) != 2:
+ print("This scripts needs one directory to process!")
+ quit(1)
+
+ directory = sys.argv[1]
+
+ print(f"Processing: {directory}.")
+
+ data = readJsonFromDir(directory)
+ processJson(directory, {}, data)
+
+
+if __name__ == "__main__":
+ main()
diff --git a/util/cmake/generate_module_map.sh b/util/cmake/generate_module_map.sh
new file mode 100755
index 0000000000..1ca0bfc43c
--- /dev/null
+++ b/util/cmake/generate_module_map.sh
@@ -0,0 +1,38 @@
+#!/usr/bin/bash
+#############################################################################
+##
+## Copyright (C) 2018 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+pro_files=$(find . -name \*.pro)
+
+for f in ${pro_files}; do
+ if grep "^load(qt_module)" "${f}" > /dev/null ; then
+ target=$(grep "TARGET" "${f}" | cut -d'=' -f2 | sed -e "s/\s*//g")
+ module=$(basename ${f})
+ echo "'${module%.pro}': '${target}',"
+ fi
+done
diff --git a/util/cmake/helper.py b/util/cmake/helper.py
new file mode 100644
index 0000000000..091b619201
--- /dev/null
+++ b/util/cmake/helper.py
@@ -0,0 +1,740 @@
+#############################################################################
+##
+## Copyright (C) 2018 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+import re
+import typing
+
+
+class LibraryMapping:
+ def __init__(
+ self,
+ soName: str,
+ packageName: typing.Optional[str],
+ targetName: typing.Optional[str],
+ *,
+ resultVariable: typing.Optional[str] = None,
+ extra: typing.List[str] = [],
+ appendFoundSuffix: bool = True,
+ emit_if: str = "",
+ ) -> None:
+ self.soName = soName
+ self.packageName = packageName
+ self.resultVariable = resultVariable
+ self.appendFoundSuffix = appendFoundSuffix
+ self.extra = extra
+ self.targetName = targetName
+
+ # if emit_if is non-empty, the generated find_package call
+ # for a library will be surrounded by this condition.
+ self.emit_if = emit_if
+
+ def is_qt(self) -> bool:
+ return self.packageName == "Qt" or self.packageName == "Qt5" or self.packageName == "Qt6"
+
+
+_qt_library_map = [
+ # Qt:
+ LibraryMapping(
+ "accessibility_support",
+ "Qt6",
+ "Qt::AccessibilitySupport",
+ extra=["COMPONENTS", "AccessibilitySupport"],
+ ),
+ LibraryMapping(
+ "androidextras", "Qt6", "Qt::AndroidExtras", extra=["COMPONENTS", "AndroidExtras"]
+ ),
+ LibraryMapping("animation", "Qt6", "Qt::3DAnimation", extra=["COMPONENTS", "3DAnimation"]),
+ LibraryMapping(
+ "application-lib", "Qt6", "Qt::AppManApplication", extra=["COMPONENTS", "AppManApplication"]
+ ),
+ LibraryMapping("bluetooth", "Qt6", "Qt::Bluetooth", extra=["COMPONENTS", "Bluetooth"]),
+ LibraryMapping("bootstrap", "Qt6", "Qt::Bootstrap", extra=["COMPONENTS", "Bootstrap"]),
+ # bootstrap-dbus: Not needed in Qt6!
+ LibraryMapping("client", "Qt6", "Qt::WaylandClient", extra=["COMPONENTS", "WaylandClient"]),
+ LibraryMapping(
+ "clipboard_support", "Qt6", "Qt::ClipboardSupport", extra=["COMPONENTS", "ClipboardSupport"]
+ ),
+ LibraryMapping("coap", "Qt6", "Qt::Coap", extra=["COMPONENTS", "Coap"]),
+ LibraryMapping("common-lib", "Qt6", "Qt::AppManCommon", extra=["COMPONENTS", "AppManCommon"]),
+ LibraryMapping(
+ "compositor", "Qt6", "Qt::WaylandCompositor", extra=["COMPONENTS", "WaylandCompositor"]
+ ),
+ LibraryMapping("concurrent", "Qt6", "Qt::Concurrent", extra=["COMPONENTS", "Concurrent"]),
+ LibraryMapping("container", "Qt6", "Qt::AxContainer", extra=["COMPONENTS", "AxContainer"]),
+ LibraryMapping("control", "Qt6", "Qt::AxServer", extra=["COMPONENTS", "AxServer"]),
+ LibraryMapping(
+ "core_headers", "Qt6", "Qt::WebEngineCore", extra=["COMPONENTS", "WebEngineCore"]
+ ),
+ LibraryMapping("core", "Qt6", "Qt::Core", extra=["COMPONENTS", "Core"]),
+ LibraryMapping("coretest", "Qt6", "Qt::3DCoreTest", extra=["COMPONENTS", "3DCoreTest"]),
+ LibraryMapping("crypto-lib", "Qt6", "Qt::AppManCrypto", extra=["COMPONENTS", "AppManCrypto"]),
+ LibraryMapping("dbus", "Qt6", "Qt::DBus", extra=["COMPONENTS", "DBus"]),
+ LibraryMapping("designer", "Qt6", "Qt::Designer", extra=["COMPONENTS", "Designer"]),
+ LibraryMapping(
+ "designercomponents",
+ "Qt6",
+ "Qt::DesignerComponents",
+ extra=["COMPONENTS", "DesignerComponents"],
+ ),
+ LibraryMapping(
+ "devicediscovery",
+ "Qt6",
+ "Qt::DeviceDiscoverySupport",
+ extra=["COMPONENTS", "DeviceDiscoverySupport"],
+ ),
+ LibraryMapping(
+ "devicediscovery_support",
+ "Qt6",
+ "Qt::DeviceDiscoverySupport",
+ extra=["COMPONENTS", "DeviceDiscoverySupport"],
+ ),
+ LibraryMapping("edid", "Qt6", "Qt::EdidSupport", extra=["COMPONENTS", "EdidSupport"]),
+ LibraryMapping("edid_support", "Qt6", "Qt::EdidSupport", extra=["COMPONENTS", "EdidSupport"]),
+ LibraryMapping("eglconvenience", "Qt6", "Qt::EglSupport", extra=["COMPONENTS", "EglSupport"]),
+ LibraryMapping(
+ "eglfsdeviceintegration",
+ "Qt6",
+ "Qt::EglFSDeviceIntegration",
+ extra=["COMPONENTS", "EglFSDeviceIntegration"],
+ ),
+ LibraryMapping(
+ "eglfs_kms_support", "Qt6", "Qt::EglFsKmsSupport", extra=["COMPONENTS", "EglFsKmsSupport"]
+ ),
+ LibraryMapping("egl_support", "Qt6", "Qt::EglSupport", extra=["COMPONENTS", "EglSupport"]),
+ # enginio: Not needed in Qt6!
+ LibraryMapping(
+ "eventdispatchers",
+ "Qt6",
+ "Qt::EventDispatcherSupport",
+ extra=["COMPONENTS", "EventDispatcherSupport"],
+ ),
+ LibraryMapping(
+ "eventdispatcher_support",
+ "Qt6",
+ "Qt::EventDispatcherSupport",
+ extra=["COMPONENTS", "EventDispatcherSupport"],
+ ),
+ LibraryMapping("extras", "Qt6", "Qt::3DExtras", extra=["COMPONENTS", "3DExtras"]),
+ LibraryMapping("fbconvenience", "Qt6", "Qt::FbSupport", extra=["COMPONENTS", "FbSupport"]),
+ LibraryMapping("fb_support", "Qt6", "Qt::FbSupport", extra=["COMPONENTS", "FbSupport"]),
+ LibraryMapping(
+ "fontdatabase_support",
+ "Qt6",
+ "Qt::FontDatabaseSupport",
+ extra=["COMPONENTS", "FontDatabaseSupport"],
+ ),
+ LibraryMapping("gamepad", "Qt6", "Qt::Gamepad", extra=["COMPONENTS", "Gamepad"]),
+ LibraryMapping(
+ "global", "Qt6", "Qt::Core", extra=["COMPONENTS", "Core"]
+ ), # manually added special case
+ LibraryMapping("glx_support", "Qt6", "Qt::GlxSupport", extra=["COMPONENTS", "GlxSupport"]),
+ LibraryMapping(
+ "graphics_support", "Qt6", "Qt::GraphicsSupport", extra=["COMPONENTS", "GraphicsSupport"]
+ ),
+ LibraryMapping(
+ "gsttools", "Qt6", "Qt::MultimediaGstTools", extra=["COMPONENTS", "MultimediaGstTools"]
+ ),
+ LibraryMapping("gui", "Qt6", "Qt::Gui", extra=["COMPONENTS", "Gui"]),
+ LibraryMapping("help", "Qt6", "Qt::Help", extra=["COMPONENTS", "Help"]),
+ LibraryMapping(
+ "hunspellinputmethod",
+ "Qt6",
+ "Qt::HunspellInputMethod",
+ extra=["COMPONENTS", "HunspellInputMethod"],
+ ),
+ LibraryMapping("input", "Qt6", "Qt::InputSupport", extra=["COMPONENTS", "InputSupport"]),
+ LibraryMapping(
+ "input_support", "Qt6", "Qt::InputSupport", extra=["COMPONENTS", "InputSupport"]
+ ),
+ LibraryMapping(
+ "installer-lib", "Qt6", "Qt::AppManInstaller", extra=["COMPONENTS", "AppManInstaller"]
+ ),
+ LibraryMapping("knx", "Qt6", "Qt::Knx", extra=["COMPONENTS", "Knx"]),
+ LibraryMapping("kmsconvenience", "Qt6", "Qt::KmsSupport", extra=["COMPONENTS", "KmsSupport"]),
+ LibraryMapping("kms_support", "Qt6", "Qt::KmsSupport", extra=["COMPONENTS", "KmsSupport"]),
+ LibraryMapping(
+ "launcher-lib", "Qt6", "Qt::AppManLauncher", extra=["COMPONENTS", "AppManLauncher"]
+ ),
+ LibraryMapping("lib", "Qt6", "Qt::Designer", extra=["COMPONENTS", "Designer"]),
+ LibraryMapping(
+ "linuxaccessibility_support",
+ "Qt6",
+ "Qt::LinuxAccessibilitySupport",
+ extra=["COMPONENTS", "LinuxAccessibilitySupport"],
+ ),
+ LibraryMapping("location", "Qt6", "Qt::Location", extra=["COMPONENTS", "Location"]),
+ LibraryMapping("logic", "Qt6", "Qt::3DLogic", extra=["COMPONENTS", "3DLogic"]),
+ LibraryMapping("macextras", "Qt6", "Qt::MacExtras", extra=["COMPONENTS", "MacExtras"]),
+ LibraryMapping("main-lib", "Qt6", "Qt::AppManMain", extra=["COMPONENTS", "AppManMain"]),
+ LibraryMapping(
+ "manager-lib", "Qt6", "Qt::AppManManager", extra=["COMPONENTS", "AppManManager"]
+ ),
+ LibraryMapping(
+ "monitor-lib", "Qt6", "Qt::AppManMonitor", extra=["COMPONENTS", "AppManMonitor"]
+ ),
+ LibraryMapping("mqtt", "Qt6", "Qt::Mqtt", extra=["COMPONENTS", "Mqtt"]),
+ LibraryMapping("multimedia", "Qt6", "Qt::Multimedia", extra=["COMPONENTS", "Multimedia"]),
+ LibraryMapping(
+ "multimediawidgets",
+ "Qt6",
+ "Qt::MultimediaWidgets",
+ extra=["COMPONENTS", "MultimediaWidgets"],
+ ),
+ LibraryMapping("network", "Qt6", "Qt::Network", extra=["COMPONENTS", "Network"]),
+ LibraryMapping("networkauth", "Qt6", "Qt::NetworkAuth", extra=["COMPONENTS", "NetworkAuth"]),
+ LibraryMapping("nfc", "Qt6", "Qt::Nfc", extra=["COMPONENTS", "Nfc"]),
+ LibraryMapping("oauth", "Qt6", "Qt::NetworkAuth", extra=["COMPONENTS", "NetworkAuth"]),
+ LibraryMapping(
+ "openglextensions", "Qt6", "Qt::OpenGLExtensions", extra=["COMPONENTS", "OpenGLExtensions"]
+ ),
+ LibraryMapping("opengl", "Qt6", "Qt::OpenGL", extra=["COMPONENTS", "OpenGL"]),
+ LibraryMapping(
+ "package-lib", "Qt6", "Qt::AppManPackage", extra=["COMPONENTS", "AppManPackage"]
+ ),
+ LibraryMapping(
+ "packetprotocol", "Qt6", "Qt::PacketProtocol", extra=["COMPONENTS", "PacketProtocol"]
+ ),
+ LibraryMapping(
+ "particles", "Qt6", "Qt::QuickParticles", extra=["COMPONENTS", "QuickParticles"]
+ ),
+ LibraryMapping(
+ "platformcompositor",
+ "Qt6",
+ "Qt::PlatformCompositorSupport",
+ extra=["COMPONENTS", "PlatformCompositorSupport"],
+ ),
+ LibraryMapping(
+ "platformcompositor_support",
+ "Qt6",
+ "Qt::PlatformCompositorSupport",
+ extra=["COMPONENTS", "PlatformCompositorSupport"],
+ ),
+ LibraryMapping(
+ "plugin-interfaces",
+ "Qt6",
+ "Qt::AppManPluginInterfaces",
+ extra=["COMPONENTS", "AppManPluginInterfaces"],
+ ),
+ LibraryMapping("positioning", "Qt6", "Qt::Positioning", extra=["COMPONENTS", "Positioning"]),
+ LibraryMapping(
+ "positioningquick", "Qt6", "Qt::PositioningQuick", extra=["COMPONENTS", "PositioningQuick"]
+ ),
+ LibraryMapping("printsupport", "Qt6", "Qt::PrintSupport", extra=["COMPONENTS", "PrintSupport"]),
+ LibraryMapping("purchasing", "Qt6", "Qt::Purchasing", extra=["COMPONENTS", "Purchasing"]),
+ LibraryMapping("qmldebug", "Qt6", "Qt::QmlDebug", extra=["COMPONENTS", "QmlDebug"]),
+ LibraryMapping("qmldevtools", "Qt6", "Qt::QmlDevTools", extra=["COMPONENTS", "QmlDevTools"]),
+ LibraryMapping("qml", "Qt6", "Qt::Qml", extra=["COMPONENTS", "Qml"]),
+ LibraryMapping("qmlmodels", "Qt6", "Qt::QmlModels", extra=["COMPONENTS", "QmlModels"]),
+ LibraryMapping("qmltest", "Qt6", "Qt::QuickTest", extra=["COMPONENTS", "QuickTest"]),
+ LibraryMapping(
+ "qtmultimediaquicktools",
+ "Qt6",
+ "Qt::MultimediaQuick",
+ extra=["COMPONENTS", "MultimediaQuick"],
+ ),
+ LibraryMapping(
+ "quick3dassetimport",
+ "Qt6",
+ "Qt::Quick3DAssetImport",
+ extra=["COMPONENTS", "Quick3DAssetImport"],
+ ),
+ LibraryMapping("quick3d", "Qt6", "Qt::Quick3D", extra=["COMPONENTS", "Quick3D"]),
+ LibraryMapping(
+ "quick3drender", "Qt6", "Qt::Quick3DRender", extra=["COMPONENTS", "Quick3DRender"]
+ ),
+ LibraryMapping(
+ "quick3druntimerender",
+ "Qt6",
+ "Qt::Quick3DRuntimeRender",
+ extra=["COMPONENTS", "Quick3DRuntimeRender"],
+ ),
+ LibraryMapping("quick3dutils", "Qt6", "Qt::Quick3DUtils", extra=["COMPONENTS", "Quick3DUtils"]),
+ LibraryMapping(
+ "quickcontrols2", "Qt6", "Qt::QuickControls2", extra=["COMPONENTS", "QuickControls2"]
+ ),
+ LibraryMapping("quick", "Qt6", "Qt::Quick", extra=["COMPONENTS", "Quick"]),
+ LibraryMapping("quickshapes", "Qt6", "Qt::QuickShapes", extra=["COMPONENTS", "QuickShapes"]),
+ LibraryMapping(
+ "quicktemplates2", "Qt6", "Qt::QuickTemplates2", extra=["COMPONENTS", "QuickTemplates2"]
+ ),
+ LibraryMapping("quickwidgets", "Qt6", "Qt::QuickWidgets", extra=["COMPONENTS", "QuickWidgets"]),
+ LibraryMapping("render", "Qt6", "Qt::3DRender", extra=["COMPONENTS", "3DRender"]),
+ LibraryMapping(
+ "remoteobjects", "Qt6", "Qt::RemoteObjects", extra=["COMPONENTS", "RemoteObjects"]
+ ),
+ LibraryMapping("script", "Qt6", "Qt::Script", extra=["COMPONENTS", "Script"]),
+ LibraryMapping("scripttools", "Qt6", "Qt::ScriptTools", extra=["COMPONENTS", "ScriptTools"]),
+ LibraryMapping("scxml", "Qt6", "Qt::Scxml", extra=["COMPONENTS", "Scxml"]),
+ LibraryMapping("sensors", "Qt6", "Qt::Sensors", extra=["COMPONENTS", "Sensors"]),
+ LibraryMapping("serialport", "Qt6", "Qt::SerialPort", extra=["COMPONENTS", "SerialPort"]),
+ LibraryMapping("serialbus", "Qt6", "Qt::SerialBus", extra=["COMPONENTS", "SerialBus"]),
+ LibraryMapping("services", "Qt6", "Qt::ServiceSupport", extra=["COMPONENTS", "ServiceSupport"]),
+ LibraryMapping(
+ "service_support", "Qt6", "Qt::ServiceSupport", extra=["COMPONENTS", "ServiceSupport"]
+ ),
+ LibraryMapping("sql", "Qt6", "Qt::Sql", extra=["COMPONENTS", "Sql"]),
+ LibraryMapping("svg", "Qt6", "Qt::Svg", extra=["COMPONENTS", "Svg"]),
+ LibraryMapping("testlib", "Qt6", "Qt::Test", extra=["COMPONENTS", "Test"]),
+ LibraryMapping("texttospeech", "Qt6", "Qt::TextToSpeech", extra=["COMPONENTS", "TextToSpeech"]),
+ LibraryMapping(
+ "theme_support", "Qt6", "Qt::ThemeSupport", extra=["COMPONENTS", "ThemeSupport"]
+ ),
+ LibraryMapping("tts", "Qt6", "Qt::TextToSpeech", extra=["COMPONENTS", "TextToSpeech"]),
+ LibraryMapping("uiplugin", "Qt6", "Qt::UiPlugin", extra=["COMPONENTS", "UiPlugin"]),
+ LibraryMapping("uitools", "Qt6", "Qt::UiTools", extra=["COMPONENTS", "UiTools"]),
+ LibraryMapping(
+ "virtualkeyboard", "Qt6", "Qt::VirtualKeyboard", extra=["COMPONENTS", "VirtualKeyboard"]
+ ),
+ LibraryMapping(
+ "vulkan_support", "Qt6", "Qt::VulkanSupport", extra=["COMPONENTS", "VulkanSupport"]
+ ),
+ LibraryMapping(
+ "waylandclient", "Qt6", "Qt::WaylandClient", extra=["COMPONENTS", "WaylandClient"]
+ ),
+ LibraryMapping(
+ "waylandcompositor",
+ "Qt6",
+ "Qt::WaylandCompositor",
+ extra=["COMPONENTS", "WaylandCompositor"],
+ ),
+ LibraryMapping("webchannel", "Qt6", "Qt::WebChannel", extra=["COMPONENTS", "WebChannel"]),
+ LibraryMapping("webengine", "Qt6", "Qt::WebEngine", extra=["COMPONENTS", "WebEngine"]),
+ LibraryMapping(
+ "webenginewidgets", "Qt6", "Qt::WebEngineWidgets", extra=["COMPONENTS", "WebEngineWidgets"]
+ ),
+ LibraryMapping("websockets", "Qt6", "Qt::WebSockets", extra=["COMPONENTS", "WebSockets"]),
+ LibraryMapping("webview", "Qt6", "Qt::WebView", extra=["COMPONENTS", "WebView"]),
+ LibraryMapping("widgets", "Qt6", "Qt::Widgets", extra=["COMPONENTS", "Widgets"]),
+ LibraryMapping("window-lib", "Qt6", "Qt::AppManWindow", extra=["COMPONENTS", "AppManWindow"]),
+ LibraryMapping(
+ "windowsuiautomation_support",
+ "Qt6",
+ "Qt::WindowsUIAutomationSupport",
+ extra=["COMPONENTS", "WindowsUIAutomationSupport"],
+ ),
+ LibraryMapping("winextras", "Qt6", "Qt::WinExtras", extra=["COMPONENTS", "WinExtras"]),
+ LibraryMapping("x11extras", "Qt6", "Qt::X11Extras", extra=["COMPONENTS", "X11Extras"]),
+ LibraryMapping("xcb_qpa_lib", "Qt6", "Qt::XcbQpa", extra=["COMPONENTS", "XcbQpa"]),
+ LibraryMapping(
+ "xkbcommon_support", "Qt6", "Qt::XkbCommonSupport", extra=["COMPONENTS", "XkbCommonSupport"]
+ ),
+ LibraryMapping("xmlpatterns", "Qt6", "Qt::XmlPatterns", extra=["COMPONENTS", "XmlPatterns"]),
+ LibraryMapping("xml", "Qt6", "Qt::Xml", extra=["COMPONENTS", "Xml"]),
+ LibraryMapping(
+ "qmlworkerscript", "Qt6", "Qt::QmlWorkerScript", extra=["COMPONENTS", "QmlWorkerScript"]
+ ),
+ LibraryMapping(
+ "quickparticles", "Qt6", "Qt::QuickParticles", extra=["COMPONENTS", "QuickParticles"]
+ ),
+ LibraryMapping(
+ "linuxofono_support",
+ "Qt6",
+ "Qt::LinuxOfonoSupport",
+ extra=["COMPONENTS", "LinuxOfonoSupport"],
+ ),
+ LibraryMapping(
+ "linuxofono_support_private",
+ "Qt6",
+ "Qt::LinuxOfonoSupportPrivate",
+ extra=["COMPONENTS", "LinuxOfonoSupportPrivate"],
+ ),
+ LibraryMapping("tools", "Qt6", "Qt::Tools", extra=["COMPONENTS", "Tools"]),
+ LibraryMapping("axcontainer", "Qt6", "Qt::AxContainer", extra=["COMPONENTS", "AxContainer"]),
+ LibraryMapping(
+ "webkitwidgets", "Qt6", "Qt::WebKitWidgets", extra=["COMPONENTS", "WebKitWidgets"]
+ )
+ # qtzlib: No longer supported.
+]
+
+# Note that the library map is adjusted dynamically further down.
+_library_map = [
+ # 3rd party:
+ LibraryMapping("atspi", "ATSPI2", "PkgConfig::ATSPI2"),
+ LibraryMapping("bluez", "BlueZ", "PkgConfig::BlueZ"),
+ LibraryMapping("corewlan", None, None),
+ LibraryMapping("cups", "Cups", "Cups::Cups"),
+ LibraryMapping("directfb", "DirectFB", "PkgConfig::DirectFB"),
+ LibraryMapping("db2", "DB2", "DB2::DB2"),
+ LibraryMapping("dbus", "WrapDBus1", "dbus-1", resultVariable="DBus1"),
+ LibraryMapping("doubleconversion", None, None),
+ LibraryMapping("drm", "Libdrm", "Libdrm::Libdrm"),
+ LibraryMapping("egl", "EGL", "EGL::EGL"),
+ LibraryMapping("flite", "Flite", "Flite::Flite"),
+ LibraryMapping("flite_alsa", "ALSA", "ALSA::ALSA"),
+ LibraryMapping(
+ "fontconfig", "Fontconfig", "Fontconfig::Fontconfig", resultVariable="FONTCONFIG"
+ ),
+ LibraryMapping("freetype", "WrapFreetype", "WrapFreetype::WrapFreetype", extra=["REQUIRED"]),
+ LibraryMapping("gbm", "gbm", "gbm::gbm"),
+ LibraryMapping("glib", "GLIB2", "GLIB2::GLIB2"),
+ LibraryMapping("gnu_iconv", None, None),
+ LibraryMapping("gtk3", "GTK3", "PkgConfig::GTK3"),
+ LibraryMapping("gssapi", "GSSAPI", "GSSAPI::GSSAPI"),
+ LibraryMapping("harfbuzz", "WrapHarfbuzz", "WrapHarfbuzz::WrapHarfbuzz"),
+ LibraryMapping("host_dbus", None, None),
+ LibraryMapping(
+ "icu", "ICU", "ICU::i18n ICU::uc ICU::data", extra=["COMPONENTS", "i18n", "uc", "data"]
+ ),
+ LibraryMapping("journald", "Libsystemd", "PkgConfig::Libsystemd"),
+ LibraryMapping("jpeg", "JPEG", "JPEG::JPEG"), # see also libjpeg
+ LibraryMapping("libatomic", "Atomic", "Atomic"),
+ LibraryMapping("libclang", "WrapLibClang", "WrapLibClang::WrapLibClang"),
+ LibraryMapping("libdl", None, "${CMAKE_DL_LIBS}"),
+ LibraryMapping("libinput", "Libinput", "Libinput::Libinput"),
+ LibraryMapping("libjpeg", "JPEG", "JPEG::JPEG"), # see also jpeg
+ LibraryMapping("libpng", "PNG", "PNG::PNG"),
+ LibraryMapping("libproxy", "Libproxy", "PkgConfig::Libproxy"),
+ LibraryMapping("librt", "WrapRt", "WrapRt"),
+ LibraryMapping("libudev", "Libudev", "PkgConfig::Libudev"),
+ LibraryMapping("lttng-ust", "LTTngUST", "LTTng::UST", resultVariable="LTTNGUST"),
+ LibraryMapping("mtdev", "Mtdev", "PkgConfig::Mtdev"),
+ LibraryMapping("mysql", "MySQL", "MySQL::MySQL"),
+ LibraryMapping("odbc", "ODBC", "ODBC::ODBC"),
+ LibraryMapping("opengl_es2", "GLESv2", "GLESv2::GLESv2"),
+ LibraryMapping("opengl", "OpenGL", "OpenGL::GL", resultVariable="OpenGL_OpenGL"),
+ LibraryMapping(
+ "openssl_headers",
+ "OpenSSL",
+ "OpenSSL::SSL_nolink",
+ resultVariable="OPENSSL_INCLUDE_DIR",
+ appendFoundSuffix=False,
+ ),
+ LibraryMapping("openssl", "OpenSSL", "OpenSSL::SSL"),
+ LibraryMapping("oci", "Oracle", "Oracle::OCI"),
+ LibraryMapping("pcre2", "WrapPCRE2", "WrapPCRE2::WrapPCRE2", extra=["REQUIRED"]),
+ LibraryMapping("posix_iconv", None, None),
+ LibraryMapping("pps", "PPS", "PPS::PPS"),
+ LibraryMapping("psql", "PostgreSQL", "PostgreSQL::PostgreSQL"),
+ LibraryMapping("slog2", "Slog2", "Slog2::Slog2"),
+ LibraryMapping("speechd", "SpeechDispatcher", "SpeechDispatcher::SpeechDispatcher"),
+ LibraryMapping("sqlite2", None, None), # No more sqlite2 support in Qt6!
+ LibraryMapping("sqlite3", "SQLite3", "SQLite::SQLite3"),
+ LibraryMapping("sun_iconv", None, None),
+ LibraryMapping("tslib", "Tslib", "PkgConfig::Tslib"),
+ LibraryMapping("udev", "Libudev", "PkgConfig::Libudev"),
+ LibraryMapping("udev", "Libudev", "PkgConfig::Libudev"), # see also libudev!
+ LibraryMapping("vulkan", "Vulkan", "Vulkan::Vulkan"),
+ LibraryMapping("wayland_server", "Wayland", "Wayland::Server"), # used in qtbase/src/gui
+ LibraryMapping("wayland-server", "Wayland", "Wayland::Server"), # used in qtwayland
+ LibraryMapping("wayland-client", "Wayland", "Wayland::Client"),
+ LibraryMapping("wayland-cursor", "Wayland", "Wayland::Cursor"),
+ LibraryMapping("wayland-egl", "Wayland", "Wayland::Egl"),
+ LibraryMapping(
+ "wayland-kms", "Waylandkms", "PkgConfig::Waylandkms"
+ ), # TODO: check if this actually works
+ LibraryMapping("x11", "X11", "X11::X11"),
+ LibraryMapping("x11sm", "X11", "${X11_SM_LIB} ${X11_ICE_LIB}", resultVariable="X11_SM"),
+ LibraryMapping(
+ "xcb",
+ "XCB",
+ "XCB::XCB",
+ extra=["1.9"],
+ resultVariable="TARGET XCB::XCB",
+ appendFoundSuffix=False,
+ ),
+ LibraryMapping(
+ "xcb_glx", "XCB", "XCB::GLX", extra=["COMPONENTS", "GLX"], resultVariable="XCB_GLX"
+ ),
+ LibraryMapping(
+ "xcb_icccm", "XCB", "XCB::ICCCM", extra=["COMPONENTS", "ICCCM"], resultVariable="XCB_ICCCM"
+ ),
+ LibraryMapping(
+ "xcb_image", "XCB", "XCB::IMAGE", extra=["COMPONENTS", "IMAGE"], resultVariable="XCB_IMAGE"
+ ),
+ LibraryMapping(
+ "xcb_keysyms",
+ "XCB",
+ "XCB::KEYSYMS",
+ extra=["COMPONENTS", "KEYSYMS"],
+ resultVariable="XCB_KEYSYMS",
+ ),
+ LibraryMapping(
+ "xcb_randr", "XCB", "XCB::RANDR", extra=["COMPONENTS", "RANDR"], resultVariable="XCB_RANDR"
+ ),
+ LibraryMapping(
+ "xcb_render",
+ "XCB",
+ "XCB::RENDER",
+ extra=["COMPONENTS", "RENDER"],
+ resultVariable="XCB_RENDER",
+ ),
+ LibraryMapping(
+ "xcb_renderutil",
+ "XCB",
+ "XCB::RENDERUTIL",
+ extra=["COMPONENTS", "RENDERUTIL"],
+ resultVariable="XCB_RENDERUTIL",
+ ),
+ LibraryMapping(
+ "xcb_shape", "XCB", "XCB::SHAPE", extra=["COMPONENTS", "SHAPE"], resultVariable="XCB_SHAPE"
+ ),
+ LibraryMapping(
+ "xcb_shm", "XCB", "XCB::SHM", extra=["COMPONENTS", "SHM"], resultVariable="XCB_SHM"
+ ),
+ LibraryMapping(
+ "xcb_sync", "XCB", "XCB::SYNC", extra=["COMPONENTS", "SYNC"], resultVariable="XCB_SYNC"
+ ),
+ LibraryMapping(
+ "xcb_xfixes",
+ "XCB",
+ "XCB::XFIXES",
+ extra=["COMPONENTS", "XFIXES"],
+ resultVariable="XCB_XFIXES",
+ ),
+ LibraryMapping(
+ "xcb_xinerama",
+ "XCB",
+ "XCB::XINERAMA",
+ extra=["COMPONENTS", "XINERAMA"],
+ resultVariable="XCB_XINERAMA",
+ ),
+ LibraryMapping(
+ "xcb_xinput",
+ "XCB",
+ "XCB::XINPUT",
+ extra=["COMPONENTS", "XINPUT"],
+ resultVariable="XCB_XINPUT",
+ ),
+ LibraryMapping(
+ "xcb_xkb", "XCB", "XCB::XKB", extra=["COMPONENTS", "XKB"], resultVariable="XCB_XKB"
+ ),
+ LibraryMapping("xcb_xlib", "X11_XCB", "X11::XCB"),
+ LibraryMapping("xcomposite", "XComposite", "PkgConfig::XComposite"),
+ LibraryMapping("xkbcommon_evdev", "XKB", "XKB::XKB", extra=["0.4.1"]), # see also xkbcommon
+ LibraryMapping("xkbcommon_x11", "XKB", "XKB::XKB", extra=["0.4.1"]), # see also xkbcommon
+ LibraryMapping("xkbcommon", "XKB", "XKB::XKB", extra=["0.4.1"]),
+ LibraryMapping("xlib", "X11", "X11::XCB"), # FIXME: Is this correct?
+ LibraryMapping("xrender", "XRender", "PkgConfig::XRender"),
+ LibraryMapping("zlib", "ZLIB", "ZLIB::ZLIB", extra=["REQUIRED"]),
+ LibraryMapping("zstd", "ZSTD", "ZSTD::ZSTD"),
+ LibraryMapping("tiff", "TIFF", "TIFF::TIFF"),
+ LibraryMapping("webp", "WrapWebP", "WrapWebP::WrapWebP"),
+ LibraryMapping("jasper", "WrapJasper", "WrapJasper::WrapJasper"),
+ LibraryMapping("sdl2", "WrapSDL2", "WrapSDL2::WrapSDL2"),
+]
+
+
+def _adjust_library_map():
+ # Assign a Linux condition on all x and wayland related packages.
+ # We don't want to get pages of package not found messages on
+ # Windows and macOS, and this also improves configure time on
+ # those platforms.
+ linux_package_prefixes = ["xcb", "x11", "xkb", "xrender", "xlib", "wayland"]
+ for i, _ in enumerate(_library_map):
+ if any([_library_map[i].soName.startswith(p) for p in linux_package_prefixes]):
+ _library_map[i].emit_if = "config.linux"
+
+
+_adjust_library_map()
+
+
+def find_3rd_party_library_mapping(soName: str) -> typing.Optional[LibraryMapping]:
+ for i in _library_map:
+ if i.soName == soName:
+ return i
+ return None
+
+
+def find_qt_library_mapping(soName: str) -> typing.Optional[LibraryMapping]:
+ for i in _qt_library_map:
+ if i.soName == soName:
+ return i
+ return None
+
+
+def find_library_info_for_target(targetName: str) -> typing.Optional[LibraryMapping]:
+ qt_target = targetName
+ if targetName.endswith("Private"):
+ qt_target = qt_target[:-7]
+
+ for i in _qt_library_map:
+ if i.targetName == qt_target:
+ return i
+
+ for i in _library_map:
+ if i.targetName == targetName:
+ return i
+
+ return None
+
+
+def featureName(name: str) -> str:
+ replacement_char = "_"
+ if name.startswith("c++"):
+ replacement_char = "x"
+ return re.sub(r"[^a-zA-Z0-9_]", replacement_char, name)
+
+
+def map_qt_library(lib: str) -> str:
+ private = False
+ if lib.endswith("-private"):
+ private = True
+ lib = lib[:-8]
+ mapped = find_qt_library_mapping(lib)
+ qt_name = lib
+ if mapped:
+ assert mapped.targetName # Qt libs must have a target name set
+ qt_name = mapped.targetName
+ if private:
+ qt_name += "Private"
+ return qt_name
+
+
+platform_mapping = {
+ "win32": "WIN32",
+ "win": "WIN32",
+ "unix": "UNIX",
+ "darwin": "APPLE",
+ "linux": "LINUX",
+ "integrity": "INTEGRITY",
+ "qnx": "QNX",
+ "vxworks": "VXWORKS",
+ "hpux": "HPUX",
+ "nacl": "NACL",
+ "android": "ANDROID",
+ "android-embedded": "ANDROID_EMBEDDED",
+ "uikit": "APPLE_UIKIT",
+ "tvos": "APPLE_TVOS",
+ "watchos": "APPLE_WATCHOS",
+ "winrt": "WINRT",
+ "wasm": "WASM",
+ "emscripten": "EMSCRIPTEN",
+ "msvc": "MSVC",
+ "clang": "CLANG",
+ "gcc": "GCC",
+ "icc": "ICC",
+ "intel_icc": "ICC",
+ "osx": "APPLE_OSX",
+ "ios": "APPLE_IOS",
+ "freebsd": "FREEBSD",
+ "openbsd": "OPENBSD",
+ "netbsd": "NETBSD",
+ "haiku": "HAIKU",
+ "netbsd": "NETBSD",
+ "mac": "APPLE",
+ "macx": "APPLE_OSX",
+ "macos": "APPLE_OSX",
+ "macx-icc": "(APPLE_OSX AND ICC)",
+}
+
+
+def map_platform(platform: str) -> str:
+ """ Return the qmake platform as cmake platform or the unchanged string. """
+ return platform_mapping.get(platform, platform)
+
+
+def is_known_3rd_party_library(lib: str) -> bool:
+ if lib.endswith("/nolink") or lib.endswith("_nolink"):
+ lib = lib[:-7]
+ mapping = find_3rd_party_library_mapping(lib)
+
+ return mapping is not None
+
+
+def map_3rd_party_library(lib: str) -> str:
+ libpostfix = ""
+ if lib.endswith("/nolink"):
+ lib = lib[:-7]
+ libpostfix = "_nolink"
+ mapping = find_3rd_party_library_mapping(lib)
+ if not mapping or not mapping.targetName:
+ return lib
+ return mapping.targetName + libpostfix
+
+
+def generate_find_package_info(
+ lib: LibraryMapping, use_qt_find_package: bool = True, *, indent: int = 0, emit_if: str = ""
+) -> str:
+ isRequired = False
+
+ extra = lib.extra.copy()
+
+ if "REQUIRED" in extra and use_qt_find_package:
+ isRequired = True
+ extra.remove("REQUIRED")
+
+ cmake_target_name = lib.targetName
+ assert cmake_target_name
+
+ # _nolink or not does not matter at this point:
+ if cmake_target_name.endswith("_nolink") or cmake_target_name.endswith("/nolink"):
+ cmake_target_name = cmake_target_name[:-7]
+
+ if cmake_target_name and use_qt_find_package:
+ extra += ["PROVIDED_TARGETS", cmake_target_name]
+
+ result = ""
+ one_ind = " "
+ ind = one_ind * indent
+
+ if use_qt_find_package:
+ if extra:
+ result = f"{ind}qt_find_package({lib.packageName} {' '.join(extra)})\n"
+ else:
+ result = f"{ind}qt_find_package({lib.packageName})\n"
+
+ if isRequired:
+ result += f"{ind}set_package_properties({lib.packageName} PROPERTIES TYPE REQUIRED)\n"
+ else:
+ if extra:
+ result = f"{ind}find_package({lib.packageName} {' '.join(extra)})\n"
+ else:
+ result = f"{ind}find_package({lib.packageName})\n"
+
+ # If a package should be found only in certain conditions, wrap
+ # the find_package call within that condition.
+ if emit_if:
+ result = f"if(({emit_if}) OR QT_FIND_ALL_PACKAGES_ALWAYS)\n{one_ind}{result}endif()\n"
+
+ return result
+
+
+def _set_up_py_parsing_nicer_debug_output(pp):
+ indent = -1
+
+ def increase_indent(fn):
+ def wrapper_function(*args):
+ nonlocal indent
+ indent += 1
+ print("> " * indent, end="")
+ return fn(*args)
+
+ return wrapper_function
+
+ def decrease_indent(fn):
+ def wrapper_function(*args):
+ nonlocal indent
+ print("> " * indent, end="")
+ indent -= 1
+ return fn(*args)
+
+ return wrapper_function
+
+ pp._defaultStartDebugAction = increase_indent(pp._defaultStartDebugAction)
+ pp._defaultSuccessDebugAction = decrease_indent(pp._defaultSuccessDebugAction)
+ pp._defaultExceptionDebugAction = decrease_indent(pp._defaultExceptionDebugAction)
diff --git a/util/cmake/json_parser.py b/util/cmake/json_parser.py
new file mode 100644
index 0000000000..a0aaecab9d
--- /dev/null
+++ b/util/cmake/json_parser.py
@@ -0,0 +1,101 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2019 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+import pyparsing as pp # type: ignore
+import json
+import re
+from helper import _set_up_py_parsing_nicer_debug_output
+
+_set_up_py_parsing_nicer_debug_output(pp)
+
+
+class QMakeSpecificJSONParser:
+ def __init__(self, *, debug: bool = False) -> None:
+ self.debug = debug
+ self.grammar = self.create_py_parsing_grammar()
+
+ def create_py_parsing_grammar(self):
+ # Keep around all whitespace.
+ pp.ParserElement.setDefaultWhitespaceChars("")
+
+ def add_element(name: str, value: pp.ParserElement):
+ nonlocal self
+ if self.debug:
+ value.setName(name)
+ value.setDebug()
+ return value
+
+ # Our grammar is pretty simple. We want to remove all newlines
+ # inside quoted strings, to make the quoted strings JSON
+ # compliant. So our grammar should skip to the first quote while
+ # keeping everything before it as-is, process the quoted string
+ # skip to the next quote, and repeat that until the end of the
+ # file.
+
+ EOF = add_element("EOF", pp.StringEnd())
+ SkipToQuote = add_element("SkipToQuote", pp.SkipTo('"'))
+ SkipToEOF = add_element("SkipToEOF", pp.SkipTo(EOF))
+
+ def remove_newlines_and_whitespace_in_quoted_string(tokens):
+ first_string = tokens[0]
+ replaced_string = re.sub(r"\n[ ]*", " ", first_string)
+ return replaced_string
+
+ QuotedString = add_element(
+ "QuotedString", pp.QuotedString(quoteChar='"', multiline=True, unquoteResults=False)
+ )
+ QuotedString.setParseAction(remove_newlines_and_whitespace_in_quoted_string)
+
+ QuotedTerm = add_element("QuotedTerm", pp.Optional(SkipToQuote) + QuotedString)
+ Grammar = add_element("Grammar", pp.OneOrMore(QuotedTerm) + SkipToEOF)
+
+ return Grammar
+
+ def parse_file_using_py_parsing(self, file: str):
+ print(f'Pre processing "{file}" using py parsing to remove incorrect newlines.')
+ try:
+ with open(file, "r") as file_fd:
+ contents = file_fd.read()
+
+ parser_result = self.grammar.parseString(contents, parseAll=True)
+ token_list = parser_result.asList()
+ joined_string = "".join(token_list)
+
+ return joined_string
+ except pp.ParseException as pe:
+ print(pe.line)
+ print(" " * (pe.col - 1) + "^")
+ print(pe)
+ raise pe
+
+ def parse(self, file: str):
+ pre_processed_string = self.parse_file_using_py_parsing(file)
+ print(f'Parsing "{file}" using json.loads().')
+ json_parsed = json.loads(pre_processed_string)
+ return json_parsed
diff --git a/util/cmake/pro2cmake.py b/util/cmake/pro2cmake.py
new file mode 100755
index 0000000000..3ad427f609
--- /dev/null
+++ b/util/cmake/pro2cmake.py
@@ -0,0 +1,3935 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2018 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+
+from __future__ import annotations
+
+import copy
+import os.path
+import posixpath
+import sys
+import re
+import io
+import glob
+
+from condition_simplifier import simplify_condition
+from condition_simplifier_cache import set_condition_simplified_cache_enabled
+
+import pyparsing as pp # type: ignore
+import xml.etree.ElementTree as ET
+
+from argparse import ArgumentParser
+from textwrap import dedent
+from textwrap import indent as textwrap_indent
+from functools import lru_cache
+from shutil import copyfile
+from collections import defaultdict
+from typing import (
+ List,
+ Optional,
+ Dict,
+ Set,
+ IO,
+ Union,
+ Any,
+ Callable,
+ FrozenSet,
+ Tuple,
+ Match,
+ Type,
+)
+
+from qmake_parser import parseProFile
+from special_case_helper import SpecialCaseHandler
+from helper import (
+ map_qt_library,
+ map_3rd_party_library,
+ is_known_3rd_party_library,
+ featureName,
+ map_platform,
+ find_library_info_for_target,
+ generate_find_package_info,
+ LibraryMapping,
+)
+
+
+cmake_version_string = "3.15.0"
+cmake_api_version = 2
+
+
+def _parse_commandline():
+ parser = ArgumentParser(
+ description="Generate CMakeLists.txt files from ." "pro files.",
+ epilog="Requirements: pip install sympy pyparsing",
+ )
+ parser.add_argument(
+ "--debug", dest="debug", action="store_true", help="Turn on all debug output"
+ )
+ parser.add_argument(
+ "--debug-parser",
+ dest="debug_parser",
+ action="store_true",
+ help="Print debug output from qmake parser.",
+ )
+ parser.add_argument(
+ "--debug-parse-result",
+ dest="debug_parse_result",
+ action="store_true",
+ help="Dump the qmake parser result.",
+ )
+ parser.add_argument(
+ "--debug-parse-dictionary",
+ dest="debug_parse_dictionary",
+ action="store_true",
+ help="Dump the qmake parser result as dictionary.",
+ )
+ parser.add_argument(
+ "--debug-pro-structure",
+ dest="debug_pro_structure",
+ action="store_true",
+ help="Dump the structure of the qmake .pro-file.",
+ )
+ parser.add_argument(
+ "--debug-full-pro-structure",
+ dest="debug_full_pro_structure",
+ action="store_true",
+ help="Dump the full structure of the qmake .pro-file " "(with includes).",
+ )
+ parser.add_argument(
+ "--debug-special-case-preservation",
+ dest="debug_special_case_preservation",
+ action="store_true",
+ help="Show all git commands and file copies.",
+ )
+
+ parser.add_argument(
+ "--is-example",
+ action="store_true",
+ dest="is_example",
+ help="Treat the input .pro file as an example.",
+ )
+ parser.add_argument(
+ "-s",
+ "--skip-special-case-preservation",
+ dest="skip_special_case_preservation",
+ action="store_true",
+ help="Skips behavior to reapply " "special case modifications (requires git in PATH)",
+ )
+ parser.add_argument(
+ "-k",
+ "--keep-temporary-files",
+ dest="keep_temporary_files",
+ action="store_true",
+ help="Don't automatically remove CMakeLists.gen.txt and other " "intermediate files.",
+ )
+
+ parser.add_argument(
+ "-e",
+ "--skip-condition-cache",
+ dest="skip_condition_cache",
+ action="store_true",
+ help="Don't use condition simplifier cache (conversion speed may decrease).",
+ )
+
+ parser.add_argument(
+ "--skip-subdirs-project",
+ dest="skip_subdirs_project",
+ action="store_true",
+ help="Skip converting project if it ends up being a TEMPLATE=subdirs project.",
+ )
+
+ parser.add_argument(
+ "-i",
+ "--ignore-skip-marker",
+ dest="ignore_skip_marker",
+ action="store_true",
+ help="If set, pro file will be converted even if skip marker is found in CMakeLists.txt.",
+ )
+
+ parser.add_argument(
+ "--api-version",
+ dest="api_version",
+ type=int,
+ help="Specify which cmake api version should be generated. 1 or 2, 2 is latest.",
+ )
+
+ parser.add_argument(
+ "files",
+ metavar="<.pro/.pri file>",
+ type=str,
+ nargs="+",
+ help="The .pro/.pri file to process",
+ )
+ return parser.parse_args()
+
+
+def is_top_level_repo_project(project_file_path: str = "") -> bool:
+ qmake_conf_path = find_qmake_conf(project_file_path)
+ qmake_conf_dir_path = os.path.dirname(qmake_conf_path)
+ project_dir_path = os.path.dirname(project_file_path)
+ return qmake_conf_dir_path == project_dir_path
+
+
+def is_top_level_repo_tests_project(project_file_path: str = "") -> bool:
+ qmake_conf_path = find_qmake_conf(project_file_path)
+ qmake_conf_dir_path = os.path.dirname(qmake_conf_path)
+ project_dir_path = os.path.dirname(project_file_path)
+ project_dir_name = os.path.basename(project_dir_path)
+ maybe_same_level_dir_path = os.path.join(project_dir_path, "..")
+ normalized_maybe_same_level_dir_path = os.path.normpath(maybe_same_level_dir_path)
+ return (
+ qmake_conf_dir_path == normalized_maybe_same_level_dir_path and project_dir_name == "tests"
+ )
+
+
+def is_top_level_repo_examples_project(project_file_path: str = "") -> bool:
+ qmake_conf_path = find_qmake_conf(project_file_path)
+ qmake_conf_dir_path = os.path.dirname(qmake_conf_path)
+ project_dir_path = os.path.dirname(project_file_path)
+ project_dir_name = os.path.basename(project_dir_path)
+ maybe_same_level_dir_path = os.path.join(project_dir_path, "..")
+ normalized_maybe_same_level_dir_path = os.path.normpath(maybe_same_level_dir_path)
+ return (
+ qmake_conf_dir_path == normalized_maybe_same_level_dir_path
+ and project_dir_name == "examples"
+ )
+
+
+def is_example_project(project_file_path: str = "") -> bool:
+ qmake_conf_path = find_qmake_conf(project_file_path)
+ qmake_conf_dir_path = os.path.dirname(qmake_conf_path)
+
+ project_relative_path = os.path.relpath(project_file_path, qmake_conf_dir_path)
+ # If the project file is found in a subdir called 'examples'
+ # relative to the repo source dir, then it must be an example, but
+ # some examples contain 3rdparty libraries that do not need to be
+ # built as examples.
+ return project_relative_path.startswith("examples") and "3rdparty" not in project_relative_path
+
+
+def is_config_test_project(project_file_path: str = "") -> bool:
+ qmake_conf_path = find_qmake_conf(project_file_path)
+ qmake_conf_dir_path = os.path.dirname(qmake_conf_path)
+ dir_name_with_qmake_confg = os.path.basename(qmake_conf_dir_path)
+
+ project_relative_path = os.path.relpath(project_file_path, qmake_conf_dir_path)
+ # If the project file is found in a subdir called 'config.tests'
+ # relative to the repo source dir, then it's probably a config test.
+ # Also if the .qmake.conf is found within config.tests dir (like in qtbase)
+ # then the project is probably a config .test
+ return (
+ project_relative_path.startswith("config.tests")
+ or dir_name_with_qmake_confg == "config.tests"
+ )
+
+
+def is_benchmark_project(project_file_path: str = "") -> bool:
+ qmake_conf_path = find_qmake_conf(project_file_path)
+ qmake_conf_dir_path = os.path.dirname(qmake_conf_path)
+
+ project_relative_path = os.path.relpath(project_file_path, qmake_conf_dir_path)
+ # If the project file is found in a subdir called 'tests/benchmarks'
+ # relative to the repo source dir, then it must be a benchmark
+ return project_relative_path.startswith("tests/benchmarks")
+
+
+def is_manual_test_project(project_file_path: str = "") -> bool:
+ qmake_conf_path = find_qmake_conf(project_file_path)
+ qmake_conf_dir_path = os.path.dirname(qmake_conf_path)
+
+ project_relative_path = os.path.relpath(project_file_path, qmake_conf_dir_path)
+ # If the project file is found in a subdir called 'tests/manual'
+ # relative to the repo source dir, then it must be a manual test
+ return project_relative_path.startswith("tests/manual")
+
+
+@lru_cache(maxsize=None)
+def find_qmake_conf(project_file_path: str = "") -> str:
+ if not os.path.isabs(project_file_path):
+ print(
+ f"Warning: could not find .qmake.conf file, given path is not an "
+ f"absolute path: {project_file_path}"
+ )
+ return ""
+
+ cwd = os.path.dirname(project_file_path)
+ file_name = ".qmake.conf"
+
+ while os.path.isdir(cwd):
+ maybe_file = posixpath.join(cwd, file_name)
+ if os.path.isfile(maybe_file):
+ return maybe_file
+ else:
+ cwd = os.path.dirname(cwd)
+
+ print(f"Warning: could not find .qmake.conf file")
+ return ""
+
+
+def set_up_cmake_api_calls():
+ def nested_dict():
+ return defaultdict(nested_dict)
+
+ api = nested_dict()
+
+ api[1]["qt_extend_target"] = "extend_target"
+ api[1]["qt_add_module"] = "add_qt_module"
+ api[1]["qt_add_plugin"] = "add_qt_plugin"
+ api[1]["qt_add_tool"] = "add_qt_tool"
+ api[1]["qt_add_test"] = "add_qt_test"
+ api[1]["qt_add_test_helper"] = "add_qt_test_helper"
+ api[1]["qt_add_manual_test"] = "add_qt_manual_test"
+ api[1]["qt_add_benchmark"] = "add_qt_benchmark"
+ api[1]["qt_add_executable"] = "add_qt_executable"
+ api[1]["qt_add_simd_part"] = "add_qt_simd_part"
+ api[1]["qt_add_docs"] = "add_qt_docs"
+ api[1]["qt_add_resource"] = "add_qt_resource"
+ api[1]["qt_add_qml_module"] = "add_qml_module"
+ api[1]["qt_add_cmake_library"] = "add_cmake_library"
+
+ api[2]["qt_extend_target"] = "qt_extend_target"
+ api[2]["qt_add_module"] = "qt_add_module"
+ api[2]["qt_add_plugin"] = "qt_add_plugin"
+ api[2]["qt_add_tool"] = "qt_add_tool"
+ api[2]["qt_add_test"] = "qt_add_test"
+ api[2]["qt_add_test_helper"] = "qt_add_test_helper"
+ api[2]["qt_add_manual_test"] = "qt_add_manual_test"
+ api[2]["qt_add_benchmark"] = "qt_add_benchmark"
+ api[2]["qt_add_executable"] = "qt_add_executable"
+ api[2]["qt_add_simd_part"] = "qt_add_simd_part"
+ api[2]["qt_add_docs"] = "qt_add_docs"
+ api[2]["qt_add_resource"] = "qt_add_resource"
+ api[2]["qt_add_qml_module"] = "qt_add_qml_module"
+ api[2]["qt_add_cmake_library"] = "qt_add_cmake_library"
+
+ return api
+
+
+cmake_api_calls = set_up_cmake_api_calls()
+
+
+def detect_cmake_api_version_used_in_file_content(project_file_path: str) -> Optional[int]:
+ dir_path = os.path.dirname(project_file_path)
+ cmake_project_path = os.path.join(dir_path, "CMakeLists.txt")
+
+ # If file doesn't exist, None implies default version selected by
+ # script.
+ if not os.path.exists(cmake_project_path):
+ return None
+
+ with open(cmake_project_path, "r") as file_fd:
+ contents = file_fd.read()
+
+ new_api_calls = [api_call for api_call in cmake_api_calls[2]]
+ new_api_calls_alternatives = "|".join(new_api_calls)
+ match = re.search(new_api_calls_alternatives, contents)
+
+ # If new style found, return latest api version. Otherwise
+ # the old version.
+ if match:
+ return 2
+ else:
+ return 1
+
+
+def get_cmake_api_call(api_name: str, api_version: Optional[int] = None) -> str:
+ if not api_version:
+ global cmake_api_version
+ api_version = cmake_api_version
+ if not cmake_api_calls[api_version][api_name]:
+ raise RuntimeError(f"No CMake API call {api_name} of version {api_version} found.")
+
+ return cmake_api_calls[api_version][api_name]
+
+
+def process_qrc_file(
+ target: str,
+ filepath: str,
+ base_dir: str = "",
+ project_file_path: str = "",
+ skip_qtquick_compiler: bool = False,
+ retain_qtquick_compiler: bool = False,
+ is_example: bool = False,
+) -> str:
+ assert target
+
+ # Hack to handle QT_SOURCE_TREE. Assume currently that it's the same
+ # as the qtbase source path.
+ qt_source_tree_literal = "${QT_SOURCE_TREE}"
+ if qt_source_tree_literal in filepath:
+ qmake_conf = find_qmake_conf(project_file_path)
+
+ if qmake_conf:
+ qt_source_tree = os.path.dirname(qmake_conf)
+ filepath = filepath.replace(qt_source_tree_literal, qt_source_tree)
+ else:
+ print(
+ f"Warning, could not determine QT_SOURCE_TREE location while trying "
+ f"to find: {filepath}"
+ )
+
+ resource_name = os.path.splitext(os.path.basename(filepath))[0]
+ dir_name = os.path.dirname(filepath)
+ base_dir = posixpath.join("" if base_dir == "." else base_dir, dir_name)
+
+ # Small not very thorough check to see if this a shared qrc resource
+ # pattern is mostly used by the tests.
+ is_parent_path = dir_name.startswith("..")
+ if not os.path.isfile(filepath):
+ raise RuntimeError(f"Invalid file path given to process_qrc_file: {filepath}")
+
+ tree = ET.parse(filepath)
+ root = tree.getroot()
+ assert root.tag == "RCC"
+
+ output = ""
+
+ resource_count = 0
+ for resource in root:
+ assert resource.tag == "qresource"
+ lang = resource.get("lang", "")
+ prefix = resource.get("prefix", "/")
+ if not prefix.startswith("/"):
+ prefix = f"/{prefix}"
+
+ full_resource_name = resource_name + (str(resource_count) if resource_count > 0 else "")
+
+ files: Dict[str, str] = {}
+ for file in resource:
+ path = file.text
+ assert path
+
+ # Get alias:
+ alias = file.get("alias", "")
+ # In cases where examples use shared resources, we set the alias
+ # too the same name of the file, or the applications won't be
+ # be able to locate the resource
+ if not alias and is_parent_path:
+ alias = path
+ files[path] = alias
+
+ output += write_add_qt_resource_call(
+ target,
+ full_resource_name,
+ prefix,
+ base_dir,
+ lang,
+ files,
+ skip_qtquick_compiler,
+ retain_qtquick_compiler,
+ is_example,
+ )
+ resource_count += 1
+
+ return output
+
+
+def write_add_qt_resource_call(
+ target: str,
+ resource_name: str,
+ prefix: Optional[str],
+ base_dir: str,
+ lang: Optional[str],
+ files: Dict[str, str],
+ skip_qtquick_compiler: bool,
+ retain_qtquick_compiler: bool,
+ is_example: bool,
+) -> str:
+ output = ""
+
+ sorted_files = sorted(files.keys())
+
+ assert sorted_files
+
+ for source in sorted_files:
+ alias = files[source]
+ if alias:
+ full_source = posixpath.join(base_dir, source)
+ output += dedent(
+ f"""\
+ set_source_files_properties("{full_source}"
+ PROPERTIES QT_RESOURCE_ALIAS "{alias}"
+ )
+ """
+ )
+
+ # Quote file paths in case there are spaces.
+ sorted_files_backup = sorted_files
+ sorted_files = []
+ for source in sorted_files_backup:
+ if source.startswith("${"):
+ sorted_files.append(source)
+ else:
+ sorted_files.append(f'"{source}"')
+
+ file_list = "\n ".join(sorted_files)
+ output += dedent(
+ f"""\
+ set({resource_name}_resource_files
+ {file_list}
+ )\n
+ """
+ )
+ file_list = f"${{{resource_name}_resource_files}}"
+ if skip_qtquick_compiler:
+ output += (
+ f"set_source_files_properties(${{{resource_name}_resource_files}}"
+ " PROPERTIES QT_SKIP_QUICKCOMPILER 1)\n\n"
+ )
+
+ if retain_qtquick_compiler:
+ output += (
+ f"set_source_files_properties(${{{resource_name}_resource_files}}"
+ "PROPERTIES QT_RETAIN_QUICKCOMPILER 1)\n\n"
+ )
+
+ params = ""
+ if lang:
+ params += f'{spaces(1)}LANG\n{spaces(2)}"{lang}"\n'
+ params += f'{spaces(1)}PREFIX\n{spaces(2)}"{prefix}"\n'
+ if base_dir:
+ params += f'{spaces(1)}BASE\n{spaces(2)}"{base_dir}"\n'
+ add_resource_command = ""
+ if is_example:
+ add_resource_command = "qt6_add_resources"
+ else:
+ add_resource_command = get_cmake_api_call("qt_add_resource")
+ output += (
+ f'{add_resource_command}({target} "{resource_name}"\n{params}{spaces(1)}FILES\n'
+ f"{spaces(2)}{file_list}\n)\n"
+ )
+
+ return output
+
+
+class QmlDirFileInfo:
+ def __init__(self, file_path: str, type_name: str) -> None:
+ self.file_path = file_path
+ self.version = ""
+ self.type_name = type_name
+ self.internal = False
+ self.singleton = False
+ self.path = ""
+
+
+class QmlDir:
+ def __init__(self) -> None:
+ self.module = ""
+ self.plugin_name = ""
+ self.plugin_path = ""
+ self.classname = ""
+ self.imports: List[str] = []
+ self.type_names: Dict[str, QmlDirFileInfo] = {}
+ self.type_infos: List[str] = []
+ self.depends: List[Tuple[str, str]] = []
+ self.designer_supported = False
+
+ def __str__(self) -> str:
+ type_infos_line = " \n".join(self.type_infos)
+ imports_line = " \n".join(self.imports)
+ string = f"""\
+ module: {self.module}
+ plugin: {self.plugin_name} {self.plugin_path}
+ classname: {self.classname}
+ type_infos:{type_infos_line}
+ imports:{imports_line}
+ dependends:
+ """
+ for dep in self.depends:
+ string += f" {dep[0]} {dep[1]}\n"
+ string += f"designer supported: {self.designer_supported}\n"
+ string += "type_names:\n"
+ for key in self.type_names:
+ file_info = self.type_names[key]
+ string += (
+ f" type:{file_info.type_name} "
+ f"version:{file_info.version} "
+ f"path:{file_info.file_path} "
+ f"internal:{file_info.internal} "
+ f"singleton:{file_info.singleton}\n"
+ )
+ return string
+
+ def get_or_create_file_info(self, path: str, type_name: str) -> QmlDirFileInfo:
+ if path not in self.type_names:
+ self.type_names[path] = QmlDirFileInfo(path, type_name)
+ qmldir_file = self.type_names[path]
+ if qmldir_file.type_name != type_name:
+ raise RuntimeError("Registered qmldir file type_name does not match.")
+ return qmldir_file
+
+ def handle_file_internal(self, type_name: str, path: str):
+ qmldir_file = self.get_or_create_file_info(path, type_name)
+ qmldir_file.internal = True
+
+ def handle_file_singleton(self, type_name: str, version: str, path: str):
+ qmldir_file = self.handle_file(type_name, version, path)
+ qmldir_file.singleton = True
+
+ def handle_file(self, type_name: str, version: str, path: str) -> QmlDirFileInfo:
+ qmldir_file = self.get_or_create_file_info(path, type_name)
+ qmldir_file.version = version
+ qmldir_file.type_name = type_name
+ qmldir_file.path = path
+ return qmldir_file
+
+ def from_lines(self, lines: [str]):
+ for line in lines:
+ self.handle_line(line)
+
+ def from_file(self, path: str):
+ f = open(path, "r")
+ if not f:
+ raise RuntimeError(f"Failed to open qmldir file at: {path}")
+ for line in f:
+ self.handle_line(line)
+
+ def handle_line(self, line: str):
+ if line.startswith("#"):
+ return
+ line = line.strip().replace("\n", "")
+ if len(line) == 0:
+ return
+
+ entries = line.split(" ")
+ if len(entries) == 0:
+ raise RuntimeError("Unexpected QmlDir file line entry")
+ if entries[0] == "module":
+ self.module = entries[1]
+ elif entries[0] == "[singleton]":
+ self.handle_file_singleton(entries[1], entries[2], entries[3])
+ elif entries[0] == "internal":
+ self.handle_file_internal(entries[1], entries[2])
+ elif entries[0] == "plugin":
+ self.plugin_name = entries[1]
+ if len(entries) > 2:
+ self.plugin_path = entries[2]
+ elif entries[0] == "classname":
+ self.classname = entries[1]
+ elif entries[0] == "typeinfo":
+ self.type_infos.append(entries[1])
+ elif entries[0] == "depends":
+ self.depends.append((entries[1], entries[2]))
+ elif entries[0] == "designersupported":
+ self.designer_supported = True
+ elif entries[0] == "import":
+ self.imports.append(entries[1])
+ elif len(entries) == 3:
+ self.handle_file(entries[0], entries[1], entries[2])
+ else:
+ raise RuntimeError(f"Uhandled qmldir entry {line}")
+
+
+def spaces(indent: int) -> str:
+ return " " * indent
+
+
+def trim_leading_dot(file: str) -> str:
+ while file.startswith("./"):
+ file = file[2:]
+ return file
+
+
+def map_to_file(f: str, scope: Scope, *, is_include: bool = False) -> str:
+ assert "$$" not in f
+
+ if f.startswith("${"): # Some cmake variable is prepended
+ return f
+
+ base_dir = scope.currentdir if is_include else scope.basedir
+ f = posixpath.join(base_dir, f)
+
+ return trim_leading_dot(f)
+
+
+def handle_vpath(source: str, base_dir: str, vpath: List[str]) -> str:
+ assert "$$" not in source
+
+ if not source:
+ return ""
+
+ if not vpath:
+ return source
+
+ if os.path.exists(os.path.join(base_dir, source)):
+ return source
+
+ variable_pattern = re.compile(r"\$\{[A-Za-z0-9_]+\}")
+ match = re.match(variable_pattern, source)
+ if match:
+ # a complex, variable based path, skipping validation
+ # or resolving
+ return source
+
+ for v in vpath:
+ fullpath = posixpath.join(v, source)
+ if os.path.exists(fullpath):
+ return trim_leading_dot(posixpath.relpath(fullpath, base_dir))
+
+ print(f" XXXX: Source {source}: Not found.")
+ return f"{source}-NOTFOUND"
+
+
+class Operation:
+ def __init__(self, value: Union[List[str], str], line_no: int = -1) -> None:
+ if isinstance(value, list):
+ self._value = value
+ else:
+ self._value = [str(value)]
+ self._line_no = line_no
+
+ def process(
+ self, key: str, sinput: List[str], transformer: Callable[[List[str]], List[str]]
+ ) -> List[str]:
+ assert False
+
+ def __repr__(self):
+ assert False
+
+ def _dump(self):
+ if not self._value:
+ return "<NOTHING>"
+
+ if not isinstance(self._value, list):
+ return "<NOT A LIST>"
+
+ result = []
+ for i in self._value:
+ if not i:
+ result.append("<NONE>")
+ else:
+ result.append(str(i))
+ return '"' + '", "'.join(result) + '"'
+
+
+class AddOperation(Operation):
+ def process(
+ self, key: str, sinput: List[str], transformer: Callable[[List[str]], List[str]]
+ ) -> List[str]:
+ return sinput + transformer(self._value)
+
+ def __repr__(self):
+ return f"+({self._dump()})"
+
+
+class UniqueAddOperation(Operation):
+ def process(
+ self, key: str, sinput: List[str], transformer: Callable[[List[str]], List[str]]
+ ) -> List[str]:
+ result = sinput
+ for v in transformer(self._value):
+ if v not in result:
+ result.append(v)
+ return result
+
+ def __repr__(self):
+ return f"*({self._dump()})"
+
+
+class ReplaceOperation(Operation):
+ def process(
+ self, key: str, sinput: List[str], transformer: Callable[[List[str]], List[str]]
+ ) -> List[str]:
+ result = []
+ for s in sinput:
+ for v in transformer(self._value):
+ pattern, replacement = self.split_rex(v)
+ result.append(re.sub(pattern, replacement, s))
+ return result
+
+ def split_rex(self, s):
+ pattern = ""
+ replacement = ""
+ if len(s) < 4:
+ return pattern, replacement
+ sep = s[1]
+ s = s[2:]
+ rex = re.compile(f"[^\\\\]{sep}")
+ m = rex.search(s)
+ if not m:
+ return pattern, replacement
+ pattern = s[: m.start() + 1]
+ replacement = s[m.end() :]
+ m = rex.search(replacement)
+ if m:
+ replacement = replacement[: m.start() + 1]
+ return pattern, replacement
+
+ def __repr__(self):
+ return f"*({self._dump()})"
+
+
+class SetOperation(Operation):
+ def process(
+ self, key: str, sinput: List[str], transformer: Callable[[List[str]], List[str]]
+ ) -> List[str]:
+ values = [] # List[str]
+ for v in self._value:
+ if v != f"$${key}":
+ values.append(v)
+ else:
+ values += sinput
+
+ if transformer:
+ return list(transformer(values))
+ else:
+ return values
+
+ def __repr__(self):
+ return f"=({self._dump()})"
+
+
+class RemoveOperation(Operation):
+ def process(
+ self, key: str, sinput: List[str], transformer: Callable[[List[str]], List[str]]
+ ) -> List[str]:
+ sinput_set = set(sinput)
+ value_set = set(self._value)
+ result: List[str] = []
+
+ # Add everything that is not going to get removed:
+ for v in sinput:
+ if v not in value_set:
+ result += [v]
+
+ # Add everything else with removal marker:
+ for v in transformer(self._value):
+ if v not in sinput_set:
+ result += [f"-{v}"]
+
+ return result
+
+ def __repr__(self):
+ return f"-({self._dump()})"
+
+
+# Helper class that stores a list of tuples, representing a scope id and
+# a line number within that scope's project file. The whole list
+# represents the full path location for a certain operation while
+# traversing include()'d scopes. Used for sorting when determining
+# operation order when evaluating operations.
+class OperationLocation(object):
+ def __init__(self):
+ self.list_of_scope_ids_and_line_numbers = []
+
+ def clone_and_append(self, scope_id: int, line_number: int) -> OperationLocation:
+ new_location = OperationLocation()
+ new_location.list_of_scope_ids_and_line_numbers = list(
+ self.list_of_scope_ids_and_line_numbers
+ )
+ new_location.list_of_scope_ids_and_line_numbers.append((scope_id, line_number))
+ return new_location
+
+ def __lt__(self, other: OperationLocation) -> Any:
+ return self.list_of_scope_ids_and_line_numbers < other.list_of_scope_ids_and_line_numbers
+
+ def __repr__(self) -> str:
+ s = ""
+ for t in self.list_of_scope_ids_and_line_numbers:
+ s += f"s{t[0]}:{t[1]} "
+ s = s.strip(" ")
+ return s
+
+
+class Scope(object):
+
+ SCOPE_ID: int = 1
+
+ def __init__(
+ self,
+ *,
+ parent_scope: Optional[Scope],
+ qmake_file: str,
+ condition: str = "",
+ base_dir: str = "",
+ operations: Union[Dict[str, List[Operation]], None] = None,
+ parent_include_line_no: int = -1,
+ ) -> None:
+ if not operations:
+ operations = {
+ "QT_SOURCE_TREE": [SetOperation(["${QT_SOURCE_TREE}"])],
+ "QT_BUILD_TREE": [SetOperation(["${PROJECT_BINARY_DIR}"])],
+ "QTRO_SOURCE_TREE": [SetOperation(["${CMAKE_SOURCE_DIR}"])],
+ }
+
+ self._operations: Dict[str, List[Operation]] = copy.deepcopy(operations)
+ if parent_scope:
+ parent_scope._add_child(self)
+ else:
+ self._parent = None # type: Optional[Scope]
+ # Only add the "QT = core gui" Set operation once, on the
+ # very top-level .pro scope, aka it's basedir is empty.
+ if not base_dir:
+ self._operations["QT"] = [SetOperation(["core", "gui"])]
+
+ self._basedir = base_dir
+ if qmake_file:
+ self._currentdir = os.path.dirname(qmake_file) or "."
+ if not self._basedir:
+ self._basedir = self._currentdir
+
+ self._scope_id = Scope.SCOPE_ID
+ Scope.SCOPE_ID += 1
+ self._file = qmake_file
+ self._file_absolute_path = os.path.abspath(qmake_file)
+ self._condition = map_condition(condition)
+ self._children = [] # type: List[Scope]
+ self._included_children = [] # type: List[Scope]
+ self._visited_keys = set() # type: Set[str]
+ self._total_condition = None # type: Optional[str]
+ self._parent_include_line_no = parent_include_line_no
+
+ def __repr__(self):
+ return (
+ f"{self._scope_id}:{self._basedir}:{self._currentdir}:{self._file}:"
+ f"{self._condition or '<TRUE>'}"
+ )
+
+ def reset_visited_keys(self):
+ self._visited_keys = set()
+
+ def merge(self, other: "Scope") -> None:
+ assert self != other
+ self._included_children.append(other)
+
+ @property
+ def scope_debug(self) -> bool:
+ merge = self.get_string("PRO2CMAKE_SCOPE_DEBUG").lower()
+ return merge == "1" or merge == "on" or merge == "yes" or merge == "true"
+
+ @property
+ def parent(self) -> Optional[Scope]:
+ return self._parent
+
+ @property
+ def basedir(self) -> str:
+ return self._basedir
+
+ @property
+ def currentdir(self) -> str:
+ return self._currentdir
+
+ def can_merge_condition(self):
+ if self._condition == "else":
+ return False
+ if self._operations:
+ return False
+
+ child_count = len(self._children)
+ if child_count == 0 or child_count > 2:
+ return False
+ assert child_count != 1 or self._children[0]._condition != "else"
+ return child_count == 1 or self._children[1]._condition == "else"
+
+ def settle_condition(self):
+ new_children: List[Scope] = []
+ for c in self._children:
+ c.settle_condition()
+
+ if c.can_merge_condition():
+ child = c._children[0]
+ child._condition = "({c._condition}) AND ({child._condition})"
+ new_children += c._children
+ else:
+ new_children.append(c)
+ self._children = new_children
+
+ @staticmethod
+ def FromDict(
+ parent_scope: Optional["Scope"],
+ file: str,
+ statements,
+ cond: str = "",
+ base_dir: str = "",
+ project_file_content: str = "",
+ parent_include_line_no: int = -1,
+ ) -> Scope:
+ scope = Scope(
+ parent_scope=parent_scope,
+ qmake_file=file,
+ condition=cond,
+ base_dir=base_dir,
+ parent_include_line_no=parent_include_line_no,
+ )
+ for statement in statements:
+ if isinstance(statement, list): # Handle skipped parts...
+ assert not statement
+ continue
+
+ operation = statement.get("operation", None)
+ if operation:
+ key = statement.get("key", "")
+ value = statement.get("value", [])
+ assert key != ""
+
+ op_location_start = operation["locn_start"]
+ operation = operation["value"]
+ op_line_no = pp.lineno(op_location_start, project_file_content)
+
+ if operation == "=":
+ scope._append_operation(key, SetOperation(value, line_no=op_line_no))
+ elif operation == "-=":
+ scope._append_operation(key, RemoveOperation(value, line_no=op_line_no))
+ elif operation == "+=":
+ scope._append_operation(key, AddOperation(value, line_no=op_line_no))
+ elif operation == "*=":
+ scope._append_operation(key, UniqueAddOperation(value, line_no=op_line_no))
+ elif operation == "~=":
+ scope._append_operation(key, ReplaceOperation(value, line_no=op_line_no))
+ else:
+ print(f'Unexpected operation "{operation}" in scope "{scope}".')
+ assert False
+
+ continue
+
+ condition = statement.get("condition", None)
+ if condition:
+ Scope.FromDict(scope, file, statement.get("statements"), condition, scope.basedir)
+
+ else_statements = statement.get("else_statements")
+ if else_statements:
+ Scope.FromDict(scope, file, else_statements, "else", scope.basedir)
+ continue
+
+ loaded = statement.get("loaded")
+ if loaded:
+ scope._append_operation("_LOADED", UniqueAddOperation(loaded))
+ continue
+
+ option = statement.get("option", None)
+ if option:
+ scope._append_operation("_OPTION", UniqueAddOperation(option))
+ continue
+
+ included = statement.get("included", None)
+ if included:
+ included_location_start = included["locn_start"]
+ included = included["value"]
+ included_line_no = pp.lineno(included_location_start, project_file_content)
+ scope._append_operation(
+ "_INCLUDED", UniqueAddOperation(included, line_no=included_line_no)
+ )
+ continue
+
+ project_required_condition = statement.get("project_required_condition")
+ if project_required_condition:
+ scope._append_operation("_REQUIREMENTS", AddOperation(project_required_condition))
+
+ scope.settle_condition()
+
+ if scope.scope_debug:
+ print(f"..... [SCOPE_DEBUG]: Created scope {scope}:")
+ scope.dump(indent=1)
+ print("..... [SCOPE_DEBUG]: <<END OF SCOPE>>")
+ return scope
+
+ def _append_operation(self, key: str, op: Operation) -> None:
+ if key in self._operations:
+ self._operations[key].append(op)
+ else:
+ self._operations[key] = [op]
+
+ @property
+ def file(self) -> str:
+ return self._file or ""
+
+ @property
+ def file_absolute_path(self) -> str:
+ return self._file_absolute_path or ""
+
+ @property
+ def generated_cmake_lists_path(self) -> str:
+ assert self.basedir
+ return os.path.join(self.basedir, "CMakeLists.gen.txt")
+
+ @property
+ def original_cmake_lists_path(self) -> str:
+ assert self.basedir
+ return os.path.join(self.basedir, "CMakeLists.txt")
+
+ @property
+ def condition(self) -> str:
+ return self._condition
+
+ @property
+ def total_condition(self) -> Optional[str]:
+ return self._total_condition
+
+ @total_condition.setter
+ def total_condition(self, condition: str) -> None:
+ self._total_condition = condition
+
+ def _add_child(self, scope: "Scope") -> None:
+ scope._parent = self
+ self._children.append(scope)
+
+ @property
+ def children(self) -> List["Scope"]:
+ result = list(self._children)
+ for include_scope in self._included_children:
+ result += include_scope.children
+ return result
+
+ def dump(self, *, indent: int = 0) -> None:
+ ind = spaces(indent)
+ print(f'{ind}Scope "{self}":')
+ if self.total_condition:
+ print(f"{ind} Total condition = {self.total_condition}")
+ print(f"{ind} Keys:")
+ keys = self._operations.keys()
+ if not keys:
+ print(f"{ind} -- NONE --")
+ else:
+ for k in sorted(keys):
+ print(f'{ind} {k} = "{self._operations.get(k, [])}"')
+ print(f"{ind} Children:")
+ if not self._children:
+ print(f"{ind} -- NONE --")
+ else:
+ for c in self._children:
+ c.dump(indent=indent + 1)
+ print(f"{ind} Includes:")
+ if not self._included_children:
+ print(f"{ind} -- NONE --")
+ else:
+ for c in self._included_children:
+ c.dump(indent=indent + 1)
+
+ def dump_structure(self, *, structure_type: str = "ROOT", indent: int = 0) -> None:
+ print(f"{spaces(indent)}{structure_type}: {self}")
+ for i in self._included_children:
+ i.dump_structure(structure_type="INCL", indent=indent + 1)
+ for i in self._children:
+ i.dump_structure(structure_type="CHLD", indent=indent + 1)
+
+ @property
+ def keys(self):
+ return self._operations.keys()
+
+ @property
+ def visited_keys(self):
+ return self._visited_keys
+
+ # Traverses a scope and its children, and collects operations
+ # that need to be processed for a certain key.
+ def _gather_operations_from_scope(
+ self,
+ operations_result: List[Dict[str, Any]],
+ current_scope: Scope,
+ op_key: str,
+ current_location: OperationLocation,
+ ):
+ for op in current_scope._operations.get(op_key, []):
+ new_op_location = current_location.clone_and_append(
+ current_scope._scope_id, op._line_no
+ )
+ op_info: Dict[str, Any] = {}
+ op_info["op"] = op
+ op_info["scope"] = current_scope
+ op_info["location"] = new_op_location
+ operations_result.append(op_info)
+
+ for included_child in current_scope._included_children:
+ new_scope_location = current_location.clone_and_append(
+ current_scope._scope_id, included_child._parent_include_line_no
+ )
+ self._gather_operations_from_scope(
+ operations_result, included_child, op_key, new_scope_location
+ )
+
+ # Partially applies a scope argument to a given transformer.
+ @staticmethod
+ def _create_transformer_for_operation(
+ given_transformer: Optional[Callable[[Scope, List[str]], List[str]]],
+ transformer_scope: Scope,
+ ) -> Callable[[List[str]], List[str]]:
+ if given_transformer:
+
+ def wrapped_transformer(values):
+ return given_transformer(transformer_scope, values)
+
+ else:
+
+ def wrapped_transformer(values):
+ return values
+
+ return wrapped_transformer
+
+ def _evalOps(
+ self,
+ key: str,
+ transformer: Optional[Callable[[Scope, List[str]], List[str]]],
+ result: List[str],
+ *,
+ inherit: bool = False,
+ ) -> List[str]:
+ self._visited_keys.add(key)
+
+ # Inherit values from parent scope.
+ # This is a strange edge case which is wrong in principle, because
+ # .pro files are imperative and not declarative. Nevertheless
+ # this fixes certain mappings (e.g. for handling
+ # VERSIONTAGGING_SOURCES in src/corelib/global/global.pri).
+ if self._parent and inherit:
+ result = self._parent._evalOps(key, transformer, result)
+
+ operations_to_run: List[Dict[str, Any]] = []
+ starting_location = OperationLocation()
+ starting_scope = self
+ self._gather_operations_from_scope(
+ operations_to_run, starting_scope, key, starting_location
+ )
+
+ # Sorts the operations based on the location of each operation. Technically compares two
+ # lists of tuples.
+ operations_to_run = sorted(operations_to_run, key=lambda o: o["location"])
+
+ # Process the operations.
+ for op_info in operations_to_run:
+ op_transformer = self._create_transformer_for_operation(transformer, op_info["scope"])
+ result = op_info["op"].process(key, result, op_transformer)
+ return result
+
+ def get(self, key: str, *, ignore_includes: bool = False, inherit: bool = False) -> List[str]:
+ is_same_path = self.currentdir == self.basedir
+ if not is_same_path:
+ relative_path = os.path.relpath(self.currentdir, self.basedir)
+
+ if key == "QQC2_SOURCE_TREE":
+ qmake_conf_path = find_qmake_conf(os.path.abspath(self.currentdir))
+ qmake_conf_dir_path = os.path.dirname(qmake_conf_path)
+ project_relative_path = os.path.relpath(qmake_conf_dir_path, self.currentdir)
+ return ["${CMAKE_CURRENT_SOURCE_DIR}/" + project_relative_path]
+
+ if key == "QT_ARCH":
+ return ["${CMAKE_SYSTEM_PROCESSOR}"]
+
+ if key == "_PRO_FILE_PWD_":
+ return ["${CMAKE_CURRENT_SOURCE_DIR}"]
+ if key == "PWD":
+ if is_same_path:
+ return ["${CMAKE_CURRENT_SOURCE_DIR}"]
+ else:
+ return [f"${{CMAKE_CURRENT_SOURCE_DIR}}/{relative_path}"]
+ if key == "OUT_PWD":
+ if is_same_path:
+ return ["${CMAKE_CURRENT_BINARY_DIR}"]
+ else:
+ return [f"${{CMAKE_CURRENT_BINARY_DIR}}/{relative_path}"]
+
+ return self._evalOps(key, None, [], inherit=inherit)
+
+ def get_string(self, key: str, default: str = "", inherit: bool = False) -> str:
+ v = self.get(key, inherit=inherit)
+ if len(v) == 0:
+ return default
+ assert len(v) == 1
+ return v[0]
+
+ def _map_files(
+ self, files: List[str], *, use_vpath: bool = True, is_include: bool = False
+ ) -> List[str]:
+
+ expanded_files = [] # type: List[str]
+ for f in files:
+ r = self._expand_value(f)
+ expanded_files += r
+
+ mapped_files = list(
+ map(lambda f: map_to_file(f, self, is_include=is_include), expanded_files)
+ )
+
+ if use_vpath:
+ result = list(
+ map(
+ lambda f: handle_vpath(f, self.basedir, self.get("VPATH", inherit=True)),
+ mapped_files,
+ )
+ )
+ else:
+ result = mapped_files
+
+ # strip ${CMAKE_CURRENT_SOURCE_DIR}:
+ result = list(
+ map(lambda f: f[28:] if f.startswith("${CMAKE_CURRENT_SOURCE_DIR}/") else f, result)
+ )
+
+ # strip leading ./:
+ result = list(map(lambda f: trim_leading_dot(f), result))
+
+ return result
+
+ def get_files(
+ self, key: str, *, use_vpath: bool = False, is_include: bool = False
+ ) -> List[str]:
+ def transformer(scope, files):
+ return scope._map_files(files, use_vpath=use_vpath, is_include=is_include)
+
+ return list(self._evalOps(key, transformer, []))
+
+ @staticmethod
+ def _replace_env_var_value(value: Any) -> Any:
+ if not isinstance(value, str):
+ return value
+
+ pattern = re.compile(r"\$\$\(([A-Za-z_][A-Za-z0-9_]*)\)")
+ match = re.search(pattern, value)
+ if match:
+ value = re.sub(pattern, r"$ENV{\1}", value)
+
+ return value
+
+ def _expand_value(self, value: str) -> List[str]:
+ result = value
+ pattern = re.compile(r"\$\$\{?([A-Za-z_][A-Za-z0-9_]*)\}?")
+ match = re.search(pattern, result)
+ while match:
+ old_result = result
+ match_group_0 = match.group(0)
+ if match_group_0 == value:
+ get_result = self.get(match.group(1), inherit=True)
+ if len(get_result) == 1:
+ result = get_result[0]
+ result = self._replace_env_var_value(result)
+ else:
+ # Recursively expand each value from the result list
+ # returned from self.get().
+ result_list: List[str] = []
+ for entry_value in get_result:
+ result_list += self._expand_value(self._replace_env_var_value(entry_value))
+ return result_list
+ else:
+ replacement = self.get(match.group(1), inherit=True)
+ replacement_str = replacement[0] if replacement else ""
+ if replacement_str == value:
+ # we have recursed
+ replacement_str = ""
+ result = result[: match.start()] + replacement_str + result[match.end() :]
+ result = self._replace_env_var_value(result)
+
+ if result == old_result:
+ return [result] # Do not go into infinite loop
+
+ match = re.search(pattern, result)
+
+ result = self._replace_env_var_value(result)
+ return [result]
+
+ def expand(self, key: str) -> List[str]:
+ value = self.get(key)
+ result: List[str] = []
+ assert isinstance(value, list)
+ for v in value:
+ result += self._expand_value(v)
+ return result
+
+ def expandString(self, key: str) -> str:
+ result = self._expand_value(self.get_string(key))
+ assert len(result) == 1
+ return result[0]
+
+ def _get_operation_at_index(self, key, index):
+ return self._operations[key][index]
+
+ @property
+ def TEMPLATE(self) -> str:
+ return self.get_string("TEMPLATE", "app")
+
+ def _rawTemplate(self) -> str:
+ return self.get_string("TEMPLATE")
+
+ @property
+ def TARGET(self) -> str:
+ target = self.expandString("TARGET") or os.path.splitext(os.path.basename(self.file))[0]
+ return re.sub(r"\.\./", "", target)
+
+ @property
+ def TARGET_ORIGINAL(self) -> str:
+ return self.expandString("TARGET") or os.path.splitext(os.path.basename(self.file))[0]
+
+ @property
+ def _INCLUDED(self) -> List[str]:
+ return self.get("_INCLUDED")
+
+
+# Given "if(a|b):c" returns "(a|b):c". Uses pyparsing to keep the parentheses
+# balanced.
+def unwrap_if(input_string):
+ # Compute the grammar only once.
+ if not hasattr(unwrap_if, "if_grammar"):
+
+ def handle_expr_with_parentheses(s, l, t):
+ # The following expression unwraps the condition via the
+ # additional info set by originalTextFor, thus returning the
+ # condition without parentheses.
+ condition_without_parentheses = s[t._original_start + 1 : t._original_end - 1]
+
+ # Re-add the parentheses, but with spaces in-between. This
+ # fixes map_condition -> map_platform to apply properly.
+ condition_with_parentheses = "( " + condition_without_parentheses + " )"
+ return condition_with_parentheses
+
+ expr_with_parentheses = pp.originalTextFor(pp.nestedExpr())
+ expr_with_parentheses.setParseAction(handle_expr_with_parentheses)
+
+ if_keyword = pp.Suppress(pp.Keyword("if"))
+ unwrap_if.if_grammar = if_keyword + expr_with_parentheses
+
+ output_string = unwrap_if.if_grammar.transformString(input_string)
+ return output_string
+
+
+def map_condition(condition: str) -> str:
+ # Some hardcoded cases that are too bothersome to generalize.
+ condition = re.sub(
+ r"qtConfig\(opengles\.\)",
+ r"(QT_FEATURE_opengles2 OR QT_FEATURE_opengles3 OR QT_FEATURE_opengles31 OR QT_FEATURE_opengles32)",
+ condition,
+ )
+ condition = re.sub(
+ r"qtConfig\(opengl\(es1\|es2\)\?\)",
+ r"QT_FEATURE_opengl OR QT_FEATURE_opengles2 OR QT_FEATURE_opengles3",
+ condition,
+ )
+ condition = re.sub(r"qtConfig\(opengl\.\*\)", r"QT_FEATURE_opengl", condition)
+ condition = re.sub(r"^win\*$", r"win", condition)
+ condition = re.sub(r"^no-png$", r"NOT QT_FEATURE_png", condition)
+ condition = re.sub(r"contains\(CONFIG, static\)", r"NOT QT_BUILD_SHARED_LIBS", condition)
+ condition = re.sub(r"contains\(QT_CONFIG,\w*shared\)", r"QT_BUILD_SHARED_LIBS", condition)
+ condition = re.sub(r"CONFIG\(osx\)", r"APPLE_OSX", condition)
+
+ def gcc_version_handler(match_obj: Match):
+ operator = match_obj.group(1)
+ version_type = match_obj.group(2)
+ if operator == "equals":
+ operator = "STREQUAL"
+ elif operator == "greaterThan":
+ operator = "STRGREATER"
+ elif operator == "lessThan":
+ operator = "STRLESS"
+
+ version = match_obj.group(3)
+ return f"(QT_COMPILER_VERSION_{version_type} {operator} {version})"
+
+ # TODO: Possibly fix for other compilers.
+ pattern = r"(equals|greaterThan|lessThan)\(QT_GCC_([A-Z]+)_VERSION,[ ]*([0-9]+)\)"
+ condition = re.sub(pattern, gcc_version_handler, condition)
+
+ def windows_sdk_version_handler(match_obj: Match):
+ operator = match_obj.group(1)
+ if operator == "equals":
+ operator = "STREQUAL"
+ elif operator == "greaterThan":
+ operator = "STRGREATER"
+ elif operator == "lessThan":
+ operator = "STRLESS"
+
+ version = match_obj.group(2)
+ return f"(QT_WINDOWS_SDK_VERSION {operator} {version})"
+
+ pattern = r"(equals|greaterThan|lessThan)\(WINDOWS_SDK_VERSION,[ ]*([0-9]+)\)"
+ condition = re.sub(pattern, windows_sdk_version_handler, condition)
+
+ # Generic lessThan|equals|lessThan()
+
+ def generic_version_handler(match_obj: Match):
+ operator = match_obj.group(1)
+ if operator == "equals":
+ operator = "EQUAL"
+ elif operator == "greaterThan":
+ operator = "GREATER"
+ elif operator == "lessThan":
+ operator = "LESS"
+
+ variable = match_obj.group(2)
+ version = match_obj.group(3)
+ return f"({variable} {operator} {version})"
+
+ pattern = r"(equals|greaterThan|lessThan)\(([^,]+?),[ ]*([0-9]+)\)"
+ condition = re.sub(pattern, generic_version_handler, condition)
+
+ # Handle if(...) conditions.
+ condition = unwrap_if(condition)
+
+ condition = re.sub(r"\bisEmpty\s*\((.*?)\)", r"\1_ISEMPTY", condition)
+ condition = re.sub(
+ r"\bcontains\s*\(\s*(?:QT_)?CONFIG\s*,\s*c\+\+(\d+)\)",
+ r"cxx_std_\1 IN_LIST CMAKE_CXX_COMPILE_FEATURES",
+ condition,
+ )
+ condition = re.sub(r'\bcontains\s*\((.*?),\s*"?(.*?)"?\)', r"\1___contains___\2", condition)
+ condition = re.sub(r'\bequals\s*\((.*?),\s*"?(.*?)"?\)', r"\1___equals___\2", condition)
+ condition = re.sub(r'\bisEqual\s*\((.*?),\s*"?(.*?)"?\)', r"\1___equals___\2", condition)
+ condition = re.sub(r"\s*==\s*", "___STREQUAL___", condition)
+ condition = re.sub(r"\bexists\s*\((.*?)\)", r"EXISTS \1", condition)
+
+ # checking mkspec, predating gcc scope in qmake, will then be replaced by platform_mapping in helper.py
+ condition = condition.replace("*-g++*", "GCC")
+ condition = condition.replace("*g++*", "GCC")
+ condition = condition.replace("aix-g++*", "AIX")
+ condition = condition.replace("*-icc*", "ICC")
+ condition = condition.replace("*-clang*", "CLANG")
+ condition = condition.replace("*-llvm", "CLANG")
+ condition = condition.replace("win32-*", "WIN32")
+
+ pattern = r"CONFIG\((debug|release),debug\|release\)"
+ match_result = re.match(pattern, condition)
+ if match_result:
+ build_type = match_result.group(1)
+ if build_type == "debug":
+ build_type = "Debug"
+ elif build_type == "release":
+ build_type = "Release"
+ condition = re.sub(pattern, f"(CMAKE_BUILD_TYPE STREQUAL {build_type})", condition)
+
+ condition = condition.replace("*", "_x_")
+ condition = condition.replace(".$$", "__ss_")
+ condition = condition.replace("$$", "_ss_")
+
+ condition = condition.replace("!", "NOT ")
+ condition = condition.replace("&&", " AND ")
+ condition = condition.replace("|", " OR ")
+
+ # new conditions added by the android multi arch qmake build
+ condition = re.sub(r"(^| )x86((?=[^\w])|$)", "TEST_architecture_arch STREQUAL i386", condition)
+ condition = re.sub(r"(^| )x86_64", " TEST_architecture_arch STREQUAL x86_64", condition)
+ condition = re.sub(r"(^| )arm64-v8a", "TEST_architecture_arch STREQUAL arm64", condition)
+ condition = re.sub(r"(^| )armeabi-v7a", "TEST_architecture_arch STREQUAL arm", condition)
+
+ # some defines replacements
+ condition = re.sub(r"DEFINES___contains___QT_NO_CURSOR", r"(NOT QT_FEATURE_cursor)", condition)
+ condition = re.sub(
+ r"DEFINES___contains___QT_NO_TRANSLATION", r"(NOT QT_FEATURE_translation)", condition
+ )
+ condition = re.sub(r"styles___contains___fusion", r"QT_FEATURE_style_fusion", condition)
+
+ condition = condition.replace("cross_compile", "CMAKE_CROSSCOMPILING")
+
+ cmake_condition = ""
+ for part in condition.split():
+ # some features contain e.g. linux, that should not be
+ # turned upper case
+ feature = re.match(r"(qtConfig|qtHaveModule)\(([a-zA-Z0-9_-]+)\)", part)
+ if feature:
+ if feature.group(1) == "qtHaveModule":
+ part = f"TARGET {map_qt_library(feature.group(2))}"
+ else:
+ feature_name = featureName(feature.group(2))
+ if feature_name.startswith("system_") and is_known_3rd_party_library(
+ feature_name[7:]
+ ):
+ part = "ON"
+ elif feature == "dlopen":
+ part = "ON"
+ else:
+ part = "QT_FEATURE_" + feature_name
+ else:
+ part = map_platform(part)
+
+ part = part.replace("true", "ON")
+ part = part.replace("false", "OFF")
+ cmake_condition += " " + part
+ return cmake_condition.strip()
+
+
+_path_replacements = {
+ "$$[QT_INSTALL_PREFIX]": "${INSTALL_DIRECTORY}",
+ "$$[QT_INSTALL_EXAMPLES]": "${INSTALL_EXAMPLESDIR}",
+ "$$[QT_INSTALL_TESTS]": "${INSTALL_TESTSDIR}",
+ "$$OUT_PWD": "${CMAKE_CURRENT_BINARY_DIR}",
+}
+
+
+def replace_path_constants(path: str, scope: Scope) -> str:
+ """ Clean up DESTDIR and target.path """
+ if path.startswith("./"):
+ path = f"${{CMAKE_CURRENT_BINARY_DIR}}/{path[2:]}"
+ elif path.startswith("../"):
+ path = f"${{CMAKE_CURRENT_BINARY_DIR}}/{path}"
+ for original, replacement in _path_replacements.items():
+ path = path.replace(original, replacement)
+ path = path.replace("$$TARGET", scope.TARGET)
+ return path
+
+
+def handle_subdir(
+ scope: Scope, cm_fh: IO[str], *, indent: int = 0, is_example: bool = False
+) -> None:
+
+ # Global nested dictionary that will contain sub_dir assignments and their conditions.
+ # Declared as a global in order not to pollute the nested function signatures with giant
+ # type hints.
+ sub_dirs: Dict[str, Dict[str, Set[FrozenSet[str]]]] = {}
+
+ # Collects assignment conditions into global sub_dirs dict.
+ def collect_subdir_info(sub_dir_assignment: str, *, current_conditions: FrozenSet[str] = None):
+ subtraction = sub_dir_assignment.startswith("-")
+ if subtraction:
+ subdir_name = sub_dir_assignment[1:]
+ else:
+ subdir_name = sub_dir_assignment
+ if subdir_name not in sub_dirs:
+ sub_dirs[subdir_name] = {}
+ additions = sub_dirs[subdir_name].get("additions", set())
+ subtractions = sub_dirs[subdir_name].get("subtractions", set())
+ if current_conditions:
+ if subtraction:
+ subtractions.add(current_conditions)
+ else:
+ additions.add(current_conditions)
+ if additions:
+ sub_dirs[subdir_name]["additions"] = additions
+ if subtractions:
+ sub_dirs[subdir_name]["subtractions"] = subtractions
+
+ # Recursive helper that collects subdir info for given scope,
+ # and the children of the given scope.
+ def handle_subdir_helper(
+ scope: Scope,
+ cm_fh: IO[str],
+ *,
+ indent: int = 0,
+ current_conditions: FrozenSet[str] = frozenset(),
+ is_example: bool = False,
+ ):
+ for sd in scope.get_files("SUBDIRS"):
+ # Collect info about conditions and SUBDIR assignments in the
+ # current scope.
+ if os.path.isdir(sd) or sd.startswith("-"):
+ collect_subdir_info(sd, current_conditions=current_conditions)
+ # For the file case, directly write into the file handle.
+ elif os.path.isfile(sd):
+ # Handle cases with SUBDIRS += Foo/bar/z.pro. We want to be able
+ # to generate add_subdirectory(Foo/bar) instead of parsing the full
+ # .pro file in the current CMakeLists.txt. This causes issues
+ # with relative paths in certain projects otherwise.
+ dirname = os.path.dirname(sd)
+ if dirname:
+ collect_subdir_info(dirname, current_conditions=current_conditions)
+ else:
+ subdir_result, project_file_content = parseProFile(sd, debug=False)
+ subdir_scope = Scope.FromDict(
+ scope,
+ sd,
+ subdir_result.asDict().get("statements"),
+ "",
+ scope.basedir,
+ project_file_content=project_file_content,
+ )
+
+ do_include(subdir_scope)
+ cmakeify_scope(subdir_scope, cm_fh, indent=indent, is_example=is_example)
+ else:
+ print(f" XXXX: SUBDIR {sd} in {scope}: Not found.")
+
+ # Collect info about conditions and SUBDIR assignments in child
+ # scopes, aka recursively call the same function, but with an
+ # updated current_conditions frozen set.
+ for c in scope.children:
+ # Use total_condition for 'else' conditions, otherwise just use the regular value to
+ # simplify the logic.
+ child_conditions = current_conditions
+ child_condition = c.total_condition if c.condition == "else" else c.condition
+ if child_condition:
+ child_conditions = frozenset((*child_conditions, child_condition))
+
+ handle_subdir_helper(
+ c,
+ cm_fh,
+ indent=indent + 1,
+ current_conditions=child_conditions,
+ is_example=is_example,
+ )
+
+ def group_and_print_sub_dirs(scope: Scope, indent: int = 0) -> None:
+ # Simplify conditions, and group
+ # subdirectories with the same conditions.
+ grouped_sub_dirs: Dict[str, List[str]] = {}
+
+ # Wraps each element in the given interable with parentheses,
+ # to make sure boolean simplification happens correctly.
+ def wrap_in_parenthesis(iterable):
+ return [f"({c})" for c in iterable]
+
+ def join_all_conditions(set_of_alternatives):
+ # Elements within one frozen set represent one single
+ # alternative whose pieces are ANDed together.
+ # This is repeated for each alternative that would
+ # enable a subdir, and are thus ORed together.
+ final_str = ""
+ if set_of_alternatives:
+ wrapped_set_of_alternatives = [
+ wrap_in_parenthesis(alternative) for alternative in set_of_alternatives
+ ]
+ alternatives = [
+ f'({" AND ".join(alternative)})' for alternative in wrapped_set_of_alternatives
+ ]
+ final_str = " OR ".join(sorted(alternatives))
+ return final_str
+
+ for subdir_name in sub_dirs:
+ additions = sub_dirs[subdir_name].get("additions", set())
+ subtractions = sub_dirs[subdir_name].get("subtractions", set())
+
+ # An empty condition key represents the group of sub dirs
+ # that should be added unconditionally.
+ condition_key = ""
+ if additions or subtractions:
+ addition_str = join_all_conditions(additions)
+ if addition_str:
+ addition_str = f"({addition_str})"
+ subtraction_str = join_all_conditions(subtractions)
+ if subtraction_str:
+ subtraction_str = f"NOT ({subtraction_str})"
+
+ condition_str = addition_str
+ if condition_str and subtraction_str:
+ condition_str += " AND "
+ condition_str += subtraction_str
+ if not condition_str.rstrip("()").strip():
+ continue
+ condition_simplified = simplify_condition(condition_str)
+ condition_key = condition_simplified
+
+ sub_dir_list_by_key: List[str] = grouped_sub_dirs.get(condition_key, [])
+ sub_dir_list_by_key.append(subdir_name)
+ grouped_sub_dirs[condition_key] = sub_dir_list_by_key
+
+ # Print any requires() blocks.
+ cm_fh.write(expand_project_requirements(scope, skip_message=True))
+
+ # Print the groups.
+ ind = spaces(indent)
+ for condition_key in grouped_sub_dirs:
+ cond_ind = ind
+ if condition_key:
+ cm_fh.write(f"{ind}if({condition_key})\n")
+ cond_ind += " "
+
+ sub_dir_list_by_key = grouped_sub_dirs.get(condition_key, [])
+ for subdir_name in sub_dir_list_by_key:
+ cm_fh.write(f"{cond_ind}add_subdirectory({subdir_name})\n")
+ if condition_key:
+ cm_fh.write(f"{ind}endif()\n")
+
+ # A set of conditions which will be ANDed together. The set is recreated with more conditions
+ # as the scope deepens.
+ current_conditions: FrozenSet[str] = frozenset()
+
+ # Compute the total condition for scopes. Needed for scopes that
+ # have 'else' as a condition.
+ recursive_evaluate_scope(scope)
+
+ # Do the work.
+ handle_subdir_helper(
+ scope, cm_fh, indent=indent, current_conditions=current_conditions, is_example=is_example
+ )
+ group_and_print_sub_dirs(scope, indent=indent)
+
+
+def sort_sources(sources: List[str]) -> List[str]:
+ to_sort = {} # type: Dict[str, List[str]]
+ for s in sources:
+ if s is None:
+ continue
+
+ path = os.path.dirname(s)
+ base = os.path.splitext(os.path.basename(s))[0]
+ if base.endswith("_p"):
+ base = base[:-2]
+ sort_name = posixpath.join(path, base)
+
+ array = to_sort.get(sort_name, [])
+ array.append(s)
+
+ to_sort[sort_name] = array
+
+ lines = []
+ for k in sorted(to_sort.keys()):
+ lines.append(" ".join(sorted(to_sort[k])))
+
+ return lines
+
+
+def _map_libraries_to_cmake(
+ libraries: List[str], known_libraries: Set[str], is_example: bool = False
+) -> List[str]:
+ result = [] # type: List[str]
+ is_framework = False
+
+ for lib in libraries:
+ if lib == "-framework":
+ is_framework = True
+ continue
+ if is_framework:
+ if is_example:
+ lib = f'"-framework {lib}"'
+ else:
+ lib = f"${{FW{lib}}}"
+ if lib.startswith("-l"):
+ lib = lib[2:]
+
+ if lib.startswith("-"):
+ lib = f"# Remove: {lib[1:]}"
+ else:
+ lib = map_3rd_party_library(lib)
+
+ if not lib or lib in result or lib in known_libraries:
+ continue
+
+ result.append(lib)
+ is_framework = False
+
+ return result
+
+
+def extract_cmake_libraries(
+ scope: Scope, *, known_libraries: Optional[Set[str]] = None, is_example: bool = False
+) -> Tuple[List[str], List[str]]:
+ if known_libraries is None:
+ known_libraries = set()
+ public_dependencies = [] # type: List[str]
+ private_dependencies = [] # type: List[str]
+
+ for key in ["QMAKE_USE", "LIBS"]:
+ public_dependencies += scope.expand(key)
+ for key in ["QMAKE_USE_PRIVATE", "QMAKE_USE_FOR_PRIVATE", "LIBS_PRIVATE"]:
+ private_dependencies += scope.expand(key)
+
+ for key in ["QT_FOR_PRIVATE", "QT_PRIVATE"]:
+ private_dependencies += [map_qt_library(q) for q in scope.expand(key)]
+
+ for key in ["QT"]:
+ # Qt public libs: These may include FooPrivate in which case we get
+ # a private dependency on FooPrivate as well as a public dependency on Foo
+ for lib in scope.expand(key):
+ mapped_lib = map_qt_library(lib)
+
+ if mapped_lib.endswith("Private"):
+ private_dependencies.append(mapped_lib)
+ public_dependencies.append(mapped_lib[:-7])
+ else:
+ public_dependencies.append(mapped_lib)
+
+ return (
+ _map_libraries_to_cmake(public_dependencies, known_libraries, is_example=is_example),
+ _map_libraries_to_cmake(private_dependencies, known_libraries, is_example=is_example),
+ )
+
+
+def write_header(cm_fh: IO[str], name: str, typename: str, *, indent: int = 0):
+ ind = spaces(indent)
+ comment_line = "#" * 69
+ cm_fh.write(f"{ind}{comment_line}\n")
+ cm_fh.write(f"{ind}## {name} {typename}:\n")
+ cm_fh.write(f"{ind}{comment_line}\n\n")
+
+
+def write_scope_header(cm_fh: IO[str], *, indent: int = 0):
+ ind = spaces(indent)
+ comment_line = "#" * 69
+ cm_fh.write(f"\n{ind}## Scopes:\n")
+ cm_fh.write(f"{ind}{comment_line}\n")
+
+
+def write_list(
+ cm_fh: IO[str],
+ entries: List[str],
+ cmake_parameter: str,
+ indent: int = 0,
+ *,
+ header: str = "",
+ footer: str = "",
+ prefix: str = "",
+):
+ if not entries:
+ return
+
+ ind = spaces(indent)
+ extra_indent = ""
+
+ if header:
+ cm_fh.write(f"{ind}{header}")
+ extra_indent += " "
+ if cmake_parameter:
+ cm_fh.write(f"{ind}{extra_indent}{cmake_parameter}\n")
+ extra_indent += " "
+ for s in sort_sources(entries):
+ cm_fh.write(f"{ind}{extra_indent}{prefix}{s}\n")
+ if footer:
+ cm_fh.write(f"{ind}{footer}\n")
+
+
+def write_source_file_list(
+ cm_fh: IO[str],
+ scope,
+ cmake_parameter: str,
+ keys: List[str],
+ indent: int = 0,
+ *,
+ header: str = "",
+ footer: str = "",
+):
+ # collect sources
+ sources: List[str] = []
+ for key in keys:
+ sources += scope.get_files(key, use_vpath=True)
+
+ # Remove duplicates, like in the case when NO_PCH_SOURCES ends up
+ # adding the file to SOURCES, but SOURCES might have already
+ # contained it before. Preserves order in Python 3.7+ because
+ # dict keys are ordered.
+ sources = list(dict.fromkeys(sources))
+
+ write_list(cm_fh, sources, cmake_parameter, indent, header=header, footer=footer)
+
+
+def write_all_source_file_lists(
+ cm_fh: IO[str],
+ scope: Scope,
+ header: str,
+ *,
+ indent: int = 0,
+ footer: str = "",
+ extra_keys: Optional[List[str]] = None,
+):
+ if extra_keys is None:
+ extra_keys = []
+ write_source_file_list(
+ cm_fh,
+ scope,
+ header,
+ ["SOURCES", "HEADERS", "OBJECTIVE_SOURCES", "OBJECTIVE_HEADERS", "NO_PCH_SOURCES", "FORMS"]
+ + extra_keys,
+ indent,
+ footer=footer,
+ )
+
+
+def write_defines(
+ cm_fh: IO[str], scope: Scope, cmake_parameter: str, *, indent: int = 0, footer: str = ""
+):
+ defines = scope.expand("DEFINES")
+ defines += [d[2:] for d in scope.expand("QMAKE_CXXFLAGS") if d.startswith("-D")]
+ defines = [
+ d.replace('=\\\\\\"$$PWD/\\\\\\"', '="${CMAKE_CURRENT_SOURCE_DIR}/"') for d in defines
+ ]
+
+ if "qml_debug" in scope.get("CONFIG"):
+ defines.append("QT_QML_DEBUG")
+
+ write_list(cm_fh, defines, cmake_parameter, indent, footer=footer)
+
+
+def write_include_paths(
+ cm_fh: IO[str], scope: Scope, cmake_parameter: str, *, indent: int = 0, footer: str = ""
+):
+ includes = [i.rstrip("/") or ("/") for i in scope.get_files("INCLUDEPATH")]
+
+ write_list(cm_fh, includes, cmake_parameter, indent, footer=footer)
+
+
+def write_compile_options(
+ cm_fh: IO[str], scope: Scope, cmake_parameter: str, *, indent: int = 0, footer: str = ""
+):
+ compile_options = [d for d in scope.expand("QMAKE_CXXFLAGS") if not d.startswith("-D")]
+
+ write_list(cm_fh, compile_options, cmake_parameter, indent, footer=footer)
+
+
+def write_library_section(
+ cm_fh: IO[str], scope: Scope, *, indent: int = 0, known_libraries: Optional[Set[str]] = None
+):
+ if known_libraries is None:
+ known_libraries = set()
+ public_dependencies, private_dependencies = extract_cmake_libraries(
+ scope, known_libraries=known_libraries
+ )
+
+ write_list(cm_fh, private_dependencies, "LIBRARIES", indent + 1)
+ write_list(cm_fh, public_dependencies, "PUBLIC_LIBRARIES", indent + 1)
+
+
+def write_autogen_section(cm_fh: IO[str], scope: Scope, *, indent: int = 0):
+ forms = scope.get_files("FORMS")
+ if forms:
+ write_list(cm_fh, ["uic"], "ENABLE_AUTOGEN_TOOLS", indent)
+
+
+def write_sources_section(
+ cm_fh: IO[str], scope: Scope, *, indent: int = 0, known_libraries: Optional[Set[str]] = None
+):
+ if known_libraries is None:
+ known_libraries = set()
+ ind = spaces(indent)
+
+ # mark RESOURCES as visited:
+ scope.get("RESOURCES")
+
+ write_all_source_file_lists(cm_fh, scope, "SOURCES", indent=indent + 1)
+
+ write_source_file_list(cm_fh, scope, "DBUS_ADAPTOR_SOURCES", ["DBUS_ADAPTORS"], indent + 1)
+ dbus_adaptor_flags = scope.expand("QDBUSXML2CPP_ADAPTOR_HEADER_FLAGS")
+ if dbus_adaptor_flags:
+ dbus_adaptor_flags_line = '" "'.join(dbus_adaptor_flags)
+ cm_fh.write(f"{ind} DBUS_ADAPTOR_FLAGS\n")
+ cm_fh.write(f'{ind} "{dbus_adaptor_flags_line}"\n')
+
+ write_source_file_list(cm_fh, scope, "DBUS_INTERFACE_SOURCES", ["DBUS_INTERFACES"], indent + 1)
+ dbus_interface_flags = scope.expand("QDBUSXML2CPP_INTERFACE_HEADER_FLAGS")
+ if dbus_interface_flags:
+ dbus_interface_flags_line = '" "'.join(dbus_interface_flags)
+ cm_fh.write(f"{ind} DBUS_INTERFACE_FLAGS\n")
+ cm_fh.write(f'{ind} "{dbus_interface_flags_line}"\n')
+
+ write_defines(cm_fh, scope, "DEFINES", indent=indent + 1)
+
+ write_include_paths(cm_fh, scope, "INCLUDE_DIRECTORIES", indent=indent + 1)
+
+ write_library_section(cm_fh, scope, indent=indent, known_libraries=known_libraries)
+
+ write_compile_options(cm_fh, scope, "COMPILE_OPTIONS", indent=indent + 1)
+
+ write_autogen_section(cm_fh, scope, indent=indent + 1)
+
+ link_options = scope.get("QMAKE_LFLAGS")
+ if link_options:
+ cm_fh.write(f"{ind} LINK_OPTIONS\n")
+ for lo in link_options:
+ cm_fh.write(f'{ind} "{lo}"\n')
+
+ moc_options = scope.get("QMAKE_MOC_OPTIONS")
+ if moc_options:
+ cm_fh.write(f"{ind} MOC_OPTIONS\n")
+ for mo in moc_options:
+ cm_fh.write(f'{ind} "{mo}"\n')
+
+ precompiled_header = scope.get("PRECOMPILED_HEADER")
+ if precompiled_header:
+ cm_fh.write(f"{ind} PRECOMPILED_HEADER\n")
+ for header in precompiled_header:
+ cm_fh.write(f'{ind} "{header}"\n')
+
+ no_pch_sources = scope.get("NO_PCH_SOURCES")
+ if no_pch_sources:
+ cm_fh.write(f"{ind} NO_PCH_SOURCES\n")
+ for source in no_pch_sources:
+ cm_fh.write(f'{ind} "{source}"\n')
+
+
+def is_simple_condition(condition: str) -> bool:
+ return " " not in condition or (condition.startswith("NOT ") and " " not in condition[4:])
+
+
+def write_ignored_keys(scope: Scope, indent: str) -> str:
+ result = ""
+ ignored_keys = scope.keys - scope.visited_keys
+ for k in sorted(ignored_keys):
+ if k in {
+ "_INCLUDED",
+ "_LOADED",
+ "TARGET",
+ "QMAKE_DOCS",
+ "QT_SOURCE_TREE",
+ "QT_BUILD_TREE",
+ "QTRO_SOURCE_TREE",
+ "TRACEPOINT_PROVIDER",
+ "PLUGIN_TYPE",
+ "PLUGIN_CLASS_NAME",
+ "CLASS_NAME",
+ "MODULE_PLUGIN_TYPES",
+ }:
+ # All these keys are actually reported already
+ continue
+ values = scope.get(k)
+ value_string = "<EMPTY>" if not values else '"' + '" "'.join(scope.get(k)) + '"'
+ result += f"{indent}# {k} = {value_string}\n"
+
+ if result:
+ result = f"\n#### Keys ignored in scope {scope}:\n{result}"
+
+ return result
+
+
+def recursive_evaluate_scope(
+ scope: Scope, parent_condition: str = "", previous_condition: str = ""
+) -> str:
+ current_condition = scope.condition
+ total_condition = current_condition
+ if total_condition == "else":
+ assert previous_condition, f"Else branch without previous condition in: {scope.file}"
+ total_condition = f"NOT ({previous_condition})"
+ if parent_condition:
+ if not total_condition:
+ total_condition = parent_condition
+ else:
+ total_condition = f"({parent_condition}) AND ({total_condition})"
+
+ scope.total_condition = simplify_condition(total_condition)
+
+ prev_condition = ""
+ for c in scope.children:
+ prev_condition = recursive_evaluate_scope(c, total_condition, prev_condition)
+
+ return current_condition
+
+
+def map_to_cmake_condition(condition: str = "") -> str:
+ condition = condition.replace("QTDIR_build", "QT_BUILDING_QT")
+ condition = re.sub(
+ r"\bQT_ARCH___equals___([a-zA-Z_0-9]*)",
+ r'(TEST_architecture_arch STREQUAL "\1")',
+ condition or "",
+ )
+ condition = re.sub(
+ r"\bQT_ARCH___contains___([a-zA-Z_0-9]*)",
+ r'(TEST_architecture_arch STREQUAL "\1")',
+ condition or "",
+ )
+ condition = condition.replace("QT___contains___opengl", "QT_FEATURE_opengl")
+ condition = condition.replace("QT___contains___widgets", "QT_FEATURE_widgets")
+ condition = condition.replace(
+ "DEFINES___contains___QT_NO_PRINTER", "(QT_FEATURE_printer EQUAL FALSE)"
+ )
+ return condition
+
+
+resource_file_expansion_counter = 0
+
+
+def expand_resource_glob(cm_fh: IO[str], expression: str) -> str:
+ global resource_file_expansion_counter
+ r = expression.replace('"', "")
+
+ cm_fh.write(
+ dedent(
+ f"""
+ file(GLOB resource_glob_{resource_file_expansion_counter} RELATIVE "${{CMAKE_CURRENT_SOURCE_DIR}}" "{r}")
+ foreach(file IN LISTS resource_glob_{resource_file_expansion_counter})
+ set_source_files_properties("${{CMAKE_CURRENT_SOURCE_DIR}}/${{file}}" PROPERTIES QT_RESOURCE_ALIAS "${{file}}")
+ endforeach()
+ """
+ )
+ )
+
+ expanded_var = f"${{resource_glob_{resource_file_expansion_counter}}}"
+ resource_file_expansion_counter += 1
+ return expanded_var
+
+
+def write_resources(cm_fh: IO[str], target: str, scope: Scope, indent: int = 0, is_example=False):
+ # vpath = scope.expand('VPATH')
+
+ # Handle QRC files by turning them into qt_add_resource:
+ resources = scope.get_files("RESOURCES")
+ qtquickcompiler_skipped = scope.get_files("QTQUICK_COMPILER_SKIPPED_RESOURCES")
+ qtquickcompiler_retained = scope.get_files("QTQUICK_COMPILER_RETAINED_RESOURCES")
+ qrc_output = ""
+ if resources:
+ standalone_files: List[str] = []
+ for r in resources:
+ skip_qtquick_compiler = r in qtquickcompiler_skipped
+ retain_qtquick_compiler = r in qtquickcompiler_retained
+ if r.endswith(".qrc"):
+ if "${CMAKE_CURRENT_BINARY_DIR}" in r:
+ cm_fh.write(f"#### Ignored generated resource: {r}")
+ continue
+ qrc_output += process_qrc_file(
+ target,
+ r,
+ scope.basedir,
+ scope.file_absolute_path,
+ skip_qtquick_compiler,
+ retain_qtquick_compiler,
+ is_example,
+ )
+ else:
+ immediate_files = {f: "" for f in scope.get_files(f"{r}.files")}
+ if immediate_files:
+ immediate_files_filtered = []
+ for f in immediate_files:
+ if "*" in f:
+ immediate_files_filtered.append(expand_resource_glob(cm_fh, f))
+ else:
+ immediate_files_filtered.append(f)
+ immediate_files = {f: "" for f in immediate_files_filtered}
+ scope_prefix = scope.get(f"{r}.prefix")
+ if scope_prefix:
+ immediate_prefix = scope_prefix[0]
+ else:
+ immediate_prefix = "/"
+ immediate_base_list = scope.get(f"{r}.base")
+ assert (
+ len(immediate_base_list) < 2
+ ), f"immediate base directory must be at most one entry"
+ immediate_base = replace_path_constants("".join(immediate_base_list), scope)
+ immediate_lang = None
+ immediate_name = f"qmake_{r}"
+ qrc_output += write_add_qt_resource_call(
+ target=target,
+ resource_name=immediate_name,
+ prefix=immediate_prefix,
+ base_dir=immediate_base,
+ lang=immediate_lang,
+ files=immediate_files,
+ skip_qtquick_compiler=skip_qtquick_compiler,
+ retain_qtquick_compiler=retain_qtquick_compiler,
+ is_example=is_example,
+ )
+ else:
+ if "*" in r:
+ standalone_files.append(expand_resource_glob(cm_fh, r))
+ else:
+ # stadalone source file properties need to be set as they
+ # are parsed.
+ if skip_qtquick_compiler:
+ qrc_output += (
+ f'set_source_files_properties("{r}" PROPERTIES '
+ f"QT_SKIP_QUICKCOMPILER 1)\n\n"
+ )
+
+ if retain_qtquick_compiler:
+ qrc_output += (
+ f'set_source_files_properties("{r}" PROPERTIES '
+ f"QT_RETAIN_QUICKCOMPILER 1)\n\n"
+ )
+ standalone_files.append(r)
+
+ if standalone_files:
+ name = "qmake_immediate"
+ prefix = "/"
+ base = ""
+ lang = None
+ files = {f: "" for f in standalone_files}
+ skip_qtquick_compiler = False
+ qrc_output += write_add_qt_resource_call(
+ target=target,
+ resource_name=name,
+ prefix=prefix,
+ base_dir=base,
+ lang=lang,
+ files=files,
+ skip_qtquick_compiler=False,
+ retain_qtquick_compiler=False,
+ is_example=is_example,
+ )
+
+ if qrc_output:
+ str_indent = spaces(indent)
+ cm_fh.write(f"\n{str_indent}# Resources:\n")
+ for line in qrc_output.split("\n"):
+ if line:
+ cm_fh.write(f"{str_indent}{line}\n")
+ else:
+ # do not add spaces to empty lines
+ cm_fh.write("\n")
+
+
+def write_statecharts(cm_fh: IO[str], target: str, scope: Scope, indent: int = 0, is_example=False):
+ sources = scope.get_files("STATECHARTS", use_vpath=True)
+ if not sources:
+ return
+ cm_fh.write("\n# Statecharts:\n")
+ if is_example:
+ cm_fh.write(f"qt6_add_statecharts({target}\n")
+ else:
+ cm_fh.write(f"add_qt_statecharts({target} FILES\n")
+ indent += 1
+ for f in sources:
+ cm_fh.write(f"{spaces(indent)}{f}\n")
+ cm_fh.write(")\n")
+
+
+def write_qlalrsources(cm_fh: IO[str], target: str, scope: Scope, indent: int = 0):
+ sources = scope.get_files("QLALRSOURCES", use_vpath=True)
+ if not sources:
+ return
+ cm_fh.write("\n# QLALR Grammars:\n")
+ cm_fh.write(f"qt_process_qlalr(\n")
+ indent += 1
+ cm_fh.write(f"{spaces(indent)}{target}\n")
+ cm_fh.write(f"{spaces(indent)}{';'.join(sources)}\n")
+ cm_fh.write(f'{spaces(indent)}""\n')
+ cm_fh.write(")\n")
+
+
+def write_repc_files(cm_fh: IO[str], target: str, scope: Scope, indent: int = 0):
+ for t in ["SOURCE", "REPLICA", "MERGED"]:
+ sources = scope.get_files("REPC_" + t, use_vpath=True)
+ if not sources:
+ continue
+ cm_fh.write(f"qt6_add_repc_{t.lower()}({target}\n")
+ indent += 1
+ for f in sources:
+ cm_fh.write(f"{spaces(indent)}{f}\n")
+ cm_fh.write(")\n")
+
+
+def expand_project_requirements(scope: Scope, skip_message: bool = False) -> str:
+ requirements = ""
+ for requirement in scope.get("_REQUIREMENTS"):
+ original_condition = simplify_condition(map_condition(requirement))
+ inverted_requirement = simplify_condition(f"NOT ({map_condition(requirement)})")
+ if not skip_message:
+ message = f"""
+{spaces(7)}message(NOTICE "Skipping the build as the condition \\"{original_condition}\\" is not met.")"""
+ else:
+ message = ""
+ requirements += dedent(
+ f"""\
+ if({inverted_requirement}){message}
+ return()
+ endif()
+"""
+ )
+ return requirements
+
+
+def write_extend_target(cm_fh: IO[str], target: str, scope: Scope, indent: int = 0):
+ ind = spaces(indent)
+ extend_qt_io_string = io.StringIO()
+ write_sources_section(extend_qt_io_string, scope)
+ extend_qt_string = extend_qt_io_string.getvalue()
+
+ assert scope.total_condition, "Cannot write CONDITION when scope.condition is None"
+
+ condition = map_to_cmake_condition(scope.total_condition)
+
+ cmake_api_call = get_cmake_api_call("qt_extend_target")
+ extend_scope = (
+ f"\n{ind}{cmake_api_call}({target} CONDITION"
+ f" {condition}\n"
+ f"{extend_qt_string}{ind})\n"
+ )
+
+ if not extend_qt_string:
+ extend_scope = "" # Nothing to report, so don't!
+
+ cm_fh.write(extend_scope)
+
+ io_string = io.StringIO()
+ write_resources(io_string, target, scope, indent + 1)
+ resource_string = io_string.getvalue()
+ if len(resource_string) != 0:
+ resource_string = resource_string.strip("\n").rstrip(f"\n{spaces(indent + 1)}")
+ cm_fh.write(f"\n{spaces(indent)}if({condition})\n{resource_string}")
+ cm_fh.write(f"\n{spaces(indent)}endif()\n")
+
+
+def flatten_scopes(scope: Scope) -> List[Scope]:
+ result = [scope] # type: List[Scope]
+ for c in scope.children:
+ result += flatten_scopes(c)
+ return result
+
+
+def merge_scopes(scopes: List[Scope]) -> List[Scope]:
+ result = [] # type: List[Scope]
+
+ # Merge scopes with their parents:
+ known_scopes = {} # type: Dict[str, Scope]
+ for scope in scopes:
+ total_condition = scope.total_condition
+ assert total_condition
+ if total_condition == "OFF":
+ # ignore this scope entirely!
+ pass
+ elif total_condition in known_scopes:
+ known_scopes[total_condition].merge(scope)
+ else:
+ # Keep everything else:
+ result.append(scope)
+ known_scopes[total_condition] = scope
+
+ return result
+
+
+def write_simd_part(cm_fh: IO[str], target: str, scope: Scope, indent: int = 0):
+ simd_options = [
+ "sse2",
+ "sse3",
+ "ssse3",
+ "sse4_1",
+ "sse4_2",
+ "aesni",
+ "shani",
+ "avx",
+ "avx2",
+ "avx512f",
+ "avx512cd",
+ "avx512er",
+ "avx512pf",
+ "avx512dq",
+ "avx512bw",
+ "avx512vl",
+ "avx512ifma",
+ "avx512vbmi",
+ "f16c",
+ "rdrnd",
+ "neon",
+ "mips_dsp",
+ "mips_dspr2",
+ "arch_haswell",
+ "avx512common",
+ "avx512core",
+ ]
+
+ simd_io_string = io.StringIO()
+
+ condition = "ON"
+ if scope.total_condition:
+ condition = map_to_cmake_condition(scope.total_condition)
+
+ if condition != "ON":
+ indent += 1
+
+ for simd in simd_options:
+ SIMD = simd.upper()
+ write_source_file_list(
+ simd_io_string,
+ scope,
+ "SOURCES",
+ [f"{SIMD}_HEADERS", f"{SIMD}_SOURCES", f"{SIMD}_C_SOURCES", f"{SIMD}_ASM"],
+ indent=indent,
+ header=f"{get_cmake_api_call('qt_add_simd_part')}({target} SIMD {simd}\n",
+ footer=")\n",
+ )
+
+ simd_string = simd_io_string.getvalue()
+ if simd_string:
+ simd_string = simd_string.rstrip("\n")
+ cond_start = ""
+ cond_end = ""
+ if condition != "ON":
+ cond_start = f"{spaces(indent - 1)}if({condition})"
+ cond_end = f"{spaces(indent - 1)}endif()"
+
+ extend_scope = f"\n{cond_start}\n" f"{simd_string}" f"\n{cond_end}\n"
+ cm_fh.write(extend_scope)
+
+
+def write_android_part(cm_fh: IO[str], target: str, scope: Scope, indent: int = 0):
+ keys = [
+ "ANDROID_BUNDLED_JAR_DEPENDENCIES",
+ "ANDROID_LIB_DEPENDENCIES",
+ "ANDROID_JAR_DEPENDENCIES",
+ "ANDROID_LIB_DEPENDENCY_REPLACEMENTS",
+ "ANDROID_BUNDLED_FILES",
+ "ANDROID_PERMISSIONS",
+ "ANDROID_PACKAGE_SOURCE_DIR",
+ ]
+
+ has_no_values = True
+ for key in keys:
+ value = scope.expand(key)
+ if len(value) != 0:
+ if has_no_values:
+ if scope.condition:
+ cm_fh.write(f"\n{spaces(indent)}if(ANDROID AND ({scope.condition}))\n")
+ else:
+ cm_fh.write(f"\n{spaces(indent)}if(ANDROID)\n")
+ indent += 1
+ has_no_values = False
+ cm_fh.write(f"{spaces(indent)}set_property(TARGET {target} APPEND PROPERTY QT_{key}\n")
+ write_list(cm_fh, value, "", indent + 1)
+ cm_fh.write(f"{spaces(indent)})\n")
+ indent -= 1
+
+ if not has_no_values:
+ cm_fh.write(f"{spaces(indent)}endif()\n")
+
+
+def write_wayland_part(cm_fh: IO[str], target: str, scope: Scope, indent: int = 0):
+ client_sources = scope.get_files("WAYLANDCLIENTSOURCES", use_vpath=True)
+ server_sources = scope.get_files("WAYLANDSERVERSOURCES", use_vpath=True)
+ if len(client_sources) == 0 and len(server_sources) == 0:
+ return
+
+ condition = "ON"
+ if scope.total_condition:
+ condition = map_to_cmake_condition(scope.total_condition)
+
+ if condition != "ON":
+ cm_fh.write(f"\n{spaces(indent)}if({condition})\n")
+ indent += 1
+
+ if len(client_sources) != 0:
+ cm_fh.write(f"\n{spaces(indent)}qt6_generate_wayland_protocol_client_sources({target}\n")
+ write_list(
+ cm_fh, client_sources, "FILES", indent + 1, prefix="${CMAKE_CURRENT_SOURCE_DIR}/"
+ )
+ cm_fh.write(f"{spaces(indent)})\n")
+
+ if len(server_sources) != 0:
+ cm_fh.write(f"\n{spaces(indent)}qt6_generate_wayland_protocol_server_sources({target}\n")
+ write_list(
+ cm_fh, server_sources, "FILES", indent + 1, prefix="${CMAKE_CURRENT_SOURCE_DIR}/"
+ )
+ cm_fh.write(f"{spaces(indent)})\n")
+
+ if condition != "ON":
+ indent -= 1
+ cm_fh.write(f"\n{spaces(indent)}endif()\n")
+
+
+def handle_source_subtractions(scopes: List[Scope]):
+ """
+ Handles source subtractions like SOURCES -= painting/qdrawhelper.cpp
+ by creating a new scope with a new condition containing all addition
+ and subtraction conditions.
+
+ Algorithm is as follows:
+ - Go through each scope and find files in SOURCES starting with "-"
+ - Save that file and the scope condition in modified_sources dict.
+ - Remove the file from the found scope (optionally remove the
+ NO_PCH_SOURCES entry for that file as well).
+ - Go through each file in modified_sources dict.
+ - Find scopes where the file is added, remove the file from that
+ scope and save the condition.
+ - Create a new scope just for that file with a new simplified
+ condition that takes all the other conditions into account.
+ """
+
+ def remove_file_from_operation(
+ scope: Scope, ops_key: str, file: str, op_type: Type[Operation]
+ ) -> bool:
+ """
+ Remove a source file from an operation in a scope.
+ Example: remove foo.cpp from any operations that have
+ ops_key="SOURCES" in "scope", where the operation is of
+ type "op_type".
+
+ The implementation is very rudimentary and might not work in
+ all cases.
+
+ Returns True if a file was found and removed in any operation.
+ """
+ file_removed = False
+ ops = scope._operations.get(ops_key, list())
+ for op in ops:
+ if not isinstance(op, op_type):
+ continue
+ if file in op._value:
+ op._value.remove(file)
+ file_removed = True
+ for include_child_scope in scope._included_children:
+ file_removed = file_removed or remove_file_from_operation(
+ include_child_scope, ops_key, file, op_type
+ )
+ return file_removed
+
+ def join_all_conditions(set_of_alternatives: Set[str]):
+ final_str = ""
+ if set_of_alternatives:
+ alternatives = [f"({alternative})" for alternative in set_of_alternatives]
+ final_str = " OR ".join(sorted(alternatives))
+ return final_str
+
+ modified_sources: Dict[str, Dict[str, Union[Set[str], bool]]] = {}
+
+ new_scopes = []
+ top_most_scope = scopes[0]
+
+ for scope in scopes:
+ sources = scope.get_files("SOURCES")
+ for file in sources:
+ # Find subtractions.
+ if file.startswith("-"):
+ file_without_minus = file[1:]
+
+ if file_without_minus not in modified_sources:
+ modified_sources[file_without_minus] = {}
+
+ subtractions = modified_sources[file_without_minus].get("subtractions", set())
+ assert isinstance(subtractions, set)
+
+ # Add the condition to the set of conditions and remove
+ # the file subtraction from the processed scope, which
+ # will be later re-added in a new scope.
+ if scope.condition:
+ assert scope.total_condition
+ subtractions.add(scope.total_condition)
+ remove_file_from_operation(scope, "SOURCES", file_without_minus, RemoveOperation)
+ if subtractions:
+ modified_sources[file_without_minus]["subtractions"] = subtractions
+
+ # In case if the source is also listed in a
+ # NO_PCH_SOURCES operation, remove it from there as
+ # well, and add it back later.
+ no_pch_source_removed = remove_file_from_operation(
+ scope, "NO_PCH_SOURCES", file_without_minus, AddOperation
+ )
+ if no_pch_source_removed:
+ modified_sources[file_without_minus]["add_to_no_pch_sources"] = True
+
+ for modified_source in modified_sources:
+ additions = modified_sources[modified_source].get("additions", set())
+ assert isinstance(additions, set), f"Additions must be a set, got {additions} instead."
+ subtractions = modified_sources[modified_source].get("subtractions", set())
+ assert isinstance(
+ subtractions, set
+ ), f"Subtractions must be a set, got {additions} instead."
+ add_to_no_pch_sources = modified_sources[modified_source].get(
+ "add_to_no_pch_sources", False
+ )
+
+ for scope in scopes:
+ sources = scope.get_files("SOURCES")
+ if modified_source in sources:
+ # Remove the source file from any addition operations
+ # that mention it.
+ remove_file_from_operation(scope, "SOURCES", modified_source, AddOperation)
+ if scope.total_condition:
+ additions.add(scope.total_condition)
+
+ # Construct a condition that takes into account all addition
+ # and subtraction conditions.
+ addition_str = join_all_conditions(additions)
+ if addition_str:
+ addition_str = f"({addition_str})"
+ subtraction_str = join_all_conditions(subtractions)
+ if subtraction_str:
+ subtraction_str = f"NOT ({subtraction_str})"
+
+ condition_str = addition_str
+ if condition_str and subtraction_str:
+ condition_str += " AND "
+ condition_str += subtraction_str
+ condition_simplified = simplify_condition(condition_str)
+
+ # Create a new scope with that condition and add the source
+ # operations.
+ new_scope = Scope(
+ parent_scope=top_most_scope,
+ qmake_file=top_most_scope.file,
+ condition=condition_simplified,
+ base_dir=top_most_scope.basedir,
+ )
+ new_scope.total_condition = condition_simplified
+ new_scope._append_operation("SOURCES", AddOperation([modified_source]))
+ if add_to_no_pch_sources:
+ new_scope._append_operation("NO_PCH_SOURCES", AddOperation([modified_source]))
+
+ new_scopes.append(new_scope)
+
+ # Add all the newly created scopes.
+ scopes += new_scopes
+
+
+def write_main_part(
+ cm_fh: IO[str],
+ name: str,
+ typename: str,
+ cmake_function: str,
+ scope: Scope,
+ *,
+ extra_lines: Optional[List[str]] = None,
+ indent: int = 0,
+ extra_keys: List[str],
+ **kwargs: Any,
+):
+ # Evaluate total condition of all scopes:
+ if extra_lines is None:
+ extra_lines = []
+ recursive_evaluate_scope(scope)
+
+ if "exceptions" in scope.get("CONFIG"):
+ extra_lines.append("EXCEPTIONS")
+
+ # Get a flat list of all scopes but the main one:
+ scopes = flatten_scopes(scope)
+ # total_scopes = len(scopes)
+ # Merge scopes based on their conditions:
+ scopes = merge_scopes(scopes)
+
+ # Handle SOURCES -= foo calls, and merge scopes one more time
+ # because there might have been several files removed with the same
+ # scope condition.
+ handle_source_subtractions(scopes)
+ scopes = merge_scopes(scopes)
+
+ assert len(scopes)
+ assert scopes[0].total_condition == "ON"
+
+ scopes[0].reset_visited_keys()
+ for k in extra_keys:
+ scopes[0].get(k)
+
+ # Now write out the scopes:
+ write_header(cm_fh, name, typename, indent=indent)
+
+ # collect all testdata and insert globbing commands
+ has_test_data = False
+ if typename == "Test":
+ test_data = scope.expand("TESTDATA")
+ if test_data:
+ has_test_data = True
+ cm_fh.write("# Collect test data\n")
+ for data in test_data:
+ if "*" in data:
+ cm_fh.write(
+ dedent(
+ f"""\
+ {spaces(indent)}file(GLOB_RECURSE test_data_glob
+ {spaces(indent+1)}RELATIVE ${{CMAKE_CURRENT_SOURCE_DIR}}
+ {spaces(indent+1)}{data})
+ """
+ )
+ )
+ cm_fh.write(f"{spaces(indent)}list(APPEND test_data ${{test_data_glob}})\n")
+ else:
+ cm_fh.write(f'{spaces(indent)}list(APPEND test_data "{data}")\n')
+ cm_fh.write("\n")
+
+ # Check for DESTDIR override
+ destdir = scope.get_string("DESTDIR")
+ if destdir:
+ already_added = False
+ for line in extra_lines:
+ if line.startswith("OUTPUT_DIRECTORY"):
+ already_added = True
+ break
+ if not already_added:
+ destdir = replace_path_constants(destdir, scope)
+ extra_lines.append(f'OUTPUT_DIRECTORY "{destdir}"')
+
+ cm_fh.write(f"{spaces(indent)}{cmake_function}({name}\n")
+ for extra_line in extra_lines:
+ cm_fh.write(f"{spaces(indent)} {extra_line}\n")
+
+ write_sources_section(cm_fh, scopes[0], indent=indent, **kwargs)
+
+ if has_test_data:
+ cm_fh.write(f"{spaces(indent)} TESTDATA ${{test_data}}\n")
+ # Footer:
+ cm_fh.write(f"{spaces(indent)})\n")
+
+ write_resources(cm_fh, name, scope, indent)
+
+ write_statecharts(cm_fh, name, scope, indent)
+
+ write_qlalrsources(cm_fh, name, scope, indent)
+
+ write_repc_files(cm_fh, name, scope, indent)
+
+ write_simd_part(cm_fh, name, scope, indent)
+
+ write_android_part(cm_fh, name, scopes[0], indent)
+
+ write_wayland_part(cm_fh, name, scopes[0], indent)
+
+ ignored_keys_report = write_ignored_keys(scopes[0], spaces(indent))
+ if ignored_keys_report:
+ cm_fh.write(ignored_keys_report)
+
+ # Scopes:
+ if len(scopes) == 1:
+ return
+
+ write_scope_header(cm_fh, indent=indent)
+
+ for c in scopes[1:]:
+ c.reset_visited_keys()
+ write_android_part(cm_fh, name, c, indent=indent)
+ write_wayland_part(cm_fh, name, c, indent=indent)
+ write_extend_target(cm_fh, name, c, indent=indent)
+ write_simd_part(cm_fh, name, c, indent=indent)
+
+ ignored_keys_report = write_ignored_keys(c, spaces(indent))
+ if ignored_keys_report:
+ cm_fh.write(ignored_keys_report)
+
+
+def write_generic_library(cm_fh: IO[str], scope: Scope, *, indent: int = 0) -> str:
+
+ target_name = scope.TARGET
+
+ library_type = ""
+
+ if "dll" in scope.get("CONFIG"):
+ library_type = "SHARED"
+
+ is_plugin = False
+ if "plugin" in scope.get("CONFIG"):
+ library_type = "MODULE"
+ is_plugin = True
+
+ # static after plugin in order to handle static library plugins
+ if "static" in scope.get("CONFIG"):
+ library_type = "STATIC"
+
+ extra_lines = []
+
+ if library_type:
+ extra_lines.append(library_type)
+
+ target_path = scope.expandString("target.path")
+ target_path = replace_path_constants(target_path, scope)
+ if target_path:
+ extra_lines.append(f'INSTALL_DIRECTORY "{target_path}"')
+
+ write_main_part(
+ cm_fh,
+ target_name,
+ "Generic Library",
+ get_cmake_api_call("qt_add_cmake_library"),
+ scope,
+ extra_lines=extra_lines,
+ indent=indent,
+ known_libraries={},
+ extra_keys=[],
+ )
+
+ if is_plugin:
+ # Plugins need to be able to run auto moc
+ cm_fh.write(f"\nqt_autogen_tools_initial_setup({target_name})\n")
+
+ if library_type == "STATIC":
+ cm_fh.write(f"\ntarget_compile_definitions({target_name} PRIVATE QT_STATICPLUGIN)\n")
+
+ return target_name
+
+
+def write_module(cm_fh: IO[str], scope: Scope, *, indent: int = 0) -> str:
+ module_name = scope.TARGET
+ if not module_name.startswith("Qt"):
+ print(f"XXXXXX Module name {module_name} does not start with Qt!")
+
+ extra = []
+
+ # A module should be static when 'static' is in CONFIG
+ # or when option(host_build) is used, as described in qt_module.prf.
+ is_static = "static" in scope.get("CONFIG") or "host_build" in scope.get("_OPTION")
+
+ if is_static:
+ extra.append("STATIC")
+ if "internal_module" in scope.get("CONFIG"):
+ extra.append("INTERNAL_MODULE")
+ if "no_module_headers" in scope.get("CONFIG"):
+ extra.append("NO_MODULE_HEADERS")
+ if "minimal_syncqt" in scope.get("CONFIG"):
+ extra.append("NO_SYNC_QT")
+ if "no_private_module" in scope.get("CONFIG"):
+ extra.append("NO_PRIVATE_MODULE")
+ if "header_module" in scope.get("CONFIG"):
+ extra.append("HEADER_MODULE")
+ if "metatypes" in scope.get("CONFIG"):
+ extra.append("GENERATE_METATYPES")
+
+ module_config = scope.get("MODULE_CONFIG")
+ if len(module_config):
+ extra.append(f'QMAKE_MODULE_CONFIG {" ".join(module_config)}')
+
+ module_plugin_types = scope.get_files("MODULE_PLUGIN_TYPES")
+ if module_plugin_types:
+ extra.append(f"PLUGIN_TYPES {' '.join(module_plugin_types)}")
+
+ target_name = module_name[2:]
+ write_main_part(
+ cm_fh,
+ target_name,
+ "Module",
+ f"{get_cmake_api_call('qt_add_module')}",
+ scope,
+ extra_lines=extra,
+ indent=indent,
+ known_libraries={},
+ extra_keys=[],
+ )
+
+ if "qt_tracepoints" in scope.get("CONFIG"):
+ tracepoints = scope.get_files("TRACEPOINT_PROVIDER")
+ cm_fh.write(
+ f"\n\n{spaces(indent)}qt_create_tracepoints({module_name[2:]} {' '.join(tracepoints)})\n"
+ )
+
+ return target_name
+
+
+def write_tool(cm_fh: IO[str], scope: Scope, *, indent: int = 0) -> str:
+ tool_name = scope.TARGET
+
+ if "force_bootstrap" in scope.get("CONFIG"):
+ extra = ["BOOTSTRAP"]
+
+ # Remove default QT libs.
+ scope._append_operation("QT", RemoveOperation(["core", "gui"]))
+ else:
+ extra = []
+
+ write_main_part(
+ cm_fh,
+ tool_name,
+ "Tool",
+ get_cmake_api_call("qt_add_tool"),
+ scope,
+ indent=indent,
+ known_libraries={"Qt::Core"},
+ extra_lines=extra,
+ extra_keys=["CONFIG"],
+ )
+
+ return tool_name
+
+
+def write_test(cm_fh: IO[str], scope: Scope, gui: bool = False, *, indent: int = 0) -> str:
+ test_name = scope.TARGET
+ assert test_name
+
+ extra = ["GUI"] if gui else []
+ libraries = {"Qt::Core", "Qt::Test"}
+
+ if "qmltestcase" in scope.get("CONFIG"):
+ libraries.add("Qt::QmlTest")
+ extra.append("QMLTEST")
+ importpath = scope.expand("IMPORTPATH")
+ if importpath:
+ extra.append("QML_IMPORTPATH")
+ for path in importpath:
+ extra.append(f' "{path}"')
+
+ target_original = scope.TARGET_ORIGINAL
+ if target_original and target_original.startswith("../"):
+ extra.append('OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../"')
+
+ requires_content = expand_project_requirements(scope, skip_message=True)
+ if requires_content:
+ requires_content += "\n"
+ cm_fh.write(requires_content)
+
+ write_main_part(
+ cm_fh,
+ test_name,
+ "Test",
+ get_cmake_api_call("qt_add_test"),
+ scope,
+ indent=indent,
+ known_libraries=libraries,
+ extra_lines=extra,
+ extra_keys=[],
+ )
+
+ return test_name
+
+
+def write_binary(cm_fh: IO[str], scope: Scope, gui: bool = False, *, indent: int = 0) -> str:
+ binary_name = scope.TARGET
+ assert binary_name
+
+ is_benchmark = is_benchmark_project(scope.file_absolute_path)
+ is_manual_test = is_manual_test_project(scope.file_absolute_path)
+
+ is_qt_test_helper = "qt_test_helper" in scope.get("_LOADED")
+
+ extra = ["GUI"] if gui and not is_qt_test_helper else []
+ cmake_function_call = get_cmake_api_call("qt_add_executable")
+ extra_keys: List[str] = []
+
+ if is_qt_test_helper:
+ binary_name += "_helper"
+ cmake_function_call = get_cmake_api_call("qt_add_test_helper")
+
+ if is_benchmark:
+ cmake_function_call = get_cmake_api_call("qt_add_benchmark")
+ elif is_manual_test:
+ cmake_function_call = get_cmake_api_call("qt_add_manual_test")
+ else:
+ extra_keys = ["target.path", "INSTALLS"]
+ target_path = scope.get_string("target.path")
+ if target_path:
+ target_path = replace_path_constants(target_path, scope)
+ if not scope.get("DESTDIR"):
+ extra.append(f'OUTPUT_DIRECTORY "{target_path}"')
+ if "target" in scope.get("INSTALLS"):
+ extra.append(f'INSTALL_DIRECTORY "{target_path}"')
+
+ write_main_part(
+ cm_fh,
+ binary_name,
+ "Binary",
+ cmake_function_call,
+ scope,
+ extra_lines=extra,
+ indent=indent,
+ known_libraries={"Qt::Core"},
+ extra_keys=extra_keys,
+ )
+
+ return binary_name
+
+
+def write_find_package_section(
+ cm_fh: IO[str], public_libs: List[str], private_libs: List[str], *, indent: int = 0
+):
+ packages = [] # type: List[LibraryMapping]
+ all_libs = public_libs + private_libs
+
+ for l in all_libs:
+ info = find_library_info_for_target(l)
+ if info and info not in packages:
+ packages.append(info)
+
+ # ind = spaces(indent)
+
+ for p in packages:
+ cm_fh.write(generate_find_package_info(p, use_qt_find_package=False, indent=indent))
+
+ if packages:
+ cm_fh.write("\n")
+
+
+def write_jar(cm_fh: IO[str], scope: Scope, *, indent: int = 0) -> str:
+
+ target = scope.TARGET
+
+ install_dir = scope.expandString("target.path")
+ if not install_dir:
+ raise RuntimeError("Could not locate jar install path")
+ install_dir = install_dir.replace("$$[QT_INSTALL_PREFIX]/", "")
+
+ android_sdk_jar = "${QT_ANDROID_JAR}"
+ android_api_level = scope.get_string("API_VERSION")
+ if android_api_level:
+ cm_fh.write(
+ f'{spaces(indent)}qt_get_android_sdk_jar_for_api("{android_api_level}" android_sdk)\n\n'
+ )
+ android_sdk_jar = "${android_sdk}"
+
+ write_source_file_list(
+ cm_fh, scope, "", ["JAVASOURCES"], indent=indent, header=f"set(java_sources\n", footer=")\n"
+ )
+
+ cm_fh.write(f"{spaces(indent)}add_jar({target}\n")
+ cm_fh.write(f"{spaces(indent+1)}INCLUDE_JARS {android_sdk_jar}\n")
+ cm_fh.write(f"{spaces(indent+1)}SOURCES ${{java_sources}}\n")
+ cm_fh.write(f"{spaces(indent)})\n\n")
+
+ cm_fh.write(f"{spaces(indent)}install_jar({target}\n")
+ cm_fh.write(f"{spaces(indent+1)}DESTINATION {install_dir}\n")
+ cm_fh.write(f"{spaces(indent+1)}COMPONENT Devel\n")
+ cm_fh.write(f"{spaces(indent)})\n\n")
+
+ return target
+
+
+def write_example(
+ cm_fh: IO[str], scope: Scope, gui: bool = False, *, indent: int = 0, is_plugin: bool = False
+) -> str:
+ binary_name = scope.TARGET
+ assert binary_name
+
+ example_install_dir = scope.expandString("target.path")
+ if not example_install_dir:
+ example_install_dir = "examples"
+ example_install_dir = example_install_dir.replace("$$[QT_INSTALL_EXAMPLES]", "examples")
+
+ cm_fh.write(
+ "cmake_minimum_required(VERSION 3.14)\n"
+ f"project({binary_name} LANGUAGES CXX)\n\n"
+ "set(CMAKE_INCLUDE_CURRENT_DIR ON)\n\n"
+ "set(CMAKE_AUTOMOC ON)\n"
+ "set(CMAKE_AUTORCC ON)\n"
+ "set(CMAKE_AUTOUIC ON)\n\n"
+ f'set(INSTALL_EXAMPLEDIR "{example_install_dir}")\n\n'
+ )
+
+ recursive_evaluate_scope(scope)
+
+ # Get a flat list of all scopes but the main one:
+ scopes = flatten_scopes(scope)
+ # Merge scopes based on their conditions:
+ scopes = merge_scopes(scopes)
+ # Handle SOURCES -= foo calls, and merge scopes one more time
+ # because there might have been several files removed with the same
+ # scope condition.
+ handle_source_subtractions(scopes)
+ scopes = merge_scopes(scopes)
+
+ (public_libs, private_libs) = extract_cmake_libraries(scope, is_example=True)
+ write_find_package_section(cm_fh, public_libs, private_libs, indent=indent)
+
+ add_target = ""
+
+ qmldir = None
+ if is_plugin:
+ if "qml" in scope.get("QT"):
+ # Get the uri from the destination directory
+ dest_dir = scope.expandString("DESTDIR")
+ if not dest_dir:
+ dest_dir = "${CMAKE_CURRENT_BINARY_DIR}"
+ else:
+ uri = os.path.basename(dest_dir)
+ dest_dir = f"${{CMAKE_CURRENT_BINARY_DIR}}/{dest_dir}"
+
+ add_target = ""
+
+ qml_dir = None
+ qml_dir_dynamic_imports = False
+
+ qmldir_file_path_list = scope.get_files("qmldir.files")
+ assert len(qmldir_file_path_list) < 2, "File path must only contain one path"
+ qmldir_file_path = qmldir_file_path_list[0] if qmldir_file_path_list else "qmldir"
+ qmldir_file_path = os.path.join(os.getcwd(), qmldir_file_path[0])
+
+ if os.path.exists(qmldir_file_path):
+ qml_dir = QmlDir()
+ qml_dir.from_file(qmldir_file_path)
+ else:
+ dynamic_qmldir = scope.get("DYNAMIC_QMLDIR")
+ if not dynamic_qmldir:
+ return None
+ qml_dir = QmlDir()
+ qml_dir.from_lines(dynamic_qmldir)
+ qml_dir_dynamic_imports = True
+
+ add_target += "set(module_dynamic_qml_imports\n "
+ if len(qml_dir.imports) != 0:
+ add_target += "\n ".join(qml_dir.imports)
+ add_target += "\n)\n\n"
+
+ for sc in scopes[1:]:
+ import_list = []
+ qml_imports = sc.get("DYNAMIC_QMLDIR")
+ for qml_import in qml_imports:
+ if not qml_import.startswith("import "):
+ raise RuntimeError(
+ "Only qmldir import statements expected in conditional scope!"
+ )
+ import_list.append(qml_import[len("import ") :])
+ if len(import_list) == 0:
+ continue
+
+ assert sc.condition
+
+ add_target += f"if ({sc.condition})\n"
+ add_target += f" list(APPEND module_dynamic_qml_imports\n "
+ add_target += "\n ".join(import_list)
+ add_target += f"\n )\nendif()\n\n"
+
+ add_target += dedent(
+ f"""\
+ qt6_add_qml_module({binary_name}
+ OUTPUT_DIRECTORY "{dest_dir}"
+ VERSION 1.0
+ URI "{uri}"
+ """
+ )
+
+ if qml_dir != None:
+ if qml_dir.designer_supported:
+ add_target += " DESIGNER_SUPPORTED\n"
+ if len(qml_dir.classname) != 0:
+ add_target += f" CLASSNAME {qml_dir.classname}\n"
+ if len(qml_dir.depends) != 0:
+ add_target += " DEPENDENCIES\n"
+ for dep in qml_dir.depends:
+ add_target += f" {dep[0]}/{dep[1]}\n"
+ if len(qml_dir.type_names) == 0:
+ add_target += " SKIP_TYPE_REGISTRATION\n"
+ if len(qml_dir.imports) != 0 and not qml_dir_dynamic_imports:
+ qml_dir_imports_line = " \n".join(qml_dir.imports)
+ add_target += f" IMPORTS\n{qml_dir_imports_line}"
+ if qml_dir_dynamic_imports:
+ add_target += " IMPORTS ${module_dynamic_qml_imports}\n"
+
+ add_target += " INSTALL_LOCATION ${INSTALL_EXAMPLEDIR}\n)\n\n"
+ add_target += f"target_sources({binary_name} PRIVATE"
+ else:
+ add_target = f"add_library({binary_name} MODULE"
+
+ else:
+ add_target = f'add_{"qt_gui_" if gui else ""}executable({binary_name}'
+
+ write_all_source_file_lists(cm_fh, scope, add_target, indent=0)
+ cm_fh.write(")\n")
+
+ handling_first_scope = True
+
+ for scope in scopes:
+ # write wayland already has condition scope handling
+ write_wayland_part(cm_fh, binary_name, scope, indent=0)
+
+ # The following options do not
+ io_string = io.StringIO()
+ condition_str = ""
+ condition = "ON"
+ if scope.total_condition:
+ condition = map_to_cmake_condition(scope.total_condition)
+
+ if condition != "ON":
+ condition_str = f"\n{spaces(indent)}if({condition})\n"
+ indent += 1
+
+ if not handling_first_scope:
+ target_sources = f"target_sources({binary_name} PUBLIC"
+ write_all_source_file_lists(
+ io_string, scope, target_sources, indent=indent, footer=")\n"
+ )
+
+ write_include_paths(
+ io_string,
+ scope,
+ f"target_include_directories({binary_name} PUBLIC",
+ indent=indent,
+ footer=")\n",
+ )
+ write_defines(
+ io_string,
+ scope,
+ f"target_compile_definitions({binary_name} PUBLIC",
+ indent=indent,
+ footer=")\n",
+ )
+
+ (scope_public_libs, scope_private_libs) = extract_cmake_libraries(scope, is_example=True)
+
+ write_list(
+ io_string,
+ scope_private_libs,
+ "",
+ indent=indent,
+ header=f"target_link_libraries({binary_name} PRIVATE\n",
+ footer=")\n",
+ )
+ write_list(
+ io_string,
+ scope_public_libs,
+ "",
+ indent=indent,
+ header=f"target_link_libraries({binary_name} PUBLIC\n",
+ footer=")\n",
+ )
+ write_compile_options(
+ io_string, scope, f"target_compile_options({binary_name}", indent=indent, footer=")\n"
+ )
+
+ write_resources(io_string, binary_name, scope, indent=indent, is_example=True)
+ write_statecharts(io_string, binary_name, scope, indent=indent, is_example=True)
+ write_repc_files(io_string, binary_name, scope, indent=indent)
+
+ if condition != "ON":
+ indent -= 1
+ string = io_string.getvalue()
+ if len(string) != 0:
+ string = string.rstrip("\n")
+ cm_fh.write(f"{condition_str}{string}\n")
+ if condition != "ON":
+ cm_fh.write(f"{spaces(indent)}endif()\n")
+
+ handling_first_scope = False
+
+ if qmldir:
+ write_qml_plugin_epilogue(cm_fh, binary_name, scope, qmldir, indent)
+
+ cm_fh.write(
+ f"\ninstall(TARGETS {binary_name}\n"
+ f' RUNTIME DESTINATION "${{INSTALL_EXAMPLEDIR}}"\n'
+ f' BUNDLE DESTINATION "${{INSTALL_EXAMPLEDIR}}"\n'
+ f' LIBRARY DESTINATION "${{INSTALL_EXAMPLEDIR}}"\n'
+ f")\n"
+ )
+
+ return binary_name
+
+
+def write_plugin(cm_fh, scope, *, indent: int = 0) -> str:
+ plugin_name = scope.TARGET
+ assert plugin_name
+
+ extra = []
+
+ qmldir = None
+ plugin_type = scope.get_string("PLUGIN_TYPE")
+ is_qml_plugin = any("qml_plugin" == s for s in scope.get("_LOADED"))
+ plugin_function_name = get_cmake_api_call("qt_add_plugin")
+ if plugin_type:
+ extra.append(f"TYPE {plugin_type}")
+ elif is_qml_plugin:
+ plugin_function_name = get_cmake_api_call("qt_add_qml_module")
+ qmldir = write_qml_plugin(cm_fh, plugin_name, scope, indent=indent, extra_lines=extra)
+ else:
+ target_path = scope.expandString("target.path")
+ target_path = replace_path_constants(target_path, scope)
+ if target_path:
+ extra.append(f'INSTALL_DIRECTORY "{target_path}"')
+ else:
+ extra.append("SKIP_INSTALL")
+
+ plugin_class_name = scope.get_string("PLUGIN_CLASS_NAME")
+ if plugin_class_name:
+ extra.append(f"CLASS_NAME {plugin_class_name}")
+
+ if "static" in scope.get("CONFIG"):
+ extra.append("STATIC")
+
+ write_main_part(
+ cm_fh,
+ plugin_name,
+ "Plugin",
+ plugin_function_name,
+ scope,
+ indent=indent,
+ extra_lines=extra,
+ known_libraries={},
+ extra_keys=[],
+ )
+
+ if qmldir:
+ write_qml_plugin_epilogue(cm_fh, plugin_name, scope, qmldir, indent)
+
+ return plugin_name
+
+
+def write_qml_plugin(
+ cm_fh: IO[str],
+ target: str,
+ scope: Scope,
+ *,
+ extra_lines: Optional[List[str]] = None,
+ indent: int = 0,
+ **kwargs: Any,
+) -> Optional[QmlDir]:
+ # Collect other args if available
+ if extra_lines is None:
+ extra_lines = []
+ indent += 2
+
+ target_path = scope.get_string("TARGETPATH")
+ if target_path:
+ uri = target_path.replace("/", ".")
+ import_name = scope.get_string("IMPORT_NAME")
+ # Catch special cases such as foo.QtQuick.2.bar, which when converted
+ # into a target path via cmake will result in foo/QtQuick/2/bar, which is
+ # not what we want. So we supply the target path override.
+ target_path_from_uri = uri.replace(".", "/")
+ if target_path != target_path_from_uri:
+ extra_lines.append(f'TARGET_PATH "{target_path}"')
+ if import_name:
+ extra_lines.append(f'URI "{import_name}"')
+ else:
+ uri = re.sub("\\.\\d+", "", uri)
+ extra_lines.append(f'URI "{uri}"')
+
+ import_version = scope.get_string("IMPORT_VERSION")
+ if import_version:
+ import_version = import_version.replace(
+ "$$QT_MINOR_VERSION", "${CMAKE_PROJECT_VERSION_MINOR}"
+ )
+ extra_lines.append(f'VERSION "{import_version}"')
+
+ plugindump_dep = scope.get_string("QML_PLUGINDUMP_DEPENDENCIES")
+
+ if plugindump_dep:
+ extra_lines.append(f'QML_PLUGINDUMP_DEPENDENCIES "{plugindump_dep}"')
+
+ qml_dir = None
+ qmldir_file_path = os.path.join(os.getcwd(), "qmldir")
+ qml_dir_dynamic_imports = False
+ if os.path.exists(qmldir_file_path):
+ qml_dir = QmlDir()
+ qml_dir.from_file(qmldir_file_path)
+ else:
+ dynamic_qmldir = scope.get("DYNAMIC_QMLDIR")
+ if not dynamic_qmldir:
+ return None
+ qml_dir = QmlDir()
+ qml_dir.from_lines(dynamic_qmldir)
+ qml_dir_dynamic_imports = True
+
+ # Check scopes for conditional entries
+ scopes = flatten_scopes(scope)
+ cm_fh.write("set(module_dynamic_qml_imports\n ")
+ if len(qml_dir.imports) != 0:
+ cm_fh.write("\n ".join(qml_dir.imports))
+ cm_fh.write("\n)\n\n")
+
+ for sc in scopes[1:]:
+ import_list = []
+ qml_imports = sc.get("DYNAMIC_QMLDIR")
+ for qml_import in qml_imports:
+ if not qml_import.startswith("import "):
+ raise RuntimeError(
+ "Only qmldir import statements expected in conditional scope!"
+ )
+ import_list.append(qml_import[len("import ") :])
+ if len(import_list) == 0:
+ continue
+
+ assert sc.condition
+
+ cm_fh.write(f"if ({sc.condition})\n")
+ cm_fh.write(f" list(APPEND module_dynamic_qml_imports\n ")
+ cm_fh.write("\n ".join(import_list))
+ cm_fh.write(f"\n )\nendif()\n\n")
+
+ if qml_dir != None:
+ if qml_dir.designer_supported:
+ extra_lines.append("DESIGNER_SUPPORTED")
+ if len(qml_dir.classname) != 0:
+ extra_lines.append(f"CLASSNAME {qml_dir.classname}")
+ if len(qml_dir.depends) != 0:
+ extra_lines.append("DEPENDENCIES")
+ for dep in qml_dir.depends:
+ extra_lines.append(f" {dep[0]}/{dep[1]}")
+ if len(qml_dir.type_names) == 0:
+ extra_lines.append("SKIP_TYPE_REGISTRATION")
+ if len(qml_dir.imports) != 0 and not qml_dir_dynamic_imports:
+ qml_dir_imports_line = "\n ".join(qml_dir.imports)
+ extra_lines.append("IMPORTS\n " f"{qml_dir_imports_line}")
+ if qml_dir_dynamic_imports:
+ extra_lines.append("IMPORTS ${module_dynamic_qml_imports}")
+
+ return qml_dir
+
+
+def write_qml_plugin_epilogue(
+ cm_fh: IO[str], target: str, scope: Scope, qmldir: QmlDir, indent: int = 0
+):
+
+ qml_files = scope.get_files("QML_FILES", use_vpath=True)
+ if qml_files:
+
+ indent_0 = spaces(indent)
+ indent_1 = spaces(indent + 1)
+ # Quote file paths in case there are spaces.
+ qml_files_quoted = [f'"{qf}"' for qf in qml_files]
+
+ indented_qml_files = f"\n{indent_1}".join(qml_files_quoted)
+ cm_fh.write(f"\n{indent_0}set(qml_files\n{indent_1}" f"{indented_qml_files}\n)\n")
+
+ for qml_file in qml_files:
+ if qml_file in qmldir.type_names:
+ qmldir_file_info = qmldir.type_names[qml_file]
+ cm_fh.write(f"{indent_0}set_source_files_properties({qml_file} PROPERTIES\n")
+ cm_fh.write(f'{indent_1}QT_QML_SOURCE_VERSION "{qmldir_file_info.version}"\n')
+ # Only write typename if they are different, CMake will infer
+ # the name by default
+ if (
+ os.path.splitext(os.path.basename(qmldir_file_info.path))[0]
+ != qmldir_file_info.type_name
+ ):
+ cm_fh.write(f"{indent_1}QT_QML_SOURCE_TYPENAME {qmldir_file_info.type_name}\n")
+ if qmldir_file_info.singleton:
+ cm_fh.write(f"{indent_1}QT_QML_SINGLETON_TYPE TRUE\n")
+ if qmldir_file_info.internal:
+ cm_fh.write(f"{indent_1}QT_QML_INTERNAL_TYPE TRUE\n")
+ cm_fh.write(f"{indent_0})\n")
+
+ cm_fh.write(
+ f"\n{indent_0}qt6_target_qml_files({target}\n{indent_1}FILES\n"
+ f"{spaces(indent+2)}${{qml_files}}\n)\n"
+ )
+
+
+def handle_app_or_lib(
+ scope: Scope, cm_fh: IO[str], *, indent: int = 0, is_example: bool = False
+) -> None:
+ assert scope.TEMPLATE in ("app", "lib")
+
+ config = scope.get("CONFIG")
+ is_jar = "java" in config
+ is_lib = scope.TEMPLATE == "lib"
+ is_qml_plugin = any("qml_plugin" == s for s in scope.get("_LOADED"))
+ is_plugin = "plugin" in config
+ is_qt_plugin = any("qt_plugin" == s for s in scope.get("_LOADED")) or is_qml_plugin
+ target = ""
+ gui = all(
+ val not in config for val in ["console", "cmdline", "-app_bundle"]
+ ) and "testlib" not in scope.expand("QT")
+
+ if is_jar:
+ write_jar(cm_fh, scope, indent=indent)
+ elif is_example:
+ target = write_example(cm_fh, scope, gui, indent=indent, is_plugin=is_plugin)
+ elif is_qt_plugin:
+ assert not is_example
+ target = write_plugin(cm_fh, scope, indent=indent)
+ elif (is_lib and "qt_module" not in scope.get("_LOADED")) or is_plugin:
+ assert not is_example
+ target = write_generic_library(cm_fh, scope, indent=indent)
+ elif is_lib or "qt_module" in scope.get("_LOADED"):
+ assert not is_example
+ target = write_module(cm_fh, scope, indent=indent)
+ elif "qt_tool" in scope.get("_LOADED"):
+ assert not is_example
+ target = write_tool(cm_fh, scope, indent=indent)
+ else:
+ if "testcase" in config or "testlib" in config or "qmltestcase" in config:
+ assert not is_example
+ target = write_test(cm_fh, scope, gui, indent=indent)
+ else:
+ target = write_binary(cm_fh, scope, gui, indent=indent)
+
+ # ind = spaces(indent)
+ cmake_api_call = get_cmake_api_call("qt_add_docs")
+ write_source_file_list(
+ cm_fh,
+ scope,
+ "",
+ ["QMAKE_DOCS"],
+ indent,
+ header=f"{cmake_api_call}({target}\n",
+ footer=")\n",
+ )
+
+
+def handle_top_level_repo_project(scope: Scope, cm_fh: IO[str]):
+ # qtdeclarative
+ project_file_name = os.path.splitext(os.path.basename(scope.file_absolute_path))[0]
+
+ # declarative
+ file_name_without_qt_prefix = project_file_name[2:]
+
+ # Qt::Declarative
+ qt_lib = map_qt_library(file_name_without_qt_prefix)
+
+ # Found a mapping, adjust name.
+ if qt_lib != file_name_without_qt_prefix:
+ # QtDeclarative
+ qt_lib = re.sub(r":", r"", qt_lib)
+
+ # Declarative
+ qt_lib_no_prefix = qt_lib[2:]
+ else:
+ qt_lib += "_FIXME"
+ qt_lib_no_prefix = qt_lib
+
+ header = dedent(
+ f"""\
+ cmake_minimum_required(VERSION {cmake_version_string})
+
+ project({qt_lib}
+ VERSION 6.0.0
+ DESCRIPTION "Qt {qt_lib_no_prefix} Libraries"
+ HOMEPAGE_URL "https://qt.io/"
+ LANGUAGES CXX C
+ )
+
+ find_package(Qt6 ${{PROJECT_VERSION}} CONFIG REQUIRED COMPONENTS BuildInternals Core SET_ME_TO_SOMETHING_USEFUL)
+ find_package(Qt6 ${{PROJECT_VERSION}} CONFIG OPTIONAL_COMPONENTS SET_ME_TO_SOMETHING_USEFUL)
+
+ """
+ )
+
+ build_repo = dedent(
+ f"""\
+ qt_build_repo()
+ """
+ )
+
+ cm_fh.write(f"{header}{expand_project_requirements(scope)}{build_repo}")
+
+
+def find_top_level_repo_project_file(project_file_path: str = "") -> Optional[str]:
+ qmake_conf_path = find_qmake_conf(project_file_path)
+ qmake_dir = os.path.dirname(qmake_conf_path)
+
+ # Hope to a programming god that there's only one .pro file at the
+ # top level directory of repository.
+ glob_result = glob.glob(os.path.join(qmake_dir, "*.pro"))
+ if len(glob_result) > 0:
+ return glob_result[0]
+ return None
+
+
+def handle_top_level_repo_tests_project(scope: Scope, cm_fh: IO[str]):
+ top_level_project_path = find_top_level_repo_project_file(scope.file_absolute_path)
+ if top_level_project_path:
+ # qtdeclarative
+ file_name = os.path.splitext(os.path.basename(top_level_project_path))[0]
+
+ # declarative
+ file_name_without_qt = file_name[2:]
+
+ # Qt::Declarative
+ qt_lib = map_qt_library(file_name_without_qt)
+
+ # Found a mapping, adjust name.
+ if qt_lib != file_name_without_qt:
+ # QtDeclarative
+ qt_lib = f'{re.sub(r":", r"", qt_lib)}{"Tests"}'
+ else:
+ qt_lib += "Tests_FIXME"
+ else:
+ qt_lib = "Tests_FIXME"
+
+ requires_content = expand_project_requirements(scope, skip_message=True)
+ if requires_content:
+ requires_content = f"\n\n{textwrap_indent(requires_content, spaces(3))}"
+
+ content = dedent(
+ f"""\
+ if(QT_BUILD_STANDALONE_TESTS)
+ # Add qt_find_package calls for extra dependencies that need to be found when building
+ # the standalone tests here.
+ endif()
+ qt_build_tests()
+"""
+ )
+
+ cm_fh.write(f"{content}")
+
+
+def write_regular_cmake_target_scope_section(
+ scope: Scope, cm_fh: IO[str], indent: int = 0, skip_sources: bool = False
+):
+ if not skip_sources:
+ target_sources = "target_sources(${PROJECT_NAME} PUBLIC"
+ write_all_source_file_lists(cm_fh, scope, target_sources, indent=indent, footer=")")
+
+ write_include_paths(
+ cm_fh,
+ scope,
+ f"target_include_directories(${{PROJECT_NAME}} PUBLIC",
+ indent=indent,
+ footer=")",
+ )
+ write_defines(
+ cm_fh,
+ scope,
+ f"target_compile_definitions(${{PROJECT_NAME}} PUBLIC",
+ indent=indent,
+ footer=")",
+ )
+ (public_libs, private_libs) = extract_cmake_libraries(scope)
+ write_list(
+ cm_fh,
+ private_libs,
+ "",
+ indent=indent,
+ header=f"target_link_libraries(${{PROJECT_NAME}} PRIVATE\n",
+ footer=")",
+ )
+ write_list(
+ cm_fh,
+ public_libs,
+ "",
+ indent=indent,
+ header=f"target_link_libraries(${{PROJECT_NAME}} PUBLIC\n",
+ footer=")",
+ )
+ write_compile_options(
+ cm_fh, scope, f"target_compile_options(${{PROJECT_NAME}}", indent=indent, footer=")"
+ )
+
+
+def handle_config_test_project(scope: Scope, cm_fh: IO[str]):
+ project_name = os.path.splitext(os.path.basename(scope.file_absolute_path))[0]
+ content = (
+ f"cmake_minimum_required(VERSION 3.14.0)\n"
+ f"project(config_test_{project_name} LANGUAGES CXX)\n"
+ )
+ cm_fh.write(f"{content}\n")
+
+ # Remove default QT libs.
+ scope._append_operation("QT", RemoveOperation(["core", "gui"]))
+
+ add_target = f"add_executable(${{PROJECT_NAME}}"
+
+ temp_buffer = io.StringIO()
+ write_all_source_file_lists(temp_buffer, scope, add_target, indent=0)
+ buffer_value = temp_buffer.getvalue()
+
+ if buffer_value:
+ cm_fh.write(buffer_value)
+ else:
+ cm_fh.write(add_target)
+ cm_fh.write(")\n")
+
+ indent = 0
+ write_regular_cmake_target_scope_section(scope, cm_fh, indent, skip_sources=True)
+
+ recursive_evaluate_scope(scope)
+ scopes = flatten_scopes(scope)
+ scopes = merge_scopes(scopes)
+
+ assert len(scopes)
+ assert scopes[0].total_condition == "ON"
+
+ for c in scopes[1:]:
+ extend_scope_io_string = io.StringIO()
+ write_regular_cmake_target_scope_section(c, extend_scope_io_string, indent=indent + 1)
+ extend_string = extend_scope_io_string.getvalue()
+
+ if extend_string:
+ assert c.total_condition, "Cannot write if with empty condition"
+ extend_scope = (
+ f"\nif({map_to_cmake_condition(c.total_condition)})\n"
+ f"{extend_string}"
+ f"endif()\n"
+ )
+ cm_fh.write(extend_scope)
+
+
+def cmakeify_scope(
+ scope: Scope, cm_fh: IO[str], *, indent: int = 0, is_example: bool = False
+) -> None:
+ template = scope.TEMPLATE
+
+ temp_buffer = io.StringIO()
+
+ # Handle top level repo project in a special way.
+ if is_top_level_repo_project(scope.file_absolute_path):
+ handle_top_level_repo_project(scope, temp_buffer)
+ # Same for top-level tests.
+ elif is_top_level_repo_tests_project(scope.file_absolute_path):
+ handle_top_level_repo_tests_project(scope, temp_buffer)
+ elif is_config_test_project(scope.file_absolute_path):
+ handle_config_test_project(scope, temp_buffer)
+ elif template == "subdirs":
+ handle_subdir(scope, temp_buffer, indent=indent, is_example=is_example)
+ elif template in ("app", "lib"):
+ handle_app_or_lib(scope, temp_buffer, indent=indent, is_example=is_example)
+ else:
+ print(f" XXXX: {scope.file}: Template type {template} not yet supported.")
+
+ buffer_value = temp_buffer.getvalue()
+
+ if is_top_level_repo_examples_project(scope.file_absolute_path):
+ # Wrap top level examples project with some commands which
+ # are necessary to build examples as part of the overall
+ # build.
+ buffer_value = f"qt_examples_build_begin()\n\n{buffer_value}\nqt_examples_build_end()\n"
+
+ cm_fh.write(buffer_value)
+
+
+def generate_new_cmakelists(scope: Scope, *, is_example: bool = False, debug: bool = False) -> None:
+ if debug:
+ print("Generating CMakeLists.gen.txt")
+ with open(scope.generated_cmake_lists_path, "w") as cm_fh:
+ assert scope.file
+ cm_fh.write(f"# Generated from {os.path.basename(scope.file)}.\n\n")
+
+ is_example_heuristic = is_example_project(scope.file_absolute_path)
+ final_is_example_decision = is_example or is_example_heuristic
+ cmakeify_scope(scope, cm_fh, is_example=final_is_example_decision)
+
+
+def do_include(scope: Scope, *, debug: bool = False) -> None:
+ for c in scope.children:
+ do_include(c)
+
+ for include_index, include_file in enumerate(scope.get_files("_INCLUDED", is_include=True)):
+ if not include_file:
+ continue
+ if not os.path.isfile(include_file):
+ generated_config_pri_pattern = re.compile(r"qt.+?-config\.pri$")
+ match_result = re.search(generated_config_pri_pattern, include_file)
+ if not match_result:
+ print(f" XXXX: Failed to include {include_file}.")
+ continue
+
+ include_op = scope._get_operation_at_index("_INCLUDED", include_index)
+ include_line_no = include_op._line_no
+
+ include_result, project_file_content = parseProFile(include_file, debug=debug)
+ include_scope = Scope.FromDict(
+ None,
+ include_file,
+ include_result.asDict().get("statements"),
+ "",
+ scope.basedir,
+ project_file_content=project_file_content,
+ parent_include_line_no=include_line_no,
+ ) # This scope will be merged into scope!
+
+ do_include(include_scope)
+
+ scope.merge(include_scope)
+
+
+def copy_generated_file_to_final_location(
+ scope: Scope, keep_temporary_files=False, debug: bool = False
+) -> None:
+ if debug:
+ print(f"Copying {scope.generated_cmake_lists_path} to {scope.original_cmake_lists_path}")
+ copyfile(scope.generated_cmake_lists_path, scope.original_cmake_lists_path)
+ if not keep_temporary_files:
+ os.remove(scope.generated_cmake_lists_path)
+
+
+def cmake_project_has_skip_marker(project_file_path: str = "") -> bool:
+ dir_path = os.path.dirname(project_file_path)
+ cmake_project_path = os.path.join(dir_path, "CMakeLists.txt")
+ if not os.path.exists(cmake_project_path):
+ return False
+
+ with open(cmake_project_path, "r") as file_fd:
+ contents = file_fd.read()
+
+ if "# special case skip regeneration" in contents:
+ return True
+
+ return False
+
+
+def should_convert_project(project_file_path: str = "", ignore_skip_marker: bool = False) -> bool:
+ qmake_conf_path = find_qmake_conf(project_file_path)
+ qmake_conf_dir_path = os.path.dirname(qmake_conf_path)
+
+ project_relative_path = os.path.relpath(project_file_path, qmake_conf_dir_path)
+
+ # Skip cmake auto tests, they should not be converted.
+ if project_relative_path.startswith("tests/auto/cmake"):
+ return False
+ if project_relative_path.startswith("tests/auto/installed_cmake"):
+ return False
+
+ # Skip qmake testdata projects.
+ if project_relative_path.startswith("tests/auto/tools/qmake/testdata"):
+ return False
+
+ # Skip certain config tests.
+ config_tests = [
+ # Relative to qtbase/config.tests
+ "arch/arch.pro",
+ "avx512/avx512.pro",
+ "stl/stl.pro",
+ "verifyspec/verifyspec.pro",
+ "x86_simd/x86_simd.pro",
+ # Relative to repo src dir
+ "config.tests/hostcompiler/hostcompiler.pro",
+ ]
+ skip_certain_tests = any(project_relative_path.startswith(c) for c in config_tests)
+ if skip_certain_tests:
+ return False
+
+ # Skip if CMakeLists.txt in the same path as project_file_path has a
+ # special skip marker.
+ if not ignore_skip_marker and cmake_project_has_skip_marker(project_file_path):
+ return False
+
+ return True
+
+
+def should_convert_project_after_parsing(
+ file_scope: Scope, skip_subdirs_project: bool = False
+) -> bool:
+ template = file_scope.TEMPLATE
+ if template == "subdirs" and skip_subdirs_project:
+ return False
+ return True
+
+
+def main() -> None:
+ # Be sure of proper Python version
+ assert sys.version_info >= (3, 7)
+
+ args = _parse_commandline()
+
+ debug_parsing = args.debug_parser or args.debug
+ if args.skip_condition_cache:
+ set_condition_simplified_cache_enabled(False)
+
+ backup_current_dir = os.getcwd()
+
+ for file in args.files:
+ new_current_dir = os.path.dirname(file)
+ file_relative_path = os.path.basename(file)
+ if new_current_dir:
+ os.chdir(new_current_dir)
+
+ project_file_absolute_path = os.path.abspath(file_relative_path)
+ if not should_convert_project(project_file_absolute_path, args.ignore_skip_marker):
+ print(f'Skipping conversion of project: "{project_file_absolute_path}"')
+ continue
+
+ parseresult, project_file_content = parseProFile(file_relative_path, debug=debug_parsing)
+
+ # If CMake api version is given on command line, that means the
+ # user wants to force use that api version.
+ global cmake_api_version
+ if args.api_version:
+ cmake_api_version = args.api_version
+ else:
+ # Otherwise detect the api version in the old CMakeLists.txt
+ # if it exsists.
+ detected_cmake_api_version = detect_cmake_api_version_used_in_file_content(
+ file_relative_path
+ )
+ if detected_cmake_api_version:
+ cmake_api_version = detected_cmake_api_version
+
+ if args.debug_parse_result or args.debug:
+ print("\n\n#### Parser result:")
+ print(parseresult)
+ print("\n#### End of parser result.\n")
+ if args.debug_parse_dictionary or args.debug:
+ print("\n\n####Parser result dictionary:")
+ print(parseresult.asDict())
+ print("\n#### End of parser result dictionary.\n")
+
+ file_scope = Scope.FromDict(
+ None,
+ file_relative_path,
+ parseresult.asDict().get("statements"),
+ project_file_content=project_file_content,
+ )
+
+ if args.debug_pro_structure or args.debug:
+ print("\n\n#### .pro/.pri file structure:")
+ file_scope.dump()
+ print("\n#### End of .pro/.pri file structure.\n")
+
+ do_include(file_scope, debug=debug_parsing)
+
+ if args.debug_full_pro_structure or args.debug:
+ print("\n\n#### Full .pro/.pri file structure:")
+ file_scope.dump()
+ print("\n#### End of full .pro/.pri file structure.\n")
+
+ if not should_convert_project_after_parsing(file_scope, args.skip_subdirs_project):
+ print(f'Skipping conversion of project: "{project_file_absolute_path}"')
+ continue
+
+ generate_new_cmakelists(file_scope, is_example=args.is_example, debug=args.debug)
+
+ copy_generated_file = True
+ if not args.skip_special_case_preservation:
+ debug_special_case = args.debug_special_case_preservation or args.debug
+ handler = SpecialCaseHandler(
+ file_scope.original_cmake_lists_path,
+ file_scope.generated_cmake_lists_path,
+ file_scope.basedir,
+ keep_temporary_files=args.keep_temporary_files,
+ debug=debug_special_case,
+ )
+
+ copy_generated_file = handler.handle_special_cases()
+
+ if copy_generated_file:
+ copy_generated_file_to_final_location(
+ file_scope, keep_temporary_files=args.keep_temporary_files
+ )
+ os.chdir(backup_current_dir)
+
+
+if __name__ == "__main__":
+ main()
diff --git a/util/cmake/pro_conversion_rate.py b/util/cmake/pro_conversion_rate.py
new file mode 100755
index 0000000000..3c0c7e3070
--- /dev/null
+++ b/util/cmake/pro_conversion_rate.py
@@ -0,0 +1,235 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2019 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+from __future__ import annotations
+
+"""
+This utility script shows statistics about
+converted .pro -> CMakeLists.txt files.
+
+To execute: python3 pro_conversion_rate.py <src dir>
+where <src dir> can be any qt source directory. For better statistics,
+specify a module root source dir (like ./qtbase or ./qtsvg).
+
+"""
+
+from argparse import ArgumentParser
+
+import os
+import typing
+from typing import Dict, Union
+from timeit import default_timer
+
+
+def _parse_commandline():
+ parser = ArgumentParser(description="Find pro files for which there are no CMakeLists.txt.")
+ parser.add_argument(
+ "source_directory", metavar="<src dir>", type=str, help="The source directory"
+ )
+
+ return parser.parse_args()
+
+
+class Blacklist:
+ """ Class to check if a certain dir_name / dir_path is blacklisted """
+
+ def __init__(self, names: typing.List[str], path_parts: typing.List[str]):
+ self.names = names
+ self.path_parts = path_parts
+
+ # The lookup algorithm
+ self.lookup = self.is_blacklisted_part
+ self.tree = None
+
+ try:
+ # If package is available, use Aho-Corasick algorithm,
+ from ahocorapy.keywordtree import KeywordTree # type: ignore
+
+ self.tree = KeywordTree(case_insensitive=True)
+
+ for p in self.path_parts:
+ self.tree.add(p)
+ self.tree.finalize()
+
+ self.lookup = self.is_blacklisted_part_aho
+ except ImportError:
+ pass
+
+ def is_blacklisted(self, dir_name: str, dir_path: str) -> bool:
+ # First check if exact dir name is blacklisted.
+ if dir_name in self.names:
+ return True
+
+ # Check if a path part is blacklisted (e.g. util/cmake)
+ return self.lookup(dir_path)
+
+ def is_blacklisted_part(self, dir_path: str) -> bool:
+ if any(part in dir_path for part in self.path_parts):
+ return True
+ return False
+
+ def is_blacklisted_part_aho(self, dir_path: str) -> bool:
+ return self.tree.search(dir_path) is not None # type: ignore
+
+
+def recursive_scan(path: str, extension: str, result_paths: typing.List[str], blacklist: Blacklist):
+ """ Find files ending with a certain extension, filtering out blacklisted entries """
+ try:
+ for entry in os.scandir(path):
+ if entry.is_file() and entry.path.endswith(extension):
+ result_paths.append(entry.path)
+ elif entry.is_dir():
+ if blacklist.is_blacklisted(entry.name, entry.path):
+ continue
+ recursive_scan(entry.path, extension, result_paths, blacklist)
+ except Exception as e:
+ print(e)
+
+
+def check_for_cmake_project(pro_path: str) -> bool:
+ pro_dir_name = os.path.dirname(pro_path)
+ cmake_project_path = os.path.join(pro_dir_name, "CMakeLists.txt")
+ return os.path.exists(cmake_project_path)
+
+
+def compute_stats(
+ src_path: str,
+ pros_with_missing_project: typing.List[str],
+ total_pros: int,
+ existing_pros: int,
+ missing_pros: int,
+) -> dict:
+ stats: Dict[str, Dict[str, Union[str, int, float]]] = {}
+ stats["total projects"] = {"label": "Total pro files found", "value": total_pros}
+ stats["existing projects"] = {
+ "label": "Existing CMakeLists.txt files found",
+ "value": existing_pros,
+ }
+ stats["missing projects"] = {
+ "label": "Missing CMakeLists.txt files found",
+ "value": missing_pros,
+ }
+ stats["missing examples"] = {"label": "Missing examples", "value": 0}
+ stats["missing tests"] = {"label": "Missing tests", "value": 0}
+ stats["missing src"] = {"label": "Missing src/**/**", "value": 0}
+ stats["missing plugins"] = {"label": "Missing plugins", "value": 0}
+
+ for p in pros_with_missing_project:
+ rel_path = os.path.relpath(p, src_path)
+ if rel_path.startswith("examples"):
+ assert isinstance(stats["missing examples"]["value"], int)
+ stats["missing examples"]["value"] += 1
+ elif rel_path.startswith("tests"):
+ assert isinstance(stats["missing tests"]["value"], int)
+ stats["missing tests"]["value"] += 1
+ elif rel_path.startswith(os.path.join("src", "plugins")):
+ assert isinstance(stats["missing plugins"]["value"], int)
+ stats["missing plugins"]["value"] += 1
+ elif rel_path.startswith("src"):
+ assert isinstance(stats["missing src"]["value"], int)
+ stats["missing src"]["value"] += 1
+
+ for stat in stats:
+ if int(stats[stat]["value"]) > 0:
+ stats[stat]["percentage"] = round(float(stats[stat]["value"]) * 100 / total_pros, 2)
+ return stats
+
+
+def print_stats(
+ src_path: str,
+ pros_with_missing_project: typing.List[str],
+ stats: dict,
+ scan_time: float,
+ script_time: float,
+):
+
+ if stats["total projects"]["value"] == 0:
+ print("No .pro files found. Did you specify a correct source path?")
+ return
+
+ if stats["total projects"]["value"] == stats["existing projects"]["value"]:
+ print("All projects were converted.")
+ else:
+ print("Missing CMakeLists.txt files for the following projects: \n")
+
+ for p in pros_with_missing_project:
+ rel_path = os.path.relpath(p, src_path)
+ print(rel_path)
+
+ print("\nStatistics: \n")
+
+ for stat in stats:
+ if stats[stat]["value"] > 0:
+ print(
+ f"{stats[stat]['label']:<40}: {stats[stat]['value']} ({stats[stat]['percentage']}%)"
+ )
+
+ print(f"\n{'Scan time':<40}: {scan_time:.10f} seconds")
+ print(f"{'Total script time':<40}: {script_time:.10f} seconds")
+
+
+def main():
+ args = _parse_commandline()
+ src_path = os.path.abspath(args.source_directory)
+ pro_paths = []
+
+ extension = ".pro"
+
+ blacklist_names = ["config.tests", "doc", "3rdparty", "angle"]
+ blacklist_path_parts = [os.path.join("util", "cmake")]
+
+ script_start_time = default_timer()
+ blacklist = Blacklist(blacklist_names, blacklist_path_parts)
+
+ scan_time_start = default_timer()
+ recursive_scan(src_path, extension, pro_paths, blacklist)
+ scan_time_end = default_timer()
+ scan_time = scan_time_end - scan_time_start
+
+ total_pros = len(pro_paths)
+
+ pros_with_missing_project = []
+ for pro_path in pro_paths:
+ if not check_for_cmake_project(pro_path):
+ pros_with_missing_project.append(pro_path)
+
+ missing_pros = len(pros_with_missing_project)
+ existing_pros = total_pros - missing_pros
+
+ stats = compute_stats(
+ src_path, pros_with_missing_project, total_pros, existing_pros, missing_pros
+ )
+ script_end_time = default_timer()
+ script_time = script_end_time - script_start_time
+
+ print_stats(src_path, pros_with_missing_project, stats, scan_time, script_time)
+
+
+if __name__ == "__main__":
+ main()
diff --git a/util/cmake/qmake_parser.py b/util/cmake/qmake_parser.py
new file mode 100644
index 0000000000..5cb629a495
--- /dev/null
+++ b/util/cmake/qmake_parser.py
@@ -0,0 +1,388 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2018 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+import collections
+import os
+import re
+from itertools import chain
+from typing import Tuple
+
+import pyparsing as pp # type: ignore
+
+from helper import _set_up_py_parsing_nicer_debug_output
+
+_set_up_py_parsing_nicer_debug_output(pp)
+
+
+def fixup_linecontinuation(contents: str) -> str:
+ # Remove all line continuations, aka a backslash followed by
+ # a newline character with an arbitrary amount of whitespace
+ # between the backslash and the newline.
+ # This greatly simplifies the qmake parsing grammar.
+ contents = re.sub(r"([^\t ])\\[ \t]*\n", "\\1 ", contents)
+ contents = re.sub(r"\\[ \t]*\n", "", contents)
+ return contents
+
+
+def fixup_comments(contents: str) -> str:
+ # Get rid of completely commented out lines.
+ # So any line which starts with a '#' char and ends with a new line
+ # will be replaced by a single new line.
+ #
+ # This is needed because qmake syntax is weird. In a multi line
+ # assignment (separated by backslashes and newlines aka
+ # # \\\n ), if any of the lines are completely commented out, in
+ # principle the assignment should fail.
+ #
+ # It should fail because you would have a new line separating
+ # the previous value from the next value, and the next value would
+ # not be interpreted as a value, but as a new token / operation.
+ # qmake is lenient though, and accepts that, so we need to take
+ # care of it as well, as if the commented line didn't exist in the
+ # first place.
+
+ contents = re.sub(r"\n#[^\n]*?\n", "\n", contents, re.DOTALL)
+ return contents
+
+
+def flatten_list(l):
+ """ Flattens an irregular nested list into a simple list."""
+ for el in l:
+ if isinstance(el, collections.abc.Iterable) and not isinstance(el, (str, bytes)):
+ yield from flatten_list(el)
+ else:
+ yield el
+
+
+def handle_function_value(group: pp.ParseResults):
+ function_name = group[0]
+ function_args = group[1]
+ if function_name == "qtLibraryTarget":
+ if len(function_args) > 1:
+ raise RuntimeError(
+ "Don't know what to with more than one function argument "
+ "for $$qtLibraryTarget()."
+ )
+ return str(function_args[0])
+
+ if function_name == "quote":
+ # Do nothing, just return a string result
+ return str(group)
+
+ if function_name == "files":
+ return str(function_args[0])
+
+ if function_name == "basename":
+ if len(function_args) != 1:
+ print(f"XXXX basename with more than one argument")
+ if function_args[0] == "_PRO_FILE_PWD_":
+ return os.path.basename(os.getcwd())
+ print(f"XXXX basename with value other than _PRO_FILE_PWD_")
+ return os.path.basename(str(function_args[0]))
+
+ if isinstance(function_args, pp.ParseResults):
+ function_args = list(flatten_list(function_args.asList()))
+
+ # For other functions, return the whole expression as a string.
+ return f"$${function_name}({' '.join(function_args)})"
+
+
+class QmakeParser:
+ def __init__(self, *, debug: bool = False) -> None:
+ self.debug = debug
+ self._Grammar = self._generate_grammar()
+
+ def _generate_grammar(self):
+ # Define grammar:
+ pp.ParserElement.setDefaultWhitespaceChars(" \t")
+
+ def add_element(name: str, value: pp.ParserElement):
+ nonlocal self
+ if self.debug:
+ value.setName(name)
+ value.setDebug()
+ return value
+
+ EOL = add_element("EOL", pp.Suppress(pp.LineEnd()))
+ Else = add_element("Else", pp.Keyword("else"))
+ Identifier = add_element(
+ "Identifier", pp.Word(f"{pp.alphas}_", bodyChars=pp.alphanums + "_-./")
+ )
+ BracedValue = add_element(
+ "BracedValue",
+ pp.nestedExpr(
+ ignoreExpr=pp.quotedString
+ | pp.QuotedString(
+ quoteChar="$(", endQuoteChar=")", escQuote="\\", unquoteResults=False
+ )
+ ).setParseAction(lambda s, l, t: ["(", *t[0], ")"]),
+ )
+
+ Substitution = add_element(
+ "Substitution",
+ pp.Combine(
+ pp.Literal("$")
+ + (
+ (
+ (pp.Literal("$") + Identifier + pp.Optional(pp.nestedExpr()))
+ | (pp.Literal("(") + Identifier + pp.Literal(")"))
+ | (pp.Literal("{") + Identifier + pp.Literal("}"))
+ | (
+ pp.Literal("$")
+ + pp.Literal("{")
+ + Identifier
+ + pp.Optional(pp.nestedExpr())
+ + pp.Literal("}")
+ )
+ | (pp.Literal("$") + pp.Literal("[") + Identifier + pp.Literal("]"))
+ )
+ )
+ ),
+ )
+ LiteralValuePart = add_element(
+ "LiteralValuePart", pp.Word(pp.printables, excludeChars="$#{}()")
+ )
+ SubstitutionValue = add_element(
+ "SubstitutionValue",
+ pp.Combine(pp.OneOrMore(Substitution | LiteralValuePart | pp.Literal("$"))),
+ )
+ FunctionValue = add_element(
+ "FunctionValue",
+ pp.Group(
+ pp.Suppress(pp.Literal("$") + pp.Literal("$"))
+ + Identifier
+ + pp.nestedExpr() # .setParseAction(lambda s, l, t: ['(', *t[0], ')'])
+ ).setParseAction(lambda s, l, t: handle_function_value(*t)),
+ )
+ Value = add_element(
+ "Value",
+ pp.NotAny(Else | pp.Literal("}") | EOL)
+ + (
+ pp.QuotedString(quoteChar='"', escChar="\\")
+ | FunctionValue
+ | SubstitutionValue
+ | BracedValue
+ ),
+ )
+
+ Values = add_element("Values", pp.ZeroOrMore(Value)("value"))
+
+ Op = add_element(
+ "OP",
+ pp.Literal("=")
+ | pp.Literal("-=")
+ | pp.Literal("+=")
+ | pp.Literal("*=")
+ | pp.Literal("~="),
+ )
+
+ Key = add_element("Key", Identifier)
+
+ Operation = add_element(
+ "Operation", Key("key") + pp.locatedExpr(Op)("operation") + Values("value")
+ )
+ CallArgs = add_element("CallArgs", pp.nestedExpr())
+
+ def parse_call_args(results):
+ out = ""
+ for item in chain(*results):
+ if isinstance(item, str):
+ out += item
+ else:
+ out += "(" + parse_call_args(item) + ")"
+ return out
+
+ CallArgs.setParseAction(parse_call_args)
+
+ Load = add_element("Load", pp.Keyword("load") + CallArgs("loaded"))
+ Include = add_element(
+ "Include", pp.Keyword("include") + pp.locatedExpr(CallArgs)("included")
+ )
+ Option = add_element("Option", pp.Keyword("option") + CallArgs("option"))
+ RequiresCondition = add_element("RequiresCondition", pp.originalTextFor(pp.nestedExpr()))
+
+ def parse_requires_condition(s, l, t):
+ # The following expression unwraps the condition via the additional info
+ # set by originalTextFor.
+ condition_without_parentheses = s[t._original_start + 1 : t._original_end - 1]
+
+ # And this replaces the colons with '&&' similar how it's done for 'Condition'.
+ condition_without_parentheses = (
+ condition_without_parentheses.strip().replace(":", " && ").strip(" && ")
+ )
+ return condition_without_parentheses
+
+ RequiresCondition.setParseAction(parse_requires_condition)
+ Requires = add_element(
+ "Requires", pp.Keyword("requires") + RequiresCondition("project_required_condition")
+ )
+
+ # ignore the whole thing...
+ DefineTestDefinition = add_element(
+ "DefineTestDefinition",
+ pp.Suppress(
+ pp.Keyword("defineTest")
+ + CallArgs
+ + pp.nestedExpr(opener="{", closer="}", ignoreExpr=pp.LineEnd())
+ ),
+ )
+
+ # ignore the whole thing...
+ ForLoop = add_element(
+ "ForLoop",
+ pp.Suppress(
+ pp.Keyword("for")
+ + CallArgs
+ + pp.nestedExpr(opener="{", closer="}", ignoreExpr=pp.LineEnd())
+ ),
+ )
+
+ # ignore the whole thing...
+ ForLoopSingleLine = add_element(
+ "ForLoopSingleLine",
+ pp.Suppress(pp.Keyword("for") + CallArgs + pp.Literal(":") + pp.SkipTo(EOL)),
+ )
+
+ # ignore the whole thing...
+ FunctionCall = add_element("FunctionCall", pp.Suppress(Identifier + pp.nestedExpr()))
+
+ Scope = add_element("Scope", pp.Forward())
+
+ Statement = add_element(
+ "Statement",
+ pp.Group(
+ Load
+ | Include
+ | Option
+ | Requires
+ | ForLoop
+ | ForLoopSingleLine
+ | DefineTestDefinition
+ | FunctionCall
+ | Operation
+ ),
+ )
+ StatementLine = add_element("StatementLine", Statement + (EOL | pp.FollowedBy("}")))
+ StatementGroup = add_element(
+ "StatementGroup", pp.ZeroOrMore(StatementLine | Scope | pp.Suppress(EOL))
+ )
+
+ Block = add_element(
+ "Block",
+ pp.Suppress("{")
+ + pp.Optional(EOL)
+ + StatementGroup
+ + pp.Optional(EOL)
+ + pp.Suppress("}")
+ + pp.Optional(EOL),
+ )
+
+ ConditionEnd = add_element(
+ "ConditionEnd",
+ pp.FollowedBy(
+ (pp.Optional(pp.White()) + (pp.Literal(":") | pp.Literal("{") | pp.Literal("|")))
+ ),
+ )
+
+ ConditionPart1 = add_element(
+ "ConditionPart1", (pp.Optional("!") + Identifier + pp.Optional(BracedValue))
+ )
+ ConditionPart2 = add_element("ConditionPart2", pp.CharsNotIn("#{}|:=\\\n"))
+ ConditionPart = add_element(
+ "ConditionPart", (ConditionPart1 ^ ConditionPart2) + ConditionEnd
+ )
+
+ ConditionOp = add_element("ConditionOp", pp.Literal("|") ^ pp.Literal(":"))
+ ConditionWhiteSpace = add_element(
+ "ConditionWhiteSpace", pp.Suppress(pp.Optional(pp.White(" ")))
+ )
+
+ ConditionRepeated = add_element(
+ "ConditionRepeated", pp.ZeroOrMore(ConditionOp + ConditionWhiteSpace + ConditionPart)
+ )
+
+ Condition = add_element("Condition", pp.Combine(ConditionPart + ConditionRepeated))
+ Condition.setParseAction(lambda x: " ".join(x).strip().replace(":", " && ").strip(" && "))
+
+ # Weird thing like write_file(a)|error() where error() is the alternative condition
+ # which happens to be a function call. In this case there is no scope, but our code expects
+ # a scope with a list of statements, so create a fake empty statement.
+ ConditionEndingInFunctionCall = add_element(
+ "ConditionEndingInFunctionCall",
+ pp.Suppress(ConditionOp)
+ + FunctionCall
+ + pp.Empty().setParseAction(lambda x: [[]]).setResultsName("statements"),
+ )
+
+ SingleLineScope = add_element(
+ "SingleLineScope",
+ pp.Suppress(pp.Literal(":")) + pp.Group(Block | (Statement + EOL))("statements"),
+ )
+ MultiLineScope = add_element("MultiLineScope", Block("statements"))
+
+ SingleLineElse = add_element(
+ "SingleLineElse",
+ pp.Suppress(pp.Literal(":")) + (Scope | Block | (Statement + pp.Optional(EOL))),
+ )
+ MultiLineElse = add_element("MultiLineElse", Block)
+ ElseBranch = add_element("ElseBranch", pp.Suppress(Else) + (SingleLineElse | MultiLineElse))
+
+ # Scope is already add_element'ed in the forward declaration above.
+ Scope <<= pp.Group(
+ Condition("condition")
+ + (SingleLineScope | MultiLineScope | ConditionEndingInFunctionCall)
+ + pp.Optional(ElseBranch)("else_statements")
+ )
+
+ Grammar = StatementGroup("statements")
+ Grammar.ignore(pp.pythonStyleComment())
+
+ return Grammar
+
+ def parseFile(self, file: str) -> Tuple[pp.ParseResults, str]:
+ print(f'Parsing "{file}"...')
+ try:
+ with open(file, "r") as file_fd:
+ contents = file_fd.read()
+
+ # old_contents = contents
+ contents = fixup_comments(contents)
+ contents = fixup_linecontinuation(contents)
+ result = self._Grammar.parseString(contents, parseAll=True)
+ except pp.ParseException as pe:
+ print(pe.line)
+ print(f"{' ' * (pe.col-1)}^")
+ print(pe)
+ raise pe
+ return result, contents
+
+
+def parseProFile(file: str, *, debug=False) -> Tuple[pp.ParseResults, str]:
+ parser = QmakeParser(debug=debug)
+ return parser.parseFile(file)
diff --git a/util/cmake/requirements.txt b/util/cmake/requirements.txt
new file mode 100644
index 0000000000..16fb99a08c
--- /dev/null
+++ b/util/cmake/requirements.txt
@@ -0,0 +1,8 @@
+pytest; python_version >= '3.7'
+pytest-cov; python_version >= '3.7'
+mypy; python_version >= '3.7'
+pyparsing; python_version >= '3.7'
+sympy; python_version >= '3.7'
+portalocker; python_version >= '3.7'
+black; python_version >= '3.7'
+
diff --git a/util/cmake/run_pro2cmake.py b/util/cmake/run_pro2cmake.py
new file mode 100755
index 0000000000..4a12c57b83
--- /dev/null
+++ b/util/cmake/run_pro2cmake.py
@@ -0,0 +1,246 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2018 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+import glob
+import os
+import subprocess
+import concurrent.futures
+import sys
+import typing
+import argparse
+from argparse import ArgumentParser
+
+
+def parse_command_line() -> argparse.Namespace:
+ parser = ArgumentParser(
+ description="Run pro2cmake on all .pro files recursively in given path. "
+ "You can pass additional arguments to the pro2cmake calls by appending "
+ "-- --foo --bar"
+ )
+ parser.add_argument(
+ "--only-existing",
+ dest="only_existing",
+ action="store_true",
+ help="Run pro2cmake only on .pro files that already have a CMakeLists.txt.",
+ )
+ parser.add_argument(
+ "--only-missing",
+ dest="only_missing",
+ action="store_true",
+ help="Run pro2cmake only on .pro files that do not have a CMakeLists.txt.",
+ )
+ parser.add_argument(
+ "--only-qtbase-main-modules",
+ dest="only_qtbase_main_modules",
+ action="store_true",
+ help="Run pro2cmake only on the main modules in qtbase.",
+ )
+ parser.add_argument(
+ "--skip-subdirs-projects",
+ dest="skip_subdirs_projects",
+ action="store_true",
+ help="Don't run pro2cmake on TEMPLATE=subdirs projects.",
+ )
+ parser.add_argument(
+ "--is-example",
+ dest="is_example",
+ action="store_true",
+ help="Run pro2cmake with --is-example flag.",
+ )
+ parser.add_argument(
+ "--count", dest="count", help="How many projects should be converted.", type=int
+ )
+ parser.add_argument(
+ "--offset",
+ dest="offset",
+ help="From the list of found projects, from which project should conversion begin.",
+ type=int,
+ )
+ parser.add_argument(
+ "path", metavar="<path>", type=str, help="The path where to look for .pro files."
+ )
+
+ args, unknown = parser.parse_known_args()
+
+ # Error out when the unknown arguments do not start with a "--",
+ # which implies passing through arguments to pro2cmake.
+ if len(unknown) > 0 and unknown[0] != "--":
+ parser.error("unrecognized arguments: {}".format(" ".join(unknown)))
+ else:
+ args.pro2cmake_args = unknown[1:]
+
+ return args
+
+
+def find_all_pro_files(base_path: str, args: argparse.Namespace):
+ def sorter(pro_file: str) -> str:
+ """ Sorter that tries to prioritize main pro files in a directory. """
+ pro_file_without_suffix = pro_file.rsplit("/", 1)[-1][:-4]
+ dir_name = os.path.dirname(pro_file)
+ if dir_name == ".":
+ dir_name = os.path.basename(os.getcwd())
+ if dir_name.endswith(pro_file_without_suffix):
+ return dir_name
+ return dir_name + "/__" + pro_file
+
+ all_files = []
+ previous_dir_name: typing.Optional[str] = None
+
+ print("Finding .pro files.")
+ glob_result = glob.glob(os.path.join(base_path, "**/*.pro"), recursive=True)
+
+ def cmake_lists_exists_filter(path):
+ path_dir_name = os.path.dirname(path)
+ if os.path.exists(os.path.join(path_dir_name, "CMakeLists.txt")):
+ return True
+ return False
+
+ def cmake_lists_missing_filter(path):
+ return not cmake_lists_exists_filter(path)
+
+ def qtbase_main_modules_filter(path):
+ main_modules = [
+ "corelib",
+ "network",
+ "gui",
+ "widgets",
+ "testlib",
+ "printsupport",
+ "opengl",
+ "sql",
+ "dbus",
+ "concurrent",
+ "xml",
+ ]
+ path_suffixes = [f"src/{m}/{m}.pro" for m in main_modules]
+
+ for path_suffix in path_suffixes:
+ if path.endswith(path_suffix):
+ return True
+ return False
+
+ filter_result = glob_result
+ filter_func = None
+ if args.only_existing:
+ filter_func = cmake_lists_exists_filter
+ elif args.only_missing:
+ filter_func = cmake_lists_missing_filter
+ elif args.only_qtbase_main_modules:
+ filter_func = qtbase_main_modules_filter
+
+ if filter_func:
+ print("Filtering.")
+ filter_result = [p for p in filter_result if filter_func(p)]
+
+ for pro_file in sorted(filter_result, key=sorter):
+ dir_name = os.path.dirname(pro_file)
+ if dir_name == previous_dir_name:
+ print("Skipping:", pro_file)
+ else:
+ all_files.append(pro_file)
+ previous_dir_name = dir_name
+ return all_files
+
+
+def run(all_files: typing.List[str], pro2cmake: str, args: argparse.Namespace) -> typing.List[str]:
+ failed_files = []
+ files_count = len(all_files)
+ workers = os.cpu_count() or 1
+
+ if args.only_qtbase_main_modules:
+ # qtbase main modules take longer than usual to process.
+ workers = 2
+
+ with concurrent.futures.ThreadPoolExecutor(max_workers=workers, initargs=(10,)) as pool:
+ print("Firing up thread pool executor.")
+
+ def _process_a_file(data: typing.Tuple[str, int, int]) -> typing.Tuple[int, str, str]:
+ filename, index, total = data
+ pro2cmake_args = []
+ if sys.platform == "win32":
+ pro2cmake_args.append(sys.executable)
+ pro2cmake_args.append(pro2cmake)
+ if args.is_example:
+ pro2cmake_args.append("--is-example")
+ if args.skip_subdirs_projects:
+ pro2cmake_args.append("--skip-subdirs-project")
+ pro2cmake_args.append(os.path.basename(filename))
+
+ if args.pro2cmake_args:
+ pro2cmake_args += args.pro2cmake_args
+
+ result = subprocess.run(
+ pro2cmake_args,
+ cwd=os.path.dirname(filename),
+ stdout=subprocess.PIPE,
+ stderr=subprocess.STDOUT,
+ )
+ stdout = f"Converted[{index}/{total}]: {filename}\n"
+ return result.returncode, filename, stdout + result.stdout.decode()
+
+ for return_code, filename, stdout in pool.map(
+ _process_a_file,
+ zip(all_files, range(1, files_count + 1), (files_count for _ in all_files)),
+ ):
+ if return_code:
+ failed_files.append(filename)
+ print(stdout)
+
+ return failed_files
+
+
+def main() -> None:
+ args = parse_command_line()
+
+ script_path = os.path.dirname(os.path.abspath(__file__))
+ pro2cmake = os.path.join(script_path, "pro2cmake.py")
+ base_path = args.path
+
+ all_files = find_all_pro_files(base_path, args)
+ if args.offset:
+ all_files = all_files[args.offset :]
+ if args.count:
+ all_files = all_files[: args.count]
+ files_count = len(all_files)
+
+ failed_files = run(all_files, pro2cmake, args)
+ if len(all_files) == 0:
+ print("No files found.")
+
+ if failed_files:
+ print(
+ f"The following files were not successfully "
+ f"converted ({len(failed_files)} of {files_count}):"
+ )
+ for f in failed_files:
+ print(f' "{f}"')
+
+
+if __name__ == "__main__":
+ main()
diff --git a/util/cmake/special_case_helper.py b/util/cmake/special_case_helper.py
new file mode 100644
index 0000000000..48c7181a04
--- /dev/null
+++ b/util/cmake/special_case_helper.py
@@ -0,0 +1,415 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2019 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+"""
+This is a helper script that takes care of reapplying special case
+modifications when regenerating a CMakeLists.txt file using
+pro2cmake.py.
+
+It has two modes of operation:
+1) Dumb "special case" block removal and re-application.
+2) Smart "special case" diff application, using a previously generated
+ "clean" CMakeLists.txt as a source. "clean" in this case means a
+ generated file which has no "special case" modifications.
+
+Both modes use a temporary git repository to compute and reapply
+"special case" diffs.
+
+For the first mode to work, the developer has to mark changes
+with "# special case" markers on every line they want to keep. Or
+enclose blocks of code they want to keep between "# special case begin"
+and "# special case end" markers.
+
+For example:
+
+SOURCES
+ foo.cpp
+ bar.cpp # special case
+
+SOURCES
+ foo1.cpp
+ foo2.cpp
+ # special case begin
+ foo3.cpp
+ foo4.cpp
+ # special case end
+
+The second mode, as mentioned, requires a previous "clean"
+CMakeLists.txt file.
+
+The script can then compute the exact diff between
+a "clean" and "modified" (with special cases) file, and reapply that
+diff to a newly generated "CMakeLists.txt" file.
+
+This implies that we always have to keep a "clean" file alongside the
+"modified" project file for each project (corelib, gui, etc.) So we
+have to commit both files to the repository.
+
+If there is no such "clean" file, we can use the first operation mode
+to generate one. After that, we only have to use the second operation
+mode for the project file in question.
+
+When the script is used, the developer only has to take care of fixing
+the newly generated "modified" file. The "clean" file is automatically
+handled and git add'ed by the script, and will be committed together
+with the "modified" file.
+
+
+"""
+
+import re
+import os
+import subprocess
+import filecmp
+import time
+import typing
+import stat
+
+from shutil import copyfile
+from shutil import rmtree
+from textwrap import dedent
+
+
+def remove_special_cases(original: str) -> str:
+ # Remove content between the following markers
+ # '# special case begin' and '# special case end'.
+ # This also remove the markers.
+ replaced = re.sub(
+ r"\n[^#\n]*?#[^\n]*?special case begin.*?#[^\n]*special case end[^\n]*?\n",
+ "\n",
+ original,
+ 0,
+ re.DOTALL,
+ )
+
+ # Remove individual lines that have the "# special case" marker.
+ replaced = re.sub(r"\n.*#.*special case[^\n]*\n", "\n", replaced)
+ return replaced
+
+
+def read_content_from_file(file_path: str) -> str:
+ with open(file_path, "r") as file_fd:
+ content = file_fd.read()
+ return content
+
+
+def write_content_to_file(file_path: str, content: str) -> None:
+ with open(file_path, "w") as file_fd:
+ file_fd.write(content)
+
+
+def resolve_simple_git_conflicts(file_path: str, debug=False) -> None:
+ content = read_content_from_file(file_path)
+ # If the conflict represents the addition of a new content hunk,
+ # keep the content and remove the conflict markers.
+ if debug:
+ print("Resolving simple conflicts automatically.")
+ replaced = re.sub(r"\n<<<<<<< HEAD\n=======(.+?)>>>>>>> master\n", r"\1", content, 0, re.DOTALL)
+ write_content_to_file(file_path, replaced)
+
+
+def copyfile_log(src: str, dst: str, debug=False):
+ if debug:
+ print(f"Copying {src} to {dst}.")
+ copyfile(src, dst)
+
+
+def check_if_git_in_path() -> bool:
+ is_win = os.name == "nt"
+ for path in os.environ["PATH"].split(os.pathsep):
+ git_path = os.path.join(path, "git")
+ if is_win:
+ git_path += ".exe"
+ if os.path.isfile(git_path) and os.access(git_path, os.X_OK):
+ return True
+ return False
+
+
+def run_process_quiet(args_string: str, debug=False) -> bool:
+ if debug:
+ print(f'Running command: "{args_string}"')
+ args_list = args_string.split()
+ try:
+ subprocess.run(args_list, check=True, stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
+ except subprocess.CalledProcessError as e:
+ # git merge with conflicts returns with exit code 1, but that's not
+ # an error for us.
+ if "git merge" not in args_string:
+ if debug:
+ print(
+ dedent(
+ f"""\
+ Error while running: "{args_string}"
+ {e.stdout}"""
+ )
+ )
+ return False
+ return True
+
+
+def does_file_have_conflict_markers(file_path: str, debug=False) -> bool:
+ if debug:
+ print(f"Checking if {file_path} has no leftover conflict markers.")
+ content_actual = read_content_from_file(file_path)
+ if "<<<<<<< HEAD" in content_actual:
+ print(f"Conflict markers found in {file_path}. " "Please remove or solve them first.")
+ return True
+ return False
+
+
+def create_file_with_no_special_cases(
+ original_file_path: str, no_special_cases_file_path: str, debug=False
+):
+ """
+ Reads content of original CMakeLists.txt, removes all content
+ between "# special case" markers or lines, saves the result into a
+ new file.
+ """
+ content_actual = read_content_from_file(original_file_path)
+ if debug:
+ print(f"Removing special case blocks from {original_file_path}.")
+ content_no_special_cases = remove_special_cases(content_actual)
+
+ if debug:
+ print(
+ f"Saving original contents of {original_file_path} "
+ f"with removed special case blocks to {no_special_cases_file_path}"
+ )
+ write_content_to_file(no_special_cases_file_path, content_no_special_cases)
+
+
+def rm_tree_on_error_handler(func: typing.Callable[..., None], path: str, exception_info: tuple):
+ # If the path is read only, try to make it writable, and try
+ # to remove the path again.
+ if not os.access(path, os.W_OK):
+ os.chmod(path, stat.S_IWRITE)
+ func(path)
+ else:
+ print(f"Error while trying to remove path: {path}. Exception: {exception_info}")
+
+
+class SpecialCaseHandler(object):
+ def __init__(
+ self,
+ original_file_path: str,
+ generated_file_path: str,
+ base_dir: str,
+ keep_temporary_files=False,
+ debug=False,
+ ) -> None:
+ self.base_dir = base_dir
+ self.original_file_path = original_file_path
+ self.generated_file_path = generated_file_path
+ self.keep_temporary_files = keep_temporary_files
+ self.use_heuristic = False
+ self.debug = debug
+
+ @property
+ def prev_file_path(self) -> str:
+ return os.path.join(self.base_dir, ".prev_CMakeLists.txt")
+
+ @property
+ def post_merge_file_path(self) -> str:
+ return os.path.join(self.base_dir, "CMakeLists-post-merge.txt")
+
+ @property
+ def no_special_file_path(self) -> str:
+ return os.path.join(self.base_dir, "CMakeLists.no-special.txt")
+
+ def apply_git_merge_magic(self, no_special_cases_file_path: str) -> None:
+ # Create new folder for temporary repo, and ch dir into it.
+ repo = os.path.join(self.base_dir, "tmp_repo")
+ repo_absolute_path = os.path.abspath(repo)
+ txt = "CMakeLists.txt"
+
+ try:
+ os.mkdir(repo)
+ current_dir = os.getcwd()
+ os.chdir(repo)
+ except Exception as e:
+ print(f"Failed to create temporary directory for temporary git repo. Exception: {e}")
+ raise e
+
+ generated_file_path = os.path.join("..", self.generated_file_path)
+ original_file_path = os.path.join("..", self.original_file_path)
+ no_special_cases_file_path = os.path.join("..", no_special_cases_file_path)
+ post_merge_file_path = os.path.join("..", self.post_merge_file_path)
+
+ try:
+ # Create new repo with the "clean" CMakeLists.txt file.
+ run_process_quiet("git init .", debug=self.debug)
+ run_process_quiet("git config user.name fake", debug=self.debug)
+ run_process_quiet("git config user.email fake@fake", debug=self.debug)
+ copyfile_log(no_special_cases_file_path, txt, debug=self.debug)
+ run_process_quiet(f"git add {txt}", debug=self.debug)
+ run_process_quiet("git commit -m no_special", debug=self.debug)
+ run_process_quiet("git checkout -b no_special", debug=self.debug)
+
+ # Copy the original "modified" file (with the special cases)
+ # and make a new commit.
+ run_process_quiet("git checkout -b original", debug=self.debug)
+ copyfile_log(original_file_path, txt, debug=self.debug)
+ run_process_quiet(f"git add {txt}", debug=self.debug)
+ run_process_quiet("git commit -m original", debug=self.debug)
+
+ # Checkout the commit with "clean" file again, and create a
+ # new branch.
+ run_process_quiet("git checkout no_special", debug=self.debug)
+ run_process_quiet("git checkout -b newly_generated", debug=self.debug)
+
+ # Copy the new "modified" file and make a commit.
+ copyfile_log(generated_file_path, txt, debug=self.debug)
+ run_process_quiet(f"git add {txt}", debug=self.debug)
+ run_process_quiet("git commit -m newly_generated", debug=self.debug)
+
+ # Merge the "old" branch with modifications into the "new"
+ # branch with the newly generated file.
+ run_process_quiet("git merge original", debug=self.debug)
+
+ # Resolve some simple conflicts (just remove the markers)
+ # for cases that don't need intervention.
+ resolve_simple_git_conflicts(txt, debug=self.debug)
+
+ # Copy the resulting file from the merge.
+ copyfile_log(txt, post_merge_file_path)
+ except Exception as e:
+ print(f"Git merge conflict resolution process failed. Exception: {e}")
+ raise e
+ finally:
+ os.chdir(current_dir)
+
+ # Remove the temporary repo.
+ try:
+ if not self.keep_temporary_files:
+ rmtree(repo_absolute_path, onerror=rm_tree_on_error_handler)
+ except Exception as e:
+ print(f"Error removing temporary repo. Exception: {e}")
+
+ def save_next_clean_file(self):
+ files_are_equivalent = filecmp.cmp(self.generated_file_path, self.post_merge_file_path)
+
+ if not files_are_equivalent:
+ # Before overriding the generated file with the post
+ # merge result, save the new "clean" file for future
+ # regenerations.
+ copyfile_log(self.generated_file_path, self.prev_file_path, debug=self.debug)
+
+ # Attempt to git add until we succeed. It can fail when
+ # run_pro2cmake executes pro2cmake in multiple threads, and git
+ # has acquired the index lock.
+ success = False
+ failed_once = False
+ i = 0
+ while not success and i < 20:
+ success = run_process_quiet(f"git add {self.prev_file_path}", debug=self.debug)
+ if not success:
+ failed_once = True
+ i += 1
+ time.sleep(0.1)
+
+ if failed_once and not success:
+ if self.debug:
+ print("Retrying git add, the index.lock was probably acquired.")
+ if failed_once and success:
+ if self.debug:
+ print("git add succeeded.")
+ elif failed_once and not success:
+ print(f"git add failed. Make sure to git add {self.prev_file_path} yourself.")
+
+ def handle_special_cases_helper(self) -> bool:
+ """
+ Uses git to reapply special case modifications to the "new"
+ generated CMakeLists.gen.txt file.
+
+ If use_heuristic is True, a new file is created from the
+ original file, with special cases removed.
+
+ If use_heuristic is False, an existing "clean" file with no
+ special cases is used from a previous conversion. The "clean"
+ file is expected to be in the same folder as the original one.
+ """
+ try:
+ if does_file_have_conflict_markers(self.original_file_path):
+ return False
+
+ if self.use_heuristic:
+ create_file_with_no_special_cases(
+ self.original_file_path, self.no_special_file_path
+ )
+ no_special_cases_file_path = self.no_special_file_path
+ else:
+ no_special_cases_file_path = self.prev_file_path
+
+ if self.debug:
+ print(
+ f"Using git to reapply special case modifications to newly "
+ f"generated {self.generated_file_path} file"
+ )
+
+ self.apply_git_merge_magic(no_special_cases_file_path)
+ self.save_next_clean_file()
+
+ copyfile_log(self.post_merge_file_path, self.generated_file_path)
+ if not self.keep_temporary_files:
+ os.remove(self.post_merge_file_path)
+ if self.debug:
+ print(
+ "Special case reapplication using git is complete. "
+ "Make sure to fix remaining conflict markers."
+ )
+
+ except Exception as e:
+ print(f"Error occurred while trying to reapply special case modifications: {e}")
+ return False
+ finally:
+ if not self.keep_temporary_files and self.use_heuristic:
+ os.remove(self.no_special_file_path)
+
+ return True
+
+ def handle_special_cases(self) -> bool:
+ original_file_exists = os.path.isfile(self.original_file_path)
+ prev_file_exists = os.path.isfile(self.prev_file_path)
+ self.use_heuristic = not prev_file_exists
+
+ git_available = check_if_git_in_path()
+ keep_special_cases = original_file_exists and git_available
+
+ if not git_available:
+ print(
+ "You need to have git in PATH in order to reapply the special "
+ "case modifications."
+ )
+
+ copy_generated_file = True
+
+ if keep_special_cases:
+ copy_generated_file = self.handle_special_cases_helper()
+
+ return copy_generated_file
diff --git a/util/cmake/tests/__init__.py b/util/cmake/tests/__init__.py
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/util/cmake/tests/__init__.py
diff --git a/util/cmake/tests/data/comment_scope.pro b/util/cmake/tests/data/comment_scope.pro
new file mode 100644
index 0000000000..be43cad37d
--- /dev/null
+++ b/util/cmake/tests/data/comment_scope.pro
@@ -0,0 +1,6 @@
+# QtCore can't be compiled with -Wl,-no-undefined because it uses the "environ"
+# variable and on FreeBSD and OpenBSD, this variable is in the final executable itself.
+# OpenBSD 6.0 will include environ in libc.
+freebsd|openbsd: QMAKE_LFLAGS_NOUNDEF =
+
+include(animation/animation.pri)
diff --git a/util/cmake/tests/data/complex_assign.pro b/util/cmake/tests/data/complex_assign.pro
new file mode 100644
index 0000000000..d251afcdd5
--- /dev/null
+++ b/util/cmake/tests/data/complex_assign.pro
@@ -0,0 +1,2 @@
+qmake-clean.commands += (cd qmake && $(MAKE) clean ":-(==)-:" '(Foo)' )
+
diff --git a/util/cmake/tests/data/complex_condition.pro b/util/cmake/tests/data/complex_condition.pro
new file mode 100644
index 0000000000..bc3369bd63
--- /dev/null
+++ b/util/cmake/tests/data/complex_condition.pro
@@ -0,0 +1,4 @@
+!system("dbus-send --session --type=signal / local.AutotestCheck.Hello >$$QMAKE_SYSTEM_NULL_DEVICE 2>&1") {
+ SOURCES = dbus.cpp
+}
+
diff --git a/util/cmake/tests/data/complex_values.pro b/util/cmake/tests/data/complex_values.pro
new file mode 100644
index 0000000000..4d747c1dd7
--- /dev/null
+++ b/util/cmake/tests/data/complex_values.pro
@@ -0,0 +1,22 @@
+linux:!static {
+ precompile_header {
+ # we'll get an error if we just use SOURCES +=
+ no_pch_assembler.commands = $$QMAKE_CC -c $(CFLAGS) $(INCPATH) ${QMAKE_FILE_IN} -o ${QMAKE_FILE_OUT}
+ no_pch_assembler.dependency_type = TYPE_C
+ no_pch_assembler.output = ${QMAKE_VAR_OBJECTS_DIR}${QMAKE_FILE_BASE}$${first(QMAKE_EXT_OBJ)}
+ no_pch_assembler.input = NO_PCH_ASM
+ no_pch_assembler.name = compiling[no_pch] ${QMAKE_FILE_IN}
+ silent: no_pch_assembler.commands = @echo compiling[no_pch] ${QMAKE_FILE_IN} && $$no_pch_assembler.commands
+ CMAKE_ANGLE_GLES2_IMPLIB_RELEASE = libGLESv2.$${QMAKE_EXTENSION_STATICLIB}
+ HOST_BINS = $$[QT_HOST_BINS]
+ CMAKE_HOST_DATA_DIR = $$[QT_HOST_DATA/src]/
+ TR_EXCLUDE += ../3rdparty/*
+
+ QMAKE_EXTRA_COMPILERS += no_pch_assembler
+ NO_PCH_ASM += global/minimum-linux.S
+ } else {
+ SOURCES += global/minimum-linux.S
+ }
+ HEADERS += global/minimum-linux_p.h
+}
+
diff --git a/util/cmake/tests/data/condition_without_scope.pro b/util/cmake/tests/data/condition_without_scope.pro
new file mode 100644
index 0000000000..2aa1237c12
--- /dev/null
+++ b/util/cmake/tests/data/condition_without_scope.pro
@@ -0,0 +1,2 @@
+write_file("a", contents)|error()
+
diff --git a/util/cmake/tests/data/contains_scope.pro b/util/cmake/tests/data/contains_scope.pro
new file mode 100644
index 0000000000..0f51350a45
--- /dev/null
+++ b/util/cmake/tests/data/contains_scope.pro
@@ -0,0 +1,4 @@
+contains(DEFINES,QT_EVAL):include(eval.pri)
+
+HOST_BINS = $$[QT_HOST_BINS]
+
diff --git a/util/cmake/tests/data/definetest.pro b/util/cmake/tests/data/definetest.pro
new file mode 100644
index 0000000000..76b63d239f
--- /dev/null
+++ b/util/cmake/tests/data/definetest.pro
@@ -0,0 +1,6 @@
+defineTest(pathIsAbsolute) {
+ p = $$clean_path($$1)
+ !isEmpty(p):isEqual(p, $$absolute_path($$p)): return(true)
+ return(false)
+}
+
diff --git a/util/cmake/tests/data/else.pro b/util/cmake/tests/data/else.pro
new file mode 100644
index 0000000000..bbf9c5ac9f
--- /dev/null
+++ b/util/cmake/tests/data/else.pro
@@ -0,0 +1,6 @@
+
+linux {
+ SOURCES += a.cpp
+} else {
+ SOURCES += b.cpp
+}
diff --git a/util/cmake/tests/data/else2.pro b/util/cmake/tests/data/else2.pro
new file mode 100644
index 0000000000..f2ef36ec28
--- /dev/null
+++ b/util/cmake/tests/data/else2.pro
@@ -0,0 +1,4 @@
+
+osx: A = 1
+else: win32: B = 2
+else: C = 3
diff --git a/util/cmake/tests/data/else3.pro b/util/cmake/tests/data/else3.pro
new file mode 100644
index 0000000000..0de9c2c1d9
--- /dev/null
+++ b/util/cmake/tests/data/else3.pro
@@ -0,0 +1,7 @@
+qtConfig(timezone) {
+ A = 1
+} else:win32 {
+ B = 2
+} else {
+ C = 3
+}
diff --git a/util/cmake/tests/data/else4.pro b/util/cmake/tests/data/else4.pro
new file mode 100644
index 0000000000..9ed676ccfa
--- /dev/null
+++ b/util/cmake/tests/data/else4.pro
@@ -0,0 +1,6 @@
+qtConfig(timezone) {
+ A = 1
+} else:win32: B = 2
+else {
+ C = 3
+}
diff --git a/util/cmake/tests/data/else5.pro b/util/cmake/tests/data/else5.pro
new file mode 100644
index 0000000000..3de76af50a
--- /dev/null
+++ b/util/cmake/tests/data/else5.pro
@@ -0,0 +1,10 @@
+# comments
+qtConfig(timezone) { # bar
+ A = 1
+} else:win32 {
+ B = 2 # foo
+} else { C = 3
+# baz
+ # foobar
+}
+# endcomment
diff --git a/util/cmake/tests/data/else6.pro b/util/cmake/tests/data/else6.pro
new file mode 100644
index 0000000000..9eaa834a19
--- /dev/null
+++ b/util/cmake/tests/data/else6.pro
@@ -0,0 +1,11 @@
+qtConfig(timezone) \
+{
+ A = \
+1
+} \
+else:win32: \
+B = 2
+else: \
+ C \
+= 3
+
diff --git a/util/cmake/tests/data/else7.pro b/util/cmake/tests/data/else7.pro
new file mode 100644
index 0000000000..e663b1c05e
--- /dev/null
+++ b/util/cmake/tests/data/else7.pro
@@ -0,0 +1,2 @@
+msvc:equals(QT_ARCH, i386): QMAKE_LFLAGS += /BASE:0x65000000
+
diff --git a/util/cmake/tests/data/else8.pro b/util/cmake/tests/data/else8.pro
new file mode 100644
index 0000000000..6d4d5f01ed
--- /dev/null
+++ b/util/cmake/tests/data/else8.pro
@@ -0,0 +1,5 @@
+qtConfig(timezone) { A = 1 } else:win32: {\
+B = 2 \
+} else: \
+ C \
+= 3 \
diff --git a/util/cmake/tests/data/escaped_value.pro b/util/cmake/tests/data/escaped_value.pro
new file mode 100644
index 0000000000..7c95b1fc30
--- /dev/null
+++ b/util/cmake/tests/data/escaped_value.pro
@@ -0,0 +1,2 @@
+MODULE_AUX_INCLUDES = \
+ \$\$QT_MODULE_INCLUDE_BASE/QtANGLE
diff --git a/util/cmake/tests/data/for.pro b/util/cmake/tests/data/for.pro
new file mode 100644
index 0000000000..5751432980
--- /dev/null
+++ b/util/cmake/tests/data/for.pro
@@ -0,0 +1,11 @@
+SOURCES = main.cpp
+for (config, SIMD) {
+ uc = $$upper($$config)
+ DEFINES += QT_COMPILER_SUPPORTS_$${uc}
+
+ add_cflags {
+ cflags = QMAKE_CFLAGS_$${uc}
+ !defined($$cflags, var): error("This compiler does not support $${uc}")
+ QMAKE_CXXFLAGS += $$eval($$cflags)
+ }
+}
diff --git a/util/cmake/tests/data/function_if.pro b/util/cmake/tests/data/function_if.pro
new file mode 100644
index 0000000000..9af018f864
--- /dev/null
+++ b/util/cmake/tests/data/function_if.pro
@@ -0,0 +1,4 @@
+pathIsAbsolute($$CMAKE_HOST_DATA_DIR) {
+ CMAKE_HOST_DATA_DIR = $$[QT_HOST_DATA/src]/
+}
+
diff --git a/util/cmake/tests/data/include.pro b/util/cmake/tests/data/include.pro
new file mode 100644
index 0000000000..22d8a40919
--- /dev/null
+++ b/util/cmake/tests/data/include.pro
@@ -0,0 +1,3 @@
+A = 42
+include(foo) # load foo
+B=23
diff --git a/util/cmake/tests/data/lc.pro b/util/cmake/tests/data/lc.pro
new file mode 100644
index 0000000000..def80e7c95
--- /dev/null
+++ b/util/cmake/tests/data/lc.pro
@@ -0,0 +1,10 @@
+TEMPLATE=subdirs
+SUBDIRS=\
+ qmacstyle \
+ qstyle \
+ qstyleoption \
+ qstylesheetstyle \
+
+!qtConfig(private_tests): SUBDIRS -= \
+ qstylesheetstyle \
+
diff --git a/util/cmake/tests/data/lc_with_comment.pro b/util/cmake/tests/data/lc_with_comment.pro
new file mode 100644
index 0000000000..176913dfc8
--- /dev/null
+++ b/util/cmake/tests/data/lc_with_comment.pro
@@ -0,0 +1,22 @@
+SUBDIRS = \
+# dds \
+ tga \
+ wbmp
+
+MYVAR = foo # comment
+MYVAR = foo2# comment
+MYVAR = foo3# comment #
+
+MYVAR = foo4# comment #
+
+##
+#
+#
+##
+
+ #
+ #
+#
+ # #
+
+MYVAR = foo5# comment # #
diff --git a/util/cmake/tests/data/load.pro b/util/cmake/tests/data/load.pro
new file mode 100644
index 0000000000..c9717e9832
--- /dev/null
+++ b/util/cmake/tests/data/load.pro
@@ -0,0 +1,3 @@
+A = 42
+load(foo)# load foo
+B=23
diff --git a/util/cmake/tests/data/multi_condition_divided_by_lc.pro b/util/cmake/tests/data/multi_condition_divided_by_lc.pro
new file mode 100644
index 0000000000..23254231df
--- /dev/null
+++ b/util/cmake/tests/data/multi_condition_divided_by_lc.pro
@@ -0,0 +1,3 @@
+equals(a): \
+ greaterThan(a):flags += 1
+
diff --git a/util/cmake/tests/data/multiline_assign.pro b/util/cmake/tests/data/multiline_assign.pro
new file mode 100644
index 0000000000..42a3d0a674
--- /dev/null
+++ b/util/cmake/tests/data/multiline_assign.pro
@@ -0,0 +1,4 @@
+A = 42 \
+ 43 \
+ 44
+B=23
diff --git a/util/cmake/tests/data/nested_function_calls.pro b/util/cmake/tests/data/nested_function_calls.pro
new file mode 100644
index 0000000000..5ecc53f1cc
--- /dev/null
+++ b/util/cmake/tests/data/nested_function_calls.pro
@@ -0,0 +1,2 @@
+requires(qtConfig(dlopen))
+
diff --git a/util/cmake/tests/data/quoted.pro b/util/cmake/tests/data/quoted.pro
new file mode 100644
index 0000000000..61682aa0d0
--- /dev/null
+++ b/util/cmake/tests/data/quoted.pro
@@ -0,0 +1,5 @@
+if(linux*|hurd*):!cross_compile:!static:!*-armcc* {
+ prog=$$quote(if (/program interpreter: (.*)]/) { print $1; })
+ DEFINES += ELF_INTERPRETER=\\\"$$system(LC_ALL=C readelf -l /bin/ls | perl -n -e \'$$prog\')\\\"
+}
+
diff --git a/util/cmake/tests/data/single_line_for.pro b/util/cmake/tests/data/single_line_for.pro
new file mode 100644
index 0000000000..806d08a49c
--- /dev/null
+++ b/util/cmake/tests/data/single_line_for.pro
@@ -0,0 +1,4 @@
+for(d, sd): \
+ exists($$d/$${d}.pro): \
+ SUBDIRS += $$d
+
diff --git a/util/cmake/tests/data/sql.pro b/util/cmake/tests/data/sql.pro
new file mode 100644
index 0000000000..a9d7fc7c5a
--- /dev/null
+++ b/util/cmake/tests/data/sql.pro
@@ -0,0 +1,3 @@
+TEMPLATE = subdirs
+SUBDIRS = \
+ kernel \
diff --git a/util/cmake/tests/data/standardpaths.pro b/util/cmake/tests/data/standardpaths.pro
new file mode 100644
index 0000000000..4b45788e4f
--- /dev/null
+++ b/util/cmake/tests/data/standardpaths.pro
@@ -0,0 +1,17 @@
+win32 {
+ !winrt {
+ SOURCES +=io/qstandardpaths_win.cpp
+ } else {
+ SOURCES +=io/qstandardpaths_winrt.cpp
+ }
+} else:unix {
+ mac {
+ OBJECTIVE_SOURCES += io/qstandardpaths_mac.mm
+ } else:android:!android-embedded {
+ SOURCES += io/qstandardpaths_android.cpp
+ } else:haiku {
+ SOURCES += io/qstandardpaths_haiku.cpp
+ } else {
+ SOURCES += io/qstandardpaths_unix.cpp
+ }
+}
diff --git a/util/cmake/tests/data/unset.pro b/util/cmake/tests/data/unset.pro
new file mode 100644
index 0000000000..7ffb0582f1
--- /dev/null
+++ b/util/cmake/tests/data/unset.pro
@@ -0,0 +1,2 @@
+unset(f16c_cxx)
+
diff --git a/util/cmake/tests/data/value_function.pro b/util/cmake/tests/data/value_function.pro
new file mode 100644
index 0000000000..598e4fadbd
--- /dev/null
+++ b/util/cmake/tests/data/value_function.pro
@@ -0,0 +1,2 @@
+TARGET = Dummy
+TARGET = $$qtLibraryTarget($$TARGET)
diff --git a/util/cmake/tests/test_lc_fixup.py b/util/cmake/tests/test_lc_fixup.py
new file mode 100755
index 0000000000..42094a5288
--- /dev/null
+++ b/util/cmake/tests/test_lc_fixup.py
@@ -0,0 +1,44 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2018 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+from qmake_parser import fixup_linecontinuation
+
+
+def test_no_change():
+ input = "test \\\nline2\n line3"
+ output = "test line2\n line3"
+ result = fixup_linecontinuation(input)
+ assert output == result
+
+
+def test_fix():
+ input = "test \\\t\nline2\\\n line3\\ \nline4 \\ \t\nline5\\\n\n\n"
+ output = "test line2 line3 line4 line5 \n\n"
+ result = fixup_linecontinuation(input)
+ assert output == result
diff --git a/util/cmake/tests/test_logic_mapping.py b/util/cmake/tests/test_logic_mapping.py
new file mode 100755
index 0000000000..c18c3ddc65
--- /dev/null
+++ b/util/cmake/tests/test_logic_mapping.py
@@ -0,0 +1,186 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2018 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+from condition_simplifier import simplify_condition
+
+
+def validate_simplify(input: str, expected: str) -> None:
+ output = simplify_condition(input)
+ assert output == expected
+
+
+def validate_simplify_unchanged(input: str) -> None:
+ validate_simplify(input, input)
+
+
+def test_simplify_on():
+ validate_simplify_unchanged('ON')
+
+
+def test_simplify_off():
+ validate_simplify_unchanged('OFF')
+
+
+def test_simplify_not_on():
+ validate_simplify('NOT ON', 'OFF')
+
+
+def test_simplify_not_off():
+ validate_simplify('NOT OFF', 'ON')
+
+
+def test_simplify_isEmpty():
+ validate_simplify_unchanged('isEmpty(foo)')
+
+
+def test_simplify_not_isEmpty():
+ validate_simplify_unchanged('NOT isEmpty(foo)')
+
+
+def test_simplify_simple_and():
+ validate_simplify_unchanged('QT_FEATURE_bar AND QT_FEATURE_foo')
+
+
+def test_simplify_simple_or():
+ validate_simplify_unchanged('QT_FEATURE_bar OR QT_FEATURE_foo')
+
+
+def test_simplify_simple_not():
+ validate_simplify_unchanged('NOT QT_FEATURE_foo')
+
+
+def test_simplify_simple_and_reorder():
+ validate_simplify('QT_FEATURE_foo AND QT_FEATURE_bar', 'QT_FEATURE_bar AND QT_FEATURE_foo')
+
+
+def test_simplify_simple_or_reorder():
+ validate_simplify('QT_FEATURE_foo OR QT_FEATURE_bar', 'QT_FEATURE_bar OR QT_FEATURE_foo')
+
+
+def test_simplify_unix_or_win32():
+ validate_simplify('WIN32 OR UNIX', 'ON')
+
+
+def test_simplify_unix_or_win32_or_foobar_or_barfoo():
+ validate_simplify('WIN32 OR UNIX OR foobar OR barfoo', 'ON')
+
+
+def test_simplify_not_not_bar():
+ validate_simplify(' NOT NOT bar ', 'bar')
+
+
+def test_simplify_not_unix():
+ validate_simplify('NOT UNIX', 'WIN32')
+
+
+def test_simplify_not_win32():
+ validate_simplify('NOT WIN32', 'UNIX')
+
+
+def test_simplify_unix_and_win32():
+ validate_simplify('WIN32 AND UNIX', 'OFF')
+
+
+def test_simplify_unix_or_win32():
+ validate_simplify('WIN32 OR UNIX', 'ON')
+
+
+def test_simplify_unix_and_win32_or_foobar_or_barfoo():
+ validate_simplify('WIN32 AND foobar AND UNIX AND barfoo', 'OFF')
+
+
+def test_simplify_watchos_and_win32():
+ validate_simplify('APPLE_WATCHOS AND WIN32', 'OFF')
+
+
+def test_simplify_win32_and_watchos():
+ validate_simplify('WIN32 AND APPLE_WATCHOS', 'OFF')
+
+
+def test_simplify_apple_and_appleosx():
+ validate_simplify('APPLE AND APPLE_OSX', 'APPLE_OSX')
+
+
+def test_simplify_apple_or_appleosx():
+ validate_simplify('APPLE OR APPLE_OSX', 'APPLE')
+
+
+def test_simplify_apple_or_appleosx_level1():
+ validate_simplify('foobar AND (APPLE OR APPLE_OSX )', 'APPLE AND foobar')
+
+
+def test_simplify_apple_or_appleosx_level1_double():
+ validate_simplify('foobar AND (APPLE OR APPLE_OSX )', 'APPLE AND foobar')
+
+
+def test_simplify_apple_or_appleosx_level1_double_with_extra_spaces():
+ validate_simplify('foobar AND (APPLE OR APPLE_OSX ) '
+ 'AND ( APPLE_OSX OR APPLE )', 'APPLE AND foobar')
+
+
+def test_simplify_apple_or_appleosx_level2():
+ validate_simplify('foobar AND ( ( APPLE OR APPLE_WATCHOS ) '
+ 'OR APPLE_OSX ) AND ( APPLE_OSX OR APPLE ) '
+ 'AND ( (WIN32 OR WINRT) OR UNIX) ', 'APPLE AND foobar')
+
+
+def test_simplify_not_apple_and_appleosx():
+ validate_simplify('NOT APPLE AND APPLE_OSX', 'OFF')
+
+
+def test_simplify_unix_and_bar_or_win32():
+ validate_simplify('WIN32 AND bar AND UNIX', 'OFF')
+
+
+def test_simplify_unix_or_bar_or_win32():
+ validate_simplify('WIN32 OR bar OR UNIX', 'ON')
+
+
+def test_simplify_complex_true():
+ validate_simplify('WIN32 OR ( APPLE OR UNIX)', 'ON')
+
+
+def test_simplify_apple_unix_freebsd():
+ validate_simplify('( APPLE OR ( UNIX OR FREEBSD ))', 'UNIX')
+
+
+def test_simplify_apple_unix_freebsd_foobar():
+ validate_simplify('( APPLE OR ( UNIX OR FREEBSD ) OR foobar)',
+ 'UNIX OR foobar')
+
+
+def test_simplify_complex_false():
+ validate_simplify('WIN32 AND foobar AND ( '
+ 'APPLE OR ( UNIX OR FREEBSD ))',
+ 'OFF')
+
+
+def test_simplify_android_not_apple():
+ validate_simplify('ANDROID AND NOT ANDROID_EMBEDDED AND NOT APPLE_OSX',
+ 'ANDROID AND NOT ANDROID_EMBEDDED')
diff --git a/util/cmake/tests/test_operations.py b/util/cmake/tests/test_operations.py
new file mode 100755
index 0000000000..c1e5f1b250
--- /dev/null
+++ b/util/cmake/tests/test_operations.py
@@ -0,0 +1,57 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2018 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+from pro2cmake import AddOperation, SetOperation, UniqueAddOperation, RemoveOperation
+
+def test_add_operation():
+ op = AddOperation(['bar', 'buz'])
+
+ result = op.process(['foo', 'bar'], ['foo', 'bar'], lambda x: x)
+ assert ['foo', 'bar', 'bar', 'buz'] == result
+
+
+def test_uniqueadd_operation():
+ op = UniqueAddOperation(['bar', 'buz'])
+
+ result = op.process(['foo', 'bar'], ['foo', 'bar'], lambda x: x)
+ assert ['foo', 'bar', 'buz'] == result
+
+
+def test_set_operation():
+ op = SetOperation(['bar', 'buz'])
+
+ result = op.process(['foo', 'bar'], ['foo', 'bar'], lambda x: x)
+ assert ['bar', 'buz'] == result
+
+
+def test_remove_operation():
+ op = RemoveOperation(['bar', 'buz'])
+
+ result = op.process(['foo', 'bar'], ['foo', 'bar'], lambda x: x)
+ assert ['foo', '-buz'] == result
diff --git a/util/cmake/tests/test_parsing.py b/util/cmake/tests/test_parsing.py
new file mode 100755
index 0000000000..9acee46007
--- /dev/null
+++ b/util/cmake/tests/test_parsing.py
@@ -0,0 +1,354 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2018 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+import os
+from qmake_parser import QmakeParser
+
+
+_tests_path = os.path.dirname(os.path.abspath(__file__))
+
+
+def validate_op(key, op, value, to_validate):
+ assert key == to_validate['key']
+ assert op == to_validate['operation']['value']
+ assert value == to_validate.get('value', None)
+
+
+def validate_single_op(key, op, value, to_validate):
+ assert len(to_validate) == 1
+ validate_op(key, op, value, to_validate[0])
+
+
+def evaluate_condition(to_validate):
+ assert 'condition' in to_validate
+ assert 'statements' in to_validate
+
+ return (to_validate['condition'],
+ to_validate['statements'],
+ to_validate.get('else_statements', {}))
+
+
+def validate_default_else_test(file_name):
+ result = parse_file(file_name)
+ assert len(result) == 1
+
+ (cond, if_branch, else_branch) = evaluate_condition(result[0])
+ assert cond == 'qtConfig(timezone)'
+ validate_single_op('A', '=', ['1'], if_branch)
+
+ assert len(else_branch) == 1
+ (cond2, if2_branch, else2_branch) = evaluate_condition(else_branch[0])
+ assert cond2 == 'win32'
+ validate_single_op('B', '=', ['2'], if2_branch)
+ validate_single_op('C', '=', ['3'], else2_branch)
+
+
+def parse_file(file):
+ p = QmakeParser(debug=True)
+ result, _ = p.parseFile(file)
+
+ print('\n\n#### Parser result:')
+ print(result)
+ print('\n#### End of parser result.\n')
+
+ print('\n\n####Parser result dictionary:')
+ print(result.asDict())
+ print('\n#### End of parser result dictionary.\n')
+
+ result_dictionary = result.asDict()
+
+ assert len(result_dictionary) == 1
+
+ return result_dictionary['statements']
+
+
+def test_else():
+ result = parse_file(_tests_path + '/data/else.pro')
+ assert len(result) == 1
+
+ (cond, if_branch, else_branch) = evaluate_condition(result[0])
+
+ assert cond == 'linux'
+ validate_single_op('SOURCES', '+=', ['a.cpp'], if_branch)
+ validate_single_op('SOURCES', '+=', ['b.cpp'], else_branch)
+
+
+def test_else2():
+ result = parse_file(_tests_path + '/data/else2.pro')
+ assert len(result) == 1
+
+ (cond, if_branch, else_branch) = evaluate_condition(result[0])
+ assert cond == 'osx'
+ validate_single_op('A', '=', ['1'], if_branch)
+
+ assert len(else_branch) == 1
+ (cond2, if2_branch, else2_branch) = evaluate_condition(else_branch[0])
+ assert cond2 == 'win32'
+ validate_single_op('B', '=', ['2'], if2_branch)
+
+ validate_single_op('C', '=', ['3'], else2_branch)
+
+
+def test_else3():
+ validate_default_else_test(_tests_path + '/data/else3.pro')
+
+
+def test_else4():
+ validate_default_else_test(_tests_path + '/data/else4.pro')
+
+
+def test_else5():
+ validate_default_else_test(_tests_path + '/data/else5.pro')
+
+
+def test_else6():
+ validate_default_else_test(_tests_path + '/data/else6.pro')
+
+
+def test_else7():
+ result = parse_file(_tests_path + '/data/else7.pro')
+ assert len(result) == 1
+
+
+def test_else8():
+ validate_default_else_test(_tests_path + '/data/else8.pro')
+
+
+def test_multiline_assign():
+ result = parse_file(_tests_path + '/data/multiline_assign.pro')
+ assert len(result) == 2
+ validate_op('A', '=', ['42', '43', '44'], result[0])
+ validate_op('B', '=', ['23'], result[1])
+
+
+def test_include():
+ result = parse_file(_tests_path + '/data/include.pro')
+ assert len(result) == 3
+ validate_op('A', '=', ['42'], result[0])
+ include = result[1]
+ assert len(include) == 1
+ assert 'included' in include
+ assert include['included'].get('value', '') == 'foo'
+ validate_op('B', '=', ['23'], result[2])
+
+
+def test_load():
+ result = parse_file(_tests_path + '/data/load.pro')
+ assert len(result) == 3
+ validate_op('A', '=', ['42'], result[0])
+ load = result[1]
+ assert len(load) == 1
+ assert load.get('loaded', '') == 'foo'
+ validate_op('B', '=', ['23'], result[2])
+
+
+def test_definetest():
+ result = parse_file(_tests_path + '/data/definetest.pro')
+ assert len(result) == 1
+ assert result[0] == []
+
+
+def test_for():
+ result = parse_file(_tests_path + '/data/for.pro')
+ assert len(result) == 2
+ validate_op('SOURCES', '=', ['main.cpp'], result[0])
+ assert result[1] == []
+
+
+def test_single_line_for():
+ result = parse_file(_tests_path + '/data/single_line_for.pro')
+ assert len(result) == 1
+ assert result[0] == []
+
+
+def test_unset():
+ result = parse_file(_tests_path + '/data/unset.pro')
+ assert len(result) == 1
+ assert result[0] == []
+
+
+def test_quoted():
+ result = parse_file(_tests_path + '/data/quoted.pro')
+ assert len(result) == 1
+
+
+def test_complex_values():
+ result = parse_file(_tests_path + '/data/complex_values.pro')
+ assert len(result) == 1
+
+
+def test_function_if():
+ result = parse_file(_tests_path + '/data/function_if.pro')
+ assert len(result) == 1
+
+
+def test_realworld_standardpaths():
+ result = parse_file(_tests_path + '/data/standardpaths.pro')
+
+ (cond, if_branch, else_branch) = evaluate_condition(result[0])
+ assert cond == 'win32'
+ assert len(if_branch) == 1
+ assert len(else_branch) == 1
+
+ # win32:
+ (cond1, if_branch1, else_branch1) = evaluate_condition(if_branch[0])
+ assert cond1 == '!winrt'
+ assert len(if_branch1) == 1
+ validate_op('SOURCES', '+=', ['io/qstandardpaths_win.cpp'], if_branch1[0])
+ assert len(else_branch1) == 1
+ validate_op('SOURCES', '+=', ['io/qstandardpaths_winrt.cpp'], else_branch1[0])
+
+ # unix:
+ (cond2, if_branch2, else_branch2) = evaluate_condition(else_branch[0])
+ assert cond2 == 'unix'
+ assert len(if_branch2) == 1
+ assert len(else_branch2) == 0
+
+ # mac / else:
+ (cond3, if_branch3, else_branch3) = evaluate_condition(if_branch2[0])
+ assert cond3 == 'mac'
+ assert len(if_branch3) == 1
+ validate_op('OBJECTIVE_SOURCES', '+=', ['io/qstandardpaths_mac.mm'], if_branch3[0])
+ assert len(else_branch3) == 1
+
+ # android / else:
+ (cond4, if_branch4, else_branch4) = evaluate_condition(else_branch3[0])
+ assert cond4 == 'android && !android-embedded'
+ assert len(if_branch4) == 1
+ validate_op('SOURCES', '+=', ['io/qstandardpaths_android.cpp'], if_branch4[0])
+ assert len(else_branch4) == 1
+
+ # haiku / else:
+ (cond5, if_branch5, else_branch5) = evaluate_condition(else_branch4[0])
+ assert cond5 == 'haiku'
+ assert len(if_branch5) == 1
+ validate_op('SOURCES', '+=', ['io/qstandardpaths_haiku.cpp'], if_branch5[0])
+ assert len(else_branch5) == 1
+ validate_op('SOURCES', '+=', ['io/qstandardpaths_unix.cpp'], else_branch5[0])
+
+
+def test_realworld_comment_scope():
+ result = parse_file(_tests_path + '/data/comment_scope.pro')
+ assert len(result) == 2
+ (cond, if_branch, else_branch) = evaluate_condition(result[0])
+ assert cond == 'freebsd|openbsd'
+ assert len(if_branch) == 1
+ validate_op('QMAKE_LFLAGS_NOUNDEF', '=', None, if_branch[0])
+
+ assert 'included' in result[1]
+ assert result[1]['included'].get('value', '') == 'animation/animation.pri'
+
+
+def test_realworld_contains_scope():
+ result = parse_file(_tests_path + '/data/contains_scope.pro')
+ assert len(result) == 2
+
+
+def test_realworld_complex_assign():
+ result = parse_file(_tests_path + '/data/complex_assign.pro')
+ assert len(result) == 1
+ validate_op('qmake-clean.commands', '+=', '( cd qmake && $(MAKE) clean ":-(==)-:" \'(Foo)\' )'.split(),
+ result[0])
+
+
+def test_realworld_complex_condition():
+ result = parse_file(_tests_path + '/data/complex_condition.pro')
+ assert len(result) == 1
+ (cond, if_branch, else_branch) = evaluate_condition(result[0])
+ assert cond == '!system("dbus-send --session --type=signal / ' \
+ 'local.AutotestCheck.Hello >$$QMAKE_SYSTEM_NULL_DEVICE ' \
+ '2>&1")'
+ assert len(if_branch) == 1
+ validate_op('SOURCES', '=', ['dbus.cpp'], if_branch[0])
+
+ assert len(else_branch) == 0
+
+
+def test_realworld_sql():
+ result = parse_file(_tests_path + '/data/sql.pro')
+ assert len(result) == 2
+ validate_op('TEMPLATE', '=', ['subdirs'], result[0])
+ validate_op('SUBDIRS', '=', ['kernel'], result[1])
+
+
+def test_realworld_qtconfig():
+ result = parse_file(_tests_path + '/data/escaped_value.pro')
+ assert len(result) == 1
+ validate_op('MODULE_AUX_INCLUDES', '=', ['\\$\\$QT_MODULE_INCLUDE_BASE/QtANGLE'], result[0])
+
+
+def test_realworld_lc():
+ result = parse_file(_tests_path + '/data/lc.pro')
+ assert len(result) == 3
+
+
+def test_realworld_lc_with_comment_in_between():
+ result = parse_file(_tests_path + '/data/lc_with_comment.pro')
+
+ my_var = result[1]['value'][0]
+ assert my_var == 'foo'
+
+ my_var = result[2]['value'][0]
+ assert my_var == 'foo2'
+
+ my_var = result[3]['value'][0]
+ assert my_var == 'foo3'
+
+ my_var = result[4]['value'][0]
+ assert my_var == 'foo4'
+
+ my_var = result[5]['value'][0]
+ assert my_var == 'foo5'
+
+ sub_dirs = result[0]['value']
+ assert sub_dirs[0] == 'tga'
+ assert sub_dirs[1] == 'wbmp'
+ assert len(result) == 6
+
+
+def test_condition_without_scope():
+ result = parse_file(_tests_path + '/data/condition_without_scope.pro')
+ assert len(result) == 1
+
+
+def test_multi_condition_divided_by_lc():
+ result = parse_file(_tests_path + '/data/multi_condition_divided_by_lc.pro')
+ assert len(result) == 1
+
+
+def test_nested_function_calls():
+ result = parse_file(_tests_path + '/data/nested_function_calls.pro')
+ assert len(result) == 1
+
+def test_value_function():
+ result = parse_file(_tests_path + '/data/value_function.pro')
+ target = result[0]['value'][0]
+ assert target == 'Dummy'
+ value = result[1]['value']
+ assert value[0] == '$$TARGET'
diff --git a/util/cmake/tests/test_scope_handling.py b/util/cmake/tests/test_scope_handling.py
new file mode 100755
index 0000000000..1db8b2a079
--- /dev/null
+++ b/util/cmake/tests/test_scope_handling.py
@@ -0,0 +1,346 @@
+#!/usr/bin/env python3
+#############################################################################
+##
+## Copyright (C) 2018 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of the plugins of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:GPL-EXCEPT$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3 as published by the Free Software
+## Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+from pro2cmake import Scope, SetOperation, merge_scopes, recursive_evaluate_scope
+
+import pytest
+import typing
+
+ScopeList = typing.List[Scope]
+
+def _map_to_operation(**kwargs):
+ result = {} # type: typing.Mapping[str, typing.List[SetOperation]]
+ for (key, value) in kwargs.items():
+ result[key] = [SetOperation([value])]
+ return result
+
+
+def _new_scope(*, parent_scope=None, condition='', **kwargs) -> Scope:
+ return Scope(parent_scope=parent_scope,
+ qmake_file='file1', condition=condition, operations=_map_to_operation(**kwargs))
+
+
+def _evaluate_scopes(scopes: ScopeList) -> ScopeList:
+ for s in scopes:
+ if not s.parent:
+ recursive_evaluate_scope(s)
+ return scopes
+
+
+def _validate(input_scopes: ScopeList, output_scopes: ScopeList):
+ merged_scopes = merge_scopes(input_scopes)
+ assert merged_scopes == output_scopes
+
+
+def test_evaluate_one_scope():
+ scope = _new_scope(condition='QT_FEATURE_foo', test1='bar')
+
+ input_scope = scope
+ recursive_evaluate_scope(scope)
+ assert scope == input_scope
+
+
+def test_evaluate_child_scope():
+ scope = _new_scope(condition='QT_FEATURE_foo', test1='bar')
+ _new_scope(parent_scope=scope, condition='QT_FEATURE_bar', test2='bar')
+
+ input_scope = scope
+ recursive_evaluate_scope(scope)
+
+ assert scope.total_condition == 'QT_FEATURE_foo'
+ assert len(scope.children) == 1
+ assert scope.get_string('test1') == 'bar'
+ assert scope.get_string('test2', 'not found') == 'not found'
+
+ child = scope.children[0]
+ assert child.total_condition == 'QT_FEATURE_bar AND QT_FEATURE_foo'
+ assert child.get_string('test1', 'not found') == 'not found'
+ assert child.get_string('test2') == 'bar'
+
+
+def test_evaluate_two_child_scopes():
+ scope = _new_scope(condition='QT_FEATURE_foo', test1='bar')
+ _new_scope(parent_scope=scope, condition='QT_FEATURE_bar', test2='bar')
+ _new_scope(parent_scope=scope, condition='QT_FEATURE_buz', test3='buz')
+
+ input_scope = scope
+ recursive_evaluate_scope(scope)
+
+ assert scope.total_condition == 'QT_FEATURE_foo'
+ assert len(scope.children) == 2
+ assert scope.get_string('test1') == 'bar'
+ assert scope.get_string('test2', 'not found') == 'not found'
+ assert scope.get_string('test3', 'not found') == 'not found'
+
+ child1 = scope.children[0]
+ assert child1.total_condition == 'QT_FEATURE_bar AND QT_FEATURE_foo'
+ assert child1.get_string('test1', 'not found') == 'not found'
+ assert child1.get_string('test2') == 'bar'
+ assert child1.get_string('test3', 'not found') == 'not found'
+
+ child2 = scope.children[1]
+ assert child2.total_condition == 'QT_FEATURE_buz AND QT_FEATURE_foo'
+ assert child2.get_string('test1', 'not found') == 'not found'
+ assert child2.get_string('test2') == ''
+ assert child2.get_string('test3', 'not found') == 'buz'
+
+
+def test_evaluate_else_child_scopes():
+ scope = _new_scope(condition='QT_FEATURE_foo', test1='bar')
+ _new_scope(parent_scope=scope, condition='QT_FEATURE_bar', test2='bar')
+ _new_scope(parent_scope=scope, condition='else', test3='buz')
+
+ input_scope = scope
+ recursive_evaluate_scope(scope)
+
+ assert scope.total_condition == 'QT_FEATURE_foo'
+ assert len(scope.children) == 2
+ assert scope.get_string('test1') == 'bar'
+ assert scope.get_string('test2', 'not found') == 'not found'
+ assert scope.get_string('test3', 'not found') == 'not found'
+
+ child1 = scope.children[0]
+ assert child1.total_condition == 'QT_FEATURE_bar AND QT_FEATURE_foo'
+ assert child1.get_string('test1', 'not found') == 'not found'
+ assert child1.get_string('test2') == 'bar'
+ assert child1.get_string('test3', 'not found') == 'not found'
+
+ child2 = scope.children[1]
+ assert child2.total_condition == 'QT_FEATURE_foo AND NOT QT_FEATURE_bar'
+ assert child2.get_string('test1', 'not found') == 'not found'
+ assert child2.get_string('test2') == ''
+ assert child2.get_string('test3', 'not found') == 'buz'
+
+
+def test_evaluate_invalid_else_child_scopes():
+ scope = _new_scope(condition='QT_FEATURE_foo', test1='bar')
+ _new_scope(parent_scope=scope, condition='else', test3='buz')
+ _new_scope(parent_scope=scope, condition='QT_FEATURE_bar', test2='bar')
+
+ input_scope = scope
+ with pytest.raises(AssertionError):
+ recursive_evaluate_scope(scope)
+
+
+def test_merge_empty_scope_list():
+ _validate([], [])
+
+
+def test_merge_one_scope():
+ scopes = [_new_scope(test='foo')]
+
+ recursive_evaluate_scope(scopes[0])
+
+ _validate(scopes, scopes)
+
+
+def test_merge_one_on_scope():
+ scopes = [_new_scope(condition='ON', test='foo')]
+
+ recursive_evaluate_scope(scopes[0])
+
+ _validate(scopes, scopes)
+
+
+def test_merge_one_off_scope():
+ scopes = [_new_scope(condition='OFF', test='foo')]
+
+ recursive_evaluate_scope(scopes[0])
+
+ _validate(scopes, [])
+
+
+def test_merge_one_conditioned_scope():
+ scopes = [_new_scope(condition='QT_FEATURE_foo', test='foo')]
+
+ recursive_evaluate_scope(scopes[0])
+
+ _validate(scopes, scopes)
+
+
+def test_merge_two_scopes_with_same_condition():
+ scopes = [_new_scope(condition='QT_FEATURE_bar', test='foo'),
+ _new_scope(condition='QT_FEATURE_bar', test2='bar')]
+
+ recursive_evaluate_scope(scopes[0])
+ recursive_evaluate_scope(scopes[1])
+
+ result = merge_scopes(scopes)
+
+ assert len(result) == 1
+ r0 = result[0]
+ assert r0.total_condition == 'QT_FEATURE_bar'
+ assert r0.get_string('test') == 'foo'
+ assert r0.get_string('test2') == 'bar'
+
+
+def test_merge_three_scopes_two_with_same_condition():
+ scopes = [_new_scope(condition='QT_FEATURE_bar', test='foo'),
+ _new_scope(condition='QT_FEATURE_baz', test1='buz'),
+ _new_scope(condition='QT_FEATURE_bar', test2='bar')]
+
+ recursive_evaluate_scope(scopes[0])
+ recursive_evaluate_scope(scopes[1])
+ recursive_evaluate_scope(scopes[2])
+
+ result = merge_scopes(scopes)
+
+ assert len(result) == 2
+ r0 = result[0]
+ assert r0.total_condition == 'QT_FEATURE_bar'
+ assert r0.get_string('test') == 'foo'
+ assert r0.get_string('test2') == 'bar'
+
+ assert result[1] == scopes[1]
+
+
+def test_merge_two_unrelated_on_off_scopes():
+ scopes = [_new_scope(condition='ON', test='foo'),
+ _new_scope(condition='OFF', test2='bar')]
+
+ recursive_evaluate_scope(scopes[0])
+ recursive_evaluate_scope(scopes[1])
+
+ _validate(scopes, [scopes[0]])
+
+
+def test_merge_two_unrelated_on_off_scopes():
+ scopes = [_new_scope(condition='OFF', test='foo'),
+ _new_scope(condition='ON', test2='bar')]
+
+ recursive_evaluate_scope(scopes[0])
+ recursive_evaluate_scope(scopes[1])
+
+ _validate(scopes, [scopes[1]])
+
+
+def test_merge_parent_child_scopes_with_different_conditions():
+ scope = _new_scope(condition='FOO', test1='parent')
+ scopes = [scope, _new_scope(parent_scope=scope, condition='bar', test2='child')]
+
+ recursive_evaluate_scope(scope)
+
+ _validate(scopes, scopes)
+
+
+def test_merge_parent_child_scopes_with_same_conditions():
+ scope = _new_scope(condition='FOO AND bar', test1='parent')
+ scopes = [scope, _new_scope(parent_scope=scope, condition='FOO AND bar', test2='child')]
+
+ recursive_evaluate_scope(scope)
+
+ result = merge_scopes(scopes)
+
+ assert len(result) == 1
+ r0 = result[0]
+ assert r0.parent == None
+ assert r0.total_condition == 'FOO AND bar'
+ assert r0.get_string('test1') == 'parent'
+ assert r0.get_string('test2') == 'child'
+
+
+def test_merge_parent_child_scopes_with_on_child_condition():
+ scope = _new_scope(condition='FOO AND bar', test1='parent')
+ scopes = [scope, _new_scope(parent_scope=scope, condition='ON', test2='child')]
+
+ recursive_evaluate_scope(scope)
+
+ result = merge_scopes(scopes)
+
+ assert len(result) == 1
+ r0 = result[0]
+ assert r0.parent == None
+ assert r0.total_condition == 'FOO AND bar'
+ assert r0.get_string('test1') == 'parent'
+ assert r0.get_string('test2') == 'child'
+
+
+# Real world examples:
+
+# qstandardpaths selection:
+
+def test_qstandardpaths_scopes():
+ # top level:
+ scope1 = _new_scope(condition='ON', scope_id=1)
+
+ # win32 {
+ scope2 = _new_scope(parent_scope=scope1, condition='WIN32')
+ # !winrt {
+ # SOURCES += io/qstandardpaths_win.cpp
+ scope3 = _new_scope(parent_scope=scope2, condition='NOT WINRT',
+ SOURCES='qsp_win.cpp')
+ # } else {
+ # SOURCES += io/qstandardpaths_winrt.cpp
+ scope4 = _new_scope(parent_scope=scope2, condition='else',
+ SOURCES='qsp_winrt.cpp')
+ # }
+ # else: unix {
+ scope5 = _new_scope(parent_scope=scope1, condition='else')
+ scope6 = _new_scope(parent_scope=scope5, condition='UNIX')
+ # mac {
+ # OBJECTIVE_SOURCES += io/qstandardpaths_mac.mm
+ scope7 = _new_scope(parent_scope=scope6, condition='APPLE_OSX', SOURCES='qsp_mac.mm')
+ # } else:android:!android-embedded {
+ # SOURCES += io/qstandardpaths_android.cpp
+ scope8 = _new_scope(parent_scope=scope6, condition='else')
+ scope9 = _new_scope(parent_scope=scope8,
+ condition='ANDROID AND NOT ANDROID_EMBEDDED',
+ SOURCES='qsp_android.cpp')
+ # } else:haiku {
+ # SOURCES += io/qstandardpaths_haiku.cpp
+ scope10 = _new_scope(parent_scope=scope8, condition='else')
+ scope11 = _new_scope(parent_scope=scope10, condition='HAIKU', SOURCES='qsp_haiku.cpp')
+ # } else {
+ # SOURCES +=io/qstandardpaths_unix.cpp
+ scope12 = _new_scope(parent_scope=scope10, condition='else', SOURCES='qsp_unix.cpp')
+ # }
+ # }
+
+ recursive_evaluate_scope(scope1)
+
+ assert scope1.total_condition == 'ON'
+ assert scope2.total_condition == 'WIN32'
+ assert scope3.total_condition == 'WIN32 AND NOT WINRT'
+ assert scope4.total_condition == 'WINRT'
+ assert scope5.total_condition == 'UNIX'
+ assert scope6.total_condition == 'UNIX'
+ assert scope7.total_condition == 'APPLE_OSX'
+ assert scope8.total_condition == 'UNIX AND NOT APPLE_OSX'
+ assert scope9.total_condition == 'ANDROID AND NOT ANDROID_EMBEDDED'
+ assert scope10.total_condition == 'UNIX AND NOT APPLE_OSX AND (ANDROID_EMBEDDED OR NOT ANDROID)'
+ assert scope11.total_condition == 'HAIKU AND (ANDROID_EMBEDDED OR NOT ANDROID)'
+ assert scope12.total_condition == 'UNIX AND NOT APPLE_OSX AND NOT HAIKU AND (ANDROID_EMBEDDED OR NOT ANDROID)'
+
+def test_recursive_expansion():
+ scope = _new_scope(A='Foo',B='$$A/Bar')
+ assert scope.get_string('A') == 'Foo'
+ assert scope.get_string('B') == '$$A/Bar'
+ assert scope._expand_value('$$B/Source.cpp') == ['Foo/Bar/Source.cpp']
+ assert scope._expand_value('$$B') == ['Foo/Bar']
+