summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.gitignore16
-rw-r--r--CMakeLists.txt61
-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.cmake164
-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/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/FindATSPI2.cmake5
-rw-r--r--cmake/FindAtomic.cmake37
-rw-r--r--cmake/FindCups.cmake98
-rw-r--r--cmake/FindGLESv2.cmake40
-rw-r--r--cmake/FindGTK3.cmake3
-rw-r--r--cmake/FindLibproxy.cmake3
-rw-r--r--cmake/FindLibsystemd.cmake3
-rw-r--r--cmake/FindLibudev.cmake3
-rw-r--r--cmake/FindMtdev.cmake3
-rw-r--r--cmake/FindPCRE2.cmake13
-rw-r--r--cmake/FindPPS.cmake19
-rw-r--r--cmake/FindSlog2.cmake19
-rw-r--r--cmake/FindTslib.cmake3
-rw-r--r--cmake/FindWrapDoubleConversion.cmake43
-rw-r--r--cmake/FindWrapOpenGL.cmake18
-rw-r--r--cmake/FindWrapRt.cmake27
-rw-r--r--cmake/FindZSTD.cmake49
-rw-r--r--cmake/Finddouble-conversion.cmake32
-rw-r--r--cmake/QtBaseCMakeTesting.cmake9
-rw-r--r--cmake/QtBaseConfigureTests.cmake149
-rw-r--r--cmake/QtBaseGlobalTargets.cmake79
-rw-r--r--cmake/QtBuild.cmake1202
-rw-r--r--cmake/QtCompilerFlags.cmake6
-rw-r--r--cmake/QtCompilerOptimization.cmake121
-rw-r--r--cmake/QtConfig.cmake.in44
-rw-r--r--cmake/QtFeature.cmake488
-rw-r--r--cmake/QtModuleConfig.cmake.in34
-rw-r--r--cmake/QtPlatformSupport.cmake42
-rw-r--r--cmake/QtPostProcess.cmake46
-rw-r--r--cmake/QtSetup.cmake80
-rw-r--r--cmake/README.md144
-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--config.tests/x86_simd/CMakeLists.txt23
-rw-r--r--configure.cmake454
-rw-r--r--configure.json11
-rw-r--r--doc/global/macros.qdocconf1
-rw-r--r--examples/CMakeLists.txt25
-rw-r--r--examples/corelib/CMakeLists.txt7
-rw-r--r--examples/corelib/ipc/CMakeLists.txt14
-rw-r--r--examples/corelib/ipc/localfortuneclient/CMakeLists.txt17
-rw-r--r--examples/corelib/ipc/localfortuneserver/CMakeLists.txt17
-rw-r--r--examples/corelib/ipc/sharedmemory/CMakeLists.txt19
-rw-r--r--examples/corelib/mimetypes/CMakeLists.txt6
-rw-r--r--examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt21
-rw-r--r--examples/corelib/serialization/CMakeLists.txt5
-rw-r--r--examples/corelib/serialization/cbordump/CMakeLists.txt19
-rw-r--r--examples/corelib/serialization/convert/CMakeLists.txt26
-rw-r--r--examples/corelib/serialization/savegame/CMakeLists.txt22
-rw-r--r--examples/corelib/threads/CMakeLists.txt9
-rw-r--r--examples/corelib/threads/mandelbrot/CMakeLists.txt25
-rw-r--r--examples/corelib/threads/queuedcustomtype/CMakeLists.txt18
-rw-r--r--examples/corelib/threads/semaphores/CMakeLists.txt15
-rw-r--r--examples/corelib/threads/waitconditions/CMakeLists.txt15
-rw-r--r--examples/corelib/tools/CMakeLists.txt5
-rw-r--r--examples/corelib/tools/contiguouscache/CMakeLists.txt16
-rw-r--r--examples/corelib/tools/customtype/CMakeLists.txt16
-rw-r--r--examples/corelib/tools/customtypesending/CMakeLists.txt17
-rw-r--r--examples/dbus/CMakeLists.txt13
-rw-r--r--examples/dbus/chat/CMakeLists.txt22
-rw-r--r--examples/dbus/complexpingpong/CMakeLists.txt16
-rw-r--r--examples/dbus/listnames/CMakeLists.txt22
-rw-r--r--examples/dbus/pingpong/CMakeLists.txt35
-rw-r--r--examples/dbus/remotecontrolledcar/CMakeLists.txt4
-rw-r--r--examples/dbus/remotecontrolledcar/car/CMakeLists.txt19
-rw-r--r--examples/dbus/remotecontrolledcar/controller/CMakeLists.txt19
-rw-r--r--examples/embedded/CMakeLists.txt8
-rw-r--r--examples/embedded/digiflip/CMakeLists.txt15
-rw-r--r--examples/embedded/flickable/CMakeLists.txt16
-rw-r--r--examples/embedded/flightinfo/CMakeLists.txt25
-rw-r--r--examples/embedded/lightmaps/CMakeLists.txt22
-rw-r--r--examples/embedded/raycasting/CMakeLists.txt23
-rw-r--r--examples/embedded/styleexample/CMakeLists.txt28
-rw-r--r--examples/gui/CMakeLists.txt8
-rw-r--r--examples/gui/analogclock/CMakeLists.txt21
-rw-r--r--examples/gui/openglwindow/CMakeLists.txt18
-rw-r--r--examples/gui/rasterwindow/CMakeLists.txt18
-rw-r--r--examples/network/CMakeLists.txt45
-rw-r--r--examples/network/bearermonitor/CMakeLists.txt31
-rw-r--r--examples/network/blockingfortuneclient/CMakeLists.txt18
-rw-r--r--examples/network/broadcastreceiver/CMakeLists.txt17
-rw-r--r--examples/network/broadcastsender/CMakeLists.txt17
-rw-r--r--examples/network/dnslookup/CMakeLists.txt27
-rw-r--r--examples/network/download/CMakeLists.txt18
-rw-r--r--examples/network/downloadmanager/CMakeLists.txt21
-rw-r--r--examples/network/fortuneclient/CMakeLists.txt17
-rw-r--r--examples/network/fortuneserver/CMakeLists.txt17
-rw-r--r--examples/network/googlesuggest/CMakeLists.txt18
-rw-r--r--examples/network/http/CMakeLists.txt18
-rw-r--r--examples/network/loopback/CMakeLists.txt17
-rw-r--r--examples/network/multicastreceiver/CMakeLists.txt17
-rw-r--r--examples/network/multicastsender/CMakeLists.txt17
-rw-r--r--examples/network/multistreamclient/CMakeLists.txt21
-rw-r--r--examples/network/multistreamserver/CMakeLists.txt24
-rw-r--r--examples/network/network-chat/CMakeLists.txt21
-rw-r--r--examples/network/securesocketclient/CMakeLists.txt24
-rw-r--r--examples/network/secureudpclient/CMakeLists.txt22
-rw-r--r--examples/network/secureudpserver/CMakeLists.txt22
-rw-r--r--examples/network/threadedfortuneserver/CMakeLists.txt19
-rw-r--r--examples/network/torrent/CMakeLists.txt42
-rw-r--r--examples/qpa/CMakeLists.txt4
-rw-r--r--examples/qpa/qrasterwindow/CMakeLists.txt15
-rw-r--r--examples/qpa/windows/CMakeLists.txt19
-rw-r--r--examples/qtconcurrent/CMakeLists.txt9
-rw-r--r--examples/qtconcurrent/imagescaling/CMakeLists.txt17
-rw-r--r--examples/qtconcurrent/map/CMakeLists.txt20
-rw-r--r--examples/qtconcurrent/progressdialog/CMakeLists.txt18
-rw-r--r--examples/qtconcurrent/runfunction/CMakeLists.txt19
-rw-r--r--examples/qtconcurrent/wordcount/CMakeLists.txt19
-rw-r--r--examples/qtestlib/CMakeLists.txt7
-rw-r--r--examples/qtestlib/tutorial1/CMakeLists.txt16
-rw-r--r--examples/qtestlib/tutorial2/CMakeLists.txt16
-rw-r--r--examples/qtestlib/tutorial3/CMakeLists.txt16
-rw-r--r--examples/qtestlib/tutorial4/CMakeLists.txt16
-rw-r--r--examples/qtestlib/tutorial5/CMakeLists.txt16
-rw-r--r--examples/sql/CMakeLists.txt17
-rw-r--r--examples/sql/books/CMakeLists.txt30
-rw-r--r--examples/sql/cachedtable/CMakeLists.txt18
-rw-r--r--examples/sql/drilldown/CMakeLists.txt28
-rw-r--r--examples/sql/masterdetail/CMakeLists.txt30
-rw-r--r--examples/sql/querymodel/CMakeLists.txt19
-rw-r--r--examples/sql/relationaltablemodel/CMakeLists.txt17
-rw-r--r--examples/sql/sqlbrowser/CMakeLists.txt29
-rw-r--r--examples/sql/sqlwidgetmapper/CMakeLists.txt17
-rw-r--r--examples/sql/tablemodel/CMakeLists.txt17
-rw-r--r--examples/widgets/CMakeLists.txt33
-rw-r--r--examples/widgets/animation/CMakeLists.txt8
-rw-r--r--examples/widgets/animation/animatedtiles/CMakeLists.txt26
-rw-r--r--examples/widgets/animation/easing/CMakeLists.txt23
-rw-r--r--examples/widgets/animation/moveblocks/CMakeLists.txt15
-rw-r--r--examples/widgets/animation/states/CMakeLists.txt25
-rw-r--r--examples/widgets/animation/stickman/CMakeLists.txt29
-rw-r--r--examples/widgets/animation/sub-attaq/CMakeLists.txt142
-rw-r--r--examples/widgets/desktop/CMakeLists.txt4
-rw-r--r--examples/widgets/desktop/screenshot/CMakeLists.txt16
-rw-r--r--examples/widgets/desktop/systray/CMakeLists.txt23
-rw-r--r--examples/widgets/dialogs/CMakeLists.txt14
-rw-r--r--examples/widgets/dialogs/classwizard/CMakeLists.txt27
-rw-r--r--examples/widgets/dialogs/extension/CMakeLists.txt16
-rw-r--r--examples/widgets/dialogs/findfiles/CMakeLists.txt16
-rw-r--r--examples/widgets/dialogs/licensewizard/CMakeLists.txt23
-rw-r--r--examples/widgets/dialogs/standarddialogs/CMakeLists.txt16
-rw-r--r--examples/widgets/dialogs/tabdialog/CMakeLists.txt16
-rw-r--r--examples/widgets/dialogs/trivialwizard/CMakeLists.txt15
-rw-r--r--examples/widgets/draganddrop/CMakeLists.txt7
-rw-r--r--examples/widgets/draganddrop/draggableicons/CMakeLists.txt23
-rw-r--r--examples/widgets/draganddrop/draggabletext/CMakeLists.txt21
-rw-r--r--examples/widgets/draganddrop/dropsite/CMakeLists.txt17
-rw-r--r--examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt22
-rw-r--r--examples/widgets/draganddrop/puzzle/CMakeLists.txt26
-rw-r--r--examples/widgets/effects/CMakeLists.txt4
-rw-r--r--examples/widgets/effects/blurpicker/CMakeLists.txt30
-rw-r--r--examples/widgets/effects/fademessage/CMakeLists.txt21
-rw-r--r--examples/widgets/gestures/CMakeLists.txt3
-rw-r--r--examples/widgets/gestures/imagegestures/CMakeLists.txt17
-rw-r--r--examples/widgets/graphicsview/CMakeLists.txt20
-rw-r--r--examples/widgets/graphicsview/anchorlayout/CMakeLists.txt15
-rw-r--r--examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt22
-rw-r--r--examples/widgets/graphicsview/boxes/CMakeLists.txt55
-rw-r--r--examples/widgets/graphicsview/chip/CMakeLists.txt44
-rw-r--r--examples/widgets/graphicsview/collidingmice/CMakeLists.txt21
-rw-r--r--examples/widgets/graphicsview/diagramscene/CMakeLists.txt39
-rw-r--r--examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt22
-rw-r--r--examples/widgets/graphicsview/elasticnodes/CMakeLists.txt18
-rw-r--r--examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt28
-rw-r--r--examples/widgets/graphicsview/flowlayout/CMakeLists.txt20
-rw-r--r--examples/widgets/graphicsview/padnavigator/CMakeLists.txt43
-rw-r--r--examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt15
-rw-r--r--examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt25
-rw-r--r--examples/widgets/itemviews/CMakeLists.txt27
-rw-r--r--examples/widgets/itemviews/addressbook/CMakeLists.txt20
-rw-r--r--examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt16
-rw-r--r--examples/widgets/itemviews/chart/CMakeLists.txt30
-rw-r--r--examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt17
-rw-r--r--examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt16
-rw-r--r--examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt23
-rw-r--r--examples/widgets/itemviews/dirview/CMakeLists.txt15
-rw-r--r--examples/widgets/itemviews/editabletreemodel/CMakeLists.txt23
-rw-r--r--examples/widgets/itemviews/fetchmore/CMakeLists.txt17
-rw-r--r--examples/widgets/itemviews/flattreeview/CMakeLists.txt15
-rw-r--r--examples/widgets/itemviews/frozencolumn/CMakeLists.txt21
-rw-r--r--examples/widgets/itemviews/interview/CMakeLists.txt32
-rw-r--r--examples/widgets/itemviews/pixelator/CMakeLists.txt31
-rw-r--r--examples/widgets/itemviews/puzzle/CMakeLists.txt23
-rw-r--r--examples/widgets/itemviews/simpledommodel/CMakeLists.txt19
-rw-r--r--examples/widgets/itemviews/simpletreemodel/CMakeLists.txt22
-rw-r--r--examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt16
-rw-r--r--examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt16
-rw-r--r--examples/widgets/itemviews/spreadsheet/CMakeLists.txt35
-rw-r--r--examples/widgets/itemviews/stardelegate/CMakeLists.txt18
-rw-r--r--examples/widgets/itemviews/storageview/CMakeLists.txt20
-rw-r--r--examples/widgets/layouts/CMakeLists.txt6
-rw-r--r--examples/widgets/layouts/basiclayouts/CMakeLists.txt16
-rw-r--r--examples/widgets/layouts/borderlayout/CMakeLists.txt17
-rw-r--r--examples/widgets/layouts/dynamiclayouts/CMakeLists.txt16
-rw-r--r--examples/widgets/layouts/flowlayout/CMakeLists.txt17
-rw-r--r--examples/widgets/mac/CMakeLists.txt7
-rw-r--r--examples/widgets/mac/qmaccocoaviewcontainer/CMakeLists.txt19
-rw-r--r--examples/widgets/mac/qmacnativewidget/CMakeLists.txt19
-rw-r--r--examples/widgets/mainwindows/CMakeLists.txt8
-rw-r--r--examples/widgets/mainwindows/application/CMakeLists.txt26
-rw-r--r--examples/widgets/mainwindows/dockwidgets/CMakeLists.txt32
-rw-r--r--examples/widgets/mainwindows/mainwindow/CMakeLists.txt35
-rw-r--r--examples/widgets/mainwindows/mdi/CMakeLists.txt27
-rw-r--r--examples/widgets/mainwindows/menus/CMakeLists.txt16
-rw-r--r--examples/widgets/mainwindows/sdi/CMakeLists.txt26
-rw-r--r--examples/widgets/painting/CMakeLists.txt14
-rw-r--r--examples/widgets/painting/affine/CMakeLists.txt23
-rw-r--r--examples/widgets/painting/basicdrawing/CMakeLists.txt23
-rw-r--r--examples/widgets/painting/composition/CMakeLists.txt23
-rw-r--r--examples/widgets/painting/concentriccircles/CMakeLists.txt17
-rw-r--r--examples/widgets/painting/deform/CMakeLists.txt21
-rw-r--r--examples/widgets/painting/fontsampler/CMakeLists.txt25
-rw-r--r--examples/widgets/painting/gradients/CMakeLists.txt21
-rw-r--r--examples/widgets/painting/imagecomposition/CMakeLists.txt22
-rw-r--r--examples/widgets/painting/painterpaths/CMakeLists.txt26
-rw-r--r--examples/widgets/painting/pathstroke/CMakeLists.txt21
-rw-r--r--examples/widgets/painting/shared/CMakeLists.txt64
-rw-r--r--examples/widgets/painting/transformations/CMakeLists.txt17
-rw-r--r--examples/widgets/richtext/CMakeLists.txt6
-rw-r--r--examples/widgets/richtext/calendar/CMakeLists.txt16
-rw-r--r--examples/widgets/richtext/orderform/CMakeLists.txt25
-rw-r--r--examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt17
-rw-r--r--examples/widgets/richtext/textedit/CMakeLists.txt75
-rw-r--r--examples/widgets/scroller/CMakeLists.txt3
-rw-r--r--examples/widgets/scroller/graphicsview/CMakeLists.txt18
-rw-r--r--examples/widgets/statemachine/CMakeLists.txt11
-rw-r--r--examples/widgets/statemachine/eventtransitions/CMakeLists.txt15
-rw-r--r--examples/widgets/statemachine/factorial/CMakeLists.txt22
-rw-r--r--examples/widgets/statemachine/pingpong/CMakeLists.txt22
-rw-r--r--examples/widgets/statemachine/rogue/CMakeLists.txt17
-rw-r--r--examples/widgets/statemachine/trafficlight/CMakeLists.txt15
-rw-r--r--examples/widgets/statemachine/twowaybutton/CMakeLists.txt15
-rw-r--r--examples/widgets/tools/CMakeLists.txt20
-rw-r--r--examples/widgets/tools/codecs/CMakeLists.txt26
-rw-r--r--examples/widgets/tools/completer/CMakeLists.txt23
-rw-r--r--examples/widgets/tools/customcompleter/CMakeLists.txt22
-rw-r--r--examples/widgets/tools/echoplugin/CMakeLists.txt4
-rw-r--r--examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt33
-rw-r--r--examples/widgets/tools/echoplugin/plugin/CMakeLists.txt22
-rw-r--r--examples/widgets/tools/i18n/CMakeLists.txt38
-rw-r--r--examples/widgets/tools/plugandpaint/CMakeLists.txt4
-rw-r--r--examples/widgets/tools/plugandpaint/app/CMakeLists.txt29
-rw-r--r--examples/widgets/tools/plugandpaint/plugins/CMakeLists.txt4
-rw-r--r--examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt30
-rw-r--r--examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt27
-rw-r--r--examples/widgets/tools/regexp/CMakeLists.txt16
-rw-r--r--examples/widgets/tools/regularexpression/CMakeLists.txt21
-rw-r--r--examples/widgets/tools/settingseditor/CMakeLists.txt22
-rw-r--r--examples/widgets/tools/styleplugin/CMakeLists.txt4
-rw-r--r--examples/widgets/tools/styleplugin/plugin/CMakeLists.txt32
-rw-r--r--examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt31
-rw-r--r--examples/widgets/tools/treemodelcompleter/CMakeLists.txt22
-rw-r--r--examples/widgets/tools/undo/CMakeLists.txt44
-rw-r--r--examples/widgets/tools/undoframework/CMakeLists.txt24
-rw-r--r--examples/widgets/touch/CMakeLists.txt6
-rw-r--r--examples/widgets/touch/dials/CMakeLists.txt16
-rw-r--r--examples/widgets/touch/fingerpaint/CMakeLists.txt25
-rw-r--r--examples/widgets/touch/knobs/CMakeLists.txt16
-rw-r--r--examples/widgets/touch/pinchzoom/CMakeLists.txt22
-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.txt19
-rw-r--r--examples/widgets/tutorials/addressbook/part2/CMakeLists.txt19
-rw-r--r--examples/widgets/tutorials/addressbook/part3/CMakeLists.txt19
-rw-r--r--examples/widgets/tutorials/addressbook/part4/CMakeLists.txt19
-rw-r--r--examples/widgets/tutorials/addressbook/part5/CMakeLists.txt20
-rw-r--r--examples/widgets/tutorials/addressbook/part6/CMakeLists.txt20
-rw-r--r--examples/widgets/tutorials/addressbook/part7/CMakeLists.txt20
-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.txt15
-rw-r--r--examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt15
-rw-r--r--examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt15
-rw-r--r--examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt15
-rw-r--r--examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt15
-rw-r--r--examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt19
-rw-r--r--examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt19
-rw-r--r--examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt19
-rw-r--r--examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt19
-rw-r--r--examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt20
-rw-r--r--examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt19
-rw-r--r--examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt19
-rw-r--r--examples/widgets/tutorials/modelview/CMakeLists.txt9
-rw-r--r--examples/widgets/tutorials/notepad/CMakeLists.txt49
-rw-r--r--examples/widgets/tutorials/widgets/CMakeLists.txt6
-rw-r--r--examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt15
-rw-r--r--examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt15
-rw-r--r--examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt15
-rw-r--r--examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt15
-rw-r--r--examples/widgets/widgets/CMakeLists.txt27
-rw-r--r--examples/widgets/widgets/analogclock/CMakeLists.txt19
-rw-r--r--examples/widgets/widgets/calculator/CMakeLists.txt17
-rw-r--r--examples/widgets/widgets/calendarwidget/CMakeLists.txt16
-rw-r--r--examples/widgets/widgets/charactermap/CMakeLists.txt17
-rw-r--r--examples/widgets/widgets/codeeditor/CMakeLists.txt16
-rw-r--r--examples/widgets/widgets/digitalclock/CMakeLists.txt16
-rw-r--r--examples/widgets/widgets/elidedlabel/CMakeLists.txt21
-rw-r--r--examples/widgets/widgets/groupbox/CMakeLists.txt16
-rw-r--r--examples/widgets/widgets/icons/CMakeLists.txt24
-rw-r--r--examples/widgets/widgets/imageviewer/CMakeLists.txt24
-rw-r--r--examples/widgets/widgets/lineedits/CMakeLists.txt16
-rw-r--r--examples/widgets/widgets/mousebuttons/CMakeLists.txt19
-rw-r--r--examples/widgets/widgets/movie/CMakeLists.txt19
-rw-r--r--examples/widgets/widgets/scribble/CMakeLists.txt25
-rw-r--r--examples/widgets/widgets/shapedclock/CMakeLists.txt16
-rw-r--r--examples/widgets/widgets/sliders/CMakeLists.txt17
-rw-r--r--examples/widgets/widgets/spinboxes/CMakeLists.txt16
-rw-r--r--examples/widgets/widgets/styles/CMakeLists.txt23
-rw-r--r--examples/widgets/widgets/stylesheet/CMakeLists.txt56
-rw-r--r--examples/widgets/widgets/tablet/CMakeLists.txt26
-rw-r--r--examples/widgets/widgets/tetrix/CMakeLists.txt18
-rw-r--r--examples/widgets/widgets/tooltips/CMakeLists.txt24
-rw-r--r--examples/widgets/widgets/validators/CMakeLists.txt25
-rw-r--r--examples/widgets/widgets/wiggly/CMakeLists.txt17
-rw-r--r--examples/widgets/widgets/windowflags/CMakeLists.txt17
-rw-r--r--examples/widgets/windowcontainer/CMakeLists.txt18
-rw-r--r--qmake/CMakeLists.txt212
-rw-r--r--src/3rdparty/CMakeLists.txt2
-rw-r--r--src/3rdparty/harfbuzz/CMakeLists.txt11
-rw-r--r--src/3rdparty/tinycbor/CMakeLists.txt2
-rw-r--r--src/CMakeLists.txt79
-rw-r--r--src/concurrent/CMakeLists.txt44
-rw-r--r--src/corelib/CMakeLists.txt1061
-rw-r--r--src/corelib/Qt5CoreConfigExtras.cmake.in177
-rw-r--r--src/corelib/Qt5CoreMacros.cmake10
-rw-r--r--src/corelib/configure.cmake893
-rw-r--r--src/corelib/configure.json27
-rw-r--r--src/corelib/global/qconfig.cpp.in65
-rw-r--r--src/corelib/kernel/qvariant.cpp4
-rw-r--r--src/dbus/CMakeLists.txt74
-rw-r--r--src/dbus/Qt5DBusConfigExtras.cmake.in33
-rw-r--r--src/dbus/Qt5DBusMacros.cmake8
-rw-r--r--src/gui/CMakeLists.txt647
-rw-r--r--src/gui/configure.cmake990
-rw-r--r--src/gui/configure.json19
-rw-r--r--src/gui/util/qshaderlanguage_p.h3
-rw-r--r--src/network/CMakeLists.txt418
-rw-r--r--src/network/configure.cmake355
-rw-r--r--src/network/configure.json18
-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/CMakeLists.txt64
-rw-r--r--src/platformheaders/CMakeLists.txt12
-rw-r--r--src/platformheaders/fake.cpp0
-rw-r--r--src/platformsupport/CMakeLists.txt54
-rw-r--r--src/platformsupport/accessibility/CMakeLists.txt21
-rw-r--r--src/platformsupport/clipboard/CMakeLists.txt30
-rw-r--r--src/platformsupport/devicediscovery/CMakeLists.txt41
-rw-r--r--src/platformsupport/edid/CMakeLists.txt21
-rw-r--r--src/platformsupport/eglconvenience/CMakeLists.txt41
-rw-r--r--src/platformsupport/eventdispatchers/CMakeLists.txt43
-rw-r--r--src/platformsupport/fbconvenience/CMakeLists.txt26
-rw-r--r--src/platformsupport/fontdatabases/CMakeLists.txt125
-rw-r--r--src/platformsupport/fontdatabases/fake.cpp0
-rw-r--r--src/platformsupport/glxconvenience/CMakeLists.txt24
-rw-r--r--src/platformsupport/graphics/CMakeLists.txt21
-rw-r--r--src/platformsupport/input/CMakeLists.txt111
-rw-r--r--src/platformsupport/input/xkbcommon/CMakeLists.txt35
-rw-r--r--src/platformsupport/kmsconvenience/CMakeLists.txt23
-rw-r--r--src/platformsupport/kmsconvenience/kmsconvenience.pro2
-rw-r--r--src/platformsupport/linuxaccessibility/CMakeLists.txt41
-rw-r--r--src/platformsupport/platformcompositor/CMakeLists.txt22
-rw-r--r--src/platformsupport/services/CMakeLists.txt30
-rw-r--r--src/platformsupport/themes/CMakeLists.txt55
-rw-r--r--src/platformsupport/vkconvenience/CMakeLists.txt22
-rw-r--r--src/platformsupport/windowsuiautomation/CMakeLists.txt29
-rw-r--r--src/plugins/CMakeLists.txt28
-rw-r--r--src/plugins/bearer/CMakeLists.txt9
-rw-r--r--src/plugins/bearer/connman/CMakeLists.txt25
-rw-r--r--src/plugins/bearer/generic/CMakeLists.txt31
-rw-r--r--src/plugins/bearer/networkmanager/CMakeLists.txt25
-rw-r--r--src/plugins/generic/CMakeLists.txt26
-rw-r--r--src/plugins/generic/evdevkeyboard/CMakeLists.txt25
-rw-r--r--src/plugins/generic/evdevmouse/CMakeLists.txt25
-rw-r--r--src/plugins/generic/evdevtablet/CMakeLists.txt25
-rw-r--r--src/plugins/generic/evdevtouch/CMakeLists.txt25
-rw-r--r--src/plugins/generic/libinput/CMakeLists.txt25
-rw-r--r--src/plugins/generic/tslib/CMakeLists.txt28
-rw-r--r--src/plugins/generic/tuiotouch/CMakeLists.txt31
-rw-r--r--src/plugins/imageformats/CMakeLists.txt11
-rw-r--r--src/plugins/imageformats/gif/CMakeLists.txt14
-rw-r--r--src/plugins/imageformats/ico/CMakeLists.txt15
-rw-r--r--src/plugins/imageformats/jpeg/CMakeLists.txt19
-rw-r--r--src/plugins/platforminputcontexts/CMakeLists.txt10
-rw-r--r--src/plugins/platforminputcontexts/compose/CMakeLists.txt29
-rw-r--r--src/plugins/platforminputcontexts/ibus/CMakeLists.txt29
-rw-r--r--src/plugins/platforms/CMakeLists.txt76
-rw-r--r--src/plugins/platforms/cocoa/CMakeLists.txt141
-rw-r--r--src/plugins/platforms/eglfs/CMakeLists.txt102
-rw-r--r--src/plugins/platforms/eglfs/deviceintegration/CMakeLists.txt49
-rw-r--r--src/plugins/platforms/eglfs/deviceintegration/eglfs_emu/CMakeLists.txt26
-rw-r--r--src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/CMakeLists.txt38
-rw-r--r--src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/CMakeLists.txt34
-rw-r--r--src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/CMakeLists.txt29
-rw-r--r--src/plugins/platforms/eglfs/deviceintegration/eglfs_x11/CMakeLists.txt31
-rw-r--r--src/plugins/platforms/linuxfb/CMakeLists.txt44
-rw-r--r--src/plugins/platforms/minimal/CMakeLists.txt36
-rw-r--r--src/plugins/platforms/minimalegl/CMakeLists.txt41
-rw-r--r--src/plugins/platforms/offscreen/CMakeLists.txt46
-rw-r--r--src/plugins/platforms/vnc/CMakeLists.txt41
-rw-r--r--src/plugins/platforms/windows/CMakeLists.txt203
-rw-r--r--src/plugins/platforms/windows/qwindowscontext.cpp2
-rw-r--r--src/plugins/platforms/xcb/CMakeLists.txt167
-rw-r--r--src/plugins/platformthemes/CMakeLists.txt10
-rw-r--r--src/plugins/platformthemes/gtk3/CMakeLists.txt29
-rw-r--r--src/plugins/platformthemes/xdgdesktopportal/CMakeLists.txt21
-rw-r--r--src/plugins/printsupport/CMakeLists.txt11
-rw-r--r--src/plugins/printsupport/cups/CMakeLists.txt28
-rw-r--r--src/plugins/sqldrivers/CMakeLists.txt51
-rw-r--r--src/plugins/sqldrivers/configure.cmake58
-rw-r--r--src/plugins/sqldrivers/configure.json4
-rw-r--r--src/plugins/sqldrivers/odbc/CMakeLists.txt33
-rw-r--r--src/plugins/sqldrivers/odbc/qsql_odbc.cpp2
-rw-r--r--src/plugins/sqldrivers/psql/CMakeLists.txt28
-rw-r--r--src/plugins/sqldrivers/sqlite/CMakeLists.txt32
-rw-r--r--src/plugins/styles/CMakeLists.txt11
-rw-r--r--src/plugins/styles/mac/CMakeLists.txt19
-rw-r--r--src/printsupport/CMakeLists.txt147
-rw-r--r--src/printsupport/configure.cmake59
-rw-r--r--src/sql/CMakeLists.txt51
-rw-r--r--src/sql/configure.cmake21
-rw-r--r--src/testlib/CMakeLists.txt112
-rw-r--r--src/testlib/Qt5TestConfigExtras.cmake.in6
-rw-r--r--src/testlib/configure.cmake26
-rw-r--r--src/tools/CMakeLists.txt7
-rw-r--r--src/tools/bootstrap/CMakeLists.txt180
-rw-r--r--src/tools/moc/CMakeLists.txt32
-rw-r--r--src/tools/qdbuscpp2xml/CMakeLists.txt40
-rw-r--r--src/tools/qdbusxml2cpp/CMakeLists.txt29
-rw-r--r--src/tools/qfloat16-tables/CMakeLists.txt16
-rw-r--r--src/tools/qlalr/CMakeLists.txt23
-rw-r--r--src/tools/qvkgen/CMakeLists.txt13
-rw-r--r--src/tools/rcc/CMakeLists.txt22
-rw-r--r--src/tools/tracegen/CMakeLists.txt21
-rw-r--r--src/tools/tracegen/provider.h1
-rw-r--r--src/tools/uic/CMakeLists.txt49
-rw-r--r--src/widgets/CMakeLists.txt792
-rw-r--r--src/widgets/Qt5WidgetsConfigExtras.cmake.in19
-rw-r--r--src/widgets/Qt5WidgetsMacros.cmake2
-rw-r--r--src/widgets/configure.cmake569
-rw-r--r--src/xml/CMakeLists.txt29
-rw-r--r--src/xml/configure.cmake22
-rw-r--r--tests/CMakeLists.txt1
-rw-r--r--tests/auto/CMakeLists.txt55
-rw-r--r--tests/auto/concurrent/CMakeLists.txt8
-rw-r--r--tests/auto/concurrent/qtconcurrentfilter/CMakeLists.txt14
-rw-r--r--tests/auto/concurrent/qtconcurrentiteratekernel/CMakeLists.txt12
-rw-r--r--tests/auto/concurrent/qtconcurrentmap/CMakeLists.txt20
-rw-r--r--tests/auto/concurrent/qtconcurrentmedian/CMakeLists.txt14
-rw-r--r--tests/auto/concurrent/qtconcurrentrun/CMakeLists.txt18
-rw-r--r--tests/auto/concurrent/qtconcurrentthreadengine/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/animation/CMakeLists.txt6
-rw-r--r--tests/auto/corelib/animation/qabstractanimation/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/animation/qanimationgroup/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/animation/qparallelanimationgroup/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/animation/qpauseanimation/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/animation/qsequentialanimationgroup/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/animation/qvariantanimation/CMakeLists.txt1
-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.txt1
-rw-r--r--tests/auto/corelib/codecs/utf8/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/global/CMakeLists.txt12
-rw-r--r--tests/auto/corelib/global/q_func_info/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/global/qflags/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/global/qfloat16/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/global/qgetputenv/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/global/qglobal/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/global/qglobalstatic/CMakeLists.txt8
-rw-r--r--tests/auto/corelib/global/qhooks/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/global/qlogging/CMakeLists.txt10
-rw-r--r--tests/auto/corelib/global/qlogging/test/test.pro1
-rw-r--r--tests/auto/corelib/global/qlogging/tst_qlogging.cpp4
-rw-r--r--tests/auto/corelib/global/qnumeric/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/global/qrand/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/global/qrandomgenerator/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/global/qtendian/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/io/CMakeLists.txt14
-rw-r--r--tests/auto/corelib/io/largefile/CMakeLists.txt6
-rw-r--r--tests/auto/corelib/io/qbuffer/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/io/qdataurl/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/io/qfilesystementry/CMakeLists.txt7
-rw-r--r--tests/auto/corelib/io/qfilesystemwatcher/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/io/qipaddress/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/io/qloggingcategory/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/io/qnodebug/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/io/qprocessenvironment/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/io/qstorageinfo/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/io/qurlquery/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/itemmodels/CMakeLists.txt4
-rw-r--r--tests/auto/corelib/itemmodels/qabstractproxymodel/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/itemmodels/qitemselectionmodel/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/itemmodels/qstringlistmodel/CMakeLists.txt4
-rw-r--r--tests/auto/corelib/kernel/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/kernel/qdeadlinetimer/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/kernel/qelapsedtimer/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/kernel/qeventdispatcher/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/kernel/qmath/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/kernel/qmetaenum/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/kernel/qmetamethod/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/kernel/qmetaobject/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/kernel/qmetaobjectbuilder/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/kernel/qmetaproperty/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/kernel/qmimedata/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/kernel/qsignalmapper/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/kernel/qwineventnotifier/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/mimetypes/CMakeLists.txt2
-rw-r--r--tests/auto/corelib/mimetypes/qmimetype/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/serialization/CMakeLists.txt5
-rw-r--r--tests/auto/corelib/serialization/qcborstreamreader/CMakeLists.txt6
-rw-r--r--tests/auto/corelib/serialization/qcborstreamwriter/CMakeLists.txt5
-rw-r--r--tests/auto/corelib/serialization/qcborvalue/CMakeLists.txt6
-rw-r--r--tests/auto/corelib/serialization/qcborvalue_json/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/statemachine/CMakeLists.txt2
-rw-r--r--tests/auto/corelib/statemachine/qstate/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/thread/CMakeLists.txt13
-rw-r--r--tests/auto/corelib/thread/qatomicint/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/thread/qatomicpointer/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/thread/qfuture/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/thread/qfuturesynchronizer/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/thread/qmutexlocker/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/thread/qreadlocker/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/thread/qreadwritelock/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/thread/qresultstore/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/thread/qsemaphore/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/thread/qthreadpool/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/thread/qwaitcondition/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/thread/qwritelocker/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/CMakeLists.txt47
-rw-r--r--tests/auto/corelib/tools/qalgorithms/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qarraydata/CMakeLists.txt4
-rw-r--r--tests/auto/corelib/tools/qbitarray/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qbytearraylist/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qbytedatabuffer/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qcache/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qcommandlineparser/CMakeLists.txt3
-rw-r--r--tests/auto/corelib/tools/qcommandlineparser/testhelper/CMakeLists.txt20
-rw-r--r--tests/auto/corelib/tools/qcontiguouscache/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qdate/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qeasingcurve/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qexplicitlyshareddatapointer/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qhash/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qhashfunctions/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qlinkedlist/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qlist/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qmakearray/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qmap/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qmargins/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qmessageauthenticationcode/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qpair/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qpoint/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qpointf/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qqueue/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qrect/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qregexp/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qregularexpression/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qringbuffer/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qscopedpointer/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qscopedvaluerollback/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qscopeguard/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qset/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qsize/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qsizef/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qstl/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qstring_no_cast_from_bytearray/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qstringbuilder/qstringbuilder1/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qstringbuilder/qstringbuilder2/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qstringbuilder/qstringbuilder3/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qstringbuilder/qstringbuilder4/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qstringiterator/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qstringlist/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qstringmatcher/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qstringref/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qtime/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qtimeline/CMakeLists.txt1
-rw-r--r--tests/auto/corelib/tools/qvarlengtharray/CMakeLists.txt1
-rw-r--r--tests/auto/dbus/CMakeLists.txt32
-rw-r--r--tests/auto/dbus/qdbusabstractadaptor/CMakeLists.txt12
-rw-r--r--tests/auto/dbus/qdbusabstractadaptor/qmyserver/CMakeLists.txt14
-rw-r--r--tests/auto/dbus/qdbusabstractinterface/CMakeLists.txt21
-rw-r--r--tests/auto/dbus/qdbusabstractinterface/qpinger/CMakeLists.txt14
-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.txt17
-rw-r--r--tests/auto/dbus/qdbuscontext/CMakeLists.txt12
-rw-r--r--tests/auto/dbus/qdbusinterface/CMakeLists.txt26
-rw-r--r--tests/auto/dbus/qdbusinterface/qmyserver/CMakeLists.txt17
-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/CMakeLists.txt26
-rw-r--r--tests/auto/dbus/qdbusmarshall/qpong/CMakeLists.txt12
-rw-r--r--tests/auto/dbus/qdbusmetaobject/CMakeLists.txt12
-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.txt26
-rw-r--r--tests/auto/dbus/qdbusxmlparser/CMakeLists.txt14
-rw-r--r--tests/auto/gui/CMakeLists.txt19
-rw-r--r--tests/auto/gui/image/CMakeLists.txt15
-rw-r--r--tests/auto/gui/image/qimageiohandler/CMakeLists.txt1
-rw-r--r--tests/auto/gui/image/qpicture/CMakeLists.txt1
-rw-r--r--tests/auto/gui/itemmodels/CMakeLists.txt4
-rw-r--r--tests/auto/gui/itemmodels/qstandarditem/CMakeLists.txt1
-rw-r--r--tests/auto/gui/kernel/CMakeLists.txt38
-rw-r--r--tests/auto/gui/kernel/qcursor/CMakeLists.txt1
-rw-r--r--tests/auto/gui/kernel/qevent/CMakeLists.txt1
-rw-r--r--tests/auto/gui/kernel/qfileopenevent/CMakeLists.txt2
-rw-r--r--tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/CMakeLists.txt1
-rw-r--r--tests/auto/gui/kernel/qfileopenevent/test/CMakeLists.txt1
-rw-r--r--tests/auto/gui/kernel/qguivariant/CMakeLists.txt2
-rw-r--r--tests/auto/gui/kernel/qguivariant/no_application/CMakeLists.txt1
-rw-r--r--tests/auto/gui/kernel/qmouseevent/CMakeLists.txt1
-rw-r--r--tests/auto/gui/kernel/qpalette/CMakeLists.txt1
-rw-r--r--tests/auto/gui/math3d/CMakeLists.txt3
-rw-r--r--tests/auto/gui/math3d/qmatrixnxn/CMakeLists.txt5
-rw-r--r--tests/auto/gui/math3d/qquaternion/CMakeLists.txt1
-rw-r--r--tests/auto/gui/math3d/qvectornd/CMakeLists.txt1
-rw-r--r--tests/auto/gui/painting/CMakeLists.txt19
-rw-r--r--tests/auto/gui/painting/qpagesize/CMakeLists.txt1
-rw-r--r--tests/auto/gui/painting/qpaintengine/CMakeLists.txt1
-rw-r--r--tests/auto/gui/painting/qpainterpath/CMakeLists.txt1
-rw-r--r--tests/auto/gui/painting/qpainterpathstroker/CMakeLists.txt1
-rw-r--r--tests/auto/gui/painting/qpen/CMakeLists.txt1
-rw-r--r--tests/auto/gui/util/CMakeLists.txt13
-rw-r--r--tests/auto/gui/util/qdoublevalidator/CMakeLists.txt1
-rw-r--r--tests/auto/gui/util/qintvalidator/CMakeLists.txt1
-rw-r--r--tests/auto/gui/util/qregexpvalidator/CMakeLists.txt1
-rw-r--r--tests/auto/gui/util/qregularexpressionvalidator/CMakeLists.txt1
-rw-r--r--tests/auto/opengl/CMakeLists.txt6
-rw-r--r--tests/auto/opengl/qgl/CMakeLists.txt7
-rw-r--r--tests/auto/opengl/qglbuffer/CMakeLists.txt1
-rw-r--r--tests/auto/opengl/qglfunctions/CMakeLists.txt1
-rw-r--r--tests/auto/opengl/qglthreads/CMakeLists.txt7
-rw-r--r--tests/auto/other/qtokenautomaton/CMakeLists.txt15
-rw-r--r--tests/auto/other/toolsupport/CMakeLists.txt1
-rw-r--r--tests/auto/other/xkbkeyboard/CMakeLists.txt2
-rw-r--r--tests/auto/printsupport/CMakeLists.txt2
-rw-r--r--tests/auto/printsupport/dialogs/CMakeLists.txt3
-rw-r--r--tests/auto/printsupport/dialogs/qabstractprintdialog/CMakeLists.txt13
-rw-r--r--tests/auto/printsupport/kernel/CMakeLists.txt5
-rw-r--r--tests/auto/printsupport/kernel/qprintdevice/CMakeLists.txt14
-rw-r--r--tests/auto/printsupport/kernel/qprinter/CMakeLists.txt13
-rw-r--r--tests/auto/printsupport/kernel/qprinterinfo/CMakeLists.txt14
-rw-r--r--tests/auto/sql/CMakeLists.txt2
-rw-r--r--tests/auto/sql/kernel/CMakeLists.txt9
-rw-r--r--tests/auto/sql/kernel/qsql/CMakeLists.txt6
-rw-r--r--tests/auto/sql/kernel/qsqldatabase/CMakeLists.txt6
-rw-r--r--tests/auto/sql/kernel/qsqldriver/CMakeLists.txt6
-rw-r--r--tests/auto/sql/kernel/qsqlerror/CMakeLists.txt1
-rw-r--r--tests/auto/sql/kernel/qsqlfield/CMakeLists.txt1
-rw-r--r--tests/auto/sql/kernel/qsqlquery/CMakeLists.txt6
-rw-r--r--tests/auto/sql/kernel/qsqlrecord/CMakeLists.txt1
-rw-r--r--tests/auto/sql/kernel/qsqlresult/CMakeLists.txt8
-rw-r--r--tests/auto/sql/kernel/qsqlthread/CMakeLists.txt6
-rw-r--r--tests/auto/sql/models/CMakeLists.txt6
-rw-r--r--tests/auto/sql/models/qsqlquerymodel/CMakeLists.txt7
-rw-r--r--tests/auto/sql/models/qsqlrelationaldelegate/CMakeLists.txt7
-rw-r--r--tests/auto/sql/models/qsqlrelationaltablemodel/CMakeLists.txt6
-rw-r--r--tests/auto/sql/models/qsqltablemodel/CMakeLists.txt6
-rw-r--r--tests/auto/testlib/CMakeLists.txt4
-rw-r--r--tests/auto/testlib/qabstractitemmodeltester/CMakeLists.txt8
-rw-r--r--tests/auto/testlib/qsignalspy/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/CMakeLists.txt42
-rw-r--r--tests/auto/testlib/selftests/assert/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/badxml/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/benchlibcallgrind/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/benchlibcounting/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/benchlibeventcounter/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/benchliboptions/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/benchlibwalltime/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/commandlinedata/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/counting/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/crashes/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/datatable/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/datetime/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/deleteLater/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/deleteLater_noApp/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/differentexec/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/expectfail/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/failcleanup/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/failinit/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/failinitdata/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/fetchbogus/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/float/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/globaldata/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/longstring/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/maxwarnings/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/multiexec/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/pairdiagnostics/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/printdatatags/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/printdatatagswithglobaltags/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/qexecstringlist/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/singleskip/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/skip/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/skipcleanup/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/skipinit/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/skipinitdata/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/sleep/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/strcmp/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/subtest/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/tuplediagnostics/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/warnings/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/xunit/CMakeLists.txt1
-rw-r--r--tests/auto/tools/qdbusxml2cpp/CMakeLists.txt1
-rw-r--r--tests/auto/tools/uic/CMakeLists.txt1
-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.txt1
-rw-r--r--tests/auto/widgets/dialogs/qdialog/CMakeLists.txt8
-rw-r--r--tests/auto/widgets/dialogs/qerrormessage/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/dialogs/qfiledialog/CMakeLists.txt9
-rw-r--r--tests/auto/widgets/dialogs/qfiledialog2/CMakeLists.txt10
-rw-r--r--tests/auto/widgets/dialogs/qfilesystemmodel/CMakeLists.txt31
-rw-r--r--tests/auto/widgets/dialogs/qfontdialog/CMakeLists.txt9
-rw-r--r--tests/auto/widgets/dialogs/qinputdialog/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/dialogs/qmessagebox/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/dialogs/qprogressdialog/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/dialogs/qsidebar/CMakeLists.txt5
-rw-r--r--tests/auto/widgets/dialogs/qwizard/CMakeLists.txt8
-rw-r--r--tests/auto/widgets/effects/CMakeLists.txt2
-rw-r--r--tests/auto/widgets/effects/qgraphicseffect/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/effects/qpixmapfilter/CMakeLists.txt5
-rw-r--r--tests/auto/widgets/graphicsview/CMakeLists.txt25
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsanchorlayout1/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicseffectsource/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsgridlayout/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsitem/CMakeLists.txt11
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsitemanimation/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicslayout/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicslayoutitem/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsobject/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicspixmapitem/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicspolygonitem/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsproxywidget/CMakeLists.txt10
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsscene/CMakeLists.txt15
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicssceneindex/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicstransform/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsview/CMakeLists.txt12
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicswidget/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/itemviews/CMakeLists.txt21
-rw-r--r--tests/auto/widgets/itemviews/qabstractitemview/CMakeLists.txt5
-rw-r--r--tests/auto/widgets/itemviews/qcolumnview/CMakeLists.txt11
-rw-r--r--tests/auto/widgets/itemviews/qdatawidgetmapper/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/itemviews/qdirmodel/CMakeLists.txt19
-rw-r--r--tests/auto/widgets/itemviews/qfileiconprovider/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/itemviews/qheaderview/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/itemviews/qitemdelegate/CMakeLists.txt3
-rw-r--r--tests/auto/widgets/itemviews/qitemeditorfactory/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/itemviews/qitemview/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/itemviews/qlistview/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/itemviews/qlistwidget/CMakeLists.txt8
-rw-r--r--tests/auto/widgets/itemviews/qtableview/CMakeLists.txt7
-rw-r--r--tests/auto/widgets/itemviews/qtablewidget/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/itemviews/qtreeview/CMakeLists.txt11
-rw-r--r--tests/auto/widgets/itemviews/qtreewidget/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/itemviews/qtreewidgetitemiterator/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/kernel/CMakeLists.txt27
-rw-r--r--tests/auto/widgets/kernel/kernel.pro2
-rw-r--r--tests/auto/widgets/kernel/qaction/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/kernel/qactiongroup/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/kernel/qboxlayout/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/kernel/qdesktopwidget/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/kernel/qformlayout/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/kernel/qgesturerecognizer/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/kernel/qgridlayout/CMakeLists.txt10
-rw-r--r--tests/auto/widgets/kernel/qlayout/CMakeLists.txt3
-rw-r--r--tests/auto/widgets/kernel/qshortcut/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/kernel/qsizepolicy/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/kernel/qstackedlayout/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/kernel/qtooltip/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/kernel/qwidget/CMakeLists.txt16
-rw-r--r--tests/auto/widgets/kernel/qwidget_window/CMakeLists.txt7
-rw-r--r--tests/auto/widgets/kernel/qwidgetaction/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/kernel/qwidgetmetatype/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/kernel/qwidgetsvariant/CMakeLists.txt8
-rw-r--r--tests/auto/widgets/kernel/qwindowcontainer/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/styles/CMakeLists.txt12
-rw-r--r--tests/auto/widgets/styles/qmacstyle/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/styles/qstyle/CMakeLists.txt3
-rw-r--r--tests/auto/widgets/styles/qstyleoption/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/styles/qstylesheetstyle/CMakeLists.txt9
-rw-r--r--tests/auto/widgets/util/CMakeLists.txt7
-rw-r--r--tests/auto/widgets/util/qcompleter/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/util/qscroller/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/util/qsystemtrayicon/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/util/qundogroup/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/util/qundostack/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/CMakeLists.txt55
-rw-r--r--tests/auto/widgets/widgets/qabstractbutton/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qabstractscrollarea/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qabstractslider/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qabstractspinbox/CMakeLists.txt7
-rw-r--r--tests/auto/widgets/widgets/qbuttongroup/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qcalendarwidget/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qcheckbox/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qcombobox/CMakeLists.txt8
-rw-r--r--tests/auto/widgets/widgets/qcommandlinkbutton/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qdatetimeedit/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/widgets/qdial/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qdialogbuttonbox/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qdockwidget/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/widgets/qdoublespinbox/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qfocusframe/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qfontcombobox/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qframe/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qgroupbox/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qkeysequenceedit/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qlabel/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/widgets/qlcdnumber/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qlineedit/CMakeLists.txt9
-rw-r--r--tests/auto/widgets/widgets/qmainwindow/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qmdiarea/CMakeLists.txt11
-rw-r--r--tests/auto/widgets/widgets/qmdisubwindow/CMakeLists.txt7
-rw-r--r--tests/auto/widgets/widgets/qmenu/CMakeLists.txt13
-rw-r--r--tests/auto/widgets/widgets/qmenubar/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/widgets/qopenglwidget/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/widgets/qplaintextedit/CMakeLists.txt7
-rw-r--r--tests/auto/widgets/widgets/qprogressbar/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qpushbutton/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qradiobutton/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qscrollarea/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qscrollbar/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qsizegrip/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qslider/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qspinbox/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qsplashscreen/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qsplitter/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qstackedwidget/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qstatusbar/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qtabbar/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qtabwidget/CMakeLists.txt3
-rw-r--r--tests/auto/widgets/widgets/qtextbrowser/CMakeLists.txt3
-rw-r--r--tests/auto/widgets/widgets/qtextedit/CMakeLists.txt8
-rw-r--r--tests/auto/widgets/widgets/qtoolbar/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qtoolbox/CMakeLists.txt1
-rw-r--r--tests/auto/widgets/widgets/qtoolbutton/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/io/qdir/10000/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/io/qprocess/test/CMakeLists.txt5
-rw-r--r--tests/benchmarks/corelib/kernel/events/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/kernel/qcoreapplication/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/kernel/qmetatype/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/mimetypes/qmimedatabase/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/plugin/quuid/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/thread/qmutex/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/thread/qthreadpool/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/thread/qthreadstorage/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/thread/qwaitcondition/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/tools/containers-associative/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/tools/containers-sequential/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/tools/qalgorithms/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/tools/qchar/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/tools/qdatetime/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/tools/qlist/CMakeLists.txt1
-rw-r--r--tests/benchmarks/corelib/tools/qlocale/CMakeLists.txt1
-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/gui/image/blendbench/CMakeLists.txt3
-rw-r--r--tests/benchmarks/gui/image/qimagescale/CMakeLists.txt3
-rw-r--r--tests/benchmarks/gui/image/qpixmapcache/CMakeLists.txt3
-rw-r--r--tests/benchmarks/gui/kernel/qguimetatype/CMakeLists.txt3
-rw-r--r--tests/benchmarks/gui/kernel/qguivariant/CMakeLists.txt3
-rw-r--r--tests/benchmarks/gui/math3d/qmatrix4x4/CMakeLists.txt3
-rw-r--r--tests/benchmarks/gui/math3d/qquaternion/CMakeLists.txt3
-rw-r--r--tests/benchmarks/gui/painting/qtransform/CMakeLists.txt3
-rw-r--r--tests/benchmarks/gui/text/qfontmetrics/CMakeLists.txt3
-rw-r--r--tests/manual/CMakeLists.txt92
-rw-r--r--tests/manual/qcursor/childwindow/CMakeLists.txt5
-rw-r--r--tests/manual/qmetatype/CMakeLists.txt5
-rw-r--r--tests/manual/qopenglwindow/multiwindow/CMakeLists.txt3
-rw-r--r--util/cmake/Pipfile15
-rwxr-xr-xutil/cmake/cmakeconversionrate.py127
-rwxr-xr-xutil/cmake/configurejson2cmake.py1039
-rwxr-xr-xutil/cmake/generate_module_map.sh38
-rw-r--r--util/cmake/helper.py272
-rwxr-xr-xutil/cmake/pro2cmake.py1592
-rwxr-xr-xutil/cmake/pro_conversion_rate.py218
-rwxr-xr-xutil/cmake/run_pro2cmake.py96
-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/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/load.pro3
-rw-r--r--util/cmake/tests/data/multiline_assign.pro4
-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
-rwxr-xr-xutil/cmake/tests/test_lc_fixup.py46
-rwxr-xr-xutil/cmake/tests/test_logic_mapping.py186
-rwxr-xr-xutil/cmake/tests/test_operations.py57
-rwxr-xr-xutil/cmake/tests/test_parsing.py307
-rwxr-xr-xutil/cmake/tests/test_scope_handling.py338
946 files changed, 27764 insertions, 298 deletions
diff --git a/.gitignore b/.gitignore
index b9188d84f7..596812c715 100644
--- a/.gitignore
+++ b/.gitignore
@@ -36,6 +36,8 @@
qt*-config.h
qt*-config_p.h
qt*-config.pri
+*.pyc
+.mypy_cache
/include/
@@ -58,11 +60,12 @@ qt*-config.pri
/src/corelib/global/qfloat16tables.cpp
-/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
@@ -323,3 +326,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..b43a662285
--- /dev/null
+++ b/CMakeLists.txt
@@ -0,0 +1,61 @@
+cmake_minimum_required(VERSION 3.14.0)
+
+project(QtBase
+ VERSION 5.12.0
+ DESCRIPTION "Qt Base Libraries"
+ HOMEPAGE_URL "https://qt.io/"
+ LANGUAGES CXX C ASM
+)
+
+## Add some paths to check for cmake modules:
+list(APPEND 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"
+)
+
+## Qt specific setup common for all modules:
+include(QtSetup)
+
+## Enable feature summary at the end of the configure run:
+include(FeatureSummary)
+
+## QtBase specific configure tests:
+include(QtBaseConfigureTests)
+
+## Build System tests:
+include(QtBaseCMakeTesting)
+
+## Targets for global features, etc.:
+include(QtBaseGlobalTargets)
+
+## 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})
+
+## Visit all the directories:
+add_subdirectory(src)
+
+if (BUILD_TESTING)
+ add_subdirectory(tests)
+endif()
+
+if (NOT CMAKE_CROSSCOMPILING)
+ add_subdirectory(qmake)
+endif()
+
+option(BUILD_EXAMPLES "Build Qt examples" ON)
+if (BUILD_EXAMPLES)
+ add_subdirectory(examples)
+endif()
+
+## Delayed actions on some of the Qt targets:
+include(QtPostProcess)
+
+## Print a feature summary:
+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)
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..de271a1140
--- /dev/null
+++ b/cmake/3rdparty/extra-cmake-modules/find-modules/FindEGL.cmake
@@ -0,0 +1,164 @@
+#.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()
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(EGL
+ FOUND_VAR
+ EGL_FOUND
+ REQUIRED_VARS
+ EGL_LIBRARY
+ EGL_INCLUDE_DIR
+ HAVE_EGL
+ VERSION_VAR
+ EGL_VERSION
+)
+
+if(EGL_FOUND AND NOT TARGET EGL::EGL)
+ 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()
+
+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/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/FindATSPI2.cmake b/cmake/FindATSPI2.cmake
new file mode 100644
index 0000000000..4e1ade0d07
--- /dev/null
+++ b/cmake/FindATSPI2.cmake
@@ -0,0 +1,5 @@
+include(FindPkgConfig)
+
+if(NOT TARGET PkgConfig::ATSPI2)
+ pkg_check_modules(ATSPI2 atspi-2 IMPORTED_TARGET)
+endif()
diff --git a/cmake/FindAtomic.cmake b/cmake/FindAtomic.cmake
new file mode 100644
index 0000000000..b4580067ca
--- /dev/null
+++ b/cmake/FindAtomic.cmake
@@ -0,0 +1,37 @@
+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/FindGLESv2.cmake b/cmake/FindGLESv2.cmake
new file mode 100644
index 0000000000..a4af6cbbbc
--- /dev/null
+++ b/cmake/FindGLESv2.cmake
@@ -0,0 +1,40 @@
+include(CheckCXXSourceCompiles)
+
+find_library(GLESv2_LIBRARY NAMES GLESv2)
+find_path(GLESv2_INCLUDE_DIR NAMES "GLES2/gl2.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)
+
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(GLESv2 DEFAULT_MSG GLESv2_INCLUDE_DIR GLESv2_LIBRARY HAVE_GLESv2)
+
+mark_as_advanced(GLESv2_INCLUDE_DIR GLESv2_LIBRARY HAVE_GLESv2)
+
+if(GLESv2_FOUND AND NOT TARGET GLESv2::GLESv2)
+ add_library(GLESv2::GLESv2 UNKNOWN IMPORTED)
+ set_target_properties(GLESv2::GLESv2 PROPERTIES
+ IMPORTED_LOCATION "${GLESv2_LIBRARY}"
+ INTERFACE_INCLUDE_DIRECTORIES "${GLESv2_INCLUDE_DIR}")
+endif()
diff --git a/cmake/FindGTK3.cmake b/cmake/FindGTK3.cmake
new file mode 100644
index 0000000000..f4476c167b
--- /dev/null
+++ b/cmake/FindGTK3.cmake
@@ -0,0 +1,3 @@
+include(FindPkgConfig)
+
+pkg_check_modules(GTK3 "gtk+-3.0 >= 3.6" IMPORTED_TARGET)
diff --git a/cmake/FindLibproxy.cmake b/cmake/FindLibproxy.cmake
new file mode 100644
index 0000000000..611a8bd7d5
--- /dev/null
+++ b/cmake/FindLibproxy.cmake
@@ -0,0 +1,3 @@
+find_package(PkgConfig)
+
+pkg_check_modules(Libproxy libproxy-1.0 IMPORTED_TARGET)
diff --git a/cmake/FindLibsystemd.cmake b/cmake/FindLibsystemd.cmake
new file mode 100644
index 0000000000..9c0082fd39
--- /dev/null
+++ b/cmake/FindLibsystemd.cmake
@@ -0,0 +1,3 @@
+find_package(PkgConfig)
+
+pkg_check_modules(Libsystemd systemd IMPORTED_TARGET)
diff --git a/cmake/FindLibudev.cmake b/cmake/FindLibudev.cmake
new file mode 100644
index 0000000000..7eeb800e09
--- /dev/null
+++ b/cmake/FindLibudev.cmake
@@ -0,0 +1,3 @@
+find_package(PkgConfig)
+
+pkg_check_modules(Libudev libudev IMPORTED_TARGET)
diff --git a/cmake/FindMtdev.cmake b/cmake/FindMtdev.cmake
new file mode 100644
index 0000000000..39d9823207
--- /dev/null
+++ b/cmake/FindMtdev.cmake
@@ -0,0 +1,3 @@
+find_package(PkgConfig)
+
+pkg_check_modules(Mtdev mtdev IMPORTED_TARGET)
diff --git a/cmake/FindPCRE2.cmake b/cmake/FindPCRE2.cmake
new file mode 100644
index 0000000000..7e45c963d7
--- /dev/null
+++ b/cmake/FindPCRE2.cmake
@@ -0,0 +1,13 @@
+
+find_library(PCRE2_LIBRARIES NAMES pcre2-16)
+find_path(PCRE2_INCLUDE_DIRS pcre2.h)
+
+if (PCRE2_LIBRARIES STREQUAL "PCRE2_LIBRARIES-NOTFOUND" OR PCRE2_INCLUDE_DIRS STREQUAL "PCRE2_INCLUDE_DIRS-NOTFOUND")
+ set(PCRE2_FOUND 0)
+else()
+ add_library(PCRE2 INTERFACE)
+ target_link_libraries(PCRE2 INTERFACE ${PCRE2_LIBRARIES})
+ target_include_directories(PCRE2 INTERFACE ${PCRE2_INCLUDE_DIRS})
+ set(PCRE2_FOUND 1)
+endif()
+
diff --git a/cmake/FindPPS.cmake b/cmake/FindPPS.cmake
new file mode 100644
index 0000000000..b1e418f227
--- /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 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..8ff00e4157
--- /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 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..979291a5f6
--- /dev/null
+++ b/cmake/FindTslib.cmake
@@ -0,0 +1,3 @@
+find_package(PkgConfig)
+
+pkg_check_modules(Tslib tslib IMPORTED_TARGET)
diff --git a/cmake/FindWrapDoubleConversion.cmake b/cmake/FindWrapDoubleConversion.cmake
new file mode 100644
index 0000000000..749965a7b8
--- /dev/null
+++ b/cmake/FindWrapDoubleConversion.cmake
@@ -0,0 +1,43 @@
+include(CheckCXXSourceCompiles)
+
+add_library(WrapDoubleConversion INTERFACE)
+
+find_package(double-conversion)
+if (double-conversion_FOUND)
+ set_package_properties(double-conversion PROPERTIES TYPE REQUIRED)
+ target_link_libraries(WrapDoubleConversion INTERFACE double-conversion::double-conversion)
+ set(WrapDoubleConversion_FOUND 1)
+ return()
+endif()
+
+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)
+
+if (HAVE__SPRINTF_L OR HAVE_SPRINTF_L)
+ target_compile_definitions(WrapDoubleConversion INTERFACE QT_NO_DOUBLECONVERSION)
+ set(WrapDoubleConversion_FOUND 1)
+else()
+ set(WrapDoubleConversion_FOUND 0)
+endif()
diff --git a/cmake/FindWrapOpenGL.cmake b/cmake/FindWrapOpenGL.cmake
new file mode 100644
index 0000000000..c97ba0e466
--- /dev/null
+++ b/cmake/FindWrapOpenGL.cmake
@@ -0,0 +1,18 @@
+
+# Logic derived from mkspecs/features/unix/opengl.prf: prefer GLESv2 over GL
+
+if(TARGET WrapOpenGL)
+ set(WrapOpenGL_FOUND ON)
+ return()
+endif()
+
+add_library(WrapOpenGL INTERFACE)
+
+if(QT_FEATURE_opengles2)
+ find_package(GLESv2)
+ target_link_libraries(WrapOpenGL INTERFACE GLESv2::GLESv2)
+else()
+ find_package(OpenGL)
+ target_link_libraries(WrapOpenGL INTERFACE OpenGL::GL)
+endif()
+set(WrapOpenGL_FOUND ON)
diff --git a/cmake/FindWrapRt.cmake b/cmake/FindWrapRt.cmake
new file mode 100644
index 0000000000..dee41e0617
--- /dev/null
+++ b/cmake/FindWrapRt.cmake
@@ -0,0 +1,27 @@
+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)
+if (LIBRT_FOUND)
+ target_link_libraries(WrapRt INTERFACE "${LIBRT}")
+endif()
+
+set(WrapRt_FOUND "${HAVE_GETTIME}")
+
diff --git a/cmake/FindZSTD.cmake b/cmake/FindZSTD.cmake
new file mode 100644
index 0000000000..040e8c1642
--- /dev/null
+++ b/cmake/FindZSTD.cmake
@@ -0,0 +1,49 @@
+#.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
+ 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)
+
+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/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..7a5502bc65
--- /dev/null
+++ b/cmake/QtBaseConfigureTests.cmake
@@ -0,0 +1,149 @@
+include(CheckCXXSourceCompiles)
+
+function(run_config_test_architecture)
+ # Test architecture
+ set(_arch_file "${CMAKE_CURRENT_BINARY_DIR}/architecture_test")
+ try_compile(_arch_result "${CMAKE_CURRENT_BINARY_DIR}"
+ "${CMAKE_CURRENT_SOURCE_DIR}/config.tests/arch/arch.cpp"
+ COPY_FILE "${_arch_file}")
+ if (NOT _arch_result)
+ message(FATAL_ERROR "Failed to compile architecture detection file.")
+ endif()
+
+ file(STRINGS "${_arch_file}" _arch_lines LENGTH_MINIMUM 16 LENGTH_MAXIMUM 1024 ENCODING UTF-8)
+
+ foreach (_line ${_arch_lines})
+ 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)
+ 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 _sub_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")
+ 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")
+ endforeach()
+ set(TEST_buildAbi "${_build_abi}" CACHE INTERNAL "Target machine buildAbi")
+endfunction()
+
+
+function(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(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(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(run_config_tests)
+ 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)
+ run_config_test_sun_iconv()
+ endif()
+ run_config_test_architecture()
+ run_linker_version_script_support()
+endfunction()
+
+run_config_tests()
diff --git a/cmake/QtBaseGlobalTargets.cmake b/cmake/QtBaseGlobalTargets.cmake
new file mode 100644
index 0000000000..73deb51b49
--- /dev/null
+++ b/cmake/QtBaseGlobalTargets.cmake
@@ -0,0 +1,79 @@
+## 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})
+set(config_install_dir "${INSTALL_LIBDIR}/cmake/${INSTALL_CMAKE_NAMESPACE}")
+
+configure_package_config_file(
+ "${PROJECT_SOURCE_DIR}/cmake/QtConfig.cmake.in"
+ "${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CMAKE_NAMESPACE}Config.cmake"
+ INSTALL_DESTINATION "${config_install_dir}"
+)
+write_basic_package_version_file(
+ ${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CMAKE_NAMESPACE}ConfigVersion.cmake
+ VERSION ${PROJECT_VERSION}
+ COMPATIBILITY AnyNewerVersion
+)
+install(FILES
+ "${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CMAKE_NAMESPACE}Config.cmake"
+ "${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CMAKE_NAMESPACE}ConfigVersion.cmake"
+ DESTINATION "${config_install_dir}"
+ COMPONENT Devel
+)
+
+
+## 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(LIBRARY Core
+ 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)
+
+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)
+
+install(TARGETS Platform GlobalConfig GlobalConfigPrivate EXPORT "${INSTALL_CMAKE_NAMESPACE}Targets")
+install(EXPORT "${INSTALL_CMAKE_NAMESPACE}Targets" NAMESPACE ${INSTALL_CMAKE_EXPORT_NAMESPACE}:: DESTINATION "${config_install_dir}")
+
+## Install some QtBase specific CMake files:
+install(FILES
+ cmake/QtBuild.cmake
+ cmake/QtCompilerFlags.cmake
+ cmake/QtCompilerOptimization.cmake
+ cmake/QtFeature.cmake
+ cmake/QtPlatformSupport.cmake
+ cmake/QtPostProcess.cmake
+ cmake/QtSetup.cmake
+ cmake/QtModuleConfig.cmake.in
+ DESTINATION "${config_install_dir}"
+)
+# TODO: Check whether this is the right place to install these
+install(DIRECTORY cmake/3rdparty
+ DESTINATION "${config_install_dir}"
+)
diff --git a/cmake/QtBuild.cmake b/cmake/QtBuild.cmake
new file mode 100644
index 0000000000..84769a4eb8
--- /dev/null
+++ b/cmake/QtBuild.cmake
@@ -0,0 +1,1202 @@
+include(CMakePackageConfigHelpers)
+
+# Install locations:
+set(INSTALL_BINDIR "bin" CACHE PATH "Executables [PREFIX/bin]")
+set(INSTALL_INCLUDEDIR "include" CACHE PATH "Header files [PREFIX/include]")
+set(INSTALL_LIBDIR "lib" CACHE PATH "Libraries [PREFIX/lib]")
+set(INSTALL_ARCHDATADIR "." CACHE PATH "Arch-dependent data [PREFIX]")
+set(INSTALL_PLUGINSDIR "${INSTALL_ARCHDATADIR}/plugins" CACHE PATH
+ "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 PATH
+ "Helper programs [ARCHDATADIR/bin on Windows, ARCHDATADIR/libexec otherwise]")
+set(INSTALL_IMPORTDIR "${INSTALL_ARCHDATADIR}/imports" CACHE PATH
+ "QML1 imports [ARCHDATADIR/imports]")
+set(INSTALL_QMLDIR "${INSTALL_ARCHDATADIR}/qml" CACHE PATH
+ "QML2 imports [ARCHDATADIR/qml]")
+set(INSTALL_DATADIR "." CACHE PATH "Arch-independent data [PREFIX]")
+set(INSTALL_DOCDIR "${INSTALL_DATADIR}/doc" CACHE PATH "Documentation [DATADIR/doc]")
+set(INSTALL_TRANSLATIONSDIR "${INSTALL_DATADIR}/translations" CACHE PATH
+ "Translations [DATADIR/translations]")
+set(INSTALL_SYSCONFDIR "etc/xdg" CACHE PATH
+ "Settings used by Qt programs [PREFIX/etc/xdg]")
+set(INSTALL_EXAMPLESDIR "examples" CACHE PATH "Examples [PREFIX/examples]")
+set(INSTALL_TESTSDIR "tests" CACHE PATH "Tests [PREFIX/tests]")
+
+set(INSTALL_CMAKE_NAMESPACE "Qt${PROJECT_VERSION_MAJOR}" CACHE STRING "CMake namespace [Qt${PROJECT_VERSION_MAJOR}]")
+
+set(QT_CMAKE_EXPORT_NAMESPACE "Qt${PROJECT_VERSION_MAJOR}" CACHE STRING "CMake namespace used when exporting targets [Qt${PROJECT_VERSION_MAJOR}]")
+set(QT_CMAKE_DIR "${CMAKE_CURRENT_LIST_DIR}")
+
+# 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)
+
+# Platform define path, etc.
+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_DEFAULT_PLATFORM_DEFINITION_DIR mkspecs/win32-msvc)
+ elseif(CLANG)
+ set(QT_DEFAULT_PLATFORM_DEFINITION_DIR mkspecs/win32-clang)
+ endif()
+elseif(LINUX)
+ if(GCC)
+ set(QT_DEFAULT_PLATFORM_DEFINITION_DIR mkspecs/linux-g++)
+ elseif(CLANG)
+ set(QT_DEFAULT_PLATFORM_DEFINITION_DIR mkspecs/linux-clang)
+ endif()
+elseif(APPLE)
+ set(QT_DEFAULT_PLATFORM_DEFINITION_DIR mkspecs/macx-clang)
+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()
+
+macro(qt_internal_set_known_qt_modules)
+ set(KNOWN_QT_MODULES ${ARGN} CACHE INTERNAL "Known Qt modules" FORCE)
+endmacro()
+
+# Reset:
+qt_internal_set_known_qt_modules("")
+
+# 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()
+
+
+# Functions and macros:
+
+# 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)
+ 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()
+
+ set(nolink_target "${target}_nolink")
+ if(NOT TARGET "${nolink_target}")
+ add_library("${nolink_target}" INTERFACE IMPORTED)
+ 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>)
+ 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()
+
+ get_target_property(mocPath "${QT_CMAKE_EXPORT_NAMESPACE}::moc" LOCATION)
+ get_filename_component(binDirectory "${mocPath}" DIRECTORY)
+ # We could put this into the cache, but on the other hand there's no real need to
+ # pollute the app's cache with this. For the first qtbase build, the variable is
+ # set in global scope.
+ set(QT_SYNCQT "${binDirectory}/syncqt.pl" CACHE FILEPATH "syncqt script")
+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()
+
+
+function(qt_internal_add_link_flags_no_undefined target)
+ if (GCC OR CLANG)
+ if(APPLE)
+ set(no_undefined_flag "-Wl,-undefined,error")
+ elseif(LINUX)
+ set(no_undefined_flag "-Wl,--no-undefined")
+ else()
+ 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)
+ if(APPLE)
+ set(gc_sections_flag "-Wl,-dead_strip")
+ elseif(LINUX OR BSD OR SOLARIS OR WIN32)
+ 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}" "${PROJECT_SOURCE_DIR}/mkspecs/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 "Qt5Core" (based on major Qt version)
+# * foo_upper with the value "CORE"
+# * foo_lower with the value "core"
+# * foo_include_dir with the module's include directory in the binary tree
+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)
+ set("${result}_upper" "${upper}" PARENT_SCOPE)
+ set("${result}_lower" "${lower}" PARENT_SCOPE)
+ set("${result}_include_dir" "${PROJECT_BINARY_DIR}/include/${module}" 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")
+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)
+
+# This function checks which autotools should be used: AUTOMOC/UIC/RCC
+function(qt_autogen_tools target)
+ qt_parse_all_arguments(arg "qt_autogen_tools" "" "" "${__default_private_args}" ${ARGN})
+
+ set_property(TARGET "${target}" PROPERTY INTERFACE_QT_MAJOR_VERSION ${PROJECT_VERSION_MAJOR})
+ set_property(TARGET "${target}" APPEND PROPERTY
+ COMPATIBLE_INTERFACE_STRING QT_MAJOR_VERSION
+ )
+
+ list(APPEND autogen_tools "moc" "uic" "rcc")
+ if (arg_DISABLE_AUTOGEN_TOOLS)
+ foreach(disable_tool ${arg_DISABLE_AUTOGEN_TOOLS})
+ list(REMOVE_ITEM autogen_tools "${disable_tool}")
+ endforeach()
+ endif()
+
+ foreach(autogen_tool ${autogen_tools})
+ string(TOUPPER "${autogen_tool}" captitalAutogenTool)
+
+ set_target_properties("${target}"
+ PROPERTIES
+ AUTO${captitalAutogenTool} ON
+ AUTO${captitalAutogenTool}_EXECUTABLE "$<TARGET_FILE:Qt::${autogen_tool}>")
+ set_property(TARGET ${target} APPEND PROPERTY AUTOGEN_TARGET_DEPENDS Qt::${autogen_tool})
+ endforeach()
+
+ set_directory_properties(PROPERTIES
+ QT_VERSION_MAJOR ${PROJECT_VERSION_MAJOR}
+ QT_VERSION_MINOR ${PROJECT_VERSION_MINOR})
+endfunction()
+
+# This function can be used to add sources/libraries/etc. to the specified CMake target
+# if the provided CONDITION evaluates to true.
+function(extend_target target)
+ if (NOT TARGET "${target}")
+ message(FATAL_ERROR "Trying to extend non-existing target \"${target}\".")
+ endif()
+ qt_parse_all_arguments(arg "extend_target" "" ""
+ "CONDITION;${__default_public_args};${__default_private_args};COMPILE_FLAGS" ${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("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()
+
+ foreach(lib ${arg_PUBLIC_LIBRARIES} ${arg_LIBRARIES})
+ string(REGEX REPLACE "_nolink$" "" base_lib "${lib}")
+ if(NOT base_lib STREQUAL lib)
+ qt_create_nolink_target("${base_lib}")
+ endif()
+ endforeach()
+
+ 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()
+ target_include_directories("${target}" PUBLIC ${arg_PUBLIC_INCLUDE_DIRECTORIES} PRIVATE ${arg_INCLUDE_DIRECTORIES})
+ target_compile_definitions("${target}" PUBLIC ${arg_PUBLIC_DEFINES} PRIVATE ${arg_DEFINES})
+ target_link_libraries("${target}" PUBLIC ${arg_PUBLIC_LIBRARIES} PRIVATE ${arg_LIBRARIES})
+ target_compile_options("${target}" PUBLIC ${arg_PUBLIC_COMPILE_OPTIONS} PRIVATE ${arg_COMPILE_OPTIONS})
+ target_link_options("${target}" PUBLIC ${arg_PUBLIC_LINK_OPTIONS} PRIVATE ${arg_LINK_OPTIONS})
+ set_target_properties("${target}" PROPERTIES AUTOMOC_MOC_OPTIONS "${arg_MOC_OPTIONS}")
+ else()
+ if(QT_CMAKE_DEBUG_EXTEND_TARGET)
+ message("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
+ set("${result}" "QT_DISABLE_DEPRECATED_BEFORE=0x040800" PARENT_SCOPE)
+ else()
+ # On other platforms, Qt's own compilation goes needs to compile the Qt 5.0 API
+ set("${result}" "QT_DISABLE_DEPRECATED_BEFORE=0x050000" PARENT_SCOPE)
+ endif()
+endfunction()
+
+
+function(qt_install_injections module)
+ set(injections ${ARGN})
+ # 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
+ separate_arguments(injections UNIX_COMMAND "${injections}")
+ foreach(injection ${injections})
+ string(REPLACE ":" ";" injection ${injection})
+ list(GET injection 0 file)
+ list(GET injection 1 destination)
+ string(REGEX REPLACE "^\\^" "" destination "${destination}")
+ list(REMOVE_AT injection 0 1)
+ set(fwd_hdrs ${injection})
+ get_filename_component(destinationdir ${destination} DIRECTORY)
+ get_filename_component(destinationname ${destination} NAME)
+ install(FILES ${PROJECT_BINARY_DIR}/${file} DESTINATION ${INSTALL_INCLUDEDIR}/${module}/${destinationdir} RENAME ${destinationname} OPTIONAL)
+ foreach(fwd_hdr ${fwd_hdrs})
+ file(GENERATE OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/${fwd_hdr}" CONTENT "#include \"${destinationname}\"\n")
+ install(FILES "${CMAKE_CURRENT_BINARY_DIR}/${fwd_hdr}" DESTINATION ${INSTALL_INCLUDEDIR}/${module}/${destinationdir} OPTIONAL)
+ 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()
+
+
+# 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(add_qt_module target)
+ qt_internal_module_info(module "${target}")
+
+ # Process arguments:
+ qt_parse_all_arguments(arg "add_qt_module" "NO_MODULE_HEADERS;STATIC" "CONFIG_MODULE_NAME"
+ "${__default_private_args};${__default_public_args}" ${ARGN})
+
+ if(NOT DEFINED arg_CONFIG_MODULE_NAME)
+ set(arg_CONFIG_MODULE_NAME "${module_lower}")
+ endif()
+
+ qt_internal_set_known_qt_modules("${KNOWN_QT_MODULES}" "${target}")
+
+ ### Define Targets:
+ if(${arg_STATIC})
+ add_library("${target}" STATIC)
+ elseif(${QT_BUILD_SHARED_LIBS})
+ add_library("${target}" SHARED)
+ else()
+ add_library("${target}" STATIC)
+ endif()
+ qt_internal_add_target_aliases("${target}")
+
+ # Add _private target to link against the private headers:
+ set(target_private "${target}Private")
+ add_library("${target_private}" INTERFACE)
+ qt_internal_add_target_aliases("${target_private}")
+
+ # Module headers:
+ if(${arg_NO_MODULE_HEADERS})
+ set_target_properties("${target}" PROPERTIES MODULE_HAS_HEADERS OFF)
+ else()
+ qt_ensure_sync_qt()
+ execute_process(COMMAND "${HOST_PERL}" -w "${QT_SYNCQT}" -quiet -module "${module}" -version "${PROJECT_VERSION}" -outdir "${PROJECT_BINARY_DIR}" "${PROJECT_SOURCE_DIR}")
+
+ set_target_properties("${target}" PROPERTIES MODULE_HAS_HEADERS ON)
+
+ ### FIXME: Can we replace headers.pri?
+ qt_read_headers_pri("${target}" "module_headers")
+ set_property(TARGET "${target}" APPEND PROPERTY PUBLIC_HEADER "${module_headers_public}")
+ set_property(TARGET "${target}" APPEND PROPERTY PUBLIC_HEADER "${module_include_dir}/${module}Depends")
+ set_property(TARGET "${target}" APPEND PROPERTY PRIVATE_HEADER "${module_headers_private}")
+ qt_install_injections("${module}" ${module_headers_injections})
+ endif()
+
+ set_target_properties("${target}" PROPERTIES
+ LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/${INSTALL_LIBDIR}"
+ RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/${INSTALL_BINDIR}"
+ VERSION ${PROJECT_VERSION}
+ SOVERSION ${PROJECT_VERSION_MAJOR}
+ OUTPUT_NAME "${INSTALL_CMAKE_NAMESPACE}${target}")
+
+ qt_internal_library_deprecation_level(deprecation_define)
+
+ qt_autogen_tools("${target}"
+ DISABLE_AUTOGEN_TOOLS ${arg_DISABLE_AUTOGEN_TOOLS}
+ )
+
+ extend_target("${target}"
+ SOURCES ${arg_SOURCES}
+ PUBLIC_INCLUDE_DIRECTORIES
+ $<BUILD_INTERFACE:${module_include_dir}>
+ $<INSTALL_INTERFACE:include/${module}>
+ ${arg_PUBLIC_INCLUDE_DIRECTORIES}
+ INCLUDE_DIRECTORIES
+ "${CMAKE_CURRENT_SOURCE_DIR}"
+ "${CMAKE_CURRENT_BINARY_DIR}"
+ $<BUILD_INTERFACE:${PROJECT_BINARY_DIR}/include>
+ "${module_include_dir}/${PROJECT_VERSION}"
+ "${module_include_dir}/${PROJECT_VERSION}/${module}"
+ ${arg_INCLUDE_DIRECTORIES}
+ PUBLIC_DEFINES
+ ${arg_PUBLIC_DEFINES}
+ QT_${module_upper}_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_upper}_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}
+ 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}
+ )
+
+ 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(DEFINED module_headers_private)
+ qt_internal_add_linker_version_script("${target}" PRIVATE_HEADERS ${module_headers_private})
+ else()
+ qt_internal_add_linker_version_script("${target}")
+ endif()
+
+ install(TARGETS "${target}" "${target_private}" EXPORT "${INSTALL_CMAKE_NAMESPACE}${target}Targets"
+ LIBRARY DESTINATION ${INSTALL_LIBDIR}
+ ARCHIVE DESTINATION ${INSTALL_LIBDIR}
+ PUBLIC_HEADER DESTINATION ${INSTALL_INCLUDEDIR}/${module}
+ PRIVATE_HEADER DESTINATION ${INSTALL_INCLUDEDIR}/${module}/${PROJECT_VERSION}/${module}/private
+ )
+
+ set(config_install_dir "${INSTALL_LIBDIR}/cmake/${INSTALL_CMAKE_NAMESPACE}${target}")
+ install(EXPORT "${INSTALL_CMAKE_NAMESPACE}${target}Targets" NAMESPACE ${QT_CMAKE_EXPORT_NAMESPACE}:: DESTINATION ${config_install_dir})
+
+ 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"
+ "${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CMAKE_NAMESPACE}${target}ConfigExtras.cmake"
+ @ONLY)
+ list(APPEND extra_cmake_files "${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CMAKE_NAMESPACE}${target}ConfigExtras.cmake")
+ list(APPEND extra_cmake_includes "${INSTALL_CMAKE_NAMESPACE}${target}ConfigExtras.cmake")
+ endif()
+
+ ### 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}")
+
+ # When a public module depends on private, also make its private depend on the other's private
+ set(qt_libs_private "")
+ foreach(it ${KNOWN_QT_MODULES})
+ list(FIND arg_LIBRARIES "Qt::${it}Private" pos)
+ if(pos GREATER -1)
+ list(APPEND qt_libs_private "Qt::${it}Private")
+ endif()
+ endforeach()
+
+ target_link_libraries("${target_private}" INTERFACE "${target}" "${qt_libs_private}")
+ target_include_directories("${target_private}" INTERFACE
+ $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>
+ $<BUILD_INTERFACE:${module_include_dir}/${PROJECT_VERSION}>
+ $<BUILD_INTERFACE:${module_include_dir}/${PROJECT_VERSION}/${module}>
+ $<INSTALL_INTERFACE:include/${module}/${PROJECT_VERSION}>
+ $<INSTALL_INTERFACE:include/${module}/${PROJECT_VERSION}/${module}>
+ )
+
+ set(target_deps)
+ foreach(lib IN LISTS arg_PUBLIC_LIBRARIES qt_libs_private)
+ if ("${lib}" MATCHES "^Qt::(.*)")
+ set(lib "${CMAKE_MATCH_1}")
+ if (lib STREQUAL Platform OR lib STREQUAL GlobalConfig)
+ list(APPEND target_deps "Qt5\;${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()
+
+ configure_package_config_file(
+ "${QT_CMAKE_DIR}/QtModuleConfig.cmake.in"
+ "${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CMAKE_NAMESPACE}${target}Config.cmake"
+ INSTALL_DESTINATION "${config_install_dir}"
+ )
+ write_basic_package_version_file(
+ ${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CMAKE_NAMESPACE}${target}ConfigVersion.cmake
+ VERSION ${PROJECT_VERSION}
+ COMPATIBILITY AnyNewerVersion
+ )
+
+ install(FILES
+ "${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CMAKE_NAMESPACE}${target}Config.cmake"
+ "${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CMAKE_NAMESPACE}${target}ConfigVersion.cmake"
+ ${extra_cmake_files}
+ DESTINATION "${config_install_dir}"
+ COMPONENT Devel
+ )
+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 "add_qt_plugin called without setting either TYPE or ${name}.")
+ endif()
+ set(${result_var} "${default}" PARENT_SCOPE)
+ else()
+ set(${result_var} "${dir}" PARENT_SCOPE)
+ endif()
+endfunction()
+
+
+# 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(add_qt_plugin target)
+ qt_internal_module_info(module "${target}")
+
+ qt_parse_all_arguments(arg "add_qt_plugin" "STATIC"
+ "TYPE;OUTPUT_DIRECTORY;INSTALL_DIRECTORY;ARCHIVE_INSTALL_DIRECTORY"
+ "${__default_private_args};${__default_public_args}" ${ARGN})
+
+ qt_internal_check_directory_or_type(OUTPUT_DIRECTORY "${arg_OUTPUT_DIRECTORY}" "${arg_TYPE}"
+ "${CMAKE_BINARY_DIR}/${INSTALL_PLUGINSDIR}/${arg_TYPE}" output_directory)
+ qt_internal_check_directory_or_type(INSTALL_DIRECTORY "${arg_INSTALL_DIRECTORY}" "${arg_TYPE}"
+ "${INSTALL_PLUGINSDIR}/${arg_TYPE}" install_directory)
+ qt_internal_check_directory_or_type(ARCHIVE_INSTALL_DIRECTORY
+ "${arg_ARCHIVE_INSTALL_DIRECTORY}" "${arg_TYPE}"
+ "${INSTALL_LIBDIR}/${arg_TYPE}" archive_install_directory)
+
+ if(arg_STATIC)
+ add_library("${target}" STATIC)
+ else()
+ add_library("${target}")
+ endif()
+ qt_internal_add_target_aliases("${target}")
+
+ set_target_properties("${target}" PROPERTIES
+ LIBRARY_OUTPUT_DIRECTORY "${output_directory}"
+ RUNTIME_OUTPUT_DIRECTORY "${output_directory}"
+ ARCHIVE_OUTPUT_DIRECTORY "${output_directory}")
+
+ qt_internal_library_deprecation_level(deprecation_define)
+
+ qt_autogen_tools("${target}"
+ DISABLE_AUTOGEN_TOOLS ${arg_DISABLE_AUTOGEN_TOOLS}
+ )
+
+ set(static_plugin_define "")
+ if (arg_STATIC OR NOT QT_BUILD_SHARED_LIBS)
+ set(static_plugin_define "QT_STATICPLUGIN")
+ endif()
+
+ extend_target("${target}"
+ SOURCES ${arg_SOURCES}
+ INCLUDE_DIRECTORIES
+ "${CMAKE_CURRENT_SOURCE_DIR}"
+ "${CMAKE_CURRENT_BINARY_DIR}"
+ ${arg_INCLUDE_DIRECTORIES}
+ PUBLIC_INCLUDE_DIRECTORIES ${arg_PUBLIC_INCLUDE_DIRECTORIES}
+ LIBRARIES ${arg_LIBRARIES}
+ PUBLIC_LIBRARIES ${arg_PUBLIC_LIBRARIES}
+ 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_upper}_LIB ### FIXME: use QT_BUILD_ADDON for Add-ons or remove if we don't have add-ons anymore
+ "${deprecation_define}"
+ "${static_plugin_define}"
+ QT_PLUGIN
+ PUBLIC_DEFINES
+ QT_${module_upper}_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}
+ )
+
+ install(TARGETS "${target}" EXPORT "${target}Targets"
+ LIBRARY DESTINATION "${install_directory}"
+ ARCHIVE DESTINATION "${archive_install_directory}")
+ install(EXPORT "${target}Targets" NAMESPACE ${QT_CMAKE_EXPORT_NAMESPACE}:: DESTINATION ${INSTALL_LIBDIR}/cmake)
+
+ ### 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}")
+
+ qt_internal_add_linker_version_script(${target})
+endfunction()
+
+
+# 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 add_qt_test or add_qt_tool below.
+function(add_qt_executable name)
+ qt_parse_all_arguments(arg "add_qt_executable" "GUI;BOOTSTRAP;NO_INSTALL" "OUTPUT_DIRECTORY;INSTALL_DIRECTORY" "EXE_FLAGS;${__default_private_args}" ${ARGN})
+
+ if ("x${arg_OUTPUT_DIRECTORY}" STREQUAL "x")
+ set(arg_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/${INSTALL_BINDIR}")
+ endif()
+
+ get_filename_component(arg_OUTPUT_DIRECTORY "${arg_OUTPUT_DIRECTORY}"
+ ABSOLUTE BASE_DIR "${CMAKE_BINARY_DIR}")
+
+ if ("x${arg_INSTALL_DIRECTORY}" STREQUAL "x")
+ set(arg_INSTALL_DIRECTORY "${INSTALL_BINDIR}")
+ endif()
+
+ add_executable("${name}" ${arg_EXE_FLAGS})
+
+ qt_autogen_tools("${name}"
+ DISABLE_AUTOGEN_TOOLS ${arg_DISABLE_AUTOGEN_TOOLS}
+ )
+
+ set(extra_libraries "")
+ if(NOT arg_BOOTSTRAP)
+ set(extra_libraries "Qt::Core")
+ endif()
+
+ extend_target("${name}"
+ SOURCES ${arg_SOURCES}
+ INCLUDE_DIRECTORIES
+ "${CMAKE_CURRENT_SOURCE_DIR}"
+ "${CMAKE_CURRENT_BINARY_DIR}"
+ ${arg_INCLUDE_DIRECTORIES}
+ DEFINES ${arg_DEFINES}
+ LIBRARIES ${arg_LIBRARIES} ${extra_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}
+ )
+ set_target_properties("${name}" PROPERTIES
+ RUNTIME_OUTPUT_DIRECTORY "${arg_OUTPUT_DIRECTORY}"
+ WIN32_EXECUTABLE "${arg_GUI}"
+ MACOSX_BUNDLE "${arg_GUI}"
+ )
+
+ if(NOT arg_NO_INSTALL)
+ install(TARGETS "${name}"
+ RUNTIME DESTINATION "${arg_INSTALL_DIRECTORY}"
+ BUNDLE DESTINATION "${arg_INSTALL_DIRECTORY}")
+ endif()
+endfunction()
+
+
+# This function creates a CMake test target with the specified name for use with CTest.
+function(add_qt_test name)
+ qt_parse_all_arguments(arg "add_qt_test" "RUN_SERIAL" "" "${__default_private_args}" ${ARGN})
+ set(path "${CMAKE_CURRENT_BINARY_DIR}")
+
+ add_qt_executable("${name}"
+ NO_INSTALL
+ OUTPUT_DIRECTORY "${path}"
+ SOURCES "${arg_SOURCES}"
+ INCLUDE_DIRECTORIES
+ "${CMAKE_CURRENT_SOURCE_DIR}"
+ "${CMAKE_CURRENT_BINARY_DIR}"
+ "${arg_INCLUDE_DIRECTORIES}"
+ DEFINES "${arg_DEFINES}"
+ LIBRARIES ${QT_CMAKE_EXPORT_NAMESPACE}::Core ${QT_CMAKE_EXPORT_NAMESPACE}::Test ${arg_LIBRARIES}
+ COMPILE_OPTIONS ${arg_COMPILE_OPTIONS}
+ LINK_OPTIONS ${arg_LINK_OPTIONS}
+ MOC_OPTIONS ${arg_MOC_OPTIONS}
+ DISABLE_AUTOGEN_TOOLS ${arg_DISABLE_AUTOGEN_TOOLS}
+ )
+
+ add_test(NAME "${name}" COMMAND "${name}" WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}")
+
+ set_tests_properties("${name}" PROPERTIES RUN_SERIAL "${arg_RUN_SERIAL}")
+ set_property(TEST "${name}" APPEND PROPERTY ENVIRONMENT "PATH=${path}${QT_PATH_SEPARATOR}${CMAKE_CURRENT_BINARY_DIR}${QT_PATH_SEPARATOR}$ENV{PATH}")
+ set_property(TEST "${name}" APPEND PROPERTY ENVIRONMENT "QT_PLUGIN_PATH=${PROJECT_BINARY_DIR}/${INSTALL_PLUGINSDIR}")
+endfunction()
+
+
+# This function creates an executable for use as helper program with tests. Some
+# tests launch separate programs to test certainly input/output behavior.
+function(add_qt_test_helper name)
+ add_qt_executable("${name}" NO_INSTALL OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/.." ${ARGN})
+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(add_qt_tool name)
+ set01(_build_tools "x${HOST_QT_TOOLS_DIRECTORY}" STREQUAL "x")
+ if (NOT _build_tools)
+ message("Searching for ${name}.")
+ find_program("_PROG_${name}" "${name}" PATHS "${HOST_QT_TOOLS_DIRECTORY}" NO_DEFAULT_PATH)
+ if (_PROG_${name} STREQUAL "_PROG_${name}-NOTFOUND")
+ message(FATAL_ERROR "The name \"${name}\" was not found in the "
+ "HOST_QT_TOOLS_DIRECTORY (\"${HOST_QT_TOOLS_DIRECTORY}\").")
+ else()
+ message(STATUS "${name} was found at ${_PROG_${name}}.")
+ add_executable("${name}" IMPORTED GLOBAL)
+ set_target_properties("${name}" PROPERTIES IMPORTED_LOCATION "${_PROG_${name}}")
+ qt_internal_add_target_aliases("${name}")
+ endif()
+ return()
+ endif()
+
+ qt_parse_all_arguments(arg "add_qt_tool" "BOOTSTRAP;NO_INSTALL" "" "${__default_private_args}" ${ARGN})
+
+ set(disable_autogen_tools "${arg_DISABLE_AUTOGEN_TOOLS}")
+ 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()
+
+ set(bootstrap "")
+ if(arg_BOOTSTRAP)
+ set(bootstrap BOOTSTRAP)
+ endif()
+
+ set(no_install "")
+ if(arg_NO_INSTALL)
+ set(no_install NO_INSTALL)
+ endif()
+
+ add_qt_executable("${name}" OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/${INSTALL_BINDIR}"
+ ${bootstrap}
+ ${no_install}
+ SOURCES ${arg_SOURCES}
+ INCLUDE_DIRECTORIES
+ ${arg_INCLUDE_DIRECTORIES}
+ DEFINES ${arg_DEFINES}
+ LIBRARIES ${corelib} ${arg_LIBRARIES}
+ 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}")
+
+ if(NOT arg_NO_INSTALL)
+ install(TARGETS "${name}" EXPORT "Qt${PROJECT_VERSION_MAJOR}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()
+
+
+
+function(add_qt_resource target resourceName)
+ qt_parse_all_arguments(rcc "add_qt_resource" "" "PREFIX;LANG;BASE" "FILES" ${ARGN})
+
+ # 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")
+
+ foreach(file ${rcc_FILES})
+ if(rcc_BASE)
+ set(based_file "${rcc_BASE}/${file}")
+ else()
+ set(based_file "${file}")
+ endif()
+ get_property(alias SOURCE ${based_file} PROPERTY alias)
+ if (NOT alias)
+ set(alias "${file}")
+ endif()
+ ### FIXME: escape file paths to be XML conform
+ # <file ...>...</file>
+ string(APPEND qrcContents " <file alias=\"${alias}\">")
+ string(APPEND qrcContents "${CMAKE_CURRENT_SOURCE_DIR}/${based_file}</file>\n")
+ endforeach()
+
+ # </qresource></RCC>
+ string(APPEND qrcContents " </qresource>\n</RCC>\n")
+
+ set(generatedResourceFile "${CMAKE_CURRENT_BINARY_DIR}/${resourceName}.qrc")
+ file(GENERATE OUTPUT "${generatedResourceFile}" CONTENT "${qrcContents}")
+
+ # Process .qrc file:
+
+ set(generatedSourceCode "${CMAKE_CURRENT_BINARY_DIR}/qrc_${resourceName}.cpp")
+ add_custom_command(OUTPUT "${generatedSourceCode}"
+ COMMAND "${QT_CMAKE_EXPORT_NAMESPACE}::rcc"
+ ARGS --name "${resourceName}"
+ --output "${generatedSourceCode}" "${generatedResourceFile}"
+ DEPENDS ${files}
+ COMMENT "RCC ${resourceName}"
+ VERBATIM)
+ target_sources(${target} PRIVATE "${generatedSourceCode}")
+endfunction()
+
+
+# Handle files that need special SIMD-related flags.
+# This creates an object library and makes target link
+# to it (privately).
+function(add_qt_simd_part target)
+ qt_parse_all_arguments(arg "add_qt_simd_part" "" ""
+ "NAME;SIMD;${__default_private_args};COMPILE_FLAGS" ${ARGN})
+ if ("x${arg_SIMD}" STREQUAL x)
+ message(FATAL_ERROR "add_qt_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("add_qt_simd_part(${target} SIMD ${arg_SIMD} ...): Evaluated")
+ endif()
+ string(TOUPPER "QT_CFLAGS_${arg_SIMD}" simd_flags)
+
+ add_library("${name}" OBJECT)
+ 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}")
+ else()
+ if(QT_CMAKE_DEBUG_EXTEND_TARGET)
+ message("add_qt_simd_part(${target} SIMD ${arg_SIMD} ...): Skipped")
+ endif()
+ endif()
+endfunction()
+
+# From Qt5CoreMacros
+# 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()
+
+
+ set(header_file "${CMAKE_CURRENT_BINARY_DIR}/${file_name}.h")
+ set(source_file "${CMAKE_CURRENT_BINARY_DIR}/${file_name}.cpp")
+
+ add_custom_command(OUTPUT "${header_file}" "${source_file}"
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::qdbusxml2cpp ${arg_FLAGS} "${option}" "${header_file}:${source_file}" "${infile}"
+ DEPENDS "${infile}"
+ WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}"
+ VERBATIM)
+
+ target_sources("${target}" PRIVATE "${header_file}" "${source_file}")
+endfunction()
+
+
+function(qt_generate_forwarding_headers target)
+ qt_parse_all_arguments(arg "qt_generate_forwarding_headers"
+ "PRIVATE" "SOURCE;DESTINATION" "CLASSES" ${ARGN})
+ qt_internal_module_info(module "${target}")
+
+ if (NOT arg_DESTINATION)
+ get_filename_component(arg_DESTINATION "${arg_SOURCE}" NAME)
+ endif()
+
+ if (arg_PRIVATE)
+ set(main_fwd "${module_include_dir}/${PROJECT_VERSION}/${module}/private/${arg_DESTINATION}")
+ else()
+ set(main_fwd "${module_include_dir}/${arg_DESTINATION}")
+ endif()
+
+ get_filename_component(main_fwd_dir "${main_fwd}" DIRECTORY)
+ file(RELATIVE_PATH relpath "${main_fwd_dir}" "${CMAKE_CURRENT_BINARY_DIR}/${arg_SOURCE}")
+ set(main_contents "#include \"${relpath}\"")
+ file(GENERATE OUTPUT "${main_fwd}" CONTENT "${main_contents}")
+
+ foreach(class_fwd ${arg_CLASSES})
+ set(class_fwd_contents "#include \"${fwd_hdr}\"")
+ message("Generating forwarding header: ${class_fwd} -> ${relpath}.")
+ file(GENERATE OUTPUT "${module_include_dir}/${class_fwd}" CONTENT "${class_fwd_contents}")
+ endforeach()
+endfunction()
+
+
+function(add_qt_docs qdocFile)
+ # TODO
+endfunction()
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..5ca28c4de4
--- /dev/null
+++ b/cmake/QtCompilerOptimization.cmake
@@ -0,0 +1,121 @@
+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")
+ set(QT_CFLAGS_NEON "-mfpu=neon")
+ 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..69586fe52e
--- /dev/null
+++ b/cmake/QtConfig.cmake.in
@@ -0,0 +1,44 @@
+@PACKAGE_INIT@
+
+# Slightly amended version of ./src/corelib/Qt5Config.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)
+
+include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@Targets.cmake")
+include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@ToolsTargets.cmake")
+
+# 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()
+
+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} 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 Qt_FIND_QUIETLY)
+ message(WARNING "Failed to find Qt component \"${module}\" config file at \"${_expected_module_location}\"")
+ endif()
+
+ unset(_expected_module_location)
+ endif()
+endforeach()
+
+set(QT_BUILD_SHARED_LIBS @BUILD_SHARED_LIBS@)
+set(QT_CMAKE_EXPORT_NAMESPACE @QT_CMAKE_EXPORT_NAMESPACE@)
+
+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..2166ac69ff
--- /dev/null
+++ b/cmake/QtFeature.cmake
@@ -0,0 +1,488 @@
+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_define_definitions "" PARENT_SCOPE)
+endfunction()
+
+function(qt_feature feature)
+ 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()
+
+ 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}}")
+ if ((cache STREQUAL "ON") OR (cache STREQUAL "OFF"))
+ 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_definition feature name)
+ 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 target)
+ 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()
+
+ 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_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_generate_forwarding_headers("${__QtFeature_library}" SOURCE "${__QtFeature_private_file}" PRIVATE)
+
+ qt_internal_feature_write_file("${CMAKE_CURRENT_BINARY_DIR}/${__QtFeature_public_file}"
+ "${__QtFeature_public_features}" "${__QtFeature_public_extra}"
+ )
+ qt_generate_forwarding_headers("${__QtFeature_library}" SOURCE "${__QtFeature_public_file}")
+
+ 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")
+ 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()
+ 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)
+endfunction()
+
+function(qt_config_compile_test name)
+ cmake_parse_arguments(arg "" "LABEL" "LIBRARIES;CODE" ${ARGN})
+
+ 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_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}")
+ endif()
+ set(TEST_${name} "${HAVE_${name}}" CACHE INTERNAL "${arg_LABEL}")
+endfunction()
+
+function(qt_config_compile_test_x86simd extension label)
+ if (DEFINED TEST_X86SIMD_${extension})
+ return()
+ endif()
+
+ 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 "-DSIMD:string=${extension}")
+ 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/QtModuleConfig.cmake.in b/cmake/QtModuleConfig.cmake.in
new file mode 100644
index 0000000000..e9eec7ae94
--- /dev/null
+++ b/cmake/QtModuleConfig.cmake.in
@@ -0,0 +1,34 @@
+@PACKAGE_INIT@
+
+include(CMakeFindDependencyMacro)
+
+get_filename_component(_import_prefix "${CMAKE_CURRENT_LIST_FILE}" PATH)
+get_filename_component(_import_prefix "${_import_prefix}" REALPATH)
+
+# note: target_deps example: "Qt5Core\;5.12.0;Qt5Gui\;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}/.." NO_DEFAULT_PATH
+ )
+ endif()
+
+ if (NOT ${pkg}_FOUND)
+ set(@INSTALL_CMAKE_NAMESPACE@@target@_FOUND FALSE)
+ return()
+ endif()
+endforeach()
+
+include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@Targets.cmake")
+
+foreach(extra_cmake_include @extra_cmake_includes@)
+ include("${CMAKE_CURRENT_LIST_DIR}/${extra_cmake_include}")
+endforeach()
+
+include(${_import_prefix}/../@INSTALL_CMAKE_NAMESPACE@/QtFeature.cmake)
+
+qt_make_features_available(@QT_CMAKE_EXPORT_NAMESPACE@::@target@)
diff --git a/cmake/QtPlatformSupport.cmake b/cmake/QtPlatformSupport.cmake
new file mode 100644
index 0000000000..45479a3a7e
--- /dev/null
+++ b/cmake/QtPlatformSupport.cmake
@@ -0,0 +1,42 @@
+function(set01 result)
+ if (${ARGN})
+ set("${result}" 1 PARENT_SCOPE)
+ else()
+ set("${result}" 0 PARENT_SCOPE)
+ endif()
+endfunction()
+
+set01(LINUX CMAKE_SYSTEM_NAME STREQUAL "Linux")
+set01(HPUX CMAKE_SYSTEM_NAME STREQUAL "HPUX")
+set01(ANDROID CMAKE_SYSTEM_NAME STREQUAL "Android") # FIXME: How to identify this?
+set01(NACL CMAKE_SYSTEM_NAME STREQUAL "NaCl") # FIXME: How to identify this?
+set01(INTEGRITY CMAKE_SYSTEM_NAME STREQUAL "Integrity") # FIXME: How to identify this?
+set01(VXWORKS CMAKE_SYSTEM_NAME STREQUAL "VxWorks") # FIXME: How to identify this?
+set01(QNX CMAKE_SYSTEM_NAME STREQUAL "QNX") # FIXME: How to identify this?
+set01(OPENBSD CMAKE_SYSTEM_NAME STREQUAL "OpenBSD") # FIXME: How to identify this?
+set01(FREEBSD CMAKE_SYSTEM_NAME STREQUAL "FreeBSD") # FIXME: How to identify this?
+set01(NETBSD CMAKE_SYSTEM_NAME STREQUAL "NetBSD") # FIXME: How to identify this?
+set01(WASM CMAKE_SYSTEM_NAME STREQUAL "Webassembly") # FIXME: How to identify this?
+
+set01(BSD APPLE OR OPENBSD OR FREEBSD OR NETBSD)
+
+set01(WINRT WIN32 AND CMAKE_VS_PLATFORM_TOOSLET STREQUAL "winrt") # FIXME: How to identify this?
+
+set01(APPLE_OSX APPLE) # FIXME: How to identify this? For now assume that always building for macOS.
+set01(APPLE_UIKIT APPLE AND CMAKE_XCODE_PLATFORM_TOOLSET STREQUAL "uikit") # FIXME: How to identify this?
+set01(APPLE_IOS APPLE AND CMAKE_XCODE_PLATFORM_TOOLSET STREQUAL "ios") # FIXME: How to identify this?
+set01(APPLE_TVOS APPLE AND CMAKE_XCODE_PLATFORM_TOOLSET STREQUAL "tvos") # FIXME: How to identify this?
+set01(APPLE_WATCHOS APPLE AND CMAKE_XCODE_PLATFORM_TOOLSET STREQUAL "watchos") # FIXME: How to identify this?
+
+set01(ANDROID_EMBEDDED ANDROID) # FIXME: How to identify this?
+
+set01(GCC CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
+set01(CLANG CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+set01(ICC CMAKE_C_COMPILER MATCHES "icc|icl")
+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()
diff --git a/cmake/QtPostProcess.cmake b/cmake/QtPostProcess.cmake
new file mode 100644
index 0000000000..0d50d7fa47
--- /dev/null
+++ b/cmake/QtPostProcess.cmake
@@ -0,0 +1,46 @@
+function(qt_internal_write_depends_file target)
+ set(module Qt${target})
+ set(outfile "${PROJECT_BINARY_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()
+
+function(qt_internal_create_depends_files)
+ message("Generating depends files for ${KNOWN_QT_MODULES}...")
+ foreach (target ${KNOWN_QT_MODULES})
+ get_target_property(depends "${target}" LINK_LIBRARIES)
+ set(qtdeps "")
+ foreach (dep ${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_QT_MODULES "${dep}" _pos)
+ if (_pos GREATER -1)
+ list(APPEND qtdeps "${dep}")
+ endif()
+ endforeach()
+
+ if (DEFINED qtdeps)
+ list(REMOVE_DUPLICATES qtdeps)
+ endif()
+
+ get_target_property(hasModuleHeaders "${target}" MODULE_HAS_HEADERS)
+ if (${hasModuleHeaders})
+ qt_internal_write_depends_file("${target}" ${qtdeps})
+ endif()
+ endforeach()
+endfunction()
+
+qt_internal_create_depends_files()
diff --git a/cmake/QtSetup.cmake b/cmake/QtSetup.cmake
new file mode 100644
index 0000000000..c7d6f50b73
--- /dev/null
+++ b/cmake/QtSetup.cmake
@@ -0,0 +1,80 @@
+## Set a default build type if none was specified
+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/libQt5DBus_debug.5.12.0.dylib
+if(WIN32)
+ set(CMAKE_DEBUG_POSTFIX "d")
+elseif(APPLE)
+ set(CMAKE_DEBUG_POSTFIX "_debug")
+endif()
+
+## Force C++ standard, do not fall back, do not use compiler extensions
+set(CMAKE_CXX_STANDARD 14)
+set(CMAKE_CXX_STANDARD_REQUIRED ON)
+set(CMAKE_CXX_EXTENSIONS OFF)
+
+## 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)
+
+## Enable testing:
+include(CTest)
+enable_testing()
+
+## Define some constants to check for certain platforms, etc:
+include(QtPlatformSupport)
+
+## add_qt_module and co.:
+include(QtBuild)
+
+## Qt Feature support:
+include(QtFeature)
+
+## Compiler optimization flags:
+include(QtCompilerOptimization)
+
+## Compiler flags:
+include(QtCompilerFlags)
+
+## Find host tools (if non native):
+set(HOST_QT_TOOLS_DIRECTORY "" CACHE PATH "Directory with Qt host tools.")
+
+if (CMAKE_CROSSCOMPILING AND "x${HOST_QT_TOOLS_DIRECTORY}" STREQUAL "x")
+ message(FATAL_ERROR "You need to set HOST_QT_TOOLS_DIRECTORY for a cross-complile.")
+endif()
+
+## Find syncqt in HOST TOOLS or locally:
+if("x${HOST_QT_TOOLS_DIRECTORY}" STREQUAL "x")
+ set(QT_SYNCQT "${PROJECT_SOURCE_DIR}/bin/syncqt.pl")
+ install(PROGRAMS "${QT_SYNCQT}" DESTINATION "${INSTALL_BINDIR}")
+else()
+ set(QT_SYNCQT "${HOST_QT_TOOLS_DIRECTORY}/syncqt.pl")
+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/README.md b/cmake/README.md
new file mode 100644
index 0000000000..24ac29d8e6
--- /dev/null
+++ b/cmake/README.md
@@ -0,0 +1,144 @@
+# Status
+
+Initial port is on-going. Some modules of QtBase are ported, incl. some of the platform modules. Most are missing still.
+
+Basic functionality is there (moc, uic, etc.), but documentation, translations, qdbusxml2cpp, etc. are missing.
+
+NOTE: YOU WILL NEED CMAKE 3.15 or later (for example, master branch,
+after 168c11f70e52f9b4f00ef289a95023be3f273d2d, for more details see
+https://gitlab.kitware.com/cmake/cmake/merge_requests/2679
+and
+https://gitlab.kitware.com/cmake/cmake/merge_requests/3049
+).
+
+# 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
+
+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
+ * Linux: ``x64-linux``
+ * Windows: ``qt-x86-windows-static``
+ * Build Qt dependencies: ``vcpkg install zlib pcre2 double-conversion harfbuzz``
+ * When running cmake in qtbase, pass ``-DCMAKE_TOOLCHAIN_FILE=/path/to/your/vcpkg/scripts/buildsystems/vcpkg.cmake``
+ Previously CMAKE_PREFIX_PATH was mentioned instead of CMAKE_TOOLCHAIN_PATH. Setting CMAKE_PREFIX_PATH to the vcpkg installed folder is not enough, because then find_package is not overridden by vcpkg and cmake might not propagate all library dependencies for static packages (freetype is one such package).
+
+
+# Building against homebrew on macOS
+
+vcpkg doesn't support clang on macOS, see https://github.com/Microsoft/vcpkg/issues/4475 .
+
+ * Install homebrew: ```/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"```
+ * Build Qt dependencies: ``brew install pcre2 harfbuzz``
+ * Build cmake from HEAD (or you can build your own): ``brew install --HEAD 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 {path to source directory}
+ cmake --build .
+```
+
+``cmake --build`` is just a simple wrapper 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`` in this case.
+
+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 {path to source directory}
+ cmake --build . # ... or ninja ;-)
+```
+
+You can look into the generated ``build.ninja`` file if you're curious and you can also build targets directory such as ``ninja lib/libQt5Core.so``.
+
+When you're done with the build, you may want to install it, using ``ninja install`` or ``make install``. The installation prefix is chosen when running cmake though:
+
+```
+ cd {build directory}
+ cmake -GNinja -DCMAKE_INSTALL_PREFIX=/path/where/to/install {path to source directory}
+ ninja
+ ninja install
+```
+
+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).
+
+## 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 setting ``BUILD_EXAMPLES=OFF`` and ``BUILD_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:
+
+```
+ -DHOST_QT_TOOLS_DIRECTORY=/path/to/your/host_build/bin
+```
+
+The specified path needs to point to a directory that contains all the binaries of the host build of Qt.
+
+# 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/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/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/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/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.cmake b/configure.cmake
new file mode 100644
index 0000000000..cd03d9af01
--- /dev/null
+++ b/configure.cmake
@@ -0,0 +1,454 @@
+
+
+#### Inputs
+
+
+
+#### Libraries
+
+find_package(ZLIB)
+set_package_properties(ZLIB PROPERTIES TYPE OPTIONAL)
+find_package(ZSTD)
+set_package_properties(ZSTD PROPERTIES TYPE OPTIONAL)
+find_package(Libudev)
+set_package_properties(Libudev PROPERTIES TYPE OPTIONAL)
+
+
+#### Tests
+
+# precompile_header
+qt_config_compile_test(precompile_header
+ LABEL "precompiled header support"
+"
+
+#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"
+"#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")']
+)
+
+# 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")
+
+# 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()"
+"
+#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"
+"
+#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"
+"
+#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"
+"
+#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"
+"#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_gold_linker_alias"
+ AUTODETECT false
+ CONDITION NOT WIN32 AND NOT INTEGRITY AND NOT WASM AND tests.use_gold_linker OR FIXME
+)
+qt_feature("developer_build"
+ LABEL "Developer build"
+ AUTODETECT OFF
+)
+qt_feature("private_tests" PRIVATE
+ LABEL "Developer build: private_tests"
+ AUTODETECT OFF
+)
+qt_feature_definition("developer_build" "QT_BUILD_INTERNAL")
+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 INPUT_sdk STREQUAL ''
+)
+qt_feature("force_asserts" PUBLIC
+ LABEL "Force assertions"
+ AUTODETECT OFF
+)
+qt_feature("framework" PUBLIC
+ LABEL "Build Apple Frameworks"
+ CONDITION APPLE AND BUILD_SHARED_LIBS
+)
+qt_feature_definition("framework" "QT_MAC_FRAMEWORK_BUILD")
+qt_feature("largefile"
+ LABEL "Large file support"
+ CONDITION NOT ANDROID AND NOT INTEGRITY AND NOT WINRT
+)
+qt_feature_definition("largefile" "QT_LARGEFILE_SUPPORT" VALUE "64")
+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("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("sse3"
+ LABEL "SSE3"
+ CONDITION QT_FEATURE_sse2 AND TEST_subarch_sse3
+)
+qt_feature_definition("sse3" "QT_COMPILER_SUPPORTS_SSE3" VALUE "1")
+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("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("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("avx"
+ LABEL "AVX"
+ CONDITION QT_FEATURE_sse4_2 AND TEST_subarch_avx
+)
+qt_feature_definition("avx" "QT_COMPILER_SUPPORTS_AVX" VALUE "1")
+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("avx2" PRIVATE
+ LABEL "AVX2"
+ CONDITION QT_FEATURE_avx AND TEST_subarch_avx2
+)
+qt_feature_definition("avx2" "QT_COMPILER_SUPPORTS_AVX2" VALUE "1")
+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("avx512er"
+ LABEL "ER"
+ CONDITION QT_FEATURE_avx512f AND TEST_subarch_avx512er
+)
+qt_feature_definition("avx512er" "QT_COMPILER_SUPPORTS_AVX512ER" VALUE "1")
+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("avx512pf"
+ LABEL "PF"
+ CONDITION QT_FEATURE_avx512f AND TEST_subarch_avx512pf
+)
+qt_feature_definition("avx512pf" "QT_COMPILER_SUPPORTS_AVX512PF" VALUE "1")
+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("avx512bw"
+ LABEL "BW"
+ CONDITION QT_FEATURE_avx512f AND TEST_subarch_avx512bw
+)
+qt_feature_definition("avx512bw" "QT_COMPILER_SUPPORTS_AVX512BW" VALUE "1")
+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("avx512ifma"
+ LABEL "IFMA"
+ CONDITION QT_FEATURE_avx512f AND TEST_subarch_avx512ifma
+)
+qt_feature_definition("avx512ifma" "QT_COMPILER_SUPPORTS_AVX512IFMA" VALUE "1")
+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("aesni"
+ LABEL "AES"
+ CONDITION QT_FEATURE_sse2 AND TEST_subarch_aes
+)
+qt_feature_definition("aesni" "QT_COMPILER_SUPPORTS_AES" VALUE "1")
+qt_feature("rdrnd"
+ LABEL "RDRAND"
+ CONDITION TEST_subarch_rdseed
+)
+qt_feature_definition("rdrnd" "QT_COMPILER_SUPPORTS_RDRND" VALUE "1")
+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("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("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("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("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("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 libs.dbus OR FIXME
+ ENABLE INPUT_dbus STREQUAL 'linked'
+ DISABLE INPUT_dbus STREQUAL 'runtime'
+)
+qt_feature("gui" PRIVATE
+ LABEL "Qt Gui"
+)
+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("xml" PRIVATE
+ LABEL "Qt Xml"
+)
+qt_feature("libudev" PRIVATE
+ LABEL "udev"
+ CONDITION Libudev_FOUND
+)
+
+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 f7449ec068..731806f7aa 100644
--- a/configure.json
+++ b/configure.json
@@ -1331,9 +1331,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",
@@ -1361,9 +1359,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",
@@ -1373,8 +1369,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/global/macros.qdocconf b/doc/global/macros.qdocconf
index ef3ca1dc1d..72330cd16c 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..cdbf0c411d
--- /dev/null
+++ b/examples/CMakeLists.txt
@@ -0,0 +1,25 @@
+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::Gui)
+ add_subdirectory(gui)
+endif()
+if(TARGET Qt::Widgets)
+ add_subdirectory(widgets)
+endif()
diff --git a/examples/corelib/CMakeLists.txt b/examples/corelib/CMakeLists.txt
new file mode 100644
index 0000000000..3b61d307d9
--- /dev/null
+++ b/examples/corelib/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from corelib.pro.
+
+add_subdirectory(ipc)
+add_subdirectory(mimetypes)
+add_subdirectory(serialization)
+add_subdirectory(threads)
+add_subdirectory(tools)
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..39ef3f4e3f
--- /dev/null
+++ b/examples/corelib/ipc/localfortuneclient/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from localfortuneclient.pro.
+
+#####################################################################
+## localfortuneclient Binary:
+#####################################################################
+
+add_qt_executable(localfortuneclient
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/ipc/localfortuneclient"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/ipc/localfortuneclient"
+ SOURCES
+ client.cpp client.h
+ main.cpp
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/corelib/ipc/localfortuneserver/CMakeLists.txt b/examples/corelib/ipc/localfortuneserver/CMakeLists.txt
new file mode 100644
index 0000000000..e94028413e
--- /dev/null
+++ b/examples/corelib/ipc/localfortuneserver/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from localfortuneserver.pro.
+
+#####################################################################
+## localfortuneserver Binary:
+#####################################################################
+
+add_qt_executable(localfortuneserver
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/ipc/localfortuneserver"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/ipc/localfortuneserver"
+ SOURCES
+ main.cpp
+ server.cpp server.h
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/corelib/ipc/sharedmemory/CMakeLists.txt b/examples/corelib/ipc/sharedmemory/CMakeLists.txt
new file mode 100644
index 0000000000..125cfbd243
--- /dev/null
+++ b/examples/corelib/ipc/sharedmemory/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from sharedmemory.pro.
+
+#####################################################################
+## sharedmemory Binary:
+#####################################################################
+
+add_qt_executable(sharedmemory
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/ipc/sharedmemory"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/ipc/sharedmemory"
+ SOURCES
+ dialog.cpp dialog.h dialog.ui
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:sharedmemory.pro:<NONE>:
+# EXAMPLE_FILES = "*.png"
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..4bd2b5ca6a
--- /dev/null
+++ b/examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from mimetypebrowser.pro.
+
+#####################################################################
+## mimetypebrowser Binary:
+#####################################################################
+
+add_qt_executable(mimetypebrowser
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/mimetypes/mimetypebrowser"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/mimetypes/mimetypebrowser"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ mimetypemodel.cpp mimetypemodel.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:mimetypebrowser.pro:<NONE>:
+# CONFIG = "-app_bundle" "c++11"
+# TEMPLATE = "app"
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..b62181a2b7
--- /dev/null
+++ b/examples/corelib/serialization/cbordump/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from cbordump.pro.
+
+#####################################################################
+## cbordump Binary:
+#####################################################################
+
+add_qt_executable(cbordump
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/serialization/cbordump"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/serialization/cbordump"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ # Remove: gui
+)
+
+#### Keys ignored in scope 1:.:cbordump.pro:<NONE>:
+# CONFIG = "-app_bundle"
+# TEMPLATE = "app"
diff --git a/examples/corelib/serialization/convert/CMakeLists.txt b/examples/corelib/serialization/convert/CMakeLists.txt
new file mode 100644
index 0000000000..4dffb69c5b
--- /dev/null
+++ b/examples/corelib/serialization/convert/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from convert.pro.
+
+#####################################################################
+## convert Binary:
+#####################################################################
+
+add_qt_executable(convert
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/serialization/convert"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/serialization/convert"
+ SOURCES
+ 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
+ LIBRARIES
+ # Remove: gui
+)
+
+#### Keys ignored in scope 1:.:convert.pro:<NONE>:
+# CONFIG = "-app_bundle"
+# TEMPLATE = "app"
diff --git a/examples/corelib/serialization/savegame/CMakeLists.txt b/examples/corelib/serialization/savegame/CMakeLists.txt
new file mode 100644
index 0000000000..175fca270f
--- /dev/null
+++ b/examples/corelib/serialization/savegame/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from savegame.pro.
+
+#####################################################################
+## savegame Binary:
+#####################################################################
+
+add_qt_executable(savegame
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/serialization/savegame"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/serialization/savegame"
+ SOURCES
+ character.cpp character.h
+ game.cpp game.h
+ level.cpp level.h
+ main.cpp
+ LIBRARIES
+ # Remove: gui
+)
+
+#### Keys ignored in scope 1:.:savegame.pro:<NONE>:
+# CONFIG = "-app_bundle"
+# TEMPLATE = "app"
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..00f27bacd9
--- /dev/null
+++ b/examples/corelib/threads/mandelbrot/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from mandelbrot.pro.
+
+#####################################################################
+## mandelbrot Binary:
+#####################################################################
+
+add_qt_executable(mandelbrot
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/threads/mandelbrot"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/threads/mandelbrot"
+ SOURCES
+ main.cpp
+ mandelbrotwidget.cpp mandelbrotwidget.h
+ renderthread.cpp renderthread.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(mandelbrot CONDITION UNIX AND NOT APPLE_OSX AND NOT HAIKU AND NOT INTEGRITY AND NOT VXWORKS
+ LIBRARIES
+ m
+)
diff --git a/examples/corelib/threads/queuedcustomtype/CMakeLists.txt b/examples/corelib/threads/queuedcustomtype/CMakeLists.txt
new file mode 100644
index 0000000000..b86092bf26
--- /dev/null
+++ b/examples/corelib/threads/queuedcustomtype/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from queuedcustomtype.pro.
+
+#####################################################################
+## queuedcustomtype Binary:
+#####################################################################
+
+add_qt_executable(queuedcustomtype
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/threads/queuedcustomtype"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/threads/queuedcustomtype"
+ SOURCES
+ block.cpp block.h
+ main.cpp
+ renderthread.cpp renderthread.h
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/corelib/threads/semaphores/CMakeLists.txt b/examples/corelib/threads/semaphores/CMakeLists.txt
new file mode 100644
index 0000000000..d94f1ba5b4
--- /dev/null
+++ b/examples/corelib/threads/semaphores/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from semaphores.pro.
+
+#####################################################################
+## semaphores Binary:
+#####################################################################
+
+add_qt_executable(semaphores
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/threads/semaphores"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/threads/semaphores"
+ SOURCES
+ semaphores.cpp
+)
+
+#### Keys ignored in scope 1:.:semaphores.pro:<NONE>:
+# CONFIG = "-app_bundle" "console"
diff --git a/examples/corelib/threads/waitconditions/CMakeLists.txt b/examples/corelib/threads/waitconditions/CMakeLists.txt
new file mode 100644
index 0000000000..0a347c1cdd
--- /dev/null
+++ b/examples/corelib/threads/waitconditions/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from waitconditions.pro.
+
+#####################################################################
+## waitconditions Binary:
+#####################################################################
+
+add_qt_executable(waitconditions
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/threads/waitconditions"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/threads/waitconditions"
+ SOURCES
+ waitconditions.cpp
+)
+
+#### Keys ignored in scope 1:.:waitconditions.pro:<NONE>:
+# CONFIG = "-moc" "-app_bundle" "console"
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..68afb7221d
--- /dev/null
+++ b/examples/corelib/tools/contiguouscache/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from contiguouscache.pro.
+
+#####################################################################
+## contiguouscache Binary:
+#####################################################################
+
+add_qt_executable(contiguouscache
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/tools/contiguouscache"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/tools/contiguouscache"
+ SOURCES
+ main.cpp
+ randomlistmodel.cpp randomlistmodel.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/corelib/tools/customtype/CMakeLists.txt b/examples/corelib/tools/customtype/CMakeLists.txt
new file mode 100644
index 0000000000..e26846da82
--- /dev/null
+++ b/examples/corelib/tools/customtype/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from customtype.pro.
+
+#####################################################################
+## customtype Binary:
+#####################################################################
+
+add_qt_executable(customtype
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/tools/customtype"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/tools/customtype"
+ SOURCES
+ main.cpp
+ message.cpp message.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/corelib/tools/customtypesending/CMakeLists.txt b/examples/corelib/tools/customtypesending/CMakeLists.txt
new file mode 100644
index 0000000000..a069f73507
--- /dev/null
+++ b/examples/corelib/tools/customtypesending/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from customtypesending.pro.
+
+#####################################################################
+## customtypesending Binary:
+#####################################################################
+
+add_qt_executable(customtypesending
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/tools/customtypesending"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/corelib/tools/customtypesending"
+ SOURCES
+ main.cpp
+ message.cpp message.h
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
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..68abe95da6
--- /dev/null
+++ b/examples/dbus/chat/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from chat.pro.
+
+#####################################################################
+## chat Binary:
+#####################################################################
+
+add_qt_executable(chat
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/chat"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/chat"
+ SOURCES
+ chat.cpp chat.h
+ chatmainwindow.ui
+ chatsetnickname.ui
+ DBUS_ADAPTOR_SOURCES
+ org.example.chat.xml
+ DBUS_INTERFACE_SOURCES
+ org.example.chat.xml
+ LIBRARIES
+ Qt::DBus
+ Qt::Widgets
+)
diff --git a/examples/dbus/complexpingpong/CMakeLists.txt b/examples/dbus/complexpingpong/CMakeLists.txt
new file mode 100644
index 0000000000..cccb9584af
--- /dev/null
+++ b/examples/dbus/complexpingpong/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from complexpong.pro.
+
+#####################################################################
+## complexpong Binary:
+#####################################################################
+
+add_qt_executable(complexpong
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/complexpingpong"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/complexpingpong"
+ SOURCES
+ complexpong.cpp complexpong.h
+ LIBRARIES
+ # Remove: gui
+ Qt::DBus
+)
diff --git a/examples/dbus/listnames/CMakeLists.txt b/examples/dbus/listnames/CMakeLists.txt
new file mode 100644
index 0000000000..eb622b0ef6
--- /dev/null
+++ b/examples/dbus/listnames/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from listnames.pro.
+
+#####################################################################
+## listnames Binary:
+#####################################################################
+
+add_qt_executable(listnames
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/listnames"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/listnames"
+ SOURCES
+ listnames.cpp
+ LIBRARIES
+ # Remove: gui
+ Qt::DBus
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:listnames.pro:WIN32:
+# CONFIG = "console"
diff --git a/examples/dbus/pingpong/CMakeLists.txt b/examples/dbus/pingpong/CMakeLists.txt
new file mode 100644
index 0000000000..0979c8d487
--- /dev/null
+++ b/examples/dbus/pingpong/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from pingpong.pro.
+
+#####################################################################
+## ping Binary:
+#####################################################################
+
+add_qt_executable(ping
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/pingpong"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/pingpong"
+ SOURCES
+ ping.cpp
+ ping-common.h
+ LIBRARIES
+ # Remove: gui
+ Qt::DBus
+)
+#####################################################################
+## pong Binary:
+#####################################################################
+
+add_qt_executable(pong
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/pingpong"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/pingpong"
+ SOURCES
+ ping-common.h
+ pong.cpp pong.h
+ LIBRARIES
+ # Remove: gui
+ Qt::DBus
+)
+
+if(WIN32)
+endif()
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..a8aed5413a
--- /dev/null
+++ b/examples/dbus/remotecontrolledcar/car/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from car.pro.
+
+#####################################################################
+## car Binary:
+#####################################################################
+
+add_qt_executable(car
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/remotecontrolledcar/car"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/remotecontrolledcar/car"
+ SOURCES
+ car.cpp car.h
+ main.cpp
+ DBUS_ADAPTOR_SOURCES
+ car.xml
+ LIBRARIES
+ Qt::DBus
+ Qt::Widgets
+)
diff --git a/examples/dbus/remotecontrolledcar/controller/CMakeLists.txt b/examples/dbus/remotecontrolledcar/controller/CMakeLists.txt
new file mode 100644
index 0000000000..c9902e2519
--- /dev/null
+++ b/examples/dbus/remotecontrolledcar/controller/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from controller.pro.
+
+#####################################################################
+## controller Binary:
+#####################################################################
+
+add_qt_executable(controller
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/remotecontrolledcar/controller"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/dbus/remotecontrolledcar/controller"
+ SOURCES
+ controller.cpp controller.h controller.ui
+ main.cpp
+ DBUS_INTERFACE_SOURCES
+ car.xml
+ LIBRARIES
+ Qt::DBus
+ Qt::Widgets
+)
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..3786ed38a4
--- /dev/null
+++ b/examples/embedded/digiflip/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from digiflip.pro.
+
+#####################################################################
+## digiflip Binary:
+#####################################################################
+
+add_qt_executable(digiflip
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/embedded/digiflip"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/embedded/digiflip"
+ SOURCES
+ digiflip.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/embedded/flickable/CMakeLists.txt b/examples/embedded/flickable/CMakeLists.txt
new file mode 100644
index 0000000000..20f8eca9f5
--- /dev/null
+++ b/examples/embedded/flickable/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from flickable.pro.
+
+#####################################################################
+## flickable Binary:
+#####################################################################
+
+add_qt_executable(flickable
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/embedded/flickable"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/embedded/flickable"
+ SOURCES
+ flickable.cpp flickable.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/embedded/flightinfo/CMakeLists.txt b/examples/embedded/flightinfo/CMakeLists.txt
new file mode 100644
index 0000000000..b7d8441b96
--- /dev/null
+++ b/examples/embedded/flightinfo/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from flightinfo.pro.
+
+#####################################################################
+## flightinfo Binary:
+#####################################################################
+
+add_qt_executable(flightinfo
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/embedded/flightinfo"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/embedded/flightinfo"
+ SOURCES
+ flightinfo.cpp
+ form.ui
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(flightinfo "flightinfo" PREFIX "/" FILES
+ aircraft.png)
+
+
+#### Keys ignored in scope 1:.:flightinfo.pro:<NONE>:
+# TEMPLATE = "app"
diff --git a/examples/embedded/lightmaps/CMakeLists.txt b/examples/embedded/lightmaps/CMakeLists.txt
new file mode 100644
index 0000000000..4779d07adc
--- /dev/null
+++ b/examples/embedded/lightmaps/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from lightmaps.pro.
+
+#####################################################################
+## lightmaps Binary:
+#####################################################################
+
+add_qt_executable(lightmaps
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/embedded/lightmaps"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/embedded/lightmaps"
+ SOURCES
+ lightmaps.cpp lightmaps.h
+ main.cpp
+ mapzoom.cpp mapzoom.h
+ slippymap.cpp slippymap.h
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:lightmaps.pro:<NONE>:
+# TEMPLATE = "app"
diff --git a/examples/embedded/raycasting/CMakeLists.txt b/examples/embedded/raycasting/CMakeLists.txt
new file mode 100644
index 0000000000..3757bb756a
--- /dev/null
+++ b/examples/embedded/raycasting/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from raycasting.pro.
+
+#####################################################################
+## raycasting Binary:
+#####################################################################
+
+add_qt_executable(raycasting
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/embedded/raycasting"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/embedded/raycasting"
+ SOURCES
+ raycasting.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(raycasting "raycasting" PREFIX "/" FILES
+ textures.png)
+
+
+#### Keys ignored in scope 1:.:raycasting.pro:<NONE>:
+# TEMPLATE = "app"
diff --git a/examples/embedded/styleexample/CMakeLists.txt b/examples/embedded/styleexample/CMakeLists.txt
new file mode 100644
index 0000000000..9c82adc99d
--- /dev/null
+++ b/examples/embedded/styleexample/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from styleexample.pro.
+
+#####################################################################
+## styleexample Binary:
+#####################################################################
+
+add_qt_executable(styleexample
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/embedded/styleexample"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/embedded/styleexample"
+ SOURCES
+ main.cpp
+ stylewidget.cpp stylewidget.h stylewidget.ui
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(styleexample "styleexample" PREFIX "/" FILES
+ files/add.png
+ files/application.qss
+ files/blue.qss
+ files/khaki.qss
+ files/nature_1.jpg
+ files/nostyle.qss
+ files/remove.png
+ files/transparent.qss)
+
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..99a879c57a
--- /dev/null
+++ b/examples/gui/analogclock/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from analogclock.pro.
+
+#####################################################################
+## analogclock Binary:
+#####################################################################
+
+add_qt_executable(analogclock
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/gui/analogclock"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/gui/analogclock"
+ SOURCES
+ ../rasterwindow/rasterwindow.cpp ../rasterwindow/rasterwindow.h
+ main.cpp
+ INCLUDE_DIRECTORIES
+ ../rasterwindow
+ LIBRARIES # special case
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:analogclock.pro:<NONE>:
+# CONFIG = "no_batch"
diff --git a/examples/gui/openglwindow/CMakeLists.txt b/examples/gui/openglwindow/CMakeLists.txt
new file mode 100644
index 0000000000..a59ba14346
--- /dev/null
+++ b/examples/gui/openglwindow/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from openglwindow.pro.
+
+#####################################################################
+## openglwindow Binary:
+#####################################################################
+
+add_qt_executable(openglwindow
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/gui/openglwindow"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/gui/openglwindow"
+ SOURCES
+ main.cpp
+ openglwindow.cpp openglwindow.h
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ LIBRARIES # special case
+ Qt::Gui
+)
diff --git a/examples/gui/rasterwindow/CMakeLists.txt b/examples/gui/rasterwindow/CMakeLists.txt
new file mode 100644
index 0000000000..61255f3038
--- /dev/null
+++ b/examples/gui/rasterwindow/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from rasterwindow.pro.
+
+#####################################################################
+## rasterwindow Binary:
+#####################################################################
+
+add_qt_executable(rasterwindow
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/gui/rasterwindow"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/gui/rasterwindow"
+ SOURCES
+ main.cpp
+ rasterwindow.cpp rasterwindow.h
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ LIBRARIES # special case
+ Qt::Gui
+)
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..001e5c7e2e
--- /dev/null
+++ b/examples/network/bearermonitor/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from bearermonitor.pro.
+
+#####################################################################
+## bearermonitor Binary:
+#####################################################################
+
+add_qt_executable(bearermonitor
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/bearermonitor"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/bearermonitor"
+ SOURCES
+ bearermonitor.cpp bearermonitor.h
+ bearermonitor_240_320.ui
+ bearermonitor_640_480.ui
+ main.cpp
+ sessionwidget.cpp sessionwidget.h sessionwidget.ui
+ LIBRARIES
+ Qt::Gui
+ Qt::Network
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:bearermonitor.pro:<NONE>:
+# CONFIG = "console"
+
+## Scopes:
+#####################################################################
+
+extend_target(bearermonitor CONDITION WIN32
+ LIBRARIES
+ ws2_32
+)
diff --git a/examples/network/blockingfortuneclient/CMakeLists.txt b/examples/network/blockingfortuneclient/CMakeLists.txt
new file mode 100644
index 0000000000..bedbf2f607
--- /dev/null
+++ b/examples/network/blockingfortuneclient/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from blockingfortuneclient.pro.
+
+#####################################################################
+## blockingfortuneclient Binary:
+#####################################################################
+
+add_qt_executable(blockingfortuneclient
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/blockingfortuneclient"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/blockingfortuneclient"
+ SOURCES
+ blockingclient.cpp blockingclient.h
+ fortunethread.cpp fortunethread.h
+ main.cpp
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/network/broadcastreceiver/CMakeLists.txt b/examples/network/broadcastreceiver/CMakeLists.txt
new file mode 100644
index 0000000000..197e56cef0
--- /dev/null
+++ b/examples/network/broadcastreceiver/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from broadcastreceiver.pro.
+
+#####################################################################
+## broadcastreceiver Binary:
+#####################################################################
+
+add_qt_executable(broadcastreceiver
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/broadcastreceiver"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/broadcastreceiver"
+ SOURCES
+ main.cpp
+ receiver.cpp receiver.h
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/network/broadcastsender/CMakeLists.txt b/examples/network/broadcastsender/CMakeLists.txt
new file mode 100644
index 0000000000..8fd49d8578
--- /dev/null
+++ b/examples/network/broadcastsender/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from broadcastsender.pro.
+
+#####################################################################
+## broadcastsender Binary:
+#####################################################################
+
+add_qt_executable(broadcastsender
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/broadcastsender"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/broadcastsender"
+ SOURCES
+ main.cpp
+ sender.cpp sender.h
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/network/dnslookup/CMakeLists.txt b/examples/network/dnslookup/CMakeLists.txt
new file mode 100644
index 0000000000..6ffc633a96
--- /dev/null
+++ b/examples/network/dnslookup/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from dnslookup.pro.
+
+#####################################################################
+## dnslookup Binary:
+#####################################################################
+
+add_qt_executable(dnslookup
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/dnslookup"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/dnslookup"
+ SOURCES
+ dnslookup.cpp dnslookup.h
+ LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:dnslookup.pro:<NONE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:dnslookup.pro:APPLE_OSX:
+# CONFIG = "-app_bundle"
+
+#### Keys ignored in scope 3:.:dnslookup.pro:WIN32:
+# CONFIG = "console"
diff --git a/examples/network/download/CMakeLists.txt b/examples/network/download/CMakeLists.txt
new file mode 100644
index 0000000000..868685fd0a
--- /dev/null
+++ b/examples/network/download/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from download.pro.
+
+#####################################################################
+## download Binary:
+#####################################################################
+
+add_qt_executable(download
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/download"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/download"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:download.pro:<NONE>:
+# CONFIG = "-app_bundle"
diff --git a/examples/network/downloadmanager/CMakeLists.txt b/examples/network/downloadmanager/CMakeLists.txt
new file mode 100644
index 0000000000..a5ccac9178
--- /dev/null
+++ b/examples/network/downloadmanager/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from downloadmanager.pro.
+
+#####################################################################
+## downloadmanager Binary:
+#####################################################################
+
+add_qt_executable(downloadmanager
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/downloadmanager"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/downloadmanager"
+ SOURCES
+ downloadmanager.cpp downloadmanager.h
+ main.cpp
+ textprogressbar.cpp textprogressbar.h
+ LIBRARIES
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:downloadmanager.pro:<NONE>:
+# CONFIG = "-app_bundle"
+# OTHER_FILES = "debian/changelog" "debian/compat" "debian/control" "debian/copyright" "debian/README" "debian/rules"
diff --git a/examples/network/fortuneclient/CMakeLists.txt b/examples/network/fortuneclient/CMakeLists.txt
new file mode 100644
index 0000000000..bbeecf9c64
--- /dev/null
+++ b/examples/network/fortuneclient/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from fortuneclient.pro.
+
+#####################################################################
+## fortuneclient Binary:
+#####################################################################
+
+add_qt_executable(fortuneclient
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/fortuneclient"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/fortuneclient"
+ SOURCES
+ client.cpp client.h
+ main.cpp
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/network/fortuneserver/CMakeLists.txt b/examples/network/fortuneserver/CMakeLists.txt
new file mode 100644
index 0000000000..299f43910f
--- /dev/null
+++ b/examples/network/fortuneserver/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from fortuneserver.pro.
+
+#####################################################################
+## fortuneserver Binary:
+#####################################################################
+
+add_qt_executable(fortuneserver
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/fortuneserver"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/fortuneserver"
+ SOURCES
+ main.cpp
+ server.cpp server.h
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/network/googlesuggest/CMakeLists.txt b/examples/network/googlesuggest/CMakeLists.txt
new file mode 100644
index 0000000000..ef5deedb80
--- /dev/null
+++ b/examples/network/googlesuggest/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from googlesuggest.pro.
+
+#####################################################################
+## googlesuggest Binary:
+#####################################################################
+
+add_qt_executable(googlesuggest
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/googlesuggest"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/googlesuggest"
+ SOURCES
+ googlesuggest.cpp googlesuggest.h
+ main.cpp
+ searchbox.cpp searchbox.h
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/network/http/CMakeLists.txt b/examples/network/http/CMakeLists.txt
new file mode 100644
index 0000000000..d1c61f1c98
--- /dev/null
+++ b/examples/network/http/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from http.pro.
+
+#####################################################################
+## http Binary:
+#####################################################################
+
+add_qt_executable(http
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/http"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/http"
+ SOURCES
+ authenticationdialog.ui
+ httpwindow.cpp httpwindow.h
+ main.cpp
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/network/loopback/CMakeLists.txt b/examples/network/loopback/CMakeLists.txt
new file mode 100644
index 0000000000..566b48a76e
--- /dev/null
+++ b/examples/network/loopback/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from loopback.pro.
+
+#####################################################################
+## loopback Binary:
+#####################################################################
+
+add_qt_executable(loopback
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/loopback"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/loopback"
+ SOURCES
+ dialog.cpp dialog.h
+ main.cpp
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/network/multicastreceiver/CMakeLists.txt b/examples/network/multicastreceiver/CMakeLists.txt
new file mode 100644
index 0000000000..11204015f2
--- /dev/null
+++ b/examples/network/multicastreceiver/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from multicastreceiver.pro.
+
+#####################################################################
+## multicastreceiver Binary:
+#####################################################################
+
+add_qt_executable(multicastreceiver
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/multicastreceiver"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/multicastreceiver"
+ SOURCES
+ main.cpp
+ receiver.cpp receiver.h
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/network/multicastsender/CMakeLists.txt b/examples/network/multicastsender/CMakeLists.txt
new file mode 100644
index 0000000000..e02a6b7145
--- /dev/null
+++ b/examples/network/multicastsender/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from multicastsender.pro.
+
+#####################################################################
+## multicastsender Binary:
+#####################################################################
+
+add_qt_executable(multicastsender
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/multicastsender"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/multicastsender"
+ SOURCES
+ main.cpp
+ sender.cpp sender.h
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/network/multistreamclient/CMakeLists.txt b/examples/network/multistreamclient/CMakeLists.txt
new file mode 100644
index 0000000000..b9f10f3fd5
--- /dev/null
+++ b/examples/network/multistreamclient/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from multistreamclient.pro.
+
+#####################################################################
+## multistreamclient Binary:
+#####################################################################
+
+add_qt_executable(multistreamclient
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/multistreamclient"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/multistreamclient"
+ SOURCES
+ chatconsumer.cpp chatconsumer.h
+ client.cpp client.h
+ consumer.h
+ main.cpp
+ movieconsumer.cpp movieconsumer.h
+ timeconsumer.cpp timeconsumer.h
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/network/multistreamserver/CMakeLists.txt b/examples/network/multistreamserver/CMakeLists.txt
new file mode 100644
index 0000000000..3475995178
--- /dev/null
+++ b/examples/network/multistreamserver/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from multistreamserver.pro.
+
+#####################################################################
+## multistreamserver Binary:
+#####################################################################
+
+add_qt_executable(multistreamserver
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/multistreamserver"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/multistreamserver"
+ SOURCES
+ chatprovider.cpp chatprovider.h
+ main.cpp
+ movieprovider.cpp movieprovider.h
+ provider.h
+ server.cpp server.h
+ timeprovider.cpp timeprovider.h
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:multistreamserver.pro:<NONE>:
+# EXAMPLE_FILES = "animation.gif"
diff --git a/examples/network/network-chat/CMakeLists.txt b/examples/network/network-chat/CMakeLists.txt
new file mode 100644
index 0000000000..56cd632529
--- /dev/null
+++ b/examples/network/network-chat/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from network-chat.pro.
+
+#####################################################################
+## network-chat Binary:
+#####################################################################
+
+add_qt_executable(network-chat
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/network-chat"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/network-chat"
+ SOURCES
+ chatdialog.cpp chatdialog.h chatdialog.ui
+ client.cpp client.h
+ connection.cpp connection.h
+ main.cpp
+ peermanager.cpp peermanager.h
+ server.cpp server.h
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/network/securesocketclient/CMakeLists.txt b/examples/network/securesocketclient/CMakeLists.txt
new file mode 100644
index 0000000000..e6fdd6b2ca
--- /dev/null
+++ b/examples/network/securesocketclient/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from securesocketclient.pro.
+
+#####################################################################
+## securesocketclient Binary:
+#####################################################################
+
+add_qt_executable(securesocketclient
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/securesocketclient"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/securesocketclient"
+ SOURCES
+ certificateinfo.cpp certificateinfo.h certificateinfo.ui
+ main.cpp
+ sslclient.cpp sslclient.h sslclient.ui
+ sslerrors.ui
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(securesocketclient "securesocketclient" FILES
+ encrypted.png)
+
diff --git a/examples/network/secureudpclient/CMakeLists.txt b/examples/network/secureudpclient/CMakeLists.txt
new file mode 100644
index 0000000000..02dfd77fe0
--- /dev/null
+++ b/examples/network/secureudpclient/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from secureudpclient.pro.
+
+#####################################################################
+## secureudpclient Binary:
+#####################################################################
+
+add_qt_executable(secureudpclient
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/secureudpclient"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/secureudpclient"
+ SOURCES
+ addressdialog.cpp addressdialog.h addressdialog.ui
+ association.cpp association.h
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ LIBRARIES
+ Qt::Widgets
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:secureudpclient.pro:<NONE>:
+# TEMPLATE = "app"
diff --git a/examples/network/secureudpserver/CMakeLists.txt b/examples/network/secureudpserver/CMakeLists.txt
new file mode 100644
index 0000000000..c7d97420ae
--- /dev/null
+++ b/examples/network/secureudpserver/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from secureudpserver.pro.
+
+#####################################################################
+## secureudpserver Binary:
+#####################################################################
+
+add_qt_executable(secureudpserver
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/secureudpserver"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/secureudpserver"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ nicselector.cpp nicselector.h nicselector.ui
+ server.cpp server.h
+ LIBRARIES
+ Qt::Widgets
+ Qt::Network
+)
+
+#### Keys ignored in scope 1:.:secureudpserver.pro:<NONE>:
+# TEMPLATE = "app"
diff --git a/examples/network/threadedfortuneserver/CMakeLists.txt b/examples/network/threadedfortuneserver/CMakeLists.txt
new file mode 100644
index 0000000000..124ac1d1cc
--- /dev/null
+++ b/examples/network/threadedfortuneserver/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from threadedfortuneserver.pro.
+
+#####################################################################
+## threadedfortuneserver Binary:
+#####################################################################
+
+add_qt_executable(threadedfortuneserver
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/threadedfortuneserver"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/threadedfortuneserver"
+ SOURCES
+ dialog.cpp dialog.h
+ fortuneserver.cpp fortuneserver.h
+ fortunethread.cpp fortunethread.h
+ main.cpp
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
diff --git a/examples/network/torrent/CMakeLists.txt b/examples/network/torrent/CMakeLists.txt
new file mode 100644
index 0000000000..f8cbc071ff
--- /dev/null
+++ b/examples/network/torrent/CMakeLists.txt
@@ -0,0 +1,42 @@
+# Generated from torrent.pro.
+
+#####################################################################
+## torrent Binary:
+#####################################################################
+
+add_qt_executable(torrent
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/torrent"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/network/torrent"
+ SOURCES
+ addtorrentdialog.cpp addtorrentdialog.h
+ bencodeparser.cpp bencodeparser.h
+ connectionmanager.cpp connectionmanager.h
+ filemanager.cpp filemanager.h
+ forms/addtorrentform.ui
+ 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
+ INCLUDE_DIRECTORIES
+ forms # special case
+ LIBRARIES
+ Qt::Network
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(torrent "icons" PREFIX "/" FILES
+ icons/1downarrow.png
+ icons/1uparrow.png
+ icons/bottom.png
+ icons/exit.png
+ icons/peertopeer.png
+ icons/player_pause.png
+ icons/player_play.png
+ icons/player_stop.png)
+
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..0eae5b28af
--- /dev/null
+++ b/examples/qpa/qrasterwindow/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from qrasterwindow.pro.
+
+#####################################################################
+## qrasterwindow Binary:
+#####################################################################
+
+add_qt_executable(qrasterwindow
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/qpa/qrasterwindow"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/qpa/qrasterwindow"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Gui # special case
+)
diff --git a/examples/qpa/windows/CMakeLists.txt b/examples/qpa/windows/CMakeLists.txt
new file mode 100644
index 0000000000..55135e02ff
--- /dev/null
+++ b/examples/qpa/windows/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from windows.pro.
+
+#####################################################################
+## windows Binary:
+#####################################################################
+
+add_qt_executable(windows
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/qpa/windows"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/qpa/windows"
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::CorePrivate
+)
+
+#### Keys ignored in scope 1:.:windows.pro:<NONE>:
+# CONFIG = "console"
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..0de3f26c5e
--- /dev/null
+++ b/examples/qtconcurrent/imagescaling/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from imagescaling.pro.
+
+#####################################################################
+## imagescaling Binary:
+#####################################################################
+
+add_qt_executable(imagescaling
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtconcurrent/imagescaling"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtconcurrent/imagescaling"
+ SOURCES
+ imagescaling.cpp imagescaling.h
+ main.cpp
+ LIBRARIES
+ Qt::Concurrent
+ Qt::Widgets
+)
diff --git a/examples/qtconcurrent/map/CMakeLists.txt b/examples/qtconcurrent/map/CMakeLists.txt
new file mode 100644
index 0000000000..147b91236b
--- /dev/null
+++ b/examples/qtconcurrent/map/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from map.pro.
+
+#####################################################################
+## mapdemo Binary:
+#####################################################################
+
+add_qt_executable(mapdemo
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtconcurrent/map"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtconcurrent/map"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Concurrent
+ Qt::Gui # special case
+)
+
+#### Keys ignored in scope 1:.:map.pro:<NONE>:
+# CONFIG = "-app_bundle"
+# TEMPLATE = "app"
diff --git a/examples/qtconcurrent/progressdialog/CMakeLists.txt b/examples/qtconcurrent/progressdialog/CMakeLists.txt
new file mode 100644
index 0000000000..3aae4af084
--- /dev/null
+++ b/examples/qtconcurrent/progressdialog/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from progressdialog.pro.
+
+#####################################################################
+## progressdialog Binary:
+#####################################################################
+
+add_qt_executable(progressdialog
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtconcurrent/progressdialog"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtconcurrent/progressdialog"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Concurrent
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:progressdialog.pro:<NONE>:
+# CONFIG = "console"
diff --git a/examples/qtconcurrent/runfunction/CMakeLists.txt b/examples/qtconcurrent/runfunction/CMakeLists.txt
new file mode 100644
index 0000000000..c400b44cf6
--- /dev/null
+++ b/examples/qtconcurrent/runfunction/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from runfunction.pro.
+
+#####################################################################
+## runfunction Binary:
+#####################################################################
+
+add_qt_executable(runfunction
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtconcurrent/runfunction"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtconcurrent/runfunction"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Concurrent
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:runfunction.pro:<NONE>:
+# CONFIG = "-app_bundle"
diff --git a/examples/qtconcurrent/wordcount/CMakeLists.txt b/examples/qtconcurrent/wordcount/CMakeLists.txt
new file mode 100644
index 0000000000..9bb2ac58d7
--- /dev/null
+++ b/examples/qtconcurrent/wordcount/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from wordcount.pro.
+
+#####################################################################
+## wordcount Binary:
+#####################################################################
+
+add_qt_executable(wordcount
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtconcurrent/wordcount"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtconcurrent/wordcount"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Concurrent
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:wordcount.pro:<NONE>:
+# CONFIG = "-app_bundle"
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..6e489e329f
--- /dev/null
+++ b/examples/qtestlib/tutorial1/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from tutorial1.pro.
+
+#####################################################################
+## tutorial1 Binary:
+#####################################################################
+
+add_qt_executable(tutorial1
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial1"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial1"
+ SOURCES
+ testqstring.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::Test
+)
diff --git a/examples/qtestlib/tutorial2/CMakeLists.txt b/examples/qtestlib/tutorial2/CMakeLists.txt
new file mode 100644
index 0000000000..06288ce50b
--- /dev/null
+++ b/examples/qtestlib/tutorial2/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from tutorial2.pro.
+
+#####################################################################
+## tutorial2 Binary:
+#####################################################################
+
+add_qt_executable(tutorial2
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial2"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial2"
+ SOURCES
+ testqstring.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::Test
+)
diff --git a/examples/qtestlib/tutorial3/CMakeLists.txt b/examples/qtestlib/tutorial3/CMakeLists.txt
new file mode 100644
index 0000000000..79683e0cfc
--- /dev/null
+++ b/examples/qtestlib/tutorial3/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from tutorial3.pro.
+
+#####################################################################
+## tutorial3 Binary:
+#####################################################################
+
+add_qt_executable(tutorial3
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial3"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial3"
+ SOURCES
+ testgui.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::Test
+)
diff --git a/examples/qtestlib/tutorial4/CMakeLists.txt b/examples/qtestlib/tutorial4/CMakeLists.txt
new file mode 100644
index 0000000000..2f3d2bb88a
--- /dev/null
+++ b/examples/qtestlib/tutorial4/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from tutorial4.pro.
+
+#####################################################################
+## tutorial4 Binary:
+#####################################################################
+
+add_qt_executable(tutorial4
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial4"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial4"
+ SOURCES
+ testgui.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::Test
+)
diff --git a/examples/qtestlib/tutorial5/CMakeLists.txt b/examples/qtestlib/tutorial5/CMakeLists.txt
new file mode 100644
index 0000000000..e4af9b354c
--- /dev/null
+++ b/examples/qtestlib/tutorial5/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from tutorial5.pro.
+
+#####################################################################
+## tutorial5 Binary:
+#####################################################################
+
+add_qt_executable(tutorial5
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial5"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial5"
+ SOURCES
+ benchmarking.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::Test
+)
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..e01adc1402
--- /dev/null
+++ b/examples/sql/books/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from books.pro.
+
+#####################################################################
+## books Binary:
+#####################################################################
+
+add_qt_executable(books
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/books"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/books"
+ SOURCES
+ bookdelegate.cpp bookdelegate.h
+ bookwindow.cpp bookwindow.h bookwindow.ui
+ initdb.h
+ main.cpp
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ LIBRARIES
+ Qt::Sql
+ Qt::Widgets
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(books "books" PREFIX "/" FILES
+ images/star.png)
+
+
+#### Keys ignored in scope 1:.:books.pro:<NONE>:
+# TEMPLATE = "app"
diff --git a/examples/sql/cachedtable/CMakeLists.txt b/examples/sql/cachedtable/CMakeLists.txt
new file mode 100644
index 0000000000..8e87a32211
--- /dev/null
+++ b/examples/sql/cachedtable/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from cachedtable.pro.
+
+#####################################################################
+## cachedtable Binary:
+#####################################################################
+
+add_qt_executable(cachedtable
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/cachedtable"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/cachedtable"
+ SOURCES
+ ../connection.h
+ main.cpp
+ tableeditor.cpp tableeditor.h
+ LIBRARIES
+ Qt::Sql
+ Qt::Widgets
+)
diff --git a/examples/sql/drilldown/CMakeLists.txt b/examples/sql/drilldown/CMakeLists.txt
new file mode 100644
index 0000000000..a4301d3474
--- /dev/null
+++ b/examples/sql/drilldown/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from drilldown.pro.
+
+#####################################################################
+## drilldown Binary:
+#####################################################################
+
+add_qt_executable(drilldown
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/drilldown"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/drilldown"
+ SOURCES
+ ../connection.h
+ imageitem.cpp imageitem.h
+ informationwindow.cpp informationwindow.h
+ main.cpp
+ view.cpp view.h
+ LIBRARIES
+ Qt::Sql
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(drilldown "drilldown" PREFIX "/" FILES
+ images/qt-creator.png
+ images/qt-logo.png
+ images/qt-project.png
+ images/qt-quick.png)
+
diff --git a/examples/sql/masterdetail/CMakeLists.txt b/examples/sql/masterdetail/CMakeLists.txt
new file mode 100644
index 0000000000..8c73675e55
--- /dev/null
+++ b/examples/sql/masterdetail/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from masterdetail.pro.
+
+#####################################################################
+## masterdetail Binary:
+#####################################################################
+
+add_qt_executable(masterdetail
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/masterdetail"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/masterdetail"
+ SOURCES
+ database.h
+ dialog.cpp dialog.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Sql
+ Qt::Widgets
+ Qt::Xml
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(masterdetail "masterdetail" FILES
+ images/icon.png
+ images/image.png)
+
+
+#### Keys ignored in scope 1:.:masterdetail.pro:<NONE>:
+# EXAMPLE_FILES = "albumdetails.xml"
diff --git a/examples/sql/querymodel/CMakeLists.txt b/examples/sql/querymodel/CMakeLists.txt
new file mode 100644
index 0000000000..5c9d48c7f1
--- /dev/null
+++ b/examples/sql/querymodel/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from querymodel.pro.
+
+#####################################################################
+## querymodel Binary:
+#####################################################################
+
+add_qt_executable(querymodel
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/querymodel"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/querymodel"
+ SOURCES
+ ../connection.h
+ customsqlmodel.cpp customsqlmodel.h
+ editablesqlmodel.cpp editablesqlmodel.h
+ main.cpp
+ LIBRARIES
+ Qt::Sql
+ Qt::Widgets
+)
diff --git a/examples/sql/relationaltablemodel/CMakeLists.txt b/examples/sql/relationaltablemodel/CMakeLists.txt
new file mode 100644
index 0000000000..d31042cc73
--- /dev/null
+++ b/examples/sql/relationaltablemodel/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from relationaltablemodel.pro.
+
+#####################################################################
+## relationaltablemodel Binary:
+#####################################################################
+
+add_qt_executable(relationaltablemodel
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/relationaltablemodel"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/relationaltablemodel"
+ SOURCES
+ ../connection.h
+ relationaltablemodel.cpp
+ LIBRARIES
+ Qt::Sql
+ Qt::Widgets
+)
diff --git a/examples/sql/sqlbrowser/CMakeLists.txt b/examples/sql/sqlbrowser/CMakeLists.txt
new file mode 100644
index 0000000000..03111e9049
--- /dev/null
+++ b/examples/sql/sqlbrowser/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from sqlbrowser.pro.
+
+#####################################################################
+## sqlbrowser Binary:
+#####################################################################
+
+add_qt_executable(sqlbrowser
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/sqlbrowser"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/sqlbrowser"
+ SOURCES
+ browser.cpp browser.h
+ browserwidget.ui
+ connectionwidget.cpp connectionwidget.h
+ main.cpp
+ qsqlconnectiondialog.cpp qsqlconnectiondialog.h qsqlconnectiondialog.ui
+ LIBRARIES
+ Qt::Sql
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:sqlbrowser.pro:<NONE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:sqlbrowser.pro:build_all AND NOT build_pass:
+# CONFIG = "-build_all" "release"
diff --git a/examples/sql/sqlwidgetmapper/CMakeLists.txt b/examples/sql/sqlwidgetmapper/CMakeLists.txt
new file mode 100644
index 0000000000..41d95da21e
--- /dev/null
+++ b/examples/sql/sqlwidgetmapper/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from sqlwidgetmapper.pro.
+
+#####################################################################
+## sqlwidgetmapper Binary:
+#####################################################################
+
+add_qt_executable(sqlwidgetmapper
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/sqlwidgetmapper"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/sqlwidgetmapper"
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Sql
+ Qt::Widgets
+)
diff --git a/examples/sql/tablemodel/CMakeLists.txt b/examples/sql/tablemodel/CMakeLists.txt
new file mode 100644
index 0000000000..68644a4b3d
--- /dev/null
+++ b/examples/sql/tablemodel/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from tablemodel.pro.
+
+#####################################################################
+## tablemodel Binary:
+#####################################################################
+
+add_qt_executable(tablemodel
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/tablemodel"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/sql/tablemodel"
+ SOURCES
+ ../connection.h
+ tablemodel.cpp
+ LIBRARIES
+ Qt::Sql
+ Qt::Widgets
+)
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..0af95adcf8
--- /dev/null
+++ b/examples/widgets/animation/animatedtiles/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from animatedtiles.pro.
+
+#####################################################################
+## animatedtiles Binary:
+#####################################################################
+
+add_qt_executable(animatedtiles
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/animation/animatedtiles"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/animation/animatedtiles"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(animatedtiles "animatedtiles" FILES
+ images/Time-For-Lunch-2.jpg
+ images/centered.png
+ images/ellipse.png
+ images/figure8.png
+ images/kinetic.png
+ images/random.png
+ images/tile.png)
+
diff --git a/examples/widgets/animation/easing/CMakeLists.txt b/examples/widgets/animation/easing/CMakeLists.txt
new file mode 100644
index 0000000000..ba391d082b
--- /dev/null
+++ b/examples/widgets/animation/easing/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from easing.pro.
+
+#####################################################################
+## easing Binary:
+#####################################################################
+
+add_qt_executable(easing
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/animation/easing"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/animation/easing"
+ SOURCES
+ animation.h
+ form.ui
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(easing "easing" FILES
+ images/qt-logo.png)
+
diff --git a/examples/widgets/animation/moveblocks/CMakeLists.txt b/examples/widgets/animation/moveblocks/CMakeLists.txt
new file mode 100644
index 0000000000..5cbb8f4936
--- /dev/null
+++ b/examples/widgets/animation/moveblocks/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from moveblocks.pro.
+
+#####################################################################
+## moveblocks Binary:
+#####################################################################
+
+add_qt_executable(moveblocks
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/animation/moveblocks"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/animation/moveblocks"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/animation/states/CMakeLists.txt b/examples/widgets/animation/states/CMakeLists.txt
new file mode 100644
index 0000000000..52a9357789
--- /dev/null
+++ b/examples/widgets/animation/states/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from states.pro.
+
+#####################################################################
+## states Binary:
+#####################################################################
+
+add_qt_executable(states
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/animation/states"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/animation/states"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(states "states" FILES
+ accessories-dictionary.png
+ akregator.png
+ digikam.png
+ help-browser.png
+ k3b.png
+ kchart.png)
+
diff --git a/examples/widgets/animation/stickman/CMakeLists.txt b/examples/widgets/animation/stickman/CMakeLists.txt
new file mode 100644
index 0000000000..f604598232
--- /dev/null
+++ b/examples/widgets/animation/stickman/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from stickman.pro.
+
+#####################################################################
+## stickman Binary:
+#####################################################################
+
+add_qt_executable(stickman
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/animation/stickman"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/animation/stickman"
+ SOURCES
+ 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
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(stickman "stickman" FILES
+ animations/chilling.bin
+ animations/dancing.bin
+ animations/dead.bin
+ animations/jumping.bin)
+
diff --git a/examples/widgets/animation/sub-attaq/CMakeLists.txt b/examples/widgets/animation/sub-attaq/CMakeLists.txt
new file mode 100644
index 0000000000..e7cb602e19
--- /dev/null
+++ b/examples/widgets/animation/sub-attaq/CMakeLists.txt
@@ -0,0 +1,142 @@
+# Generated from sub-attaq.pro.
+
+#####################################################################
+## sub-attaq Binary:
+#####################################################################
+
+add_qt_executable(sub-attaq
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/animation/sub-attaq"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/animation/sub-attaq"
+ SOURCES
+ 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
+ submarine.cpp submarine.h submarine_p.h
+ textinformationitem.cpp textinformationitem.h
+ torpedo.cpp torpedo.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+set_source_files_properties("pics/big/background.png"
+ PROPERTIES alias "big/background")
+set_source_files_properties("pics/big/boat.png"
+ PROPERTIES alias "big/boat")
+set_source_files_properties("pics/big/bomb.png"
+ PROPERTIES alias "big/bomb")
+set_source_files_properties("pics/big/explosion/boat/step1.png"
+ PROPERTIES alias "big/explosion/boat/step1")
+set_source_files_properties("pics/big/explosion/boat/step2.png"
+ PROPERTIES alias "big/explosion/boat/step2")
+set_source_files_properties("pics/big/explosion/boat/step3.png"
+ PROPERTIES alias "big/explosion/boat/step3")
+set_source_files_properties("pics/big/explosion/boat/step4.png"
+ PROPERTIES alias "big/explosion/boat/step4")
+set_source_files_properties("pics/big/explosion/submarine/step1.png"
+ PROPERTIES alias "big/explosion/submarine/step1")
+set_source_files_properties("pics/big/explosion/submarine/step2.png"
+ PROPERTIES alias "big/explosion/submarine/step2")
+set_source_files_properties("pics/big/explosion/submarine/step3.png"
+ PROPERTIES alias "big/explosion/submarine/step3")
+set_source_files_properties("pics/big/explosion/submarine/step4.png"
+ PROPERTIES alias "big/explosion/submarine/step4")
+set_source_files_properties("pics/big/submarine.png"
+ PROPERTIES alias "big/submarine")
+set_source_files_properties("pics/big/surface.png"
+ PROPERTIES alias "big/surface")
+set_source_files_properties("pics/big/torpedo.png"
+ PROPERTIES alias "big/torpedo")
+set_source_files_properties("pics/scalable/boat.svg"
+ PROPERTIES alias "boat")
+set_source_files_properties("pics/scalable/sub-attaq.svg"
+ PROPERTIES alias "all")
+set_source_files_properties("pics/scalable/submarine.svg"
+ PROPERTIES alias "submarine")
+set_source_files_properties("pics/scalable/torpedo.svg"
+ PROPERTIES alias "torpedo")
+set_source_files_properties("pics/small/background.png"
+ PROPERTIES alias "small/background")
+set_source_files_properties("pics/small/boat.png"
+ PROPERTIES alias "small/boat")
+set_source_files_properties("pics/small/bomb.png"
+ PROPERTIES alias "small/bomb")
+set_source_files_properties("pics/small/submarine.png"
+ PROPERTIES alias "small/submarine")
+set_source_files_properties("pics/small/surface.png"
+ PROPERTIES alias "small/surface")
+set_source_files_properties("pics/small/torpedo.png"
+ PROPERTIES alias "small/torpedo")
+set_source_files_properties("pics/welcome/logo-a.png"
+ PROPERTIES alias "logo-a")
+set_source_files_properties("pics/welcome/logo-a2.png"
+ PROPERTIES alias "logo-a2")
+set_source_files_properties("pics/welcome/logo-b.png"
+ PROPERTIES alias "logo-b")
+set_source_files_properties("pics/welcome/logo-dash.png"
+ PROPERTIES alias "logo-dash")
+set_source_files_properties("pics/welcome/logo-excl.png"
+ PROPERTIES alias "logo-excl")
+set_source_files_properties("pics/welcome/logo-q.png"
+ PROPERTIES alias "logo-q")
+set_source_files_properties("pics/welcome/logo-s.png"
+ PROPERTIES alias "logo-s")
+set_source_files_properties("pics/welcome/logo-t.png"
+ PROPERTIES alias "logo-t")
+set_source_files_properties("pics/welcome/logo-t2.png"
+ PROPERTIES alias "logo-t2")
+set_source_files_properties("pics/welcome/logo-u.png"
+ PROPERTIES alias "logo-u")
+add_qt_resource(sub-attaq "subattaq" PREFIX "/" FILES
+ data.xml
+ pics/big/background.png
+ pics/big/boat.png
+ pics/big/bomb.png
+ pics/big/explosion/boat/step1.png
+ pics/big/explosion/boat/step2.png
+ pics/big/explosion/boat/step3.png
+ pics/big/explosion/boat/step4.png
+ pics/big/explosion/submarine/step1.png
+ pics/big/explosion/submarine/step2.png
+ pics/big/explosion/submarine/step3.png
+ pics/big/explosion/submarine/step4.png
+ pics/big/submarine.png
+ pics/big/surface.png
+ pics/big/torpedo.png
+ pics/scalable/boat.svg
+ pics/scalable/sub-attaq.svg
+ pics/scalable/submarine.svg
+ pics/scalable/torpedo.svg
+ pics/small/background.png
+ pics/small/boat.png
+ pics/small/bomb.png
+ pics/small/submarine.png
+ pics/small/surface.png
+ pics/small/torpedo.png
+ pics/welcome/logo-a.png
+ pics/welcome/logo-a2.png
+ pics/welcome/logo-b.png
+ pics/welcome/logo-dash.png
+ pics/welcome/logo-excl.png
+ pics/welcome/logo-q.png
+ pics/welcome/logo-s.png
+ pics/welcome/logo-t.png
+ pics/welcome/logo-t2.png
+ pics/welcome/logo-u.png)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(sub-attaq CONDITION TARGET Qt::OpenGL
+ LIBRARIES
+ Qt::OpenGL
+)
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..1956e3800e
--- /dev/null
+++ b/examples/widgets/desktop/screenshot/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from screenshot.pro.
+
+#####################################################################
+## screenshot Binary:
+#####################################################################
+
+add_qt_executable(screenshot
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/desktop/screenshot"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/desktop/screenshot"
+ SOURCES
+ main.cpp
+ screenshot.cpp screenshot.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/desktop/systray/CMakeLists.txt b/examples/widgets/desktop/systray/CMakeLists.txt
new file mode 100644
index 0000000000..9f5d05e751
--- /dev/null
+++ b/examples/widgets/desktop/systray/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from systray.pro.
+
+#####################################################################
+## systray Binary:
+#####################################################################
+
+add_qt_executable(systray
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/desktop/systray"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/desktop/systray"
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(systray "systray" PREFIX "/" FILES
+ images/bad.png
+ images/heart.png
+ images/trash.png)
+
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..6d1cf9bab8
--- /dev/null
+++ b/examples/widgets/dialogs/classwizard/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from classwizard.pro.
+
+#####################################################################
+## classwizard Binary:
+#####################################################################
+
+add_qt_executable(classwizard
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/classwizard"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/classwizard"
+ SOURCES
+ classwizard.cpp classwizard.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(classwizard "classwizard" FILES
+ images/background.png
+ images/banner.png
+ images/logo1.png
+ images/logo2.png
+ images/logo3.png
+ images/watermark1.png
+ images/watermark2.png)
+
diff --git a/examples/widgets/dialogs/extension/CMakeLists.txt b/examples/widgets/dialogs/extension/CMakeLists.txt
new file mode 100644
index 0000000000..400cf23989
--- /dev/null
+++ b/examples/widgets/dialogs/extension/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from extension.pro.
+
+#####################################################################
+## extension Binary:
+#####################################################################
+
+add_qt_executable(extension
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/extension"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/extension"
+ SOURCES
+ finddialog.cpp finddialog.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/dialogs/findfiles/CMakeLists.txt b/examples/widgets/dialogs/findfiles/CMakeLists.txt
new file mode 100644
index 0000000000..26442a71b1
--- /dev/null
+++ b/examples/widgets/dialogs/findfiles/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from findfiles.pro.
+
+#####################################################################
+## findfiles Binary:
+#####################################################################
+
+add_qt_executable(findfiles
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/findfiles"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/findfiles"
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/dialogs/licensewizard/CMakeLists.txt b/examples/widgets/dialogs/licensewizard/CMakeLists.txt
new file mode 100644
index 0000000000..78b8cb7f51
--- /dev/null
+++ b/examples/widgets/dialogs/licensewizard/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from licensewizard.pro.
+
+#####################################################################
+## licensewizard Binary:
+#####################################################################
+
+add_qt_executable(licensewizard
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/licensewizard"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/licensewizard"
+ SOURCES
+ licensewizard.cpp licensewizard.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::PrintSupport
+)
+
+# Resources:
+add_qt_resource(licensewizard "licensewizard" FILES
+ images/logo.png
+ images/watermark.png)
+
diff --git a/examples/widgets/dialogs/standarddialogs/CMakeLists.txt b/examples/widgets/dialogs/standarddialogs/CMakeLists.txt
new file mode 100644
index 0000000000..3c0ddc0199
--- /dev/null
+++ b/examples/widgets/dialogs/standarddialogs/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from standarddialogs.pro.
+
+#####################################################################
+## standarddialogs Binary:
+#####################################################################
+
+add_qt_executable(standarddialogs
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/standarddialogs"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/standarddialogs"
+ SOURCES
+ dialog.cpp dialog.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/dialogs/tabdialog/CMakeLists.txt b/examples/widgets/dialogs/tabdialog/CMakeLists.txt
new file mode 100644
index 0000000000..a8cbbb4b4e
--- /dev/null
+++ b/examples/widgets/dialogs/tabdialog/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from tabdialog.pro.
+
+#####################################################################
+## tabdialog Binary:
+#####################################################################
+
+add_qt_executable(tabdialog
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/tabdialog"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/tabdialog"
+ SOURCES
+ main.cpp
+ tabdialog.cpp tabdialog.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/dialogs/trivialwizard/CMakeLists.txt b/examples/widgets/dialogs/trivialwizard/CMakeLists.txt
new file mode 100644
index 0000000000..2deae77c0d
--- /dev/null
+++ b/examples/widgets/dialogs/trivialwizard/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from trivialwizard.pro.
+
+#####################################################################
+## trivialwizard Binary:
+#####################################################################
+
+add_qt_executable(trivialwizard
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/trivialwizard"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/dialogs/trivialwizard"
+ SOURCES
+ trivialwizard.cpp
+ LIBRARIES
+ Qt::Widgets
+)
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..62a7be0cef
--- /dev/null
+++ b/examples/widgets/draganddrop/draggableicons/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from draggableicons.pro.
+
+#####################################################################
+## draggableicons Binary:
+#####################################################################
+
+add_qt_executable(draggableicons
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/draggableicons"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/draggableicons"
+ SOURCES
+ dragwidget.cpp dragwidget.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(draggableicons "draggableicons" FILES
+ images/boat.png
+ images/car.png
+ images/house.png)
+
diff --git a/examples/widgets/draganddrop/draggabletext/CMakeLists.txt b/examples/widgets/draganddrop/draggabletext/CMakeLists.txt
new file mode 100644
index 0000000000..96ec5feff6
--- /dev/null
+++ b/examples/widgets/draganddrop/draggabletext/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from draggabletext.pro.
+
+#####################################################################
+## draggabletext Binary:
+#####################################################################
+
+add_qt_executable(draggabletext
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/draggabletext"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/draggabletext"
+ SOURCES
+ dragwidget.cpp dragwidget.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(draggabletext "draggabletext" PREFIX "/dictionary" FILES
+ words.txt)
+
diff --git a/examples/widgets/draganddrop/dropsite/CMakeLists.txt b/examples/widgets/draganddrop/dropsite/CMakeLists.txt
new file mode 100644
index 0000000000..0d54133750
--- /dev/null
+++ b/examples/widgets/draganddrop/dropsite/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from dropsite.pro.
+
+#####################################################################
+## dropsite Binary:
+#####################################################################
+
+add_qt_executable(dropsite
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/dropsite"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/dropsite"
+ SOURCES
+ droparea.cpp droparea.h
+ dropsitewindow.cpp dropsitewindow.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt b/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt
new file mode 100644
index 0000000000..fcd7f3da15
--- /dev/null
+++ b/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from fridgemagnets.pro.
+
+#####################################################################
+## fridgemagnets Binary:
+#####################################################################
+
+add_qt_executable(fridgemagnets
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/fridgemagnets"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/fridgemagnets"
+ SOURCES
+ draglabel.cpp draglabel.h
+ dragwidget.cpp dragwidget.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(fridgemagnets "fridgemagnets" PREFIX "/dictionary" FILES
+ words.txt)
+
diff --git a/examples/widgets/draganddrop/puzzle/CMakeLists.txt b/examples/widgets/draganddrop/puzzle/CMakeLists.txt
new file mode 100644
index 0000000000..2622dd068e
--- /dev/null
+++ b/examples/widgets/draganddrop/puzzle/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from puzzle.pro.
+
+#####################################################################
+## puzzle Binary:
+#####################################################################
+
+add_qt_executable(puzzle
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/puzzle"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/puzzle"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ pieceslist.cpp pieceslist.h
+ puzzlewidget.cpp puzzlewidget.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(puzzle "puzzle" PREFIX "/images" FILES
+ example.jpg)
+
+
+#### Keys ignored in scope 1:.:puzzle.pro:<NONE>:
+# QMAKE_PROJECT_NAME = "dndpuzzle"
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..f534c47102
--- /dev/null
+++ b/examples/widgets/effects/blurpicker/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from blurpicker.pro.
+
+#####################################################################
+## blurpicker Binary:
+#####################################################################
+
+add_qt_executable(blurpicker
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/effects/blurpicker"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/effects/blurpicker"
+ SOURCES
+ blureffect.cpp blureffect.h
+ blurpicker.cpp blurpicker.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(blurpicker "blurpicker" PREFIX "/" FILES
+ images/accessories-calculator.png
+ images/accessories-text-editor.png
+ images/background.jpg
+ images/help-browser.png
+ images/internet-group-chat.png
+ images/internet-mail.png
+ images/internet-web-browser.png
+ images/office-calendar.png
+ images/system-users.png)
+
diff --git a/examples/widgets/effects/fademessage/CMakeLists.txt b/examples/widgets/effects/fademessage/CMakeLists.txt
new file mode 100644
index 0000000000..838a10022e
--- /dev/null
+++ b/examples/widgets/effects/fademessage/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from fademessage.pro.
+
+#####################################################################
+## fademessage Binary:
+#####################################################################
+
+add_qt_executable(fademessage
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/effects/fademessage"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/effects/fademessage"
+ SOURCES
+ fademessage.cpp fademessage.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(fademessage "fademessage" PREFIX "/" FILES
+ background.jpg)
+
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..4862654314
--- /dev/null
+++ b/examples/widgets/gestures/imagegestures/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from imagegestures.pro.
+
+#####################################################################
+## imagegestures Binary:
+#####################################################################
+
+add_qt_executable(imagegestures
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/gestures/imagegestures"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/gestures/imagegestures"
+ SOURCES
+ imagewidget.cpp imagewidget.h
+ main.cpp
+ mainwidget.cpp mainwidget.h
+ LIBRARIES
+ Qt::Widgets
+)
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..8149f96784
--- /dev/null
+++ b/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from anchorlayout.pro.
+
+#####################################################################
+## anchorlayout Binary:
+#####################################################################
+
+add_qt_executable(anchorlayout
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/anchorlayout"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/anchorlayout"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt b/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt
new file mode 100644
index 0000000000..d285a35ecc
--- /dev/null
+++ b/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from basicgraphicslayouts.pro.
+
+#####################################################################
+## basicgraphicslayouts Binary:
+#####################################################################
+
+add_qt_executable(basicgraphicslayouts
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/basicgraphicslayouts"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/basicgraphicslayouts"
+ SOURCES
+ layoutitem.cpp layoutitem.h
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(basicgraphicslayouts "basicgraphicslayouts" FILES
+ images/block.png)
+
diff --git a/examples/widgets/graphicsview/boxes/CMakeLists.txt b/examples/widgets/graphicsview/boxes/CMakeLists.txt
new file mode 100644
index 0000000000..10ff8b5b47
--- /dev/null
+++ b/examples/widgets/graphicsview/boxes/CMakeLists.txt
@@ -0,0 +1,55 @@
+# Generated from boxes.pro.
+
+find_package(WrapOpenGL)
+
+#####################################################################
+## boxes Binary:
+#####################################################################
+
+add_qt_executable(boxes
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/boxes"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/boxes"
+ SOURCES
+ 3rdparty/fbm.c 3rdparty/fbm.h
+ 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
+ LIBRARIES
+ Qt::OpenGL
+ Qt::Widgets
+ WrapOpenGL
+)
+
+# Resources:
+add_qt_resource(boxes "boxes" PREFIX "/res/boxes" FILES
+ basic.fsh
+ basic.vsh
+ cubemap_negx.jpg
+ cubemap_negy.jpg
+ cubemap_negz.jpg
+ cubemap_posx.jpg
+ cubemap_posy.jpg
+ cubemap_posz.jpg
+ dotted.fsh
+ fresnel.fsh
+ glass.fsh
+ granite.fsh
+ marble.fsh
+ parameters.par
+ qt-logo.jpg
+ qt-logo.png
+ reflection.fsh
+ refraction.fsh
+ smiley.png
+ square.jpg
+ wood.fsh)
+
+
+## Scopes:
+#####################################################################
diff --git a/examples/widgets/graphicsview/chip/CMakeLists.txt b/examples/widgets/graphicsview/chip/CMakeLists.txt
new file mode 100644
index 0000000000..566a8aae02
--- /dev/null
+++ b/examples/widgets/graphicsview/chip/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from chip.pro.
+
+#####################################################################
+## chip Binary:
+#####################################################################
+
+add_qt_executable(chip
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/chip"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/chip"
+ SOURCES
+ chip.cpp chip.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ view.cpp view.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(chip "images" FILES
+ fileprint.png
+ qt4logo.png
+ rotateleft.png
+ rotateright.png
+ zoomin.png
+ zoomout.png)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(chip CONDITION TARGET Qt::PrintSupport
+ LIBRARIES
+ Qt::PrintSupport
+)
+
+extend_target(chip CONDITION TARGET Qt::OpenGL
+ LIBRARIES
+ Qt::OpenGL
+)
+
+#### Keys ignored in scope 4:.:chip.pro:build_all AND NOT build_pass:
+# CONFIG = "-build_all" "release"
diff --git a/examples/widgets/graphicsview/collidingmice/CMakeLists.txt b/examples/widgets/graphicsview/collidingmice/CMakeLists.txt
new file mode 100644
index 0000000000..5455bec89e
--- /dev/null
+++ b/examples/widgets/graphicsview/collidingmice/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from collidingmice.pro.
+
+#####################################################################
+## collidingmice Binary:
+#####################################################################
+
+add_qt_executable(collidingmice
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/collidingmice"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/collidingmice"
+ SOURCES
+ main.cpp
+ mouse.cpp mouse.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(collidingmice "mice" PREFIX "/" FILES
+ images/cheese.jpg)
+
diff --git a/examples/widgets/graphicsview/diagramscene/CMakeLists.txt b/examples/widgets/graphicsview/diagramscene/CMakeLists.txt
new file mode 100644
index 0000000000..fb3ff6c712
--- /dev/null
+++ b/examples/widgets/graphicsview/diagramscene/CMakeLists.txt
@@ -0,0 +1,39 @@
+# Generated from diagramscene.pro.
+
+#####################################################################
+## diagramscene Binary:
+#####################################################################
+
+add_qt_executable(diagramscene
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/diagramscene"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/diagramscene"
+ SOURCES
+ arrow.cpp arrow.h
+ diagramitem.cpp diagramitem.h
+ diagramscene.cpp diagramscene.h
+ diagramtextitem.cpp diagramtextitem.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(diagramscene "diagramscene" FILES
+ images/background1.png
+ images/background2.png
+ images/background3.png
+ images/background4.png
+ images/bold.png
+ images/bringtofront.png
+ images/delete.png
+ images/floodfill.png
+ images/italic.png
+ images/linecolor.png
+ images/linepointer.png
+ images/pointer.png
+ images/sendtoback.png
+ images/textpointer.png
+ images/underline.png)
+
diff --git a/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt b/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt
new file mode 100644
index 0000000000..76932368e8
--- /dev/null
+++ b/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from dragdroprobot.pro.
+
+#####################################################################
+## dragdroprobot Binary:
+#####################################################################
+
+add_qt_executable(dragdroprobot
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/dragdroprobot"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/dragdroprobot"
+ SOURCES
+ coloritem.cpp coloritem.h
+ main.cpp
+ robot.cpp robot.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(dragdroprobot "robot" PREFIX "/" FILES
+ images/head.png)
+
diff --git a/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt b/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt
new file mode 100644
index 0000000000..d1c10327b0
--- /dev/null
+++ b/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from elasticnodes.pro.
+
+#####################################################################
+## elasticnodes Binary:
+#####################################################################
+
+add_qt_executable(elasticnodes
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/elasticnodes"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/elasticnodes"
+ SOURCES
+ edge.cpp edge.h
+ graphwidget.cpp graphwidget.h
+ main.cpp
+ node.cpp node.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt b/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt
new file mode 100644
index 0000000000..d31e15102e
--- /dev/null
+++ b/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from embeddeddialogs.pro.
+
+#####################################################################
+## embeddeddialogs Binary:
+#####################################################################
+
+add_qt_executable(embeddeddialogs
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/embeddeddialogs"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/embeddeddialogs"
+ SOURCES
+ customproxy.cpp customproxy.h
+ embeddeddialog.cpp embeddeddialog.h embeddeddialog.ui
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(embeddeddialogs "embeddeddialogs" FILES
+ No-Ones-Laughing-3.jpg)
+
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:embeddeddialogs.pro:build_all AND NOT build_pass:
+# CONFIG = "-build_all" "release"
diff --git a/examples/widgets/graphicsview/flowlayout/CMakeLists.txt b/examples/widgets/graphicsview/flowlayout/CMakeLists.txt
new file mode 100644
index 0000000000..2d313ff700
--- /dev/null
+++ b/examples/widgets/graphicsview/flowlayout/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from flowlayout.pro.
+
+#####################################################################
+## flowlayout Binary:
+#####################################################################
+
+add_qt_executable(flowlayout
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/flowlayout"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/flowlayout"
+ SOURCES
+ flowlayout.cpp flowlayout.h
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:flowlayout.pro:<NONE>:
+# QMAKE_PROJECT_NAME = "flowlayout_graphicsview"
diff --git a/examples/widgets/graphicsview/padnavigator/CMakeLists.txt b/examples/widgets/graphicsview/padnavigator/CMakeLists.txt
new file mode 100644
index 0000000000..ad879d3a8b
--- /dev/null
+++ b/examples/widgets/graphicsview/padnavigator/CMakeLists.txt
@@ -0,0 +1,43 @@
+# 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
+ LIBRARIES
+ Qt::Widgets
+)
+
+# 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:<NONE>:
+# CONFIG = "console"
+
+## Scopes:
+#####################################################################
+
+extend_target(padnavigator CONDITION TARGET Qt::OpenGL
+ LIBRARIES
+ Qt::OpenGL
+)
diff --git a/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt b/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt
new file mode 100644
index 0000000000..87e4742b44
--- /dev/null
+++ b/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from simpleanchorlayout.pro.
+
+#####################################################################
+## simpleanchorlayout Binary:
+#####################################################################
+
+add_qt_executable(simpleanchorlayout
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/simpleanchorlayout"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/simpleanchorlayout"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt b/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt
new file mode 100644
index 0000000000..5a20bbdb2e
--- /dev/null
+++ b/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from weatheranchorlayout.pro.
+
+#####################################################################
+## weatheranchorlayout Binary:
+#####################################################################
+
+add_qt_executable(weatheranchorlayout
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/weatheranchorlayout"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/weatheranchorlayout"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(weatheranchorlayout "weatheranchorlayout" FILES
+ images/5days.jpg
+ images/details.jpg
+ images/place.jpg
+ images/tabbar.jpg
+ images/title.jpg
+ images/weather-few-clouds.png)
+
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..cee0ef70e2
--- /dev/null
+++ b/examples/widgets/itemviews/addressbook/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from addressbook.pro.
+
+#####################################################################
+## addressbook Binary:
+#####################################################################
+
+add_qt_executable(addressbook
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/addressbook"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/addressbook"
+ SOURCES
+ adddialog.cpp adddialog.h
+ addresswidget.cpp addresswidget.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ newaddresstab.cpp newaddresstab.h
+ tablemodel.cpp tablemodel.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt b/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt
new file mode 100644
index 0000000000..6da9a73867
--- /dev/null
+++ b/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from basicsortfiltermodel.pro.
+
+#####################################################################
+## basicsortfiltermodel Binary:
+#####################################################################
+
+add_qt_executable(basicsortfiltermodel
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/basicsortfiltermodel"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/basicsortfiltermodel"
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/itemviews/chart/CMakeLists.txt b/examples/widgets/itemviews/chart/CMakeLists.txt
new file mode 100644
index 0000000000..9d707d1ec6
--- /dev/null
+++ b/examples/widgets/itemviews/chart/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from chart.pro.
+
+#####################################################################
+## chart Binary:
+#####################################################################
+
+add_qt_executable(chart
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/chart"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/chart"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ pieview.cpp pieview.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(chart "chart" PREFIX "/Charts" FILES
+ qtdata.cht)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(chart CONDITION UNIX AND NOT APPLE_OSX AND NOT HAIKU AND NOT INTEGRITY AND NOT VXWORKS
+ LIBRARIES
+ m
+)
diff --git a/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt b/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt
new file mode 100644
index 0000000000..317489e6e2
--- /dev/null
+++ b/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from coloreditorfactory.pro.
+
+#####################################################################
+## coloreditorfactory Binary:
+#####################################################################
+
+add_qt_executable(coloreditorfactory
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/coloreditorfactory"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/coloreditorfactory"
+ SOURCES
+ colorlisteditor.cpp colorlisteditor.h
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt b/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt
new file mode 100644
index 0000000000..326df33ba2
--- /dev/null
+++ b/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from combowidgetmapper.pro.
+
+#####################################################################
+## combowidgetmapper Binary:
+#####################################################################
+
+add_qt_executable(combowidgetmapper
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/combowidgetmapper"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/combowidgetmapper"
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt b/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt
new file mode 100644
index 0000000000..6cbfa84ae1
--- /dev/null
+++ b/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from customsortfiltermodel.pro.
+
+#####################################################################
+## customsortfiltermodel Binary:
+#####################################################################
+
+add_qt_executable(customsortfiltermodel
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/customsortfiltermodel"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/customsortfiltermodel"
+ SOURCES
+ filterwidget.cpp filterwidget.h
+ main.cpp
+ mysortfilterproxymodel.cpp mysortfilterproxymodel.h
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(customsortfiltermodel "customsortfiltermodel" PREFIX "/" FILES
+ images/find.png)
+
diff --git a/examples/widgets/itemviews/dirview/CMakeLists.txt b/examples/widgets/itemviews/dirview/CMakeLists.txt
new file mode 100644
index 0000000000..5ad3455249
--- /dev/null
+++ b/examples/widgets/itemviews/dirview/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from dirview.pro.
+
+#####################################################################
+## dirview Binary:
+#####################################################################
+
+add_qt_executable(dirview
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/dirview"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/dirview"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt b/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt
new file mode 100644
index 0000000000..699dfb1733
--- /dev/null
+++ b/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from editabletreemodel.pro.
+
+#####################################################################
+## editabletreemodel Binary:
+#####################################################################
+
+add_qt_executable(editabletreemodel
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/editabletreemodel"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/editabletreemodel"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ treeitem.cpp treeitem.h
+ treemodel.cpp treemodel.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(editabletreemodel "editabletreemodel" PREFIX "/" FILES
+ default.txt)
+
diff --git a/examples/widgets/itemviews/fetchmore/CMakeLists.txt b/examples/widgets/itemviews/fetchmore/CMakeLists.txt
new file mode 100644
index 0000000000..d3f2578302
--- /dev/null
+++ b/examples/widgets/itemviews/fetchmore/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from fetchmore.pro.
+
+#####################################################################
+## fetchmore Binary:
+#####################################################################
+
+add_qt_executable(fetchmore
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/fetchmore"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/fetchmore"
+ SOURCES
+ filelistmodel.cpp filelistmodel.h
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/itemviews/flattreeview/CMakeLists.txt b/examples/widgets/itemviews/flattreeview/CMakeLists.txt
new file mode 100644
index 0000000000..c8bffce970
--- /dev/null
+++ b/examples/widgets/itemviews/flattreeview/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from flattreeview.pro.
+
+#####################################################################
+## flattreeview Binary:
+#####################################################################
+
+add_qt_executable(flattreeview
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/flattreeview"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/flattreeview"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/itemviews/frozencolumn/CMakeLists.txt b/examples/widgets/itemviews/frozencolumn/CMakeLists.txt
new file mode 100644
index 0000000000..11e8a1e471
--- /dev/null
+++ b/examples/widgets/itemviews/frozencolumn/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from frozencolumn.pro.
+
+#####################################################################
+## frozencolumn Binary:
+#####################################################################
+
+add_qt_executable(frozencolumn
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/frozencolumn"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/frozencolumn"
+ SOURCES
+ freezetablewidget.cpp freezetablewidget.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(frozencolumn "grades" PREFIX "/" FILES
+ grades.txt)
+
diff --git a/examples/widgets/itemviews/interview/CMakeLists.txt b/examples/widgets/itemviews/interview/CMakeLists.txt
new file mode 100644
index 0000000000..d970348bc6
--- /dev/null
+++ b/examples/widgets/itemviews/interview/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from interview.pro.
+
+#####################################################################
+## interview Binary:
+#####################################################################
+
+add_qt_executable(interview
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/interview"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/interview"
+ SOURCES
+ main.cpp
+ model.cpp model.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(interview "interview" PREFIX "/" FILES
+ images/folder.png
+ images/interview.png
+ images/services.png)
+
+
+#### Keys ignored in scope 1:.:interview.pro:<NONE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:interview.pro:build_all AND NOT build_pass:
+# CONFIG = "-build_all" "release"
diff --git a/examples/widgets/itemviews/pixelator/CMakeLists.txt b/examples/widgets/itemviews/pixelator/CMakeLists.txt
new file mode 100644
index 0000000000..fc29cde3b1
--- /dev/null
+++ b/examples/widgets/itemviews/pixelator/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from pixelator.pro.
+
+#####################################################################
+## pixelator Binary:
+#####################################################################
+
+add_qt_executable(pixelator
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/pixelator"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/pixelator"
+ SOURCES
+ imagemodel.cpp imagemodel.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ pixeldelegate.cpp pixeldelegate.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(pixelator "images" FILES
+ images/qt.png)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(pixelator CONDITION TARGET Qt::PrintSupport
+ LIBRARIES
+ Qt::PrintSupport
+)
diff --git a/examples/widgets/itemviews/puzzle/CMakeLists.txt b/examples/widgets/itemviews/puzzle/CMakeLists.txt
new file mode 100644
index 0000000000..a105278418
--- /dev/null
+++ b/examples/widgets/itemviews/puzzle/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from puzzle.pro.
+
+#####################################################################
+## puzzle Binary:
+#####################################################################
+
+add_qt_executable(puzzle_itemview # special case
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/puzzle"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/puzzle"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ piecesmodel.cpp piecesmodel.h
+ puzzlewidget.cpp puzzlewidget.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(puzzle_itemview "puzzle" PREFIX "/images" FILES # special case
+ example.jpg)
+
diff --git a/examples/widgets/itemviews/simpledommodel/CMakeLists.txt b/examples/widgets/itemviews/simpledommodel/CMakeLists.txt
new file mode 100644
index 0000000000..2514287049
--- /dev/null
+++ b/examples/widgets/itemviews/simpledommodel/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from simpledommodel.pro.
+
+#####################################################################
+## simpledommodel Binary:
+#####################################################################
+
+add_qt_executable(simpledommodel
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/simpledommodel"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/simpledommodel"
+ SOURCES
+ domitem.cpp domitem.h
+ dommodel.cpp dommodel.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Xml
+ Qt::Widgets
+)
diff --git a/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt b/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt
new file mode 100644
index 0000000000..1b50a3508c
--- /dev/null
+++ b/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from simpletreemodel.pro.
+
+#####################################################################
+## simpletreemodel Binary:
+#####################################################################
+
+add_qt_executable(simpletreemodel
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/simpletreemodel"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/simpletreemodel"
+ SOURCES
+ main.cpp
+ treeitem.cpp treeitem.h
+ treemodel.cpp treemodel.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(simpletreemodel "simpletreemodel" FILES
+ default.txt)
+
diff --git a/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt b/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt
new file mode 100644
index 0000000000..849f7e2969
--- /dev/null
+++ b/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from simplewidgetmapper.pro.
+
+#####################################################################
+## simplewidgetmapper Binary:
+#####################################################################
+
+add_qt_executable(simplewidgetmapper
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/simplewidgetmapper"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/simplewidgetmapper"
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt b/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt
new file mode 100644
index 0000000000..b8c24f591c
--- /dev/null
+++ b/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from spinboxdelegate.pro.
+
+#####################################################################
+## spinboxdelegate Binary:
+#####################################################################
+
+add_qt_executable(spinboxdelegate
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/spinboxdelegate"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/spinboxdelegate"
+ SOURCES
+ delegate.cpp delegate.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/itemviews/spreadsheet/CMakeLists.txt b/examples/widgets/itemviews/spreadsheet/CMakeLists.txt
new file mode 100644
index 0000000000..498164c1cd
--- /dev/null
+++ b/examples/widgets/itemviews/spreadsheet/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from spreadsheet.pro.
+
+#####################################################################
+## spreadsheet Binary:
+#####################################################################
+
+add_qt_executable(spreadsheet
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/spreadsheet"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/spreadsheet"
+ SOURCES
+ main.cpp
+ printview.cpp printview.h
+ spreadsheet.cpp spreadsheet.h
+ spreadsheetdelegate.cpp spreadsheetdelegate.h
+ spreadsheetitem.cpp spreadsheetitem.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(spreadsheet "spreadsheet" PREFIX "/" FILES
+ images/interview.png)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(spreadsheet CONDITION TARGET Qt::PrintSupport
+ LIBRARIES
+ Qt::PrintSupport
+)
+
+#### Keys ignored in scope 3:.:spreadsheet.pro:build_all AND NOT build_pass:
+# CONFIG = "-build_all" "release"
diff --git a/examples/widgets/itemviews/stardelegate/CMakeLists.txt b/examples/widgets/itemviews/stardelegate/CMakeLists.txt
new file mode 100644
index 0000000000..0b94a12fb6
--- /dev/null
+++ b/examples/widgets/itemviews/stardelegate/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from stardelegate.pro.
+
+#####################################################################
+## stardelegate Binary:
+#####################################################################
+
+add_qt_executable(stardelegate
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/stardelegate"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/stardelegate"
+ SOURCES
+ main.cpp
+ stardelegate.cpp stardelegate.h
+ stareditor.cpp stareditor.h
+ starrating.cpp starrating.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/itemviews/storageview/CMakeLists.txt b/examples/widgets/itemviews/storageview/CMakeLists.txt
new file mode 100644
index 0000000000..efad83e1a1
--- /dev/null
+++ b/examples/widgets/itemviews/storageview/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from storageview.pro.
+
+#####################################################################
+## storageview Binary:
+#####################################################################
+
+add_qt_executable(storageview
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/storageview"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/itemviews/storageview"
+ SOURCES
+ main.cpp
+ storagemodel.cpp storagemodel.h
+ LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:storageview.pro:<NONE>:
+# TEMPLATE = "app"
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..28ac6a48b2
--- /dev/null
+++ b/examples/widgets/layouts/basiclayouts/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from basiclayouts.pro.
+
+#####################################################################
+## basiclayouts Binary:
+#####################################################################
+
+add_qt_executable(basiclayouts
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/layouts/basiclayouts"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/layouts/basiclayouts"
+ SOURCES
+ dialog.cpp dialog.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/layouts/borderlayout/CMakeLists.txt b/examples/widgets/layouts/borderlayout/CMakeLists.txt
new file mode 100644
index 0000000000..72cf6002a2
--- /dev/null
+++ b/examples/widgets/layouts/borderlayout/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from borderlayout.pro.
+
+#####################################################################
+## borderlayout Binary:
+#####################################################################
+
+add_qt_executable(borderlayout
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/layouts/borderlayout"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/layouts/borderlayout"
+ SOURCES
+ borderlayout.cpp borderlayout.h
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt b/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt
new file mode 100644
index 0000000000..47f935bf68
--- /dev/null
+++ b/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from dynamiclayouts.pro.
+
+#####################################################################
+## dynamiclayouts Binary:
+#####################################################################
+
+add_qt_executable(dynamiclayouts
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/layouts/dynamiclayouts"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/layouts/dynamiclayouts"
+ SOURCES
+ dialog.cpp dialog.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/layouts/flowlayout/CMakeLists.txt b/examples/widgets/layouts/flowlayout/CMakeLists.txt
new file mode 100644
index 0000000000..a887abb93e
--- /dev/null
+++ b/examples/widgets/layouts/flowlayout/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from flowlayout.pro.
+
+#####################################################################
+## flowlayout Binary:
+#####################################################################
+
+add_qt_executable(flowlayout_layout # special case
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/layouts/flowlayout"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/layouts/flowlayout"
+ SOURCES
+ flowlayout.cpp flowlayout.h
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
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..52d1db1d9e
--- /dev/null
+++ b/examples/widgets/mac/qmaccocoaviewcontainer/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qmaccocoaviewcontainer.pro.
+
+#####################################################################
+## qmaccocoaviewcontainer Binary:
+#####################################################################
+
+add_qt_executable(qmaccocoaviewcontainer
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mac/qmaccocoaviewcontainer"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mac/qmaccocoaviewcontainer"
+ SOURCES
+ main.mm
+ LIBRARIES
+ Qt::Widgets
+ ${FWAppKit}
+)
+
+#### Keys ignored in scope 1:.:qmaccocoaviewcontainer.pro:<NONE>:
+# TEMPLATE = "app"
diff --git a/examples/widgets/mac/qmacnativewidget/CMakeLists.txt b/examples/widgets/mac/qmacnativewidget/CMakeLists.txt
new file mode 100644
index 0000000000..9708fae762
--- /dev/null
+++ b/examples/widgets/mac/qmacnativewidget/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from qmacnativewidget.pro.
+
+#####################################################################
+## qmacnativewidget Binary:
+#####################################################################
+
+add_qt_executable(qmacnativewidget
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mac/qmacnativewidget"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mac/qmacnativewidget"
+ SOURCES
+ main.mm
+ LIBRARIES
+ Qt::Widgets
+ ${FWAppKit}
+)
+
+#### Keys ignored in scope 1:.:qmacnativewidget.pro:<NONE>:
+# TEMPLATE = "app"
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..8a9bdea2c2
--- /dev/null
+++ b/examples/widgets/mainwindows/application/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from application.pro.
+
+#####################################################################
+## application Binary:
+#####################################################################
+
+add_qt_executable(application
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/application"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/application"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(application "application" FILES
+ images/copy.png
+ images/cut.png
+ images/new.png
+ images/open.png
+ images/paste.png
+ images/save.png)
+
diff --git a/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt b/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt
new file mode 100644
index 0000000000..e8fd580fd8
--- /dev/null
+++ b/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from dockwidgets.pro.
+
+#####################################################################
+## dockwidgets Binary:
+#####################################################################
+
+add_qt_executable(dockwidgets
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/dockwidgets"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/dockwidgets"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(dockwidgets "dockwidgets" FILES
+ images/new.png
+ images/print.png
+ images/save.png
+ images/undo.png)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(dockwidgets CONDITION TARGET Qt::PrintSupport
+ LIBRARIES
+ Qt::PrintSupport
+)
diff --git a/examples/widgets/mainwindows/mainwindow/CMakeLists.txt b/examples/widgets/mainwindows/mainwindow/CMakeLists.txt
new file mode 100644
index 0000000000..df1d9b6355
--- /dev/null
+++ b/examples/widgets/mainwindows/mainwindow/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from mainwindow.pro.
+
+#####################################################################
+## mainwindow Binary:
+#####################################################################
+
+add_qt_executable(mainwindow
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/mainwindow"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/mainwindow"
+ SOURCES
+ colorswatch.cpp colorswatch.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ toolbar.cpp toolbar.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(mainwindow "mainwindow" PREFIX "/res" FILES
+ qt.png
+ titlebarCenter.png
+ titlebarLeft.png
+ titlebarRight.png)
+
+
+#### Keys ignored in scope 1:.:mainwindow.pro:<NONE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:mainwindow.pro:build_all AND NOT build_pass:
+# CONFIG = "-build_all" "release"
diff --git a/examples/widgets/mainwindows/mdi/CMakeLists.txt b/examples/widgets/mainwindows/mdi/CMakeLists.txt
new file mode 100644
index 0000000000..c20acbdfca
--- /dev/null
+++ b/examples/widgets/mainwindows/mdi/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from mdi.pro.
+
+#####################################################################
+## mdi Binary:
+#####################################################################
+
+add_qt_executable(mdi
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/mdi"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/mdi"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ mdichild.cpp mdichild.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(mdi "mdi" FILES
+ images/copy.png
+ images/cut.png
+ images/new.png
+ images/open.png
+ images/paste.png
+ images/save.png)
+
diff --git a/examples/widgets/mainwindows/menus/CMakeLists.txt b/examples/widgets/mainwindows/menus/CMakeLists.txt
new file mode 100644
index 0000000000..6d7e471a8c
--- /dev/null
+++ b/examples/widgets/mainwindows/menus/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from menus.pro.
+
+#####################################################################
+## menus Binary:
+#####################################################################
+
+add_qt_executable(menus
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/menus"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/menus"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/mainwindows/sdi/CMakeLists.txt b/examples/widgets/mainwindows/sdi/CMakeLists.txt
new file mode 100644
index 0000000000..8391aa0cbc
--- /dev/null
+++ b/examples/widgets/mainwindows/sdi/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from sdi.pro.
+
+#####################################################################
+## sdi Binary:
+#####################################################################
+
+add_qt_executable(sdi
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/sdi"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/sdi"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(sdi "sdi" FILES
+ images/copy.png
+ images/cut.png
+ images/new.png
+ images/open.png
+ images/paste.png
+ images/save.png)
+
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..cda43296dd
--- /dev/null
+++ b/examples/widgets/painting/affine/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from affine.pro.
+
+#####################################################################
+## affine Binary:
+#####################################################################
+
+add_qt_executable(affine
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/affine"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/affine"
+ SOURCES
+ main.cpp
+ xform.cpp xform.h
+ # INCLUDE_DIRECTORIES ../shared # special case
+ LIBRARIES # special case
+ painting_shared
+)
+
+# Resources:
+add_qt_resource(affine "affine" PREFIX "/res/affine" FILES
+ bg1.jpg
+ xform.cpp
+ xform.html)
diff --git a/examples/widgets/painting/basicdrawing/CMakeLists.txt b/examples/widgets/painting/basicdrawing/CMakeLists.txt
new file mode 100644
index 0000000000..176149dad5
--- /dev/null
+++ b/examples/widgets/painting/basicdrawing/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from basicdrawing.pro.
+
+#####################################################################
+## basicdrawing Binary:
+#####################################################################
+
+add_qt_executable(basicdrawing
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/basicdrawing"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/basicdrawing"
+ SOURCES
+ main.cpp
+ renderarea.cpp renderarea.h
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(basicdrawing "basicdrawing" FILES
+ images/brick.png
+ images/qt-logo.png)
+
diff --git a/examples/widgets/painting/composition/CMakeLists.txt b/examples/widgets/painting/composition/CMakeLists.txt
new file mode 100644
index 0000000000..1e83bc4814
--- /dev/null
+++ b/examples/widgets/painting/composition/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from composition.pro.
+
+#####################################################################
+## composition Binary:
+#####################################################################
+
+add_qt_executable(composition
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/composition"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/composition"
+ SOURCES
+ composition.cpp composition.h
+ main.cpp
+ LIBRARIES # special case
+ painting_shared
+)
+
+# Resources:
+add_qt_resource(composition "composition" PREFIX "/res/composition" FILES
+ composition.cpp
+ composition.html
+ flower.jpg
+ flower_alpha.jpg)
diff --git a/examples/widgets/painting/concentriccircles/CMakeLists.txt b/examples/widgets/painting/concentriccircles/CMakeLists.txt
new file mode 100644
index 0000000000..a2305782a5
--- /dev/null
+++ b/examples/widgets/painting/concentriccircles/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from concentriccircles.pro.
+
+#####################################################################
+## concentriccircles Binary:
+#####################################################################
+
+add_qt_executable(concentriccircles
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/concentriccircles"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/concentriccircles"
+ SOURCES
+ circlewidget.cpp circlewidget.h
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/painting/deform/CMakeLists.txt b/examples/widgets/painting/deform/CMakeLists.txt
new file mode 100644
index 0000000000..67622da25d
--- /dev/null
+++ b/examples/widgets/painting/deform/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from deform.pro.
+
+#####################################################################
+## deform Binary:
+#####################################################################
+
+add_qt_executable(deform
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/deform"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/deform"
+ SOURCES
+ main.cpp
+ pathdeform.cpp pathdeform.h
+ LIBRARIES # special case
+ painting_shared
+)
+
+# Resources:
+add_qt_resource(deform "deform" PREFIX "/res/deform" FILES
+ pathdeform.cpp
+ pathdeform.html)
diff --git a/examples/widgets/painting/fontsampler/CMakeLists.txt b/examples/widgets/painting/fontsampler/CMakeLists.txt
new file mode 100644
index 0000000000..a32b10589f
--- /dev/null
+++ b/examples/widgets/painting/fontsampler/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from fontsampler.pro.
+
+#####################################################################
+## fontsampler Binary:
+#####################################################################
+
+add_qt_executable(fontsampler
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/fontsampler"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/fontsampler"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ mainwindowbase.ui
+ LIBRARIES
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(fontsampler CONDITION TARGET Qt::PrintSupport
+ LIBRARIES
+ Qt::PrintSupport
+)
diff --git a/examples/widgets/painting/gradients/CMakeLists.txt b/examples/widgets/painting/gradients/CMakeLists.txt
new file mode 100644
index 0000000000..0d5553b986
--- /dev/null
+++ b/examples/widgets/painting/gradients/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from gradients.pro.
+
+#####################################################################
+## gradients Binary:
+#####################################################################
+
+add_qt_executable(gradients
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/gradients"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/gradients"
+ SOURCES
+ gradients.cpp gradients.h
+ main.cpp
+ LIBRARIES # special case
+ painting_shared
+)
+
+# Resources:
+add_qt_resource(gradients "gradients" PREFIX "/res/gradients" FILES
+ gradients.cpp
+ gradients.html)
diff --git a/examples/widgets/painting/imagecomposition/CMakeLists.txt b/examples/widgets/painting/imagecomposition/CMakeLists.txt
new file mode 100644
index 0000000000..eed2bede43
--- /dev/null
+++ b/examples/widgets/painting/imagecomposition/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from imagecomposition.pro.
+
+#####################################################################
+## imagecomposition Binary:
+#####################################################################
+
+add_qt_executable(imagecomposition
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/imagecomposition"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/imagecomposition"
+ SOURCES
+ imagecomposer.cpp imagecomposer.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(imagecomposition "imagecomposition" FILES
+ images/butterfly.png
+ images/checker.png)
+
diff --git a/examples/widgets/painting/painterpaths/CMakeLists.txt b/examples/widgets/painting/painterpaths/CMakeLists.txt
new file mode 100644
index 0000000000..13dd321a52
--- /dev/null
+++ b/examples/widgets/painting/painterpaths/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from painterpaths.pro.
+
+#####################################################################
+## painterpaths Binary:
+#####################################################################
+
+add_qt_executable(painterpaths
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/painterpaths"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/painterpaths"
+ SOURCES
+ main.cpp
+ renderarea.cpp renderarea.h
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+ painting_shared # special case
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(painterpaths CONDITION UNIX AND NOT APPLE_OSX AND NOT HAIKU AND NOT INTEGRITY AND NOT VXWORKS
+ LIBRARIES
+ m
+)
diff --git a/examples/widgets/painting/pathstroke/CMakeLists.txt b/examples/widgets/painting/pathstroke/CMakeLists.txt
new file mode 100644
index 0000000000..150a1baa83
--- /dev/null
+++ b/examples/widgets/painting/pathstroke/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from pathstroke.pro.
+
+#####################################################################
+## pathstroke Binary:
+#####################################################################
+
+add_qt_executable(pathstroke
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/pathstroke"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/pathstroke"
+ SOURCES
+ main.cpp
+ pathstroke.cpp pathstroke.h
+ LIBRARIES # special case
+ painting_shared
+)
+
+# Resources:
+add_qt_resource(pathstroke "pathstroke" PREFIX "/res/pathstroke" FILES
+ pathstroke.cpp
+ pathstroke.html)
diff --git a/examples/widgets/painting/shared/CMakeLists.txt b/examples/widgets/painting/shared/CMakeLists.txt
new file mode 100644
index 0000000000..a7bec2789b
--- /dev/null
+++ b/examples/widgets/painting/shared/CMakeLists.txt
@@ -0,0 +1,64 @@
+# special case: Entire file!
+
+# special case:
+add_library(painting_shared OBJECT)
+qt_manual_moc(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}")
+
+
+# Resources:
+add_qt_resource(painting_shared "shared" PREFIX "/res" FILES
+ images/button_normal_cap_left.png
+ images/button_normal_cap_right.png
+ images/button_normal_stretch.png
+ images/button_pressed_cap_left.png
+ images/button_pressed_cap_right.png
+ images/button_pressed_stretch.png
+ images/frame_bottom.png
+ images/frame_bottomleft.png
+ images/frame_bottomright.png
+ images/frame_left.png
+ images/frame_right.png
+ images/frame_top.png
+ images/frame_topleft.png
+ images/frame_topright.png
+ images/groupframe_bottom_left.png
+ images/groupframe_bottom_right.png
+ images/groupframe_bottom_stretch.png
+ images/groupframe_left_stretch.png
+ images/groupframe_right_stretch.png
+ images/groupframe_top_stretch.png
+ images/groupframe_topleft.png
+ images/groupframe_topright.png
+ images/line_dash_dot.png
+ images/line_dash_dot_dot.png
+ images/line_dashed.png
+ images/line_dotted.png
+ images/line_solid.png
+ images/radiobutton-on.png
+ images/radiobutton_off.png
+ images/radiobutton_on.png
+ images/slider_bar.png
+ images/slider_thumb_on.png
+ images/title_cap_left.png
+ images/title_cap_right.png
+ images/title_stretch.png)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(painting_shared CONDITION TARGET Qt::OpenGL OR QT_FEATURE_opengles2
+ DEFINES
+ QT_OPENGL_SUPPORT
+ LIBRARIES
+ Qt::OpenGL
+ Qt::Widgets
+)
diff --git a/examples/widgets/painting/transformations/CMakeLists.txt b/examples/widgets/painting/transformations/CMakeLists.txt
new file mode 100644
index 0000000000..a3c3130c32
--- /dev/null
+++ b/examples/widgets/painting/transformations/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from transformations.pro.
+
+#####################################################################
+## transformations Binary:
+#####################################################################
+
+add_qt_executable(transformations
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/transformations"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/painting/transformations"
+ SOURCES
+ main.cpp
+ renderarea.cpp renderarea.h
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
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..8d26479929
--- /dev/null
+++ b/examples/widgets/richtext/calendar/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from calendar.pro.
+
+#####################################################################
+## calendar Binary:
+#####################################################################
+
+add_qt_executable(calendar
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/richtext/calendar"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/richtext/calendar"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/richtext/orderform/CMakeLists.txt b/examples/widgets/richtext/orderform/CMakeLists.txt
new file mode 100644
index 0000000000..5f12e98cdf
--- /dev/null
+++ b/examples/widgets/richtext/orderform/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from orderform.pro.
+
+#####################################################################
+## orderform Binary:
+#####################################################################
+
+add_qt_executable(orderform
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/richtext/orderform"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/richtext/orderform"
+ SOURCES
+ detailsdialog.cpp detailsdialog.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(orderform CONDITION TARGET Qt::PrintSupport
+ LIBRARIES
+ Qt::PrintSupport
+)
diff --git a/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt b/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt
new file mode 100644
index 0000000000..afffcc639b
--- /dev/null
+++ b/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from syntaxhighlighter.pro.
+
+#####################################################################
+## syntaxhighlighter Binary:
+#####################################################################
+
+add_qt_executable(syntaxhighlighter
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/richtext/syntaxhighlighter"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/richtext/syntaxhighlighter"
+ SOURCES
+ highlighter.cpp highlighter.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/richtext/textedit/CMakeLists.txt b/examples/widgets/richtext/textedit/CMakeLists.txt
new file mode 100644
index 0000000000..9166f6748a
--- /dev/null
+++ b/examples/widgets/richtext/textedit/CMakeLists.txt
@@ -0,0 +1,75 @@
+# Generated from textedit.pro.
+
+#####################################################################
+## textedit Binary:
+#####################################################################
+
+add_qt_executable(textedit
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/richtext/textedit"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/richtext/textedit"
+ SOURCES
+ main.cpp
+ textedit.cpp textedit.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(textedit "textedit" PREFIX "/" FILES
+ example.html
+ images/logo32.png
+ images/mac/editcopy.png
+ images/mac/editcut.png
+ images/mac/editpaste.png
+ images/mac/editredo.png
+ images/mac/editundo.png
+ images/mac/exportpdf.png
+ images/mac/filenew.png
+ images/mac/fileopen.png
+ images/mac/fileprint.png
+ images/mac/filesave.png
+ images/mac/textbold.png
+ images/mac/textcenter.png
+ images/mac/textitalic.png
+ images/mac/textjustify.png
+ images/mac/textleft.png
+ images/mac/textright.png
+ images/mac/textunder.png
+ images/mac/zoomin.png
+ images/mac/zoomout.png
+ images/win/editcopy.png
+ images/win/editcut.png
+ images/win/editpaste.png
+ images/win/editredo.png
+ images/win/editundo.png
+ images/win/exportpdf.png
+ images/win/filenew.png
+ images/win/fileopen.png
+ images/win/fileprint.png
+ images/win/filesave.png
+ images/win/textbold.png
+ images/win/textcenter.png
+ images/win/textitalic.png
+ images/win/textjustify.png
+ images/win/textleft.png
+ images/win/textright.png
+ images/win/textunder.png
+ images/win/zoomin.png
+ images/win/zoomout.png)
+
+
+#### Keys ignored in scope 1:.:textedit.pro:<NONE>:
+# EXAMPLE_FILES = "textedit.qdoc"
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(textedit CONDITION TARGET Qt::PrintSupport
+ LIBRARIES
+ Qt::PrintSupport
+)
+
+#### Keys ignored in scope 3:.:textedit.pro:build_all AND NOT build_pass:
+# CONFIG = "-build_all" "release"
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..0f25d6b71c
--- /dev/null
+++ b/examples/widgets/scroller/graphicsview/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from graphicsview.pro.
+
+#####################################################################
+## graphicsview Binary:
+#####################################################################
+
+add_qt_executable(graphicsview
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/scroller/graphicsview"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/scroller/graphicsview"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:graphicsview.pro:<NONE>:
+# TEMPLATE = "app"
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..0fc20f59ae
--- /dev/null
+++ b/examples/widgets/statemachine/eventtransitions/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from eventtransitions.pro.
+
+#####################################################################
+## eventtransitions Binary:
+#####################################################################
+
+add_qt_executable(eventtransitions
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/statemachine/eventtransitions"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/statemachine/eventtransitions"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/statemachine/factorial/CMakeLists.txt b/examples/widgets/statemachine/factorial/CMakeLists.txt
new file mode 100644
index 0000000000..e38995220e
--- /dev/null
+++ b/examples/widgets/statemachine/factorial/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from factorial.pro.
+
+#####################################################################
+## factorial Binary:
+#####################################################################
+
+add_qt_executable(factorial
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/statemachine/factorial"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/statemachine/factorial"
+ SOURCES
+ main.cpp
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:factorial.pro:WIN32:
+# CONFIG = "console"
+
+#### Keys ignored in scope 3:.:factorial.pro:APPLE_OSX:
+# CONFIG = "-app_bundle"
diff --git a/examples/widgets/statemachine/pingpong/CMakeLists.txt b/examples/widgets/statemachine/pingpong/CMakeLists.txt
new file mode 100644
index 0000000000..b911bd727f
--- /dev/null
+++ b/examples/widgets/statemachine/pingpong/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from pingpong.pro.
+
+#####################################################################
+## pingpong Binary:
+#####################################################################
+
+add_qt_executable(pingpong
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/statemachine/pingpong"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/statemachine/pingpong"
+ SOURCES
+ main.cpp
+)
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:pingpong.pro:WIN32:
+# CONFIG = "console"
+
+#### Keys ignored in scope 3:.:pingpong.pro:APPLE_OSX:
+# CONFIG = "-app_bundle"
diff --git a/examples/widgets/statemachine/rogue/CMakeLists.txt b/examples/widgets/statemachine/rogue/CMakeLists.txt
new file mode 100644
index 0000000000..a6a1a473e1
--- /dev/null
+++ b/examples/widgets/statemachine/rogue/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from rogue.pro.
+
+#####################################################################
+## rogue Binary:
+#####################################################################
+
+add_qt_executable(rogue
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/statemachine/rogue"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/statemachine/rogue"
+ SOURCES
+ main.cpp
+ movementtransition.h
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/statemachine/trafficlight/CMakeLists.txt b/examples/widgets/statemachine/trafficlight/CMakeLists.txt
new file mode 100644
index 0000000000..52f9fb3c6c
--- /dev/null
+++ b/examples/widgets/statemachine/trafficlight/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from trafficlight.pro.
+
+#####################################################################
+## trafficlight Binary:
+#####################################################################
+
+add_qt_executable(trafficlight
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/statemachine/trafficlight"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/statemachine/trafficlight"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/statemachine/twowaybutton/CMakeLists.txt b/examples/widgets/statemachine/twowaybutton/CMakeLists.txt
new file mode 100644
index 0000000000..c5f14b7514
--- /dev/null
+++ b/examples/widgets/statemachine/twowaybutton/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from twowaybutton.pro.
+
+#####################################################################
+## twowaybutton Binary:
+#####################################################################
+
+add_qt_executable(twowaybutton
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/statemachine/twowaybutton"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/statemachine/twowaybutton"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/tools/CMakeLists.txt b/examples/widgets/tools/CMakeLists.txt
new file mode 100644
index 0000000000..90ac6fe86f
--- /dev/null
+++ b/examples/widgets/tools/CMakeLists.txt
@@ -0,0 +1,20 @@
+# 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)
+ add_subdirectory(plugandpaint)
+endif()
diff --git a/examples/widgets/tools/codecs/CMakeLists.txt b/examples/widgets/tools/codecs/CMakeLists.txt
new file mode 100644
index 0000000000..703aa3fb47
--- /dev/null
+++ b/examples/widgets/tools/codecs/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from codecs.pro.
+
+#####################################################################
+## codecs Binary:
+#####################################################################
+
+add_qt_executable(codecs
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/codecs"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/codecs"
+ SOURCES
+ encodingdialog.cpp encodingdialog.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ previewform.cpp previewform.h
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(codecs "codecs" PREFIX "/" FILES
+ images/editcopy.png)
+
+
+#### Keys ignored in scope 1:.:.:codecs.pro:<TRUE>:
+# EXAMPLE_FILES = "encodedfiles"
diff --git a/examples/widgets/tools/completer/CMakeLists.txt b/examples/widgets/tools/completer/CMakeLists.txt
new file mode 100644
index 0000000000..b39b4f262d
--- /dev/null
+++ b/examples/widgets/tools/completer/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from completer.pro.
+
+#####################################################################
+## completer Binary:
+#####################################################################
+
+add_qt_executable(completer
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/completer"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/completer"
+ SOURCES
+ fsmodel.cpp fsmodel.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(completer "completer" PREFIX "/" FILES
+ resources/countries.txt
+ resources/wordlist.txt)
+
diff --git a/examples/widgets/tools/customcompleter/CMakeLists.txt b/examples/widgets/tools/customcompleter/CMakeLists.txt
new file mode 100644
index 0000000000..04f8035ff3
--- /dev/null
+++ b/examples/widgets/tools/customcompleter/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from customcompleter.pro.
+
+#####################################################################
+## customcompleter Binary:
+#####################################################################
+
+add_qt_executable(customcompleter
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/customcompleter"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/customcompleter"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ textedit.cpp textedit.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(customcompleter "customcompleter" PREFIX "/" FILES
+ resources/wordlist.txt)
+
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..3c9082db07
--- /dev/null
+++ b/examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt
@@ -0,0 +1,33 @@
+# Generated from echowindow.pro.
+
+#####################################################################
+## echoplugin Binary:
+#####################################################################
+
+add_qt_executable(echoplugin
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/echoplugin"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/echoplugin"
+ SOURCES
+ echointerface.h
+ echowindow.cpp echowindow.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:echowindow.pro:<NONE>:
+# CONFIG = "install_ok"
+# QMAKE_PROJECT_NAME = "echopluginwindow"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:echowindow.pro:CONFIG(debug,release OR debug):
+# DESTDIR = "../debug/"
+
+#### Keys ignored in scope 4:.:echowindow.pro:CONFIG(release,release OR debug):
+# DESTDIR = "../release/"
+
+#### Keys ignored in scope 5:.:echowindow.pro:else:
+# DESTDIR = "../"
diff --git a/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt b/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt
new file mode 100644
index 0000000000..7250a7e0a6
--- /dev/null
+++ b/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from plugin.pro.
+
+#####################################################################
+## qtLibraryTargetechoplugin Module:
+#####################################################################
+
+add_qt_plugin(echoplugin_plugin TYPE plugin # special case
+ SOURCES
+ echoplugin.cpp echoplugin.h
+ INCLUDE_DIRECTORIES
+ ../echowindow
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:plugin.pro:<NONE>:
+# CONFIG = "plugin" "install_ok"
+# DESTDIR = "../plugins"
+# EXAMPLE_FILES = "echoplugin.json"
+# INSTALLS = "target"
+# TEMPLATE = "lib"
+# target.path = "$$[QT_INSTALL_EXAMPLES]/widgets/tools/echoplugin/plugins"
diff --git a/examples/widgets/tools/i18n/CMakeLists.txt b/examples/widgets/tools/i18n/CMakeLists.txt
new file mode 100644
index 0000000000..033362bb4c
--- /dev/null
+++ b/examples/widgets/tools/i18n/CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from i18n.pro.
+
+#####################################################################
+## i18n Binary:
+#####################################################################
+
+add_qt_executable(i18n
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/i18n"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/i18n"
+ SOURCES
+ languagechooser.cpp languagechooser.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(i18n "i18n" FILES
+ translations/i18n_ar.qm
+ translations/i18n_cs.qm
+ translations/i18n_de.qm
+ translations/i18n_el.qm
+ translations/i18n_en.qm
+ translations/i18n_eo.qm
+ translations/i18n_fr.qm
+ translations/i18n_it.qm
+ translations/i18n_jp.qm
+ translations/i18n_ko.qm
+ translations/i18n_no.qm
+ translations/i18n_ru.qm
+ translations/i18n_sv.qm
+ translations/i18n_zh.qm)
+
+
+#### Keys ignored in scope 1:.:i18n.pro:<NONE>:
+# TRANSLATIONS = "translations/i18n_ar.ts" "translations/i18n_cs.ts" "translations/i18n_de.ts" "translations/i18n_el.ts" "translations/i18n_en.ts" "translations/i18n_eo.ts" "translations/i18n_fr.ts" "translations/i18n_it.ts" "translations/i18n_jp.ts" "translations/i18n_ko.ts" "translations/i18n_no.ts" "translations/i18n_ru.ts" "translations/i18n_sv.ts" "translations/i18n_zh.ts"
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..e5bbbacec2
--- /dev/null
+++ b/examples/widgets/tools/plugandpaint/app/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from app.pro.
+
+#####################################################################
+## plugandpaint Binary:
+#####################################################################
+
+add_qt_executable(plugandpaint
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/plugandpaint"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/plugandpaint"
+ SOURCES
+ interfaces.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ paintarea.cpp paintarea.h
+ plugindialog.cpp plugindialog.h
+ LIBRARIES
+ Qt::Widgets
+ pnp_basictools # special case
+)
+
+#### Keys ignored in scope 1:.:app.pro:<NONE>:
+# CONFIG = "install_ok"
+# DESTDIR = ".."
+
+## Scopes:
+#####################################################################
+
+# special case: Remove the rest
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..a059d0deab
--- /dev/null
+++ b/examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from basictools.pro.
+
+#####################################################################
+## qtLibraryTargetpnp_basictools Module:
+#####################################################################
+
+add_qt_plugin(pnp_basictools # special case
+ STATIC # special case
+ OUTPUT_DIRECTORY ../../plugins # special case
+ INSTALL_DIRECTORY ../../plugins # special case
+ ARCHIVE_INSTALL_DIRECTORY ../../plugins # special case
+ SOURCES
+ basictoolsplugin.cpp basictoolsplugin.h
+ INCLUDE_DIRECTORIES
+ ../../app
+ LIBRARIES
+ Qt::Widgets
+)
+
+# CONFIG = "plugin" "static" "install_ok"
+# DESTDIR = "../../plugins"
+# INSTALLS = "target"
+# TEMPLATE = "lib"
+# target.path = "$$[QT_INSTALL_EXAMPLES]/widgets/tools/plugandpaint/plugins"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:basictools.pro:APPLE_UIKIT:
+# CONFIG = "debug_and_release"
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..a0447c833e
--- /dev/null
+++ b/examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from extrafilters.pro.
+
+#####################################################################
+## qtLibraryTargetpnp_extrafilters Module:
+#####################################################################
+
+add_qt_plugin(pnp_extrafilters_plugin TYPE plugin # special case
+ SOURCES
+ extrafiltersplugin.cpp extrafiltersplugin.h
+ INCLUDE_DIRECTORIES
+ ../../app
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:extrafilters.pro:<NONE>:
+# CONFIG = "plugin" "install_ok"
+# DESTDIR = "../../plugins"
+# INSTALLS = "target"
+# TEMPLATE = "lib"
+# target.path = "$$[QT_INSTALL_EXAMPLES]/widgets/tools/plugandpaint/plugins"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:extrafilters.pro:APPLE_UIKIT:
+# CONFIG = "debug_and_release"
diff --git a/examples/widgets/tools/regexp/CMakeLists.txt b/examples/widgets/tools/regexp/CMakeLists.txt
new file mode 100644
index 0000000000..da729f5f5b
--- /dev/null
+++ b/examples/widgets/tools/regexp/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from regexp.pro.
+
+#####################################################################
+## regexp Binary:
+#####################################################################
+
+add_qt_executable(regexp
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/regexp"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/regexp"
+ SOURCES
+ main.cpp
+ regexpdialog.cpp regexpdialog.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/tools/regularexpression/CMakeLists.txt b/examples/widgets/tools/regularexpression/CMakeLists.txt
new file mode 100644
index 0000000000..e9dcb977a2
--- /dev/null
+++ b/examples/widgets/tools/regularexpression/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from regularexpression.pro.
+
+#####################################################################
+## regularexpression Binary:
+#####################################################################
+
+add_qt_executable(regularexpression
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/regularexpression"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/regularexpression"
+ SOURCES
+ main.cpp
+ regularexpressiondialog.cpp regularexpressiondialog.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(regularexpression "regularexpression" FILES
+ images/copy.png)
+
diff --git a/examples/widgets/tools/settingseditor/CMakeLists.txt b/examples/widgets/tools/settingseditor/CMakeLists.txt
new file mode 100644
index 0000000000..ce260da358
--- /dev/null
+++ b/examples/widgets/tools/settingseditor/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from settingseditor.pro.
+
+#####################################################################
+## settingseditor Binary:
+#####################################################################
+
+add_qt_executable(settingseditor
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/settingseditor"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/settingseditor"
+ SOURCES
+ locationdialog.cpp locationdialog.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ settingstree.cpp settingstree.h
+ variantdelegate.cpp variantdelegate.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:settingseditor.pro:<NONE>:
+# EXAMPLE_FILES = "inifiles"
diff --git a/examples/widgets/tools/styleplugin/CMakeLists.txt b/examples/widgets/tools/styleplugin/CMakeLists.txt
new file mode 100644
index 0000000000..630c3703f8
--- /dev/null
+++ b/examples/widgets/tools/styleplugin/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from styleplugin.pro.
+
+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..c311799d30
--- /dev/null
+++ b/examples/widgets/tools/styleplugin/plugin/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from plugin.pro.
+
+#####################################################################
+## mplestyleplugin Module:
+#####################################################################
+
+add_qt_plugin(simplestyleplugin TYPE style # special case
+ SOURCES
+ simplestyle.cpp simplestyle.h
+ simplestyleplugin.cpp simplestyleplugin.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:plugin.pro:<NONE>:
+# CONFIG = "plugin" "install_ok"
+# EXAMPLE_FILES = "simplestyle.json"
+# INSTALLS = "target"
+# TEMPLATE = "lib"
+# target.path = "$$[QT_INSTALL_EXAMPLES]/widgets/tools/styleplugin/styles"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:plugin.pro:CONFIG(debug,release OR debug):
+# DESTDIR = "../debug/styles/"
+
+#### Keys ignored in scope 4:.:plugin.pro:CONFIG(release,release OR debug):
+# DESTDIR = "../release/styles/"
+
+#### Keys ignored in scope 5:.:plugin.pro:else:
+# DESTDIR = "../styles/"
diff --git a/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt b/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt
new file mode 100644
index 0000000000..a6d6a56874
--- /dev/null
+++ b/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from stylewindow.pro.
+
+#####################################################################
+## styleplugin Binary:
+#####################################################################
+
+add_qt_executable(styleplugin
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/styleplugin"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/styleplugin"
+ SOURCES
+ main.cpp
+ stylewindow.cpp stylewindow.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:stylewindow.pro:<NONE>:
+# CONFIG = "install_ok"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 3:.:stylewindow.pro:debug:
+# DESTDIR = "../debug/"
+
+#### Keys ignored in scope 4:.:stylewindow.pro:release:
+# DESTDIR = "../release/"
+
+#### Keys ignored in scope 5:.:stylewindow.pro:else:
+# DESTDIR = "../"
diff --git a/examples/widgets/tools/treemodelcompleter/CMakeLists.txt b/examples/widgets/tools/treemodelcompleter/CMakeLists.txt
new file mode 100644
index 0000000000..ab4d60f290
--- /dev/null
+++ b/examples/widgets/tools/treemodelcompleter/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from treemodelcompleter.pro.
+
+#####################################################################
+## treemodelcompleter Binary:
+#####################################################################
+
+add_qt_executable(treemodelcompleter
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/treemodelcompleter"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/treemodelcompleter"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ treemodelcompleter.cpp treemodelcompleter.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(treemodelcompleter "treemodelcompleter" PREFIX "/" FILES
+ resources/treemodel.txt)
+
diff --git a/examples/widgets/tools/undo/CMakeLists.txt b/examples/widgets/tools/undo/CMakeLists.txt
new file mode 100644
index 0000000000..751026bd62
--- /dev/null
+++ b/examples/widgets/tools/undo/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from undo.pro.
+
+#####################################################################
+## undo Binary:
+#####################################################################
+
+add_qt_executable(undo
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/undo"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/undo"
+ SOURCES
+ commands.cpp commands.h
+ document.cpp document.h
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(undo "undo" PREFIX "/" FILES
+ icons/background.png
+ icons/blue.png
+ icons/circle.png
+ icons/exit.png
+ icons/fileclose.png
+ icons/filenew.png
+ icons/fileopen.png
+ icons/filesave.png
+ icons/green.png
+ icons/ok.png
+ icons/rectangle.png
+ icons/red.png
+ icons/redo.png
+ icons/remove.png
+ icons/triangle.png
+ icons/undo.png)
+
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:undo.pro:build_all AND NOT build_pass:
+# CONFIG = "-build_all" "release"
diff --git a/examples/widgets/tools/undoframework/CMakeLists.txt b/examples/widgets/tools/undoframework/CMakeLists.txt
new file mode 100644
index 0000000000..0689d0df08
--- /dev/null
+++ b/examples/widgets/tools/undoframework/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from undoframework.pro.
+
+#####################################################################
+## undoframework Binary:
+#####################################################################
+
+add_qt_executable(undoframework
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/undoframework"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tools/undoframework"
+ SOURCES
+ commands.cpp commands.h
+ diagramitem.cpp diagramitem.h
+ diagramscene.cpp diagramscene.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(undoframework "undoframework" FILES
+ images/cross.png)
+
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..0266bc4e3b
--- /dev/null
+++ b/examples/widgets/touch/dials/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from dials.pro.
+
+#####################################################################
+## dials Binary:
+#####################################################################
+
+add_qt_executable(dials
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/touch/dials"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/touch/dials"
+ SOURCES
+ dials.ui
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/touch/fingerpaint/CMakeLists.txt b/examples/widgets/touch/fingerpaint/CMakeLists.txt
new file mode 100644
index 0000000000..82ec8cd91e
--- /dev/null
+++ b/examples/widgets/touch/fingerpaint/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from fingerpaint.pro.
+
+#####################################################################
+## fingerpaint Binary:
+#####################################################################
+
+add_qt_executable(fingerpaint
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/touch/fingerpaint"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/touch/fingerpaint"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ scribblearea.cpp scribblearea.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(fingerpaint CONDITION TARGET Qt::PrintSupport
+ LIBRARIES
+ Qt::PrintSupport
+)
diff --git a/examples/widgets/touch/knobs/CMakeLists.txt b/examples/widgets/touch/knobs/CMakeLists.txt
new file mode 100644
index 0000000000..e8976db270
--- /dev/null
+++ b/examples/widgets/touch/knobs/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from knobs.pro.
+
+#####################################################################
+## knobs Binary:
+#####################################################################
+
+add_qt_executable(knobs
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/touch/knobs"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/touch/knobs"
+ SOURCES
+ knob.cpp knob.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/touch/pinchzoom/CMakeLists.txt b/examples/widgets/touch/pinchzoom/CMakeLists.txt
new file mode 100644
index 0000000000..92d7b4c3b3
--- /dev/null
+++ b/examples/widgets/touch/pinchzoom/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from pinchzoom.pro.
+
+#####################################################################
+## pinchzoom Binary:
+#####################################################################
+
+add_qt_executable(pinchzoom
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/touch/pinchzoom"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/touch/pinchzoom"
+ SOURCES
+ graphicsview.cpp graphicsview.h
+ main.cpp
+ mouse.cpp mouse.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(pinchzoom "mice" PREFIX "/" FILES
+ images/cheese.jpg)
+
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..dcfc424a24
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part1/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from part1.pro.
+
+#####################################################################
+## part1 Binary:
+#####################################################################
+
+add_qt_executable(part1
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part1"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part1"
+ SOURCES
+ addressbook.cpp addressbook.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:part1.pro:<NONE>:
+# QMAKE_PROJECT_NAME = "ab_part1"
diff --git a/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt
new file mode 100644
index 0000000000..b9fe9307ee
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from part2.pro.
+
+#####################################################################
+## part2 Binary:
+#####################################################################
+
+add_qt_executable(part2
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part2"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part2"
+ SOURCES
+ addressbook.cpp addressbook.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:part2.pro:<NONE>:
+# QMAKE_PROJECT_NAME = "ab_part2"
diff --git a/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt
new file mode 100644
index 0000000000..f83a8c5379
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from part3.pro.
+
+#####################################################################
+## part3 Binary:
+#####################################################################
+
+add_qt_executable(part3
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part3"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part3"
+ SOURCES
+ addressbook.cpp addressbook.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:part3.pro:<NONE>:
+# QMAKE_PROJECT_NAME = "ab_part3"
diff --git a/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt
new file mode 100644
index 0000000000..0dee5fab9a
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from part4.pro.
+
+#####################################################################
+## part4 Binary:
+#####################################################################
+
+add_qt_executable(part4
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part4"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part4"
+ SOURCES
+ addressbook.cpp addressbook.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:part4.pro:<NONE>:
+# QMAKE_PROJECT_NAME = "ab_part4"
diff --git a/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt
new file mode 100644
index 0000000000..564f044ba8
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from part5.pro.
+
+#####################################################################
+## part5 Binary:
+#####################################################################
+
+add_qt_executable(part5
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part5"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part5"
+ SOURCES
+ addressbook.cpp addressbook.h
+ finddialog.cpp finddialog.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:part5.pro:<NONE>:
+# QMAKE_PROJECT_NAME = "ab_part5"
diff --git a/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt
new file mode 100644
index 0000000000..375f1f0612
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from part6.pro.
+
+#####################################################################
+## part6 Binary:
+#####################################################################
+
+add_qt_executable(part6
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part6"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part6"
+ SOURCES
+ addressbook.cpp addressbook.h
+ finddialog.cpp finddialog.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:part6.pro:<NONE>:
+# QMAKE_PROJECT_NAME = "ab_part6"
diff --git a/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt
new file mode 100644
index 0000000000..1ccd87fff5
--- /dev/null
+++ b/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from part7.pro.
+
+#####################################################################
+## part7 Binary:
+#####################################################################
+
+add_qt_executable(part7
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part7"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part7"
+ SOURCES
+ addressbook.cpp addressbook.h
+ finddialog.cpp finddialog.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:part7.pro:<NONE>:
+# QMAKE_PROJECT_NAME = "ab_part7"
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..c39133d235
--- /dev/null
+++ b/examples/widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from part1.pro.
+
+#####################################################################
+## part1 Binary:
+#####################################################################
+
+add_qt_executable(part1
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part1"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part1"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
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..ff9ddd6584
--- /dev/null
+++ b/examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from part2.pro.
+
+#####################################################################
+## part2 Binary:
+#####################################################################
+
+add_qt_executable(part2
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part2"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part2"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
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..2564472be6
--- /dev/null
+++ b/examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from part3.pro.
+
+#####################################################################
+## part3 Binary:
+#####################################################################
+
+add_qt_executable(part3
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part3"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part3"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
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..473b803044
--- /dev/null
+++ b/examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from part4.pro.
+
+#####################################################################
+## part4 Binary:
+#####################################################################
+
+add_qt_executable(part4
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part4"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part4"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
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..93d2ea4175
--- /dev/null
+++ b/examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from part5.pro.
+
+#####################################################################
+## part5 Binary:
+#####################################################################
+
+add_qt_executable(part5
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part5"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part5"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
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..1edda802f9
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from 1_readonly.pro.
+
+#####################################################################
+## mv_readonly Binary:
+#####################################################################
+
+add_qt_executable(mv_readonly
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/1_readonly"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/1_readonly"
+ SOURCES
+ main.cpp
+ mymodel.cpp mymodel.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:1_readonly.pro:<NONE>:
+# TEMPLATE = "app"
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..3235275d6a
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from 2_formatting.pro.
+
+#####################################################################
+## mv_formatting Binary:
+#####################################################################
+
+add_qt_executable(mv_formatting
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/2_formatting"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/2_formatting"
+ SOURCES
+ main.cpp
+ mymodel.cpp mymodel.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:2_formatting.pro:<NONE>:
+# TEMPLATE = "app"
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..746bafc19a
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from 3_changingmodel.pro.
+
+#####################################################################
+## mv_changingmodel Binary:
+#####################################################################
+
+add_qt_executable(mv_changingmodel
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/3_changingmodel"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/3_changingmodel"
+ SOURCES
+ main.cpp
+ mymodel.cpp mymodel.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:3_changingmodel.pro:<NONE>:
+# TEMPLATE = "app"
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..ef7e0a501b
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from 4_headers.pro.
+
+#####################################################################
+## mv_headers Binary:
+#####################################################################
+
+add_qt_executable(mv_headers
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/4_headers"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/4_headers"
+ SOURCES
+ main.cpp
+ mymodel.cpp mymodel.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:4_headers.pro:<NONE>:
+# TEMPLATE = "app"
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..2ce884a7fe
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from 5_edit.pro.
+
+#####################################################################
+## mv_edit Binary:
+#####################################################################
+
+add_qt_executable(mv_edit
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/5_edit"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/5_edit"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ mymodel.cpp mymodel.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:5_edit.pro:<NONE>:
+# TEMPLATE = "app"
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..1d5a9425e5
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from 6_treeview.pro.
+
+#####################################################################
+## mv_tree Binary:
+#####################################################################
+
+add_qt_executable(mv_tree
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/6_treeview"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/6_treeview"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:6_treeview.pro:<NONE>:
+# TEMPLATE = "app"
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..0560dc7a60
--- /dev/null
+++ b/examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from 7_selections.pro.
+
+#####################################################################
+## mv_selections Binary:
+#####################################################################
+
+add_qt_executable(mv_selections
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/7_selections"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/7_selections"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:7_selections.pro:<NONE>:
+# TEMPLATE = "app"
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/CMakeLists.txt b/examples/widgets/tutorials/notepad/CMakeLists.txt
new file mode 100644
index 0000000000..9dcf98fe4c
--- /dev/null
+++ b/examples/widgets/tutorials/notepad/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
+ LIBRARIES # special case
+ Qt::Widgets
+)
+
+# 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:<NONE>:
+# TEMPLATE = "app"
+
+## Scopes:
+#####################################################################
+
+extend_target(notepad CONDITION TARGET Qt::PrintSupport
+ LIBRARIES
+ Qt::PrintSupport
+)
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..823098c9fc
--- /dev/null
+++ b/examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from childwidget.pro.
+
+#####################################################################
+## childwidget Binary:
+#####################################################################
+
+add_qt_executable(childwidget
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/childwidget"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/childwidget"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt b/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt
new file mode 100644
index 0000000000..7f88c89d80
--- /dev/null
+++ b/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from nestedlayouts.pro.
+
+#####################################################################
+## nestedlayouts Binary:
+#####################################################################
+
+add_qt_executable(nestedlayouts
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/nestedlayouts"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/nestedlayouts"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt b/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt
new file mode 100644
index 0000000000..2ef630033b
--- /dev/null
+++ b/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from toplevel.pro.
+
+#####################################################################
+## toplevel Binary:
+#####################################################################
+
+add_qt_executable(toplevel
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/toplevel"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/toplevel"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt b/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt
new file mode 100644
index 0000000000..157865b68c
--- /dev/null
+++ b/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from windowlayout.pro.
+
+#####################################################################
+## windowlayout Binary:
+#####################################################################
+
+add_qt_executable(windowlayout
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/windowlayout"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/windowlayout"
+ SOURCES
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
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..890a300294
--- /dev/null
+++ b/examples/widgets/widgets/analogclock/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from analogclock.pro.
+
+#####################################################################
+## analogclock Binary:
+#####################################################################
+
+add_qt_executable(analogclock_widgets # special case
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/analogclock"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/analogclock"
+ SOURCES
+ analogclock.cpp analogclock.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:analogclock.pro:<NONE>:
+# QMAKE_PROJECT_NAME = "widgets_analogclock"
diff --git a/examples/widgets/widgets/calculator/CMakeLists.txt b/examples/widgets/widgets/calculator/CMakeLists.txt
new file mode 100644
index 0000000000..b4f58b4f39
--- /dev/null
+++ b/examples/widgets/widgets/calculator/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from calculator.pro.
+
+#####################################################################
+## calculator Binary:
+#####################################################################
+
+add_qt_executable(calculator
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/calculator"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/calculator"
+ SOURCES
+ button.cpp button.h
+ calculator.cpp calculator.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/widgets/calendarwidget/CMakeLists.txt b/examples/widgets/widgets/calendarwidget/CMakeLists.txt
new file mode 100644
index 0000000000..463fce3849
--- /dev/null
+++ b/examples/widgets/widgets/calendarwidget/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from calendarwidget.pro.
+
+#####################################################################
+## calendarwidget Binary:
+#####################################################################
+
+add_qt_executable(calendarwidget
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/calendarwidget"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/calendarwidget"
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/widgets/charactermap/CMakeLists.txt b/examples/widgets/widgets/charactermap/CMakeLists.txt
new file mode 100644
index 0000000000..a09b63a4f7
--- /dev/null
+++ b/examples/widgets/widgets/charactermap/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from charactermap.pro.
+
+#####################################################################
+## charactermap Binary:
+#####################################################################
+
+add_qt_executable(charactermap
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/charactermap"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/charactermap"
+ SOURCES
+ characterwidget.cpp characterwidget.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/widgets/codeeditor/CMakeLists.txt b/examples/widgets/widgets/codeeditor/CMakeLists.txt
new file mode 100644
index 0000000000..7c29d383ff
--- /dev/null
+++ b/examples/widgets/widgets/codeeditor/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from codeeditor.pro.
+
+#####################################################################
+## codeeditor Binary:
+#####################################################################
+
+add_qt_executable(codeeditor
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/codeeditor"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/codeeditor"
+ SOURCES
+ codeeditor.cpp codeeditor.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/widgets/digitalclock/CMakeLists.txt b/examples/widgets/widgets/digitalclock/CMakeLists.txt
new file mode 100644
index 0000000000..b85528a1e8
--- /dev/null
+++ b/examples/widgets/widgets/digitalclock/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from digitalclock.pro.
+
+#####################################################################
+## digitalclock Binary:
+#####################################################################
+
+add_qt_executable(digitalclock
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/digitalclock"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/digitalclock"
+ SOURCES
+ digitalclock.cpp digitalclock.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/widgets/elidedlabel/CMakeLists.txt b/examples/widgets/widgets/elidedlabel/CMakeLists.txt
new file mode 100644
index 0000000000..b894e18692
--- /dev/null
+++ b/examples/widgets/widgets/elidedlabel/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from elidedlabel.pro.
+
+#####################################################################
+## elidedlabel Binary:
+#####################################################################
+
+add_qt_executable(elidedlabel
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/elidedlabel"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/elidedlabel"
+ SOURCES
+ elidedlabel.cpp elidedlabel.h
+ main.cpp
+ testwidget.cpp testwidget.h
+ LIBRARIES
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:elidedlabel.pro:<NONE>:
+# TEMPLATE = "app"
diff --git a/examples/widgets/widgets/groupbox/CMakeLists.txt b/examples/widgets/widgets/groupbox/CMakeLists.txt
new file mode 100644
index 0000000000..1d77ab37dc
--- /dev/null
+++ b/examples/widgets/widgets/groupbox/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from groupbox.pro.
+
+#####################################################################
+## groupbox Binary:
+#####################################################################
+
+add_qt_executable(groupbox
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/groupbox"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/groupbox"
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/widgets/icons/CMakeLists.txt b/examples/widgets/widgets/icons/CMakeLists.txt
new file mode 100644
index 0000000000..34d9bcec94
--- /dev/null
+++ b/examples/widgets/widgets/icons/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from icons.pro.
+
+#####################################################################
+## icons Binary:
+#####################################################################
+
+add_qt_executable(icons
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/icons"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/icons"
+ SOURCES
+ iconpreviewarea.cpp iconpreviewarea.h
+ iconsizespinbox.cpp iconsizespinbox.h
+ imagedelegate.cpp imagedelegate.h
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ DEFINES
+ SRCDIR=\\\"/\\\"
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:icons.pro:<NONE>:
+# EXAMPLE_FILES = "images/*"
diff --git a/examples/widgets/widgets/imageviewer/CMakeLists.txt b/examples/widgets/widgets/imageviewer/CMakeLists.txt
new file mode 100644
index 0000000000..4684653e64
--- /dev/null
+++ b/examples/widgets/widgets/imageviewer/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from imageviewer.pro.
+
+#####################################################################
+## imageviewer Binary:
+#####################################################################
+
+add_qt_executable(imageviewer
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/imageviewer"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/imageviewer"
+ SOURCES
+ imageviewer.cpp imageviewer.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(imageviewer CONDITION TARGET Qt::PrintSupport
+ LIBRARIES
+ Qt::PrintSupport
+)
diff --git a/examples/widgets/widgets/lineedits/CMakeLists.txt b/examples/widgets/widgets/lineedits/CMakeLists.txt
new file mode 100644
index 0000000000..59406a703d
--- /dev/null
+++ b/examples/widgets/widgets/lineedits/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from lineedits.pro.
+
+#####################################################################
+## lineedits Binary:
+#####################################################################
+
+add_qt_executable(lineedits
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/lineedits"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/lineedits"
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/widgets/mousebuttons/CMakeLists.txt b/examples/widgets/widgets/mousebuttons/CMakeLists.txt
new file mode 100644
index 0000000000..6ec817458c
--- /dev/null
+++ b/examples/widgets/widgets/mousebuttons/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from mousebuttons.pro.
+
+#####################################################################
+## mousebuttons Binary:
+#####################################################################
+
+add_qt_executable(mousebuttons
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/mousebuttons"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/mousebuttons"
+ SOURCES
+ buttontester.cpp buttontester.h
+ main.cpp
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:mousebuttons.pro:<NONE>:
+# TEMPLATE = "app"
diff --git a/examples/widgets/widgets/movie/CMakeLists.txt b/examples/widgets/widgets/movie/CMakeLists.txt
new file mode 100644
index 0000000000..0df3465fea
--- /dev/null
+++ b/examples/widgets/widgets/movie/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from movie.pro.
+
+#####################################################################
+## movie Binary:
+#####################################################################
+
+add_qt_executable(movie
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/movie"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/movie"
+ SOURCES
+ main.cpp
+ movieplayer.cpp movieplayer.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:movie.pro:<NONE>:
+# EXAMPLE_FILES = "animation.gif"
diff --git a/examples/widgets/widgets/scribble/CMakeLists.txt b/examples/widgets/widgets/scribble/CMakeLists.txt
new file mode 100644
index 0000000000..d9b2292336
--- /dev/null
+++ b/examples/widgets/widgets/scribble/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from scribble.pro.
+
+#####################################################################
+## scribble Binary:
+#####################################################################
+
+add_qt_executable(scribble
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/scribble"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/scribble"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ scribblearea.cpp scribblearea.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(scribble CONDITION TARGET Qt::PrintSupport
+ LIBRARIES
+ Qt::PrintSupport
+)
diff --git a/examples/widgets/widgets/shapedclock/CMakeLists.txt b/examples/widgets/widgets/shapedclock/CMakeLists.txt
new file mode 100644
index 0000000000..ab199d6981
--- /dev/null
+++ b/examples/widgets/widgets/shapedclock/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from shapedclock.pro.
+
+#####################################################################
+## shapedclock Binary:
+#####################################################################
+
+add_qt_executable(shapedclock
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/shapedclock"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/shapedclock"
+ SOURCES
+ main.cpp
+ shapedclock.cpp shapedclock.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/widgets/sliders/CMakeLists.txt b/examples/widgets/widgets/sliders/CMakeLists.txt
new file mode 100644
index 0000000000..a064ad5a4a
--- /dev/null
+++ b/examples/widgets/widgets/sliders/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from sliders.pro.
+
+#####################################################################
+## sliders Binary:
+#####################################################################
+
+add_qt_executable(sliders
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/sliders"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/sliders"
+ SOURCES
+ main.cpp
+ slidersgroup.cpp slidersgroup.h
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/widgets/spinboxes/CMakeLists.txt b/examples/widgets/widgets/spinboxes/CMakeLists.txt
new file mode 100644
index 0000000000..8635f06a8e
--- /dev/null
+++ b/examples/widgets/widgets/spinboxes/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from spinboxes.pro.
+
+#####################################################################
+## spinboxes Binary:
+#####################################################################
+
+add_qt_executable(spinboxes
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/spinboxes"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/spinboxes"
+ SOURCES
+ main.cpp
+ window.cpp window.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/widgets/styles/CMakeLists.txt b/examples/widgets/widgets/styles/CMakeLists.txt
new file mode 100644
index 0000000000..d33d90a5bc
--- /dev/null
+++ b/examples/widgets/widgets/styles/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from styles.pro.
+
+#####################################################################
+## styles Binary:
+#####################################################################
+
+add_qt_executable(styles
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/styles"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/styles"
+ SOURCES
+ main.cpp
+ norwegianwoodstyle.cpp norwegianwoodstyle.h
+ widgetgallery.cpp widgetgallery.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(styles "styles" FILES
+ images/woodbackground.png
+ images/woodbutton.png)
+
diff --git a/examples/widgets/widgets/stylesheet/CMakeLists.txt b/examples/widgets/widgets/stylesheet/CMakeLists.txt
new file mode 100644
index 0000000000..dfb52a1a47
--- /dev/null
+++ b/examples/widgets/widgets/stylesheet/CMakeLists.txt
@@ -0,0 +1,56 @@
+# Generated from stylesheet.pro.
+
+#####################################################################
+## stylesheet Binary:
+#####################################################################
+
+add_qt_executable(stylesheet
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/stylesheet"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/stylesheet"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h mainwindow.ui
+ stylesheeteditor.cpp stylesheeteditor.h stylesheeteditor.ui
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(stylesheet "stylesheet" PREFIX "/" FILES
+ images/checkbox_checked.png
+ images/checkbox_checked_hover.png
+ images/checkbox_checked_pressed.png
+ images/checkbox_unchecked.png
+ images/checkbox_unchecked_hover.png
+ images/checkbox_unchecked_pressed.png
+ images/down_arrow.png
+ images/down_arrow_disabled.png
+ images/frame.png
+ images/pagefold.png
+ images/pushbutton.png
+ images/pushbutton_hover.png
+ images/pushbutton_pressed.png
+ images/radiobutton_checked.png
+ images/radiobutton_checked_hover.png
+ images/radiobutton_checked_pressed.png
+ images/radiobutton_unchecked.png
+ images/radiobutton_unchecked_hover.png
+ images/radiobutton_unchecked_pressed.png
+ images/sizegrip.png
+ images/spindown.png
+ images/spindown_hover.png
+ images/spindown_off.png
+ images/spindown_pressed.png
+ images/spinup.png
+ images/spinup_hover.png
+ images/spinup_off.png
+ images/spinup_pressed.png
+ images/up_arrow.png
+ images/up_arrow_disabled.png
+ layouts/default.ui
+ layouts/pagefold.ui
+ qss/coffee.qss
+ qss/default.qss
+ qss/pagefold.qss)
+
diff --git a/examples/widgets/widgets/tablet/CMakeLists.txt b/examples/widgets/widgets/tablet/CMakeLists.txt
new file mode 100644
index 0000000000..f23fe7ec71
--- /dev/null
+++ b/examples/widgets/widgets/tablet/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from tablet.pro.
+
+#####################################################################
+## qttablet Binary:
+#####################################################################
+
+add_qt_executable(qttablet
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/tablet"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/tablet"
+ SOURCES
+ main.cpp
+ mainwindow.cpp mainwindow.h
+ tabletapplication.cpp tabletapplication.h
+ tabletcanvas.cpp tabletcanvas.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(qttablet "images" FILES
+ images/cursor-airbrush.png
+ images/cursor-eraser.png
+ images/cursor-felt-marker.png
+ images/cursor-pencil.png)
+
diff --git a/examples/widgets/widgets/tetrix/CMakeLists.txt b/examples/widgets/widgets/tetrix/CMakeLists.txt
new file mode 100644
index 0000000000..002667a6b9
--- /dev/null
+++ b/examples/widgets/widgets/tetrix/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from tetrix.pro.
+
+#####################################################################
+## tetrix Binary:
+#####################################################################
+
+add_qt_executable(tetrix
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/tetrix"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/tetrix"
+ SOURCES
+ main.cpp
+ tetrixboard.cpp tetrixboard.h
+ tetrixpiece.cpp tetrixpiece.h
+ tetrixwindow.cpp tetrixwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/widgets/tooltips/CMakeLists.txt b/examples/widgets/widgets/tooltips/CMakeLists.txt
new file mode 100644
index 0000000000..02d773858a
--- /dev/null
+++ b/examples/widgets/widgets/tooltips/CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from tooltips.pro.
+
+#####################################################################
+## tooltips Binary:
+#####################################################################
+
+add_qt_executable(tooltips
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/tooltips"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/tooltips"
+ SOURCES
+ main.cpp
+ shapeitem.cpp shapeitem.h
+ sortingbox.cpp sortingbox.h
+ LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(tooltips "tooltips" FILES
+ images/circle.png
+ images/square.png
+ images/triangle.png)
+
diff --git a/examples/widgets/widgets/validators/CMakeLists.txt b/examples/widgets/widgets/validators/CMakeLists.txt
new file mode 100644
index 0000000000..9da1da775e
--- /dev/null
+++ b/examples/widgets/widgets/validators/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from validators.pro.
+
+#####################################################################
+## validators Binary:
+#####################################################################
+
+add_qt_executable(validators
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/validators"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/validators"
+ SOURCES
+ ledwidget.cpp ledwidget.h
+ localeselector.cpp localeselector.h
+ main.cpp
+ validators.ui
+ validatorwidget.cpp validatorwidget.h
+ PUBLIC_LIBRARIES
+ Qt::Widgets
+)
+
+# Resources:
+add_qt_resource(validators "validators" PREFIX "/" FILES
+ ledoff.png
+ ledon.png)
+
diff --git a/examples/widgets/widgets/wiggly/CMakeLists.txt b/examples/widgets/widgets/wiggly/CMakeLists.txt
new file mode 100644
index 0000000000..cc8c0befbf
--- /dev/null
+++ b/examples/widgets/widgets/wiggly/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from wiggly.pro.
+
+#####################################################################
+## wiggly Binary:
+#####################################################################
+
+add_qt_executable(wiggly
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/wiggly"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/wiggly"
+ SOURCES
+ dialog.cpp dialog.h
+ main.cpp
+ wigglywidget.cpp wigglywidget.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/widgets/windowflags/CMakeLists.txt b/examples/widgets/widgets/windowflags/CMakeLists.txt
new file mode 100644
index 0000000000..aa2eff0088
--- /dev/null
+++ b/examples/widgets/widgets/windowflags/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from windowflags.pro.
+
+#####################################################################
+## windowflags Binary:
+#####################################################################
+
+add_qt_executable(windowflags
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/windowflags"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/widgets/windowflags"
+ SOURCES
+ controllerwindow.cpp controllerwindow.h
+ main.cpp
+ previewwindow.cpp previewwindow.h
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/examples/widgets/windowcontainer/CMakeLists.txt b/examples/widgets/windowcontainer/CMakeLists.txt
new file mode 100644
index 0000000000..88dc37ea5e
--- /dev/null
+++ b/examples/widgets/windowcontainer/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from windowcontainer.pro.
+
+#####################################################################
+## windowcontainer Binary:
+#####################################################################
+
+add_qt_executable(windowcontainer
+ GUI
+ OUTPUT_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/windowcontainer"
+ INSTALL_DIRECTORY "${INSTALL_EXAMPLESDIR}/widgets/windowcontainer"
+ SOURCES
+ ../../gui/openglwindow/openglwindow.cpp ../../gui/openglwindow/openglwindow.h
+ windowcontainer.cpp
+ INCLUDE_DIRECTORIES
+ ../../gui/openglwindow
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/qmake/CMakeLists.txt b/qmake/CMakeLists.txt
new file mode 100644
index 0000000000..d40ec9119b
--- /dev/null
+++ b/qmake/CMakeLists.txt
@@ -0,0 +1,212 @@
+# Generated from qmake.pro.
+
+# special case:
+install(DIRECTORY "${PROJECT_SOURCE_DIR}/mkspecs" DESTINATION ${INSTALL_DATADIR})
+
+find_library(FWApplicationServices ApplicationServices) # special case
+find_library(FWCoreServices CoreServices) # special case
+find_library(FWFoundation Foundation) # special case
+
+#####################################################################
+## qmake Binary:
+#####################################################################
+
+add_qt_tool(qmake # special case
+ # GUI # special case: remove this
+ 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/qjson.cpp ../src/corelib/serialization/qjson_p.h
+ ../src/corelib/serialization/qjsonarray.cpp ../src/corelib/serialization/qjsonarray.h
+ ../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/qbytearray.cpp ../src/corelib/tools/qbytearray.h
+ ../src/corelib/tools/qbytearraymatcher.cpp ../src/corelib/tools/qbytearraymatcher.h
+ ../src/corelib/tools/qchar.h
+ ../src/corelib/tools/qcryptographichash.cpp ../src/corelib/tools/qcryptographichash.h
+ ../src/corelib/tools/qdatetime.cpp ../src/corelib/tools/qdatetime.h ../src/corelib/tools/qdatetime_p.h
+ ../src/corelib/tools/qhash.cpp ../src/corelib/tools/qhash.h
+ ../src/corelib/tools/qlinkedlist.cpp ../src/corelib/tools/qlinkedlist.h
+ ../src/corelib/tools/qlist.cpp ../src/corelib/tools/qlist.h
+ ../src/corelib/tools/qlocale.cpp ../src/corelib/tools/qlocale.h
+ ../src/corelib/tools/qlocale_tools.cpp ../src/corelib/tools/qlocale_tools_p.h
+ ../src/corelib/tools/qmap.cpp ../src/corelib/tools/qmap.h
+ ../src/corelib/tools/qregexp.cpp ../src/corelib/tools/qregexp.h
+ ../src/corelib/tools/qstring.cpp ../src/corelib/tools/qstring.h
+ ../src/corelib/tools/qstring_compat.cpp
+ ../src/corelib/tools/qstringlist.cpp ../src/corelib/tools/qstringlist.h
+ ../src/corelib/tools/qstringmatcher.h
+ ../src/corelib/tools/qvector.h
+ ../src/corelib/tools/qversionnumber.cpp ../src/corelib/tools/qversionnumber.h
+ ../src/corelib/tools/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
+ library
+ generators
+ generators/unix
+ generators/win32
+ generators/mac
+ $<TARGET_PROPERTY:Qt::CorePrivate,INTERFACE_INCLUDE_DIRECTORIES> # special case
+ ${CMAKE_BINARY_DIR}/src/corelib/global # special case: for qconfig.cpp
+)
+
+qt_internal_add_target_aliases(Bootstrap) # special case
+
+#### Keys ignored in scope 1:.:.:qmake.pro:<TRUE>:
+# CONFIG = "cmdline" "-qt"
+# PRECOMPILED_HEADER = "qmake_pch.h"
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
+
+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/tools/qlocale_win.cpp
+ library/registry.cpp # special case
+ DEFINES
+ UNICODE
+ _ENABLE_EXTENDED_ALIGNED_STORAGE
+ _CRT_SECURE_NO_WARNINGS
+ _SCL_SECURE_NO_WARNINGS
+ PUBLIC_LIBRARIES
+ advapi32
+ kernel32
+ netapi32
+ ole32
+)
+
+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/tools/qlocale_unix.cpp
+)
+
+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/tools/qlocale_win.cpp
+ ../src/corelib/io/qsettings_win.cpp
+ ../src/corelib/global/qoperatingsystemversion.cpp
+ ../src/corelib/global/qoperatingsystemversion_win.cpp
+ ../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
+)
+
+extend_target(qmake CONDITION WIN32 AND mingw
+ PUBLIC_LIBRARIES
+ uuid
+)
+
+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
+)
diff --git a/src/3rdparty/CMakeLists.txt b/src/3rdparty/CMakeLists.txt
new file mode 100644
index 0000000000..77c4970f49
--- /dev/null
+++ b/src/3rdparty/CMakeLists.txt
@@ -0,0 +1,2 @@
+add_subdirectory(tinycbor)
+add_subdirectory(harfbuzz)
diff --git a/src/3rdparty/harfbuzz/CMakeLists.txt b/src/3rdparty/harfbuzz/CMakeLists.txt
new file mode 100644
index 0000000000..25a3b75d2f
--- /dev/null
+++ b/src/3rdparty/harfbuzz/CMakeLists.txt
@@ -0,0 +1,11 @@
+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 src)
diff --git a/src/3rdparty/tinycbor/CMakeLists.txt b/src/3rdparty/tinycbor/CMakeLists.txt
new file mode 100644
index 0000000000..3a1a760af9
--- /dev/null
+++ b/src/3rdparty/tinycbor/CMakeLists.txt
@@ -0,0 +1,2 @@
+add_library(tinycbor INTERFACE)
+target_include_directories(tinycbor INTERFACE "${CMAKE_CURRENT_SOURCE_DIR}/src")
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
new file mode 100644
index 0000000000..212df0d9c2
--- /dev/null
+++ b/src/CMakeLists.txt
@@ -0,0 +1,79 @@
+if(APPLE)
+ find_library(FWAppKit AppKit)
+ find_library(FWApplicationServices ApplicationServices)
+ find_library(FWCarbon Carbon)
+ find_library(FWCoreFoundation CoreFoundation)
+ find_library(FWCoreServices CoreServices)
+ find_library(FWCoreVideo CoreVideo)
+ find_library(FWcups cups)
+ find_library(FWDiskArbitration DiskArbitration)
+ find_library(FWFoundation Foundation)
+ 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)
+endif()
+
+add_subdirectory(3rdparty)
+
+function(find_or_build_bootstrap_names)
+ # Move these into their own folder and move this code in the CMakeLists.txt file there!
+ set01(_build_tools "x${HOST_QT_TOOLS_DIRECTORY}" STREQUAL "x")
+
+ if (_build_tools)
+ add_subdirectory(tools/bootstrap) # bootstrap library
+ endif()
+ add_subdirectory(tools/moc)
+ add_subdirectory(tools/rcc)
+ add_subdirectory(tools/qfloat16-tables)
+ add_subdirectory(tools/tracegen)
+
+ if (_build_tools)
+ install(EXPORT "Qt${PROJECT_VERSION_MAJOR}ToolsTargets" NAMESPACE "${QT_CMAKE_EXPORT_NAMESPACE}::" DESTINATION "${INSTALL_LIBDIR}/cmake/Qt${PROJECT_VERSION_MAJOR}")
+ endif()
+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()
+if (QT_FEATURE_dbus)
+ add_subdirectory(dbus)
+endif()
+add_subdirectory(tools)
+if(QT_FEATURE_gui)
+ add_subdirectory(gui)
+
+ 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)
diff --git a/src/concurrent/CMakeLists.txt b/src/concurrent/CMakeLists.txt
new file mode 100644
index 0000000000..25ca44ddbf
--- /dev/null
+++ b/src/concurrent/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from concurrent.pro.
+
+#####################################################################
+## Concurrent Module:
+#####################################################################
+
+add_qt_module(Concurrent
+ 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_USING_NAMESPACE
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES # special case
+ Qt::Core
+ # CONFIG = "exceptions"
+ # PRECOMPILED_HEADER = "../corelib/global/qt_pch.h"
+ # _LOADED = "qt_module"
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(Concurrent CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x66000000"
+)
+
+add_qt_docs(./doc/qtconcurrent.qdocconf)
diff --git a/src/corelib/CMakeLists.txt b/src/corelib/CMakeLists.txt
new file mode 100644
index 0000000000..eb11b1251e
--- /dev/null
+++ b/src/corelib/CMakeLists.txt
@@ -0,0 +1,1061 @@
+# Generated from corelib.pro.
+
+# special case:
+find_package(Threads)
+find_package(WrapDoubleConversion REQUIRED)
+
+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()
+
+#####################################################################
+## Core Module:
+#####################################################################
+
+add_qt_module(Core
+ 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/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/qcborstream.cpp serialization/qcborstream.h
+ serialization/qcborvalue.cpp serialization/qcborvalue.h serialization/qcborvalue_p.h
+ serialization/qdatastream.cpp serialization/qdatastream.h serialization/qdatastream_p.h
+ serialization/qjson.cpp 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
+ thread/qmutex.h
+ thread/qreadwritelock.h
+ thread/qrunnable.cpp thread/qrunnable.h
+ thread/qthread.cpp thread/qthread.h
+ thread/qthreadstorage.h
+ thread/qwaitcondition.h
+ tools/qalgorithms.h
+ tools/qarraydata.cpp tools/qarraydata.h
+ tools/qarraydataops.h
+ tools/qarraydatapointer.h
+ tools/qbitarray.cpp tools/qbitarray.h
+ tools/qbytearray.cpp tools/qbytearray.h tools/qbytearray_p.h
+ tools/qbytearraylist.cpp tools/qbytearraylist.h
+ tools/qbytearraymatcher.cpp tools/qbytearraymatcher.h
+ tools/qbytedata_p.h
+ tools/qcache.h
+ tools/qchar.h
+ tools/qcollator.cpp tools/qcollator.h tools/qcollator_p.h
+ tools/qcontainerfwd.h
+ tools/qcontiguouscache.cpp tools/qcontiguouscache.h
+ tools/qcryptographichash.cpp tools/qcryptographichash.h
+ tools/qdatetime.cpp tools/qdatetime.h tools/qdatetime_p.h
+ tools/qdoublescanprint_p.h
+ tools/qeasingcurve.cpp tools/qeasingcurve.h
+ tools/qfreelist.cpp tools/qfreelist_p.h
+ tools/qharfbuzz.cpp tools/qharfbuzz_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/qlocale.cpp tools/qlocale.h tools/qlocale_p.h
+ tools/qlocale_data_p.h
+ tools/qlocale_tools.cpp tools/qlocale_tools_p.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/qregexp.cpp tools/qregexp.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/qstring.cpp tools/qstring.h
+ tools/qstring_compat.cpp
+ tools/qstringalgorithms.h tools/qstringalgorithms_p.h
+ tools/qstringbuilder.cpp tools/qstringbuilder.h
+ tools/qstringiterator_p.h
+ tools/qstringlist.cpp tools/qstringlist.h
+ tools/qstringliteral.h
+ tools/qstringmatcher.h
+ tools/qstringview.cpp tools/qstringview.h
+ tools/qtextboundaryfinder.cpp tools/qtextboundaryfinder.h
+ tools/qtimeline.cpp tools/qtimeline.h
+ tools/qtools_p.h
+ tools/qunicodetables_p.h
+ tools/qunicodetools.cpp tools/qunicodetools_p.h
+ tools/qvarlengtharray.h
+ tools/qvector.h
+ tools/qversionnumber.cpp tools/qversionnumber.h
+ tools/qvsnprintf.cpp
+ DEFINES
+ QT_NO_USING_NAMESPACE
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_BINARY_DIR}/global # special case
+ # special case: remove ../3rdparty/...
+ LIBRARIES
+ ZLIB::ZLIB
+ # double-conversion # special case
+ Qt::GlobalConfigPrivate # special case
+ QtHarfBuzz # special case
+ Threads::Threads # special case
+ tinycbor # special case
+ WrapDoubleConversion # special case
+ PUBLIC_LIBRARIES # special case:
+ Qt::Platform
+ DISABLE_AUTOGEN_TOOLS # special case:
+ uic
+)
+
+# special case:
+add_dependencies(Core Qt::moc)
+add_dependencies(Core Qt::rcc)
+add_dependencies(CorePrivate Qt::moc)
+add_dependencies(CorePrivate Qt::rcc)
+
+if (QT_NAMESPACE STREQUAL "")
+else()
+ target_compile_definitions(Core PUBLIC "QT_NAMESPACE=${QT_NAMESPACE}")
+endif()
+
+configure_file(global/qconfig.cpp.in global/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)
+
+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()
+
+add_qt_simd_part(Core SIMD mips_dsp
+ SOURCES
+ ../gui/painting/qt_mips_asm_dsp_p.h
+ tools/qstring_mips_dsp_asm.S
+)
+
+
+#### Keys ignored in scope 1:.:.:corelib.pro:<TRUE>:
+# ANDROID_BUNDLED_JAR_DEPENDENCIES = "jar/QtAndroid.jar"
+# ANDROID_LIB_DEPENDENCIES = "plugins/platforms/android/libqtforandroid.so"
+# ANDROID_PERMISSIONS = "android.permission.INTERNET" "android.permission.WRITE_EXTERNAL_STORAGE"
+# CMAKE_DISABLED_FEATURES = "$$joinQT_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]"
+# CONFIG = "exceptions" "qt_tracepoints" "$$MODULE_CONFIG" "simd" "optimize_full"
+# 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"
+# _LOADED = "qt_module" "cmake_functions"
+# 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"
+
+extend_target(Core CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x67000000"
+)
+
+#### Keys ignored in scope 5:.:.:corelib.pro:FREEBSD OR OPENBSD:
+# QMAKE_LFLAGS_NOUNDEF = <EMPTY>
+
+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
+)
+
+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
+)
+
+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
+ LIBRARIES
+ advapi32
+ kernel32
+ ole32
+ shell32
+ user32
+ uuid
+ version
+ winmm
+ PUBLIC_LIBRARIES
+ mpr
+ netapi32
+ userenv
+)
+
+extend_target(Core CONDITION APPLE
+ SOURCES
+ global/qoperatingsystemversion_darwin.mm
+ LIBRARIES
+ ${FWCoreFoundation}
+ ${FWFoundation}
+)
+
+extend_target(Core CONDITION APPLE_OSX
+ SOURCES
+ 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
+ ${FWAppKit}
+ ${FWApplicationServices}
+ ${FWCoreServices}
+ ${FWFoundation}
+ ${FWSecurity}
+ PUBLIC_LIBRARIES
+ ${FWDiskArbitration}
+ ${FWIOKit}
+)
+
+extend_target(Core CONDITION INTEGRITY
+ LIBRARIES
+ ivfs
+ net
+ posix
+ shm_client
+ socket
+ COMPILE_OPTIONS
+ "--pending_instantiations=128"
+)
+
+#### Keys ignored in scope 13:.:.: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 14:.:.: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 17:.:global:global/global.pri:QT_CPU_FEATURES__ss_QT_ARCH___contains___f16c:
+# f16c_cxx = "true"
+
+#### Keys ignored in scope 19:.:global:global/global.pri:CLANG OR intel_icl OR ICC:
+# f16c_cxx = "false"
+
+#### Keys ignored in scope 21:.:global:global/global.pri:GCC AND f16c AND x86SimdAlways:
+# f16c_cxx = "true"
+
+#### Keys ignored in scope 23:.:global:global/global.pri:MSVC AND QT_CPU_FEATURES__ss_QT_ARCH___contains___avx:
+# f16c_cxx = "true"
+
+#### Keys ignored in scope 24:.:global:global/global.pri:else:
+# f16c_cxx = "false"
+
+# special case: Handled manually:
+# extend_target(Core CONDITION _ss_f16c_cxx ...
+
+#### Keys ignored in scope 26:.:global:global/global.pri:else:
+# F16C_SOURCES = "global/qfloat16_f16c.c"
+
+extend_target(Core CONDITION linux_x_ OR hurd_x_ AND NOT cross_compile AND NOT static AND NOT _x_-armcc_x_
+ DEFINES
+ ELF_INTERPRETER=\\\"=Creadelf-l/bin/ls|perl-n-e\'/programinterpreter:.*]/{print$1;}\'\\\"
+ LINK_OPTIONS
+ "-Wl,-e,qt_core_boilerplate"
+)
+
+extend_target(Core CONDITION LINUX AND NOT static
+ SOURCES
+ global/minimum-linux_p.h
+)
+
+#### Keys ignored in scope 31:.: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 32:.:global:global/global.pri:silent:
+# no_pch_assembler.commands = "@echo" "compiling[no_pch]" "${QMAKE_FILE_IN}" "&&" "$$no_pch_assembler.commands"
+
+extend_target(Core CONDITION LINUX AND NOT precompile_header AND NOT static
+ SOURCES
+ global/minimum-linux.S
+)
+
+extend_target(Core CONDITION QT_FEATURE_slog2
+ LIBRARIES
+ slog2
+)
+
+extend_target(Core CONDITION QT_FEATURE_journald
+ LIBRARIES
+ journald
+)
+
+#### Keys ignored in scope 36:.: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 37:.:global:global/global.pri:silent:
+# versiontagging_compiler.commands = "@echo" "compiling[versiontagging]" "${QMAKE_FILE_IN}" "&&" "$$versiontagging_compiler.commands"
+
+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
+)
+
+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/qmutex.cpp thread/qmutex_p.h
+ thread/qmutexpool.cpp thread/qmutexpool_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
+)
+
+extend_target(Core CONDITION QT_FEATURE_thread AND WIN32
+ SOURCES
+ thread/qmutex_win.cpp
+ thread/qwaitcondition_win.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_thread AND UNIX
+ SOURCES
+ thread/qwaitcondition_unix.cpp
+)
+
+extend_target(Core CONDITION APPLE AND QT_FEATURE_thread
+ SOURCES
+ thread/qmutex_mac.cpp
+)
+
+extend_target(Core CONDITION LINUX AND QT_FEATURE_thread
+ SOURCES
+ thread/qmutex_linux.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_thread AND UNIX AND NOT APPLE AND NOT LINUX
+ SOURCES
+ thread/qmutex_unix.cpp
+)
+
+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
+)
+
+extend_target(Core CONDITION QT_FEATURE_std_atomic64
+ PUBLIC_LIBRARIES
+ Atomic
+)
+
+extend_target(Core CONDITION ICC
+ COMPILE_OPTIONS
+ "-fp-model"
+ "strict"
+)
+
+extend_target(Core CONDITION MSVC
+ SOURCES
+ tools/qvector_msvc.cpp
+)
+
+extend_target(Core CONDITION APPLE_OSX AND NOT NACL
+ SOURCES
+ kernel/qelapsedtimer_mac.cpp
+ tools/qlocale_mac.mm
+)
+
+extend_target(Core CONDITION UNIX AND (NACL OR NOT APPLE_OSX)
+ SOURCES
+ tools/qlocale_unix.cpp
+)
+
+extend_target(Core CONDITION WIN32 AND (NACL OR NOT APPLE_OSX)
+ SOURCES
+ tools/qlocale_win.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_icu
+ SOURCES
+ tools/qcollator_icu.cpp
+ tools/qlocale_icu.cpp
+ LIBRARIES
+ ICU::i18n ICU::uc ICU::data
+)
+
+extend_target(Core CONDITION WIN32 AND NOT QT_FEATURE_icu
+ SOURCES
+ tools/qcollator_win.cpp
+)
+
+extend_target(Core CONDITION APPLE_OSX AND NOT QT_FEATURE_icu
+ SOURCES
+ tools/qcollator_macx.cpp
+)
+
+extend_target(Core CONDITION UNIX AND NOT APPLE_OSX AND NOT QT_FEATURE_icu
+ SOURCES
+ tools/qcollator_posix.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_timezone
+ SOURCES
+ tools/qtimezone.cpp tools/qtimezone.h
+ tools/qtimezoneprivate.cpp tools/qtimezoneprivate_p.h
+ tools/qtimezoneprivate_data_p.h
+)
+
+extend_target(Core CONDITION APPLE AND QT_FEATURE_timezone AND NOT NACL
+ SOURCES
+ tools/qtimezoneprivate_mac.mm
+)
+
+extend_target(Core CONDITION ANDROID AND QT_FEATURE_timezone AND NOT ANDROID_EMBEDDED AND (NACL OR NOT APPLE)
+ SOURCES
+ tools/qtimezoneprivate_android.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_timezone AND UNIX AND (ANDROID_EMBEDDED OR NOT ANDROID) AND (NACL OR NOT APPLE)
+ SOURCES
+ tools/qtimezoneprivate_tz.cpp
+)
+
+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
+ tools/qtimezoneprivate_icu.cpp
+)
+
+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
+ tools/qtimezoneprivate_icu.cpp
+)
+
+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
+ tools/qtimezoneprivate_win.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_datetimeparser
+ SOURCES
+ tools/qdatetimeparser.cpp tools/qdatetimeparser_p.h
+)
+
+extend_target(Core CONDITION QT_FEATURE_regularexpression
+ SOURCES
+ tools/qregularexpression.cpp tools/qregularexpression.h
+ LIBRARIES
+ PCRE2
+)
+
+extend_target(Core CONDITION QT_FEATURE_commandlineparser
+ SOURCES
+ tools/qcommandlineoption.cpp tools/qcommandlineoption.h
+ tools/qcommandlineparser.cpp tools/qcommandlineparser.h
+)
+
+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
+)
+
+extend_target(Core CONDITION QT_FEATURE_zstd
+ LIBRARIES
+ ZSTD::ZSTD
+)
+
+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
+)
+
+extend_target(Core CONDITION QT_FEATURE_filesystemwatcher AND WIN32
+ SOURCES
+ io/qfilesystemwatcher_win.cpp io/qfilesystemwatcher_win_p.h
+)
+
+extend_target(Core CONDITION APPLE_OSX AND QT_FEATURE_filesystemwatcher
+ SOURCES
+ io/qfilesystemwatcher_fsevents.mm io/qfilesystemwatcher_fsevents_p.h
+)
+
+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
+)
+
+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
+)
+
+extend_target(Core CONDITION QT_FEATURE_processenvironment
+ SOURCES
+ io/qprocess.cpp io/qprocess.h io/qprocess_p.h
+)
+
+extend_target(Core CONDITION QT_FEATURE_processenvironment AND WIN32 AND NOT WINRT
+ SOURCES
+ io/qprocess_win.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_processenvironment AND UNIX
+ SOURCES
+ io/qprocess_unix.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_settings
+ SOURCES
+ io/qsettings.cpp io/qsettings.h io/qsettings_p.h
+)
+
+extend_target(Core CONDITION QT_FEATURE_settings AND WIN32 AND NOT WINRT
+ SOURCES
+ io/qsettings_win.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_settings AND WINRT
+ SOURCES
+ io/qsettings_winrt.cpp
+)
+
+extend_target(Core CONDITION APPLE AND QT_FEATURE_settings AND NOT NACL
+ SOURCES
+ io/qsettings_mac.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_filesystemiterator AND WIN32
+ SOURCES
+ io/qfilesystemiterator_win.cpp
+)
+
+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
+)
+
+extend_target(Core CONDITION UNIX AND NOT APPLE_UIKIT AND NOT INTEGRITY
+ SOURCES
+ ../3rdparty/forkfd/forkfd.h
+ io/forkfd_qt.cpp
+ INCLUDE_DIRECTORIES
+ ../3rdparty/forkfd
+)
+
+extend_target(Core CONDITION APPLE_OSX AND QT_FEATURE_processenvironment
+ SOURCES
+ io/qprocess_darwin.mm
+)
+
+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
+)
+
+extend_target(Core CONDITION HAIKU AND (ANDROID_EMBEDDED OR NOT ANDROID)
+ SOURCES
+ io/qstandardpaths_haiku.cpp
+ io/qstorageinfo_unix.cpp
+ PUBLIC_LIBRARIES
+ be
+)
+
+extend_target(Core CONDITION UNIX AND NOT APPLE_OSX AND NOT HAIKU AND (ANDROID_EMBEDDED OR NOT ANDROID)
+ SOURCES
+ io/qstandardpaths_unix.cpp
+ io/qstorageinfo_unix.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_proxymodel
+ SOURCES
+ itemmodels/qabstractproxymodel.cpp itemmodels/qabstractproxymodel.h itemmodels/qabstractproxymodel_p.h
+)
+
+extend_target(Core CONDITION QT_FEATURE_concatenatetablesproxymodel AND QT_FEATURE_proxymodel
+ SOURCES
+ itemmodels/qconcatenatetablesproxymodel.cpp itemmodels/qconcatenatetablesproxymodel.h
+)
+
+extend_target(Core CONDITION QT_FEATURE_identityproxymodel AND QT_FEATURE_proxymodel
+ SOURCES
+ itemmodels/qidentityproxymodel.cpp itemmodels/qidentityproxymodel.h
+)
+
+extend_target(Core CONDITION QT_FEATURE_proxymodel AND QT_FEATURE_sortfilterproxymodel
+ SOURCES
+ itemmodels/qsortfilterproxymodel.cpp itemmodels/qsortfilterproxymodel.h
+)
+
+extend_target(Core CONDITION QT_FEATURE_proxymodel AND QT_FEATURE_transposeproxymodel
+ SOURCES
+ itemmodels/qtransposeproxymodel.cpp itemmodels/qtransposeproxymodel.h itemmodels/qtransposeproxymodel_p.h
+)
+
+extend_target(Core CONDITION QT_FEATURE_stringlistmodel
+ SOURCES
+ itemmodels/qstringlistmodel.cpp itemmodels/qstringlistmodel.h
+)
+
+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
+ LIBRARIES
+ ${CMAKE_DL_LIBS}
+)
+
+extend_target(Core CONDITION QT_FEATURE_library AND UNIX
+ SOURCES
+ plugin/qlibrary_unix.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_library AND WIN32
+ SOURCES
+ plugin/qlibrary_win.cpp
+)
+
+extend_target(Core CONDITION APPLE_OSX AND (APPLE_IOS OR APPLE_TVOS)
+ LIBRARIES
+ ${FWUIKit}
+)
+
+extend_target(Core CONDITION APPLE_OSX AND APPLE_WATCHOS
+ LIBRARIES
+ ${FWWatchKit}
+)
+
+extend_target(Core CONDITION NACL
+ SOURCES
+ kernel/qfunctions_nacl.cpp kernel/qfunctions_nacl.h
+)
+
+extend_target(Core CONDITION INTEGRITY OR (NACL AND UNIX) OR (UNIX AND NOT APPLE)
+ SOURCES
+ kernel/qelapsedtimer_unix.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_poll_select AND UNIX
+ SOURCES
+ kernel/qpoll.cpp
+)
+
+extend_target(Core CONDITION QT_FEATURE_glib AND UNIX
+ SOURCES
+ kernel/qeventdispatcher_glib.cpp kernel/qeventdispatcher_glib_p.h
+ LIBRARIES
+ GLIB2::GLIB2
+)
+
+extend_target(Core CONDITION QT_FEATURE_clock_gettime AND UNIX
+ LIBRARIES
+ WrapRt
+)
+
+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
+)
+
+extend_target(Core CONDITION ANDROID
+ SOURCES
+ kernel/qsharedmemory_android.cpp
+ kernel/qsystemsemaphore_android.cpp
+)
+
+extend_target(Core CONDITION VXWORKS
+ SOURCES
+ kernel/qfunctions_vxworks.cpp kernel/qfunctions_vxworks.h
+)
+
+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
+)
+
+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
+)
+
+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
+)
+
+extend_target(Core CONDITION QT_FEATURE_icu AND QT_FEATURE_textcodec
+ SOURCES
+ codecs/qicucodec.cpp codecs/qicucodec_p.h
+)
+
+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
+)
+
+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
+)
+
+extend_target(Core CONDITION QT_FEATURE_textcodec AND WIN32 AND NOT QT_FEATURE_icu
+ SOURCES
+ codecs/qwindowscodec.cpp codecs/qwindowscodec_p.h
+)
+
+extend_target(Core CONDITION QT_FEATURE_qeventtransition
+ SOURCES
+ statemachine/qeventtransition.cpp statemachine/qeventtransition.h statemachine/qeventtransition_p.h
+)
+
+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:
+set_source_files_properties("mimetypes/mime/packages/freedesktop.org.xml"
+ PROPERTIES alias "freedesktop.org.xml")
+add_qt_resource(Core "mimetypes" PREFIX "/qt-project.org/qmime/packages" BASE "mimetypes" FILES
+ mime/packages/freedesktop.org.xml)
+
+
+extend_target(Core CONDITION WASM
+ SOURCES
+ platform/wasm/qstdweb.cpp platform/wasm/qstdweb_p.h
+)
+
+# special case:
+# 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()
+ add_qt_simd_part(Core SIMD f16c
+ SOURCES
+ global/qfloat16_f16c.c
+ )
+endif()
+
+# special case:
+add_custom_command(OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/global/qfloat16tables.cpp"
+ COMMAND qfloat16-tables
+ ARGS "${CMAKE_CURRENT_BINARY_DIR}/global/qfloat16tables.cpp"
+ DEPENDS global/qfloat16.h
+ COMMENT qfloat16-tables
+ VERBATIM)
+target_sources(Core PRIVATE "${CMAKE_CURRENT_BINARY_DIR}/global/qfloat16tables.cpp")
+
+# special case:
+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!
+
+# special case
+# 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) # special case
+
+qt_create_tracepoints(Core ./qtcore.tracepoints)
+add_qt_docs(
+ ./doc/qtcore.qdocconf
+)
diff --git a/src/corelib/Qt5CoreConfigExtras.cmake.in b/src/corelib/Qt5CoreConfigExtras.cmake.in
index e0652fdcf9..3775fc64b9 100644
--- a/src/corelib/Qt5CoreConfigExtras.cmake.in
+++ b/src/corelib/Qt5CoreConfigExtras.cmake.in
@@ -1,75 +1,18 @@
-
-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(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
+set_property(TARGET @QT_CMAKE_EXPORT_NAMESPACE@::Core PROPERTY INTERFACE_QT_MAJOR_VERSION @PROJECT_MAJOR_VERSION@)
+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
)
-include(\"${CMAKE_CURRENT_LIST_DIR}/Qt5CoreConfigExtrasMkspecDir.cmake\")
+# include(\"${CMAKE_CURRENT_LIST_DIR}/Qt5CoreConfigExtrasMkspecDir.cmake\")
+#
+# foreach(_dir ${_qt5_corelib_extra_includes})
+# _qt5_Core_check_file_exists(${_dir})
+# endforeach()
-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)
+# 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)
# 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
@@ -78,96 +21,12 @@ set(Qt5_POSITION_INDEPENDENT_CODE True)
# 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()
+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()
-!!ENDIF
-
-get_filename_component(_Qt5CoreConfigDir ${CMAKE_CURRENT_LIST_FILE} PATH)
-set(_Qt5CTestMacros \"${_Qt5CoreConfigDir}/Qt5CTestMacros.cmake\")
-
-_qt5_Core_check_file_exists(${_Qt5CTestMacros})
+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)
diff --git a/src/corelib/Qt5CoreMacros.cmake b/src/corelib/Qt5CoreMacros.cmake
index 78b99f5bfe..bae1518375 100644
--- a/src/corelib/Qt5CoreMacros.cmake
+++ b/src/corelib/Qt5CoreMacros.cmake
@@ -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)
@@ -249,7 +249,7 @@ 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})
@@ -282,7 +282,7 @@ function(QT5_ADD_RESOURCES outfiles )
set_source_files_properties(${infile} PROPERTIES SKIP_AUTORCC ON)
add_custom_command(OUTPUT ${outfile}
- COMMAND ${Qt5Core_RCC_EXECUTABLE}
+ COMMAND ${QT_CMAKE_EXPORT_NAMESPACE}::rcc
ARGS ${rcc_options} --name ${outfilename} --output ${outfile} ${infile}
MAIN_DEPENDENCY ${infile}
DEPENDS ${_rc_depends} "${_out_depends}" VERBATIM)
@@ -319,7 +319,7 @@ function(QT5_ADD_BIG_RESOURCES outfiles )
_QT5_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})
@@ -327,7 +327,7 @@ function(QT5_ADD_BIG_RESOURCES outfiles )
set_target_properties(rcc_object_${outfilename} PROPERTIES AUTOUIC OFF)
add_dependencies(rcc_object_${outfilename} big_resources_${outfilename})
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)
diff --git a/src/corelib/configure.cmake b/src/corelib/configure.cmake
new file mode 100644
index 0000000000..10d2ea60de
--- /dev/null
+++ b/src/corelib/configure.cmake
@@ -0,0 +1,893 @@
+
+
+#### Inputs
+
+# input iconv
+set(INPUT_iconv "undefined" CACHE STRING "")
+set_property(CACHE INPUT_iconv PROPERTY STRINGS undefined no yes posix sun gnu)
+
+
+
+#### Libraries
+
+find_package(GLIB2)
+set_package_properties(GLIB2 PROPERTIES TYPE OPTIONAL)
+find_package(ICU COMPONENTS i18n uc data)
+set_package_properties(ICU PROPERTIES TYPE OPTIONAL)
+find_package(Libsystemd)
+set_package_properties(Libsystemd PROPERTIES TYPE OPTIONAL)
+find_package(Atomic)
+set_package_properties(Atomic PROPERTIES TYPE OPTIONAL)
+find_package(WrapRt)
+set_package_properties(WrapRt PROPERTIES TYPE OPTIONAL)
+find_package(LTTngUST)
+set_package_properties(LTTngUST PROPERTIES TYPE OPTIONAL)
+find_package(PCRE2)
+set_package_properties(PCRE2 PROPERTIES TYPE REQUIRED)
+find_package(PPS)
+set_package_properties(PPS PROPERTIES TYPE OPTIONAL)
+find_package(Slog2)
+set_package_properties(Slog2 PROPERTIES TYPE OPTIONAL)
+
+
+#### Tests
+
+# atomicfptr
+qt_config_compile_test(atomicfptr
+ LABEL "working std::atomic for function pointers"
+"
+#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"
+"
+#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;
+}
+"# FIXME: use: librt
+)
+
+# cloexec
+qt_config_compile_test(cloexec
+ LABEL "O_CLOEXEC"
+"#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>"
+"
+#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"
+"
+#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()"
+"
+#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()"
+"
+#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()"
+"
+#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()"
+"
+#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"
+"
+#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"
+"
+#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"
+"
+#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()"
+"#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()"
+"
+#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()"
+"
+#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()"
+"
+#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()"
+"#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"
+"#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"
+"
+#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)"
+"
+
+#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@/tools/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("dlopen" PRIVATE
+ LABEL "dlopen()"
+ CONDITION UNIX
+)
+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("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("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("systemsemaphore" PUBLIC
+ SECTION "Kernel"
+ LABEL "QSystemSemaphore"
+ PURPOSE "Provides a general counting system semaphore."
+ CONDITION ( NOT INTEGRITY AND NOT VXWORKS ) 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 convertion 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
+)
+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
+)
+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("animation" PUBLIC
+ SECTION "Utilities"
+ LABEL "Animation"
+ PURPOSE "Provides a framework for animations."
+ CONDITION QT_FEATURE_properties
+)
+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("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."
+)
diff --git a/src/corelib/configure.json b/src/corelib/configure.json
index a6091d4825..cdf9586100 100644
--- a/src/corelib/configure.json
+++ b/src/corelib/configure.json
@@ -730,11 +730,6 @@
"condition": "libs.pps",
"output": [ "privateFeature" ]
},
- "qeventtransition": {
- "label": "QEventTransition class",
- "condition": "features.statemachine",
- "output": [ "publicFeature" ]
- },
"renameat2": {
"label": "renameat2()",
"condition": "config.linux && tests.renameat2",
@@ -963,6 +958,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.",
@@ -1011,10 +1011,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" ]
}
@@ -1024,10 +1021,7 @@ Mozilla License) is included. The data is then also used in QNetworkCookieJar::v
{
"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",
@@ -1037,15 +1031,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"
}
],
diff --git a/src/corelib/global/qconfig.cpp.in b/src/corelib/global/qconfig.cpp.in
new file mode 100644
index 0000000000..6f589b3771
--- /dev/null
+++ b/src/corelib/global/qconfig.cpp.in
@@ -0,0 +1,65 @@
+/* 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[] = {
+ 0,
+ 4,
+ 12,
+ 16,
+ 24,
+ 28,
+ 36,
+ 44,
+ 48,
+ 50,
+ 52,
+ 65,
+ 74,
+#ifdef QT_BUILD_QMAKE
+ 80,
+ 81,
+ 87,
+ 91,
+ 95,
+ 97,
+ 107,
+#endif
+};
+static const char qt_configure_strs[] =
+ "doc\0"
+ "include\0"
+ "lib\0"
+ "libexec\0"
+ "bin\0"
+ "plugins\0"
+ "imports\0"
+ "qml\0"
+ ".\0"
+ ".\0"
+ "translations\0"
+ "examples\0"
+ "tests\0"
+#ifdef QT_BUILD_QMAKE
+ "\0"
+ "false\0"
+ "bin\0"
+ "lib\0"
+ ".\0"
+ "linux-g++\0"
+ "linux-g++\0"
+#endif
+;
+#define QT_CONFIGURE_SETTINGS_PATH "etc/xdg"
+#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/kernel/qvariant.cpp b/src/corelib/kernel/qvariant.cpp
index cd4e233af0..ec5c39d8c1 100644
--- a/src/corelib/kernel/qvariant.cpp
+++ b/src/corelib/kernel/qvariant.cpp
@@ -4227,8 +4227,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 a null pointer 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/dbus/CMakeLists.txt b/src/dbus/CMakeLists.txt
new file mode 100644
index 0000000000..d17667a26a
--- /dev/null
+++ b/src/dbus/CMakeLists.txt
@@ -0,0 +1,74 @@
+# Generated from dbus.pro.
+
+#####################################################################
+## DBus Module:
+#####################################################################
+
+add_qt_module(DBus
+ 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 # special case
+ # MODULE_CONFIG = "dbusadaptors" "dbusinterfaces"
+ # _LOADED = "qt_module"
+)
+
+set_source_files_properties(qdbusmarshaller.cpp
+ PROPERTIES HEADER_FILE_ONLY ON) # special case: This file is included by qdbusargument.cpp
+
+
+## Scopes:
+#####################################################################
+
+extend_target(DBus CONDITION QT_FEATURE_dbus_linked
+ DEFINES
+ QT_LINKED_LIBDBUS
+ LIBRARIES
+ dbus
+)
+
+extend_target(DBus CONDITION WIN32
+ LIBRARIES
+ ws2_32
+ advapi32
+ netapi32
+ user32
+)
+
+add_qt_docs(./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/Qt5DBusMacros.cmake
index b381ab0934..ce430ed9cd 100644
--- a/src/dbus/Qt5DBusMacros.cmake
+++ b/src/dbus/Qt5DBusMacros.cmake
@@ -58,7 +58,7 @@ 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)
@@ -111,7 +111,7 @@ 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()
@@ -135,12 +135,12 @@ 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()
diff --git a/src/gui/CMakeLists.txt b/src/gui/CMakeLists.txt
new file mode 100644
index 0000000000..fb60ac2781
--- /dev/null
+++ b/src/gui/CMakeLists.txt
@@ -0,0 +1,647 @@
+# Generated from gui.pro.
+
+# special case:
+set(OpenGL_GL_PREFERENCE GLVND)
+
+#####################################################################
+## Gui Module:
+#####################################################################
+
+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 "webassembly")
+ else()
+ set(_default_platform "xcb")
+ endif()
+
+ set(QT_QPA_DEFAULT_PLATFORM "${_default_platform}" CACHE STRING "QPA default platform")
+endif()
+
+add_qt_module(Gui
+ FEATURE_DEPENDENCIES # special case:
+ Qt::Network
+ 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_compat.cpp
+ 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/qpictureformatplugin.cpp image/qpictureformatplugin.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/qkeysequence.cpp kernel/qkeysequence.h kernel/qkeysequence_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/qshortcutmap.cpp kernel/qshortcutmap_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.cpp 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
+ 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/qshadergenerator.cpp util/qshadergenerator_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_USING_NAMESPACE
+ QT_NO_FOREACH
+ QT_QPA_DEFAULT_PLATFORM_NAME="${QT_QPA_DEFAULT_PLATFORM}" # special case
+ LIBRARIES
+ Qt::CorePrivate
+ ZLIB::ZLIB # special case
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+# Resources:
+
+# special case:
+# This name is fixed in the code:-/
+add_qt_resource(Gui qmake_webgradients PREFIX "/qgradient" BASE "painting" FILES
+ webgradients.binaryjson
+)
+
+set_source_files_properties("painting/../../3rdparty/icc/sRGB2014.icc"
+ PROPERTIES alias "sRGB2014.icc")
+add_qt_resource(Gui "qpdf" PREFIX "qpdf/" BASE "painting" FILES
+ ../../3rdparty/icc/sRGB2014.icc
+ qpdfa_metadata.xml)
+
+add_qt_simd_part(Gui SIMD sse2
+ SOURCES
+ painting/qdrawhelper_sse2.cpp
+)
+
+add_qt_simd_part(Gui SIMD ssse3
+ SOURCES
+ image/qimage_ssse3.cpp
+ painting/qdrawhelper_ssse3.cpp
+)
+
+add_qt_simd_part(Gui SIMD sse4_1
+ SOURCES
+ painting/qdrawhelper_sse4.cpp
+ painting/qimagescale_sse4.cpp
+)
+
+add_qt_simd_part(Gui SIMD neon
+ SOURCES
+ image/qimage_neon.cpp
+ painting/qdrawhelper_neon.cpp painting/qdrawhelper_neon_p.h
+ painting/qimagescale_neon.cpp
+)
+
+add_qt_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
+)
+
+add_qt_simd_part(Gui SIMD mips_dspr2
+ SOURCES
+ image/qimage_mips_dspr2.cpp
+ image/qimage_mips_dspr2_asm.S
+ painting/qdrawhelper_mips_dspr2_asm.S
+)
+
+# special case: Replace arch_haswell with avx2 feature. That is what is used in the code requireing
+# this file, too!
+add_qt_simd_part(Gui SIMD avx2
+ SOURCES
+ painting/qdrawhelper_avx2.cpp
+)
+
+#special case:
+extend_target(Gui CONDITION QT_FEATURE_standarditemmodel
+ SOURCES
+ itemmodels/qstandarditemmodel.cpp itemmodels/qstandarditemmodel.h itemmodels/qstandarditemmodel_p.h
+)
+
+
+#### Keys ignored in scope 1:.:.:gui.pro:<TRUE>:
+# CONFIG = "simd" "optimize_full" "qt_tracepoints"
+# 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"
+# _LOADED = "qt_module" "cmake_functions"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:gui.pro:qtConfig(opengl._x_):
+# MODULE_CONFIG = "opengl"
+
+#### Keys ignored in scope 3:.:.:gui.pro:QT_FEATURE_angle:
+# MODULE_AUX_INCLUDES = "\$\$QT_MODULE_INCLUDE_BASE/QtANGLE"
+
+#### Keys ignored in scope 4:.:.:gui.pro:testcocoon:
+# _LOADED = "testcocoon"
+
+extend_target(Gui CONDITION APPLE_OSX
+ LIBRARIES
+ ${FWAppKit}
+)
+
+extend_target(Gui CONDITION APPLE
+ SOURCES
+ image/qimage_darwin.mm
+ painting/qcoregraphics.mm painting/qcoregraphics_p.h
+ LIBRARIES
+ ${FWCoreGraphics}
+)
+
+extend_target(Gui CONDITION QT_FEATURE_animation
+ SOURCES
+ animation/qguivariantanimation.cpp
+)
+
+extend_target(Gui CONDITION WIN32
+ SOURCES
+ kernel/qwindowdefs_win.h
+)
+
+#### 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_OSX:
+# CMAKE_GL_HEADER_NAME = "gl.h"
+
+#### Keys ignored in scope 22:.:.:gui.pro:QT_FEATURE_egl:
+# CMAKE_EGL_INCDIRS = "$$cmakePortablePaths$$QMAKE_INCDIR_EGL"
+
+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
+)
+
+extend_target(Gui CONDITION APPLE_OSX AND QT_FEATURE_accessibility
+ SOURCES
+ accessible/qaccessiblecache_mac.mm
+ LIBRARIES
+ ${FWFoundation}
+)
+
+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
+)
+
+# special case:
+# With qmake, gui's opengl.pri used CONFIG += opengl, where opengl.prf
+# acted like WrapOpenGL: direct 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 add_qt_module call.
+find_package(WrapOpenGL) # special case
+
+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
+ LIBRARIES # special case
+ WrapOpenGL
+)
+
+extend_target(Gui CONDITION QT_FEATURE_movie
+ SOURCES
+ image/qmovie.cpp image/qmovie.h
+)
+
+extend_target(Gui CONDITION WIN32 AND NOT WINRT
+ SOURCES
+ image/qpixmap_win.cpp
+)
+
+extend_target(Gui CONDITION QT_FEATURE_png
+ SOURCES
+ image/qpnghandler.cpp image/qpnghandler_p.h
+ LIBRARIES
+ PNG::PNG
+)
+
+extend_target(Gui CONDITION QT_FEATURE_harfbuzz
+ SOURCES
+ text/qharfbuzzng.cpp text/qharfbuzzng_p.h
+ LIBRARIES
+ harfbuzz::harfbuzz
+)
+
+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
+)
+
+extend_target(Gui CONDITION QT_FEATURE_cssparser
+ SOURCES
+ painting/qcssutil.cpp
+ text/qcssparser.cpp text/qcssparser_p.h
+)
+
+# special case:
+# extend_target(Gui CONDITION GCC AND QT_GCC_MAJOR_VERSION___equals___5 ...
+
+#### Keys ignored in scope 45:.:painting:painting/painting.pri:NOT APPLE_UIKIT AND NOT WIN32 AND QT_ARCH___contains___arm:
+# CONFIG = "no_clang_integrated_as"
+
+extend_target(Gui CONDITION UNIX AND NOT APPLE_UIKIT AND NOT INTEGRITY AND NOT (TEST_architecture_arch STREQUAL "arm64")
+ DEFINES
+ ENABLE_PIXMAN_DRAWHELPERS
+)
+
+# special case:
+extend_target(Gui CONDITION UNIX AND NOT APPLE_UIKIT AND NOT INTEGRITY AND NOT (TEST_architecture_arch STREQUAL "arm64" AND QT_FEATURE_neon)
+ SOURCES
+ ../3rdparty/pixman/pixman-arm-neon-asm.S
+ painting/qdrawhelper_neon_asm.S
+)
+
+
+#### Keys ignored in scope 46:.:painting:painting/painting.pri:NOT APPLE_UIKIT AND NOT WIN32 AND NOT INTEGRITY AND NOT QT_ARCH___contains___arm64:
+# NEON_ASM = "../3rdparty/pixman/pixman-arm-neon-asm.S" "painting/qdrawhelper_neon_asm.S"
+
+#### Keys ignored in scope 55:.:opengl:opengl/opengl.pri:QT_FEATURE_opengles2:
+# CONFIG = "opengles2"
+
+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
+)
+
+extend_target(Gui CONDITION QT_FEATURE_opengl AND QT_FEATURE_opengles2
+ SOURCES
+ opengl/qopenglfunctions_es2.cpp opengl/qopenglfunctions_es2.h
+)
+
+# special case
+# 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()
+
+extend_target(Gui CONDITION QT_FEATURE_vulkan
+ SOURCES
+ 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
+)
+
+# special case:
+if (QT_FEATURE_vulkan)
+ set(qvkgen_command "${HOST_QVKGEN}")
+ if (TARGET qvkgen)
+ set(qvkgen_command qvkgen)
+ endif()
+
+ set(vulkan_fun "qvulkanfunctions.h")
+ set(vulkan_fun_p "qvulkanfunctions_p.h")
+ set(vulkan_fun_p_cpp "qvulkanfunctions_p.cpp")
+
+ add_custom_command(
+ OUTPUT "vulkan/${vulkan_fun}" "vulkan/${vulkan_fun_p}" "vulkan/${vulkan_fun_p_cpp}"
+ COMMAND "${CMAKE_COMMAND}" -E make_directory "${CMAKE_CURRENT_BINARY_DIR}/vulkan/"
+ COMMAND "${qvkgen_command}"
+ "${CMAKE_CURRENT_SOURCE_DIR}/vulkan/vk.xml"
+ "${PROJECT_SOURCE_DIR}/header.LGPL"
+ "${CMAKE_CURRENT_BINARY_DIR}/vulkan/qvulkanfunctions"
+ DEPENDS vulkan/vk.xml
+ WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"
+ COMMENT "Generating vulkan data"
+ )
+
+ qt_generate_forwarding_headers("Gui" SOURCE "vulkan/${vulkan_fun}"
+ DESTINATION "qvulkanfunctions.h"
+ CLASSES QVulkanFunctions QVulkanDeviceFunctions
+ )
+ qt_generate_forwarding_headers("Gui" SOURCE "vulkan/${vulkan_fun_p}"
+ DESTINATION "qvulkanfunctions_p.h" PRIVATE
+ )
+
+ extend_target(Gui CONDITION QT_FEATURE_vulkan
+ 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}"
+ )
+endif()
+
+#### Keys ignored in scope 62:.:vulkan:vulkan/vulkan.pri:QT_FEATURE_vulkan:
+# CONFIG = "generated_privates"
+
+#### Keys ignored in scope 64:.:vulkan:vulkan/vulkan.pri:else:
+# qvkgen_h.CONFIG = "target_predeps" "no_link"
+
+extend_target(Gui CONDITION WASM
+ SOURCES
+ platform/wasm/qwasmlocalfileaccess.cpp platform/wasm/qwasmlocalfileaccess_p.h
+)
+
+# special case:
+# qpa headers are expected to be located right next to QtGui's private
+# headers. So a private QtGui header is #include <private/qfoo_p.h> and
+# a qpa header is #include <qpa/qplatformfoo.h>, both of them implying
+# linkage against Qt::GuiPrivate.
+qt_read_headers_pri("Gui" "module_headers") # special case
+install(FILES ${module_headers_qpa}
+ DESTINATION ${INSTALL_INCLUDEDIR}/QtGui/${PROJECT_VERSION}/QtGui/qpa) # special case
+
+qt_create_tracepoints(Gui qtgui.tracepoints)
+add_qt_docs(
+ doc/qtgui.qdocconf
+)
diff --git a/src/gui/configure.cmake b/src/gui/configure.cmake
new file mode 100644
index 0000000000..354be5bd44
--- /dev/null
+++ b/src/gui/configure.cmake
@@ -0,0 +1,990 @@
+
+
+#### 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 libpng
+set(INPUT_libpng "undefined" CACHE STRING "")
+set_property(CACHE INPUT_libpng PROPERTY STRINGS undefined no qt system)
+
+# input xcb
+set(INPUT_xcb "undefined" CACHE STRING "")
+set_property(CACHE INPUT_xcb PROPERTY STRINGS undefined no yes qt system)
+
+
+
+#### Libraries
+
+find_package(ATSPI2)
+set_package_properties(ATSPI2 PROPERTIES TYPE OPTIONAL)
+find_package(Libdrm)
+set_package_properties(Libdrm PROPERTIES TYPE OPTIONAL)
+find_package(EGL)
+set_package_properties(EGL PROPERTIES TYPE OPTIONAL)
+find_package(Freetype)
+set_package_properties(Freetype PROPERTIES TYPE OPTIONAL)
+find_package(Fontconfig)
+set_package_properties(Fontconfig PROPERTIES TYPE OPTIONAL)
+find_package(gbm)
+set_package_properties(gbm PROPERTIES TYPE OPTIONAL)
+find_package(harfbuzz)
+set_package_properties(harfbuzz PROPERTIES TYPE OPTIONAL)
+find_package(Libinput)
+set_package_properties(Libinput PROPERTIES TYPE OPTIONAL)
+find_package(JPEG)
+set_package_properties(JPEG PROPERTIES TYPE OPTIONAL)
+find_package(PNG)
+set_package_properties(PNG PROPERTIES TYPE OPTIONAL)
+find_package(Mtdev)
+set_package_properties(Mtdev PROPERTIES TYPE OPTIONAL)
+find_package(OpenGL)
+set_package_properties(OpenGL PROPERTIES TYPE OPTIONAL)
+find_package(GLESv2)
+set_package_properties(GLESv2 PROPERTIES TYPE OPTIONAL)
+find_package(Tslib)
+set_package_properties(Tslib PROPERTIES TYPE OPTIONAL)
+find_package(Vulkan)
+set_package_properties(Vulkan PROPERTIES TYPE OPTIONAL)
+find_package(Wayland)
+set_package_properties(Wayland PROPERTIES TYPE OPTIONAL)
+find_package(X11)
+set_package_properties(X11 PROPERTIES TYPE OPTIONAL)
+find_package(XCB 1.9)
+set_package_properties(XCB PROPERTIES TYPE OPTIONAL)
+find_package(X11_XCB)
+set_package_properties(X11_XCB PROPERTIES TYPE OPTIONAL)
+find_package(XKB 0.4.1)
+set_package_properties(XKB PROPERTIES TYPE OPTIONAL)
+
+
+#### Tests
+
+# angle_d3d11_qdtd
+qt_config_compile_test(angle_d3d11_qdtd
+ LABEL "D3D11_QUERY_DATA_TIMESTAMP_DISJOINT"
+"
+#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"
+"#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;
+}
+"# FIXME: use: drm
+)
+
+# egl-x11
+qt_config_compile_test(egl_x11
+ LABEL "EGL on X11"
+"// 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;
+}
+"# FIXME: use: egl xlib
+)
+
+# egl-brcm
+qt_config_compile_test(egl_brcm
+ LABEL "Broadcom EGL (Raspberry Pi)"
+"
+#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: egl bcm_host
+)
+
+# egl-egldevice
+qt_config_compile_test(egl_egldevice
+ LABEL "EGLDevice"
+"
+#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;
+}
+"# FIXME: use: egl
+)
+
+# egl-mali
+qt_config_compile_test(egl_mali
+ LABEL "Mali EGL"
+"
+#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;
+}
+"# FIXME: use: egl
+)
+
+# egl-mali-2
+qt_config_compile_test(egl_mali_2
+ LABEL "Mali 2 EGL"
+"
+#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;
+}
+"# FIXME: use: egl
+)
+
+# egl-viv
+qt_config_compile_test(egl_viv
+ LABEL "i.Mx6 EGL"
+"
+#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']
+# FIXME: use: egl
+)
+
+# egl-openwfd
+qt_config_compile_test(egl_openwfd
+ LABEL "OpenWFD EGL"
+"
+#include <wfd.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+wfdEnumerateDevices(nullptr, 0, nullptr);
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: use: egl
+)
+
+# egl-rcar
+qt_config_compile_test(egl_rcar
+ LABEL "RCAR EGL"
+"
+#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;
+}
+"# FIXME: use: egl opengl_es2
+)
+
+# evdev
+qt_config_compile_test(evdev
+ LABEL "evdev"
+"#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"
+"
+#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"
+"
+#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"
+"#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;
+}
+"# FIXME: use: opengl_es2
+)
+
+# opengles31
+qt_config_compile_test(opengles31
+ LABEL "OpenGL ES 3.1"
+"
+#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;
+}
+"# FIXME: use: opengl_es2
+)
+
+# opengles32
+qt_config_compile_test(opengles32
+ LABEL "OpenGL ES 3.2"
+"
+#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;
+}
+"# FIXME: use: opengl_es2
+)
+
+# xcb_syslibs
+qt_config_compile_test(xcb_syslibs
+ LABEL "XCB (extensions)"
+"
+#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>
+
+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);
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: use: xcb_icccm xcb_image xcb_keysyms xcb_randr xcb_render xcb_renderutil xcb_shape xcb_shm xcb_sync xcb_xfixes xcb_xinerama xcb
+)
+
+
+
+#### 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 libs.directfb OR FIXME
+)
+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 WIN32 AND ON AND FONTCONFIG_FOUND
+)
+qt_feature_definition("fontconfig" "QT_NO_FONTCONFIG" NEGATE VALUE "1")
+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("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("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("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"
+ AUTODETECT OFF
+ CONDITION WIN32 AND NOT WINRT
+ 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("vulkan" PUBLIC
+ LABEL "Vulkan"
+ CONDITION 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 )
+)
+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 QT_FEATURE_xkbcommon AND XCB_FOUND
+ ENABLE INPUT_xcb STREQUAL 'system' OR INPUT_xcb STREQUAL 'qt' OR INPUT_xcb STREQUAL 'yes'
+)
+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)"
+ CONDITION QT_FEATURE_xcb_xlib AND QT_FEATURE_fontconfig AND XCB_RENDER_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("xkb" PRIVATE
+ LABEL "XCB XKB"
+ CONDITION ( NOT ON OR XCB_XKB_FOUND ) AND libs.xkbcommon_x11 OR FIXME
+ EMIT_IF QT_FEATURE_xcb
+)
+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("xcb_xinput" PRIVATE
+ LABEL "XCB XInput"
+ CONDITION NOT ON OR XCB_XINPUT_FOUND
+ EMIT_IF QT_FEATURE_xcb
+)
+qt_feature("xkbcommon" PRIVATE
+ LABEL "xkbcommon"
+ CONDITION 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("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("shortcut" PUBLIC
+ SECTION "Kernel"
+ LABEL "QShortcut"
+ PURPOSE "Provides keyboard accelerators and shortcuts."
+)
+qt_feature_definition("shortcut" "QT_NO_SHORTCUT" NEGATE VALUE "1")
+qt_feature("action" PUBLIC
+ SECTION "Kernel"
+ LABEL "QAction"
+ PURPOSE "Provides widget 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
+)
+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
+)
+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 5bcfbc88bf..ce6524ac2f 100644
--- a/src/gui/configure.json
+++ b/src/gui/configure.json
@@ -1328,8 +1328,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",
@@ -1798,9 +1797,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",
@@ -1815,16 +1812,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",
@@ -1834,9 +1827,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/gui/util/qshaderlanguage_p.h b/src/gui/util/qshaderlanguage_p.h
index 3af967b8c6..441f7a58d5 100644
--- a/src/gui/util/qshaderlanguage_p.h
+++ b/src/gui/util/qshaderlanguage_p.h
@@ -59,7 +59,8 @@ QT_BEGIN_NAMESPACE
namespace QShaderLanguage
{
- Q_GUI_EXPORT Q_NAMESPACE
+ Q_GUI_EXPORT
+ Q_NAMESPACE
enum StorageQualifier : char {
Const = 1,
diff --git a/src/network/CMakeLists.txt b/src/network/CMakeLists.txt
new file mode 100644
index 0000000000..02d31fc468
--- /dev/null
+++ b/src/network/CMakeLists.txt
@@ -0,0 +1,418 @@
+# Generated from network.pro.
+
+#####################################################################
+## Network Module:
+#####################################################################
+
+add_qt_module(Network
+ 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/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/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/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_USING_NAMESPACE
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ kernel
+ LIBRARIES
+ Qt::CorePrivate
+ ZLIB::ZLIB # special case
+ PUBLIC_LIBRARIES
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:.:network.pro:<TRUE>:
+# MODULE_PLUGIN_TYPES = "bearer"
+# MODULE_WINRT_CAPABILITIES = "internetClient" "internetClientServer" "privateNetworkClientServer"
+# QMAKE_LIBS = "$$QMAKE_LIBS_NETWORK"
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+extend_target(Network CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x64000000"
+)
+
+#### Keys ignored in scope 3:.:.:network.pro:QT_FEATURE_bearermanagement:
+# ANDROID_BUNDLED_JAR_DEPENDENCIES = "jar/QtAndroidBearer.jar"
+# ANDROID_LIB_DEPENDENCIES = "plugins/bearer/libqandroidbearer.so"
+# ANDROID_PERMISSIONS = "android.permission.ACCESS_NETWORK_STATE"
+# MODULE_PLUGIN_TYPES = "bearer"
+
+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
+)
+
+extend_target(Network CONDITION QT_FEATURE_networkdiskcache
+ SOURCES
+ access/qnetworkdiskcache.cpp access/qnetworkdiskcache.h access/qnetworkdiskcache_p.h
+)
+
+extend_target(Network CONDITION QT_FEATURE_settings
+ SOURCES
+ access/qhstsstore.cpp access/qhstsstore_p.h
+)
+
+extend_target(Network CONDITION APPLE_OSX
+ SOURCES
+ kernel/qnetworkproxy_mac.cpp
+ LIBRARIES
+ ${FWCoreFoundation}
+ ${FWSecurity}
+)
+
+extend_target(Network CONDITION WASM
+ SOURCES
+ access/qnetworkreplywasmimpl.cpp access/qnetworkreplywasmimpl_p.h
+)
+
+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/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
+)
+
+extend_target(Network CONDITION QT_FEATURE_http AND QT_FEATURE_ssl
+ SOURCES
+ access/qspdyprotocolhandler.cpp access/qspdyprotocolhandler_p.h
+)
+
+extend_target(Network CONDITION QT_FEATURE_dnslookup
+ SOURCES
+ kernel/qdnslookup.cpp kernel/qdnslookup.h kernel/qdnslookup_p.h
+)
+
+extend_target(Network CONDITION UNIX
+ SOURCES
+ kernel/qhostinfo_unix.cpp
+ socket/qnativesocketengine_unix.cpp
+ socket/qnet_unix_p.h
+ LIBRARIES
+ ${CMAKE_DL_LIBS}
+)
+
+# special case: Do not add this to android!
+extend_target(Network CONDITION QT_FEATURE_dnslookup AND UNIX AND NOT INTEGRITY AND NOT ANDROID
+ SOURCES
+ kernel/qdnslookup_unix.cpp
+)
+
+extend_target(Network CONDITION QT_FEATURE_linux_netlink AND UNIX
+ SOURCES
+ kernel/qnetworkinterface_linux.cpp
+)
+
+extend_target(Network CONDITION UNIX AND NOT QT_FEATURE_linux_netlink
+ SOURCES
+ kernel/qnetworkinterface_unix.cpp
+)
+
+extend_target(Network CONDITION ANDROID AND QT_FEATURE_dnslookup
+ SOURCES
+ # kernel/qdnslookup_unix.cpp # special case: No more need to remove this
+ kernel/qdnslookup_android.cpp
+)
+
+extend_target(Network CONDITION WIN32
+ SOURCES
+ kernel/qhostinfo_win.cpp
+)
+
+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
+)
+
+extend_target(Network CONDITION QT_FEATURE_dnslookup AND WIN32 AND NOT WINRT
+ SOURCES
+ kernel/qdnslookup_win.cpp
+)
+
+extend_target(Network CONDITION WINRT
+ SOURCES
+ kernel/qnetworkinterface_winrt.cpp
+ socket/qnativesocketengine_winrt.cpp socket/qnativesocketengine_winrt_p.h
+)
+
+extend_target(Network CONDITION QT_FEATURE_dnslookup AND WINRT
+ SOURCES
+ kernel/qdnslookup_winrt.cpp
+)
+
+extend_target(Network CONDITION APPLE_OSX AND NOT APPLE_UIKIT
+ LIBRARIES
+ ${FWCoreServices}
+ ${FWSystemConfiguration}
+)
+
+extend_target(Network CONDITION QT_FEATURE_gssapi
+ LIBRARIES
+ gssapi_krb5
+)
+
+extend_target(Network CONDITION APPLE_UIKIT
+ SOURCES
+ kernel/qnetworkinterface_uikit_p.h
+)
+
+extend_target(Network CONDITION QT_FEATURE_libproxy AND NOT APPLE_OSX AND (UNIX OR WINRT)
+ SOURCES
+ kernel/qnetworkproxy_libproxy.cpp
+ LIBRARIES
+ ${CMAKE_DL_LIBS}
+ LibProxy::LibProxy
+)
+
+extend_target(Network CONDITION NOT APPLE_OSX AND NOT QT_FEATURE_libproxy AND (UNIX OR WINRT)
+ SOURCES
+ kernel/qnetworkproxy_generic.cpp
+)
+
+extend_target(Network CONDITION QT_FEATURE_socks5
+ SOURCES
+ socket/qsocks5socketengine.cpp socket/qsocks5socketengine_p.h
+)
+
+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
+)
+
+extend_target(Network CONDITION NOT WINRT
+ SOURCES
+ socket/qnativesocketengine.cpp socket/qnativesocketengine_p.h
+)
+
+extend_target(Network CONDITION MSVC
+ MOC_OPTIONS
+ "-D_WINSOCK_DEPRECATED_NO_WARNINGS"
+)
+
+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
+)
+
+extend_target(Network CONDITION QT_FEATURE_localserver AND (INTEGRITY OR WINRT)
+ SOURCES
+ socket/qlocalserver_tcp.cpp
+ socket/qlocalsocket_tcp.cpp
+ DEFINES
+ QT_LOCALSOCKET_TCP
+)
+
+extend_target(Network CONDITION QT_FEATURE_localserver AND UNIX AND NOT INTEGRITY AND NOT WINRT
+ SOURCES
+ socket/qlocalserver_unix.cpp
+ socket/qlocalsocket_unix.cpp
+)
+
+extend_target(Network CONDITION QT_FEATURE_localserver AND WIN32 AND NOT WINRT
+ SOURCES
+ socket/qlocalserver_win.cpp
+ socket/qlocalsocket_win.cpp
+)
+
+extend_target(Network CONDITION QT_FEATURE_system_proxies
+ DEFINES
+ QT_USE_SYSTEM_PROXIES
+)
+
+extend_target(Network CONDITION NOT QT_FEATURE_openssl
+ SOURCES
+ ssl/qsslcertificate_qt.cpp
+)
+
+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
+)
+
+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
+)
+
+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
+)
+
+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
+)
+
+extend_target(Network CONDITION QT_FEATURE_dtls AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qdtls.cpp ssl/qdtls.h ssl/qdtls_p.h
+)
+
+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
+)
+
+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
+)
+
+extend_target(Network CONDITION QT_FEATURE_ocsp AND QT_FEATURE_openssl AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qocsp_p.h
+)
+
+extend_target(Network CONDITION QT_FEATURE_openssl AND QT_FEATURE_opensslv11 AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qsslcontext_openssl11.cpp
+ ssl/qsslsocket_openssl11.cpp
+ ssl/qsslsocket_openssl11_symbols_p.h
+ DEFINES
+ OPENSSL_API_COMPAT=0x10100000L
+)
+
+extend_target(Network CONDITION QT_FEATURE_openssl AND QT_FEATURE_ssl AND NOT QT_FEATURE_opensslv11
+ SOURCES
+ ssl/qsslcontext_opensslpre11.cpp
+ ssl/qsslsocket_opensslpre11.cpp
+ ssl/qsslsocket_opensslpre11_symbols_p.h
+)
+
+extend_target(Network CONDITION APPLE AND QT_FEATURE_openssl AND QT_FEATURE_ssl
+ SOURCES
+ ssl/qsslsocket_mac_shared.cpp
+)
+
+extend_target(Network CONDITION ANDROID AND QT_FEATURE_openssl AND QT_FEATURE_ssl AND NOT ANDROID_EMBEDDED
+ SOURCES
+ ssl/qsslsocket_openssl_android.cpp
+)
+
+extend_target(Network CONDITION QT_FEATURE_openssl AND QT_FEATURE_openssl_linked AND QT_FEATURE_ssl
+ LIBRARIES
+ OpenSSL::SSL
+)
+
+extend_target(Network CONDITION QT_FEATURE_openssl AND QT_FEATURE_ssl AND NOT QT_FEATURE_openssl_linked
+ LIBRARIES
+ OpenSSL::SSL_nolink
+)
+
+extend_target(Network CONDITION QT_FEATURE_openssl AND QT_FEATURE_ssl AND WIN32
+ SOURCES
+ ssl/qwindowscarootfetcher.cpp ssl/qwindowscarootfetcher_p.h
+ LIBRARIES
+ crypt32
+)
+
+extend_target(Network CONDITION WIN32 LIBRARIES ws2_32) # special case: mkspecs/common/msvc-desktop.conf
+
+add_qt_docs(
+ doc/qtnetwork.qdocconf
+)
diff --git a/src/network/configure.cmake b/src/network/configure.cmake
new file mode 100644
index 0000000000..0bb54a6f7d
--- /dev/null
+++ b/src/network/configure.cmake
@@ -0,0 +1,355 @@
+
+
+#### Inputs
+
+
+
+#### Libraries
+
+find_package(Libproxy)
+set_package_properties(Libproxy PROPERTIES TYPE OPTIONAL)
+find_package(OpenSSL)
+set_package_properties(OpenSSL PROPERTIES TYPE OPTIONAL)
+
+
+#### Tests
+
+# getifaddrs
+qt_config_compile_test(getifaddrs
+ LABEL "getifaddrs()"
+"
+#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: network
+)
+
+# ipv6ifname
+qt_config_compile_test(ipv6ifname
+ LABEL "IPv6 ifname"
+"
+#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: network
+)
+
+# linux-netlink
+qt_config_compile_test(linux_netlink
+ LABEL "Linux AF_NETLINK sockets"
+"
+#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"
+"
+#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: network
+)
+
+# openssl11
+qt_config_compile_test(openssl11
+ LABEL "OpenSSL 1.1 support"
+"
+#include <openssl/opensslv.h>
+#if !defined(OPENSSL_VERSION_NUMBER) || OPENSSL_VERSION_NUMBER-0 < 0x10100000L
+# error OpenSSL >= 1.1 is required
+#endif
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: use: openssl
+)
+
+# dtls
+qt_config_compile_test(dtls
+ LABEL "DTLS support in OpenSSL"
+"
+#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;
+}
+"# FIXME: use: openssl
+)
+
+# ocsp
+qt_config_compile_test(ocsp
+ LABEL "OCSP stapling support in OpenSSL"
+"
+#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;
+}
+"# FIXME: use: openssl
+)
+
+# gssapi
+qt_config_compile_test(gssapi
+ LABEL "KRB5 GSSAPI support"
+"
+#include <gssapi/gssapi.h>
+
+int main(int argc, char **argv)
+{
+ (void)argc; (void)argv;
+ /* BEGIN TEST: */
+gss_ctx_id_t ctx;
+ /* END TEST: */
+ return 0;
+}
+"# FIXME: qmake: LIBS += -lgssapi_krb5
+)
+
+
+
+#### 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("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 AND ( OPENSSL_VERSION VERSION_GREATER_EQUAL "1.1.0" )
+)
+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("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 TEST_gssapi
+)
+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")
diff --git a/src/network/configure.json b/src/network/configure.json
index 56805da7b2..7225a6251d 100644
--- a/src/network/configure.json
+++ b/src/network/configure.json
@@ -403,25 +403,13 @@
"report": [
{
"type": "note",
- "condition": "features.openssl-linked && libs.openssl.source != 0
- && input.openssl.prefix == '' && input.openssl.libs == '' && input.openssl.libs.debug == ''",
- "message": "When linking against OpenSSL, you can override the default
-library names through OPENSSL_LIBS.
-For example:
- OPENSSL_LIBS='-L/opt/ssl/lib -lssl -lcrypto' ./configure -openssl-linked"
+ "condition": "features.openssl-linked && libs.openssl.source != 0 && input.openssl.prefix == '' && input.openssl.libs == '' && input.openssl.libs.debug == ''",
+ "message": "When linking against OpenSSL, you can override the default library names through OPENSSL_LIBS. For example: OPENSSL_LIBS='-L/opt/ssl/lib -lssl -lcrypto' ./configure -openssl-linked"
},
{
"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/qhttpsocketengine.cpp b/src/network/socket/qhttpsocketengine.cpp
index 6cae29193d..6be1e9443e 100644
--- a/src/network/socket/qhttpsocketengine.cpp
+++ b/src/network/socket/qhttpsocketengine.cpp
@@ -866,3 +866,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 5126a5330f..7085fe3bbd 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 23aec12390..27657956df 100644
--- a/src/network/socket/qsocks5socketengine.cpp
+++ b/src/network/socket/qsocks5socketengine.cpp
@@ -1920,3 +1920,5 @@ QAbstractSocketEngine *QSocks5SocketEngineHandler::createSocketEngine(qintptr so
}
QT_END_NAMESPACE
+
+#include "moc_qsocks5socketengine_p.cpp"
diff --git a/src/opengl/CMakeLists.txt b/src/opengl/CMakeLists.txt
new file mode 100644
index 0000000000..acc4cdda9a
--- /dev/null
+++ b/src/opengl/CMakeLists.txt
@@ -0,0 +1,64 @@
+# Generated from opengl.pro.
+
+#####################################################################
+## OpenGL Module:
+#####################################################################
+
+add_qt_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_USING_NAMESPACE
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ WrapOpenGL # special case
+ PUBLIC_LIBRARIES # special case
+ Qt::Core
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:opengl.pro:<NONE>:
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+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"
+
+#### Keys ignored in scope 4:.:opengl.pro:QT_FEATURE_opengl:
+# CONFIG = "opengl"
+
+#### Keys ignored in scope 5:.:opengl.pro:QT_FEATURE_opengles2:
+# CONFIG = "opengles2"
+
+extend_target(OpenGL CONDITION QT_FEATURE_graphicseffect
+ SOURCES
+ qgraphicsshadereffect.cpp qgraphicsshadereffect_p.h
+)
+
+add_qt_docs(./doc/qtopengl.qdocconf)
diff --git a/src/platformheaders/CMakeLists.txt b/src/platformheaders/CMakeLists.txt
new file mode 100644
index 0000000000..431aade79b
--- /dev/null
+++ b/src/platformheaders/CMakeLists.txt
@@ -0,0 +1,12 @@
+# FIXME Add the rest of the stuff
+
+add_qt_module(PlatformHeaders SOURCES fake.cpp)
+set_source_files_properties(fake.cpp PROPERTIES
+ SKIP_AUTOMOC ON
+ SKIP_AUTOUIC ON
+ SKIP_AUTORCC ON
+)
+
+extend_target(PlatformHeaders CONDITION APPLE SOURCES cocoafunctions/qcocoawindowfunctions.h)
+
+add_qt_docs(./doc/qtplatformheaders.qdocconf)
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..ece4eed2aa
--- /dev/null
+++ b/src/platformsupport/CMakeLists.txt
@@ -0,0 +1,54 @@
+# Generated from platformsupport.pro.
+
+add_subdirectory(themes)
+add_subdirectory(edid)
+add_subdirectory(eventdispatchers)
+add_subdirectory(devicediscovery)
+add_subdirectory(fbconvenience)
+
+if(QT_FEATURE_freetype OR APPLE OR WIN32)
+ add_subdirectory(fontdatabases)
+endif()
+
+if((UNIX AND (NOT uikit)) OR QT_FEATURE_xcb)
+ add_subdirectory(services)
+endif()
+
+if(QT_FEATURE_evdev OR QT_FEATURE_tslib OR QT_FEATURE_libinput OR QT_FEATURE_integrityhid)
+ add_subdirectory(input)
+endif()
+
+if(QT_FEATURE_accessibility)
+ add_subdirectory(accessibility)
+ if(QT_FEATURE_accessibility_atspi_bridge)
+ add_subdirectory(linuxaccessibility)
+ endif()
+ if(WIN32 AND NOT WINRT)
+ add_subdirectory(windowsuiautomation)
+ endif()
+endif()
+
+if(QT_FEATURE_vulkan)
+ add_subdirectory(vkconvenience)
+endif()
+
+if(QT_FEATURE_kms)
+ add_subdirectory(kmsconvenience)
+endif()
+
+if(QT_FEATURE_egl)
+ add_subdirectory(eglconvenience)
+endif()
+
+if(QT_FEATURE_opengl)
+ add_subdirectory(platformcompositor)
+endif()
+
+if (QT_FEATURE_xlib AND QT_FEATURE_opengl AND (NOT QT_FEATURE_opengles2))
+ add_subdirectory(glxconvenience)
+endif()
+
+if(APPLE)
+ add_subdirectory(clipboard)
+ add_subdirectory(graphics)
+endif()
diff --git a/src/platformsupport/accessibility/CMakeLists.txt b/src/platformsupport/accessibility/CMakeLists.txt
new file mode 100644
index 0000000000..14b24aba56
--- /dev/null
+++ b/src/platformsupport/accessibility/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from accessibility.pro.
+
+#####################################################################
+## AccessibilitySupport Module:
+#####################################################################
+
+add_qt_module(AccessibilitySupport
+ STATIC
+ SOURCES
+ qaccessiblebridgeutils.cpp qaccessiblebridgeutils_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+
+#### Keys ignored in scope 1:.:accessibility.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "accessibility_support"
+# _LOADED = "qt_module"
diff --git a/src/platformsupport/clipboard/CMakeLists.txt b/src/platformsupport/clipboard/CMakeLists.txt
new file mode 100644
index 0000000000..97ffe79043
--- /dev/null
+++ b/src/platformsupport/clipboard/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from clipboard.pro.
+
+#####################################################################
+## ClipboardSupport Module:
+#####################################################################
+
+add_qt_module(ClipboardSupport
+ STATIC
+ SOURCES
+ qmacmime.mm qmacmime_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ ${FWImageIO}
+ Qt::CorePrivate
+ Qt::Gui
+)
+
+#### Keys ignored in scope 1:.:clipboard.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "clipboard_support"
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+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..cfb06cd3eb
--- /dev/null
+++ b/src/platformsupport/devicediscovery/CMakeLists.txt
@@ -0,0 +1,41 @@
+# Generated from devicediscovery.pro.
+
+#####################################################################
+## DeviceDiscoverySupport Module:
+#####################################################################
+
+add_qt_module(DeviceDiscoverySupport
+ STATIC
+ SOURCES
+ qdevicediscovery_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+#### Keys ignored in scope 1:.:devicediscovery.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "devicediscovery_support"
+# QT_FOR_CONFIG = "gui-private"
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+extend_target(DeviceDiscoverySupport CONDITION QT_FEATURE_libudev
+ SOURCES
+ qdevicediscovery_udev.cpp qdevicediscovery_udev_p.h
+ LIBRARIES
+ PkgConfig::Libudev
+)
+
+extend_target(DeviceDiscoverySupport CONDITION QT_FEATURE_evdev AND NOT QT_FEATURE_libudev
+ SOURCES
+ qdevicediscovery_static.cpp qdevicediscovery_static_p.h
+)
+
+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..3c9668527e
--- /dev/null
+++ b/src/platformsupport/edid/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from edid.pro.
+
+#####################################################################
+## EdidSupport Module:
+#####################################################################
+
+add_qt_module(EdidSupport
+ STATIC
+ SOURCES
+ qedidparser.cpp qedidparser_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+)
+
+#### Keys ignored in scope 1:.:edid.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "edid_support"
+# PRECOMPILED_HEADER = "../../corelib/global/qt_pch.h"
+# _LOADED = "qt_module"
diff --git a/src/platformsupport/eglconvenience/CMakeLists.txt b/src/platformsupport/eglconvenience/CMakeLists.txt
new file mode 100644
index 0000000000..2cbc02073c
--- /dev/null
+++ b/src/platformsupport/eglconvenience/CMakeLists.txt
@@ -0,0 +1,41 @@
+find_package(EGL) # special case
+
+#####################################################################
+## EglSupport Module:
+#####################################################################
+
+add_qt_module(EglSupport
+ STATIC
+ SOURCES
+ qeglconvenience.cpp qeglconvenience_p.h
+ qeglstreamconvenience.cpp qeglstreamconvenience_p.h
+ qt_egl_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_EGL_NO_X11
+ LIBRARIES
+ ${CMAKE_DL_LIBS}
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ EGL::EGL # special case
+)
+
+#### Keys ignored in scope 1:.:eglconvenience.pro:<NONE>:
+# CONFIG = "static" "internal_module" "egl"
+# MODULE = "egl_support"
+# PRECOMPILED_HEADER = "../../corelib/global/qt_pch.h"
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+extend_target(EglSupport CONDITION QT_FEATURE_opengl
+ SOURCES
+ qeglpbuffer.cpp qeglpbuffer_p.h
+ qeglplatformcontext.cpp qeglplatformcontext_p.h
+)
+
+extend_target(EglSupport CONDITION QT_FEATURE_xlib
+ SOURCES
+ qxlibeglintegration.cpp qxlibeglintegration_p.h
+)
diff --git a/src/platformsupport/eventdispatchers/CMakeLists.txt b/src/platformsupport/eventdispatchers/CMakeLists.txt
new file mode 100644
index 0000000000..ba0d71f03b
--- /dev/null
+++ b/src/platformsupport/eventdispatchers/CMakeLists.txt
@@ -0,0 +1,43 @@
+find_package(GLIB2) # special case
+set_package_properties(GLib PROPERTIES TYPE OPTIONAL) # special case
+
+#####################################################################
+## EventDispatcherSupport Module:
+#####################################################################
+
+add_qt_module(EventDispatcherSupport
+ STATIC
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+
+#### Keys ignored in scope 1:.:eventdispatchers.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "eventdispatcher_support"
+# PRECOMPILED_HEADER = "../../corelib/global/qt_pch.h"
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+extend_target(EventDispatcherSupport CONDITION UNIX
+ SOURCES
+ qgenericunixeventdispatcher.cpp qgenericunixeventdispatcher_p.h
+ qunixeventdispatcher.cpp
+ qunixeventdispatcher_qpa_p.h
+)
+
+extend_target(EventDispatcherSupport CONDITION WIN32
+ SOURCES
+ qwindowsguieventdispatcher.cpp qwindowsguieventdispatcher_p.h
+)
+
+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..bb283979db
--- /dev/null
+++ b/src/platformsupport/fbconvenience/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from fbconvenience.pro.
+
+#####################################################################
+## FbSupport Module:
+#####################################################################
+
+add_qt_module(FbSupport
+ STATIC
+ 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
+)
+
+#### Keys ignored in scope 1:.:fbconvenience.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "fb_support"
+# PRECOMPILED_HEADER = "../../corelib/global/qt_pch.h"
+# _LOADED = "qt_module"
diff --git a/src/platformsupport/fontdatabases/CMakeLists.txt b/src/platformsupport/fontdatabases/CMakeLists.txt
new file mode 100644
index 0000000000..be1047eb13
--- /dev/null
+++ b/src/platformsupport/fontdatabases/CMakeLists.txt
@@ -0,0 +1,125 @@
+find_package(Freetype) # special case
+find_package(Fontconfig) # special case
+
+#####################################################################
+## FontDatabaseSupport Module:
+#####################################################################
+
+add_qt_module(FontDatabaseSupport
+ STATIC
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+
+#### Keys ignored in scope 1:.:fontdatabases.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "fontdatabase_support"
+# PRECOMPILED_HEADER = "../../corelib/global/qt_pch.h"
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+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}
+)
+
+#### Keys ignored in scope 2:.:fontdatabases.pro:APPLE:
+# CONFIG = "watchos_coretext"
+
+extend_target(FontDatabaseSupport CONDITION APPLE AND QT_FEATURE_freetype
+ SOURCES
+ freetype/qfontengine_ft.cpp freetype/qfontengine_ft_p.h
+ LIBRARIES
+ Freetype::Freetype
+)
+
+extend_target(FontDatabaseSupport CONDITION APPLE_OSX
+ LIBRARIES
+ ${FWAppKit}
+)
+
+extend_target(FontDatabaseSupport CONDITION APPLE AND NOT APPLE_OSX
+ LIBRARIES
+ ${FWUIKit}
+)
+
+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
+ Freetype::Freetype
+)
+
+extend_target(FontDatabaseSupport CONDITION UNIX
+ SOURCES
+ genericunix/qgenericunixfontdatabase_p.h
+)
+
+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
+)
+
+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
+)
+
+extend_target(FontDatabaseSupport CONDITION QT_FEATURE_freetype AND WIN32 AND NOT WINRT
+ SOURCES
+ windows/qwindowsfontdatabase_ft.cpp windows/qwindowsfontdatabase_ft_p.h
+)
+
+extend_target(FontDatabaseSupport CONDITION QT_FEATURE_directwrite AND WIN32 AND NOT WINRT
+ SOURCES
+ windows/qwindowsfontenginedirectwrite.cpp windows/qwindowsfontenginedirectwrite_p.h
+)
+
+extend_target(FontDatabaseSupport CONDITION QT_FEATURE_directwrite AND QT_FEATURE_directwrite2 AND WIN32 AND NOT WINRT
+ DEFINES
+ QT_USE_DIRECTWRITE2
+)
+
+extend_target(FontDatabaseSupport CONDITION WIN32 AND NOT QT_FEATURE_directwrite AND NOT WINRT
+ DEFINES
+ QT_NO_DIRECTWRITE
+)
+
+extend_target(FontDatabaseSupport CONDITION WIN32 AND mingw AND NOT WINRT
+ LIBRARIES
+ uuid
+)
+
+extend_target(FontDatabaseSupport CONDITION WINRT
+ SOURCES
+ winrt/qwinrtfontdatabase.cpp winrt/qwinrtfontdatabase_p.h
+ DEFINES
+ __WRL_NO_DEFAULT_LIB__
+ LIBRARIES
+ Qt::GuiPrivate
+ dwrite
+ ws2_32
+)
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/CMakeLists.txt b/src/platformsupport/glxconvenience/CMakeLists.txt
new file mode 100644
index 0000000000..6bc3e1629e
--- /dev/null
+++ b/src/platformsupport/glxconvenience/CMakeLists.txt
@@ -0,0 +1,24 @@
+find_package(X11) # special case
+find_package(OpenGL) # special case
+
+#####################################################################
+## GlxSupport Module:
+#####################################################################
+
+add_qt_module(GlxSupport
+ STATIC
+ SOURCES
+ qglxconvenience.cpp qglxconvenience_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ OpenGL::GLX # special case
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ X11::X11 # special case
+)
+
+#### Keys ignored in scope 1:.:glxconvenience.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "glx_support"
+# _LOADED = "qt_module"
diff --git a/src/platformsupport/graphics/CMakeLists.txt b/src/platformsupport/graphics/CMakeLists.txt
new file mode 100644
index 0000000000..9deca9d7c7
--- /dev/null
+++ b/src/platformsupport/graphics/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from graphics.pro.
+
+#####################################################################
+## GraphicsSupport Module:
+#####################################################################
+
+add_qt_module(GraphicsSupport
+ STATIC
+ SOURCES
+ qrasterbackingstore.cpp qrasterbackingstore_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+
+#### Keys ignored in scope 1:.:graphics.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "graphics_support"
+# _LOADED = "qt_module"
diff --git a/src/platformsupport/input/CMakeLists.txt b/src/platformsupport/input/CMakeLists.txt
new file mode 100644
index 0000000000..1ab85ce239
--- /dev/null
+++ b/src/platformsupport/input/CMakeLists.txt
@@ -0,0 +1,111 @@
+# Generated from input.pro.
+
+find_package(Libinput) # special case
+find_package(XKB) # special case
+find_package(Tslib) # special case
+find_package(Mtdev) # special case
+
+#####################################################################
+## InputSupport Module:
+#####################################################################
+
+add_qt_module(InputSupport
+ STATIC
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DeviceDiscoverySupportPrivate
+ Qt::GuiPrivate
+ PUBLIC_LIBRARIES
+ Qt::Core
+ Qt::DeviceDiscoverySupport
+ Qt::Gui
+)
+
+#### Keys ignored in scope 3:.:.:input-support.pro:<TRUE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "input_support"
+# PRECOMPILED_HEADER = "../../corelib/global/qt_pch.h"
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+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
+)
+
+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
+)
+
+extend_target(InputSupport CONDITION QT_FEATURE_evdev AND QT_FEATURE_libudev AND QT_FEATURE_tabletevent
+ LIBRARIES
+ PkgConfig::Libudev
+)
+
+extend_target(InputSupport CONDITION QT_FEATURE_evdev AND QT_FEATURE_libudev
+ LIBRARIES
+ PkgConfig::Libudev
+)
+
+extend_target(InputSupport CONDITION QT_FEATURE_evdev AND QT_FEATURE_mtdev
+ LIBRARIES
+ PkgConfig::Mtdev
+)
+
+extend_target(InputSupport CONDITION QT_FEATURE_tslib
+ SOURCES
+ tslib/qtslib.cpp tslib/qtslib_p.h
+ PUBLIC_LIBRARIES
+ PkgConfig::Tslib
+)
+
+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
+)
+
+extend_target(InputSupport CONDITION QT_FEATURE_libinput AND QT_FEATURE_xkbcommon
+ LIBRARIES
+ Qt::XkbCommonSupportPrivate
+ XKB::XKB
+ PUBLIC_LIBRARIES
+ Qt::XkbCommonSupport
+)
+
+extend_target(InputSupport CONDITION QT_FEATURE_evdev OR QT_FEATURE_libinput
+ SOURCES
+ shared/qtouchoutputmapping.cpp shared/qtouchoutputmapping_p.h
+)
+
+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..2797966fc4
--- /dev/null
+++ b/src/platformsupport/input/xkbcommon/CMakeLists.txt
@@ -0,0 +1,35 @@
+# Generated from xkbcommon.pro.
+
+#####################################################################
+## XkbCommonSupport Module:
+#####################################################################
+
+add_qt_module(XkbCommonSupport
+ STATIC
+ 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
+)
+
+#### Keys ignored in scope 1:.:.:xkbcommon.pro:<TRUE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "xkbcommon_support"
+# PRECOMPILED_HEADER = "../../../corelib/global/qt_pch.h"
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+extend_target(XkbCommonSupport CONDITION CLANG AND NOT ICC
+ COMPILE_OPTIONS
+ "-ftemplate-depth=1024"
+)
diff --git a/src/platformsupport/kmsconvenience/CMakeLists.txt b/src/platformsupport/kmsconvenience/CMakeLists.txt
new file mode 100644
index 0000000000..cf006fbeed
--- /dev/null
+++ b/src/platformsupport/kmsconvenience/CMakeLists.txt
@@ -0,0 +1,23 @@
+find_package(Libdrm) # special case
+
+#####################################################################
+## KmsSupport Module:
+#####################################################################
+
+add_qt_module(KmsSupport
+ STATIC
+ SOURCES
+ qkmsdevice.cpp qkmsdevice_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ PUBLIC_LIBRARIES # special case
+ Libdrm::Libdrm
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+
+#### Keys ignored in scope 1:.:kmsconvenience.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "kms_support"
+# _LOADED = "qt_module"
diff --git a/src/platformsupport/kmsconvenience/kmsconvenience.pro b/src/platformsupport/kmsconvenience/kmsconvenience.pro
index 5ea2e3f208..0c5a20a239 100644
--- a/src/platformsupport/kmsconvenience/kmsconvenience.pro
+++ b/src/platformsupport/kmsconvenience/kmsconvenience.pro
@@ -6,7 +6,7 @@ CONFIG += static internal_module
DEFINES += QT_NO_CAST_FROM_ASCII
-HEADERS +=
+HEADERS += \
qkmsdevice_p.h
SOURCES += \
diff --git a/src/platformsupport/linuxaccessibility/CMakeLists.txt b/src/platformsupport/linuxaccessibility/CMakeLists.txt
new file mode 100644
index 0000000000..5478c9f773
--- /dev/null
+++ b/src/platformsupport/linuxaccessibility/CMakeLists.txt
@@ -0,0 +1,41 @@
+find_package(ATSPI2 REQUIRED) # special case
+
+#####################################################################
+## LinuxAccessibilitySupport Module:
+#####################################################################
+
+add_qt_module(LinuxAccessibilitySupport
+ STATIC
+ 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::DBus
+ Qt::GuiPrivate
+ PkgConfig::ATSPI2
+)
+
+#### Keys ignored in scope 1:.:linuxaccessibility.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "linuxaccessibility_support"
+# PRECOMPILED_HEADER = "../../corelib/global/qt_pch.h"
+# _LOADED = "qt_module"
diff --git a/src/platformsupport/platformcompositor/CMakeLists.txt b/src/platformsupport/platformcompositor/CMakeLists.txt
new file mode 100644
index 0000000000..a8696be5cd
--- /dev/null
+++ b/src/platformsupport/platformcompositor/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from platformcompositor.pro.
+
+#####################################################################
+## PlatformCompositorSupport Module:
+#####################################################################
+
+add_qt_module(PlatformCompositorSupport
+ STATIC
+ SOURCES
+ qopenglcompositor.cpp qopenglcompositor_p.h
+ qopenglcompositorbackingstore.cpp qopenglcompositorbackingstore_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+
+#### Keys ignored in scope 1:.:platformcompositor.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "platformcompositor_support"
+# _LOADED = "qt_module"
diff --git a/src/platformsupport/services/CMakeLists.txt b/src/platformsupport/services/CMakeLists.txt
new file mode 100644
index 0000000000..3169332381
--- /dev/null
+++ b/src/platformsupport/services/CMakeLists.txt
@@ -0,0 +1,30 @@
+# Generated from services.pro.
+
+#####################################################################
+## ServiceSupport Module:
+#####################################################################
+
+add_qt_module(ServiceSupport
+ STATIC
+ SOURCES
+ genericunix/qgenericunixservices.cpp genericunix/qgenericunixservices_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+
+#### Keys ignored in scope 1:.:services.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "service_support"
+# PRECOMPILED_HEADER = "../../corelib/global/qt_pch.h"
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+extend_target(ServiceSupport CONDITION QT_FEATURE_dbus
+ LIBRARIES
+ Qt::DBus
+)
diff --git a/src/platformsupport/themes/CMakeLists.txt b/src/platformsupport/themes/CMakeLists.txt
new file mode 100644
index 0000000000..865624bd39
--- /dev/null
+++ b/src/platformsupport/themes/CMakeLists.txt
@@ -0,0 +1,55 @@
+# Generated from themes.pro.
+
+#####################################################################
+## ThemeSupport Module:
+#####################################################################
+
+add_qt_module(ThemeSupport
+ STATIC
+ SOURCES
+ qabstractfileiconengine.cpp qabstractfileiconengine_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+
+#### Keys ignored in scope 1:.:themes.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "theme_support"
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+extend_target(ThemeSupport CONDITION QT_FEATURE_xcb OR (UNIX AND NOT APPLE_UIKIT)
+ SOURCES
+ genericunix/qgenericunixthemes.cpp genericunix/qgenericunixthemes_p.h
+)
+
+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
+)
+
+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/CMakeLists.txt b/src/platformsupport/vkconvenience/CMakeLists.txt
new file mode 100644
index 0000000000..106f78fb3d
--- /dev/null
+++ b/src/platformsupport/vkconvenience/CMakeLists.txt
@@ -0,0 +1,22 @@
+find_package(Vulkan) # special case
+
+#####################################################################
+## VulkanSupport Module:
+#####################################################################
+
+add_qt_module(VulkanSupport
+ STATIC
+ SOURCES
+ qbasicvulkanplatforminstance.cpp qbasicvulkanplatforminstance_p.h
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+
+#### Keys ignored in scope 1:.:vkconvenience.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "vulkan_support"
+# PRECOMPILED_HEADER = "../../corelib/global/qt_pch.h"
+# _LOADED = "qt_module"
diff --git a/src/platformsupport/windowsuiautomation/CMakeLists.txt b/src/platformsupport/windowsuiautomation/CMakeLists.txt
new file mode 100644
index 0000000000..84c118258e
--- /dev/null
+++ b/src/platformsupport/windowsuiautomation/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from windowsuiautomation.pro.
+
+#####################################################################
+## WindowsUIAutomationSupport Module:
+#####################################################################
+
+add_qt_module(WindowsUIAutomationSupport
+ STATIC
+ 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
+)
+
+#### Keys ignored in scope 1:.:windowsuiautomation.pro:<NONE>:
+# CONFIG = "static" "internal_module"
+# MODULE = "windowsuiautomation_support"
+# _LOADED = "qt_module"
diff --git a/src/plugins/CMakeLists.txt b/src/plugins/CMakeLists.txt
new file mode 100644
index 0000000000..9c4eee2db4
--- /dev/null
+++ b/src/plugins/CMakeLists.txt
@@ -0,0 +1,28 @@
+
+if (QT_FEATURE_sql)
+ add_subdirectory(sqldrivers)
+endif()
+
+if(QT_FEATURE_network AND QT_FEATURE_bearermanagement)
+ add_subdirectory(bearer)
+endif()
+
+if(QT_FEATURE_gui)
+ add_subdirectory(platforms)
+ add_subdirectory(platformthemes)
+ add_subdirectory(platforminputcontexts)
+ if (QT_FEATURE_imageformatplugin)
+ add_subdirectory(imageformats)
+ endif()
+ if (NOT ANDROID AND QT_FEATURE_library)
+ add_subdirectory(generic)
+ endif()
+endif()
+
+if (QT_FEATURE_widgets)
+ add_subdirectory(styles)
+endif()
+
+if (NOT WINRT AND TARGET PrintSupport)
+ add_subdirectory(printsupport)
+endif()
diff --git a/src/plugins/bearer/CMakeLists.txt b/src/plugins/bearer/CMakeLists.txt
new file mode 100644
index 0000000000..ec860de2cb
--- /dev/null
+++ b/src/plugins/bearer/CMakeLists.txt
@@ -0,0 +1,9 @@
+if (NOT ANDROID AND LINUX AND QT_FEATURE_dbus)
+ add_subdirectory(generic)
+ add_subdirectory(connman)
+ add_subdirectory(networkmanager)
+elseif(ANDROID AND NOT ANDROID_EMBEDDED)
+# TODO add_subdirectory(android)
+else()
+ add_subdirectory(generic)
+endif()
diff --git a/src/plugins/bearer/connman/CMakeLists.txt b/src/plugins/bearer/connman/CMakeLists.txt
new file mode 100644
index 0000000000..08f286aee1
--- /dev/null
+++ b/src/plugins/bearer/connman/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from connman.pro.
+
+#####################################################################
+## qconnmanbearer Plugin:
+#####################################################################
+
+add_qt_plugin(qconnmanbearer
+ TYPE bearer
+ SOURCES
+ ../linux_common/qofonoservice_linux.cpp ../linux_common/qofonoservice_linux_p.h
+ ../qbearerengine_impl.h
+ ../qnetworksession_impl.cpp ../qnetworksession_impl.h
+ main.cpp
+ qconnmanengine.cpp qconnmanengine.h
+ qconnmanservice_linux.cpp qconnmanservice_linux_p.h
+ LIBRARIES
+ Qt::Core
+ Qt::DBus
+ Qt::NetworkPrivate
+)
+
+#### Keys ignored in scope 1:.:connman.pro:<NONE>:
+# OTHER_FILES = "connman.json"
+# PLUGIN_CLASS_NAME = "QConnmanEnginePlugin"
+# _LOADED = "qt_plugin"
diff --git a/src/plugins/bearer/generic/CMakeLists.txt b/src/plugins/bearer/generic/CMakeLists.txt
new file mode 100644
index 0000000000..822cd12b19
--- /dev/null
+++ b/src/plugins/bearer/generic/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from generic.pro.
+
+#####################################################################
+## qgenericbearer Plugin:
+#####################################################################
+
+add_qt_plugin(qgenericbearer
+ TYPE bearer
+ SOURCES
+ ../platformdefs_win.h
+ ../qbearerengine_impl.h
+ ../qnetworksession_impl.cpp ../qnetworksession_impl.h
+ main.cpp
+ qgenericengine.cpp qgenericengine.h
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::NetworkPrivate
+)
+
+#### Keys ignored in scope 1:.:generic.pro:<NONE>:
+# OTHER_FILES = "generic.json"
+# PLUGIN_CLASS_NAME = "QGenericEnginePlugin"
+# _LOADED = "qt_plugin"
+
+## Scopes:
+#####################################################################
+
+extend_target(qgenericbearer CONDITION WIN32 AND NOT WINRT
+ LIBRARIES
+ iphlpapi
+)
diff --git a/src/plugins/bearer/networkmanager/CMakeLists.txt b/src/plugins/bearer/networkmanager/CMakeLists.txt
new file mode 100644
index 0000000000..62c0b2a98b
--- /dev/null
+++ b/src/plugins/bearer/networkmanager/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from networkmanager.pro.
+
+#####################################################################
+## qnmbearer Plugin:
+#####################################################################
+
+add_qt_plugin(qnmbearer
+ TYPE bearer
+ SOURCES
+ ../linux_common/qofonoservice_linux.cpp ../linux_common/qofonoservice_linux_p.h
+ ../qbearerengine_impl.h
+ ../qnetworksession_impl.cpp ../qnetworksession_impl.h
+ main.cpp
+ qnetworkmanagerengine.cpp qnetworkmanagerengine.h
+ qnetworkmanagerservice.cpp qnetworkmanagerservice.h
+ LIBRARIES
+ Qt::Core
+ Qt::DBus
+ Qt::NetworkPrivate
+)
+
+#### Keys ignored in scope 1:.:networkmanager.pro:<NONE>:
+# OTHER_FILES = "networkmanager.json"
+# PLUGIN_CLASS_NAME = "QNetworkManagerEnginePlugin"
+# _LOADED = "qt_plugin"
diff --git a/src/plugins/generic/CMakeLists.txt b/src/plugins/generic/CMakeLists.txt
new file mode 100644
index 0000000000..487a79b22b
--- /dev/null
+++ b/src/plugins/generic/CMakeLists.txt
@@ -0,0 +1,26 @@
+if(QT_FEATURE_evdev)
+ add_subdirectory(evdevmouse)
+ add_subdirectory(evdevtouch)
+ add_subdirectory(evdevkeyboard)
+
+ if(QT_FEATURE_tabletevent)
+ add_subdirectory(evdevtablet)
+ endif()
+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)
+# TODO add_subdirectory(bsdkeyboard)
+# TODO add_subdirectory(bsdmouse)
+endif()
diff --git a/src/plugins/generic/evdevkeyboard/CMakeLists.txt b/src/plugins/generic/evdevkeyboard/CMakeLists.txt
new file mode 100644
index 0000000000..fd636e6b94
--- /dev/null
+++ b/src/plugins/generic/evdevkeyboard/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from evdevkeyboard.pro.
+
+#####################################################################
+## qevdevkeyboardplugin Plugin:
+#####################################################################
+
+add_qt_plugin(qevdevkeyboardplugin
+ TYPE generic
+ 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_CLASS_NAME = "QEvdevKeyboardPlugin"
+# PLUGIN_EXTENDS = "-"
+# _LOADED = "qt_plugin"
diff --git a/src/plugins/generic/evdevmouse/CMakeLists.txt b/src/plugins/generic/evdevmouse/CMakeLists.txt
new file mode 100644
index 0000000000..0035e6d960
--- /dev/null
+++ b/src/plugins/generic/evdevmouse/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from evdevmouse.pro.
+
+#####################################################################
+## qevdevmouseplugin Plugin:
+#####################################################################
+
+add_qt_plugin(qevdevmouseplugin
+ TYPE generic
+ 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_CLASS_NAME = "QEvdevMousePlugin"
+# PLUGIN_EXTENDS = "-"
+# _LOADED = "qt_plugin"
diff --git a/src/plugins/generic/evdevtablet/CMakeLists.txt b/src/plugins/generic/evdevtablet/CMakeLists.txt
new file mode 100644
index 0000000000..c473fce68b
--- /dev/null
+++ b/src/plugins/generic/evdevtablet/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from evdevtablet.pro.
+
+#####################################################################
+## qevdevtabletplugin Plugin:
+#####################################################################
+
+add_qt_plugin(qevdevtabletplugin
+ TYPE generic
+ 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_CLASS_NAME = "QEvdevTabletPlugin"
+# PLUGIN_EXTENDS = "-"
+# _LOADED = "qt_plugin"
diff --git a/src/plugins/generic/evdevtouch/CMakeLists.txt b/src/plugins/generic/evdevtouch/CMakeLists.txt
new file mode 100644
index 0000000000..fd6b9008ca
--- /dev/null
+++ b/src/plugins/generic/evdevtouch/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from evdevtouch.pro.
+
+#####################################################################
+## qevdevtouchplugin Plugin:
+#####################################################################
+
+add_qt_plugin(qevdevtouchplugin
+ TYPE generic
+ 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_CLASS_NAME = "QEvdevTouchScreenPlugin"
+# PLUGIN_EXTENDS = "-"
+# _LOADED = "qt_plugin"
diff --git a/src/plugins/generic/libinput/CMakeLists.txt b/src/plugins/generic/libinput/CMakeLists.txt
new file mode 100644
index 0000000000..fb0cf677e9
--- /dev/null
+++ b/src/plugins/generic/libinput/CMakeLists.txt
@@ -0,0 +1,25 @@
+# Generated from libinput.pro.
+
+#####################################################################
+## qlibinputplugin Plugin:
+#####################################################################
+
+add_qt_plugin(qlibinputplugin
+ TYPE generic
+ 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_CLASS_NAME = "QLibInputPlugin"
+# PLUGIN_EXTENDS = "-"
+# _LOADED = "qt_plugin"
diff --git a/src/plugins/generic/tslib/CMakeLists.txt b/src/plugins/generic/tslib/CMakeLists.txt
new file mode 100644
index 0000000000..b46217d845
--- /dev/null
+++ b/src/plugins/generic/tslib/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from tslib.pro.
+
+find_package(Tslib) # special case
+
+#####################################################################
+## qtslibplugin Plugin:
+#####################################################################
+
+add_qt_plugin(qtslibplugin
+ TYPE generic
+ 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_CLASS_NAME = "QTsLibPlugin"
+# PLUGIN_EXTENDS = "-"
+# _LOADED = "qt_plugin"
diff --git a/src/plugins/generic/tuiotouch/CMakeLists.txt b/src/plugins/generic/tuiotouch/CMakeLists.txt
new file mode 100644
index 0000000000..c6452780c5
--- /dev/null
+++ b/src/plugins/generic/tuiotouch/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from tuiotouch.pro.
+
+#####################################################################
+## qtuiotouchplugin Plugin:
+#####################################################################
+
+add_qt_plugin(qtuiotouchplugin
+ TYPE generic
+ 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_CLASS_NAME = "QTuioTouchPlugin"
+# PLUGIN_EXTENDS = "-"
+# _LOADED = "qt_plugin"
diff --git a/src/plugins/imageformats/CMakeLists.txt b/src/plugins/imageformats/CMakeLists.txt
new file mode 100644
index 0000000000..cd5c0347e5
--- /dev/null
+++ b/src/plugins/imageformats/CMakeLists.txt
@@ -0,0 +1,11 @@
+if(QT_FEATURE_gif)
+ add_subdirectory(gif)
+endif()
+if(QT_FEATURE_ico)
+ add_subdirectory(ico)
+endif()
+if(QT_FEATURE_jpeg)
+ add_subdirectory(jpeg)
+endif()
+
+
diff --git a/src/plugins/imageformats/gif/CMakeLists.txt b/src/plugins/imageformats/gif/CMakeLists.txt
new file mode 100644
index 0000000000..efd910c3ff
--- /dev/null
+++ b/src/plugins/imageformats/gif/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from gif.pro.
+
+#####################################################################
+## qgif Plugin:
+#####################################################################
+
+add_qt_plugin(qgif
+ TYPE imageformats
+ SOURCES
+ main.cpp main.h
+ qgifhandler.cpp qgifhandler_p.h
+ LIBRARIES
+ Qt::Gui
+)
diff --git a/src/plugins/imageformats/ico/CMakeLists.txt b/src/plugins/imageformats/ico/CMakeLists.txt
new file mode 100644
index 0000000000..52550eab60
--- /dev/null
+++ b/src/plugins/imageformats/ico/CMakeLists.txt
@@ -0,0 +1,15 @@
+# Generated from ico.pro.
+
+#####################################################################
+## qico Plugin:
+#####################################################################
+
+add_qt_plugin(qico
+ TYPE imageformats
+ SOURCES
+ main.cpp main.h
+ qicohandler.cpp qicohandler.h
+ LIBRARIES
+ Qt::Gui
+ Qt::CorePrivate
+)
diff --git a/src/plugins/imageformats/jpeg/CMakeLists.txt b/src/plugins/imageformats/jpeg/CMakeLists.txt
new file mode 100644
index 0000000000..f70c72b992
--- /dev/null
+++ b/src/plugins/imageformats/jpeg/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from jpeg.pro.
+
+#####################################################################
+## qjpeg Plugin:
+#####################################################################
+
+find_package(JPEG)
+
+add_qt_plugin(qjpeg
+ TYPE imageformats
+ SOURCES
+ main.cpp main.h
+ qjpeghandler.cpp qjpeghandler_p.h
+ LIBRARIES
+ Qt::Gui
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ JPEG::JPEG
+)
diff --git a/src/plugins/platforminputcontexts/CMakeLists.txt b/src/plugins/platforminputcontexts/CMakeLists.txt
new file mode 100644
index 0000000000..c8baf76f95
--- /dev/null
+++ b/src/plugins/platforminputcontexts/CMakeLists.txt
@@ -0,0 +1,10 @@
+
+if(QT_FEATURE_dbus AND (NOT APPLE_OSX) AND (NOT WIN32))
+ add_subdirectory(ibus)
+endif()
+
+if(QT_FEATURE_xcb)
+ add_subdirectory(compose)
+endif()
+
+
diff --git a/src/plugins/platforminputcontexts/compose/CMakeLists.txt b/src/plugins/platforminputcontexts/compose/CMakeLists.txt
new file mode 100644
index 0000000000..eaa3ac8f73
--- /dev/null
+++ b/src/plugins/platforminputcontexts/compose/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from compose.pro.
+
+#####################################################################
+## composeplatforminputcontextplugin Plugin:
+#####################################################################
+
+find_package(XKB) # special case
+
+pkg_get_variable(PKG_X11_PREFIX x11 prefix) # special case
+
+add_qt_plugin(composeplatforminputcontextplugin
+ TYPE platforminputcontexts
+ 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_CLASS_NAME = "QComposePlatformInputContextPlugin"
+# PLUGIN_EXTENDS = "-"
+# _LOADED = "qt_plugin"
diff --git a/src/plugins/platforminputcontexts/ibus/CMakeLists.txt b/src/plugins/platforminputcontexts/ibus/CMakeLists.txt
new file mode 100644
index 0000000000..99e924f752
--- /dev/null
+++ b/src/plugins/platforminputcontexts/ibus/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from ibus.pro.
+
+#####################################################################
+## ibusplatforminputcontextplugin Plugin:
+#####################################################################
+
+add_qt_plugin(ibusplatforminputcontextplugin
+ TYPE platforminputcontexts
+ 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::DBus
+ Qt::Gui
+ Qt::XkbCommonSupport
+)
+
+#### Keys ignored in scope 1:.:.:ibus.pro:<TRUE>:
+# OTHER_FILES = "$$PWD/ibus.json"
+# PLUGIN_CLASS_NAME = "QIbusPlatformInputContextPlugin"
+# PLUGIN_EXTENDS = "-"
+# _LOADED = "qt_plugin"
diff --git a/src/plugins/platforms/CMakeLists.txt b/src/plugins/platforms/CMakeLists.txt
new file mode 100644
index 0000000000..a6dfadc7e8
--- /dev/null
+++ b/src/plugins/platforms/CMakeLists.txt
@@ -0,0 +1,76 @@
+if(ANDROID) # AND NOT android-embedded
+# TODO add_subdirectory(android)
+endif()
+
+if(NOT ANDROID)
+ add_subdirectory(minimal)
+endif()
+
+if (NOT ANDROID AND QT_FEATURE_freetype)
+ add_subdirectory(offscreen)
+endif()
+
+if(QT_FEATURE_xcb)
+ add_subdirectory(xcb)
+endif()
+
+if(APPLE_UIKIT AND NOT watchOS)
+# TODO add_subdirectory(ios)
+endif()
+
+if(APPLE_OSX)
+ add_subdirectory(cocoa)
+endif()
+
+if(WIN32 AND NOT WINRT)
+ add_subdirectory(windows)
+endif()
+
+if(WINRT)
+# TODO add_subdirectory(winrt)
+endif()
+
+if(QT_FEATURE_direct2d)
+# TODO add_subdirectory(direct2d)
+endif()
+
+if(QNX)
+# TODO add_subdirectory(qnx)
+endif()
+
+if(QT_FEATURE_eglfs)
+ add_subdirectory(eglfs)
+ add_subdirectory(minimalegl)
+endif()
+
+if(QT_FEATURE_directfb)
+# TODO add_subdirectory(directfb)
+endif()
+
+if(QT_FEATURE_linuxfb)
+ add_subdirectory(linuxfb)
+endif()
+
+if(TARGET Qt::Network AND QT_FEATURE_vnc)
+ add_subdirectory(vnc)
+endif()
+
+if(FREEBSD)
+# TODO add_subdirectory(bsdfb)
+endif()
+
+if(HAIKU)
+# TODO add_subdirectory(haiku)
+endif()
+
+#if(WASM)
+# TODO add_subdirectory(wasm)
+#endif()
+
+if(QT_FEATURE_mirclient)
+# TODO add_subdirectory(mirclient)
+endif()
+
+if(QT_FEATURE_integrityfb)
+# TODO add_subdirectory(integrityfb)
+endif()
diff --git a/src/plugins/platforms/cocoa/CMakeLists.txt b/src/plugins/platforms/cocoa/CMakeLists.txt
new file mode 100644
index 0000000000..0b08d49390
--- /dev/null
+++ b/src/plugins/platforms/cocoa/CMakeLists.txt
@@ -0,0 +1,141 @@
+# Generated from cocoa.pro.
+
+# special case:
+find_package(Cups)
+find_package(WrapOpenGL)
+
+#####################################################################
+## qcocoa Plugin:
+#####################################################################
+
+add_qt_plugin(qcocoa
+ TYPE platforms
+ SOURCES
+ main.mm
+ messages.cpp messages.h
+ qcocoaaccessibility.h qcocoaaccessibility.mm
+ qcocoaaccessibilityelement.h qcocoaaccessibilityelement.mm
+ 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
+ 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::AccessibilitySupportPrivate
+ 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::AccessibilitySupport
+ Qt::ClipboardSupport
+ Qt::Core
+ Qt::FontDatabaseSupport
+ Qt::GraphicsSupport
+ Qt::Gui
+ Qt::ThemeSupport
+)
+
+# Resources:
+add_qt_resource(qcocoa "qcocoaresources" PREFIX "/qt-project.org/mac/cursors" FILES
+ images/sizeallcursor.png
+ images/spincursor.png
+ images/waitcursor.png)
+
+
+#### Keys ignored in scope 1:.:.:cocoa.pro:<TRUE>:
+# CONFIG = "no_app_extension_api_only"
+# OTHER_FILES = "cocoa.json"
+# PLUGIN_CLASS_NAME = "QCocoaIntegrationPlugin"
+# _LOADED = "qt_plugin"
+
+## Scopes:
+#####################################################################
+
+extend_target(qcocoa CONDITION QT_FEATURE_opengl # special case
+ SOURCES
+ qcocoaglcontext.h qcocoaglcontext.mm
+ LIBRARIES
+ WrapOpenGL # special case
+)
+
+extend_target(qcocoa CONDITION QT_FEATURE_vulkan
+ SOURCES
+ qcocoavulkaninstance.h qcocoavulkaninstance.mm
+ LIBRARIES
+ Qt::VulkanSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::VulkanSupport
+)
+
+extend_target(qcocoa CONDITION TARGET Qt::Widgets
+ SOURCES
+ qcocoaprintdevice.h qcocoaprintdevice.mm
+ qcocoaprintersupport.h qcocoaprintersupport.mm
+ qpaintengine_mac.mm qpaintengine_mac_p.h
+ qprintengine_mac.mm qprintengine_mac_p.h
+ LIBRARIES
+ Qt::PrintSupportPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES
+ Qt::PrintSupport
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 5:.:.:cocoa.pro:TARGET Qt::Widgets:
+# QT_FOR_CONFIG = "widgets"
+
+extend_target(qcocoa CONDITION (TARGET Qt::Widgets) AND (QT_FEATURE_colordialog)
+ SOURCES
+ qcocoacolordialoghelper.h qcocoacolordialoghelper.mm
+)
+
+extend_target(qcocoa CONDITION (TARGET Qt::Widgets) AND (QT_FEATURE_filedialog)
+ SOURCES
+ qcocoafiledialoghelper.h qcocoafiledialoghelper.mm
+)
+
+extend_target(qcocoa CONDITION (TARGET Qt::Widgets) AND (QT_FEATURE_fontdialog)
+ SOURCES
+ qcocoafontdialoghelper.h qcocoafontdialoghelper.mm
+)
+
+#### Keys ignored in scope 9:.:.:cocoa.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
diff --git a/src/plugins/platforms/eglfs/CMakeLists.txt b/src/plugins/platforms/eglfs/CMakeLists.txt
new file mode 100644
index 0000000000..5a4639ddd3
--- /dev/null
+++ b/src/plugins/platforms/eglfs/CMakeLists.txt
@@ -0,0 +1,102 @@
+find_package(EGL)
+find_package(WrapOpenGL)
+
+#####################################################################
+## EglFSDeviceIntegration Module:
+#####################################################################
+
+add_qt_module(EglFSDeviceIntegration
+ 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_EGL_NO_X11
+ QT_BUILD_EGL_DEVICE_LIB
+ 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
+ WrapOpenGL # special case
+)
+
+#### Keys ignored in scope 2:.:./eglfsdeviceintegration.pro:<NONE>:
+# CONFIG = "internal_module" "egl"
+# MODULE = "eglfsdeviceintegration"
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+extend_target(EglFSDeviceIntegration CONDITION TARGET Qt::InputSupportPrivate
+ LIBRARIES
+ Qt::InputSupportPrivate
+)
+
+extend_target(EglFSDeviceIntegration CONDITION TARGET Qt::PlatformCompositorSupportPrivate
+ LIBRARIES
+ Qt::PlatformCompositorSupportPrivate
+)
+
+# special case:
+# extend_target(EglFSDeviceIntegration CONDITION NOT EGLFS_PLATFORM_HOOKS_SOURCES_ISEMPTY ...
+# extend_target(EglFSDeviceIntegration CONDITION NOT EGLFS_DEVICE_INTEGRATION_ISEMPTY ...
+
+#### Keys ignored in scope 7:.:./eglfsdeviceintegration.pro:use_gold_linker:
+# CONFIG = "no_linker_version_script"
+
+# Resources:
+add_qt_resource(EglFSDeviceIntegration "cursor" FILES
+ cursor-atlas.png
+ cursor.json)
+
+
+extend_target(EglFSDeviceIntegration CONDITION QT_FEATURE_opengl
+ SOURCES
+ api/qeglfscontext.cpp api/qeglfscontext_p.h
+ api/qeglfscursor.cpp api/qeglfscursor_p.h
+)
+#####################################################################
+## qeglfs Plugin:
+#####################################################################
+
+add_qt_plugin(qeglfs
+ TYPE platforms
+ 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:<NONE>:
+# CONFIG = "egl"
+# OTHER_FILES = "$$PWD/eglfs.json"
+# PLUGIN_CLASS_NAME = "QEglFSIntegrationPlugin"
+# _LOADED = "qt_plugin"
+
+## 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/CMakeLists.txt b/src/plugins/platforms/eglfs/deviceintegration/CMakeLists.txt
new file mode 100644
index 0000000000..396964a5e7
--- /dev/null
+++ b/src/plugins/platforms/eglfs/deviceintegration/CMakeLists.txt
@@ -0,0 +1,49 @@
+# Generated from deviceintegration.pro.
+
+if(QT_FEATURE_egl_x11)
+ add_subdirectory(eglfs_x11)
+endif()
+
+if(QT_FEATURE_eglfs_gbm OR QT_FEATURE_eglfs_egldevice)
+ 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)
+# TODO add_subdirectory(eglfs_kms_vsp2)
+endif()
+
+if(QT_FEATURE_eglfs_brcm)
+# TODO add_subdirectory(eglfs_brcm)
+endif()
+
+if(QT_FEATURE_eglfs_mali)
+# TODO add_subdirectory(eglfs_mali)
+endif()
+
+if(QT_FEATURE_eglfs_viv)
+# TODO add_subdirectory(eglfs_viv)
+endif()
+
+if(QT_FEATURE_eglfs_rcar)
+# TODO add_subdirectory(eglfs_rcar)
+endif()
+
+if(QT_FEATURE_eglfs_viv_wl)
+# TODO add_subdirectory(eglfs_viv_wl)
+endif()
+
+if(QT_FEATURE_eglfs_openwfd)
+# TODO add_subdirectory(eglfs_openwfd)
+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..64dd4d8548
--- /dev/null
+++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_emu/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from eglfs_emu.pro.
+
+#####################################################################
+## qeglfs-emu-integration Plugin:
+#####################################################################
+
+add_qt_plugin(qeglfs-emu-integration
+ TYPE egldeviceintegrations
+ SOURCES
+ qeglfsemulatorintegration.cpp qeglfsemulatorintegration.h
+ qeglfsemulatorscreen.cpp qeglfsemulatorscreen.h
+ qeglfsemumain.cpp
+ DEFINES
+ QT_EGL_NO_X11
+ INCLUDE_DIRECTORIES
+ ../../api
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::EglFSDeviceIntegrationPrivate
+ # CONFIG = "egl"
+ # DISTFILES = "eglfs_emu.json"
+ # OTHER_FILES = "$$PWD/eglfs_emu.json"
+ # PLUGIN_CLASS_NAME = "QEglFSEmulatorIntegrationPlugin"
+ # _LOADED = "qt_plugin"
+)
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..09a9560f80
--- /dev/null
+++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/CMakeLists.txt
@@ -0,0 +1,38 @@
+# Generated from eglfs_kms.pro.
+
+find_package(gbm)
+find_package(Libdrm)
+
+#####################################################################
+## qeglfs-kms-integration Plugin:
+#####################################################################
+
+add_qt_plugin(qeglfs-kms-integration
+ TYPE egldeviceintegrations
+ 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::GuiPrivate
+ Qt::EglFSDeviceIntegrationPrivate
+ Qt::EglFsKmsSupportPrivate
+ Qt::KmsSupportPrivate
+ Qt::EdidSupportPrivate
+ Qt::PlatformCompositorSupportPrivate
+ gbm::gbm
+ Libdrm::Libdrm
+ # CONFIG = "egl"
+ # OTHER_FILES = "$$PWD/eglfs_kms.json"
+ # PLUGIN_CLASS_NAME = "QEglFSKmsGbmIntegrationPlugin"
+ # _LOADED = "qt_plugin"
+)
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..9dc5d84523
--- /dev/null
+++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/CMakeLists.txt
@@ -0,0 +1,34 @@
+# Generated from eglfs_kms_egldevice.pro.
+
+find_package(Libdrm)
+
+#####################################################################
+## qeglfs-kms-egldevice-integration Plugin:
+#####################################################################
+
+add_qt_plugin(qeglfs-kms-egldevice-integration
+ TYPE egldeviceintegrations
+ 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::GuiPrivate
+ Qt::EglFSDeviceIntegrationPrivate
+ Qt::EglFsKmsSupportPrivate
+ Qt::KmsSupportPrivate
+ Qt::EdidSupportPrivate
+ Qt::PlatformCompositorSupportPrivate
+ Libdrm::Libdrm
+ # CONFIG = "egl"
+ # OTHER_FILES = "$$PWD/eglfs_kms_egldevice.json"
+ # PLUGIN_CLASS_NAME = "QEglFSKmsEglDeviceIntegrationPlugin"
+ # _LOADED = "qt_plugin"
+)
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..f077ceae4a
--- /dev/null
+++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_support/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from eglfs_kms_support.pro.
+
+find_package(Libdrm)
+
+#####################################################################
+## EglFsKmsSupport Module:
+#####################################################################
+
+add_qt_module(EglFsKmsSupport
+ 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::GuiPrivate
+ Qt::EglFSDeviceIntegrationPrivate
+ Qt::KmsSupportPrivate
+ Qt::EdidSupportPrivate
+ Libdrm::Libdrm
+ # CONFIG = "no_module_headers" "internal_module" "egl"
+ # _LOADED = "qt_module"
+)
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..aaa4da9cb3
--- /dev/null
+++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_x11/CMakeLists.txt
@@ -0,0 +1,31 @@
+# Generated from eglfs_x11.pro.
+
+find_package(XCB)
+find_package(X11)
+find_package(X11_XCB)
+
+#####################################################################
+## qeglfs-x11-integration Plugin:
+#####################################################################
+
+add_qt_plugin(qeglfs-x11-integration
+ TYPE egldeviceintegrations
+ SOURCES
+ qeglfsx11integration.cpp qeglfsx11integration.h
+ qeglfsx11main.cpp
+ DEFINES
+ QT_EGL_NO_X11
+ INCLUDE_DIRECTORIES
+ ../../api
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::EglFSDeviceIntegrationPrivate
+ XCB::XCB
+ X11::X11
+ X11::XCB
+ # CONFIG = "egl"
+ # OTHER_FILES = "$$PWD/eglfs_x11.json"
+ # PLUGIN_CLASS_NAME = "QEglFSX11IntegrationPlugin"
+ # _LOADED = "qt_plugin"
+)
diff --git a/src/plugins/platforms/linuxfb/CMakeLists.txt b/src/plugins/platforms/linuxfb/CMakeLists.txt
new file mode 100644
index 0000000000..6c80083503
--- /dev/null
+++ b/src/plugins/platforms/linuxfb/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from linuxfb.pro.
+
+#####################################################################
+## qlinuxfb Plugin:
+#####################################################################
+
+add_qt_plugin(qlinuxfb
+ TYPE platforms
+ SOURCES
+ main.cpp
+ qlinuxfbintegration.cpp qlinuxfbintegration.h
+ qlinuxfbscreen.cpp qlinuxfbscreen.h
+ DEFINES
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::ServiceSupportPrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::FbSupportPrivate
+ # OTHER_FILES = "linuxfb.json"
+ # PLUGIN_CLASS_NAME = "QLinuxFbIntegrationPlugin"
+ # _LOADED = "qt_plugin"
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(qlinuxfb CONDITION TARGET Qt::InputSupportPrivate
+ LIBRARIES
+ Qt::InputSupportPrivate
+)
+
+extend_target(qlinuxfb CONDITION TARGET Qt::KmsSupportPrivate
+ SOURCES
+ qlinuxfbdrmscreen.cpp qlinuxfbdrmscreen.h
+ LIBRARIES
+ Qt::KmsSupportPrivate
+)
+#
+#extend_target(qlinuxfb CONDITION 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..0c3e44e2f1
--- /dev/null
+++ b/src/plugins/platforms/minimal/CMakeLists.txt
@@ -0,0 +1,36 @@
+find_package(Freetype) # special case
+
+#####################################################################
+## qminimal Plugin:
+#####################################################################
+
+add_qt_plugin(qminimal
+ TYPE platforms
+ SOURCES
+ main.cpp
+ qminimalbackingstore.cpp qminimalbackingstore.h
+ qminimalintegration.cpp qminimalintegration.h
+ DEFINES
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+)
+
+#### Keys ignored in scope 1:.:minimal.pro:<NONE>:
+# OTHER_FILES = "minimal.json"
+# PLUGIN_CLASS_NAME = "QMinimalIntegrationPlugin"
+# _LOADED = "qt_plugin"
+
+## Scopes:
+#####################################################################
+
+extend_target(qminimal CONDITION QT_FEATURE_freetype
+ LIBRARIES
+ Freetype::Freetype
+)
+
+#### Keys ignored in scope 3:.:minimal.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..f42925f632
--- /dev/null
+++ b/src/plugins/platforms/minimalegl/CMakeLists.txt
@@ -0,0 +1,41 @@
+# Generated from minimalegl.pro.
+
+find_package(WrapOpenGL)
+
+#####################################################################
+## qminimalegl Plugin:
+#####################################################################
+
+add_qt_plugin(qminimalegl
+ TYPE platforms
+ SOURCES
+ main.cpp
+ qminimaleglintegration.cpp qminimaleglintegration.h
+ qminimaleglscreen.cpp qminimaleglscreen.h
+ qminimaleglwindow.cpp qminimaleglwindow.h
+ DEFINES
+ QT_EGL_NO_X11
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::EglSupportPrivate
+ WrapOpenGL
+ # CONFIG = "egl"
+ # OTHER_FILES = "minimalegl.json"
+ # PLUGIN_CLASS_NAME = "QMinimalEglIntegrationPlugin"
+ # _LOADED = "qt_plugin"
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(qminimalegl CONDITION QT_FEATURE_opengl
+ SOURCES
+ qminimaleglbackingstore.cpp qminimaleglbackingstore.h
+)
+#
+#extend_target(qminimalegl CONDITION 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..3546f8710b
--- /dev/null
+++ b/src/plugins/platforms/offscreen/CMakeLists.txt
@@ -0,0 +1,46 @@
+# Generated from offscreen.pro.
+
+#####################################################################
+## qoffscreen Plugin:
+#####################################################################
+
+add_qt_plugin(qoffscreen
+ TYPE platforms
+ 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"
+# PLUGIN_CLASS_NAME = "QOffscreenIntegrationPlugin"
+# _LOADED = "qt_plugin"
+
+## Scopes:
+#####################################################################
+
+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/CMakeLists.txt b/src/plugins/platforms/vnc/CMakeLists.txt
new file mode 100644
index 0000000000..ced972391d
--- /dev/null
+++ b/src/plugins/platforms/vnc/CMakeLists.txt
@@ -0,0 +1,41 @@
+# Generated from vnc.pro.
+
+#####################################################################
+## qvnc Plugin:
+#####################################################################
+
+add_qt_plugin(qvnc
+ TYPE platforms
+ 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::Network
+ Qt::GuiPrivate
+ Qt::ServiceSupportPrivate
+ Qt::ThemeSupportPrivate
+ Qt::FbSupportPrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ # OTHER_FILES = "vnc.json"
+ # PLUGIN_CLASS_NAME = "QVncIntegrationPlugin"
+ # _LOADED = "qt_plugin"
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(qvnc CONDITION TARGET Qt::InputSupportPrivate
+ LIBRARIES
+ Qt::InputSupportPrivate
+)
+#
+#extend_target(qvnc CONDITION NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN
+# # PLUGIN_EXTENDS = "-"
+#)
diff --git a/src/plugins/platforms/windows/CMakeLists.txt b/src/plugins/platforms/windows/CMakeLists.txt
new file mode 100644
index 0000000000..c665d75af7
--- /dev/null
+++ b/src/plugins/platforms/windows/CMakeLists.txt
@@ -0,0 +1,203 @@
+# Generated from windows.pro.
+
+#####################################################################
+## qwindows Plugin:
+#####################################################################
+
+add_qt_plugin(qwindows
+ TYPE platforms
+ 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
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EventDispatcherSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ThemeSupportPrivate
+ advapi32
+ dwmapi
+ gdi32
+ imm32
+ ole32
+ oleaut32
+ shell32
+ shlwapi
+ user32
+ winmm
+ winspool
+ wtsapi32
+)
+
+# Resources:
+set_source_files_properties("openglblacklists/default.json"
+ PROPERTIES alias "default.json")
+add_qt_resource(qwindows "openglblacklists" PREFIX "/qt-project.org/windows/openglblacklists" FILES
+ openglblacklists/default.json)
+
+
+#### Keys ignored in scope 1:.:windows.pro:<NONE>:
+# OTHER_FILES = "windows.json"
+# PLUGIN_CLASS_NAME = "QWindowsIntegrationPlugin"
+# QT_FOR_CONFIG = "gui"
+# _LOADED = "qt_plugin"
+
+## Scopes:
+#####################################################################
+
+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
+ LIBRARIES
+ Qt::AccessibilitySupportPrivate
+)
+
+extend_target(qwindows CONDITION QT_FEATURE_vulkan
+ SOURCES
+ qwindowsvulkaninstance.cpp qwindowsvulkaninstance.h
+ LIBRARIES
+ Qt::VulkanSupportPrivate
+)
+
+#### Keys ignored in scope 4:.:windows.pro:NOT TARGET___equals____ss_QT_DEFAULT_QPA_PLUGIN:
+# PLUGIN_EXTENDS = "-"
+
+extend_target(qwindows CONDITION QT_FEATURE_opengl AND NOT QT_FEATURE_dynamicgl AND NOT QT_FEATURE_opengles2
+ LIBRARIES
+ opengl32
+)
+
+extend_target(qwindows CONDITION mingw
+ LIBRARIES
+ uuid
+)
+
+extend_target(qwindows CONDITION QT_FEATURE_opengl
+ SOURCES
+ qwindowsopenglcontext.h
+)
+
+extend_target(qwindows CONDITION QT_FEATURE_opengles2
+ SOURCES
+ qwindowseglcontext.cpp qwindowseglcontext.h
+)
+
+extend_target(qwindows CONDITION QT_FEATURE_opengl AND NOT QT_FEATURE_opengles2
+ SOURCES
+ qwindowsglcontext.cpp qwindowsglcontext.h
+)
+
+extend_target(qwindows CONDITION QT_FEATURE_dynamicgl
+ SOURCES
+ qwindowseglcontext.cpp qwindowseglcontext.h
+)
+
+extend_target(qwindows CONDITION QT_FEATURE_systemtrayicon
+ SOURCES
+ qwindowssystemtrayicon.cpp qwindowssystemtrayicon.h
+)
+
+extend_target(qwindows CONDITION QT_FEATURE_clipboard
+ SOURCES
+ qwindowsclipboard.cpp qwindowsclipboard.h
+)
+
+extend_target(qwindows CONDITION QT_FEATURE_clipboard AND QT_FEATURE_draganddrop
+ SOURCES
+ qwindowsdrag.cpp qwindowsdrag.h
+)
+
+extend_target(qwindows CONDITION QT_FEATURE_tabletevent
+ SOURCES
+ qwindowstabletsupport.cpp qwindowstabletsupport.h
+ INCLUDE_DIRECTORIES
+ ${PROJECT_SOURCE_DIR}/src/3rdparty/wintab
+)
+
+extend_target(qwindows CONDITION QT_FEATURE_sessionmanager
+ SOURCES
+ qwindowssessionmanager.cpp qwindowssessionmanager.h
+)
+
+# Resources:
+add_qt_resource(qwindows "cursors" PREFIX "/qt-project.org/windows/cursors" 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)
+
+
+extend_target(qwindows CONDITION (QT_FEATURE_accessibility) AND (TARGET WindowsUIAutomationSupportPrivate)
+ LIBRARIES
+ Qt::WindowsUIAutomationSupportPrivate
+)
+
+extend_target(qwindows CONDITION QT_FEATURE_accessibility AND mingw
+ 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 073d6da536..e14a0c1984 100644
--- a/src/plugins/platforms/windows/qwindowscontext.cpp
+++ b/src/plugins/platforms/windows/qwindowscontext.cpp
@@ -907,7 +907,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/CMakeLists.txt b/src/plugins/platforms/xcb/CMakeLists.txt
new file mode 100644
index 0000000000..646d9f1976
--- /dev/null
+++ b/src/plugins/platforms/xcb/CMakeLists.txt
@@ -0,0 +1,167 @@
+# Generated from xcb_qpa_lib.pro.
+
+# special case:
+find_package(X11_XCB)
+find_package(X11)
+find_package(XCB)
+find_package(XKB)
+find_package(PkgConfig)
+find_package(Freetype)
+find_package(GLIB2)
+
+pkg_check_modules(XKB_COMMON_X11 xkbcommon-x11>=0.4.1 IMPORTED_TARGET) # special case
+
+#####################################################################
+## XcbQpa Module:
+#####################################################################
+
+add_qt_module(XcbQpa
+ 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
+ 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_NO_FOREACH
+ QT_BUILD_XCB_PLUGIN
+ INCLUDE_DIRECTORIES
+ gl_integrations
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::EdidSupportPrivate
+ Qt::FontDatabaseSupportPrivate
+ Qt::GuiPrivate
+ Qt::ServiceSupportPrivate
+ Qt::ThemeSupportPrivate
+ Qt::XkbCommonSupportPrivate
+ PUBLIC_LIBRARIES
+ ${CMAKE_DL_LIBS}
+ 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
+ XKB::XKB
+)
+
+#### Keys ignored in scope 1:.:.:xcb_qpa_lib.pro:<TRUE>:
+# CONFIG = "no_module_headers" "internal_module"
+# _LOADED = "qt_build_paths" "qt_module"
+
+## Scopes:
+#####################################################################
+
+extend_target(XcbQpa CONDITION TARGET Qt::LinuxAccessibilitySupportPrivate
+ LIBRARIES
+ Qt::LinuxAccessibilitySupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::LinuxAccessibilitySupport
+)
+
+extend_target(XcbQpa CONDITION QT_FEATURE_vulkan
+ SOURCES
+ qxcbvulkaninstance.cpp qxcbvulkaninstance.h
+ qxcbvulkanwindow.cpp qxcbvulkanwindow.h
+ LIBRARIES
+ Qt::VulkanSupportPrivate
+ PUBLIC_LIBRARIES
+ Qt::VulkanSupport
+)
+
+extend_target(XcbQpa CONDITION QT_FEATURE_glib
+ LIBRARIES
+ GLIB2::GLIB2
+)
+
+extend_target(XcbQpa CONDITION QT_FEATURE_draganddrop
+ SOURCES
+ qxcbdrag.cpp qxcbdrag.h
+)
+
+extend_target(XcbQpa CONDITION QT_FEATURE_xcb_xlib
+ PUBLIC_LIBRARIES
+ X11::XCB
+)
+
+extend_target(XcbQpa CONDITION QT_FEATURE_xcb_xinput
+ SOURCES
+ qxcbconnection_xi2.cpp
+ PUBLIC_LIBRARIES
+ XCB::XINPUT
+)
+
+extend_target(XcbQpa CONDITION QT_FEATURE_xcb_sm
+ SOURCES
+ qxcbsessionmanager.cpp qxcbsessionmanager.h
+ PUBLIC_LIBRARIES
+ ${X11_SM_LIB} ${X11_ICE_LIB}
+)
+
+extend_target(XcbQpa CONDITION QT_FEATURE_xkb
+ PUBLIC_LIBRARIES
+ XCB::XKB
+ XKB::XKB
+)
+
+extend_target(XcbQpa CONDITION CLANG AND NOT ICC
+ COMPILE_OPTIONS
+ "-ftemplate-depth=1024"
+)
+
+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
+)
+
+extend_target(XcbQpa CONDITION QT_FEATURE_xcb_native_painting AND QT_FEATURE_xrender
+ PUBLIC_LIBRARIES
+ X11::Xrender # special case
+)
+
+extend_target(XcbQpa CONDITION QT_FEATURE_fontconfig AND QT_FEATURE_xcb_native_painting
+ LIBRARIES
+ Freetype::Freetype
+)
diff --git a/src/plugins/platformthemes/CMakeLists.txt b/src/plugins/platformthemes/CMakeLists.txt
new file mode 100644
index 0000000000..8550a80652
--- /dev/null
+++ b/src/plugins/platformthemes/CMakeLists.txt
@@ -0,0 +1,10 @@
+# Generated from platformthemes.pro.
+
+if (QT_FEATURE_dbus AND QT_FEATURE_regularexpression)
+ add_subdirectory(xdgdesktopportal)
+endif()
+
+if (QT_FEATURE_widgets AND QT_FEATURE_gtk3)
+ add_subdirectory(gtk3)
+endif()
+
diff --git a/src/plugins/platformthemes/gtk3/CMakeLists.txt b/src/plugins/platformthemes/gtk3/CMakeLists.txt
new file mode 100644
index 0000000000..18bf562970
--- /dev/null
+++ b/src/plugins/platformthemes/gtk3/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from gtk3.pro.
+
+find_package(GTK3)
+find_package(X11)
+
+#####################################################################
+## qgtk3 Plugin:
+#####################################################################
+
+add_qt_plugin(qgtk3
+ TYPE platformthemes
+ 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
+ PkgConfig::GTK3
+ X11::X11
+ # CONFIG = "X11"
+ # PLUGIN_CLASS_NAME = "QGtk3ThemePlugin"
+ # PLUGIN_EXTENDS = "-"
+ # _LOADED = "qt_plugin"
+)
diff --git a/src/plugins/platformthemes/xdgdesktopportal/CMakeLists.txt b/src/plugins/platformthemes/xdgdesktopportal/CMakeLists.txt
new file mode 100644
index 0000000000..59e555cde0
--- /dev/null
+++ b/src/plugins/platformthemes/xdgdesktopportal/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from xdgdesktopportal.pro.
+
+#####################################################################
+## qxdgdesktopportal Plugin:
+#####################################################################
+
+add_qt_plugin(qxdgdesktopportal
+ TYPE platformthemes
+ SOURCES
+ main.cpp
+ qxdgdesktopportalfiledialog.cpp qxdgdesktopportalfiledialog_p.h
+ qxdgdesktopportaltheme.cpp qxdgdesktopportaltheme.h
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBus
+ Qt::GuiPrivate
+ Qt::ThemeSupportPrivate
+ # PLUGIN_CLASS_NAME = "QXdgDesktopPortalThemePlugin"
+ # PLUGIN_EXTENDS = "-"
+ # _LOADED = "qt_plugin"
+)
diff --git a/src/plugins/printsupport/CMakeLists.txt b/src/plugins/printsupport/CMakeLists.txt
new file mode 100644
index 0000000000..9a92a865c0
--- /dev/null
+++ b/src/plugins/printsupport/CMakeLists.txt
@@ -0,0 +1,11 @@
+if (APPLE_OSX)
+# TODO add_subdirectory(cocoa)
+endif()
+
+if (WIN32)
+# TODO add_subdirectory(windows)
+endif()
+
+if (UNIX AND NOT APPLE AND QT_FEATURE_cups)
+ add_subdirectory(cups)
+endif()
diff --git a/src/plugins/printsupport/cups/CMakeLists.txt b/src/plugins/printsupport/cups/CMakeLists.txt
new file mode 100644
index 0000000000..d36a5e7be5
--- /dev/null
+++ b/src/plugins/printsupport/cups/CMakeLists.txt
@@ -0,0 +1,28 @@
+# Generated from cups.pro.
+
+find_package(Cups)
+
+#####################################################################
+## cupsprintersupport Plugin:
+#####################################################################
+
+add_qt_plugin(cupsprintersupport
+ TYPE printsupport
+ SOURCES
+ main.cpp
+ qcupsprintengine.cpp qcupsprintengine_p.h
+ qcupsprintersupport.cpp qcupsprintersupport_p.h
+ qppdprintdevice.cpp qppdprintdevice.h
+ INCLUDE_DIRECTORIES
+ ../../../printsupport/kernel
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::PrintSupport
+ Qt::PrintSupportPrivate
+ Cups::Cups
+ # MODULE = "cupsprintersupport"
+ # OTHER_FILES = "cups.json"
+ # PLUGIN_CLASS_NAME = "QCupsPrinterSupportPlugin"
+ # _LOADED = "qt_plugin"
+)
diff --git a/src/plugins/sqldrivers/CMakeLists.txt b/src/plugins/sqldrivers/CMakeLists.txt
new file mode 100644
index 0000000000..1676396f3a
--- /dev/null
+++ b/src/plugins/sqldrivers/CMakeLists.txt
@@ -0,0 +1,51 @@
+# Generated from sqldrivers.pro.
+
+# 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)
+# TODO 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)
+# TODO add_subdirectory(oci)
+endif()
+
+if(QT_FEATURE_sql_db2)
+# TODO 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()
diff --git a/src/plugins/sqldrivers/configure.cmake b/src/plugins/sqldrivers/configure.cmake
new file mode 100644
index 0000000000..41a66197d1
--- /dev/null
+++ b/src/plugins/sqldrivers/configure.cmake
@@ -0,0 +1,58 @@
+
+
+#### Inputs
+
+
+
+#### Libraries
+
+find_package(PostgreSQL)
+set_package_properties(PostgreSQL PROPERTIES TYPE OPTIONAL)
+find_package(ODBC)
+set_package_properties(ODBC PROPERTIES TYPE OPTIONAL)
+find_package(SQLite3)
+set_package_properties(SQLite3 PROPERTIES TYPE OPTIONAL)
+
+
+#### Tests
+
+
+
+#### Features
+
+qt_feature("sql_db2" PRIVATE
+ LABEL "DB2 (IBM)"
+ CONDITION libs.db2 OR FIXME
+)
+qt_feature("sql_ibase" PRIVATE
+ LABEL "InterBase"
+ CONDITION libs.ibase OR FIXME
+)
+qt_feature("sql_mysql" PRIVATE
+ LABEL "MySql"
+ CONDITION libs.mysql OR FIXME
+)
+qt_feature("sql_oci" PRIVATE
+ LABEL "OCI (Oracle)"
+ CONDITION libs.oci OR FIXME
+)
+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 cd20eef1df..441cdc4885 100644
--- a/src/plugins/sqldrivers/configure.json
+++ b/src/plugins/sqldrivers/configure.json
@@ -216,9 +216,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/odbc/CMakeLists.txt b/src/plugins/sqldrivers/odbc/CMakeLists.txt
new file mode 100644
index 0000000000..c3c52f526c
--- /dev/null
+++ b/src/plugins/sqldrivers/odbc/CMakeLists.txt
@@ -0,0 +1,33 @@
+find_package(ODBC) # special case
+
+#####################################################################
+## qsqlodbc Plugin:
+#####################################################################
+
+add_qt_plugin(qsqlodbc
+ TYPE sqldrivers
+ SOURCES
+ main.cpp
+ qsql_odbc.cpp qsql_odbc_p.h
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ ODBC::ODBC
+ Qt::Core
+ Qt::CorePrivate
+ Qt::SqlPrivate
+)
+
+#### Keys ignored in scope 1:.:odbc.pro:<NONE>:
+# OTHER_FILES = "odbc.json"
+# PLUGIN_CLASS_NAME = "QODBCDriverPlugin"
+# _LOADED = "qt_plugin"
+
+## Scopes:
+#####################################################################
+
+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 7f98efccba..5bf23fdaed 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/CMakeLists.txt b/src/plugins/sqldrivers/psql/CMakeLists.txt
new file mode 100644
index 0000000000..dfbeaba6de
--- /dev/null
+++ b/src/plugins/sqldrivers/psql/CMakeLists.txt
@@ -0,0 +1,28 @@
+# 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
+find_package(PostgreSQL) # special case
+
+#####################################################################
+## qsqlpsql Plugin:
+#####################################################################
+
+add_qt_plugin(qsqlpsql
+ TYPE sqldrivers
+ SOURCES
+ main.cpp
+ qsql_psql.cpp qsql_psql_p.h
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ PostgreSQL::PostgreSQL
+ Qt::Core
+ Qt::CorePrivate
+ Qt::SqlPrivate
+)
+
+#### Keys ignored in scope 1:.:psql.pro:<NONE>:
+# OTHER_FILES = "psql.json"
+# PLUGIN_CLASS_NAME = "QPSQLDriverPlugin"
+# _LOADED = "qt_plugin"
diff --git a/src/plugins/sqldrivers/sqlite/CMakeLists.txt b/src/plugins/sqldrivers/sqlite/CMakeLists.txt
new file mode 100644
index 0000000000..4034f3f4e0
--- /dev/null
+++ b/src/plugins/sqldrivers/sqlite/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from sqlite.pro.
+
+#####################################################################
+## qsqlite Plugin:
+#####################################################################
+
+add_qt_plugin(qsqlite
+ TYPE sqldrivers
+ SOURCES
+ qsql_sqlite.cpp qsql_sqlite_p.h
+ smain.cpp
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::Core
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ SQLite::SQLite3
+)
+
+#### Keys ignored in scope 1:.:sqlite.pro:<NONE>:
+# OTHER_FILES = "sqlite.json"
+# PLUGIN_CLASS_NAME = "QSQLiteDriverPlugin"
+# QT_FOR_CONFIG = "sqldrivers-private"
+# _LOADED = "qt_plugin"
+
+## Scopes:
+#####################################################################
+
+# special case: Remove dead stuff
+# extend_target(qsqlite CONDITION (NOT (ON)) AND (CONFIG(release,debug OR release)) ...
diff --git a/src/plugins/styles/CMakeLists.txt b/src/plugins/styles/CMakeLists.txt
new file mode 100644
index 0000000000..34248d0a59
--- /dev/null
+++ b/src/plugins/styles/CMakeLists.txt
@@ -0,0 +1,11 @@
+if(QT_FEATURE_style_android)
+# TODO add_subdirectory(android)
+endif()
+
+if(QT_FEATURE_style_mac)
+ add_subdirectory(mac)
+endif()
+
+if(QT_FEATURE_style_windowsvista)
+# TODO 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..1daee30060
--- /dev/null
+++ b/src/plugins/styles/mac/CMakeLists.txt
@@ -0,0 +1,19 @@
+# Generated from mac.pro.
+
+#####################################################################
+## qmacstyle Plugin:
+#####################################################################
+
+add_qt_plugin(qmacstyle
+ TYPE styles
+ SOURCES
+ main.mm
+ qmacstyle_mac.mm qmacstyle_mac_p.h
+ qmacstyle_mac_p_p.h
+ LIBRARIES
+ Qt::WidgetsPrivate
+ ${FWAppKit}
+ # DISTFILES = "macstyle.json"
+ # PLUGIN_CLASS_NAME = "QMacStylePlugin"
+ # _LOADED = "qt_plugin"
+)
diff --git a/src/printsupport/CMakeLists.txt b/src/printsupport/CMakeLists.txt
new file mode 100644
index 0000000000..b23a61e55d
--- /dev/null
+++ b/src/printsupport/CMakeLists.txt
@@ -0,0 +1,147 @@
+# Generated from printsupport.pro.
+
+#####################################################################
+## PrintSupport Module:
+#####################################################################
+
+add_qt_module(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_USING_NAMESPACE
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ widgets
+ dialogs
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ PUBLIC_LIBRARIES # special case
+ Qt::Gui
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:printsupport.pro:<NONE>:
+# MODULE_PLUGIN_TYPES = "printsupport"
+# QMAKE_LIBS = "$$QMAKE_LIBS_PRINTSUPPORT"
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+extend_target(PrintSupport CONDITION QT_FEATURE_printpreviewwidget
+ SOURCES
+ kernel/qpaintengine_preview.cpp kernel/qpaintengine_preview_p.h
+ widgets/qprintpreviewwidget.cpp widgets/qprintpreviewwidget.h
+)
+
+extend_target(PrintSupport CONDITION WIN32
+ SOURCES
+ kernel/qprintengine_win.cpp kernel/qprintengine_win_p.h
+)
+
+extend_target(PrintSupport CONDITION WIN32 AND NOT WINRT
+ LIBRARIES
+ comdlg32
+ gdi32
+ user32
+ winspool
+)
+
+extend_target(PrintSupport CONDITION QT_FEATURE_cups AND UNIX AND NOT APPLE
+ SOURCES
+ kernel/qcups.cpp kernel/qcups_p.h
+)
+
+extend_target(PrintSupport CONDITION QT_FEATURE_cupsjobwidget AND UNIX AND NOT APPLE
+ SOURCES
+ widgets/qcupsjobwidget.cpp widgets/qcupsjobwidget.ui widgets/qcupsjobwidget_p.h
+)
+
+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
+)
+
+# Resources:
+add_qt_resource(PrintSupport "qprintdialog" PREFIX "/qt-project.org/dialogs/qprintpreviewdialog" BASE "dialogs" 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)
+add_qt_resource(PrintSupport "qprintdialog1" PREFIX "/qt-project.org/dialogs/qprintdialog" BASE "dialogs" FILES
+ images/status-color.png
+ images/status-gray-scale.png)
+
+
+extend_target(PrintSupport CONDITION APPLE_OSX AND QT_FEATURE_printdialog
+ SOURCES
+ dialogs/qpagesetupdialog_mac.mm
+ dialogs/qprintdialog_mac.mm
+ LIBRARIES
+ ${FWAppKit}
+)
+
+extend_target(PrintSupport CONDITION QT_FEATURE_printdialog AND WIN32
+ SOURCES
+ dialogs/qpagesetupdialog_win.cpp
+ dialogs/qprintdialog_win.cpp
+)
+
+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
+ ${PROJECT_SOURCE_DIR}/src/plugins/printsupport/cups
+)
+
+extend_target(PrintSupport CONDITION QT_FEATURE_printpreviewdialog
+ SOURCES
+ dialogs/qprintpreviewdialog.cpp dialogs/qprintpreviewdialog.h
+)
+
+add_qt_docs(./doc/qtprintsupport.qdocconf)
diff --git a/src/printsupport/configure.cmake b/src/printsupport/configure.cmake
new file mode 100644
index 0000000000..40aab5d9f7
--- /dev/null
+++ b/src/printsupport/configure.cmake
@@ -0,0 +1,59 @@
+
+
+#### Inputs
+
+
+
+#### Libraries
+
+find_package(Cups)
+set_package_properties(Cups PROPERTIES TYPE OPTIONAL)
+
+
+#### 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..d438b78446
--- /dev/null
+++ b/src/sql/CMakeLists.txt
@@ -0,0 +1,51 @@
+# Generated from sql.pro.
+
+#####################################################################
+## Sql Module:
+#####################################################################
+
+add_qt_module(Sql
+ 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_USING_NAMESPACE
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES # special case
+ Qt::Core
+ # MODULE_PLUGIN_TYPES = "sqldrivers"
+ # PRECOMPILED_HEADER = "../corelib/global/qt_pch.h"
+ # SQL_P = "sql"
+ # _LOADED = "qt_module"
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(Sql CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x62000000"
+)
+
+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
+)
+
+add_qt_docs(./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/CMakeLists.txt b/src/testlib/CMakeLists.txt
new file mode 100644
index 0000000000..509748e51e
--- /dev/null
+++ b/src/testlib/CMakeLists.txt
@@ -0,0 +1,112 @@
+# Generated from testlib.pro.
+
+#####################################################################
+## Test Module:
+#####################################################################
+
+add_qt_module(Test
+ CONFIG_MODULE_NAME testlib # special case
+ SOURCES
+ qabstracttestlogger.cpp
+ 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
+ qbenchmarkvalgrind.cpp qbenchmarkvalgrind_p.h
+ qcsvbenchmarklogger.cpp
+ qplaintestlogger.cpp
+ qsignaldumper.cpp
+ qsignalspy.h
+ qtaptestlogger.cpp qtaptestlogger_p.h
+ qteamcitylogger.cpp
+ qtest.h
+ qtest_gui.h
+ qtest_network.h
+ qtest_widgets.h
+ qtestaccessible.h
+ qtestassert.h
+ qtestblacklist.cpp qtestblacklist_p.h
+ qtestcase.cpp qtestcase.h
+ qtestdata.cpp qtestdata.h
+ qtestelement.cpp
+ qtestelementattribute.cpp
+ qtestevent.h
+ qtesteventloop.h
+ qtesthelpers_p.h
+ qtestkeyboard.h
+ qtestlog.cpp
+ qtestmouse.cpp qtestmouse.h
+ qtestresult.cpp
+ qtestspontaneevent.h
+ qtestsystem.h
+ qtesttable.cpp
+ qtesttouch.h
+ qtestxunitstreamer.cpp
+ qttestglobal.h
+ qxmltestlogger.cpp
+ qxunittestlogger.cpp
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ QT_NO_DATASTREAM
+ QT_BUILD_TESTLIB_LIB # special case
+ LIBRARIES
+ Qt::CorePrivate
+ PUBLIC_LIBRARIES # special case
+ Qt::Core
+)
+
+#### Keys ignored in scope 1:.:testlib.pro:<NONE>:
+# CONFIG = "exceptions"
+# MODULE_CONFIG = "console" "testlib_defines"
+# _LOADED = "qt_module"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:testlib.pro:UNIX AND NOT embedded:
+# QMAKE_PKGCONFIG_DESCRIPTION = "Qt" "Unit" "Testing" "Library"
+
+extend_target(Test CONDITION QT_FEATURE_itemmodeltester
+ SOURCES
+ qabstractitemmodeltester.cpp qabstractitemmodeltester.h
+)
+
+extend_target(Test CONDITION embedded
+ COMPILE_OPTIONS
+ "-fno-rtti"
+)
+
+extend_target(Test CONDITION APPLE_OSX
+ SOURCES
+ qappletestlogger.cpp qappletestlogger_p.h
+ qtestutil_macos.mm qtestutil_macos_p.h
+ LIBRARIES
+ ${FWApplicationServices}
+ ${FWFoundation}
+ ${FWIOKit}
+ ${FWSecurity}
+)
+
+# special case: Do not bother with disabld 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) ...
+
+#### Keys ignored in scope 8:.:testlib.pro:NOT QMAKE_MAC_SDK_PLATFORM_PATH_ISEMPTY:
+# MODULE_CONFIG = "xctest"
+# platform_dev_frameworks_path = "$${QMAKE_MAC_SDK_PLATFORM_PATH}/Developer/Library/Frameworks"
+
+#### Keys ignored in scope 9:.:testlib.pro:NOT TARGET Qt::Gui:
+# HEADERSCLEAN_EXCLUDE = "qtest_gui.h" "qtestaccessible.h" "qtestkeyboard.h" "qtestmouse.h" "qtesttouch.h"
+
+#### Keys ignored in scope 10:.:testlib.pro:NOT TARGET Qt::Widgets:
+# HEADERSCLEAN_EXCLUDE = "qtest_widgets.h"
+
+#### Keys ignored in scope 11:.:testlib.pro:NOT TARGET Qt::Network:
+# HEADERSCLEAN_EXCLUDE = "qtest_network.h"
+
+add_qt_docs(./doc/qttestlib.qdocconf)
diff --git a/src/testlib/Qt5TestConfigExtras.cmake.in b/src/testlib/Qt5TestConfigExtras.cmake.in
index 2a575958ae..86a706ea9d 100644
--- a/src/testlib/Qt5TestConfigExtras.cmake.in
+++ b/src/testlib/Qt5TestConfigExtras.cmake.in
@@ -1,5 +1 @@
-
-set_property(TARGET Qt5::Test
- APPEND PROPERTY
- INTERFACE_COMPILE_DEFINITIONS QT_TESTCASE_BUILDDIR=\\\"\${CMAKE_BINARY_DIR}\\\"
-)
+set_property(TARGET @QT_CMAKE_EXPORT_NAMESPACE@::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..74d32e9dfc
--- /dev/null
+++ b/src/testlib/configure.cmake
@@ -0,0 +1,26 @@
+
+
+#### 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
+)
diff --git a/src/tools/CMakeLists.txt b/src/tools/CMakeLists.txt
new file mode 100644
index 0000000000..77942a9c7e
--- /dev/null
+++ b/src/tools/CMakeLists.txt
@@ -0,0 +1,7 @@
+add_subdirectory(uic)
+if (QT_FEATURE_dbus)
+ add_subdirectory(qdbuscpp2xml)
+ add_subdirectory(qdbusxml2cpp)
+endif()
+add_subdirectory(qlalr)
+add_subdirectory(qvkgen)
diff --git a/src/tools/bootstrap/CMakeLists.txt b/src/tools/bootstrap/CMakeLists.txt
new file mode 100644
index 0000000000..d171c1bcb5
--- /dev/null
+++ b/src/tools/bootstrap/CMakeLists.txt
@@ -0,0 +1,180 @@
+# Generated from bootstrap.pro.
+
+#####################################################################
+## Bootstrap Module:
+#####################################################################
+
+# special case:
+add_library(Bootstrap STATIC)
+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/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/kernel/qcoreapplication.cpp
+ ../../corelib/kernel/qcoreglobaldata.cpp
+ ../../corelib/kernel/qmetatype.cpp
+ ../../corelib/kernel/qsystemerror.cpp
+ ../../corelib/kernel/qvariant.cpp
+ ../../corelib/plugin/quuid.cpp
+ ../../corelib/serialization/qdatastream.cpp
+ ../../corelib/serialization/qjson.cpp
+ ../../corelib/serialization/qjsonarray.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/tools/qarraydata.cpp
+ ../../corelib/tools/qbitarray.cpp
+ ../../corelib/tools/qbytearray.cpp
+ ../../corelib/tools/qbytearraymatcher.cpp
+ ../../corelib/tools/qcommandlineoption.cpp
+ ../../corelib/tools/qcommandlineparser.cpp
+ ../../corelib/tools/qcryptographichash.cpp
+ ../../corelib/tools/qdatetime.cpp
+ ../../corelib/tools/qhash.cpp
+ ../../corelib/tools/qline.cpp
+ ../../corelib/tools/qlinkedlist.cpp
+ ../../corelib/tools/qlist.cpp
+ ../../corelib/tools/qlocale.cpp
+ ../../corelib/tools/qlocale_tools.cpp
+ ../../corelib/tools/qmap.cpp
+ ../../corelib/tools/qpoint.cpp
+ ../../corelib/tools/qrect.cpp
+ ../../corelib/tools/qregexp.cpp
+ ../../corelib/tools/qringbuffer.cpp
+ ../../corelib/tools/qsize.cpp
+ ../../corelib/tools/qstring.cpp
+ ../../corelib/tools/qstring_compat.cpp
+ ../../corelib/tools/qstringbuilder.cpp
+ ../../corelib/tools/qstringlist.cpp
+ ../../corelib/tools/qstringview.cpp
+ ../../corelib/tools/qversionnumber.cpp
+ ../../corelib/tools/qvsnprintf.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_BOOTSTRAPPED
+ QT_NO_CAST_TO_ASCII
+ QT_NO_FOREACH
+ QT_NO_CAST_FROM_ASCII
+ PUBLIC_INCLUDE_DIRECTORIES # special case
+ $<TARGET_PROPERTY:CorePrivate,INTERFACE_INCLUDE_DIRECTORIES>
+ $<TARGET_PROPERTY:XmlPrivate,INTERFACE_INCLUDE_DIRECTORIES>
+ PUBLIC_LIBRARIES # special case
+ ZLIB::ZLIB
+ Qt::Platform
+)
+
+#### Keys ignored in scope 1:.:.:bootstrap.pro:<TRUE>:
+# CONFIG = "minimal_syncqt" "internal_module" "force_bootstrap" "gc_binaries"
+# INSTALLS = "lib"
+# MODULE_CONFIG = "gc_binaries"
+# MODULE_INCNAME = "QtCore" "QtXml"
+# _LOADED = "qt_module"
+# _OPTION = "host_build"
+# lib.CONFIG = "dummy_install"
+
+## Scopes:
+#####################################################################
+
+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
+)
+
+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/plugin/qsystemlibrary.cpp
+ PUBLIC_LIBRARIES
+ advapi32
+ netapi32
+ ole32
+ shell32
+ user32
+)
+
+extend_target(Bootstrap CONDITION APPLE_OSX
+ SOURCES
+ ../../corelib/global/qoperatingsystemversion_darwin.mm
+ ../../corelib/io/qstandardpaths_mac.mm
+ ../../corelib/kernel/qcore_foundation.mm
+ ../../corelib/kernel/qcore_mac.cpp
+ ../../corelib/kernel/qcore_mac_objc.mm
+ ../../corelib/kernel/qcoreapplication_mac.cpp
+ LIBRARIES
+ ${FWCoreServices}
+ PUBLIC_LIBRARIES
+ ${FWFoundation}
+)
+
+extend_target(Bootstrap CONDITION APPLE_OSX AND APPLE_UIKIT
+ LIBRARIES
+ ${FWUIKit}
+)
+
+extend_target(Bootstrap CONDITION UNIX AND NOT APPLE_OSX
+ SOURCES
+ ../../corelib/io/qstandardpaths_unix.cpp
+)
+
+# special case: This will never get cross_compiled!
+# extend_target(Bootstrap CONDITION cross_compile [...])
+# extend_target(Bootstrap CONDITION NOT cross_compile [...])
+
+#### Keys ignored in scope 12:.:.:bootstrap.pro:else:
+# CONFIG = "no_core_dep"
+
+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/moc/CMakeLists.txt b/src/tools/moc/CMakeLists.txt
new file mode 100644
index 0000000000..470baa7127
--- /dev/null
+++ b/src/tools/moc/CMakeLists.txt
@@ -0,0 +1,32 @@
+# Generated from moc.pro.
+
+#####################################################################
+## moc Tool:
+#####################################################################
+
+add_qt_tool(moc
+ BOOTSTRAP
+ SOURCES
+ cbordevice.h
+ generator.cpp generator.h
+ main.cpp # special case
+ moc.cpp moc.h
+ outputrevision.h
+ parser.cpp parser.h
+ preprocessor.cpp preprocessor.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
+ LIBRARIES
+ tinycbor
+ # CONFIG = "force_bootstrap"
+ # QMAKE_TARGET_DESCRIPTION = "Qt Meta Object Compiler"
+ # _LOADED = "qt_tool"
+ # _OPTION = "host_build"
+)
diff --git a/src/tools/qdbuscpp2xml/CMakeLists.txt b/src/tools/qdbuscpp2xml/CMakeLists.txt
new file mode 100644
index 0000000000..5e2937aa05
--- /dev/null
+++ b/src/tools/qdbuscpp2xml/CMakeLists.txt
@@ -0,0 +1,40 @@
+# Generated from qdbuscpp2xml.pro.
+
+#####################################################################
+## qdbuscpp2xml Tool:
+#####################################################################
+
+add_qt_tool(qdbuscpp2xml
+ SOURCES
+ ../moc/cbordevice.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 # special case
+ DEFINES
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ ../moc
+ LIBRARIES
+ tinycbor # special case
+ 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"
+)
+
+## Scopes:
+#####################################################################
+
+# special case:
+# extend_target(qdbuscpp2xml CONDITION force_bootstrap [...])
+# extend_target(qdbuscpp2xml CONDITION NOT force_bootstrap [...])
diff --git a/src/tools/qdbusxml2cpp/CMakeLists.txt b/src/tools/qdbusxml2cpp/CMakeLists.txt
new file mode 100644
index 0000000000..e9a72a3d45
--- /dev/null
+++ b/src/tools/qdbusxml2cpp/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from qdbusxml2cpp.pro.
+
+#####################################################################
+## qdbusxml2cpp Tool:
+#####################################################################
+
+add_qt_tool(qdbusxml2cpp
+ 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"
+)
+
+## Scopes:
+#####################################################################
+
+# special case:
+# 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 [...])
diff --git a/src/tools/qfloat16-tables/CMakeLists.txt b/src/tools/qfloat16-tables/CMakeLists.txt
new file mode 100644
index 0000000000..f437ccc8db
--- /dev/null
+++ b/src/tools/qfloat16-tables/CMakeLists.txt
@@ -0,0 +1,16 @@
+# Generated from qfloat16-tables.pro.
+
+#####################################################################
+## qfloat16-tables Tool:
+#####################################################################
+
+add_qt_tool(qfloat16-tables
+ BOOTSTRAP
+ SOURCES
+ gen_qfloat16_tables.cpp
+ # CONFIG = "force_bootstrap"
+ # INSTALLS = "lib"
+ # _LOADED = "qt_tool"
+ # _OPTION = "host_build"
+ # lib.CONFIG = "dummy_install"
+)
diff --git a/src/tools/qlalr/CMakeLists.txt b/src/tools/qlalr/CMakeLists.txt
new file mode 100644
index 0000000000..83d067751f
--- /dev/null
+++ b/src/tools/qlalr/CMakeLists.txt
@@ -0,0 +1,23 @@
+# Generated from qlalr.pro.
+
+#####################################################################
+## qlalr Tool:
+#####################################################################
+
+add_qt_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
+ # OTHER_FILES = "lalr.g"
+ # QMAKE_TARGET_DESCRIPTION = "Qt Look Ahead LR Parser Generator"
+ # _LOADED = "qt_tool"
+ # _OPTION = "host_build"
+)
diff --git a/src/tools/qvkgen/CMakeLists.txt b/src/tools/qvkgen/CMakeLists.txt
new file mode 100644
index 0000000000..ea9dbeeed7
--- /dev/null
+++ b/src/tools/qvkgen/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qvkgen.pro.
+
+#####################################################################
+## qvkgen Tool:
+#####################################################################
+
+add_qt_tool(qvkgen
+ SOURCES
+ qvkgen.cpp
+ # QMAKE_TARGET_DESCRIPTION = "Qt Vulkan Header Generator"
+ # _LOADED = "qt_tool"
+ # _OPTION = "host_build"
+)
diff --git a/src/tools/rcc/CMakeLists.txt b/src/tools/rcc/CMakeLists.txt
new file mode 100644
index 0000000000..12fd0690a7
--- /dev/null
+++ b/src/tools/rcc/CMakeLists.txt
@@ -0,0 +1,22 @@
+# Generated from rcc.pro.
+
+#####################################################################
+## rcc Tool:
+#####################################################################
+
+add_qt_tool(rcc
+ BOOTSTRAP
+ SOURCES
+ main.cpp
+ rcc.cpp rcc.h
+ DEFINES
+ QT_RCC
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}
+ # CONFIG = "force_bootstrap"
+ # QMAKE_TARGET_DESCRIPTION = "Qt Resource Compiler"
+ # _LOADED = "qt_tool"
+ # _OPTION = "host_build"
+)
diff --git a/src/tools/tracegen/CMakeLists.txt b/src/tools/tracegen/CMakeLists.txt
new file mode 100644
index 0000000000..df98910626
--- /dev/null
+++ b/src/tools/tracegen/CMakeLists.txt
@@ -0,0 +1,21 @@
+# Generated from tracegen.pro.
+
+#####################################################################
+## tracegen Tool:
+#####################################################################
+
+add_qt_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>:
+# _LOADED = "qt_tool"
+# _OPTION = "host_build"
diff --git a/src/tools/tracegen/provider.h b/src/tools/tracegen/provider.h
index 9be0c33d89..a4baf56815 100644
--- a/src/tools/tracegen/provider.h
+++ b/src/tools/tracegen/provider.h
@@ -42,6 +42,7 @@
#include <qvector.h>
#include <qstring.h>
+#include <qstringlist.h>
#include <qtypeinfo.h>
struct Tracepoint
diff --git a/src/tools/uic/CMakeLists.txt b/src/tools/uic/CMakeLists.txt
new file mode 100644
index 0000000000..05de0a71ba
--- /dev/null
+++ b/src/tools/uic/CMakeLists.txt
@@ -0,0 +1,49 @@
+# Generated from uic.pro.
+
+#####################################################################
+## uic Tool:
+#####################################################################
+
+add_qt_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_UIC
+ QT_NO_CAST_FROM_ASCII
+ QT_NO_FOREACH
+ QT_UIC_CPP_GENERATOR # special case
+ INCLUDE_DIRECTORIES
+ # . # special case: remove
+ shared
+ cpp
+ # ${CMAKE_CURRENT_BINARY_DIR} # special case: remove
+ python
+ DISABLE_AUTOGEN_TOOLS # special case:
+ uic rcc
+)
+
+#### Keys ignored in scope 1:.:.:uic.pro:<TRUE>:
+# QMAKE_TARGET_DESCRIPTION = "Qt User Interface Compiler"
+# _LOADED = "qt_tool"
+# _OPTION = "host_build"
+
+## Scopes:
+#####################################################################
+
+#### Keys ignored in scope 2:.:.:uic.pro:NOT force_bootstrap AND NOT qtConfig(commandlineparser OR NOT QT_FEATURE_textcodec OR NOT QT_FEATURE_xmlstreamreader OR NOT QT_FEATURE_xmlstreamwriter:
+# CONFIG = "force_bootstrap"
diff --git a/src/widgets/CMakeLists.txt b/src/widgets/CMakeLists.txt
new file mode 100644
index 0000000000..a92da0f32e
--- /dev/null
+++ b/src/widgets/CMakeLists.txt
@@ -0,0 +1,792 @@
+# Generated from widgets.pro.
+
+#####################################################################
+## Widgets Module:
+#####################################################################
+
+add_qt_module(Widgets
+ SOURCES
+ itemviews/qfileiconprovider.cpp itemviews/qfileiconprovider.h itemviews/qfileiconprovider_p.h
+ kernel/qaction.cpp kernel/qaction.h kernel/qaction_p.h
+ kernel/qactiongroup.cpp kernel/qactiongroup.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/qshortcut.cpp kernel/qshortcut.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/qtooltip.cpp kernel/qtooltip.h
+ kernel/qtwidgetsglobal.h kernel/qtwidgetsglobal_p.h
+ kernel/qwidget.cpp kernel/qwidget.h kernel/qwidget_p.h
+ kernel/qwidgetaction.cpp kernel/qwidgetaction.h kernel/qwidgetaction_p.h
+ kernel/qwidgetbackingstore.cpp kernel/qwidgetbackingstore_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/qstyleanimation.cpp styles/qstyleanimation_p.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 # special case
+ Qt::Core
+ Qt::Gui
+ # CONFIG = "$$MODULE_CONFIG" "qt_tracepoints"
+ # KERNEL_P = "kernel"
+ # MODULE_CONFIG = "uic"
+ # MODULE_PLUGIN_TYPES = "styles"
+ # PRECOMPILED_HEADER = "kernel/qt_widgets_pch.h"
+ # QMAKE_DYNAMIC_LIST_FILE = "$$PWD/QtWidgets.dynlist"
+ # QMAKE_LIBS = "$$QMAKE_LIBS_GUI"
+ # TRACEPOINT_PROVIDER = "$$PWD/qtwidgets.tracepoints"
+ # _LOADED = "qt_module"
+)
+
+add_dependencies(Widgets Qt::uic) # special case
+
+# Resources:
+add_qt_resource(Widgets "qstyle" PREFIX "/qt-project.org/styles/commonstyle" BASE "styles" 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)
+set_source_files_properties("styles/images/closedock-down-macstyle-16.png"
+ PROPERTIES alias "images/closedock-down-16.png")
+set_source_files_properties("styles/images/closedock-macstyle-16.png"
+ PROPERTIES alias "images/closedock-16.png")
+set_source_files_properties("styles/images/dockdock-down-macstyle-16.png"
+ PROPERTIES alias "images/dockdock-down-16.png")
+set_source_files_properties("styles/images/dockdock-macstyle-16.png"
+ PROPERTIES alias "images/dockdock-16.png")
+set_source_files_properties("styles/images/toolbar-ext-macstyle.png"
+ PROPERTIES alias "images/toolbar-ext.png")
+set_source_files_properties("styles/images/toolbar-ext-macstyle@2x.png"
+ PROPERTIES alias "images/toolbar-ext@2x.png")
+add_qt_resource(Widgets "qstyle1" PREFIX "/qt-project.org/styles/macstyle" BASE "styles" 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)
+
+
+## Scopes:
+#####################################################################
+
+extend_target(Widgets CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x65000000"
+)
+
+extend_target(Widgets CONDITION APPLE_OSX
+ SOURCES
+ kernel/qmacgesturerecognizer.cpp kernel/qmacgesturerecognizer_p.h
+ util/qscroller_mac.mm
+ widgets/qmaccocoaviewcontainer_mac.h widgets/qmaccocoaviewcontainer_mac.mm
+ widgets/qmacnativewidget_mac.h widgets/qmacnativewidget_mac.mm
+ LIBRARIES
+ ${FWAppKit}
+ z
+)
+
+# extend_target(Widgets CONDITION ((APPLE_OSX) AND (APPLE_OSX)) AND (_x_-mwerks) # special case
+
+extend_target(Widgets CONDITION WIN32
+ INCLUDE_DIRECTORIES
+ ../3rdparty/wintab
+)
+
+extend_target(Widgets CONDITION WIN32 AND NOT WINRT
+ LIBRARIES
+ shell32
+ uxtheme
+ dwmapi
+)
+
+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
+)
+#
+#extend_target(Widgets CONDITION testcocoon
+# # _LOADED = "testcocoon"
+#)
+
+extend_target(Widgets CONDITION QT_FEATURE_opengl
+ SOURCES
+ kernel/qopenglwidget.cpp kernel/qopenglwidget.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_formlayout
+ SOURCES
+ kernel/qformlayout.cpp kernel/qformlayout.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_whatsthis
+ SOURCES
+ kernel/qwhatsthis.cpp kernel/qwhatsthis.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_style_windows
+ SOURCES
+ styles/qwindowsstyle.cpp styles/qwindowsstyle_p.h
+ styles/qwindowsstyle_p_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_style_fusion
+ SOURCES
+ styles/qfusionstyle.cpp styles/qfusionstyle_p.h
+ styles/qfusionstyle_p_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_abstractbutton
+ SOURCES
+ widgets/qabstractbutton.cpp widgets/qabstractbutton.h widgets/qabstractbutton_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_abstractslider
+ SOURCES
+ widgets/qabstractslider.cpp widgets/qabstractslider.h widgets/qabstractslider_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_buttongroup
+ SOURCES
+ widgets/qbuttongroup.cpp widgets/qbuttongroup.h widgets/qbuttongroup_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_calendarwidget
+ SOURCES
+ widgets/qcalendarwidget.cpp widgets/qcalendarwidget.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_checkbox
+ SOURCES
+ widgets/qcheckbox.cpp widgets/qcheckbox.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_combobox
+ SOURCES
+ widgets/qcombobox.cpp widgets/qcombobox.h widgets/qcombobox_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_commandlinkbutton
+ SOURCES
+ widgets/qcommandlinkbutton.cpp widgets/qcommandlinkbutton.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_datetimeedit
+ SOURCES
+ widgets/qdatetimeedit.cpp widgets/qdatetimeedit.h widgets/qdatetimeedit_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_dial
+ SOURCES
+ widgets/qdial.cpp widgets/qdial.h
+)
+
+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
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_effects
+ SOURCES
+ widgets/qeffects.cpp widgets/qeffects_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_fontcombobox
+ SOURCES
+ widgets/qfontcombobox.cpp widgets/qfontcombobox.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_groupbox
+ SOURCES
+ widgets/qgroupbox.cpp widgets/qgroupbox.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_keysequenceedit
+ SOURCES
+ widgets/qkeysequenceedit.cpp widgets/qkeysequenceedit.h widgets/qkeysequenceedit_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_label
+ SOURCES
+ widgets/qlabel.cpp widgets/qlabel.h widgets/qlabel_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_lcdnumber
+ SOURCES
+ widgets/qlcdnumber.cpp widgets/qlcdnumber.h
+)
+
+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
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_mainwindow
+ SOURCES
+ widgets/qmainwindow.cpp widgets/qmainwindow.h
+ widgets/qmainwindowlayout.cpp widgets/qmainwindowlayout_p.h
+)
+
+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
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_menu
+ SOURCES
+ widgets/qmenu.cpp widgets/qmenu.h widgets/qmenu_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_menubar
+ SOURCES
+ widgets/qmenubar.cpp widgets/qmenubar.h widgets/qmenubar_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_progressbar
+ SOURCES
+ widgets/qprogressbar.cpp widgets/qprogressbar.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_pushbutton
+ SOURCES
+ widgets/qpushbutton.cpp widgets/qpushbutton.h widgets/qpushbutton_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_radiobutton
+ SOURCES
+ widgets/qradiobutton.cpp widgets/qradiobutton.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_resizehandler
+ SOURCES
+ widgets/qwidgetresizehandler.cpp widgets/qwidgetresizehandler_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_dialogbuttonbox
+ SOURCES
+ widgets/qdialogbuttonbox.cpp widgets/qdialogbuttonbox.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_rubberband
+ SOURCES
+ widgets/qrubberband.cpp widgets/qrubberband.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_scrollarea
+ SOURCES
+ widgets/qscrollarea.cpp widgets/qscrollarea.h widgets/qscrollarea_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_scrollbar
+ SOURCES
+ widgets/qscrollbar.cpp widgets/qscrollbar.h widgets/qscrollbar_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_sizegrip
+ SOURCES
+ widgets/qsizegrip.cpp widgets/qsizegrip.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_slider
+ SOURCES
+ widgets/qslider.cpp widgets/qslider.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_spinbox
+ SOURCES
+ widgets/qabstractspinbox.cpp widgets/qabstractspinbox.h widgets/qabstractspinbox_p.h
+ widgets/qspinbox.cpp widgets/qspinbox.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_splashscreen
+ SOURCES
+ widgets/qsplashscreen.cpp widgets/qsplashscreen.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_splitter
+ SOURCES
+ widgets/qsplitter.cpp widgets/qsplitter.h widgets/qsplitter_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_stackedwidget
+ SOURCES
+ widgets/qstackedwidget.cpp widgets/qstackedwidget.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_statusbar
+ SOURCES
+ widgets/qstatusbar.cpp widgets/qstatusbar.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_tabbar
+ SOURCES
+ widgets/qtabbar.cpp widgets/qtabbar.h widgets/qtabbar_p.h
+)
+
+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
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_textbrowser
+ SOURCES
+ widgets/qtextbrowser.cpp widgets/qtextbrowser.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_tabwidget
+ SOURCES
+ widgets/qtabwidget.cpp widgets/qtabwidget.h
+)
+
+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
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_toolbox
+ SOURCES
+ widgets/qtoolbox.cpp widgets/qtoolbox.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_toolbutton
+ SOURCES
+ widgets/qtoolbarextension.cpp widgets/qtoolbarextension_p.h
+ widgets/qtoolbutton.cpp widgets/qtoolbutton.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_widgettextcontrol
+ SOURCES
+ widgets/qwidgettextcontrol.cpp widgets/qwidgettextcontrol_p.h
+ widgets/qwidgettextcontrol_p_p.h
+)
+
+extend_target(Widgets CONDITION APPLE_OSX AND (QT_FEATURE_menu OR QT_FEATURE_menubar)
+ SOURCES
+ widgets/qmenu_mac.mm
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_colordialog
+ SOURCES
+ dialogs/qcolordialog.cpp dialogs/qcolordialog.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_dialog
+ SOURCES
+ dialogs/qdialog.cpp dialogs/qdialog.h dialogs/qdialog_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_errormessage
+ SOURCES
+ dialogs/qerrormessage.cpp dialogs/qerrormessage.h
+)
+
+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
+)
+
+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
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_fontdialog
+ SOURCES
+ dialogs/qfontdialog.cpp dialogs/qfontdialog.h dialogs/qfontdialog_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_fscompleter
+ SOURCES
+ dialogs/qfscompleter_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_inputdialog
+ SOURCES
+ dialogs/qinputdialog.cpp dialogs/qinputdialog.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_messagebox
+ SOURCES
+ dialogs/qmessagebox.cpp dialogs/qmessagebox.h
+)
+
+# Resources:
+add_qt_resource(Widgets "qmessagebox" PREFIX "/qt-project.org/qmessagebox" BASE "dialogs" FILES
+ images/qtlogo-64.png)
+
+
+extend_target(Widgets CONDITION QT_FEATURE_progressdialog
+ SOURCES
+ dialogs/qprogressdialog.cpp dialogs/qprogressdialog.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_wizard
+ SOURCES
+ dialogs/qwizard.cpp dialogs/qwizard.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_wizard AND WIN32
+ SOURCES
+ dialogs/qwizard_win.cpp dialogs/qwizard_win_p.h
+)
+
+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
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_accessibility AND QT_FEATURE_itemviews
+ SOURCES
+ accessible/itemviews.cpp accessible/itemviews_p.h
+)
+
+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
+)
+
+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
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_datawidgetmapper
+ SOURCES
+ itemviews/qdatawidgetmapper.cpp itemviews/qdatawidgetmapper.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_dirmodel
+ SOURCES
+ itemviews/qdirmodel.cpp itemviews/qdirmodel.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_listview
+ SOURCES
+ itemviews/qlistview.cpp itemviews/qlistview.h itemviews/qlistview_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_listwidget
+ SOURCES
+ itemviews/qlistwidget.cpp itemviews/qlistwidget.h itemviews/qlistwidget_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_tableview
+ SOURCES
+ itemviews/qtableview.cpp itemviews/qtableview.h itemviews/qtableview_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_tablewidget
+ SOURCES
+ itemviews/qtablewidget.cpp itemviews/qtablewidget.h itemviews/qtablewidget_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_treeview
+ SOURCES
+ itemviews/qtreeview.cpp itemviews/qtreeview.h itemviews/qtreeview_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_treewidget
+ SOURCES
+ itemviews/qtreewidget.cpp itemviews/qtreewidget.h itemviews/qtreewidget_p.h
+ itemviews/qtreewidgetitemiterator.cpp itemviews/qtreewidgetitemiterator.h
+)
+
+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/qgraphicsitemanimation.cpp graphicsview/qgraphicsitemanimation.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
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_completer
+ SOURCES
+ util/qcompleter.cpp util/qcompleter.h util/qcompleter_p.h
+)
+
+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
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_undocommand
+ SOURCES
+ util/qundostack.cpp util/qundostack.h util/qundostack_p.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_undogroup
+ SOURCES
+ util/qundogroup.cpp util/qundogroup.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_undoview
+ SOURCES
+ util/qundoview.cpp util/qundoview.h
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_xcb
+ SOURCES
+ util/qsystemtrayicon_x11.cpp
+)
+
+extend_target(Widgets CONDITION NOT QT_FEATURE_xcb
+ SOURCES
+ util/qsystemtrayicon_qpa.cpp
+)
+
+extend_target(Widgets CONDITION QT_FEATURE_statemachine
+ SOURCES
+ statemachine/qguistatemachine.cpp
+)
+
+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)
+
+add_qt_docs(./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/Qt5WidgetsMacros.cmake
index 737371a5ad..864efae868 100644
--- a/src/widgets/Qt5WidgetsMacros.cmake
+++ b/src/widgets/Qt5WidgetsMacros.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..fead6b60b5
--- /dev/null
+++ b/src/widgets/configure.cmake
@@ -0,0 +1,569 @@
+
+
+#### Inputs
+
+
+
+#### Libraries
+
+find_package(GTK3)
+set_package_properties(GTK3 PROPERTIES TYPE OPTIONAL)
+
+
+#### 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."
+)
+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("paint_debug" PUBLIC
+ SECTION "Painting"
+ LABEL "Painting Debug Utilities"
+ PURPOSE "Enabled debugging painting with the environment variables QT_FLUSH_UPDATE and QT_FLUSH_PAINT."
+)
+qt_feature_definition("paint_debug" "QT_NO_PAINT_DEBUG" 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/xml/CMakeLists.txt b/src/xml/CMakeLists.txt
new file mode 100644
index 0000000000..7ce740476c
--- /dev/null
+++ b/src/xml/CMakeLists.txt
@@ -0,0 +1,29 @@
+# Generated from xml.pro.
+
+#####################################################################
+## Xml Module:
+#####################################################################
+
+add_qt_module(Xml
+ SOURCES
+ dom/qdom.cpp dom/qdom.h
+ qtxmlglobal.h
+ sax/qxml.cpp sax/qxml.h sax/qxml_p.h
+ DEFINES
+ QT_NO_USING_NAMESPACE
+ QT_NO_FOREACH
+ LIBRARIES
+ Qt::CorePrivate
+ # PRECOMPILED_HEADER = <EMPTY>
+ # _LOADED = "qt_module"
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(Xml CONDITION MSVC AND (TEST_architecture_arch STREQUAL "i386")
+ LINK_OPTIONS
+ "/BASE:0x61000000"
+)
+
+add_qt_docs(./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/CMakeLists.txt b/tests/CMakeLists.txt
new file mode 100644
index 0000000000..0653827192
--- /dev/null
+++ b/tests/CMakeLists.txt
@@ -0,0 +1 @@
+add_subdirectory(auto)
diff --git a/tests/auto/CMakeLists.txt b/tests/auto/CMakeLists.txt
new file mode 100644
index 0000000000..e1c4a4dc59
--- /dev/null
+++ b/tests/auto/CMakeLists.txt
@@ -0,0 +1,55 @@
+# Generated from auto.pro.
+
+if (NOT APPLE_UIKIT)
+ add_subdirectory(corelib)
+endif()
+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 (NOT APPLE_UIKIT AND TARGET Qt::Gui)
+ add_subdirectory(gui)
+endif()
+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/CMakeLists.txt b/tests/auto/concurrent/qtconcurrentfilter/CMakeLists.txt
new file mode 100644
index 0000000000..e4e6884728
--- /dev/null
+++ b/tests/auto/concurrent/qtconcurrentfilter/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qtconcurrentfilter.pro.
+
+#####################################################################
+## tst_qtconcurrentfilter Test:
+#####################################################################
+
+add_qt_test(tst_qtconcurrentfilter
+ SOURCES
+ tst_qtconcurrentfilter.cpp
+ DEFINES
+ QT_STRICT_ITERATORS
+ 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..ae3e950af8
--- /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
+ LIBRARIES
+ Qt::Concurrent
+)
diff --git a/tests/auto/concurrent/qtconcurrentmap/CMakeLists.txt b/tests/auto/concurrent/qtconcurrentmap/CMakeLists.txt
new file mode 100644
index 0000000000..2158aa7d75
--- /dev/null
+++ b/tests/auto/concurrent/qtconcurrentmap/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qtconcurrentmap.pro.
+
+#####################################################################
+## tst_qtconcurrentmap Test:
+#####################################################################
+
+add_qt_test(tst_qtconcurrentmap
+ SOURCES
+ tst_qtconcurrentmap.cpp
+ DEFINES
+ QT_STRICT_ITERATORS
+ LIBRARIES
+ Qt::Concurrent
+)
+
+## Scopes:
+#####################################################################
+#
+#extend_target(tst_qtconcurrentmap CONDITION contains(QT_CONFIG, c++1z)
+#)
diff --git a/tests/auto/concurrent/qtconcurrentmedian/CMakeLists.txt b/tests/auto/concurrent/qtconcurrentmedian/CMakeLists.txt
new file mode 100644
index 0000000000..6e49501d01
--- /dev/null
+++ b/tests/auto/concurrent/qtconcurrentmedian/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qtconcurrentmedian.pro.
+
+#####################################################################
+## tst_qtconcurrentmedian Test:
+#####################################################################
+
+add_qt_test(tst_qtconcurrentmedian
+ SOURCES
+ tst_qtconcurrentmedian.cpp
+ DEFINES
+ QT_STRICT_ITERATORS
+ 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..d3ce0d5e4d
--- /dev/null
+++ b/tests/auto/concurrent/qtconcurrentrun/CMakeLists.txt
@@ -0,0 +1,18 @@
+# Generated from qtconcurrentrun.pro.
+
+#####################################################################
+## tst_qtconcurrentrun Test:
+#####################################################################
+
+add_qt_test(tst_qtconcurrentrun
+ SOURCES
+ tst_qtconcurrentrun.cpp
+ LIBRARIES
+ Qt::Concurrent
+)
+
+## Scopes:
+#####################################################################
+#
+#extend_target(tst_qtconcurrentrun CONDITION contains(QT_CONFIG, c++1z)
+#)
diff --git a/tests/auto/concurrent/qtconcurrentthreadengine/CMakeLists.txt b/tests/auto/concurrent/qtconcurrentthreadengine/CMakeLists.txt
new file mode 100644
index 0000000000..7833f6b7f4
--- /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
+ LIBRARIES
+ Qt::Concurrent
+)
diff --git a/tests/auto/corelib/CMakeLists.txt b/tests/auto/corelib/CMakeLists.txt
new file mode 100644
index 0000000000..1625488909
--- /dev/null
+++ b/tests/auto/corelib/CMakeLists.txt
@@ -0,0 +1,12 @@
+add_subdirectory(animation)
+add_subdirectory(codecs)
+add_subdirectory(global)
+add_subdirectory(io)
+add_subdirectory(itemmodels)
+add_subdirectory(kernel)
+add_subdirectory(mimetypes)
+add_subdirectory(serialization)
+add_subdirectory(statemachine)
+add_subdirectory(thread)
+add_subdirectory(tools)
+
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..5a9bb29f18
--- /dev/null
+++ b/tests/auto/corelib/animation/qabstractanimation/CMakeLists.txt
@@ -0,0 +1 @@
+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..82f50b8f75
--- /dev/null
+++ b/tests/auto/corelib/animation/qanimationgroup/CMakeLists.txt
@@ -0,0 +1 @@
+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..798e49b0c0
--- /dev/null
+++ b/tests/auto/corelib/animation/qparallelanimationgroup/CMakeLists.txt
@@ -0,0 +1 @@
+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..a960722b87
--- /dev/null
+++ b/tests/auto/corelib/animation/qpauseanimation/CMakeLists.txt
@@ -0,0 +1 @@
+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..da5d3cfe6a
--- /dev/null
+++ b/tests/auto/corelib/animation/qsequentialanimationgroup/CMakeLists.txt
@@ -0,0 +1 @@
+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..de548e07ff
--- /dev/null
+++ b/tests/auto/corelib/animation/qvariantanimation/CMakeLists.txt
@@ -0,0 +1 @@
+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..bfc7d39b5e
--- /dev/null
+++ b/tests/auto/corelib/codecs/qtextcodec/echo/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test_helper(echo_helper SOURCES main.cpp LIBRARIES Qt::Core)
diff --git a/tests/auto/corelib/codecs/utf8/CMakeLists.txt b/tests/auto/corelib/codecs/utf8/CMakeLists.txt
new file mode 100644
index 0000000000..69825823f4
--- /dev/null
+++ b/tests/auto/corelib/codecs/utf8/CMakeLists.txt
@@ -0,0 +1 @@
+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..a8384a17a7
--- /dev/null
+++ b/tests/auto/corelib/global/q_func_info/CMakeLists.txt
@@ -0,0 +1 @@
+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..c464dd0aab
--- /dev/null
+++ b/tests/auto/corelib/global/qflags/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qflags SOURCES tst_qflags.cpp)
diff --git a/tests/auto/corelib/global/qfloat16/CMakeLists.txt b/tests/auto/corelib/global/qfloat16/CMakeLists.txt
new file mode 100644
index 0000000000..272215216d
--- /dev/null
+++ b/tests/auto/corelib/global/qfloat16/CMakeLists.txt
@@ -0,0 +1 @@
+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..390263691b
--- /dev/null
+++ b/tests/auto/corelib/global/qgetputenv/CMakeLists.txt
@@ -0,0 +1 @@
+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..129a35157a
--- /dev/null
+++ b/tests/auto/corelib/global/qglobal/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qglobal SOURCES tst_qglobal.cpp qglobal.c)
diff --git a/tests/auto/corelib/global/qglobalstatic/CMakeLists.txt b/tests/auto/corelib/global/qglobalstatic/CMakeLists.txt
new file mode 100644
index 0000000000..3aa4511d6f
--- /dev/null
+++ b/tests/auto/corelib/global/qglobalstatic/CMakeLists.txt
@@ -0,0 +1,8 @@
+add_qt_test(tst_qglobalstatic
+ 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..2412253060
--- /dev/null
+++ b/tests/auto/corelib/global/qhooks/CMakeLists.txt
@@ -0,0 +1 @@
+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..05b5bdb63b
--- /dev/null
+++ b/tests/auto/corelib/global/qlogging/CMakeLists.txt
@@ -0,0 +1,10 @@
+if(NOT WINRT)
+ add_qt_test_helper(qlogging_helper SOURCES app/main.cpp DEFINES QT_MESSAGELOGCONTEXT LIBRARIES Qt::Core)
+endif()
+
+add_qt_test(tst_qlogging SOURCES tst_qlogging.cpp
+ DEFINES
+ QT_MESSAGELOGCONTEXT
+ QT_DISABLE_DEPRECATED_BEFORE=0
+ HELPER_BINARY="qlogging_helper"
+)
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 f212fe6f27..d10d879130 100644
--- a/tests/auto/corelib/global/qlogging/tst_qlogging.cpp
+++ b/tests/auto/corelib/global/qlogging/tst_qlogging.cpp
@@ -814,7 +814,7 @@ 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"));
#endif
@@ -864,7 +864,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..ebd05c1489
--- /dev/null
+++ b/tests/auto/corelib/global/qnumeric/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qnumeric SOURCES tst_qnumeric.cpp LIBRARIES Qt::CorePrivate)
diff --git a/tests/auto/corelib/global/qrand/CMakeLists.txt b/tests/auto/corelib/global/qrand/CMakeLists.txt
new file mode 100644
index 0000000000..4fccf1b0da
--- /dev/null
+++ b/tests/auto/corelib/global/qrand/CMakeLists.txt
@@ -0,0 +1 @@
+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..e742537bf8
--- /dev/null
+++ b/tests/auto/corelib/global/qrandomgenerator/CMakeLists.txt
@@ -0,0 +1 @@
+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..91b5c13162
--- /dev/null
+++ b/tests/auto/corelib/global/qtendian/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qtendian SOURCES tst_qtendian.cpp LIBRARIES Qt::CorePrivate)
diff --git a/tests/auto/corelib/io/CMakeLists.txt b/tests/auto/corelib/io/CMakeLists.txt
new file mode 100644
index 0000000000..e1b4f931cd
--- /dev/null
+++ b/tests/auto/corelib/io/CMakeLists.txt
@@ -0,0 +1,14 @@
+add_subdirectory(largefile)
+add_subdirectory(qbuffer)
+add_subdirectory(qdataurl)
+if(QT_FEATURE_private_tests)
+ add_subdirectory(qfilesystementry)
+endif()
+add_subdirectory(qfilesystemwatcher)
+add_subdirectory(qipaddress)
+# add_subdirectory(qloggingcategory)
+add_subdirectory(qnodebug)
+add_subdirectory(qprocessenvironment)
+add_subdirectory(qstorageinfo)
+add_subdirectory(qurlquery)
+
diff --git a/tests/auto/corelib/io/largefile/CMakeLists.txt b/tests/auto/corelib/io/largefile/CMakeLists.txt
new file mode 100644
index 0000000000..d85cfd73b4
--- /dev/null
+++ b/tests/auto/corelib/io/largefile/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test(tst_largefile SOURCES
+ tst_largefile.cpp
+ ../../../../shared/emulationdetector.h
+ INCLUDE_DIRECTORIES
+ ../../../../shared/
+)
diff --git a/tests/auto/corelib/io/qbuffer/CMakeLists.txt b/tests/auto/corelib/io/qbuffer/CMakeLists.txt
new file mode 100644
index 0000000000..3ed9738217
--- /dev/null
+++ b/tests/auto/corelib/io/qbuffer/CMakeLists.txt
@@ -0,0 +1 @@
+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..d24b18dfc9
--- /dev/null
+++ b/tests/auto/corelib/io/qdataurl/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qdataurl SOURCES tst_qdataurl.cpp LIBRARIES Qt::CorePrivate)
diff --git a/tests/auto/corelib/io/qfilesystementry/CMakeLists.txt b/tests/auto/corelib/io/qfilesystementry/CMakeLists.txt
new file mode 100644
index 0000000000..58c859dc2e
--- /dev/null
+++ b/tests/auto/corelib/io/qfilesystementry/CMakeLists.txt
@@ -0,0 +1,7 @@
+add_qt_test(tst_qfilesystementry SOURCES
+ tst_qfilesystementry.cpp
+ ${PROJECT_SOURCE_DIR}/src/corelib/io/qfilesystementry.cpp
+ ${PROJECT_SOURCE_DIR}/src/corelib/io/qfilesystementry_p.h
+ 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..978f87acab
--- /dev/null
+++ b/tests/auto/corelib/io/qfilesystemwatcher/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qfilesystemwatcher SOURCES tst_qfilesystemwatcher.cpp)
diff --git a/tests/auto/corelib/io/qipaddress/CMakeLists.txt b/tests/auto/corelib/io/qipaddress/CMakeLists.txt
new file mode 100644
index 0000000000..c60bae1c21
--- /dev/null
+++ b/tests/auto/corelib/io/qipaddress/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qipaddress SOURCES tst_qipaddress.cpp LIBRARIES Qt::CorePrivate)
diff --git a/tests/auto/corelib/io/qloggingcategory/CMakeLists.txt b/tests/auto/corelib/io/qloggingcategory/CMakeLists.txt
new file mode 100644
index 0000000000..00b807eeba
--- /dev/null
+++ b/tests/auto/corelib/io/qloggingcategory/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qloggingcategory SOURCES tst_qloggingcategory.cpp LIBRARIES Qt::CorePrivate)
diff --git a/tests/auto/corelib/io/qnodebug/CMakeLists.txt b/tests/auto/corelib/io/qnodebug/CMakeLists.txt
new file mode 100644
index 0000000000..15e46596f4
--- /dev/null
+++ b/tests/auto/corelib/io/qnodebug/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qnodebug SOURCES tst_qnodebug.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..68c6a9936f
--- /dev/null
+++ b/tests/auto/corelib/io/qprocessenvironment/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qprocessenvironment SOURCES tst_qprocessenvironment.cpp)
diff --git a/tests/auto/corelib/io/qstorageinfo/CMakeLists.txt b/tests/auto/corelib/io/qstorageinfo/CMakeLists.txt
new file mode 100644
index 0000000000..16e4415bc5
--- /dev/null
+++ b/tests/auto/corelib/io/qstorageinfo/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qstorageinfo SOURCES tst_qstorageinfo.cpp LIBRARIES Qt::CorePrivate)
diff --git a/tests/auto/corelib/io/qurlquery/CMakeLists.txt b/tests/auto/corelib/io/qurlquery/CMakeLists.txt
new file mode 100644
index 0000000000..88fd621720
--- /dev/null
+++ b/tests/auto/corelib/io/qurlquery/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qurlquery SOURCES tst_qurlquery.cpp 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..3f47845905
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/CMakeLists.txt
@@ -0,0 +1,4 @@
+# add_subdirectory(qabstractproxymodel)
+# add_subdirectory(qitemselectionmodel)
+add_subdirectory(qstringlistmodel)
+
diff --git a/tests/auto/corelib/itemmodels/qabstractproxymodel/CMakeLists.txt b/tests/auto/corelib/itemmodels/qabstractproxymodel/CMakeLists.txt
new file mode 100644
index 0000000000..7f2e10cf65
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qabstractproxymodel/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qabstractproxymodel SOURCES tst_qabstractproxymodel.cpp)
diff --git a/tests/auto/corelib/itemmodels/qitemselectionmodel/CMakeLists.txt b/tests/auto/corelib/itemmodels/qitemselectionmodel/CMakeLists.txt
new file mode 100644
index 0000000000..03c2ddede1
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qitemselectionmodel/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qitemselectionmodel SOURCES tst_qitemselectionmodel.cpp)
diff --git a/tests/auto/corelib/itemmodels/qstringlistmodel/CMakeLists.txt b/tests/auto/corelib/itemmodels/qstringlistmodel/CMakeLists.txt
new file mode 100644
index 0000000000..1cec834423
--- /dev/null
+++ b/tests/auto/corelib/itemmodels/qstringlistmodel/CMakeLists.txt
@@ -0,0 +1,4 @@
+add_qt_test(tst_qstringlistmodel SOURCES
+ qmodellistener.h
+ tst_qstringlistmodel.cpp
+)
diff --git a/tests/auto/corelib/kernel/CMakeLists.txt b/tests/auto/corelib/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..208cd89ca7
--- /dev/null
+++ b/tests/auto/corelib/kernel/CMakeLists.txt
@@ -0,0 +1,13 @@
+add_subdirectory(qdeadlinetimer)
+add_subdirectory(qelapsedtimer)
+add_subdirectory(qeventdispatcher)
+add_subdirectory(qmath)
+add_subdirectory(qmetaenum)
+add_subdirectory(qmetamethod)
+add_subdirectory(qmetaobject)
+add_subdirectory(qmetaobjectbuilder)
+add_subdirectory(qmetaproperty)
+# add_subdirectory(qmimedata)
+add_subdirectory(qsignalmapper)
+# add_subdirectory(qwineventnotifier)
+
diff --git a/tests/auto/corelib/kernel/qdeadlinetimer/CMakeLists.txt b/tests/auto/corelib/kernel/qdeadlinetimer/CMakeLists.txt
new file mode 100644
index 0000000000..0bf39130c2
--- /dev/null
+++ b/tests/auto/corelib/kernel/qdeadlinetimer/CMakeLists.txt
@@ -0,0 +1 @@
+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..7a937730ab
--- /dev/null
+++ b/tests/auto/corelib/kernel/qelapsedtimer/CMakeLists.txt
@@ -0,0 +1 @@
+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..832bbd4079
--- /dev/null
+++ b/tests/auto/corelib/kernel/qeventdispatcher/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qeventdispatcher SOURCES tst_qeventdispatcher.cpp)
diff --git a/tests/auto/corelib/kernel/qmath/CMakeLists.txt b/tests/auto/corelib/kernel/qmath/CMakeLists.txt
new file mode 100644
index 0000000000..3edebc0776
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmath/CMakeLists.txt
@@ -0,0 +1 @@
+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..2db56b9f3c
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmetaenum/CMakeLists.txt
@@ -0,0 +1 @@
+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..ca41b0d676
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmetamethod/CMakeLists.txt
@@ -0,0 +1 @@
+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..61b64ef36d
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmetaobject/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qmetaobject SOURCES tst_qmetaobject.cpp LIBRARIES Qt::CorePrivate)
diff --git a/tests/auto/corelib/kernel/qmetaobjectbuilder/CMakeLists.txt b/tests/auto/corelib/kernel/qmetaobjectbuilder/CMakeLists.txt
new file mode 100644
index 0000000000..bc86eb1e1e
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmetaobjectbuilder/CMakeLists.txt
@@ -0,0 +1 @@
+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..46635feb3a
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmetaproperty/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qmetaproperty SOURCES tst_qmetaproperty.cpp)
diff --git a/tests/auto/corelib/kernel/qmimedata/CMakeLists.txt b/tests/auto/corelib/kernel/qmimedata/CMakeLists.txt
new file mode 100644
index 0000000000..78d0a69d68
--- /dev/null
+++ b/tests/auto/corelib/kernel/qmimedata/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qmimedata SOURCES tst_qmimedata.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..1a6416fabb
--- /dev/null
+++ b/tests/auto/corelib/kernel/qsignalmapper/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qsignalmapper SOURCES tst_qsignalmapper.cpp)
diff --git a/tests/auto/corelib/kernel/qwineventnotifier/CMakeLists.txt b/tests/auto/corelib/kernel/qwineventnotifier/CMakeLists.txt
new file mode 100644
index 0000000000..db888dcda0
--- /dev/null
+++ b/tests/auto/corelib/kernel/qwineventnotifier/CMakeLists.txt
@@ -0,0 +1 @@
+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..1e59aa3329
--- /dev/null
+++ b/tests/auto/corelib/mimetypes/CMakeLists.txt
@@ -0,0 +1,2 @@
+# add_subdirectory(qmimetype)
+
diff --git a/tests/auto/corelib/mimetypes/qmimetype/CMakeLists.txt b/tests/auto/corelib/mimetypes/qmimetype/CMakeLists.txt
new file mode 100644
index 0000000000..9b70d0971a
--- /dev/null
+++ b/tests/auto/corelib/mimetypes/qmimetype/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qmimetype SOURCES tst_qmimetype.cpp LIBRARIES Qt::CorePrivate)
diff --git a/tests/auto/corelib/serialization/CMakeLists.txt b/tests/auto/corelib/serialization/CMakeLists.txt
new file mode 100644
index 0000000000..e856ccae90
--- /dev/null
+++ b/tests/auto/corelib/serialization/CMakeLists.txt
@@ -0,0 +1,5 @@
+add_subdirectory(qcborvalue_json)
+add_subdirectory(qcborstreamreader)
+add_subdirectory(qcborstreamwriter)
+add_subdirectory(qcborvalue)
+
diff --git a/tests/auto/corelib/serialization/qcborstreamreader/CMakeLists.txt b/tests/auto/corelib/serialization/qcborstreamreader/CMakeLists.txt
new file mode 100644
index 0000000000..2db29547a4
--- /dev/null
+++ b/tests/auto/corelib/serialization/qcborstreamreader/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test(tst_qcborstreamreader SOURCES
+ tst_qcborstreamreader.cpp
+ 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..483a335cd3
--- /dev/null
+++ b/tests/auto/corelib/serialization/qcborstreamwriter/CMakeLists.txt
@@ -0,0 +1,5 @@
+add_qt_test(tst_qcborstreamwriter SOURCES
+ tst_qcborstreamwriter.cpp
+ 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..f1630798e9
--- /dev/null
+++ b/tests/auto/corelib/serialization/qcborvalue/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test(tst_qcborvalue SOURCES
+ tst_qcborvalue.cpp
+ 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..651e0c68af
--- /dev/null
+++ b/tests/auto/corelib/serialization/qcborvalue_json/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qcborvalue_json SOURCES tst_qcborvalue_json.cpp)
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..28aa801be9
--- /dev/null
+++ b/tests/auto/corelib/statemachine/qstate/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qstate SOURCES tst_qstate.cpp)
diff --git a/tests/auto/corelib/thread/CMakeLists.txt b/tests/auto/corelib/thread/CMakeLists.txt
new file mode 100644
index 0000000000..357ae844f6
--- /dev/null
+++ b/tests/auto/corelib/thread/CMakeLists.txt
@@ -0,0 +1,13 @@
+add_subdirectory(qatomicint)
+add_subdirectory(qatomicpointer)
+add_subdirectory(qfuture)
+add_subdirectory(qfuturesynchronizer)
+add_subdirectory(qmutexlocker)
+add_subdirectory(qreadlocker)
+add_subdirectory(qreadwritelock)
+add_subdirectory(qresultstore)
+add_subdirectory(qsemaphore)
+add_subdirectory(qthreadpool)
+add_subdirectory(qwaitcondition)
+add_subdirectory(qwritelocker)
+
diff --git a/tests/auto/corelib/thread/qatomicint/CMakeLists.txt b/tests/auto/corelib/thread/qatomicint/CMakeLists.txt
new file mode 100644
index 0000000000..e94c228820
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicint/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qatomicint SOURCES tst_qatomicint.cpp)
diff --git a/tests/auto/corelib/thread/qatomicpointer/CMakeLists.txt b/tests/auto/corelib/thread/qatomicpointer/CMakeLists.txt
new file mode 100644
index 0000000000..3a74e4dc1f
--- /dev/null
+++ b/tests/auto/corelib/thread/qatomicpointer/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qatomicpointer SOURCES tst_qatomicpointer.cpp)
diff --git a/tests/auto/corelib/thread/qfuture/CMakeLists.txt b/tests/auto/corelib/thread/qfuture/CMakeLists.txt
new file mode 100644
index 0000000000..d37f134c46
--- /dev/null
+++ b/tests/auto/corelib/thread/qfuture/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qfuture SOURCES tst_qfuture.cpp 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..3745db0a75
--- /dev/null
+++ b/tests/auto/corelib/thread/qfuturesynchronizer/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qfuturesynchronizer SOURCES tst_qfuturesynchronizer.cpp)
diff --git a/tests/auto/corelib/thread/qmutexlocker/CMakeLists.txt b/tests/auto/corelib/thread/qmutexlocker/CMakeLists.txt
new file mode 100644
index 0000000000..de6be505ea
--- /dev/null
+++ b/tests/auto/corelib/thread/qmutexlocker/CMakeLists.txt
@@ -0,0 +1 @@
+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..b7b7c4add7
--- /dev/null
+++ b/tests/auto/corelib/thread/qreadlocker/CMakeLists.txt
@@ -0,0 +1 @@
+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..2a8ac42909
--- /dev/null
+++ b/tests/auto/corelib/thread/qreadwritelock/CMakeLists.txt
@@ -0,0 +1 @@
+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..52fefb84bb
--- /dev/null
+++ b/tests/auto/corelib/thread/qresultstore/CMakeLists.txt
@@ -0,0 +1 @@
+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..7bc1183bd2
--- /dev/null
+++ b/tests/auto/corelib/thread/qsemaphore/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qsemaphore SOURCES tst_qsemaphore.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..385bfcdea4
--- /dev/null
+++ b/tests/auto/corelib/thread/qthreadpool/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qthreadpool SOURCES tst_qthreadpool.cpp)
diff --git a/tests/auto/corelib/thread/qwaitcondition/CMakeLists.txt b/tests/auto/corelib/thread/qwaitcondition/CMakeLists.txt
new file mode 100644
index 0000000000..ab81379e03
--- /dev/null
+++ b/tests/auto/corelib/thread/qwaitcondition/CMakeLists.txt
@@ -0,0 +1 @@
+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..4635a34b6e
--- /dev/null
+++ b/tests/auto/corelib/thread/qwritelocker/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qwritelocker SOURCES tst_qwritelocker.cpp)
diff --git a/tests/auto/corelib/tools/CMakeLists.txt b/tests/auto/corelib/tools/CMakeLists.txt
new file mode 100644
index 0000000000..befa8e900d
--- /dev/null
+++ b/tests/auto/corelib/tools/CMakeLists.txt
@@ -0,0 +1,47 @@
+add_subdirectory(qalgorithms)
+add_subdirectory(qarraydata)
+add_subdirectory(qbitarray)
+add_subdirectory(qbytearraylist)
+add_subdirectory(qbytedatabuffer)
+add_subdirectory(qcache)
+add_subdirectory(qcommandlineparser)
+add_subdirectory(qcontiguouscache)
+add_subdirectory(qdate)
+add_subdirectory(qeasingcurve)
+add_subdirectory(qexplicitlyshareddatapointer)
+add_subdirectory(qhash)
+add_subdirectory(qhashfunctions)
+add_subdirectory(qlinkedlist)
+add_subdirectory(qlist)
+add_subdirectory(qmakearray)
+add_subdirectory(qmap)
+add_subdirectory(qmargins)
+add_subdirectory(qmessageauthenticationcode)
+add_subdirectory(qpair)
+add_subdirectory(qpoint)
+add_subdirectory(qpointf)
+add_subdirectory(qqueue)
+add_subdirectory(qrect)
+add_subdirectory(qregexp)
+add_subdirectory(qregularexpression)
+add_subdirectory(qringbuffer)
+add_subdirectory(qscopedpointer)
+add_subdirectory(qscopedvaluerollback)
+add_subdirectory(qscopeguard)
+add_subdirectory(qset)
+add_subdirectory(qsize)
+add_subdirectory(qsizef)
+add_subdirectory(qstl)
+add_subdirectory(qstring_no_cast_from_bytearray)
+add_subdirectory(qstringbuilder/qstringbuilder1)
+add_subdirectory(qstringbuilder/qstringbuilder2)
+add_subdirectory(qstringbuilder/qstringbuilder3)
+add_subdirectory(qstringbuilder/qstringbuilder4)
+add_subdirectory(qstringiterator)
+add_subdirectory(qstringlist)
+add_subdirectory(qstringmatcher)
+add_subdirectory(qstringref)
+add_subdirectory(qtime)
+add_subdirectory(qtimeline)
+add_subdirectory(qvarlengtharray)
+
diff --git a/tests/auto/corelib/tools/qalgorithms/CMakeLists.txt b/tests/auto/corelib/tools/qalgorithms/CMakeLists.txt
new file mode 100644
index 0000000000..66c205b605
--- /dev/null
+++ b/tests/auto/corelib/tools/qalgorithms/CMakeLists.txt
@@ -0,0 +1 @@
+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..573f13af55
--- /dev/null
+++ b/tests/auto/corelib/tools/qarraydata/CMakeLists.txt
@@ -0,0 +1,4 @@
+add_qt_test(tst_qarraydata SOURCES
+ tst_qarraydata.cpp
+ simplevector.h
+)
diff --git a/tests/auto/corelib/tools/qbitarray/CMakeLists.txt b/tests/auto/corelib/tools/qbitarray/CMakeLists.txt
new file mode 100644
index 0000000000..684fa58694
--- /dev/null
+++ b/tests/auto/corelib/tools/qbitarray/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qbitarray SOURCES tst_qbitarray.cpp)
diff --git a/tests/auto/corelib/tools/qbytearraylist/CMakeLists.txt b/tests/auto/corelib/tools/qbytearraylist/CMakeLists.txt
new file mode 100644
index 0000000000..f7b8314dbd
--- /dev/null
+++ b/tests/auto/corelib/tools/qbytearraylist/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qbytearraylist SOURCES tst_qbytearraylist.cpp)
diff --git a/tests/auto/corelib/tools/qbytedatabuffer/CMakeLists.txt b/tests/auto/corelib/tools/qbytedatabuffer/CMakeLists.txt
new file mode 100644
index 0000000000..c02ee4c284
--- /dev/null
+++ b/tests/auto/corelib/tools/qbytedatabuffer/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qbytedatabuffer SOURCES tst_qbytedatabuffer.cpp LIBRARIES Qt::CorePrivate)
diff --git a/tests/auto/corelib/tools/qcache/CMakeLists.txt b/tests/auto/corelib/tools/qcache/CMakeLists.txt
new file mode 100644
index 0000000000..816614bebf
--- /dev/null
+++ b/tests/auto/corelib/tools/qcache/CMakeLists.txt
@@ -0,0 +1 @@
+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..f4a38ed52d
--- /dev/null
+++ b/tests/auto/corelib/tools/qcommandlineparser/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_subdirectory(testhelper)
+
+add_qt_test(tst_qcommandlineparser SOURCES tst_qcommandlineparser.cpp)
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..d93193ac64
--- /dev/null
+++ b/tests/auto/corelib/tools/qcommandlineparser/testhelper/CMakeLists.txt
@@ -0,0 +1,20 @@
+# Generated from qcommandlineparser_test_helper.pro.
+
+#####################################################################
+## qcommandlineparser_test_helper Binary:
+#####################################################################
+
+# special case
+add_qt_test_helper(qcommandlineparser_test_helper
+ SOURCES
+ qcommandlineparser_test_helper.cpp
+)
+
+# special case
+set_target_properties(qcommandlineparser_test_helper PROPERTIES
+ RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
+
+
+#### Keys ignored in scope 1:tests/auto/corelib/tools/qcommandlineparser/testhelper:tests/auto/corelib/tools/qcommandlineparser/testhelper/qcommandlineparser_test_helper.pro:<NONE>:
+# CONFIG = "console" "-app_bundle"
+# DESTDIR = "./"
diff --git a/tests/auto/corelib/tools/qcontiguouscache/CMakeLists.txt b/tests/auto/corelib/tools/qcontiguouscache/CMakeLists.txt
new file mode 100644
index 0000000000..3f7dc63c5b
--- /dev/null
+++ b/tests/auto/corelib/tools/qcontiguouscache/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qcontiguouscache SOURCES tst_qcontiguouscache.cpp)
diff --git a/tests/auto/corelib/tools/qdate/CMakeLists.txt b/tests/auto/corelib/tools/qdate/CMakeLists.txt
new file mode 100644
index 0000000000..e967a03edf
--- /dev/null
+++ b/tests/auto/corelib/tools/qdate/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qdate SOURCES tst_qdate.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..42bfd081af
--- /dev/null
+++ b/tests/auto/corelib/tools/qeasingcurve/CMakeLists.txt
@@ -0,0 +1 @@
+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..5da0db0398
--- /dev/null
+++ b/tests/auto/corelib/tools/qexplicitlyshareddatapointer/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qexplicitlyshareddatapointer SOURCES tst_qexplicitlyshareddatapointer.cpp)
diff --git a/tests/auto/corelib/tools/qhash/CMakeLists.txt b/tests/auto/corelib/tools/qhash/CMakeLists.txt
new file mode 100644
index 0000000000..1e0026e5ba
--- /dev/null
+++ b/tests/auto/corelib/tools/qhash/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qhash SOURCES tst_qhash.cpp)
diff --git a/tests/auto/corelib/tools/qhashfunctions/CMakeLists.txt b/tests/auto/corelib/tools/qhashfunctions/CMakeLists.txt
new file mode 100644
index 0000000000..2a9b50e70e
--- /dev/null
+++ b/tests/auto/corelib/tools/qhashfunctions/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qhashfunctions SOURCES tst_qhashfunctions.cpp)
diff --git a/tests/auto/corelib/tools/qlinkedlist/CMakeLists.txt b/tests/auto/corelib/tools/qlinkedlist/CMakeLists.txt
new file mode 100644
index 0000000000..aad00ab21e
--- /dev/null
+++ b/tests/auto/corelib/tools/qlinkedlist/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qlinkedlist SOURCES tst_qlinkedlist.cpp)
diff --git a/tests/auto/corelib/tools/qlist/CMakeLists.txt b/tests/auto/corelib/tools/qlist/CMakeLists.txt
new file mode 100644
index 0000000000..ca5195b12e
--- /dev/null
+++ b/tests/auto/corelib/tools/qlist/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qlist SOURCES tst_qlist.cpp)
diff --git a/tests/auto/corelib/tools/qmakearray/CMakeLists.txt b/tests/auto/corelib/tools/qmakearray/CMakeLists.txt
new file mode 100644
index 0000000000..f63961fe14
--- /dev/null
+++ b/tests/auto/corelib/tools/qmakearray/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qmakearray SOURCES tst_qmakearray.cpp LIBRARIES Qt::CorePrivate)
diff --git a/tests/auto/corelib/tools/qmap/CMakeLists.txt b/tests/auto/corelib/tools/qmap/CMakeLists.txt
new file mode 100644
index 0000000000..a53b522bd8
--- /dev/null
+++ b/tests/auto/corelib/tools/qmap/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qmap SOURCES tst_qmap.cpp)
diff --git a/tests/auto/corelib/tools/qmargins/CMakeLists.txt b/tests/auto/corelib/tools/qmargins/CMakeLists.txt
new file mode 100644
index 0000000000..7bfb2d01f2
--- /dev/null
+++ b/tests/auto/corelib/tools/qmargins/CMakeLists.txt
@@ -0,0 +1 @@
+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..1c85138607
--- /dev/null
+++ b/tests/auto/corelib/tools/qmessageauthenticationcode/CMakeLists.txt
@@ -0,0 +1 @@
+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..e8a0c8e855
--- /dev/null
+++ b/tests/auto/corelib/tools/qpair/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qpair SOURCES tst_qpair.cpp)
diff --git a/tests/auto/corelib/tools/qpoint/CMakeLists.txt b/tests/auto/corelib/tools/qpoint/CMakeLists.txt
new file mode 100644
index 0000000000..869ddab1c7
--- /dev/null
+++ b/tests/auto/corelib/tools/qpoint/CMakeLists.txt
@@ -0,0 +1 @@
+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..d0cfc0c8ed
--- /dev/null
+++ b/tests/auto/corelib/tools/qpointf/CMakeLists.txt
@@ -0,0 +1 @@
+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..4e8a711fd9
--- /dev/null
+++ b/tests/auto/corelib/tools/qqueue/CMakeLists.txt
@@ -0,0 +1 @@
+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..3ffa3d1d34
--- /dev/null
+++ b/tests/auto/corelib/tools/qrect/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qrect SOURCES tst_qrect.cpp)
diff --git a/tests/auto/corelib/tools/qregexp/CMakeLists.txt b/tests/auto/corelib/tools/qregexp/CMakeLists.txt
new file mode 100644
index 0000000000..1a37644977
--- /dev/null
+++ b/tests/auto/corelib/tools/qregexp/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qregexp SOURCES tst_qregexp.cpp)
diff --git a/tests/auto/corelib/tools/qregularexpression/CMakeLists.txt b/tests/auto/corelib/tools/qregularexpression/CMakeLists.txt
new file mode 100644
index 0000000000..ff0cb8d962
--- /dev/null
+++ b/tests/auto/corelib/tools/qregularexpression/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qregularexpression SOURCES tst_qregularexpression.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..ccb9a1b7b4
--- /dev/null
+++ b/tests/auto/corelib/tools/qringbuffer/CMakeLists.txt
@@ -0,0 +1 @@
+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..24cc66b34a
--- /dev/null
+++ b/tests/auto/corelib/tools/qscopedpointer/CMakeLists.txt
@@ -0,0 +1 @@
+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..e772f67fb4
--- /dev/null
+++ b/tests/auto/corelib/tools/qscopedvaluerollback/CMakeLists.txt
@@ -0,0 +1 @@
+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..dae2fd49ff
--- /dev/null
+++ b/tests/auto/corelib/tools/qscopeguard/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qscopeguard SOURCES tst_qscopeguard.cpp)
diff --git a/tests/auto/corelib/tools/qset/CMakeLists.txt b/tests/auto/corelib/tools/qset/CMakeLists.txt
new file mode 100644
index 0000000000..e602ff4293
--- /dev/null
+++ b/tests/auto/corelib/tools/qset/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qset SOURCES tst_qset.cpp)
diff --git a/tests/auto/corelib/tools/qsize/CMakeLists.txt b/tests/auto/corelib/tools/qsize/CMakeLists.txt
new file mode 100644
index 0000000000..595b5f4af8
--- /dev/null
+++ b/tests/auto/corelib/tools/qsize/CMakeLists.txt
@@ -0,0 +1 @@
+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..05aa4ba8a7
--- /dev/null
+++ b/tests/auto/corelib/tools/qsizef/CMakeLists.txt
@@ -0,0 +1 @@
+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..37a9529e8f
--- /dev/null
+++ b/tests/auto/corelib/tools/qstl/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qstl SOURCES tst_qstl.cpp)
diff --git a/tests/auto/corelib/tools/qstring_no_cast_from_bytearray/CMakeLists.txt b/tests/auto/corelib/tools/qstring_no_cast_from_bytearray/CMakeLists.txt
new file mode 100644
index 0000000000..46a9e9ff79
--- /dev/null
+++ b/tests/auto/corelib/tools/qstring_no_cast_from_bytearray/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qstring_no_cast_from_bytearray SOURCES tst_qstring_no_cast_from_bytearray.cpp)
diff --git a/tests/auto/corelib/tools/qstringbuilder/qstringbuilder1/CMakeLists.txt b/tests/auto/corelib/tools/qstringbuilder/qstringbuilder1/CMakeLists.txt
new file mode 100644
index 0000000000..2fad1ee7ed
--- /dev/null
+++ b/tests/auto/corelib/tools/qstringbuilder/qstringbuilder1/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qstringbuilder1 SOURCES tst_qstringbuilder1.cpp)
diff --git a/tests/auto/corelib/tools/qstringbuilder/qstringbuilder2/CMakeLists.txt b/tests/auto/corelib/tools/qstringbuilder/qstringbuilder2/CMakeLists.txt
new file mode 100644
index 0000000000..93231a22e1
--- /dev/null
+++ b/tests/auto/corelib/tools/qstringbuilder/qstringbuilder2/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qstringbuilder2 SOURCES tst_qstringbuilder2.cpp)
diff --git a/tests/auto/corelib/tools/qstringbuilder/qstringbuilder3/CMakeLists.txt b/tests/auto/corelib/tools/qstringbuilder/qstringbuilder3/CMakeLists.txt
new file mode 100644
index 0000000000..4669fc93b4
--- /dev/null
+++ b/tests/auto/corelib/tools/qstringbuilder/qstringbuilder3/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qstringbuilder3 SOURCES tst_qstringbuilder3.cpp)
diff --git a/tests/auto/corelib/tools/qstringbuilder/qstringbuilder4/CMakeLists.txt b/tests/auto/corelib/tools/qstringbuilder/qstringbuilder4/CMakeLists.txt
new file mode 100644
index 0000000000..d6e7be6c11
--- /dev/null
+++ b/tests/auto/corelib/tools/qstringbuilder/qstringbuilder4/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qstringbuilder4 SOURCES tst_qstringbuilder4.cpp)
diff --git a/tests/auto/corelib/tools/qstringiterator/CMakeLists.txt b/tests/auto/corelib/tools/qstringiterator/CMakeLists.txt
new file mode 100644
index 0000000000..572ada1f4c
--- /dev/null
+++ b/tests/auto/corelib/tools/qstringiterator/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qstringiterator SOURCES tst_qstringiterator.cpp LIBRARIES Qt::CorePrivate)
diff --git a/tests/auto/corelib/tools/qstringlist/CMakeLists.txt b/tests/auto/corelib/tools/qstringlist/CMakeLists.txt
new file mode 100644
index 0000000000..af361fbbcc
--- /dev/null
+++ b/tests/auto/corelib/tools/qstringlist/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qstringlist SOURCES tst_qstringlist.cpp)
diff --git a/tests/auto/corelib/tools/qstringmatcher/CMakeLists.txt b/tests/auto/corelib/tools/qstringmatcher/CMakeLists.txt
new file mode 100644
index 0000000000..1bf0a6e15f
--- /dev/null
+++ b/tests/auto/corelib/tools/qstringmatcher/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qstringmatcher SOURCES tst_qstringmatcher.cpp)
diff --git a/tests/auto/corelib/tools/qstringref/CMakeLists.txt b/tests/auto/corelib/tools/qstringref/CMakeLists.txt
new file mode 100644
index 0000000000..d4daf1a437
--- /dev/null
+++ b/tests/auto/corelib/tools/qstringref/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qstringref SOURCES tst_qstringref.cpp)
diff --git a/tests/auto/corelib/tools/qtime/CMakeLists.txt b/tests/auto/corelib/tools/qtime/CMakeLists.txt
new file mode 100644
index 0000000000..0b8b4c81f3
--- /dev/null
+++ b/tests/auto/corelib/tools/qtime/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qtime SOURCES tst_qtime.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..b23f07e9b5
--- /dev/null
+++ b/tests/auto/corelib/tools/qtimeline/CMakeLists.txt
@@ -0,0 +1 @@
+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..a1bea13f9e
--- /dev/null
+++ b/tests/auto/corelib/tools/qvarlengtharray/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qvarlengtharray SOURCES tst_qvarlengtharray.cpp)
diff --git a/tests/auto/dbus/CMakeLists.txt b/tests/auto/dbus/CMakeLists.txt
new file mode 100644
index 0000000000..ed61a5be9e
--- /dev/null
+++ b/tests/auto/dbus/CMakeLists.txt
@@ -0,0 +1,32 @@
+# 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)
+
+ if(QT_FEATURE_private_tests)
+ add_subdirectory(qdbusmarshall)
+ endif()
+endif()
+
+if(QT_FEATURE_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..08bfb51234
--- /dev/null
+++ b/tests/auto/dbus/qdbusabstractadaptor/CMakeLists.txt
@@ -0,0 +1,12 @@
+# 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/CMakeLists.txt b/tests/auto/dbus/qdbusabstractadaptor/qmyserver/CMakeLists.txt
new file mode 100644
index 0000000000..e8d542056c
--- /dev/null
+++ b/tests/auto/dbus/qdbusabstractadaptor/qmyserver/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qmyserver.pro.
+
+#####################################################################
+## qmyserver Binary:
+#####################################################################
+
+add_qt_executable(qmyserver
+ SOURCES
+ ../myobject.h
+ qmyserver.cpp
+ LIBRARIES
+ Qt::Core
+ 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/qpinger/CMakeLists.txt b/tests/auto/dbus/qdbusabstractinterface/qpinger/CMakeLists.txt
new file mode 100644
index 0000000000..c2bf6ea3e3
--- /dev/null
+++ b/tests/auto/dbus/qdbusabstractinterface/qpinger/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qpinger.pro.
+
+#####################################################################
+## qpinger Binary:
+#####################################################################
+
+add_qt_executable(qpinger
+ SOURCES
+ ../interface.cpp ../interface.h
+ qpinger.cpp
+ LIBRARIES
+ Qt::Core
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusconnection/CMakeLists.txt b/tests/auto/dbus/qdbusconnection/CMakeLists.txt
new file mode 100644
index 0000000000..e2886d9185
--- /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
+ 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..8463fea971
--- /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}/"
+ 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..07223682cf
--- /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
+ 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..8cd1e2a3d3
--- /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
+ 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..08a5c3cad5
--- /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
+ 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..e7c6cf0ea2
--- /dev/null
+++ b/tests/auto/dbus/qdbusconnection_spyhook/CMakeLists.txt
@@ -0,0 +1,17 @@
+# 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
+ LIBRARIES
+ Qt::DBus
+ RUN_SERIAL
+)
diff --git a/tests/auto/dbus/qdbuscontext/CMakeLists.txt b/tests/auto/dbus/qdbuscontext/CMakeLists.txt
new file mode 100644
index 0000000000..e5ecc293e5
--- /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
+ 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..bb1debd590
--- /dev/null
+++ b/tests/auto/dbus/qdbusinterface/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from qdbusinterface.pro.
+
+add_subdirectory(qmyserver)
+
+add_qt_test(tst_qdbusinterface
+ SOURCES
+ myobject.h
+ tst_qdbusinterface.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBus
+ Qt::DBusPrivate
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qdbusinterface CONDITION QT_FEATURE_dbus_linked
+ DEFINES
+ QT_LINKED_LIBDBUS
+)
+
+extend_target(tst_qdbusinterface CONDITION NOT QT_FEATURE_dbus_linked
+ SOURCES
+ ../../../../src/dbus/qdbus_symbols.cpp
+)
diff --git a/tests/auto/dbus/qdbusinterface/qmyserver/CMakeLists.txt b/tests/auto/dbus/qdbusinterface/qmyserver/CMakeLists.txt
new file mode 100644
index 0000000000..81427017bd
--- /dev/null
+++ b/tests/auto/dbus/qdbusinterface/qmyserver/CMakeLists.txt
@@ -0,0 +1,17 @@
+# Generated from qmyserver.pro.
+
+#####################################################################
+## qmyserver Binary:
+#####################################################################
+
+# Can't be called qmyserver since the qdbusabstractadaptor test
+# already has a executable target named like that, so use
+# a different target name and then rename the binary
+add_qt_executable(qmyserver_qdbusinterface
+ SOURCES
+ ../myobject.h
+ qmyserver.cpp
+ LIBRARIES
+ Qt::Core
+ Qt::DBus
+)
diff --git a/tests/auto/dbus/qdbusinterface/tst_qdbusinterface.cpp b/tests/auto/dbus/qdbusinterface/tst_qdbusinterface.cpp
index 05480c6dd2..ca3b779fea 100644
--- a/tests/auto/dbus/qdbusinterface/tst_qdbusinterface.cpp
+++ b/tests/auto/dbus/qdbusinterface/tst_qdbusinterface.cpp
@@ -270,7 +270,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..fee5d38372
--- /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
+ 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/CMakeLists.txt b/tests/auto/dbus/qdbusmarshall/qdbusmarshall/CMakeLists.txt
new file mode 100644
index 0000000000..bfa7cf0b2f
--- /dev/null
+++ b/tests/auto/dbus/qdbusmarshall/qdbusmarshall/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from qdbusmarshall.pro.
+
+#####################################################################
+## ../tst_qdbusmarshall Test:
+#####################################################################
+
+add_qt_test(../tst_qdbusmarshall
+ SOURCES
+ ../tst_qdbusmarshall.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBusPrivate
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(../tst_qdbusmarshall CONDITION QT_FEATURE_dbus_linked
+ DEFINES
+ QT_LINKED_LIBDBUS
+)
+
+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..358bb235ed
--- /dev/null
+++ b/tests/auto/dbus/qdbusmarshall/qpong/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qpong.pro.
+
+#####################################################################
+## qpong Binary:
+#####################################################################
+
+add_qt_executable(qpong
+ SOURCES
+ qpong.cpp
+ 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..661339c4fe
--- /dev/null
+++ b/tests/auto/dbus/qdbusmetaobject/CMakeLists.txt
@@ -0,0 +1,12 @@
+# Generated from qdbusmetaobject.pro.
+
+#####################################################################
+## tst_qdbusmetaobject Test:
+#####################################################################
+
+add_qt_test(tst_qdbusmetaobject
+ SOURCES
+ tst_qdbusmetaobject.cpp
+ LIBRARIES
+ Qt::DBusPrivate
+)
diff --git a/tests/auto/dbus/qdbusmetatype/CMakeLists.txt b/tests/auto/dbus/qdbusmetatype/CMakeLists.txt
new file mode 100644
index 0000000000..cde3362ed8
--- /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
+ 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..86f981221a
--- /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
+ 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..82224c20d6
--- /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
+ 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..283be755f6
--- /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
+ 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..fe1c3c7911
--- /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
+ 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..7cab309dbf
--- /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
+ 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..c76f44ba02
--- /dev/null
+++ b/tests/auto/dbus/qdbustype/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from qdbustype.pro.
+
+#####################################################################
+## tst_qdbustype Test:
+#####################################################################
+
+add_qt_test(tst_qdbustype
+ SOURCES
+ tst_qdbustype.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBusPrivate
+)
+
+## Scopes:
+#####################################################################
+
+extend_target(tst_qdbustype CONDITION QT_FEATURE_dbus_linked
+ DEFINES
+ QT_LINKED_LIBDBUS
+)
+
+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..ab35fba048
--- /dev/null
+++ b/tests/auto/dbus/qdbusxmlparser/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qdbusxmlparser.pro.
+
+#####################################################################
+## tst_qdbusxmlparser Test:
+#####################################################################
+
+add_qt_test(tst_qdbusxmlparser
+ SOURCES
+ tst_qdbusxmlparser.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::DBusPrivate
+ Qt::Xml
+)
diff --git a/tests/auto/gui/CMakeLists.txt b/tests/auto/gui/CMakeLists.txt
new file mode 100644
index 0000000000..8be8abea63
--- /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")
+ if (QT_FEATURE_opengl AND NOT WINRT)
+ # missing CMakeLists.txt: add_subdirectory("qopenglconfig")
+ # missing CMakeLists.txt: add_subdirectory("qopengl")
+ endif()
+ # if (QT_FEATURE_vulkan)
+ # add_subdirectory("qvulkan")
+ # endif()
+ # add_subdirectory("text")
+ add_subdirectory("util")
+ add_subdirectory("itemmodels")
+endif()
diff --git a/tests/auto/gui/image/CMakeLists.txt b/tests/auto/gui/image/CMakeLists.txt
new file mode 100644
index 0000000000..ea56c0474a
--- /dev/null
+++ b/tests/auto/gui/image/CMakeLists.txt
@@ -0,0 +1,15 @@
+if (QT_FEATURE_network)
+# add_subdirectory("qimagereader")
+endif()
+# add_subdirectory("qicoimageformat")
+# add_subdirectory("qpixmap")
+if (QT_FEATURE_private_tests)
+# add_subdirectory("qpixmapcache")
+endif()
+# add_subdirectory("qimage")
+add_subdirectory("qimageiohandler")
+# add_subdirectory("qimagewriter")
+# add_subdirectory("qmovie")
+add_subdirectory("qpicture")
+# add_subdirectory("qicon")
+# add_subdirectory("qiconhighdpi")
diff --git a/tests/auto/gui/image/qimageiohandler/CMakeLists.txt b/tests/auto/gui/image/qimageiohandler/CMakeLists.txt
new file mode 100644
index 0000000000..fbefeb26d8
--- /dev/null
+++ b/tests/auto/gui/image/qimageiohandler/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qimageiohandler SOURCES tst_qimageiohandler.cpp LIBRARIES Qt::Gui)
diff --git a/tests/auto/gui/image/qpicture/CMakeLists.txt b/tests/auto/gui/image/qpicture/CMakeLists.txt
new file mode 100644
index 0000000000..c3db4ffb25
--- /dev/null
+++ b/tests/auto/gui/image/qpicture/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qpicture SOURCES tst_qpicture.cpp 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..cfbf843cac
--- /dev/null
+++ b/tests/auto/gui/itemmodels/qstandarditem/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qstandarditem SOURCES tst_qstandarditem.cpp 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..f48625d539
--- /dev/null
+++ b/tests/auto/gui/kernel/CMakeLists.txt
@@ -0,0 +1,38 @@
+# add_subdirectory("qbackingstore")
+if (NOT ANDROID AND NOT APPLE_UIKIT)
+# add_subdirectory("qclipboard")
+endif()
+add_subdirectory("qcursor")
+# add_subdirectory("qdrag")
+add_subdirectory("qevent")
+add_subdirectory("qfileopenevent")
+#add_subdirectory("qguieventdispatcher")
+if (QT_FEATURE_network)
+# add_subdirectory("qguieventloop")
+endif()
+# add_subdirectory("qguimetatype")
+# add_subdirectory("qguitimer")
+add_subdirectory("qguivariant")
+# add_subdirectory("qinputmethod")
+# add_subdirectory("qkeyevent")
+# add_subdirectory("qkeysequence")
+add_subdirectory("qmouseevent")
+if (QT_FEATURE_widgets)
+# add_subdirectory("qmouseevent_modal")
+ add_subdirectory("qpalette")
+endif()
+# add_subdirectory("qscreen")
+# add_subdirectory("qsurfaceformat")
+# add_subdirectory("qtouchevent")
+# add_subdirectory("qwindow")
+# add_subdirectory("qguiapplication")
+# add_subdirectory("qpixelformat")
+if (QT_FEATURE_opengl)
+# add_subdirectory("qopenglwindow")
+endif()
+# add_subdirectory("qrasterwindow")
+
+if(WIN32 AND NOT WINRT AND QT_FEATURE_network)
+# add_subdirectory("noqteventloop")
+endif()
+
diff --git a/tests/auto/gui/kernel/qcursor/CMakeLists.txt b/tests/auto/gui/kernel/qcursor/CMakeLists.txt
new file mode 100644
index 0000000000..431aa9f374
--- /dev/null
+++ b/tests/auto/gui/kernel/qcursor/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qcursor SOURCES tst_qcursor.cpp 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..7fa08d2609
--- /dev/null
+++ b/tests/auto/gui/kernel/qevent/CMakeLists.txt
@@ -0,0 +1 @@
+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..c5bafe3ebe
--- /dev/null
+++ b/tests/auto/gui/kernel/qfileopenevent/CMakeLists.txt
@@ -0,0 +1,2 @@
+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..fddc9399f5
--- /dev/null
+++ b/tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(qfileopeneventexternal SOURCES qfileopeneventexternal.cpp LIBRARIES Qt::Gui)
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..122d449770
--- /dev/null
+++ b/tests/auto/gui/kernel/qfileopenevent/test/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qfileopenevent SOURCES tst_qfileopenevent.cpp LIBRARIES Qt::Gui)
diff --git a/tests/auto/gui/kernel/qguivariant/CMakeLists.txt b/tests/auto/gui/kernel/qguivariant/CMakeLists.txt
new file mode 100644
index 0000000000..41b0aacf85
--- /dev/null
+++ b/tests/auto/gui/kernel/qguivariant/CMakeLists.txt
@@ -0,0 +1,2 @@
+# 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..b8acedbe45
--- /dev/null
+++ b/tests/auto/gui/kernel/qguivariant/no_application/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(no_application SOURCES main.cpp LIBRARIES Qt::Gui)
diff --git a/tests/auto/gui/kernel/qmouseevent/CMakeLists.txt b/tests/auto/gui/kernel/qmouseevent/CMakeLists.txt
new file mode 100644
index 0000000000..a478d9c027
--- /dev/null
+++ b/tests/auto/gui/kernel/qmouseevent/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qmouseevent SOURCES tst_qmouseevent.cpp 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..d7573bbc70
--- /dev/null
+++ b/tests/auto/gui/kernel/qpalette/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qpalette SOURCES tst_qpalette.cpp LIBRARIES Qt::Gui)
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..f1758bf473
--- /dev/null
+++ b/tests/auto/gui/math3d/qmatrixnxn/CMakeLists.txt
@@ -0,0 +1,5 @@
+add_qt_test(tst_qmatrixnxn
+ SOURCES tst_qmatrixnxn.cpp
+ DEFINES QT_DISABLE_DEPRECATED_BEFORE=0
+ 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..dd53422535
--- /dev/null
+++ b/tests/auto/gui/math3d/qquaternion/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qquaternion SOURCES tst_qquaternion.cpp 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..7a4321740f
--- /dev/null
+++ b/tests/auto/gui/math3d/qvectornd/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qvectornd SOURCES tst_qvectornd.cpp 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..fc62e50c1e
--- /dev/null
+++ b/tests/auto/gui/painting/CMakeLists.txt
@@ -0,0 +1,19 @@
+# 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)
+ 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..73e7dcfd6b
--- /dev/null
+++ b/tests/auto/gui/painting/qpagesize/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qpagesize SOURCES tst_qpagesize.cpp 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..d361a5707b
--- /dev/null
+++ b/tests/auto/gui/painting/qpaintengine/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qpaintengine SOURCES tst_qpaintengine.cpp 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..3e4880ae63
--- /dev/null
+++ b/tests/auto/gui/painting/qpainterpath/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qpainterpath SOURCES tst_qpainterpath.cpp 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..15279ca69f
--- /dev/null
+++ b/tests/auto/gui/painting/qpainterpathstroker/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qpainterpathstroker SOURCES tst_qpainterpathstroker.cpp 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..99668679ff
--- /dev/null
+++ b/tests/auto/gui/painting/qpen/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qpen SOURCES tst_qpen.cpp LIBRARIES Qt::Gui)
diff --git a/tests/auto/gui/util/CMakeLists.txt b/tests/auto/gui/util/CMakeLists.txt
new file mode 100644
index 0000000000..c7dec5460d
--- /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/qdoublevalidator/CMakeLists.txt b/tests/auto/gui/util/qdoublevalidator/CMakeLists.txt
new file mode 100644
index 0000000000..5d6bf2ceea
--- /dev/null
+++ b/tests/auto/gui/util/qdoublevalidator/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qdoublevalidator SOURCES tst_qdoublevalidator.cpp 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..54bb16e248
--- /dev/null
+++ b/tests/auto/gui/util/qintvalidator/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qintvalidator SOURCES tst_qintvalidator.cpp 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..1447d702ec
--- /dev/null
+++ b/tests/auto/gui/util/qregexpvalidator/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qregexpvalidator SOURCES tst_qregexpvalidator.cpp 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..8d57b0fa08
--- /dev/null
+++ b/tests/auto/gui/util/qregularexpressionvalidator/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qregularexpressionvalidator SOURCES tst_qregularexpressionvalidator.cpp LIBRARIES Qt::Gui)
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..77c0afca75
--- /dev/null
+++ b/tests/auto/opengl/qgl/CMakeLists.txt
@@ -0,0 +1,7 @@
+add_qt_test("tst_qgl" SOURCES qgl.qrc tst_qgl.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::OpenGLPrivate
+ Qt::GuiPrivate
+ Qt::CorePrivate
+)
diff --git a/tests/auto/opengl/qglbuffer/CMakeLists.txt b/tests/auto/opengl/qglbuffer/CMakeLists.txt
new file mode 100644
index 0000000000..96296846b4
--- /dev/null
+++ b/tests/auto/opengl/qglbuffer/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qglbuffer" SOURCES tst_qglbuffer.cpp LIBRARIES Qt::OpenGL Qt::Widgets)
diff --git a/tests/auto/opengl/qglfunctions/CMakeLists.txt b/tests/auto/opengl/qglfunctions/CMakeLists.txt
new file mode 100644
index 0000000000..21a0766ac2
--- /dev/null
+++ b/tests/auto/opengl/qglfunctions/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qglfunctions" SOURCES tst_qglfunctions.cpp LIBRARIES Qt::OpenGL Qt::Widgets)
diff --git a/tests/auto/opengl/qglthreads/CMakeLists.txt b/tests/auto/opengl/qglthreads/CMakeLists.txt
new file mode 100644
index 0000000000..0564fe3e6f
--- /dev/null
+++ b/tests/auto/opengl/qglthreads/CMakeLists.txt
@@ -0,0 +1,7 @@
+add_qt_test("tst_qglthreads" SOURCES tst_qglthreads.cpp tst_qglthreads.h
+ LIBRARIES
+ Qt::OpenGL
+ Qt::Widgets
+ Qt::GuiPrivate
+ Qt::CorePrivate
+)
diff --git a/tests/auto/other/qtokenautomaton/CMakeLists.txt b/tests/auto/other/qtokenautomaton/CMakeLists.txt
new file mode 100644
index 0000000000..394dc614f1
--- /dev/null
+++ b/tests/auto/other/qtokenautomaton/CMakeLists.txt
@@ -0,0 +1,15 @@
+add_qt_test(tst_qtokenautomaton SOURCES
+ tst_qtokenautomaton.cpp
+ tokenizers/basic/basic.cpp
+ tokenizers/basicNamespace/basicNamespace.cpp
+ tokenizers/boilerplate/boilerplate.cpp
+ tokenizers/noNamespace/noNamespace.cpp
+ tokenizers/noToString/noToString.cpp
+ tokenizers/withNamespace/withNamespace.cpp
+ tokenizers/basic/basic.h
+ tokenizers/basicNamespace/basicNamespace.h
+ tokenizers/boilerplate/boilerplate.h
+ tokenizers/noNamespace/noNamespace.h
+ tokenizers/noToString/noToString.h
+ tokenizers/withNamespace/withNamespace.h
+)
diff --git a/tests/auto/other/toolsupport/CMakeLists.txt b/tests/auto/other/toolsupport/CMakeLists.txt
new file mode 100644
index 0000000000..637a00bffc
--- /dev/null
+++ b/tests/auto/other/toolsupport/CMakeLists.txt
@@ -0,0 +1 @@
+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..610fa3006c
--- /dev/null
+++ b/tests/auto/other/xkbkeyboard/CMakeLists.txt
@@ -0,0 +1,2 @@
+add_qt_test(alive SOURCES tst_alive.cpp
+ LIBRARIES Widgets)
diff --git a/tests/auto/printsupport/CMakeLists.txt b/tests/auto/printsupport/CMakeLists.txt
new file mode 100644
index 0000000000..791d6e4807
--- /dev/null
+++ b/tests/auto/printsupport/CMakeLists.txt
@@ -0,0 +1,2 @@
+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..1297d0138d
--- /dev/null
+++ b/tests/auto/printsupport/dialogs/qabstractprintdialog/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qabstractprintdialog.pro.
+
+#####################################################################
+## tst_qabstractprintdialog Test:
+#####################################################################
+
+add_qt_test(tst_qabstractprintdialog
+ SOURCES
+ tst_qabstractprintdialog.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::PrintSupport
+)
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..ce0e6d96a9
--- /dev/null
+++ b/tests/auto/printsupport/kernel/qprintdevice/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qprintdevice.pro.
+
+#####################################################################
+## tst_qprintdevice Test:
+#####################################################################
+
+add_qt_test(tst_qprintdevice
+ SOURCES
+ tst_qprintdevice.cpp
+ DEFINES
+ QT_USE_USING_NAMESPACE
+ LIBRARIES
+ Qt::PrintSupportPrivate
+)
diff --git a/tests/auto/printsupport/kernel/qprinter/CMakeLists.txt b/tests/auto/printsupport/kernel/qprinter/CMakeLists.txt
new file mode 100644
index 0000000000..800e693321
--- /dev/null
+++ b/tests/auto/printsupport/kernel/qprinter/CMakeLists.txt
@@ -0,0 +1,13 @@
+# Generated from qprinter.pro.
+
+#####################################################################
+## tst_qprinter Test:
+#####################################################################
+
+add_qt_test(tst_qprinter
+ SOURCES
+ tst_qprinter.cpp
+ LIBRARIES
+ 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..482891d85b
--- /dev/null
+++ b/tests/auto/printsupport/kernel/qprinterinfo/CMakeLists.txt
@@ -0,0 +1,14 @@
+# Generated from qprinterinfo.pro.
+
+#####################################################################
+## tst_qprinterinfo Test:
+#####################################################################
+
+add_qt_test(tst_qprinterinfo
+ SOURCES
+ tst_qprinterinfo.cpp
+ DEFINES
+ QT_USE_USING_NAMESPACE
+ LIBRARIES
+ Qt::PrintSupport
+)
diff --git a/tests/auto/sql/CMakeLists.txt b/tests/auto/sql/CMakeLists.txt
new file mode 100644
index 0000000000..7d4cd486b4
--- /dev/null
+++ b/tests/auto/sql/CMakeLists.txt
@@ -0,0 +1,2 @@
+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..0e11fced12
--- /dev/null
+++ b/tests/auto/sql/kernel/qsql/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test(tst_qsql
+ SOURCES tst_qsql.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+)
diff --git a/tests/auto/sql/kernel/qsqldatabase/CMakeLists.txt b/tests/auto/sql/kernel/qsqldatabase/CMakeLists.txt
new file mode 100644
index 0000000000..344d96406b
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqldatabase/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test(tst_qsqldatabase
+ SOURCES tst_qsqldatabase.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+)
diff --git a/tests/auto/sql/kernel/qsqldriver/CMakeLists.txt b/tests/auto/sql/kernel/qsqldriver/CMakeLists.txt
new file mode 100644
index 0000000000..66139b08c9
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqldriver/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test(tst_qsqldriver
+ SOURCES tst_qsqldriver.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+)
diff --git a/tests/auto/sql/kernel/qsqlerror/CMakeLists.txt b/tests/auto/sql/kernel/qsqlerror/CMakeLists.txt
new file mode 100644
index 0000000000..4c2b7a8988
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqlerror/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qsqlerror SOURCES tst_qsqlerror.cpp 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..71b470706f
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqlfield/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qsqlfield SOURCES tst_qsqlfield.cpp 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..5c35765679
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqlquery/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test(tst_qsqlquery
+ SOURCES tst_qsqlquery.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+)
diff --git a/tests/auto/sql/kernel/qsqlrecord/CMakeLists.txt b/tests/auto/sql/kernel/qsqlrecord/CMakeLists.txt
new file mode 100644
index 0000000000..68c80ed990
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqlrecord/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qsqlrecord SOURCES tst_qsqlrecord.cpp 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..01ac844bc5
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqlresult/CMakeLists.txt
@@ -0,0 +1,8 @@
+add_qt_test(tst_qsqlresult
+ SOURCES
+ testsqldriver.h
+ tst_qsqlresult.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+)
diff --git a/tests/auto/sql/kernel/qsqlthread/CMakeLists.txt b/tests/auto/sql/kernel/qsqlthread/CMakeLists.txt
new file mode 100644
index 0000000000..77762d286f
--- /dev/null
+++ b/tests/auto/sql/kernel/qsqlthread/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test(tst_qsqlthread
+ SOURCES tst_qsqlthread.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+)
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..0233cd8dc8
--- /dev/null
+++ b/tests/auto/sql/models/qsqlquerymodel/CMakeLists.txt
@@ -0,0 +1,7 @@
+add_qt_test(tst_qsqlquerymodel
+ SOURCES tst_qsqlquerymodel.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::CorePrivate
+ Qt::SqlPrivate
+)
diff --git a/tests/auto/sql/models/qsqlrelationaldelegate/CMakeLists.txt b/tests/auto/sql/models/qsqlrelationaldelegate/CMakeLists.txt
new file mode 100644
index 0000000000..f84a74417c
--- /dev/null
+++ b/tests/auto/sql/models/qsqlrelationaldelegate/CMakeLists.txt
@@ -0,0 +1,7 @@
+add_qt_test(tst_qsqlrelationaldelegate
+ SOURCES tst_qsqlrelationaldelegate.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+ 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..efb2aa84a5
--- /dev/null
+++ b/tests/auto/sql/models/qsqlrelationaltablemodel/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test(tst_qsqlrelationaltablemodel
+ SOURCES tst_qsqlrelationaltablemodel.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+)
diff --git a/tests/auto/sql/models/qsqltablemodel/CMakeLists.txt b/tests/auto/sql/models/qsqltablemodel/CMakeLists.txt
new file mode 100644
index 0000000000..b364e176f0
--- /dev/null
+++ b/tests/auto/sql/models/qsqltablemodel/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test(tst_qsqltablemodel
+ SOURCES tst_qsqltablemodel.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::SqlPrivate
+)
diff --git a/tests/auto/testlib/CMakeLists.txt b/tests/auto/testlib/CMakeLists.txt
new file mode 100644
index 0000000000..a87e2203f9
--- /dev/null
+++ b/tests/auto/testlib/CMakeLists.txt
@@ -0,0 +1,4 @@
+add_subdirectory(qabstractitemmodeltester)
+add_subdirectory(qsignalspy)
+add_subdirectory(selftests)
+
diff --git a/tests/auto/testlib/qabstractitemmodeltester/CMakeLists.txt b/tests/auto/testlib/qabstractitemmodeltester/CMakeLists.txt
new file mode 100644
index 0000000000..bcb975d846
--- /dev/null
+++ b/tests/auto/testlib/qabstractitemmodeltester/CMakeLists.txt
@@ -0,0 +1,8 @@
+add_qt_test(tst_qabstractitemmodeltester SOURCES
+ tst_qabstractitemmodeltester.cpp
+ ${CMAKE_CURRENT_SOURCE_DIR}/../../other/qabstractitemmodelutils/dynamictreemodel.cpp
+ INCLUDE_DIRECTORIES
+ ${CMAKE_CURRENT_SOURCE_DIR}/../../other/qabstractitemmodelutils
+ LIBRARIES
+ Qt::Widgets
+)
diff --git a/tests/auto/testlib/qsignalspy/CMakeLists.txt b/tests/auto/testlib/qsignalspy/CMakeLists.txt
new file mode 100644
index 0000000000..ffdaa28de4
--- /dev/null
+++ b/tests/auto/testlib/qsignalspy/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qsignalspy SOURCES tst_qsignalspy.cpp)
diff --git a/tests/auto/testlib/selftests/CMakeLists.txt b/tests/auto/testlib/selftests/CMakeLists.txt
new file mode 100644
index 0000000000..ee1efa53fc
--- /dev/null
+++ b/tests/auto/testlib/selftests/CMakeLists.txt
@@ -0,0 +1,42 @@
+# add_subdirectory(alive) # TODO is commented in selftests.pri too. Investigate if should be readded
+add_subdirectory(assert)
+add_subdirectory(badxml)
+add_subdirectory(benchlibcallgrind)
+add_subdirectory(benchlibcounting)
+add_subdirectory(benchlibeventcounter)
+add_subdirectory(benchliboptions)
+add_subdirectory(benchlibwalltime)
+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(expectfail)
+add_subdirectory(failcleanup)
+add_subdirectory(failinit)
+add_subdirectory(failinitdata)
+add_subdirectory(fetchbogus)
+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(singleskip)
+add_subdirectory(skip)
+add_subdirectory(skipcleanup)
+add_subdirectory(skipinit)
+add_subdirectory(skipinitdata)
+add_subdirectory(sleep)
+add_subdirectory(strcmp)
+add_subdirectory(subtest)
+add_subdirectory(tuplediagnostics)
+add_subdirectory(warnings)
+add_subdirectory(xunit)
+
diff --git a/tests/auto/testlib/selftests/assert/CMakeLists.txt b/tests/auto/testlib/selftests/assert/CMakeLists.txt
new file mode 100644
index 0000000000..f988275038
--- /dev/null
+++ b/tests/auto/testlib/selftests/assert/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(assert SOURCES tst_assert.cpp)
diff --git a/tests/auto/testlib/selftests/badxml/CMakeLists.txt b/tests/auto/testlib/selftests/badxml/CMakeLists.txt
new file mode 100644
index 0000000000..9a709a2d7d
--- /dev/null
+++ b/tests/auto/testlib/selftests/badxml/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(badxml SOURCES tst_badxml.cpp LIBRARIES Qt::CorePrivate)
diff --git a/tests/auto/testlib/selftests/benchlibcallgrind/CMakeLists.txt b/tests/auto/testlib/selftests/benchlibcallgrind/CMakeLists.txt
new file mode 100644
index 0000000000..f247623e6c
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibcallgrind/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(benchlibcallgrind SOURCES tst_benchlibcallgrind.cpp)
diff --git a/tests/auto/testlib/selftests/benchlibcounting/CMakeLists.txt b/tests/auto/testlib/selftests/benchlibcounting/CMakeLists.txt
new file mode 100644
index 0000000000..e8df2820d6
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibcounting/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(benchlibcounting SOURCES tst_benchlibcounting.cpp)
diff --git a/tests/auto/testlib/selftests/benchlibeventcounter/CMakeLists.txt b/tests/auto/testlib/selftests/benchlibeventcounter/CMakeLists.txt
new file mode 100644
index 0000000000..b98c46c870
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibeventcounter/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(benchlibeventcounter SOURCES tst_benchlibeventcounter.cpp)
diff --git a/tests/auto/testlib/selftests/benchliboptions/CMakeLists.txt b/tests/auto/testlib/selftests/benchliboptions/CMakeLists.txt
new file mode 100644
index 0000000000..c7e57e6080
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchliboptions/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(benchliboptions SOURCES tst_benchliboptions.cpp)
diff --git a/tests/auto/testlib/selftests/benchlibwalltime/CMakeLists.txt b/tests/auto/testlib/selftests/benchlibwalltime/CMakeLists.txt
new file mode 100644
index 0000000000..d774fb95c0
--- /dev/null
+++ b/tests/auto/testlib/selftests/benchlibwalltime/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(benchlibwalltime SOURCES tst_benchlibwalltime.cpp)
diff --git a/tests/auto/testlib/selftests/commandlinedata/CMakeLists.txt b/tests/auto/testlib/selftests/commandlinedata/CMakeLists.txt
new file mode 100644
index 0000000000..a9d4fee477
--- /dev/null
+++ b/tests/auto/testlib/selftests/commandlinedata/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(commandlinedata SOURCES tst_commandlinedata.cpp)
diff --git a/tests/auto/testlib/selftests/counting/CMakeLists.txt b/tests/auto/testlib/selftests/counting/CMakeLists.txt
new file mode 100644
index 0000000000..bde163f663
--- /dev/null
+++ b/tests/auto/testlib/selftests/counting/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(counting SOURCES tst_counting.cpp)
diff --git a/tests/auto/testlib/selftests/crashes/CMakeLists.txt b/tests/auto/testlib/selftests/crashes/CMakeLists.txt
new file mode 100644
index 0000000000..046e0e0fcc
--- /dev/null
+++ b/tests/auto/testlib/selftests/crashes/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(crashes SOURCES tst_crashes.cpp)
diff --git a/tests/auto/testlib/selftests/datatable/CMakeLists.txt b/tests/auto/testlib/selftests/datatable/CMakeLists.txt
new file mode 100644
index 0000000000..a6f5bd10a7
--- /dev/null
+++ b/tests/auto/testlib/selftests/datatable/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(datatable SOURCES tst_datatable.cpp)
diff --git a/tests/auto/testlib/selftests/datetime/CMakeLists.txt b/tests/auto/testlib/selftests/datetime/CMakeLists.txt
new file mode 100644
index 0000000000..989f9b242c
--- /dev/null
+++ b/tests/auto/testlib/selftests/datetime/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(datetime SOURCES tst_datetime.cpp)
diff --git a/tests/auto/testlib/selftests/deleteLater/CMakeLists.txt b/tests/auto/testlib/selftests/deleteLater/CMakeLists.txt
new file mode 100644
index 0000000000..e07f87a111
--- /dev/null
+++ b/tests/auto/testlib/selftests/deleteLater/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_deleteLater SOURCES tst_deleteLater.cpp)
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..cd2818e2f7
--- /dev/null
+++ b/tests/auto/testlib/selftests/deleteLater_noApp/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_deleteLater_noApp SOURCES tst_deleteLater_noApp.cpp)
diff --git a/tests/auto/testlib/selftests/differentexec/CMakeLists.txt b/tests/auto/testlib/selftests/differentexec/CMakeLists.txt
new file mode 100644
index 0000000000..9dd4fb2e89
--- /dev/null
+++ b/tests/auto/testlib/selftests/differentexec/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(differentexec SOURCES tst_differentexec.cpp)
diff --git a/tests/auto/testlib/selftests/expectfail/CMakeLists.txt b/tests/auto/testlib/selftests/expectfail/CMakeLists.txt
new file mode 100644
index 0000000000..72dd051b7c
--- /dev/null
+++ b/tests/auto/testlib/selftests/expectfail/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(expectfail SOURCES tst_expectfail.cpp)
diff --git a/tests/auto/testlib/selftests/failcleanup/CMakeLists.txt b/tests/auto/testlib/selftests/failcleanup/CMakeLists.txt
new file mode 100644
index 0000000000..d6dae7593f
--- /dev/null
+++ b/tests/auto/testlib/selftests/failcleanup/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(failcleanup SOURCES tst_failcleanup.cpp)
diff --git a/tests/auto/testlib/selftests/failinit/CMakeLists.txt b/tests/auto/testlib/selftests/failinit/CMakeLists.txt
new file mode 100644
index 0000000000..11c0cacf7f
--- /dev/null
+++ b/tests/auto/testlib/selftests/failinit/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(failinit SOURCES tst_failinit.cpp)
diff --git a/tests/auto/testlib/selftests/failinitdata/CMakeLists.txt b/tests/auto/testlib/selftests/failinitdata/CMakeLists.txt
new file mode 100644
index 0000000000..ac7f01423e
--- /dev/null
+++ b/tests/auto/testlib/selftests/failinitdata/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(failinitdata SOURCES tst_failinitdata.cpp)
diff --git a/tests/auto/testlib/selftests/fetchbogus/CMakeLists.txt b/tests/auto/testlib/selftests/fetchbogus/CMakeLists.txt
new file mode 100644
index 0000000000..854f63ec20
--- /dev/null
+++ b/tests/auto/testlib/selftests/fetchbogus/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(fetchbogus SOURCES tst_fetchbogus.cpp)
diff --git a/tests/auto/testlib/selftests/float/CMakeLists.txt b/tests/auto/testlib/selftests/float/CMakeLists.txt
new file mode 100644
index 0000000000..6068aa3a1e
--- /dev/null
+++ b/tests/auto/testlib/selftests/float/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(float SOURCES tst_float.cpp)
diff --git a/tests/auto/testlib/selftests/globaldata/CMakeLists.txt b/tests/auto/testlib/selftests/globaldata/CMakeLists.txt
new file mode 100644
index 0000000000..2722788c8e
--- /dev/null
+++ b/tests/auto/testlib/selftests/globaldata/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(globaldata SOURCES tst_globaldata.cpp)
diff --git a/tests/auto/testlib/selftests/longstring/CMakeLists.txt b/tests/auto/testlib/selftests/longstring/CMakeLists.txt
new file mode 100644
index 0000000000..56912b6cd1
--- /dev/null
+++ b/tests/auto/testlib/selftests/longstring/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(longstring SOURCES tst_longstring.cpp)
diff --git a/tests/auto/testlib/selftests/maxwarnings/CMakeLists.txt b/tests/auto/testlib/selftests/maxwarnings/CMakeLists.txt
new file mode 100644
index 0000000000..c9077b32b0
--- /dev/null
+++ b/tests/auto/testlib/selftests/maxwarnings/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(maxwarnings SOURCES maxwarnings.cpp)
diff --git a/tests/auto/testlib/selftests/multiexec/CMakeLists.txt b/tests/auto/testlib/selftests/multiexec/CMakeLists.txt
new file mode 100644
index 0000000000..bee72b2b17
--- /dev/null
+++ b/tests/auto/testlib/selftests/multiexec/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(multiexec SOURCES tst_multiexec.cpp)
diff --git a/tests/auto/testlib/selftests/pairdiagnostics/CMakeLists.txt b/tests/auto/testlib/selftests/pairdiagnostics/CMakeLists.txt
new file mode 100644
index 0000000000..677be5403a
--- /dev/null
+++ b/tests/auto/testlib/selftests/pairdiagnostics/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(pairdiagnostics SOURCES tst_pairdiagnostics.cpp)
diff --git a/tests/auto/testlib/selftests/printdatatags/CMakeLists.txt b/tests/auto/testlib/selftests/printdatatags/CMakeLists.txt
new file mode 100644
index 0000000000..778dcc184f
--- /dev/null
+++ b/tests/auto/testlib/selftests/printdatatags/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(printdatatags SOURCES tst_printdatatags.cpp)
diff --git a/tests/auto/testlib/selftests/printdatatagswithglobaltags/CMakeLists.txt b/tests/auto/testlib/selftests/printdatatagswithglobaltags/CMakeLists.txt
new file mode 100644
index 0000000000..0942ed15d4
--- /dev/null
+++ b/tests/auto/testlib/selftests/printdatatagswithglobaltags/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(printdatatagswithglobaltags SOURCES tst_printdatatagswithglobaltags.cpp)
diff --git a/tests/auto/testlib/selftests/qexecstringlist/CMakeLists.txt b/tests/auto/testlib/selftests/qexecstringlist/CMakeLists.txt
new file mode 100644
index 0000000000..6429b5f531
--- /dev/null
+++ b/tests/auto/testlib/selftests/qexecstringlist/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(qexecstringlist SOURCES tst_qexecstringlist.cpp)
diff --git a/tests/auto/testlib/selftests/singleskip/CMakeLists.txt b/tests/auto/testlib/selftests/singleskip/CMakeLists.txt
new file mode 100644
index 0000000000..041b06aabb
--- /dev/null
+++ b/tests/auto/testlib/selftests/singleskip/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(singleskip SOURCES tst_singleskip.cpp)
diff --git a/tests/auto/testlib/selftests/skip/CMakeLists.txt b/tests/auto/testlib/selftests/skip/CMakeLists.txt
new file mode 100644
index 0000000000..974020cdbc
--- /dev/null
+++ b/tests/auto/testlib/selftests/skip/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(skip SOURCES tst_skip.cpp)
diff --git a/tests/auto/testlib/selftests/skipcleanup/CMakeLists.txt b/tests/auto/testlib/selftests/skipcleanup/CMakeLists.txt
new file mode 100644
index 0000000000..bf8c6e7ade
--- /dev/null
+++ b/tests/auto/testlib/selftests/skipcleanup/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(skipcleanup SOURCES tst_skipcleanup.cpp)
diff --git a/tests/auto/testlib/selftests/skipinit/CMakeLists.txt b/tests/auto/testlib/selftests/skipinit/CMakeLists.txt
new file mode 100644
index 0000000000..a9eb542e1c
--- /dev/null
+++ b/tests/auto/testlib/selftests/skipinit/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(skipinit SOURCES tst_skipinit.cpp)
diff --git a/tests/auto/testlib/selftests/skipinitdata/CMakeLists.txt b/tests/auto/testlib/selftests/skipinitdata/CMakeLists.txt
new file mode 100644
index 0000000000..cc38fed14f
--- /dev/null
+++ b/tests/auto/testlib/selftests/skipinitdata/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(skipinitdata SOURCES tst_skipinitdata.cpp)
diff --git a/tests/auto/testlib/selftests/sleep/CMakeLists.txt b/tests/auto/testlib/selftests/sleep/CMakeLists.txt
new file mode 100644
index 0000000000..49c5e97ac2
--- /dev/null
+++ b/tests/auto/testlib/selftests/sleep/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(sleep SOURCES tst_sleep.cpp)
diff --git a/tests/auto/testlib/selftests/strcmp/CMakeLists.txt b/tests/auto/testlib/selftests/strcmp/CMakeLists.txt
new file mode 100644
index 0000000000..cb50518af2
--- /dev/null
+++ b/tests/auto/testlib/selftests/strcmp/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(strcmp SOURCES tst_strcmp.cpp)
diff --git a/tests/auto/testlib/selftests/subtest/CMakeLists.txt b/tests/auto/testlib/selftests/subtest/CMakeLists.txt
new file mode 100644
index 0000000000..434fd88563
--- /dev/null
+++ b/tests/auto/testlib/selftests/subtest/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(subtest SOURCES tst_subtest.cpp)
diff --git a/tests/auto/testlib/selftests/tuplediagnostics/CMakeLists.txt b/tests/auto/testlib/selftests/tuplediagnostics/CMakeLists.txt
new file mode 100644
index 0000000000..1dfe64c642
--- /dev/null
+++ b/tests/auto/testlib/selftests/tuplediagnostics/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tuplediagnostics SOURCES tst_tuplediagnostics.cpp)
diff --git a/tests/auto/testlib/selftests/warnings/CMakeLists.txt b/tests/auto/testlib/selftests/warnings/CMakeLists.txt
new file mode 100644
index 0000000000..35f53f2822
--- /dev/null
+++ b/tests/auto/testlib/selftests/warnings/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(warnings SOURCES tst_warnings.cpp)
diff --git a/tests/auto/testlib/selftests/xunit/CMakeLists.txt b/tests/auto/testlib/selftests/xunit/CMakeLists.txt
new file mode 100644
index 0000000000..8c151ab1ac
--- /dev/null
+++ b/tests/auto/testlib/selftests/xunit/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(xunit SOURCES tst_xunit.cpp)
diff --git a/tests/auto/tools/qdbusxml2cpp/CMakeLists.txt b/tests/auto/tools/qdbusxml2cpp/CMakeLists.txt
new file mode 100644
index 0000000000..c6dbbcdc3a
--- /dev/null
+++ b/tests/auto/tools/qdbusxml2cpp/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_qdbusxml2cpp SOURCES tst_qdbusxml2cpp.cpp)
diff --git a/tests/auto/tools/uic/CMakeLists.txt b/tests/auto/tools/uic/CMakeLists.txt
new file mode 100644
index 0000000000..22d43d9868
--- /dev/null
+++ b/tests/auto/tools/uic/CMakeLists.txt
@@ -0,0 +1 @@
+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..c025189fd5
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qcolordialog/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qcolordialog" SOURCES tst_qcolordialog.cpp LIBRARIES 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..1164e9ed6a
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qdialog/CMakeLists.txt
@@ -0,0 +1,8 @@
+add_qt_test("tst_qdialog"
+ SOURCES
+ tst_qdialog.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::GuiPrivate
+ Qt::CorePrivate
+)
diff --git a/tests/auto/widgets/dialogs/qerrormessage/CMakeLists.txt b/tests/auto/widgets/dialogs/qerrormessage/CMakeLists.txt
new file mode 100644
index 0000000000..f1b03de367
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qerrormessage/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qerrormessage" SOURCES tst_qerrormessage.cpp LIBRARIES Qt::Widgets)
diff --git a/tests/auto/widgets/dialogs/qfiledialog/CMakeLists.txt b/tests/auto/widgets/dialogs/qfiledialog/CMakeLists.txt
new file mode 100644
index 0000000000..7c22f8fa7b
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qfiledialog/CMakeLists.txt
@@ -0,0 +1,9 @@
+add_qt_test("tst_qfiledialog"
+ SOURCES tst_qfiledialog.cpp
+ DEFINES SRCDIR="${CMAKE_CURRENT_SOURCE_DIR}/"
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+
diff --git a/tests/auto/widgets/dialogs/qfiledialog2/CMakeLists.txt b/tests/auto/widgets/dialogs/qfiledialog2/CMakeLists.txt
new file mode 100644
index 0000000000..7bf7b09de1
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qfiledialog2/CMakeLists.txt
@@ -0,0 +1,10 @@
+add_qt_test("tst_qfiledialog2"
+ SOURCES
+ tst_qfiledialog2.cpp
+ DEFINES
+ SRCDIR="${CMAKE_CURRENT_SOURCE_DIR}/"
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
diff --git a/tests/auto/widgets/dialogs/qfilesystemmodel/CMakeLists.txt b/tests/auto/widgets/dialogs/qfilesystemmodel/CMakeLists.txt
new file mode 100644
index 0000000000..336ce4ca15
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qfilesystemmodel/CMakeLists.txt
@@ -0,0 +1,31 @@
+# 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::Core
+ Qt::Widgets
+)
+
+#### Keys ignored in scope 1:.:.:qfilesystemmodel.pro:<TRUE>:
+# CONFIG = "testcase"
+
+## 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..099fee7a51
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qfontdialog/CMakeLists.txt
@@ -0,0 +1,9 @@
+add_qt_test("tst_qfontdialog"
+ SOURCES
+ testfonts.qrc
+ tst_qfontdialog.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
diff --git a/tests/auto/widgets/dialogs/qinputdialog/CMakeLists.txt b/tests/auto/widgets/dialogs/qinputdialog/CMakeLists.txt
new file mode 100644
index 0000000000..4abe554291
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qinputdialog/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qinputdialog" SOURCES tst_qinputdialog.cpp LIBRARIES Qt::WidgetsPrivate)
diff --git a/tests/auto/widgets/dialogs/qmessagebox/CMakeLists.txt b/tests/auto/widgets/dialogs/qmessagebox/CMakeLists.txt
new file mode 100644
index 0000000000..785a1a0184
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qmessagebox/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qmessagebox" SOURCES tst_qmessagebox.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::CorePrivate
+ Qt::Widgets
+)
diff --git a/tests/auto/widgets/dialogs/qprogressdialog/CMakeLists.txt b/tests/auto/widgets/dialogs/qprogressdialog/CMakeLists.txt
new file mode 100644
index 0000000000..894f2ab37e
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qprogressdialog/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qprogressdialog" SOURCES tst_qprogressdialog.cpp LIBRARIES 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..6f92dc58fc
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qsidebar/CMakeLists.txt
@@ -0,0 +1,5 @@
+add_qt_test("tst_qsidebar" SOURCES tst_qsidebar.cpp
+ LIBRARIES
+ Qt::CorePrivate
+ Qt::WidgetsPrivate
+)
diff --git a/tests/auto/widgets/dialogs/qwizard/CMakeLists.txt b/tests/auto/widgets/dialogs/qwizard/CMakeLists.txt
new file mode 100644
index 0000000000..3d88e2cb69
--- /dev/null
+++ b/tests/auto/widgets/dialogs/qwizard/CMakeLists.txt
@@ -0,0 +1,8 @@
+add_qt_test("tst_qwizard"
+ SOURCES
+ qwizard.qrc
+ tst_qwizard.cpp
+ tst_qwizard_2.cpp
+ LIBRARIES
+ Qt::Widgets
+)
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..e3388bba73
--- /dev/null
+++ b/tests/auto/widgets/effects/qgraphicseffect/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qgraphicseffect" SOURCES tst_qgraphicseffect.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
diff --git a/tests/auto/widgets/effects/qpixmapfilter/CMakeLists.txt b/tests/auto/widgets/effects/qpixmapfilter/CMakeLists.txt
new file mode 100644
index 0000000000..5d7df75bac
--- /dev/null
+++ b/tests/auto/widgets/effects/qpixmapfilter/CMakeLists.txt
@@ -0,0 +1,5 @@
+add_qt_test("tst_qpixmapfilter" SOURCES tst_qpixmapfilter.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::GuiPrivate
+)
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..6e97335a9a
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsanchorlayout/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qgraphicsanchorlayout" SOURCES tst_qgraphicsanchorlayout.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicsanchorlayout1/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicsanchorlayout1/CMakeLists.txt
new file mode 100644
index 0000000000..ef52c03bc8
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsanchorlayout1/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qgraphicsanchorlayout1" SOURCES tst_qgraphicsanchorlayout1.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicseffectsource/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicseffectsource/CMakeLists.txt
new file mode 100644
index 0000000000..51add34605
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicseffectsource/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qgraphicseffectsource" SOURCES tst_qgraphicseffectsource.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicsgridlayout/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicsgridlayout/CMakeLists.txt
new file mode 100644
index 0000000000..ecb90ea557
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsgridlayout/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qgraphicsgridlayout" SOURCES tst_qgraphicsgridlayout.cpp LIBRARIES 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..e5446407ab
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsitem/CMakeLists.txt
@@ -0,0 +1,11 @@
+add_qt_test("tst_qgraphicsitem" SOURCES tst_qgraphicsitem.cpp
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::TestPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+
+extend_target("tst_qgraphicsitem" CONDITION WIN32 AND NOT WINRT LIBRARIES -luser32)
diff --git a/tests/auto/widgets/graphicsview/qgraphicsitemanimation/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicsitemanimation/CMakeLists.txt
new file mode 100644
index 0000000000..7fe81cb6ea
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsitemanimation/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qgraphicsitemanimation" SOURCES tst_qgraphicsitemanimation.cpp
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ 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..65ae39ae8f
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicslayout/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qgraphicslayout" SOURCES tst_qgraphicslayout.cpp
+ DEFINES
+ QT_USE_USING_NAMESPACE
+ LIBRARIES
+ 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..8f1e57ea47
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicslayoutitem/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qgraphicslayoutitem" SOURCES tst_qgraphicslayoutitem.cpp LIBRARIES 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..b4d4b6630a
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicslinearlayout/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qgraphicslinearlayout" SOURCES tst_qgraphicslinearlayout.cpp LIBRARIES 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..8d5d7ddfe4
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsobject/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qgraphicsobject" SOURCES tst_qgraphicsobject.cpp LIBRARIES Qt::Widgets Qt::CorePrivate)
diff --git a/tests/auto/widgets/graphicsview/qgraphicspixmapitem/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicspixmapitem/CMakeLists.txt
new file mode 100644
index 0000000000..d6c87306da
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicspixmapitem/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qgraphicspixmapitem" SOURCES tst_qgraphicspixmapitem.cpp LIBRARIES 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..df9f5c71fe
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicspolygonitem/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qgraphicspolygonitem" SOURCES tst_qgraphicspolygonitem.cpp LIBRARIES 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..0dd32c50dd
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsproxywidget/CMakeLists.txt
@@ -0,0 +1,10 @@
+add_qt_test("tst_qgraphicsproxywidget"
+ SOURCES
+ tst_qgraphicsproxywidget.cpp
+ DEFINES
+ QTEST_QPA_MOUSE_HANDLING
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicsscene/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicsscene/CMakeLists.txt
new file mode 100644
index 0000000000..e3c0ed8559
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsscene/CMakeLists.txt
@@ -0,0 +1,15 @@
+add_qt_test("tst_qgraphicsscene"
+ SOURCES
+ images.qrc
+ testdata.qrc
+ tst_qgraphicsscene.cpp
+ DEFINES
+ SRCDIR="${CMAKE_CURRENT_SOURCE_DIR}"
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
+
+extend_target("tst_qgraphicsscene" CONDITION WIN32 AND NOT WINRT LIBRARIES -luser32)
diff --git a/tests/auto/widgets/graphicsview/qgraphicssceneindex/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicssceneindex/CMakeLists.txt
new file mode 100644
index 0000000000..127e4d1d2f
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicssceneindex/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qgraphicssceneindex" SOURCES tst_qgraphicssceneindex.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicstransform/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicstransform/CMakeLists.txt
new file mode 100644
index 0000000000..638432f39e
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicstransform/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qgraphicstransform" SOURCES tst_qgraphicstransform.cpp LIBRARIES 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..9541044cfd
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicsview/CMakeLists.txt
@@ -0,0 +1,12 @@
+add_qt_test("tst_qgraphicsview"
+ SOURCES
+ tst_qgraphicsview.cpp tst_qgraphicsview.h
+ tst_qgraphicsview_2.cpp
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+)
diff --git a/tests/auto/widgets/graphicsview/qgraphicswidget/CMakeLists.txt b/tests/auto/widgets/graphicsview/qgraphicswidget/CMakeLists.txt
new file mode 100644
index 0000000000..dd84df4758
--- /dev/null
+++ b/tests/auto/widgets/graphicsview/qgraphicswidget/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qgraphicswidget" SOURCES tst_qgraphicswidget.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
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..dbabcecf8a
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qabstractitemview/CMakeLists.txt
@@ -0,0 +1,5 @@
+add_qt_test("tst_qabstractitemview" SOURCES tst_qabstractitemview.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::TestPrivate
+)
diff --git a/tests/auto/widgets/itemviews/qcolumnview/CMakeLists.txt b/tests/auto/widgets/itemviews/qcolumnview/CMakeLists.txt
new file mode 100644
index 0000000000..07ae31be61
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qcolumnview/CMakeLists.txt
@@ -0,0 +1,11 @@
+add_qt_test("tst_qcolumnview"
+ SOURCES
+ ../../../../shared/fakedirmodel.h
+ tst_qcolumnview.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::WidgetsPrivate
+ Qt::GuiPrivate
+ Qt::CorePrivate
+ Qt::TestPrivate
+)
diff --git a/tests/auto/widgets/itemviews/qdatawidgetmapper/CMakeLists.txt b/tests/auto/widgets/itemviews/qdatawidgetmapper/CMakeLists.txt
new file mode 100644
index 0000000000..ef7d9cf63e
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qdatawidgetmapper/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qdatawidgetmapper" SOURCES tst_qdatawidgetmapper.cpp LIBRARIES 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..29ffde1801
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qdirmodel/CMakeLists.txt
@@ -0,0 +1,19 @@
+add_qt_test("tst_qdirmodel"
+ SOURCES
+ ../../../../shared/emulationdetector.h
+ tst_qdirmodel.cpp
+ INCLUDE_DIRECTORIES
+ ../../../../shared/
+ LIBRARIES
+ Qt::Widgets
+)
+
+extend_target("tst_qdirmodel" CONDITION ANDROID DEFINES SRCDIR="./")
+
+extend_target("tst_qdirmodel" CONDITION NOT ANDROID
+ DEFINES SRCDIR="${CMAKE_CURRENT_SOURCE_DIR}/"
+)
+
+extend_target("tst_qdirmodel" CONDITION ANDROID AND NOT ANDROID_EMBEDDED
+ SOURCES testdata.qrc
+)
diff --git a/tests/auto/widgets/itemviews/qfileiconprovider/CMakeLists.txt b/tests/auto/widgets/itemviews/qfileiconprovider/CMakeLists.txt
new file mode 100644
index 0000000000..c1aa9a8d3f
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qfileiconprovider/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qfileiconprovider" SOURCES tst_qfileiconprovider.cpp LIBRARIES 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..512179bcca
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qheaderview/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qheaderview" SOURCES tst_qheaderview.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
diff --git a/tests/auto/widgets/itemviews/qitemdelegate/CMakeLists.txt b/tests/auto/widgets/itemviews/qitemdelegate/CMakeLists.txt
new file mode 100644
index 0000000000..70cc1a7540
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qitemdelegate/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test("tst_qitemdelegate" SOURCES tst_qitemdelegate.cpp LIBRARIES Qt::WidgetsPrivate)
+
+extend_target("tst_qitemdelegate" CONDITION WIN32 AND NOT WINRT LIBRARIES -luser32)
diff --git a/tests/auto/widgets/itemviews/qitemeditorfactory/CMakeLists.txt b/tests/auto/widgets/itemviews/qitemeditorfactory/CMakeLists.txt
new file mode 100644
index 0000000000..7100fb802f
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qitemeditorfactory/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qitemeditorfactory" SOURCES tst_qitemeditorfactory.cpp LIBRARIES 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..9b298d97f3
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qitemview/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qitemview" SOURCES tst_qitemview.cpp LIBRARIES 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..56812234c8
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qlistview/CMakeLists.txt
@@ -0,0 +1,13 @@
+add_qt_test("tst_qlistview"
+ SOURCES
+ tst_qlistview.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::TestPrivate
+)
+
+extend_target("tst_qlistview" CONDITION WIN32 AND NOT WINRT
+ LIBRARIES -luser32
+)
diff --git a/tests/auto/widgets/itemviews/qlistwidget/CMakeLists.txt b/tests/auto/widgets/itemviews/qlistwidget/CMakeLists.txt
new file mode 100644
index 0000000000..5b16aa61a6
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qlistwidget/CMakeLists.txt
@@ -0,0 +1,8 @@
+add_qt_test("tst_qlistwidget"
+ SOURCES
+ tst_qlistwidget.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
diff --git a/tests/auto/widgets/itemviews/qtableview/CMakeLists.txt b/tests/auto/widgets/itemviews/qtableview/CMakeLists.txt
new file mode 100644
index 0000000000..655d91d300
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qtableview/CMakeLists.txt
@@ -0,0 +1,7 @@
+add_qt_test("tst_qtableview" SOURCES tst_qtableview.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+)
diff --git a/tests/auto/widgets/itemviews/qtablewidget/CMakeLists.txt b/tests/auto/widgets/itemviews/qtablewidget/CMakeLists.txt
new file mode 100644
index 0000000000..f8bcef068e
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qtablewidget/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qtablewidget" SOURCES tst_qtablewidget.cpp LIBRARIES 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..582b45ef78
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qtreeview/CMakeLists.txt
@@ -0,0 +1,11 @@
+add_qt_test("tst_qtreeview"
+ SOURCES
+ ../../../../shared/fakedirmodel.h
+ tst_qtreeview.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::WidgetsPrivate
+ Qt::GuiPrivate
+ Qt::CorePrivate
+ Qt::TestPrivate
+)
diff --git a/tests/auto/widgets/itemviews/qtreewidget/CMakeLists.txt b/tests/auto/widgets/itemviews/qtreewidget/CMakeLists.txt
new file mode 100644
index 0000000000..6d180e2167
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qtreewidget/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qtreewidget" SOURCES tst_qtreewidget.cpp LIBRARIES 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..c29cb76bc8
--- /dev/null
+++ b/tests/auto/widgets/itemviews/qtreewidgetitemiterator/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qtreewidgetitemiterator" SOURCES tst_qtreewidgetitemiterator.cpp LIBRARIES Qt::Widgets)
diff --git a/tests/auto/widgets/kernel/CMakeLists.txt b/tests/auto/widgets/kernel/CMakeLists.txt
new file mode 100644
index 0000000000..046f12e014
--- /dev/null
+++ b/tests/auto/widgets/kernel/CMakeLists.txt
@@ -0,0 +1,27 @@
+# Generated from kernel.pro.
+
+add_subdirectory(qaction)
+add_subdirectory(qactiongroup)
+# add_subdirectory(qapplication) # FIXME: Enable this!
+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(OFF)
+ add_subdirectory(qsound)
+endif()
+
+if(NOT APPLE)
+ add_subdirectory(qgesturerecognizer)
+endif()
diff --git a/tests/auto/widgets/kernel/kernel.pro b/tests/auto/widgets/kernel/kernel.pro
index af85a2bd13..15fcf99765 100644
--- a/tests/auto/widgets/kernel/kernel.pro
+++ b/tests/auto/widgets/kernel/kernel.pro
@@ -20,5 +20,5 @@ SUBDIRS=\
qshortcut \
qsizepolicy
-darwin:SUBDIRS -= \ # Uses native recognizers
+darwin:SUBDIRS -= \
qgesturerecognizer \
diff --git a/tests/auto/widgets/kernel/qaction/CMakeLists.txt b/tests/auto/widgets/kernel/qaction/CMakeLists.txt
new file mode 100644
index 0000000000..8bea25a189
--- /dev/null
+++ b/tests/auto/widgets/kernel/qaction/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qaction" SOURCES tst_qaction.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::CorePrivate
+ 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..404e1bab60
--- /dev/null
+++ b/tests/auto/widgets/kernel/qactiongroup/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qactiongroup" SOURCES tst_qactiongroup.cpp LIBRARIES Qt::Widgets)
diff --git a/tests/auto/widgets/kernel/qboxlayout/CMakeLists.txt b/tests/auto/widgets/kernel/qboxlayout/CMakeLists.txt
new file mode 100644
index 0000000000..0fb220514b
--- /dev/null
+++ b/tests/auto/widgets/kernel/qboxlayout/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qboxlayout" SOURCES tst_qboxlayout.cpp LIBRARIES Qt::Widgets Qt::TestPrivate)
diff --git a/tests/auto/widgets/kernel/qdesktopwidget/CMakeLists.txt b/tests/auto/widgets/kernel/qdesktopwidget/CMakeLists.txt
new file mode 100644
index 0000000000..6cfea9d4f4
--- /dev/null
+++ b/tests/auto/widgets/kernel/qdesktopwidget/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qdesktopwidget" SOURCES tst_qdesktopwidget.cpp LIBRARIES 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..c5ef0946f9
--- /dev/null
+++ b/tests/auto/widgets/kernel/qformlayout/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qformlayout" SOURCES tst_qformlayout.cpp LIBRARIES Qt::Widgets Qt::TestPrivate)
diff --git a/tests/auto/widgets/kernel/qgesturerecognizer/CMakeLists.txt b/tests/auto/widgets/kernel/qgesturerecognizer/CMakeLists.txt
new file mode 100644
index 0000000000..fe47f9bcd6
--- /dev/null
+++ b/tests/auto/widgets/kernel/qgesturerecognizer/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qgesturerecognizer" SOURCES tst_qgesturerecognizer.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::GuiPrivate
+ Qt::CorePrivate
+)
diff --git a/tests/auto/widgets/kernel/qgridlayout/CMakeLists.txt b/tests/auto/widgets/kernel/qgridlayout/CMakeLists.txt
new file mode 100644
index 0000000000..6cfd4ab427
--- /dev/null
+++ b/tests/auto/widgets/kernel/qgridlayout/CMakeLists.txt
@@ -0,0 +1,10 @@
+add_qt_test("tst_qgridlayout"
+ SOURCES
+ sortdialog.ui
+ tst_qgridlayout.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+)
diff --git a/tests/auto/widgets/kernel/qlayout/CMakeLists.txt b/tests/auto/widgets/kernel/qlayout/CMakeLists.txt
new file mode 100644
index 0000000000..a9b80c1287
--- /dev/null
+++ b/tests/auto/widgets/kernel/qlayout/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test("tst_qlayout" SOURCES tst_qlayout.cpp LIBRARIES Qt::WidgetsPrivate Qt::TestPrivate)
+
+extend_target("tst_qlayout" CONDITION ANDROID AND NOT ANDROID_EMBEDDED SOURCES testdata.qrc)
diff --git a/tests/auto/widgets/kernel/qshortcut/CMakeLists.txt b/tests/auto/widgets/kernel/qshortcut/CMakeLists.txt
new file mode 100644
index 0000000000..d71f1aae6c
--- /dev/null
+++ b/tests/auto/widgets/kernel/qshortcut/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qshortcut" SOURCES tst_qshortcut.cpp LIBRARIES 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..32b17c8bba
--- /dev/null
+++ b/tests/auto/widgets/kernel/qsizepolicy/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qsizepolicy" SOURCES tst_qsizepolicy.cpp LIBRARIES Qt::WidgetsPrivate)
diff --git a/tests/auto/widgets/kernel/qstackedlayout/CMakeLists.txt b/tests/auto/widgets/kernel/qstackedlayout/CMakeLists.txt
new file mode 100644
index 0000000000..24c681dc45
--- /dev/null
+++ b/tests/auto/widgets/kernel/qstackedlayout/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qstackedlayout" SOURCES tst_qstackedlayout.cpp LIBRARIES 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..e5cdace275
--- /dev/null
+++ b/tests/auto/widgets/kernel/qtooltip/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qtooltip" SOURCES tst_qtooltip.cpp LIBRARIES 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..3bafe782d6
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwidget/CMakeLists.txt
@@ -0,0 +1,16 @@
+add_qt_test("tst_qwidget"
+ SOURCES
+ qwidget.qrc
+ tst_qwidget.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::WidgetsPrivate
+ Qt::TestPrivate
+)
+
+extend_target("tst_qwidget" CONDITION APPLE_OSX
+ SOURCES tst_qwidget_mac_helpers.mm
+ LIBRARIES ${FWSecurity} ${FWAppKit}
+)
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..9d16c40be4
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwidget_window/CMakeLists.txt
@@ -0,0 +1,7 @@
+add_qt_test("tst_qwidget_window" SOURCES tst_qwidget_window.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::CorePrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+)
diff --git a/tests/auto/widgets/kernel/qwidgetaction/CMakeLists.txt b/tests/auto/widgets/kernel/qwidgetaction/CMakeLists.txt
new file mode 100644
index 0000000000..d58853790e
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwidgetaction/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qwidgetaction" SOURCES tst_qwidgetaction.cpp LIBRARIES Qt::Widgets Qt::TestPrivate)
diff --git a/tests/auto/widgets/kernel/qwidgetmetatype/CMakeLists.txt b/tests/auto/widgets/kernel/qwidgetmetatype/CMakeLists.txt
new file mode 100644
index 0000000000..ab69449fba
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwidgetmetatype/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qwidgetmetatype" SOURCES tst_qwidgetmetatype.cpp LIBRARIES 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..53a479ef80
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwidgetsvariant/CMakeLists.txt
@@ -0,0 +1,8 @@
+add_qt_test("tst_qwidgetsvariant"
+ SOURCES
+ tst_qwidgetsvariant.cpp
+ INCLUDE_DIRECTORIES
+ ./../../../other/qvariant_common
+ LIBRARIES
+ 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..329260bd05
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwindowcontainer/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qwindowcontainer" SOURCES tst_qwindowcontainer.cpp LIBRARIES 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..a1b68b3d74
--- /dev/null
+++ b/tests/auto/widgets/styles/qmacstyle/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qmacstyle" SOURCES tst_qmacstyle.cpp LIBRARIES Qt::WidgetsPrivate)
diff --git a/tests/auto/widgets/styles/qstyle/CMakeLists.txt b/tests/auto/widgets/styles/qstyle/CMakeLists.txt
new file mode 100644
index 0000000000..b6af379092
--- /dev/null
+++ b/tests/auto/widgets/styles/qstyle/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test("tst_qstyle" SOURCES tst_qstyle.cpp LIBRARIES Qt::Widgets Qt::TestPrivate)
+
+extend_target("tst_qstyle" CONDITION ANDROID AND NOT ANDROID_EMBEDDED SOURCES testdata.qrc)
diff --git a/tests/auto/widgets/styles/qstyleoption/CMakeLists.txt b/tests/auto/widgets/styles/qstyleoption/CMakeLists.txt
new file mode 100644
index 0000000000..855336b769
--- /dev/null
+++ b/tests/auto/widgets/styles/qstyleoption/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qstyleoption" SOURCES tst_qstyleoption.cpp LIBRARIES Qt::Widgets)
diff --git a/tests/auto/widgets/styles/qstylesheetstyle/CMakeLists.txt b/tests/auto/widgets/styles/qstylesheetstyle/CMakeLists.txt
new file mode 100644
index 0000000000..608b7d299b
--- /dev/null
+++ b/tests/auto/widgets/styles/qstylesheetstyle/CMakeLists.txt
@@ -0,0 +1,9 @@
+add_qt_test("tst_qstylesheetstyle"
+ SOURCES
+ resources.qrc
+ tst_qstylesheetstyle.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::GuiPrivate
+ Qt::TestPrivate
+)
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..15b01f0346
--- /dev/null
+++ b/tests/auto/widgets/util/qcompleter/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qcompleter" SOURCES tst_qcompleter.cpp LIBRARIES Qt::Widgets Qt::TestPrivate)
diff --git a/tests/auto/widgets/util/qscroller/CMakeLists.txt b/tests/auto/widgets/util/qscroller/CMakeLists.txt
new file mode 100644
index 0000000000..006399652c
--- /dev/null
+++ b/tests/auto/widgets/util/qscroller/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qscroller" SOURCES tst_qscroller.cpp LIBRARIES Qt::Widgets Qt::GuiPrivate)
diff --git a/tests/auto/widgets/util/qsystemtrayicon/CMakeLists.txt b/tests/auto/widgets/util/qsystemtrayicon/CMakeLists.txt
new file mode 100644
index 0000000000..2b609725a1
--- /dev/null
+++ b/tests/auto/widgets/util/qsystemtrayicon/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qsystemtrayicon" SOURCES tst_qsystemtrayicon.cpp LIBRARIES 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..9c67f61c51
--- /dev/null
+++ b/tests/auto/widgets/util/qundogroup/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qundogroup" SOURCES tst_qundogroup.cpp LIBRARIES 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..690bcdacfd
--- /dev/null
+++ b/tests/auto/widgets/util/qundostack/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qundostack" SOURCES tst_qundostack.cpp LIBRARIES 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..7b2123b530
--- /dev/null
+++ b/tests/auto/widgets/widgets/qabstractbutton/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qabstractbutton" RUN_SERIAL SOURCES tst_qabstractbutton.cpp LIBRARIES 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..a003346393
--- /dev/null
+++ b/tests/auto/widgets/widgets/qabstractscrollarea/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qabstractscrollarea" RUN_SERIAL SOURCES tst_qabstractscrollarea.cpp LIBRARIES 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..6974ae4172
--- /dev/null
+++ b/tests/auto/widgets/widgets/qabstractslider/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qabstractslider" RUN_SERIAL SOURCES tst_qabstractslider.cpp LIBRARIES Qt::Widgets Qt::TestPrivate)
diff --git a/tests/auto/widgets/widgets/qabstractspinbox/CMakeLists.txt b/tests/auto/widgets/widgets/qabstractspinbox/CMakeLists.txt
new file mode 100644
index 0000000000..88c69d370b
--- /dev/null
+++ b/tests/auto/widgets/widgets/qabstractspinbox/CMakeLists.txt
@@ -0,0 +1,7 @@
+add_qt_test("tst_qabstractspinbox" RUN_SERIAL SOURCES tst_qabstractspinbox.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::GuiPrivate
+ Qt::CorePrivate
+ Qt::TestPrivate
+)
diff --git a/tests/auto/widgets/widgets/qbuttongroup/CMakeLists.txt b/tests/auto/widgets/widgets/qbuttongroup/CMakeLists.txt
new file mode 100644
index 0000000000..37b2196705
--- /dev/null
+++ b/tests/auto/widgets/widgets/qbuttongroup/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qbuttongroup" RUN_SERIAL SOURCES tst_qbuttongroup.cpp LIBRARIES 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..4aad3abff9
--- /dev/null
+++ b/tests/auto/widgets/widgets/qcalendarwidget/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qcalendarwidget" RUN_SERIAL SOURCES tst_qcalendarwidget.cpp LIBRARIES 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..2640889d94
--- /dev/null
+++ b/tests/auto/widgets/widgets/qcheckbox/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qcheckbox" RUN_SERIAL SOURCES tst_qcheckbox.cpp LIBRARIES 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..8697a67820
--- /dev/null
+++ b/tests/auto/widgets/widgets/qcombobox/CMakeLists.txt
@@ -0,0 +1,8 @@
+add_qt_test("tst_qcombobox" RUN_SERIAL SOURCES tst_qcombobox.cpp
+ DEFINES QTEST_QPA_MOUSE_HANDLING
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::GuiPrivate
+ Qt::CorePrivate
+ Qt::TestPrivate
+)
diff --git a/tests/auto/widgets/widgets/qcommandlinkbutton/CMakeLists.txt b/tests/auto/widgets/widgets/qcommandlinkbutton/CMakeLists.txt
new file mode 100644
index 0000000000..2893e2d0f3
--- /dev/null
+++ b/tests/auto/widgets/widgets/qcommandlinkbutton/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qcommandlinkbutton" RUN_SERIAL SOURCES tst_qcommandlinkbutton.cpp LIBRARIES 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..1f977399ac
--- /dev/null
+++ b/tests/auto/widgets/widgets/qdatetimeedit/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qdatetimeedit" RUN_SERIAL SOURCES tst_qdatetimeedit.cpp
+ LIBRARIES
+ Qt::Widgets
+ Qt::CorePrivate
+ Qt::WidgetsPrivate
+)
diff --git a/tests/auto/widgets/widgets/qdial/CMakeLists.txt b/tests/auto/widgets/widgets/qdial/CMakeLists.txt
new file mode 100644
index 0000000000..76fc75d85a
--- /dev/null
+++ b/tests/auto/widgets/widgets/qdial/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qdial" RUN_SERIAL SOURCES tst_qdial.cpp LIBRARIES 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..032189307c
--- /dev/null
+++ b/tests/auto/widgets/widgets/qdialogbuttonbox/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qdialogbuttonbox" RUN_SERIAL SOURCES tst_qdialogbuttonbox.cpp LIBRARIES 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..4bbe5234d9
--- /dev/null
+++ b/tests/auto/widgets/widgets/qdockwidget/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qdockwidget" RUN_SERIAL SOURCES tst_qdockwidget.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
diff --git a/tests/auto/widgets/widgets/qdoublespinbox/CMakeLists.txt b/tests/auto/widgets/widgets/qdoublespinbox/CMakeLists.txt
new file mode 100644
index 0000000000..8030b82b42
--- /dev/null
+++ b/tests/auto/widgets/widgets/qdoublespinbox/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qdoublespinbox" RUN_SERIAL SOURCES tst_qdoublespinbox.cpp LIBRARIES 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..1aac33f254
--- /dev/null
+++ b/tests/auto/widgets/widgets/qfocusframe/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qfocusframe" RUN_SERIAL SOURCES tst_qfocusframe.cpp LIBRARIES 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..6bb659cca2
--- /dev/null
+++ b/tests/auto/widgets/widgets/qfontcombobox/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qfontcombobox" RUN_SERIAL SOURCES tst_qfontcombobox.cpp LIBRARIES 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..f109c76d0d
--- /dev/null
+++ b/tests/auto/widgets/widgets/qframe/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qframe" RUN_SERIAL SOURCES tst_qframe.cpp LIBRARIES Qt::Widgets)
diff --git a/tests/auto/widgets/widgets/qgroupbox/CMakeLists.txt b/tests/auto/widgets/widgets/qgroupbox/CMakeLists.txt
new file mode 100644
index 0000000000..5885420d31
--- /dev/null
+++ b/tests/auto/widgets/widgets/qgroupbox/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qgroupbox" RUN_SERIAL SOURCES tst_qgroupbox.cpp LIBRARIES 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..415b49dd1b
--- /dev/null
+++ b/tests/auto/widgets/widgets/qkeysequenceedit/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qkeysequenceedit" RUN_SERIAL SOURCES tst_qkeysequenceedit.cpp LIBRARIES 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..91ce86552a
--- /dev/null
+++ b/tests/auto/widgets/widgets/qlabel/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qlabel" RUN_SERIAL SOURCES tst_qlabel.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::CorePrivate
+ Qt::GuiPrivate
+)
diff --git a/tests/auto/widgets/widgets/qlcdnumber/CMakeLists.txt b/tests/auto/widgets/widgets/qlcdnumber/CMakeLists.txt
new file mode 100644
index 0000000000..4f748f0ae8
--- /dev/null
+++ b/tests/auto/widgets/widgets/qlcdnumber/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qlcdnumber" RUN_SERIAL SOURCES tst_qlcdnumber.cpp LIBRARIES 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..00e0c1d575
--- /dev/null
+++ b/tests/auto/widgets/widgets/qlineedit/CMakeLists.txt
@@ -0,0 +1,9 @@
+add_qt_test("tst_qlineedit" RUN_SERIAL SOURCES tst_qlineedit.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::CorePrivate
+ Qt::WidgetsPrivate
+ Qt::TestPrivate
+)
+
+extend_target("tst_qlineedit" CONDITION APPLE_OSX 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..f1756bd342
--- /dev/null
+++ b/tests/auto/widgets/widgets/qmainwindow/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qmainwindow" RUN_SERIAL SOURCES tst_qmainwindow.cpp LIBRARIES Qt::WidgetsPrivate)
diff --git a/tests/auto/widgets/widgets/qmdiarea/CMakeLists.txt b/tests/auto/widgets/widgets/qmdiarea/CMakeLists.txt
new file mode 100644
index 0000000000..0f32c0ebce
--- /dev/null
+++ b/tests/auto/widgets/widgets/qmdiarea/CMakeLists.txt
@@ -0,0 +1,11 @@
+add_qt_test("tst_qmdiarea" RUN_SERIAL SOURCES tst_qmdiarea.cpp
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::Widgets
+)
+
+extend_target("tst_qmdiarea" CONDITION TARGET Qt::OpenGL LIBRARIES Qt::OpenGL)
+extend_target("tst_qmdiarea" CONDITION APPLE_OSX 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..c095ccebd0
--- /dev/null
+++ b/tests/auto/widgets/widgets/qmdisubwindow/CMakeLists.txt
@@ -0,0 +1,7 @@
+add_qt_test("tst_qmdisubwindow" RUN_SERIAL SOURCES tst_qmdisubwindow.cpp
+ DEFINES
+ QT_NO_CAST_TO_ASCII
+ QT_NO_CAST_FROM_ASCII
+ LIBRARIES
+ Qt::WidgetsPrivate
+)
diff --git a/tests/auto/widgets/widgets/qmenu/CMakeLists.txt b/tests/auto/widgets/widgets/qmenu/CMakeLists.txt
new file mode 100644
index 0000000000..6e9da6d474
--- /dev/null
+++ b/tests/auto/widgets/widgets/qmenu/CMakeLists.txt
@@ -0,0 +1,13 @@
+add_qt_test("tst_qmenu" RUN_SERIAL SOURCES tst_qmenu.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::Widgets
+ Qt::TestPrivate
+)
+
+extend_target("tst_qmenu" CONDITION APPLE_OSX
+ SOURCES tst_qmenu_mac.mm
+ LIBRARIES -lobjc
+)
+
+extend_target("tst_qmenu" CONDITION NOT APPLEL_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..3fb1c5ccb1
--- /dev/null
+++ b/tests/auto/widgets/widgets/qmenubar/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qmenubar" RUN_SERIAL SOURCES tst_qmenubar.cpp LIBRARIES Qt::Widgets Qt::TestPrivate)
+
+extend_target("tst_qmenubar" CONDITION APPLE_OSX
+ SOURCES tst_qmenubar_mac.mm
+ 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..a9172dec4f
--- /dev/null
+++ b/tests/auto/widgets/widgets/qopenglwidget/CMakeLists.txt
@@ -0,0 +1,6 @@
+add_qt_test("tst_qopenglwidget" RUN_SERIAL SOURCES tst_qopenglwidget.cpp
+ LIBRARIES
+ Qt::GuiPrivate
+ Qt::CorePrivate
+ 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..f3a9a9ab90
--- /dev/null
+++ b/tests/auto/widgets/widgets/qplaintextedit/CMakeLists.txt
@@ -0,0 +1,7 @@
+add_qt_test("tst_qplaintextedit" RUN_SERIAL SOURCES tst_qplaintextedit.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::GuiPrivate
+)
+
+extend_target("tst_qplaintextedit" CONDITION APPLE_OSX 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..5fb9e79056
--- /dev/null
+++ b/tests/auto/widgets/widgets/qprogressbar/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qprogressbar" RUN_SERIAL SOURCES tst_qprogressbar.cpp LIBRARIES 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..7b78b96844
--- /dev/null
+++ b/tests/auto/widgets/widgets/qpushbutton/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qpushbutton" RUN_SERIAL SOURCES tst_qpushbutton.cpp LIBRARIES 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..08322899a2
--- /dev/null
+++ b/tests/auto/widgets/widgets/qradiobutton/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qradiobutton" RUN_SERIAL SOURCES tst_qradiobutton.cpp LIBRARIES 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..b21a9755d4
--- /dev/null
+++ b/tests/auto/widgets/widgets/qscrollarea/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qscrollarea" RUN_SERIAL SOURCES tst_qscrollarea.cpp LIBRARIES 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..88163f38c3
--- /dev/null
+++ b/tests/auto/widgets/widgets/qscrollbar/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qscrollbar" RUN_SERIAL SOURCES tst_qscrollbar.cpp LIBRARIES Qt::Widgets Qt::TestPrivate)
diff --git a/tests/auto/widgets/widgets/qsizegrip/CMakeLists.txt b/tests/auto/widgets/widgets/qsizegrip/CMakeLists.txt
new file mode 100644
index 0000000000..f3f6548774
--- /dev/null
+++ b/tests/auto/widgets/widgets/qsizegrip/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qsizegrip" RUN_SERIAL SOURCES tst_qsizegrip.cpp LIBRARIES 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..1da3dc0d0a
--- /dev/null
+++ b/tests/auto/widgets/widgets/qslider/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qslider" RUN_SERIAL SOURCES tst_qslider.cpp LIBRARIES 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..80f1de0702
--- /dev/null
+++ b/tests/auto/widgets/widgets/qspinbox/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qspinbox" RUN_SERIAL SOURCES tst_qspinbox.cpp LIBRARIES 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..028d8fc82e
--- /dev/null
+++ b/tests/auto/widgets/widgets/qsplashscreen/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qsplashscreen" RUN_SERIAL SOURCES tst_qsplashscreen.cpp LIBRARIES 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..a0dfd3a9c5
--- /dev/null
+++ b/tests/auto/widgets/widgets/qsplitter/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qsplitter" RUN_SERIAL SOURCES tst_qsplitter.cpp LIBRARIES Qt::Widgets)
diff --git a/tests/auto/widgets/widgets/qstackedwidget/CMakeLists.txt b/tests/auto/widgets/widgets/qstackedwidget/CMakeLists.txt
new file mode 100644
index 0000000000..8b2b79b181
--- /dev/null
+++ b/tests/auto/widgets/widgets/qstackedwidget/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qstackedwidget" RUN_SERIAL SOURCES tst_qstackedwidget.cpp LIBRARIES 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..ba65925b6e
--- /dev/null
+++ b/tests/auto/widgets/widgets/qstatusbar/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qstatusbar" RUN_SERIAL SOURCES tst_qstatusbar.cpp LIBRARIES 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..003d4a778b
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtabbar/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qtabbar" RUN_SERIAL SOURCES tst_qtabbar.cpp LIBRARIES 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..440603fac4
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtabwidget/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test("tst_qtabwidget" RUN_SERIAL SOURCES tst_qtabwidget.cpp LIBRARIES Qt::WidgetsPrivate)
+
+extend_target("tst_qtabwidget" CONDITION WIN32 AND NOT WINRT LIBRARIES -luser32)
diff --git a/tests/auto/widgets/widgets/qtextbrowser/CMakeLists.txt b/tests/auto/widgets/widgets/qtextbrowser/CMakeLists.txt
new file mode 100644
index 0000000000..15601c9855
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtextbrowser/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test("tst_qtextbrowser" RUN_SERIAL SOURCES tst_qtextbrowser.cpp LIBRARIES Qt::Widgets)
+
+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..1a8e79e055
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtextedit/CMakeLists.txt
@@ -0,0 +1,8 @@
+add_qt_test("tst_qtextedit" RUN_SERIAL SOURCES tst_qtextedit.cpp
+ LIBRARIES
+ Qt::WidgetsPrivate
+ Qt::GuiPrivate
+ Qt::CorePrivate
+)
+
+extend_target("tst_qtextedit" CONDITION APPLE_OSX 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..ab6d4d082a
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtoolbar/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qtoolbar" RUN_SERIAL SOURCES tst_qtoolbar.cpp LIBRARIES Qt::WidgetsPrivate Qt::GuiPrivate)
diff --git a/tests/auto/widgets/widgets/qtoolbox/CMakeLists.txt b/tests/auto/widgets/widgets/qtoolbox/CMakeLists.txt
new file mode 100644
index 0000000000..337f187878
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtoolbox/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qtoolbox" RUN_SERIAL SOURCES tst_qtoolbox.cpp LIBRARIES 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..a253255617
--- /dev/null
+++ b/tests/auto/widgets/widgets/qtoolbutton/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test("tst_qtoolbutton" RUN_SERIAL SOURCES tst_qtoolbutton.cpp LIBRARIES Qt::Widgets)
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..bcb10365fa
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qdir/10000/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qdir_10000 SOURCES bench_qdir_10000.cpp)
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..a6c5ceebd3
--- /dev/null
+++ b/tests/benchmarks/corelib/io/qprocess/test/CMakeLists.txt
@@ -0,0 +1,5 @@
+add_qt_test(../tst_bench_qprocess SOURCES
+ ../tst_bench_qprocess.cpp
+ LIBRARIES
+ Qt::CorePrivate
+)
diff --git a/tests/benchmarks/corelib/kernel/events/CMakeLists.txt b/tests/benchmarks/corelib/kernel/events/CMakeLists.txt
new file mode 100644
index 0000000000..cabe71e3d6
--- /dev/null
+++ b/tests/benchmarks/corelib/kernel/events/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_events SOURCES main.cpp)
diff --git a/tests/benchmarks/corelib/kernel/qcoreapplication/CMakeLists.txt b/tests/benchmarks/corelib/kernel/qcoreapplication/CMakeLists.txt
new file mode 100644
index 0000000000..55d68f0372
--- /dev/null
+++ b/tests/benchmarks/corelib/kernel/qcoreapplication/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qcoreapplication SOURCES main.cpp)
diff --git a/tests/benchmarks/corelib/kernel/qmetatype/CMakeLists.txt b/tests/benchmarks/corelib/kernel/qmetatype/CMakeLists.txt
new file mode 100644
index 0000000000..6bbaeee1e0
--- /dev/null
+++ b/tests/benchmarks/corelib/kernel/qmetatype/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qmetatype SOURCES tst_qmetatype.cpp)
diff --git a/tests/benchmarks/corelib/mimetypes/qmimedatabase/CMakeLists.txt b/tests/benchmarks/corelib/mimetypes/qmimedatabase/CMakeLists.txt
new file mode 100644
index 0000000000..ec0cf48255
--- /dev/null
+++ b/tests/benchmarks/corelib/mimetypes/qmimedatabase/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qmimedatabase SOURCES main.cpp)
diff --git a/tests/benchmarks/corelib/plugin/quuid/CMakeLists.txt b/tests/benchmarks/corelib/plugin/quuid/CMakeLists.txt
new file mode 100644
index 0000000000..e334bcb68a
--- /dev/null
+++ b/tests/benchmarks/corelib/plugin/quuid/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_quuid SOURCES tst_quuid.cpp)
diff --git a/tests/benchmarks/corelib/thread/qmutex/CMakeLists.txt b/tests/benchmarks/corelib/thread/qmutex/CMakeLists.txt
new file mode 100644
index 0000000000..aef0da2565
--- /dev/null
+++ b/tests/benchmarks/corelib/thread/qmutex/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qmutex SOURCES tst_qmutex.cpp)
diff --git a/tests/benchmarks/corelib/thread/qthreadpool/CMakeLists.txt b/tests/benchmarks/corelib/thread/qthreadpool/CMakeLists.txt
new file mode 100644
index 0000000000..55b03b9ad9
--- /dev/null
+++ b/tests/benchmarks/corelib/thread/qthreadpool/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qthreadpool SOURCES tst_qthreadpool.cpp)
diff --git a/tests/benchmarks/corelib/thread/qthreadstorage/CMakeLists.txt b/tests/benchmarks/corelib/thread/qthreadstorage/CMakeLists.txt
new file mode 100644
index 0000000000..0797d99625
--- /dev/null
+++ b/tests/benchmarks/corelib/thread/qthreadstorage/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qthreadstorage SOURCES tst_qthreadstorage.cpp)
diff --git a/tests/benchmarks/corelib/thread/qwaitcondition/CMakeLists.txt b/tests/benchmarks/corelib/thread/qwaitcondition/CMakeLists.txt
new file mode 100644
index 0000000000..94c4391c84
--- /dev/null
+++ b/tests/benchmarks/corelib/thread/qwaitcondition/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qwaitcondition SOURCES tst_qwaitcondition.cpp)
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..7495677c0a
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/containers-associative/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_containers-associative SOURCES main.cpp)
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..6a22402a46
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/containers-sequential/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_containers-sequential SOURCES main.cpp)
diff --git a/tests/benchmarks/corelib/tools/qalgorithms/CMakeLists.txt b/tests/benchmarks/corelib/tools/qalgorithms/CMakeLists.txt
new file mode 100644
index 0000000000..6cfb746934
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qalgorithms/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qalgorithms SOURCES tst_qalgorithms.cpp)
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/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/qlist/CMakeLists.txt b/tests/benchmarks/corelib/tools/qlist/CMakeLists.txt
new file mode 100644
index 0000000000..6e7dec7dfe
--- /dev/null
+++ b/tests/benchmarks/corelib/tools/qlist/CMakeLists.txt
@@ -0,0 +1 @@
+add_qt_test(tst_bench_qlist SOURCES main.cpp)
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/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/gui/image/blendbench/CMakeLists.txt b/tests/benchmarks/gui/image/blendbench/CMakeLists.txt
new file mode 100644
index 0000000000..24b2a79df1
--- /dev/null
+++ b/tests/benchmarks/gui/image/blendbench/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test(tst_bench_blendbench SOURCES
+ main.cpp
+)
diff --git a/tests/benchmarks/gui/image/qimagescale/CMakeLists.txt b/tests/benchmarks/gui/image/qimagescale/CMakeLists.txt
new file mode 100644
index 0000000000..58b9159eba
--- /dev/null
+++ b/tests/benchmarks/gui/image/qimagescale/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test(tst_bench_imageScale SOURCES
+ tst_qimagescale.cpp
+)
diff --git a/tests/benchmarks/gui/image/qpixmapcache/CMakeLists.txt b/tests/benchmarks/gui/image/qpixmapcache/CMakeLists.txt
new file mode 100644
index 0000000000..e2aa20d75a
--- /dev/null
+++ b/tests/benchmarks/gui/image/qpixmapcache/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test(tst_bench_qpixmapcache SOURCES
+ tst_qpixmapcache.cpp
+)
diff --git a/tests/benchmarks/gui/kernel/qguimetatype/CMakeLists.txt b/tests/benchmarks/gui/kernel/qguimetatype/CMakeLists.txt
new file mode 100644
index 0000000000..025a6d15ed
--- /dev/null
+++ b/tests/benchmarks/gui/kernel/qguimetatype/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test(tst_bench_qguimetatype SOURCES
+ tst_qguimetatype.cpp
+)
diff --git a/tests/benchmarks/gui/kernel/qguivariant/CMakeLists.txt b/tests/benchmarks/gui/kernel/qguivariant/CMakeLists.txt
new file mode 100644
index 0000000000..f25c0a17d7
--- /dev/null
+++ b/tests/benchmarks/gui/kernel/qguivariant/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test(tst_bench_qguivariant SOURCES
+ tst_qguivariant.cpp
+)
diff --git a/tests/benchmarks/gui/math3d/qmatrix4x4/CMakeLists.txt b/tests/benchmarks/gui/math3d/qmatrix4x4/CMakeLists.txt
new file mode 100644
index 0000000000..7b6525bb63
--- /dev/null
+++ b/tests/benchmarks/gui/math3d/qmatrix4x4/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test(tst_bench_qmatrix4x4 SOURCES
+ tst_qmatrix4x4.cpp
+)
diff --git a/tests/benchmarks/gui/math3d/qquaternion/CMakeLists.txt b/tests/benchmarks/gui/math3d/qquaternion/CMakeLists.txt
new file mode 100644
index 0000000000..a7ed4a2ab8
--- /dev/null
+++ b/tests/benchmarks/gui/math3d/qquaternion/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test(tst_bench_qquaternion SOURCES
+ tst_qquaternion.cpp
+)
diff --git a/tests/benchmarks/gui/painting/qtransform/CMakeLists.txt b/tests/benchmarks/gui/painting/qtransform/CMakeLists.txt
new file mode 100644
index 0000000000..9dbfe8106a
--- /dev/null
+++ b/tests/benchmarks/gui/painting/qtransform/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test(tst_bench_qtransform SOURCES
+ tst_qtransform.cpp
+)
diff --git a/tests/benchmarks/gui/text/qfontmetrics/CMakeLists.txt b/tests/benchmarks/gui/text/qfontmetrics/CMakeLists.txt
new file mode 100644
index 0000000000..44f5c09077
--- /dev/null
+++ b/tests/benchmarks/gui/text/qfontmetrics/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test(tst_bench_QFontMetrics SOURCES
+ main.cpp
+)
diff --git a/tests/manual/CMakeLists.txt b/tests/manual/CMakeLists.txt
new file mode 100644
index 0000000000..0746c0ef66
--- /dev/null
+++ b/tests/manual/CMakeLists.txt
@@ -0,0 +1,92 @@
+# Generated from tests/manual/manual.pro.
+
+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("network_remote_stresstest")
+add_subdirectory("network_stresstest")
+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("qnetworkaccessmanager/qget")
+add_subdirectory("qnetworkconfigurationmanager")
+add_subdirectory("qnetworkconfiguration")
+add_subdirectory("qnetworkreply")
+add_subdirectory("qstorageinfo")
+add_subdirectory("qscreen")
+add_subdirectory("qssloptions")
+add_subdirectory("qsslsocket")
+add_subdirectory("qsysinfo")
+add_subdirectory("qtabletevent")
+add_subdirectory("qtexteditlist")
+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")
+
+if(NOT ${QT_FEATURE_openssl})
+ ### remove_subdirectory("qssloptions")
+endif()
+
+if(${QT_FEATURE_opengl})
+ add_subdirectory("qopengltextureblitter")
+
+ if(${QT_FEATURE_egl})
+ add_subdirectory("qopenglcontext")
+ endif()
+endif()
+
+if(WIN32)
+ ### remove_subdirectory("network_remote_stresstest")
+ ### remove_subdirectory("network_stresstest")
+endif()
+
+if(lessThan(QT_MAJOR_VERSION, 5))
+ ### remove_subdirectory("bearerex")
+ ### remove_subdirectory("lance")
+ ### remove_subdirectory("qnetworkaccessmanager/qget")
+ ### remove_subdirectory("qmimedatabase")
+ ### remove_subdirectory("qnetworkreply")
+ ### remove_subdirectory("qpainfo")
+ ### remove_subdirectory("qscreen")
+ ### remove_subdirectory("socketengine")
+ ### remove_subdirectory("xembed-raster")
+ ### remove_subdirectory("xembed-widgets")
+ ### remove_subdirectory("windowtransparency")
+ ### remove_subdirectory("embeddedintoforeignwindow")
+ ### remove_subdirectory("foreignwindows")
+endif()
+
+if(${QT_FEATURE_vulkan})
+ add_subdirectory("qvulkaninstance")
+endif()
diff --git a/tests/manual/qcursor/childwindow/CMakeLists.txt b/tests/manual/qcursor/childwindow/CMakeLists.txt
new file mode 100644
index 0000000000..1f1001350b
--- /dev/null
+++ b/tests/manual/qcursor/childwindow/CMakeLists.txt
@@ -0,0 +1,5 @@
+add_qt_test(childwindow SOURCES
+ main.cpp
+ INCLUDE_DIRECTORIES
+ .
+)
diff --git a/tests/manual/qmetatype/CMakeLists.txt b/tests/manual/qmetatype/CMakeLists.txt
new file mode 100644
index 0000000000..5648a365f2
--- /dev/null
+++ b/tests/manual/qmetatype/CMakeLists.txt
@@ -0,0 +1,5 @@
+add_qt_test(tst_qmetatype_expect_fail SOURCES
+ declare_metatype_noninline.h
+ tst_qmetatype.cpp
+ declare_metatype_noninline.cpp
+)
diff --git a/tests/manual/qopenglwindow/multiwindow/CMakeLists.txt b/tests/manual/qopenglwindow/multiwindow/CMakeLists.txt
new file mode 100644
index 0000000000..96e57b502c
--- /dev/null
+++ b/tests/manual/qopenglwindow/multiwindow/CMakeLists.txt
@@ -0,0 +1,3 @@
+add_qt_test(multiwindow SOURCES
+ main.cpp
+)
diff --git a/util/cmake/Pipfile b/util/cmake/Pipfile
new file mode 100644
index 0000000000..7fbf716eb8
--- /dev/null
+++ b/util/cmake/Pipfile
@@ -0,0 +1,15 @@
+[[source]]
+url = "https://pypi.org/simple"
+verify_ssl = true
+name = "pypi"
+
+[packages]
+pytest = "*"
+mypy = "*"
+pyparsing = "*"
+sympy = "*"
+
+[dev-packages]
+
+[requires]
+python_version = "3.7"
diff --git a/util/cmake/cmakeconversionrate.py b/util/cmake/cmakeconversionrate.py
new file mode 100755
index 0000000000..3496ed1b91
--- /dev/null
+++ b/util/cmake/cmakeconversionrate.py
@@ -0,0 +1,127 @@
+#!/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 sys
+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('Scanning "{}" for qmake-based tests.'.format(source_directory))
+ 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('Running cmake in "{}".'.format(binary_directory))
+ result = subprocess.run(['/usr/bin/cmake', '-GNinja', abs_source], cwd=binary_directory)
+ if debug:
+ print('CMake return code: {}.'.format(result.returncode))
+
+ assert result.returncode == 0
+
+ if debug:
+ print('Running ninja in "{}".'.format(binary_directory))
+ result = subprocess.run('/usr/bin/ninja', cwd=binary_directory)
+ if debug:
+ print('Ninja return code: {}.'.format(result.returncode))
+
+ assert result.returncode == 0
+
+
+def test(binary_directory: str, *, debug=False) -> typing.Tuple[int, int]:
+ if debug:
+ print('Running ctest in "{}".'.format(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('Test summary: {} ({}).'.format(summary, result.returncode))
+
+ matches = re.fullmatch(r'\d+% tests passed, (\d+) tests failed out of (\d+)', summary)
+ if matches:
+ if debug:
+ print('Matches: failed {}, total {}.'.format(matches.group(1), 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('Could not find the qmake baseline in {}.'.format(args.source_directory))
+ return 1
+
+ if args.debug:
+ print('qmake baseline: {} test binaries.'.format(base_line))
+
+ 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('\n\n\nCMake test conversion rate: {:.2%}.'.format(cmake_total / base_line))
+ print('CMake test success rate : {:.2%}.'.format(cmake_success / base_line))
+ return 0
+
+
+if __name__ == '__main__':
+ main()
diff --git a/util/cmake/configurejson2cmake.py b/util/cmake/configurejson2cmake.py
new file mode 100755
index 0000000000..58ab106555
--- /dev/null
+++ b/util/cmake/configurejson2cmake.py
@@ -0,0 +1,1039 @@
+#!/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
+import os.path
+import re
+import sys
+from typing import Set, Union, List, Dict
+
+from helper import map_qt_library, featureName, substitute_platform
+
+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_library(lib: str) -> Union[str, LibraryMapping, List[str]]:
+ libmap = {
+ 'atspi': 'ATSPI2',
+ 'corewlan': None, # Framework
+ 'cups': 'Cups',
+ 'double-conversion': None,
+ 'drm': 'Libdrm',
+ 'egl': 'EGL',
+ 'fontconfig': LibraryMapping(package='Fontconfig', resultVariable="FONTCONFIG"),
+ 'freetype': 'Freetype',
+ 'gbm': 'gbm',
+ 'glib': 'GLIB2',
+ 'gnu_iconv': None,
+ 'gtk3': 'GTK3',
+ 'harfbuzz': 'harfbuzz',
+ 'host_dbus': None,
+ 'icu': ['ICU', 'COMPONENTS', 'i18n', 'uc', 'data'],
+ 'journald': 'Libsystemd',
+ 'libatomic': 'Atomic',
+ 'libdl': None, # handled by CMAKE_DL_LIBS
+ 'libinput': 'Libinput',
+ 'libjpeg': 'JPEG',
+ 'libpng': 'PNG',
+ 'libpng': 'PNG',
+ 'libproxy': 'Libproxy',
+ 'librt': 'WrapRt',
+ 'libudev': 'Libudev',
+ 'lttng-ust': LibraryMapping(package='LTTngUST', resultVariable="LTTNGUST"),
+ 'mtdev': 'Mtdev',
+ 'odbc': 'ODBC',
+ 'opengl': LibraryMapping(package="OpenGL", resultVariable="OpenGL_OpenGL"),
+ 'openssl': 'OpenSSL',
+ 'openssl_headers': LibraryMapping(package="OpenSSL", resultVariable="OPENSSL_INCLUDE_DIR", appendFoundSuffix=False),
+ 'pcre2': ['PCRE2', 'REQUIRED'],
+ 'posix_iconv': None,
+ 'pps': 'PPS',
+ 'psql': 'PostgreSQL',
+ 'slog2': 'Slog2',
+ 'sqlite3': 'SQLite3',
+ 'sun_iconv': None,
+ 'tslib': 'Tslib',
+ 'udev': 'Libudev',
+ 'vulkan': 'Vulkan',
+ 'wayland_server': 'Wayland',
+ 'x11sm': LibraryMapping(package="X11", resultVariable="X11_SM"),
+ 'xcb_glx': LibraryMapping(package="XCB", resultVariable="XCB_GLX"),
+ 'xcb_render': LibraryMapping(package="XCB", resultVariable="XCB_RENDER"),
+ 'xcb': ['XCB', '1.9'],
+ 'xcb_xinput': LibraryMapping(package="XCB", resultVariable="XCB_XINPUT"),
+ 'xcb_xkb': LibraryMapping(package="XCB", resultVariable="XCB_XKB"),
+ 'xcb_xlib': 'X11_XCB',
+ 'xkbcommon': ['XKB', '0.4.1'],
+ 'xlib': 'X11',
+ 'xrender': LibraryMapping(package="XCB", resultVariable="XCB_RENDER"),
+ 'zlib': 'ZLIB',
+ 'zstd': 'ZSTD',
+ 'opengl_es2': 'GLESv2',
+ } # type: Dict[str, Union[str, List[str], LibraryMapping]]
+ if lib not in libmap:
+ raise Exception(' XXXX Unknown library "{}".'.format(lib))
+
+ return libmap[lib]
+
+
+def map_tests(test: str) -> str:
+ testmap = {
+ 'c++11': '$<COMPILE_FEATURES:cxx_std_11>',
+ 'c++14': '$<COMPILE_FEATURES:cxx_std_14>',
+ 'c++1z': '$<COMPILE_FEATURES:cxx_std_17>',
+ 'c99': '$<COMPILE_FEATURES:c_std_99>',
+ 'c11': '$<COMPILE_FEATURES:c_std_11>',
+
+ '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',
+ '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",
+ }
+ if test in testmap:
+ return testmap.get(test, None)
+ if test in knownTests:
+ return 'TEST_{}'.format(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(dir):
+ path = os.path.join(dir, 'configure.json')
+
+ print('Reading {}...'.format(path))
+ assert os.path.exists(path)
+
+ with open(path, 'r') as fh:
+ return json.load(fh)
+
+
+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):
+ extra = []
+ try:
+ newlib = map_library(lib)
+ if isinstance(newlib, list):
+ extra = newlib[1:]
+ newlib = newlib[0]
+ elif isinstance(newlib, LibraryMapping):
+ newlib = newlib.package
+ except Exception:
+ return ctx
+
+ if newlib is None:
+ print(' **** Skipping library "{}" -- was masked.'.format(lib))
+ return
+
+ print(' mapped library {} to {}.'.format(lib, newlib))
+
+ # Avoid duplicate find_package calls.
+ if newlib in cmake_find_packages_set:
+ return
+
+ cmake_find_packages_set.add(newlib)
+
+ isRequired = False
+
+ if extra:
+ if "REQUIRED" in extra:
+ isRequired = True
+ extra.remove("REQUIRED")
+
+ if extra:
+ cm_fh.write('find_package({} {})\n'.format(newlib, ' '.join(extra)))
+ else:
+ cm_fh.write('find_package({})\n'.format(newlib))
+
+ cm_fh.write('set_package_properties({} PROPERTIES TYPE {})\n'
+ .format(newlib, 'REQUIRED' if isRequired else 'OPTIONAL')
+ )
+
+def lineify(label, value, quote=True):
+ if value:
+ if quote:
+ return ' {} "{}"\n'.format(label, value.replace('"', '\\"'))
+ return ' {} {}\n'.format(label, value)
+ 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':
+ try:
+ substitution = map_library(match.group(2))
+ if isinstance(substitution, list):
+ substitution = substitution[0]
+ elif isinstance(substitution, LibraryMapping):
+ appendFoundSuffix = substitution.appendFoundSuffix
+ substitution = substitution.resultVariable
+ except Exception:
+ substitution = None
+
+ if substitution is not None and appendFoundSuffix:
+ substitution += '_FOUND'
+
+ elif match.group(1) == 'features':
+ feature = match.group(2)
+ if feature in mapped_features:
+ substitution = mapped_features.get(feature)
+ else:
+ substitution = 'QT_FEATURE_{}'.format(featureName(match.group(2)))
+
+ elif match.group(1) == 'subarch':
+ substitution = 'TEST_arch_{}_subarch_{}'.format("${TEST_architecture_arch}",
+ 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 = 'INPUT_{}'.format(featureName(match.group(2)))
+
+ elif match.group(1) == 'config':
+ substitution = substitute_platform(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(' XXXX Unknown condition "{}".'.format(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()
+
+ if has_failed:
+ condition += ' OR FIXME'
+
+ return condition
+
+
+def parseInput(ctx, input, 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 input in skip_inputs:
+ print(' **** Skipping input {}: masked.'.format(input))
+ return
+
+ type = data
+ if isinstance(data, dict):
+ type = data["type"]
+
+ if type == "boolean":
+ print(' **** Skipping boolean input {}: masked.'.format(input))
+ return
+
+ if type == "enum":
+ cm_fh.write("# input {}\n".format(input))
+ cm_fh.write('set(INPUT_{} "undefined" CACHE STRING "")\n'.format(featureName(input)))
+ cm_fh.write('set_property(CACHE INPUT_{} PROPERTY STRINGS undefined {})\n\n'.format(featureName(input), " ".join(data["values"])))
+ return
+
+ print(' XXXX UNHANDLED INPUT TYPE {} in input description'.format(type))
+ 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 = {
+ 'c++11', 'c++14', 'c++1y', 'c++1z',
+ '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',
+ 'xlib',
+ }
+
+ if test in skip_tests:
+ print(' **** Skipping features {}: masked.'.format(test))
+ return
+
+ if data["type"] == "compile":
+ knownTests.add(test)
+
+ details = data["test"]
+
+ if isinstance(details, str):
+ print(' XXXX UNHANDLED TEST SUB-TYPE {} in test description'.format(details))
+ 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 = '#include <{}>'.format(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 = ""
+ qmakeFixme = ""
+
+ cm_fh.write("# {}\n".format(test))
+ 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"] == "CONFIG += c++11":
+ # do nothing we're always in c++11 mode
+ pass
+ else:
+ qmakeFixme = "# FIXME: qmake: {}\n".format(details["qmake"])
+
+ if "use" in data:
+ if data["use"] == "egl xcb_xlib":
+ librariesCmakeName = format(featureName(test)) + "_TEST_LIBRARIES"
+ cm_fh.write("if (HAVE_EGL AND X11_XCB_FOUND AND X11_FOUND)\n")
+ cm_fh.write(" set(" + librariesCmakeName + " EGL::EGL X11::X11 X11::XCB)\n")
+ cm_fh.write("endif()\n")
+ else:
+ qmakeFixme += "# FIXME: use: {}\n".format(data["use"])
+
+ cm_fh.write("qt_config_compile_test({}\n".format(featureName(test)))
+ cm_fh.write(lineify("LABEL", data.get("label", "")))
+ if librariesCmakeName != "":
+ cm_fh.write(lineify("LIBRARIES", "${"+librariesCmakeName+"}"))
+ cm_fh.write(" CODE\n")
+ cm_fh.write('"' + sourceCode + '"')
+ if qmakeFixme != "":
+ cm_fh.write(qmakeFixme)
+ cm_fh.write(")\n\n")
+
+ elif data["type"] == "x86Simd":
+ knownTests.add(test)
+
+ label = data["label"]
+
+ cm_fh.write("# {}\n".format(test))
+ cm_fh.write("qt_config_compile_test_x86simd({} \"{}\")\n".format(test, label))
+ 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(' XXXX UNHANDLED TEST TYPE {} in test description'.format(data["type"]))
+
+
+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,
+ 'c++11': None, # C and C++ versions
+ 'c11': None,
+ 'c++14': None,
+ 'c++1y': None,
+ 'c++1z': 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 )'
+ },
+ '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,
+ 'use_gold_linker': None,
+ 'verifyspec': None, # qmake specific...
+ 'warnings_are_errors': None, # FIXME: Do we need these?
+ 'xkbcommon-system': None, # another system library, just named a bit different from the rest
+ }
+
+ mapping = feature_mapping.get(feature, {})
+
+ if mapping is None:
+ print(' **** Skipping features {}: masked.'.format(feature))
+ 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(' XXXX UNHANDLED KEY {} in feature description'.format(k))
+
+ 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
+
+ for o in output:
+ outputType = o
+ outputArgs = {}
+ if isinstance(o, dict):
+ outputType = o['type']
+ outputArgs = o
+
+ if outputType in ['varAssign', 'varAppend', 'varRemove', 'publicQtConfig', 'privateConfig', 'publicConfig']:
+ 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
+ else:
+ print(' XXXX UNHANDLED OUTPUT TYPE {} in feature {}.'.format(outputType, feature))
+ continue
+
+ if not any([publicFeature, privateFeature, internalFeature, publicDefine, negativeFeature]):
+ print(' **** Skipping feature {}: Not relevant for C++.'.format(feature))
+ return
+
+ cxxFeature = featureName(feature)
+
+ def writeFeature(name, publicFeature=False, privateFeature=False, labelAppend=''):
+ if comment:
+ cm_fh.write('# {}\n'.format(comment))
+
+ cm_fh.write('qt_feature("{}"'.format(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))
+ cm_fh.write(lineify('CONDITION', 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[cxxFeature] = {'name': cxxFeature, 'labelAppend': ''}
+
+ # Go over all outputs to compute the number of features that have to be declared
+ for o in output:
+ outputType = o
+ name = cxxFeature
+
+ # 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 = ': {}'.format(o['name'])
+
+ if outputType not in ['feature', 'publicFeature', 'privateFeature']:
+ continue
+ if name not in featureCalls:
+ featureCalls[name] = {'name': name, 'labelAppend': labelAppend}
+
+ if outputType in ['feature', 'publicFeature']:
+ featureCalls[name]['publicFeature'] = True
+ elif outputType == 'privateFeature':
+ featureCalls[name]['privateFeature'] = 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': 'QT_NO_{}'.format(cxxFeature.upper()),
+ 'negative': True,
+ 'value': 1,
+ 'type': 'define'}
+
+ if outputType != 'define':
+ continue
+
+ if outputArgs.get('name') is None:
+ print(' XXXX DEFINE output without name in feature {}.'.format(feature))
+ continue
+
+ cm_fh.write('qt_feature_definition("{}" "{}"'.format(cxxFeature, outputArgs.get('name')))
+ if outputArgs.get('negative', False):
+ cm_fh.write(' NEGATE')
+ if outputArgs.get('value') is not None:
+ cm_fh.write(' VALUE "{}"'.format(outputArgs.get('value')))
+ 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 in commandLine['options']:
+ parseInput(ctx, input, commandLine['options'][input], 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['libraries'][lib], cm_fh, cmake_find_packages_set)
+
+
+def processSubconfigs(dir, ctx, data):
+ assert ctx is not None
+ if 'subconfigs' in data:
+ for subconf in data['subconfigs']:
+ subconfDir = os.path.join(dir, subconf)
+ subconfData = readJsonFromDir(subconfDir)
+ subconfCtx = ctx
+ processJson(subconfDir, subconfCtx, subconfData)
+
+
+def processJson(dir, ctx, data):
+ ctx['module'] = data.get('module', 'global')
+
+ ctx = processFiles(ctx, data)
+
+ with open(os.path.join(dir, "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(dir, ctx, data)
+
+
+def main():
+ if len(sys.argv) != 2:
+ print("This scripts needs one directory to process!")
+ quit(1)
+
+ dir = sys.argv[1]
+
+ print("Processing: {}.".format(dir))
+
+ data = readJsonFromDir(dir)
+ processJson(dir, {}, 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..13c1677b52
--- /dev/null
+++ b/util/cmake/helper.py
@@ -0,0 +1,272 @@
+#############################################################################
+##
+## 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
+
+
+def featureName(input: str) -> str:
+ return re.sub(r'[^a-zA-Z0-9_]', '_', input)
+
+
+def map_qt_base_library(lib: str) -> str:
+ library_map = {
+ 'global': 'Qt::Core', # manually added special case
+ 'accessibility_support': 'Qt::AccessibilitySupport',
+ 'androidextras': 'Qt::AndroidExtras',
+ 'animation': 'Qt::3DAnimation',
+ 'application-lib': 'Qt::AppManApplication',
+ 'bluetooth': 'Qt::Bluetooth',
+ 'bootstrap-dbus': 'Qt::BootstrapDBus',
+ 'bootstrap': 'Qt::Bootstrap',
+ 'client': 'Qt::WaylandClient',
+ 'clipboard_support': 'Qt::ClipboardSupport',
+ 'common-lib': 'Qt::AppManCommon',
+ 'compositor': 'Qt::WaylandCompositor',
+ 'concurrent': 'Qt::Concurrent',
+ 'container': 'Qt::AxContainer',
+ 'control': 'Qt::AxServer',
+ 'core_headers': 'Qt::WebEngineCore',
+ 'core': 'Qt::Core',
+ 'coretest': 'Qt::3DCoreTest',
+ 'crypto-lib': 'Qt::AppManCrypto',
+ 'dbus': 'Qt::DBus',
+ 'devicediscovery': 'Qt::DeviceDiscoverySupport',
+ 'devicediscovery_support': 'Qt::DeviceDiscoverySupport',
+ 'edid': 'Qt::EdidSupport',
+ 'eglconvenience': 'Qt::EglSupport',
+ 'eglfsdeviceintegration': 'Qt::EglFSDeviceIntegration',
+ 'eglfs_kms_support': 'Qt::EglFsKmsSupport',
+ 'egl_support': 'Qt::EglSupport',
+ 'enginio_client': 'Enginio',
+ 'eventdispatchers': 'Qt::EventDispatcherSupport',
+ 'extras': 'Qt::3DExtras',
+ 'fb_support': 'Qt::FbSupport',
+ 'fbconvenience': 'Qt::FbSupport',
+ 'fontdatabase_support': 'Qt::FontDatabaseSupport',
+ 'gamepad': 'Qt::Gamepad',
+ 'glx_support': 'Qt::GlxSupport',
+ 'graphics_support': 'Qt::GraphicsSupport',
+ 'gsttools': 'Qt::MultimediaGstTools',
+ 'gui': 'Qt::Gui',
+ 'help': 'Qt::Help',
+ 'hunspellinputmethod': 'Qt::HunspellInputMethod',
+ 'input': 'Qt::InputSupport',
+ 'input_support': 'Qt::InputSupport',
+ 'installer-lib': 'Qt::AppManInstaller',
+ 'kmsconvenience': 'Qt::KmsSupport',
+ 'kms_support': 'Qt::KmsSupport',
+ 'launcher-lib': 'Qt::AppManLauncher',
+ 'lib': 'Qt::Designer',
+ 'linuxaccessibility_support': 'Qt::LinuxAccessibilitySupport',
+ 'location': 'Qt::Location',
+ 'logic': 'Qt::3DLogic',
+ 'macextras': 'Qt::MacExtras',
+ 'main-lib': 'Qt::AppManMain',
+ 'manager-lib': 'Qt::AppManManager',
+ 'monitor-lib': 'Qt::AppManMonitor',
+ 'multimedia': 'Qt::Multimedia',
+ 'multimediawidgets': 'Qt::MultimediaWidgets',
+ 'network': 'Qt::Network',
+ 'nfc': 'Qt::Nfc',
+ 'oauth': 'Qt::NetworkAuth',
+ 'openglextensions': 'Qt::OpenGLExtensions',
+ 'opengl': 'Qt::OpenGL',
+ 'package-lib': 'Qt::AppManPackage',
+ 'packetprotocol': 'Qt::PacketProtocol',
+ 'particles': 'Qt::QuickParticles',
+ 'platformcompositor': 'Qt::PlatformCompositorSupport',
+ 'platformcompositor_support': 'Qt::PlatformCompositorSupport',
+ 'plugin-interfaces': 'Qt::AppManPluginInterfaces',
+ 'positioning': 'Qt::Positioning',
+ 'positioningquick': 'Qt::PositioningQuick',
+ 'printsupport': 'Qt::PrintSupport',
+ 'purchasing': 'Qt::Purchasing',
+ 'qmldebug': 'Qt::QmlDebug',
+ 'qmldevtools': 'Qt::QmlDevTools',
+ 'qml': 'Qt::Qml',
+ 'qmltest': 'Qt::QuickTest',
+ 'qtmultimediaquicktools': 'Qt::MultimediaQuick',
+ 'qtzlib': 'Qt::Zlib',
+ 'quick3danimation': 'Qt::3DQuickAnimation',
+ 'quick3dextras': 'Qt::3DQuickExtras',
+ 'quick3dinput': 'Qt::3DQuickInput',
+ 'quick3d': 'Qt::3DQuick',
+ 'quick3drender': 'Qt::3DQuickRender',
+ 'quick3dscene2d': 'Qt::3DQuickScene2D',
+ 'quickcontrols2': 'Qt::QuickControls2',
+ 'quick': 'Qt::Quick',
+ 'quickshapes': 'Qt::QuickShapes',
+ 'quicktemplates2': 'Qt::QuickTemplates2',
+ 'quickwidgets': 'Qt::QuickWidgets',
+ 'render': 'Qt::3DRender',
+ 'script': 'Qt::Script',
+ 'scripttools': 'Qt::ScriptTools',
+ 'sensors': 'Qt::Sensors',
+ 'serialport': 'Qt::SerialPort',
+ 'services': 'Qt::ServiceSupport',
+ 'sql': 'Qt::Sql',
+ 'svg': 'Qt::Svg',
+ 'testlib': 'Qt::Test',
+ 'theme_support': 'Qt::ThemeSupport',
+ 'service_support': 'Qt::ServiceSupport',
+ 'eventdispatcher_support': 'Qt::EventDispatcherSupport',
+ 'edid_support': 'Qt::EdidSupport',
+ 'tts': 'Qt::TextToSpeech',
+ 'uiplugin': 'Qt::UiPlugin',
+ 'uitools': 'Qt::UiTools',
+ 'virtualkeyboard': 'Qt::VirtualKeyboard',
+ 'vulkan_support': 'Qt::VulkanSupport',
+ 'webchannel': 'Qt::WebChannel',
+ 'webengine': 'Qt::WebEngine',
+ 'webenginewidgets': 'Qt::WebEngineWidgets',
+ 'websockets': 'Qt::WebSockets',
+ 'webview': 'Qt::WebView',
+ 'widgets': 'Qt::Widgets',
+ 'window-lib': 'Qt::AppManWindow',
+ 'windowsuiautomation_support': 'Qt::WindowsUIAutomationSupport',
+ 'winextras': 'Qt::WinExtras',
+ 'x11extras': 'Qt::X11Extras',
+ 'xcb_qpa_lib': 'Qt::XcbQpa',
+ 'xkbcommon_support': 'Qt::XkbCommonSupport',
+ 'xmlpatterns': 'Qt::XmlPatterns',
+ 'xml': 'Qt::Xml',
+ }
+ return library_map.get(lib, lib)
+
+
+def map_qt_library(lib: str) -> str:
+ private = False
+ if lib.endswith('-private'):
+ private = True
+ lib = lib[:-8]
+ mapped = map_qt_base_library(lib)
+ if private:
+ mapped += 'Private'
+ return mapped
+
+
+platform_mapping = {
+ 'win32': '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',
+ '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_OSX',
+ 'macx': 'APPLE_OSX',
+ 'macos': 'APPLE_OSX',
+ 'macx-icc': '(APPLE_OSX AND ICC)',
+}
+
+
+def substitute_platform(platform: str) -> str:
+ """ Return the qmake platform as cmake platform or the unchanged string. """
+ return platform_mapping.get(platform, platform)
+
+
+libray_mapping = {
+ 'atspi': 'PkgConfig::ATSPI2',
+ 'cups': 'Cups::Cups',
+ 'drm': 'Libdrm::Libdrm',
+ 'doubleconversion': 'double-conversion',
+ 'fontconfig': 'Fontconfig::Fontconfig',
+ 'freetype': 'Freetype::Freetype',
+ 'gbm': 'gbm::gbm',
+ 'glib': 'GLIB2::GLIB2',
+ 'glx_support': 'Qt::GlxSupport',
+ 'glx_supportPrivate': 'Qt::GlxSupportPrivate',
+ 'harfbuzz': 'harfbuzz::harfbuzz',
+ 'icu': 'ICU::i18n ICU::uc ICU::data',
+ 'libatomic': 'Atomic',
+ 'libdl': '${CMAKE_DL_LIBS}',
+ 'libinput': 'Libinput::Libinput',
+ 'libpng' : 'PNG::PNG',
+ 'libproxy': 'LibProxy::LibProxy',
+ 'librt': 'WrapRt',
+ 'libudev': 'PkgConfig::Libudev',
+ 'mtdev': 'PkgConfig::Mtdev',
+ 'odbc': 'ODBC::ODBC',
+ 'openssl': 'OpenSSL::SSL',
+ 'pcre2': 'PCRE2',
+ 'psql': 'PostgreSQL::PostgreSQL',
+ 'sqlite': 'SQLite::SQLite3',
+ 'SQLite3': 'SQLite::SQLite3',
+ 'tslib': 'PkgConfig::Tslib',
+ 'x11sm': '${X11_SM_LIB} ${X11_ICE_LIB}',
+ 'xcb_icccm': 'XCB::ICCCM',
+ 'xcb_image': 'XCB::IMAGE',
+ 'xcb_keysyms': 'XCB::KEYSYMS',
+ 'xcb_randr': 'XCB::RANDR',
+ 'xcb_renderutil': 'XCB::RENDERUTIL',
+ 'xcb_render': 'XCB::RENDER',
+ 'xcb_shape': 'XCB::SHAPE',
+ 'xcb_shm': 'XCB::SHM',
+ 'xcb_sync': 'XCB::SYNC',
+ 'xcb': 'XCB::XCB',
+ 'xcb_xfixes': 'XCB::XFIXES',
+ 'xcb_xinerama': 'XCB::XINERAMA',
+ 'xcb_xinput': 'XCB::XINPUT',
+ 'xcb_xkb': 'XCB::XKB',
+ 'xcb_xlib': 'X11::XCB',
+ 'xkbcommon_evdev': 'XKB::XKB',
+ 'xkbcommon_x11': 'XKB::XKB',
+ 'xkbcommon': 'XKB::XKB',
+ 'xrender': 'XCB::RENDER',
+ 'zlib': 'ZLIB::ZLIB',
+ 'zstd': 'ZSTD::ZSTD',
+}
+
+
+def substitute_libs(lib: str) -> str:
+ libpostfix = ''
+ if lib.endswith('/nolink'):
+ lib = lib[:-7]
+ libpostfix = '_nolink'
+ return libray_mapping.get(lib, lib) + libpostfix
diff --git a/util/cmake/pro2cmake.py b/util/cmake/pro2cmake.py
new file mode 100755
index 0000000000..7801c4d103
--- /dev/null
+++ b/util/cmake/pro2cmake.py
@@ -0,0 +1,1592 @@
+#!/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
+
+from argparse import ArgumentParser
+import copy
+import xml.etree.ElementTree as ET
+from itertools import chain
+import os.path
+import re
+import io
+import typing
+
+from sympy.logic import (simplify_logic, And, Or, Not,)
+import pyparsing as pp
+
+from helper import map_qt_library, map_qt_base_library, featureName, \
+ substitute_platform, substitute_libs
+
+
+def _parse_commandline():
+ parser = ArgumentParser(description='Generate CMakeLists.txt files from .'
+ 'pro files.')
+ 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('files', metavar='<.pro/.pri file>', type=str,
+ nargs='+', help='The .pro/.pri file to process')
+
+ return parser.parse_args()
+
+
+def process_qrc_file(target: str, filepath: str, base_dir: str = '') -> str:
+ assert(target)
+ resource_name = os.path.splitext(os.path.basename(filepath))[0]
+ base_dir = os.path.join('' if base_dir == '.' else base_dir, os.path.dirname(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', '')
+
+ full_resource_name = resource_name + (str(resource_count) if resource_count > 0 else '')
+
+ files: typing.Dict[str, str] = {}
+ for file in resource:
+ path = file.text
+ assert path
+
+ # Get alias:
+ alias = file.get('alias', '')
+ files[path] = alias
+
+ sorted_files = sorted(files.keys())
+
+ assert(sorted_files)
+
+ for source in sorted_files:
+ alias = files[source]
+ if alias:
+ full_source = os.path.join(base_dir, source)
+ output += 'set_source_files_properties("{}"\n' \
+ ' PROPERTIES alias "{}")\n'.format(full_source, alias)
+
+ params = ''
+ if lang:
+ params += ' LANG "{}"'.format(lang)
+ if prefix:
+ params += ' PREFIX "{}"'.format(prefix)
+ if base_dir:
+ params += ' BASE "{}"'.format(base_dir)
+ output += 'add_qt_resource({} "{}"{} FILES\n {})\n'.format(target, full_resource_name,
+ params,
+ '\n '.join(sorted_files))
+
+ resource_count += 1
+
+ return output
+
+
+def fixup_linecontinuation(contents: str) -> str:
+ contents = re.sub(r'([^\t ])\\[ \t]*\n', '\\1 \\\n', contents)
+ contents = re.sub(r'\\[ \t]*\n', '\\\n', contents)
+
+ return contents
+
+
+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 = os.path.join(base_dir, f)
+
+ return trim_leading_dot(f)
+
+
+def handle_vpath(source: str, base_dir: str, vpath: typing.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 = os.path.join(v, source)
+ if os.path.exists(fullpath):
+ return trim_leading_dot(os.path.relpath(fullpath, base_dir))
+
+ print(' XXXX: Source {}: Not found.'.format(source))
+ return '{}-NOTFOUND'.format(source)
+
+
+class Operation:
+ def __init__(self, value):
+ if isinstance(value, list):
+ self._value = value
+ else:
+ self._value = [str(value), ]
+
+ def process(self, key, input, transformer):
+ 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, input, transformer):
+ return input + transformer(self._value)
+
+ def __repr__(self):
+ return '+({})'.format(self._dump())
+
+
+class UniqueAddOperation(Operation):
+ def process(self, key, input, transformer):
+ result = input
+ for v in transformer(self._value):
+ if v not in result:
+ result.append(v)
+ return result
+
+ def __repr__(self):
+ return '*({})'.format(self._dump())
+
+
+class SetOperation(Operation):
+ def process(self, key, input, transformer):
+ values = [] # typing.List[str]
+ for v in self._value:
+ if v != '$$' + key:
+ values.append(v)
+ else:
+ values += input
+
+ if transformer:
+ return list(transformer(values))
+ else:
+ return values
+
+ def __repr__(self):
+ return '=({})'.format(self._dump())
+
+
+class RemoveOperation(Operation):
+ def __init__(self, value):
+ super().__init__(value)
+
+ def process(self, key, input, transformer):
+ input_set = set(input)
+ value_set = set(self._value)
+ result = []
+
+ # Add everything that is not going to get removed:
+ for v in input:
+ if v not in value_set:
+ result += [v,]
+
+ # Add everything else with removal marker:
+ for v in transformer(self._value):
+ if v not in input_set:
+ result += ['-{}'.format(v), ]
+
+ return result
+
+ def __repr__(self):
+ return '-({})'.format(self._dump())
+
+
+class Scope(object):
+
+ SCOPE_ID: int = 1
+
+ def __init__(self, *,
+ parent_scope: typing.Optional[Scope],
+ file: typing.Optional[str] = None, condition: str = '',
+ base_dir: str = '',
+ operations: typing.Mapping[str, typing.List[Operation]] = {
+ 'QT_SOURCE_TREE': [SetOperation('${PROJECT_SOURCE_DIR}')],
+ 'QT_BUILD_TREE': [SetOperation('${PROJECT_BUILD_DIR}')],
+ }) -> None:
+ if parent_scope:
+ parent_scope._add_child(self)
+ else:
+ self._parent = None # type: typing.Optional[Scope]
+
+ self._basedir = base_dir
+ if file:
+ self._currentdir = os.path.dirname(file)
+ if not self._currentdir:
+ self._currentdir = '.'
+ if not self._basedir:
+ self._basedir = self._currentdir
+
+ self._scope_id = Scope.SCOPE_ID
+ Scope.SCOPE_ID += 1
+ self._file = file
+ self._condition = map_condition(condition)
+ self._children = [] # type: typing.List[Scope]
+ self._included_children = [] # type: typing.List[Scope]
+ self._operations = copy.deepcopy(operations)
+ self._visited_keys = set() # type: typing.Set[str]
+ self._total_condition = None # type: typing.Optional[str]
+
+ def __repr__(self):
+ return '{}:{}:{}:{}:{}'.format(self._scope_id,
+ self._basedir, self._currentdir,
+ self._file, 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 and (merge == '1' or merge == 'on' or merge == 'yes' or merge == 'true')
+
+ @property
+ def parent(self) -> typing.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: typing.List[Scope] = []
+ for c in self._children:
+ c.settle_condition()
+
+ if c.can_merge_condition():
+ child = c._children[0]
+ child._condition = '({}) AND ({})'.format(c._condition, child._condition)
+ new_children += c._children
+ else:
+ new_children.append(c)
+ self._children = new_children
+
+ @staticmethod
+ def FromDict(parent_scope: typing.Optional['Scope'],
+ file: str, statements, cond: str = '', base_dir: str = '') -> Scope:
+ scope = Scope(parent_scope=parent_scope, file=file, condition=cond, base_dir=base_dir)
+ 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 != ''
+
+ if operation == '=':
+ scope._append_operation(key, SetOperation(value))
+ elif operation == '-=':
+ scope._append_operation(key, RemoveOperation(value))
+ elif operation == '+=':
+ scope._append_operation(key, AddOperation(value))
+ elif operation == '*=':
+ scope._append_operation(key, UniqueAddOperation(value))
+ else:
+ print('Unexpected operation "{}" in scope "{}".'
+ .format(operation, 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:
+ scope._append_operation('_INCLUDED',
+ UniqueAddOperation(included))
+ continue
+
+ scope.settle_condition()
+
+ if scope.scope_debug:
+ print('..... [SCOPE_DEBUG]: Created scope {}:'.format(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 cMakeListsFile(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) -> typing.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) -> typing.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 = ' ' * indent
+ print('{}Scope "{}":'.format(ind, self))
+ if self.total_condition:
+ print('{} Total condition = {}'.format(ind, self.total_condition))
+ print('{} Keys:'.format(ind))
+ keys = self._operations.keys()
+ if not keys:
+ print('{} -- NONE --'.format(ind))
+ else:
+ for k in sorted(keys):
+ print('{} {} = "{}"'
+ .format(ind, k, self._operations.get(k, [])))
+ print('{} Children:'.format(ind))
+ if not self._children:
+ print('{} -- NONE --'.format(ind))
+ else:
+ for c in self._children:
+ c.dump(indent=indent + 1)
+ print('{} Includes:'.format(ind))
+ if not self._included_children:
+ print('{} -- NONE --'.format(ind))
+ else:
+ for c in self._included_children:
+ c.dump(indent=indent + 1)
+
+ def dump_structure(self, *, type: str = 'ROOT', indent: int = 0) -> None:
+ print('{}{}: {}'.format(spaces(indent), type, self))
+ for i in self._included_children:
+ i.dump_structure(type='INCL', indent=indent + 1)
+ for i in self._children:
+ i.dump_structure(type='CHLD', indent=indent + 1)
+
+ @property
+ def keys(self):
+ return self._operations.keys()
+
+ @property
+ def visited_keys(self):
+ return self._visited_keys
+
+ def _evalOps(self, key: str,
+ transformer: typing.Optional[typing.Callable[[Scope, typing.List[str]], typing.List[str]]],
+ result: typing.List[str], *, inherrit: bool = False) \
+ -> typing.List[str]:
+ self._visited_keys.add(key)
+
+ # Inherrit values from above:
+ if self._parent and inherrit:
+ result = self._parent._evalOps(key, transformer, result)
+
+ if transformer:
+ op_transformer = lambda files: transformer(self, files)
+ else:
+ op_transformer = lambda files: files
+
+ for op in self._operations.get(key, []):
+ result = op.process(key, result, op_transformer)
+
+ for ic in self._included_children:
+ result = list(ic._evalOps(key, transformer, result))
+
+ return result
+
+ def get(self, key: str, *, ignore_includes: bool = False, inherrit: bool = False) -> typing.List[str]:
+ if key == 'PWD':
+ return ['${CMAKE_CURRENT_SOURCE_DIR}/' + os.path.relpath(self.currentdir, self.basedir),]
+ if key == 'OUT_PWD':
+ return ['${CMAKE_CURRENT_BUILD_DIR}/' + os.path.relpath(self.currentdir, self.basedir),]
+
+ return self._evalOps(key, None, [], inherrit=inherrit)
+
+ def get_string(self, key: str, default: str = '') -> str:
+ v = self.get(key)
+ if len(v) == 0:
+ return default
+ assert len(v) == 1
+ return v[0]
+
+ def _map_files(self, files: typing.List[str], *,
+ use_vpath: bool = True, is_include: bool = False) -> typing.List[str]:
+
+ expanded_files = [] # typing.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', inherrit=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) -> typing.List[str]:
+ transformer = lambda scope, files: scope._map_files(files, use_vpath=use_vpath, is_include=is_include)
+ return list(self._evalOps(key, transformer, []))
+
+ def _expand_value(self, value: str) -> typing.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
+ if match.group(0) == value:
+ return self.get(match.group(1))
+
+ replacement = self.get(match.group(1))
+ replacement_str = replacement[0] if replacement else ''
+ result = result[:match.start()] \
+ + replacement_str \
+ + result[match.end():]
+
+ if result == old_result:
+ return [result,] # Do not go into infinite loop
+
+ match = re.search(pattern, result)
+ return [result,]
+
+ def expand(self, key: str) -> typing.List[str]:
+ value = self.get(key)
+ result: typing.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]
+
+ @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:
+ return self.get_string('TARGET') \
+ or os.path.splitext(os.path.basename(self.file))[0]
+
+ @property
+ def _INCLUDED(self) -> typing.List[str]:
+ return self.get('_INCLUDED')
+
+
+class QmakeParser:
+ def __init__(self, *, debug: bool = False) -> None:
+ self._Grammar = self._generate_grammar(debug)
+
+ def _generate_grammar(self, debug: bool):
+ # Define grammar:
+ pp.ParserElement.setDefaultWhitespaceChars(' \t')
+
+ LC = pp.Suppress(pp.Literal('\\\n'))
+ EOL = pp.Suppress(pp.LineEnd())
+ Else = pp.Keyword('else')
+ Identifier = pp.Word(pp.alphas + '_', bodyChars=pp.alphanums+'_-./')
+ BracedValue = pp.nestedExpr(ignoreExpr=pp.quotedString \
+ | pp.QuotedString(quoteChar='$(',
+ endQuoteChar=')',
+ escQuote='\\',
+ unquoteResults=False)
+ ).setParseAction(lambda s, l, t: ['(', *t[0], ')'])
+
+ 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 = pp.Word(pp.printables, excludeChars='$#{}()')
+ SubstitutionValue \
+ = pp.Combine(pp.OneOrMore(Substitution | LiteralValuePart
+ | pp.Literal('$')))
+ Value = pp.NotAny(Else | pp.Literal('}') | EOL) \
+ + (pp.QuotedString(quoteChar='"', escChar='\\')
+ | SubstitutionValue
+ | BracedValue)
+
+ Values = pp.ZeroOrMore(Value + pp.Optional(LC))('value')
+
+ Op = pp.Literal('=') | pp.Literal('-=') | pp.Literal('+=') \
+ | pp.Literal('*=')
+
+ Key = Identifier
+
+ Operation = Key('key') + pp.Optional(LC) \
+ + Op('operation') + pp.Optional(LC) \
+ + Values('value')
+ CallArgs = pp.Optional(LC) + 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 = pp.Keyword('load') + CallArgs('loaded')
+ Include = pp.Keyword('include') + CallArgs('included')
+ Option = pp.Keyword('option') + CallArgs('option')
+ DefineTestDefinition = pp.Suppress(pp.Keyword('defineTest') + CallArgs
+ + pp.nestedExpr(opener='{', closer='}', ignoreExpr=pp.LineEnd())) # ignore the whole thing...
+ ForLoop = pp.Suppress(pp.Keyword('for') + CallArgs
+ + pp.nestedExpr(opener='{', closer='}', ignoreExpr=pp.LineEnd())) # ignore the whole thing...
+ ForLoopSingleLine = pp.Suppress(pp.Keyword('for') + CallArgs
+ + pp.Literal(':') + pp.SkipTo(EOL, ignore=LC)) # ignore the whole thing...
+ FunctionCall = pp.Suppress(Identifier + pp.nestedExpr())
+
+ Scope = pp.Forward()
+
+ Statement = pp.Group(Load | Include | Option | ForLoop | ForLoopSingleLine \
+ | DefineTestDefinition | FunctionCall | Operation)
+ StatementLine = Statement + (EOL | pp.FollowedBy('}'))
+ StatementGroup = pp.ZeroOrMore(StatementLine | Scope | pp.Suppress(EOL))
+
+ Block = pp.Suppress('{') + pp.Optional(LC | EOL) \
+ + StatementGroup + pp.Optional(LC | EOL) \
+ + pp.Suppress('}') + pp.Optional(LC | EOL)
+
+ ConditionEnd = pp.FollowedBy((pp.Optional(pp.White())
+ + pp.Optional(LC) + (pp.Literal(':') \
+ | pp.Literal('{') \
+ | pp.Literal('|'))))
+ ConditionPart = ((pp.Optional('!') + Identifier + pp.Optional(BracedValue)) \
+ ^ pp.CharsNotIn('#{}|:=\\\n')) + pp.Optional(LC) + ConditionEnd
+ Condition = pp.Combine(ConditionPart \
+ + pp.ZeroOrMore((pp.Literal('|') ^ pp.Literal(':')) \
+ + ConditionPart))
+ Condition.setParseAction(lambda x: ' '.join(x).strip().replace(':', ' && ').strip(' && '))
+
+ SingleLineScope = pp.Suppress(pp.Literal(':')) + pp.Optional(LC) \
+ + pp.Group(Block | (Statement + EOL))('statements')
+ MultiLineScope = pp.Optional(LC) + Block('statements')
+
+ SingleLineElse = pp.Suppress(pp.Literal(':')) + pp.Optional(LC) \
+ + (Scope | Block | (Statement + pp.Optional(EOL)))
+ MultiLineElse = Block
+ ElseBranch = pp.Suppress(Else) + (SingleLineElse | MultiLineElse)
+ Scope <<= pp.Optional(LC) \
+ + pp.Group(Condition('condition') \
+ + (SingleLineScope | MultiLineScope) \
+ + pp.Optional(ElseBranch)('else_statements'))
+
+ if debug:
+ for ename in 'LC EOL ' \
+ 'Condition ConditionPart ConditionEnd ' \
+ 'Else ElseBranch SingleLineElse MultiLineElse ' \
+ 'SingleLineScope MultiLineScope ' \
+ 'Identifier ' \
+ 'Key Op Values Value BracedValue ' \
+ 'Scope Block ' \
+ 'StatementGroup StatementLine Statement '\
+ 'Load Include Option DefineTestDefinition ForLoop ' \
+ 'FunctionCall CallArgs Operation'.split():
+ expr = locals()[ename]
+ expr.setName(ename)
+ expr.setDebug()
+
+ Grammar = StatementGroup('statements')
+ Grammar.ignore(pp.pythonStyleComment())
+
+ return Grammar
+
+ def parseFile(self, file: str):
+ print('Parsing \"{}\"...'.format(file))
+ try:
+ with open(file, 'r') as file_fd:
+ contents = file_fd.read()
+
+ old_contents = contents
+ contents = fixup_linecontinuation(contents)
+
+ if old_contents != contents:
+ print('Warning: Fixed line continuation in .pro-file!\n'
+ ' Position information in Parsing output might be wrong!')
+ result = self._Grammar.parseString(contents, parseAll=True)
+ except pp.ParseException as pe:
+ print(pe.line)
+ print(' '*(pe.col-1) + '^')
+ print(pe)
+ raise pe
+ return result
+
+
+def parseProFile(file: str, *, debug=False):
+ parser = QmakeParser(debug=debug)
+ return parser.parseFile(file)
+
+
+def map_condition(condition: str) -> str:
+ condition = re.sub(r'\bif\s*\((.*?)\)', r'\1', condition)
+ condition = re.sub(r'\bisEmpty\s*\((.*?)\)', r'\1_ISEMPTY', 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'\s*==\s*', '___STREQUAL___', 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 ')
+
+ 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 = 'TARGET {}'.format(map_qt_library(feature.group(2)))
+ else:
+ feature = featureName(feature.group(2))
+ if feature.startswith('system_') and substitute_libs(feature[7:]) != feature[7:]:
+ # Qt6 always uses system libraries!
+ part = 'ON'
+ elif feature == 'dlopen':
+ part = 'ON'
+ else:
+ part = 'QT_FEATURE_' + feature
+ else:
+ part = substitute_platform(part)
+
+ part = part.replace('true', 'ON')
+ part = part.replace('false', 'OFF')
+ cmake_condition += ' ' + part
+ return cmake_condition.strip()
+
+
+def handle_subdir(scope: Scope, cm_fh: typing.IO[str], *,
+ indent: int = 0) -> None:
+ ind = ' ' * indent
+ for sd in scope.get_files('SUBDIRS'):
+ if os.path.isdir(sd):
+ cm_fh.write('{}add_subdirectory({})\n'.format(ind, sd))
+ elif os.path.isfile(sd):
+ subdir_result = parseProFile(sd, debug=False)
+ subdir_scope \
+ = Scope.FromDict(scope, sd,
+ subdir_result.asDict().get('statements'),
+ '', scope.basedir)
+
+ do_include(subdir_scope)
+ cmakeify_scope(subdir_scope, cm_fh, indent=indent)
+ elif sd.startswith('-'):
+ cm_fh.write('{}### remove_subdirectory'
+ '("{}")\n'.format(ind, sd[1:]))
+ else:
+ print(' XXXX: SUBDIR {} in {}: Not found.'.format(sd, scope))
+
+ for c in scope.children:
+ cond = c.condition
+ if cond == 'else':
+ cm_fh.write('\n{}else()\n'.format(ind))
+ elif cond:
+ cm_fh.write('\n{}if({})\n'.format(ind, cond))
+
+ handle_subdir(c, cm_fh, indent=indent + 1)
+
+ if cond:
+ cm_fh.write('{}endif()\n'.format(ind))
+
+
+def sort_sources(sources: typing.List[str]) -> typing.List[str]:
+ to_sort = {} # type: typing.Dict[str, typing.List[str]]
+ for s in sources:
+ if s is None:
+ continue
+
+ dir = os.path.dirname(s)
+ base = os.path.splitext(os.path.basename(s))[0]
+ if base.endswith('_p'):
+ base = base[:-2]
+ sort_name = os.path.join(dir, 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 write_header(cm_fh: typing.IO[str], name: str,
+ typename: str, *, indent: int = 0):
+ cm_fh.write('{}###########################################'
+ '##########################\n'.format(spaces(indent)))
+ cm_fh.write('{}## {} {}:\n'.format(spaces(indent), name, typename))
+ cm_fh.write('{}###########################################'
+ '##########################\n\n'.format(spaces(indent)))
+
+
+def write_scope_header(cm_fh: typing.IO[str], *, indent: int = 0):
+ cm_fh.write('\n{}## Scopes:\n'.format(spaces(indent)))
+ cm_fh.write('{}###########################################'
+ '##########################\n'.format(spaces(indent)))
+
+
+def write_source_file_list(cm_fh: typing.IO[str], scope, cmake_parameter: str,
+ keys: typing.List[str], indent: int = 0, *,
+ header: str = '', footer: str = ''):
+ ind = spaces(indent)
+
+ # collect sources
+ sources: typing.List[str] = []
+ for key in keys:
+ sources += scope.get_files(key, use_vpath=True)
+
+ if not sources:
+ return
+
+ cm_fh.write(header)
+ extra_indent = ''
+ if cmake_parameter:
+ cm_fh.write('{} {}\n'.format(ind, cmake_parameter))
+ extra_indent = ' '
+ for s in sort_sources(sources):
+ cm_fh.write('{} {}{}\n'.format(ind, extra_indent, s))
+ cm_fh.write(footer)
+
+
+def write_library_list(cm_fh: typing.IO[str], cmake_keyword: str,
+ dependencies: typing.List[str], *, indent: int = 0):
+ dependencies_to_print = []
+ is_framework = False
+
+ for d in dependencies:
+ if d == '-framework':
+ is_framework = True
+ continue
+ if is_framework:
+ d = '${FW%s}' % d
+ if d.startswith('-l'):
+ d = d[2:]
+
+ if d.startswith('-'):
+ d = '# Remove: {}'.format(d[1:])
+ else:
+ d = substitute_libs(d)
+ dependencies_to_print.append(d)
+ is_framework = False
+
+ if dependencies_to_print:
+ ind = spaces(indent)
+ cm_fh.write('{} {}\n'.format(ind, cmake_keyword))
+ for d in sorted(list(set(dependencies_to_print))):
+ cm_fh.write('{} {}\n'.format(ind, d))
+
+
+
+def write_library_section(cm_fh: typing.IO[str], scope: Scope,
+ public: typing.List[str],
+ private: typing.List[str],
+ mixed: typing.List[str], *,
+ indent: int = 0, known_libraries=set()):
+ public_dependencies = [] # typing.List[str]
+ private_dependencies = [] # typing.List[str]
+
+ for key in public:
+ public_dependencies += [map_qt_library(q) for q in scope.expand(key)
+ if map_qt_library(q) not in known_libraries]
+ for key in private:
+ private_dependencies += [map_qt_library(q) for q in scope.expand(key)
+ if map_qt_library(q) not in known_libraries]
+ for key in mixed:
+ for lib in scope.expand(key):
+ mapped_lib = map_qt_library(lib)
+ if mapped_lib in known_libraries:
+ continue
+
+ if mapped_lib.endswith('Private'):
+ private_dependencies.append(mapped_lib)
+ public_dependencies.append(mapped_lib[:-7])
+ else:
+ public_dependencies.append(mapped_lib)
+
+ write_library_list(cm_fh, 'LIBRARIES', private_dependencies, indent=indent)
+ write_library_list(cm_fh, 'PUBLIC_LIBRARIES', public_dependencies, indent=indent)
+
+
+
+def write_sources_section(cm_fh: typing.IO[str], scope: Scope, *,
+ indent: int = 0, known_libraries=set()):
+ ind = spaces(indent)
+
+ # mark RESOURCES as visited:
+ scope.get('RESOURCES')
+
+ plugin_type = scope.get_string('PLUGIN_TYPE')
+
+ if plugin_type:
+ cm_fh.write('{} TYPE {}\n'.format(ind, plugin_type))
+
+ source_keys: typing.List[str] = []
+ write_source_file_list(cm_fh, scope, 'SOURCES',
+ ['SOURCES', 'HEADERS', 'OBJECTIVE_SOURCES', 'NO_PCH_SOURCES', 'FORMS'],
+ indent)
+
+ write_source_file_list(cm_fh, scope, 'DBUS_ADAPTOR_SOURCES', ['DBUS_ADAPTORS',], indent)
+ dbus_adaptor_flags = scope.expand('QDBUSXML2CPP_ADAPTOR_HEADER_FLAGS')
+ if dbus_adaptor_flags:
+ cm_fh.write('{} DBUS_ADAPTOR_FLAGS\n'.format(ind))
+ cm_fh.write('{} "{}"\n'.format(ind, '" "'.join(dbus_adaptor_flags)))
+
+ write_source_file_list(cm_fh, scope, 'DBUS_INTERFACE_SOURCES', ['DBUS_INTERFACES',], indent)
+ dbus_interface_flags = scope.expand('QDBUSXML2CPP_INTERFACE_HEADER_FLAGS')
+ if dbus_interface_flags:
+ cm_fh.write('{} DBUS_INTERFACE_FLAGS\n'.format(ind))
+ cm_fh.write('{} "{}"\n'.format(ind, '" "'.join(dbus_interface_flags)))
+
+ defines = scope.expand('DEFINES')
+ defines += [d[2:] for d in scope.expand('QMAKE_CXXFLAGS') if d.startswith('-D')]
+ if defines:
+ cm_fh.write('{} DEFINES\n'.format(ind))
+ for d in defines:
+ d = d.replace('=\\\\\\"$$PWD/\\\\\\"',
+ '="${CMAKE_CURRENT_SOURCE_DIR}/"')
+ cm_fh.write('{} {}\n'.format(ind, d))
+ includes = scope.get_files('INCLUDEPATH')
+ if includes:
+ cm_fh.write('{} INCLUDE_DIRECTORIES\n'.format(ind))
+ for i in includes:
+ i = i.rstrip('/') or ('/')
+ cm_fh.write('{} {}\n'.format(ind, i))
+
+ write_library_section(cm_fh, scope,
+ ['QMAKE_USE', 'LIBS'],
+ ['QT_FOR_PRIVATE', 'QMAKE_USE_PRIVATE', 'QMAKE_USE_FOR_PRIVATE', 'LIBS_PRIVATE'],
+ ['QT',],
+ indent=indent, known_libraries=known_libraries)
+
+ compile_options = [d for d in scope.expand('QMAKE_CXXFLAGS') if not d.startswith('-D')]
+ if compile_options:
+ cm_fh.write('{} COMPILE_OPTIONS\n'.format(ind))
+ for co in compile_options:
+ cm_fh.write('{} "{}"\n'.format(ind, co))
+
+ link_options = scope.get('QMAKE_LFLAGS')
+ if link_options:
+ cm_fh.write('{} LINK_OPTIONS\n'.format(ind))
+ for lo in link_options:
+ cm_fh.write('{} "{}"\n'.format(ind, lo))
+
+ moc_options = scope.get('QMAKE_MOC_OPTIONS')
+ if moc_options:
+ cm_fh.write('{} MOC_OPTIONS\n'.format(ind))
+ for mo in moc_options:
+ cm_fh.write('{} "{}"\n'.format(ind, mo))
+
+
+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 == '_INCLUDED' or k == 'TARGET' or k == 'QMAKE_DOCS' or k == 'QT_SOURCE_TREE' \
+ or k == 'QT_BUILD_TREE' or k == 'TRACEPOINT_PROVIDER':
+ # All these keys are actually reported already
+ continue
+ values = scope.get(k)
+ value_string = '<EMPTY>' if not values \
+ else '"' + '" "'.join(scope.get(k)) + '"'
+ result += '{}# {} = {}\n'.format(indent, k, value_string)
+
+ if result:
+ result = '\n#### Keys ignored in scope {}:\n{}'.format(scope, result)
+
+ return result
+
+
+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 knownledge 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
+
+
+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 ')
+
+ try:
+ # Generate and simplify condition using sympy:
+ condition_expr = simplify_logic(condition)
+ condition = str(_recursive_simplify(condition_expr))
+
+ # 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')
+ except:
+ # sympy did not like our input, so leave this condition alone:
+ condition = input_condition
+
+ return condition or 'ON'
+
+
+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, \
+ "Else branch without previous condition in: %s" % scope.file
+ total_condition = 'NOT ({})'.format(previous_condition)
+ if parent_condition:
+ if not total_condition:
+ total_condition = parent_condition
+ else:
+ total_condition = '({}) AND ({})'.format(parent_condition,
+ 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 = re.sub(r'\bQT_ARCH___equals___([a-zA-Z_0-9]*)',
+ r'(TEST_architecture_arch STREQUAL "\1")', condition)
+ condition = re.sub(r'\bQT_ARCH___contains___([a-zA-Z_0-9]*)',
+ r'(TEST_architecture_arch STREQUAL "\1")', condition)
+ return condition
+
+
+def write_resources(cm_fh: typing.IO[str], target: str, scope: Scope, indent: int = 0):
+ vpath = scope.expand('VPATH')
+
+ # Handle QRC files by turning them into add_qt_resource:
+ resources = scope.get_files('RESOURCES')
+ qrc_output = ''
+ if resources:
+ qrc_only = True
+ for r in resources:
+ if r.endswith('.qrc'):
+ qrc_output += process_qrc_file(target, r, scope.basedir)
+ else:
+ qrc_only = False
+
+ if not qrc_only:
+ print(' XXXX Ignoring non-QRC file resources.')
+
+ if qrc_output:
+ cm_fh.write('\n# Resources:\n')
+ for line in qrc_output.split('\n'):
+ cm_fh.write(' ' * indent + line + '\n')
+
+
+def write_extend_target(cm_fh: typing.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()
+
+ extend_scope = '\n{}extend_target({} CONDITION {}\n' \
+ '{}{})\n'.format(ind, target,
+ map_to_cmake_condition(scope.total_condition),
+ extend_qt_string, ind)
+
+ if not extend_qt_string:
+ extend_scope = '' # Nothing to report, so don't!
+
+ cm_fh.write(extend_scope)
+
+ write_resources(cm_fh, target, scope, indent)
+
+
+def flatten_scopes(scope: Scope) -> typing.List[Scope]:
+ result = [scope] # type: typing.List[Scope]
+ for c in scope.children:
+ result += flatten_scopes(c)
+ return result
+
+
+def merge_scopes(scopes: typing.List[Scope]) -> typing.List[Scope]:
+ result = [] # type: typing.List[Scope]
+
+ # Merge scopes with their parents:
+ known_scopes = {} # type: typing.Mapping[str, Scope]
+ for scope in scopes:
+ total_condition = scope.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: typing.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'];
+ ind = spaces(indent)
+
+ for simd in simd_options:
+ SIMD = simd.upper();
+ write_source_file_list(cm_fh, scope, 'SOURCES',
+ ['{}_HEADERS'.format(SIMD),
+ '{}_SOURCES'.format(SIMD),
+ '{}_C_SOURCES'.format(SIMD),
+ '{}_ASM'.format(SIMD)],
+ indent,
+ header = '{}add_qt_simd_part({} SIMD {}\n'.format(ind, target, simd),
+ footer = '{})\n\n'.format(ind))
+
+
+def write_main_part(cm_fh: typing.IO[str], name: str, typename: str,
+ cmake_function: str, scope: Scope, *,
+ extra_lines: typing.List[str] = [],
+ indent: int = 0, extra_keys: typing.List[str],
+ **kwargs: typing.Any):
+ # Evaluate total condition of all scopes:
+ recursive_evaluate_scope(scope)
+
+ # 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)
+
+ 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)
+
+ cm_fh.write('{}{}({}\n'.format(spaces(indent), cmake_function, name))
+ for extra_line in extra_lines:
+ cm_fh.write('{} {}\n'.format(spaces(indent), extra_line))
+
+ write_sources_section(cm_fh, scopes[0], indent=indent, **kwargs)
+
+ # Footer:
+ cm_fh.write('{})\n'.format(spaces(indent)))
+
+ write_resources(cm_fh, name, scope, indent)
+
+ write_simd_part(cm_fh, name, scope, 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_extend_target(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_module(cm_fh: typing.IO[str], scope: Scope, *,
+ indent: int = 0) -> None:
+ module_name = scope.TARGET
+ if not module_name.startswith('Qt'):
+ print('XXXXXX Module name {} does not start with Qt!'.format(module_name))
+
+ extra = []
+ if 'static' in scope.get('CONFIG'):
+ extra.append('STATIC')
+ if 'no_module_headers' in scope.get('CONFIG'):
+ extra.append('NO_MODULE_HEADERS')
+
+ write_main_part(cm_fh, module_name[2:], 'Module', 'add_qt_module', scope,
+ extra_lines=extra, indent=indent,
+ known_libraries={'Qt::Core', }, extra_keys=[])
+
+ if 'qt_tracepoints' in scope.get('CONFIG'):
+ tracepoints = scope.get_files('TRACEPOINT_PROVIDER')
+ cm_fh.write('\n\n{}qt_create_tracepoints({} {})\n'
+ .format(spaces(indent), module_name[2:], ' '.join(tracepoints)))
+
+
+def write_tool(cm_fh: typing.IO[str], scope: Scope, *,
+ indent: int = 0) -> None:
+ tool_name = scope.TARGET
+
+ extra = ['BOOTSTRAP'] if 'force_bootstrap' in scope.get('CONFIG') else []
+
+ write_main_part(cm_fh, tool_name, 'Tool', 'add_qt_tool', scope,
+ indent=indent, known_libraries={'Qt::Core', },
+ extra_lines=extra, extra_keys=['CONFIG'])
+
+
+def write_test(cm_fh: typing.IO[str], scope: Scope, *,
+ indent: int = 0) -> None:
+ test_name = scope.TARGET
+ assert test_name
+
+ write_main_part(cm_fh, test_name, 'Test', 'add_qt_test', scope,
+ indent=indent, known_libraries={'Qt::Core', 'Qt::Test',},
+ extra_keys=[])
+
+
+def write_binary(cm_fh: typing.IO[str], scope: Scope,
+ gui: bool = False, *, indent: int = 0) -> None:
+ binary_name = scope.TARGET
+ assert binary_name
+
+ extra = ['GUI',] if gui else[]
+
+ target_path = scope.get_string('target.path')
+ if target_path:
+ target_path = target_path.replace('$$[QT_INSTALL_EXAMPLES]', '${INSTALL_EXAMPLESDIR}')
+ extra.append('OUTPUT_DIRECTORY "{}"'.format(target_path))
+ if 'target' in scope.get('INSTALLS'):
+ extra.append('INSTALL_DIRECTORY "{}"'.format(target_path))
+
+ write_main_part(cm_fh, binary_name, 'Binary', 'add_qt_executable', scope,
+ extra_lines=extra, indent=indent,
+ known_libraries={'Qt::Core', }, extra_keys=['target.path', 'INSTALLS'])
+
+
+def write_plugin(cm_fh, scope, *, indent: int = 0):
+ plugin_name = scope.TARGET
+ assert plugin_name
+
+ write_main_part(cm_fh, plugin_name, 'Plugin', 'add_qt_plugin', scope,
+ indent=indent, known_libraries={'QtCore', }, extra_keys=[])
+
+
+def handle_app_or_lib(scope: Scope, cm_fh: typing.IO[str], *,
+ indent: int = 0) -> None:
+ assert scope.TEMPLATE in ('app', 'lib')
+
+ is_lib = scope.TEMPLATE == 'lib'
+ is_plugin = any('qt_plugin' == s for s in scope.get('_LOADED'))
+
+ if is_lib or 'qt_module' in scope.get('_LOADED'):
+ write_module(cm_fh, scope, indent=indent)
+ elif is_plugin:
+ write_plugin(cm_fh, scope, indent=indent)
+ elif 'qt_tool' in scope.get('_LOADED'):
+ write_tool(cm_fh, scope, indent=indent)
+ else:
+ if 'testcase' in scope.get('CONFIG') \
+ or 'testlib' in scope.get('CONFIG'):
+ write_test(cm_fh, scope, indent=indent)
+ else:
+ gui = 'console' not in scope.get('CONFIG')
+ write_binary(cm_fh, scope, gui, indent=indent)
+
+ ind = spaces(indent)
+ write_source_file_list(cm_fh, scope, '',
+ ['QMAKE_DOCS',],
+ indent,
+ header = '{}add_qt_docs(\n'.format(ind),
+ footer = '{})\n'.format(ind))
+
+
+def cmakeify_scope(scope: Scope, cm_fh: typing.IO[str], *,
+ indent: int = 0) -> None:
+ template = scope.TEMPLATE
+ if template == 'subdirs':
+ handle_subdir(scope, cm_fh, indent=indent)
+ elif template in ('app', 'lib'):
+ handle_app_or_lib(scope, cm_fh, indent=indent)
+ else:
+ print(' XXXX: {}: Template type {} not yet supported.'
+ .format(scope.file, template))
+
+
+def generate_cmakelists(scope: Scope) -> None:
+ with open(scope.cMakeListsFile, 'w') as cm_fh:
+ assert scope.file
+ cm_fh.write('# Generated from {}.\n\n'
+ .format(os.path.basename(scope.file)))
+ cmakeify_scope(scope, cm_fh)
+
+
+def do_include(scope: Scope, *, debug: bool = False) -> None:
+ for c in scope.children:
+ do_include(c)
+
+ for include_file in scope.get_files('_INCLUDED', is_include=True):
+ if not include_file:
+ continue
+ if not os.path.isfile(include_file):
+ print(' XXXX: Failed to include {}.'.format(include_file))
+ continue
+
+ include_result = parseProFile(include_file, debug=debug)
+ include_scope \
+ = Scope.FromDict(None, include_file,
+ include_result.asDict().get('statements'),
+ '', scope.basedir) # This scope will be merged into scope!
+
+ do_include(include_scope)
+
+ scope.merge(include_scope)
+
+
+def main() -> None:
+ args = _parse_commandline()
+
+ debug_parsing = args.debug_parser or args.debug
+
+ for file in args.files:
+ parseresult = parseProFile(file, debug=debug_parsing)
+
+ 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,
+ parseresult.asDict().get('statements'))
+
+ if args.debug_pro_structure or args.debug:
+ print('\n\n#### .pro/.pri file structure:')
+ print(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:')
+ print(file_scope.dump())
+ print('\n#### End of full .pro/.pri file structure.\n')
+
+ generate_cmakelists(file_scope)
+
+
+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..740e834ca5
--- /dev/null
+++ b/util/cmake/pro_conversion_rate.py
@@ -0,0 +1,218 @@
+#!/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 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
+ 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
+
+
+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):
+ entry: os.DirEntry = entry
+
+ 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 = {}
+ 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"):
+ stats['missing examples']['value'] += 1
+ elif rel_path.startswith("tests"):
+ stats['missing tests']['value'] += 1
+ elif rel_path.startswith(os.path.join("src", "plugins")):
+ stats['missing plugins']['value'] += 1
+ elif rel_path.startswith("src"):
+ stats['missing src']['value'] += 1
+
+ for stat in stats:
+ if stats[stat]['value'] > 0:
+ stats[stat]['percentage'] = round(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("{:<40}: {} ({}%)".format(stats[stat]['label'],
+ stats[stat]['value'],
+ stats[stat]['percentage']))
+
+ print("\n{:<40}: {:.10f} seconds".format("Scan time", scan_time))
+ print("{:<40}: {:.10f} seconds".format("Total script time", script_time))
+
+
+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/run_pro2cmake.py b/util/cmake/run_pro2cmake.py
new file mode 100755
index 0000000000..47bc6b661f
--- /dev/null
+++ b/util/cmake/run_pro2cmake.py
@@ -0,0 +1,96 @@
+#!/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
+
+script_path = os.path.dirname(os.path.abspath(__file__))
+base_path = os.path.dirname(script_path)
+pro2cmake = os.path.join(script_path, 'pro2cmake.py')
+
+if len(sys.argv) > 1:
+ base_path = os.path.abspath(sys.argv[1])
+
+
+def find_all_pro_files():
+
+ 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.endswith('/' + pro_file_without_suffix):
+ return dir_name
+ return dir_name + "/__" + pro_file
+
+ all_files = []
+ previous_dir_name: str = None
+ for pro_file in sorted(glob.glob(os.path.join(base_path, '**/*.pro'),
+ recursive=True),
+ 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
+
+
+failed_files = []
+all_files = find_all_pro_files()
+files_count = len(all_files)
+
+with concurrent.futures.ThreadPoolExecutor(initializer=os.nice, initargs=(10,)) as pool:
+
+ def _process_a_file(data: typing.Tuple[str, int, int]) -> typing.Tuple[int, str, str]:
+ filename, index, total = data
+ result = subprocess.run((pro2cmake, os.path.basename(filename)),
+ cwd=os.path.dirname(filename),
+ stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
+ stdout = 'Converted[{}/{}]: {}\n'.format(index, total, filename)
+ 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)
+
+if failed_files:
+ print('The following files were not successfully '
+ 'converted ({} of {}):'.format(len(failed_files), files_count))
+ for f in failed_files:
+ print(' "{}"'.format(f))
+
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/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/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/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/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/test_lc_fixup.py b/util/cmake/tests/test_lc_fixup.py
new file mode 100755
index 0000000000..d3680e895d
--- /dev/null
+++ b/util/cmake/tests/test_lc_fixup.py
@@ -0,0 +1,46 @@
+#!/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 fixup_linecontinuation
+
+from textwrap import dedent
+
+
+def test_no_change():
+ input = "test \\\nline2\n line3"
+ result = fixup_linecontinuation(input)
+ assert input == result
+
+
+def test_fix():
+ input = "test \\\t\nline2\\\n line3\\ \nline4 \\ \t\nline5\\\n\n\n"
+ result = fixup_linecontinuation(input)
+ assert 'test \\\nline2 \\\n line3 \\\nline4 \\\nline5 \\\n\n\n' == 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..c477aa8351
--- /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 pro2cmake 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..3ea2f76a43
--- /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'])
+ assert ['foo', 'bar', 'bar', 'buz'] == result
+
+
+def test_uniqueadd_operation():
+ op = UniqueAddOperation(['bar', 'buz'])
+
+ result = op.process(['foo', 'bar'])
+ assert ['foo', 'bar', 'buz'] == result
+
+
+def test_set_operation():
+ op = SetOperation(['bar', 'buz'])
+
+ result = op.process(['foo', 'bar'])
+ assert ['bar', 'buz'] == result
+
+
+def test_remove_operation():
+ op = RemoveOperation(['bar', 'buz'])
+
+ result = op.process(['foo', 'bar'])
+ 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..79ad0a4945
--- /dev/null
+++ b/util/cmake/tests/test_parsing.py
@@ -0,0 +1,307 @@
+#!/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 pro2cmake 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']
+ 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 include.get('included', '') == '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 result[1].get('included', '') == '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
+
diff --git a/util/cmake/tests/test_scope_handling.py b/util/cmake/tests/test_scope_handling.py
new file mode 100755
index 0000000000..8bca8c8ec5
--- /dev/null
+++ b/util/cmake/tests/test_scope_handling.py
@@ -0,0 +1,338 @@
+#!/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,
+ 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.getString('test1') == 'bar'
+ assert scope.getString('test2', 'not found') == 'not found'
+
+ child = scope.children[0]
+ assert child.total_condition == 'QT_FEATURE_bar AND QT_FEATURE_foo'
+ assert child.getString('test1', 'not found') == 'not found'
+ assert child.getString('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.getString('test1') == 'bar'
+ assert scope.getString('test2', 'not found') == 'not found'
+ assert scope.getString('test3', 'not found') == 'not found'
+
+ child1 = scope.children[0]
+ assert child1.total_condition == 'QT_FEATURE_bar AND QT_FEATURE_foo'
+ assert child1.getString('test1', 'not found') == 'not found'
+ assert child1.getString('test2') == 'bar'
+ assert child1.getString('test3', 'not found') == 'not found'
+
+ child2 = scope.children[1]
+ assert child2.total_condition == 'QT_FEATURE_buz AND QT_FEATURE_foo'
+ assert child2.getString('test1', 'not found') == 'not found'
+ assert child2.getString('test2') == ''
+ assert child2.getString('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.getString('test1') == 'bar'
+ assert scope.getString('test2', 'not found') == 'not found'
+ assert scope.getString('test3', 'not found') == 'not found'
+
+ child1 = scope.children[0]
+ assert child1.total_condition == 'QT_FEATURE_bar AND QT_FEATURE_foo'
+ assert child1.getString('test1', 'not found') == 'not found'
+ assert child1.getString('test2') == 'bar'
+ assert child1.getString('test3', 'not found') == 'not found'
+
+ child2 = scope.children[1]
+ assert child2.total_condition == 'QT_FEATURE_foo AND NOT QT_FEATURE_bar'
+ assert child2.getString('test1', 'not found') == 'not found'
+ assert child2.getString('test2') == ''
+ assert child2.getString('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.getString('test') == 'foo'
+ assert r0.getString('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.getString('test') == 'foo'
+ assert r0.getString('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.getString('test1') == 'parent'
+ assert r0.getString('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.getString('test1') == 'parent'
+ assert r0.getString('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)'