From 80a76df1784a135fa1d86ac88f8c4d2dc6bf8c35 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kai=20K=C3=B6hne?= Date: Wed, 8 Dec 2021 17:25:35 +0100 Subject: Examples: Fix whitespace issues in CMakeLists.txt Pick-to: 6.3 Change-Id: I8e6dd1f250f8be6016ee4164cb2ab7034cbb1203 Reviewed-by: Alexandru Croitor --- .../corelib/bindableproperties/bindablesubscription/CMakeLists.txt | 3 ++- examples/corelib/bindableproperties/subscription/CMakeLists.txt | 4 ++-- examples/corelib/ipc/localfortuneclient/CMakeLists.txt | 4 +++- examples/corelib/ipc/localfortuneserver/CMakeLists.txt | 4 +++- examples/corelib/ipc/sharedmemory/CMakeLists.txt | 4 +++- examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt | 4 +++- examples/corelib/platform/androidnotifier/CMakeLists.txt | 2 +- examples/corelib/serialization/cbordump/CMakeLists.txt | 4 +++- examples/corelib/serialization/convert/CMakeLists.txt | 4 +++- examples/corelib/serialization/savegame/CMakeLists.txt | 4 +++- examples/corelib/threads/mandelbrot/CMakeLists.txt | 4 +++- examples/corelib/threads/queuedcustomtype/CMakeLists.txt | 4 +++- examples/corelib/threads/semaphores/CMakeLists.txt | 4 +++- examples/corelib/threads/waitconditions/CMakeLists.txt | 4 +++- examples/corelib/tools/contiguouscache/CMakeLists.txt | 4 +++- examples/corelib/tools/customtype/CMakeLists.txt | 4 +++- examples/corelib/tools/customtypesending/CMakeLists.txt | 4 +++- examples/dbus/chat/CMakeLists.txt | 5 ++++- examples/dbus/listnames/CMakeLists.txt | 4 +++- examples/dbus/remotecontrolledcar/car/CMakeLists.txt | 4 +++- examples/dbus/remotecontrolledcar/controller/CMakeLists.txt | 4 +++- examples/embedded/digiflip/CMakeLists.txt | 4 +++- examples/embedded/flickable/CMakeLists.txt | 4 +++- examples/embedded/flightinfo/CMakeLists.txt | 5 +++-- examples/embedded/lightmaps/CMakeLists.txt | 4 +++- examples/embedded/raycasting/CMakeLists.txt | 5 +++-- examples/embedded/styleexample/CMakeLists.txt | 5 +++-- examples/gui/analogclock/CMakeLists.txt | 6 ++++-- examples/gui/rasterwindow/CMakeLists.txt | 5 ++++- examples/network/blockingfortuneclient/CMakeLists.txt | 4 +++- examples/network/broadcastreceiver/CMakeLists.txt | 4 +++- examples/network/broadcastsender/CMakeLists.txt | 4 +++- examples/network/dnslookup/CMakeLists.txt | 4 +++- examples/network/download/CMakeLists.txt | 4 +++- examples/network/downloadmanager/CMakeLists.txt | 4 +++- examples/network/fortuneclient/CMakeLists.txt | 4 +++- examples/network/fortuneserver/CMakeLists.txt | 4 +++- examples/network/googlesuggest/CMakeLists.txt | 4 +++- examples/network/http/CMakeLists.txt | 4 +++- examples/network/loopback/CMakeLists.txt | 4 +++- examples/network/multicastreceiver/CMakeLists.txt | 4 +++- examples/network/multicastsender/CMakeLists.txt | 4 +++- examples/network/multistreamclient/CMakeLists.txt | 4 +++- examples/network/multistreamserver/CMakeLists.txt | 4 +++- examples/network/network-chat/CMakeLists.txt | 4 +++- examples/network/securesocketclient/CMakeLists.txt | 5 +++-- examples/network/secureudpclient/CMakeLists.txt | 4 +++- examples/network/secureudpserver/CMakeLists.txt | 4 +++- examples/network/threadedfortuneserver/CMakeLists.txt | 4 +++- examples/network/torrent/CMakeLists.txt | 5 +++-- examples/opengl/2dpainting/CMakeLists.txt | 4 +++- examples/opengl/computegles31/CMakeLists.txt | 5 +++-- examples/opengl/contextinfo/CMakeLists.txt | 4 +++- examples/opengl/cube/CMakeLists.txt | 6 ++++-- examples/opengl/hellogl2/CMakeLists.txt | 4 +++- examples/opengl/hellogles3/CMakeLists.txt | 5 +++-- examples/opengl/hellowindow/CMakeLists.txt | 4 +++- examples/opengl/openglwindow/CMakeLists.txt | 4 +++- examples/opengl/paintedwindow/CMakeLists.txt | 4 +++- examples/opengl/qopenglwidget/CMakeLists.txt | 5 +++-- examples/opengl/qopenglwindow/CMakeLists.txt | 5 +++-- examples/opengl/textures/CMakeLists.txt | 5 +++-- examples/opengl/threadedqopenglwidget/CMakeLists.txt | 4 +++- examples/qpa/qrasterwindow/CMakeLists.txt | 4 +++- examples/qpa/windows/CMakeLists.txt | 4 +++- examples/qtconcurrent/imagescaling/CMakeLists.txt | 4 +++- examples/qtconcurrent/map/CMakeLists.txt | 5 ++++- examples/qtconcurrent/progressdialog/CMakeLists.txt | 4 +++- examples/qtconcurrent/runfunction/CMakeLists.txt | 4 +++- examples/qtconcurrent/wordcount/CMakeLists.txt | 4 +++- examples/qtestlib/tutorial1/CMakeLists.txt | 4 +++- examples/qtestlib/tutorial2/CMakeLists.txt | 4 +++- examples/qtestlib/tutorial3/CMakeLists.txt | 4 +++- examples/qtestlib/tutorial4/CMakeLists.txt | 4 +++- examples/qtestlib/tutorial5/CMakeLists.txt | 4 +++- examples/sql/books/CMakeLists.txt | 5 +++-- examples/sql/cachedtable/CMakeLists.txt | 4 +++- examples/sql/drilldown/CMakeLists.txt | 5 +++-- examples/sql/masterdetail/CMakeLists.txt | 5 +++-- examples/sql/querymodel/CMakeLists.txt | 4 +++- examples/sql/relationaltablemodel/CMakeLists.txt | 4 +++- examples/sql/sqlbrowser/CMakeLists.txt | 4 +++- examples/sql/sqlwidgetmapper/CMakeLists.txt | 4 +++- examples/sql/tablemodel/CMakeLists.txt | 4 +++- examples/vulkan/hellovulkancubes/CMakeLists.txt | 7 +++++-- examples/vulkan/hellovulkantexture/CMakeLists.txt | 5 +++-- examples/vulkan/hellovulkantriangle/CMakeLists.txt | 7 +++++-- examples/vulkan/hellovulkanwidget/CMakeLists.txt | 7 +++++-- examples/vulkan/hellovulkanwindow/CMakeLists.txt | 4 +++- examples/widgets/animation/easing/CMakeLists.txt | 5 +++-- examples/widgets/desktop/screenshot/CMakeLists.txt | 4 +++- examples/widgets/desktop/systray/CMakeLists.txt | 5 +++-- examples/widgets/dialogs/classwizard/CMakeLists.txt | 5 +++-- examples/widgets/dialogs/extension/CMakeLists.txt | 4 +++- examples/widgets/dialogs/findfiles/CMakeLists.txt | 4 +++- examples/widgets/dialogs/licensewizard/CMakeLists.txt | 5 +++-- examples/widgets/dialogs/standarddialogs/CMakeLists.txt | 4 +++- examples/widgets/dialogs/tabdialog/CMakeLists.txt | 4 +++- examples/widgets/dialogs/trivialwizard/CMakeLists.txt | 4 +++- examples/widgets/draganddrop/draggableicons/CMakeLists.txt | 5 +++-- examples/widgets/draganddrop/draggabletext/CMakeLists.txt | 5 +++-- examples/widgets/draganddrop/dropsite/CMakeLists.txt | 4 +++- examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt | 5 +++-- examples/widgets/draganddrop/puzzle/CMakeLists.txt | 5 +++-- examples/widgets/effects/blurpicker/CMakeLists.txt | 5 +++-- examples/widgets/effects/fademessage/CMakeLists.txt | 5 +++-- examples/widgets/gallery/CMakeLists.txt | 4 +++- examples/widgets/gestures/imagegestures/CMakeLists.txt | 4 +++- examples/widgets/graphicsview/anchorlayout/CMakeLists.txt | 4 +++- examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt | 5 +++-- examples/widgets/graphicsview/chip/CMakeLists.txt | 5 +++-- examples/widgets/graphicsview/collidingmice/CMakeLists.txt | 5 +++-- examples/widgets/graphicsview/diagramscene/CMakeLists.txt | 5 +++-- examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt | 5 +++-- examples/widgets/graphicsview/elasticnodes/CMakeLists.txt | 4 +++- examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt | 5 +++-- examples/widgets/graphicsview/flowlayout/CMakeLists.txt | 4 +++- examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt | 4 +++- examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt | 5 +++-- examples/widgets/itemviews/addressbook/CMakeLists.txt | 4 +++- examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt | 4 +++- examples/widgets/itemviews/chart/CMakeLists.txt | 5 +++-- examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt | 4 +++- examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt | 4 +++- examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt | 5 +++-- examples/widgets/itemviews/dirview/CMakeLists.txt | 4 +++- examples/widgets/itemviews/editabletreemodel/CMakeLists.txt | 5 +++-- examples/widgets/itemviews/fetchmore/CMakeLists.txt | 4 +++- examples/widgets/itemviews/flattreeview/CMakeLists.txt | 4 +++- examples/widgets/itemviews/frozencolumn/CMakeLists.txt | 5 +++-- examples/widgets/itemviews/interview/CMakeLists.txt | 5 +++-- examples/widgets/itemviews/pixelator/CMakeLists.txt | 5 +++-- examples/widgets/itemviews/puzzle/CMakeLists.txt | 5 +++-- examples/widgets/itemviews/simpledommodel/CMakeLists.txt | 4 +++- examples/widgets/itemviews/simpletreemodel/CMakeLists.txt | 5 +++-- examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt | 4 +++- examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt | 4 +++- examples/widgets/itemviews/spreadsheet/CMakeLists.txt | 5 +++-- examples/widgets/itemviews/stardelegate/CMakeLists.txt | 4 +++- examples/widgets/itemviews/storageview/CMakeLists.txt | 4 +++- examples/widgets/layouts/basiclayouts/CMakeLists.txt | 4 +++- examples/widgets/layouts/borderlayout/CMakeLists.txt | 4 +++- examples/widgets/layouts/dynamiclayouts/CMakeLists.txt | 4 +++- examples/widgets/layouts/flowlayout/CMakeLists.txt | 4 +++- examples/widgets/mainwindows/application/CMakeLists.txt | 5 +++-- examples/widgets/mainwindows/dockwidgets/CMakeLists.txt | 5 +++-- examples/widgets/mainwindows/mainwindow/CMakeLists.txt | 5 +++-- examples/widgets/mainwindows/mdi/CMakeLists.txt | 5 +++-- examples/widgets/mainwindows/menus/CMakeLists.txt | 4 +++- examples/widgets/mainwindows/sdi/CMakeLists.txt | 5 +++-- examples/widgets/painting/affine/CMakeLists.txt | 6 ++++-- examples/widgets/painting/basicdrawing/CMakeLists.txt | 5 +++-- examples/widgets/painting/composition/CMakeLists.txt | 6 ++++-- examples/widgets/painting/concentriccircles/CMakeLists.txt | 4 +++- examples/widgets/painting/deform/CMakeLists.txt | 6 ++++-- examples/widgets/painting/fontsampler/CMakeLists.txt | 4 +++- examples/widgets/painting/gradients/CMakeLists.txt | 6 ++++-- examples/widgets/painting/imagecomposition/CMakeLists.txt | 5 +++-- examples/widgets/painting/painterpaths/CMakeLists.txt | 4 +++- examples/widgets/painting/pathstroke/CMakeLists.txt | 6 ++++-- examples/widgets/painting/shared/CMakeLists.txt | 1 + examples/widgets/painting/transformations/CMakeLists.txt | 4 +++- examples/widgets/richtext/calendar/CMakeLists.txt | 4 +++- examples/widgets/richtext/orderform/CMakeLists.txt | 4 +++- examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt | 4 +++- examples/widgets/richtext/textedit/CMakeLists.txt | 5 +++-- examples/widgets/scroller/graphicsview/CMakeLists.txt | 4 +++- examples/widgets/tools/completer/CMakeLists.txt | 5 +++-- examples/widgets/tools/customcompleter/CMakeLists.txt | 5 +++-- examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt | 2 ++ examples/widgets/tools/echoplugin/plugin/CMakeLists.txt | 3 +++ examples/widgets/tools/i18n/CMakeLists.txt | 5 +++-- examples/widgets/tools/plugandpaint/app/CMakeLists.txt | 2 ++ .../widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt | 2 ++ .../widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt | 3 +++ examples/widgets/tools/regularexpression/CMakeLists.txt | 5 +++-- examples/widgets/tools/settingseditor/CMakeLists.txt | 4 +++- examples/widgets/tools/styleplugin/plugin/CMakeLists.txt | 3 +++ examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt | 3 +++ examples/widgets/tools/treemodelcompleter/CMakeLists.txt | 5 +++-- examples/widgets/tools/undo/CMakeLists.txt | 5 +++-- examples/widgets/tools/undoframework/CMakeLists.txt | 5 +++-- examples/widgets/touch/dials/CMakeLists.txt | 4 +++- examples/widgets/touch/fingerpaint/CMakeLists.txt | 4 +++- examples/widgets/touch/knobs/CMakeLists.txt | 4 +++- examples/widgets/touch/pinchzoom/CMakeLists.txt | 5 +++-- examples/widgets/tutorials/addressbook/part1/CMakeLists.txt | 4 +++- examples/widgets/tutorials/addressbook/part2/CMakeLists.txt | 4 +++- examples/widgets/tutorials/addressbook/part3/CMakeLists.txt | 4 +++- examples/widgets/tutorials/addressbook/part4/CMakeLists.txt | 4 +++- examples/widgets/tutorials/addressbook/part5/CMakeLists.txt | 4 +++- examples/widgets/tutorials/addressbook/part6/CMakeLists.txt | 4 +++- examples/widgets/tutorials/addressbook/part7/CMakeLists.txt | 4 +++- .../widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt | 4 +++- .../widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt | 4 +++- .../widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt | 4 +++- .../widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt | 4 +++- .../widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt | 4 +++- examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt | 4 +++- examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt | 4 +++- .../widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt | 4 +++- examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt | 4 +++- examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt | 4 +++- examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt | 4 +++- examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt | 4 +++- examples/widgets/tutorials/notepad/CMakeLists.txt | 5 +++-- examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt | 4 +++- examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt | 4 +++- examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt | 4 +++- examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt | 4 +++- examples/widgets/widgets/analogclock/CMakeLists.txt | 4 +++- examples/widgets/widgets/calculator/CMakeLists.txt | 4 +++- examples/widgets/widgets/calendarwidget/CMakeLists.txt | 4 +++- examples/widgets/widgets/charactermap/CMakeLists.txt | 4 +++- examples/widgets/widgets/codeeditor/CMakeLists.txt | 4 +++- examples/widgets/widgets/digitalclock/CMakeLists.txt | 4 +++- examples/widgets/widgets/elidedlabel/CMakeLists.txt | 4 +++- examples/widgets/widgets/groupbox/CMakeLists.txt | 4 +++- examples/widgets/widgets/icons/CMakeLists.txt | 4 +++- examples/widgets/widgets/imageviewer/CMakeLists.txt | 4 +++- examples/widgets/widgets/lineedits/CMakeLists.txt | 4 +++- examples/widgets/widgets/mousebuttons/CMakeLists.txt | 4 +++- examples/widgets/widgets/movie/CMakeLists.txt | 4 +++- examples/widgets/widgets/scribble/CMakeLists.txt | 4 +++- examples/widgets/widgets/shapedclock/CMakeLists.txt | 4 +++- examples/widgets/widgets/sliders/CMakeLists.txt | 4 +++- examples/widgets/widgets/spinboxes/CMakeLists.txt | 4 +++- examples/widgets/widgets/styles/CMakeLists.txt | 5 +++-- examples/widgets/widgets/stylesheet/CMakeLists.txt | 5 +++-- examples/widgets/widgets/tablet/CMakeLists.txt | 5 +++-- examples/widgets/widgets/tetrix/CMakeLists.txt | 4 +++- examples/widgets/widgets/tooltips/CMakeLists.txt | 5 +++-- examples/widgets/widgets/validators/CMakeLists.txt | 5 +++-- examples/widgets/widgets/wiggly/CMakeLists.txt | 4 +++- examples/widgets/widgets/windowflags/CMakeLists.txt | 4 +++- examples/widgets/windowcontainer/CMakeLists.txt | 4 +++- examples/xml/dombookmarks/CMakeLists.txt | 4 +++- examples/xml/htmlinfo/CMakeLists.txt | 5 +++-- examples/xml/rsslisting/CMakeLists.txt | 4 +++- examples/xml/streambookmarks/CMakeLists.txt | 4 +++- examples/xml/xmlstreamlint/CMakeLists.txt | 4 +++- 241 files changed, 730 insertions(+), 307 deletions(-) diff --git a/examples/corelib/bindableproperties/bindablesubscription/CMakeLists.txt b/examples/corelib/bindableproperties/bindablesubscription/CMakeLists.txt index 6787858538..eb9e99b207 100644 --- a/examples/corelib/bindableproperties/bindablesubscription/CMakeLists.txt +++ b/examples/corelib/bindableproperties/bindablesubscription/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/bindableproperties/bindablesubscription") @@ -22,6 +22,7 @@ qt_add_executable(bindablesubscription bindablesubscription.cpp bindablesubscription.h bindableuser.cpp bindableuser.h ) + target_link_libraries(bindablesubscription PUBLIC Qt::Core Qt::Gui diff --git a/examples/corelib/bindableproperties/subscription/CMakeLists.txt b/examples/corelib/bindableproperties/subscription/CMakeLists.txt index 841f535daf..b97d2a83b7 100644 --- a/examples/corelib/bindableproperties/subscription/CMakeLists.txt +++ b/examples/corelib/bindableproperties/subscription/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/bindableproperties/subscription") @@ -21,13 +21,13 @@ qt_add_executable(subscription subscription.cpp subscription.h user.cpp user.h ) + target_link_libraries(subscription PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(countries_resource_files "../shared/finland.png" diff --git a/examples/corelib/ipc/localfortuneclient/CMakeLists.txt b/examples/corelib/ipc/localfortuneclient/CMakeLists.txt index 658832307d..18218431a8 100644 --- a/examples/corelib/ipc/localfortuneclient/CMakeLists.txt +++ b/examples/corelib/ipc/localfortuneclient/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/ipc/localfortuneclient") @@ -19,10 +19,12 @@ qt_add_executable(localfortuneclient client.cpp client.h main.cpp ) + set_target_properties(localfortuneclient PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(localfortuneclient PUBLIC Qt::Core Qt::Gui diff --git a/examples/corelib/ipc/localfortuneserver/CMakeLists.txt b/examples/corelib/ipc/localfortuneserver/CMakeLists.txt index a08502ea4e..ba2eda505f 100644 --- a/examples/corelib/ipc/localfortuneserver/CMakeLists.txt +++ b/examples/corelib/ipc/localfortuneserver/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/ipc/localfortuneserver") @@ -19,10 +19,12 @@ qt_add_executable(localfortuneserver main.cpp server.cpp server.h ) + set_target_properties(localfortuneserver PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(localfortuneserver PUBLIC Qt::Core Qt::Gui diff --git a/examples/corelib/ipc/sharedmemory/CMakeLists.txt b/examples/corelib/ipc/sharedmemory/CMakeLists.txt index dc75abd637..f8c8f9ae37 100644 --- a/examples/corelib/ipc/sharedmemory/CMakeLists.txt +++ b/examples/corelib/ipc/sharedmemory/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/ipc/sharedmemory") @@ -19,10 +19,12 @@ qt_add_executable(sharedmemory dialog.cpp dialog.h dialog.ui main.cpp ) + set_target_properties(sharedmemory PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(sharedmemory PUBLIC Qt::Core Qt::Gui diff --git a/examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt b/examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt index 3e2fb51411..1e0545b63c 100644 --- a/examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt +++ b/examples/corelib/mimetypes/mimetypebrowser/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/mimetypes/mimetypebrowser") @@ -20,10 +20,12 @@ qt_add_executable(mimetypebrowser mainwindow.cpp mainwindow.h mimetypemodel.cpp mimetypemodel.h ) + set_target_properties(mimetypebrowser PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE FALSE ) + target_link_libraries(mimetypebrowser PUBLIC Qt::Core Qt::Gui diff --git a/examples/corelib/platform/androidnotifier/CMakeLists.txt b/examples/corelib/platform/androidnotifier/CMakeLists.txt index b042a40a72..31ea2336ac 100644 --- a/examples/corelib/platform/androidnotifier/CMakeLists.txt +++ b/examples/corelib/platform/androidnotifier/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() find_package(Qt6 REQUIRED COMPONENTS Widgets) diff --git a/examples/corelib/serialization/cbordump/CMakeLists.txt b/examples/corelib/serialization/cbordump/CMakeLists.txt index f37c39295e..046447995d 100644 --- a/examples/corelib/serialization/cbordump/CMakeLists.txt +++ b/examples/corelib/serialization/cbordump/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/serialization/cbordump") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core) qt_add_executable(cbordump main.cpp ) + set_target_properties(cbordump PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE FALSE ) + target_link_libraries(cbordump PUBLIC Qt::Core ) diff --git a/examples/corelib/serialization/convert/CMakeLists.txt b/examples/corelib/serialization/convert/CMakeLists.txt index bf2aa15f16..55e016aedf 100644 --- a/examples/corelib/serialization/convert/CMakeLists.txt +++ b/examples/corelib/serialization/convert/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/serialization/convert") @@ -25,10 +25,12 @@ qt_add_executable(convert textconverter.cpp textconverter.h xmlconverter.cpp xmlconverter.h ) + set_target_properties(convert PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE FALSE ) + target_link_libraries(convert PUBLIC Qt::Core ) diff --git a/examples/corelib/serialization/savegame/CMakeLists.txt b/examples/corelib/serialization/savegame/CMakeLists.txt index 3a04bb8c61..3ffc3c97d3 100644 --- a/examples/corelib/serialization/savegame/CMakeLists.txt +++ b/examples/corelib/serialization/savegame/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/serialization/savegame") @@ -21,10 +21,12 @@ qt_add_executable(savegame level.cpp level.h main.cpp ) + set_target_properties(savegame PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE FALSE ) + target_link_libraries(savegame PUBLIC Qt::Core ) diff --git a/examples/corelib/threads/mandelbrot/CMakeLists.txt b/examples/corelib/threads/mandelbrot/CMakeLists.txt index 6ab2f4df72..c946e35e76 100644 --- a/examples/corelib/threads/mandelbrot/CMakeLists.txt +++ b/examples/corelib/threads/mandelbrot/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/threads/mandelbrot") @@ -20,10 +20,12 @@ qt_add_executable(mandelbrot mandelbrotwidget.cpp mandelbrotwidget.h renderthread.cpp renderthread.h ) + set_target_properties(mandelbrot PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mandelbrot PUBLIC Qt::Core Qt::Gui diff --git a/examples/corelib/threads/queuedcustomtype/CMakeLists.txt b/examples/corelib/threads/queuedcustomtype/CMakeLists.txt index 97553952ee..69e3e4b35d 100644 --- a/examples/corelib/threads/queuedcustomtype/CMakeLists.txt +++ b/examples/corelib/threads/queuedcustomtype/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/threads/queuedcustomtype") @@ -21,10 +21,12 @@ qt_add_executable(queuedcustomtype renderthread.cpp renderthread.h window.cpp window.h ) + set_target_properties(queuedcustomtype PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(queuedcustomtype PUBLIC Qt::Core Qt::Gui diff --git a/examples/corelib/threads/semaphores/CMakeLists.txt b/examples/corelib/threads/semaphores/CMakeLists.txt index 2268b1ce98..f5206dabc9 100644 --- a/examples/corelib/threads/semaphores/CMakeLists.txt +++ b/examples/corelib/threads/semaphores/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/threads/semaphores") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core) qt_add_executable(semaphores semaphores.cpp ) + set_target_properties(semaphores PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE FALSE ) + target_link_libraries(semaphores PUBLIC Qt::Core ) diff --git a/examples/corelib/threads/waitconditions/CMakeLists.txt b/examples/corelib/threads/waitconditions/CMakeLists.txt index f1e2c7826a..8b9a24d584 100644 --- a/examples/corelib/threads/waitconditions/CMakeLists.txt +++ b/examples/corelib/threads/waitconditions/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/threads/waitconditions") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core) qt_add_executable(waitconditions waitconditions.cpp ) + set_target_properties(waitconditions PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE FALSE ) + target_link_libraries(waitconditions PUBLIC Qt::Core ) diff --git a/examples/corelib/tools/contiguouscache/CMakeLists.txt b/examples/corelib/tools/contiguouscache/CMakeLists.txt index 5ad5d5d83f..1b47b4a374 100644 --- a/examples/corelib/tools/contiguouscache/CMakeLists.txt +++ b/examples/corelib/tools/contiguouscache/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/tools/contiguouscache") @@ -19,10 +19,12 @@ qt_add_executable(contiguouscache main.cpp randomlistmodel.cpp randomlistmodel.h ) + set_target_properties(contiguouscache PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(contiguouscache PUBLIC Qt::Core Qt::Gui diff --git a/examples/corelib/tools/customtype/CMakeLists.txt b/examples/corelib/tools/customtype/CMakeLists.txt index 037126cb90..7266ad6a0f 100644 --- a/examples/corelib/tools/customtype/CMakeLists.txt +++ b/examples/corelib/tools/customtype/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/tools/customtype") @@ -19,10 +19,12 @@ qt_add_executable(customtype main.cpp message.cpp message.h ) + set_target_properties(customtype PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(customtype PUBLIC Qt::Core Qt::Gui diff --git a/examples/corelib/tools/customtypesending/CMakeLists.txt b/examples/corelib/tools/customtypesending/CMakeLists.txt index 07fcab0da1..cbe3c8279d 100644 --- a/examples/corelib/tools/customtypesending/CMakeLists.txt +++ b/examples/corelib/tools/customtypesending/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/corelib/tools/customtypesending") @@ -20,10 +20,12 @@ qt_add_executable(customtypesending message.cpp message.h window.cpp window.h ) + set_target_properties(customtypesending PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(customtypesending PUBLIC Qt::Core Qt::Gui diff --git a/examples/dbus/chat/CMakeLists.txt b/examples/dbus/chat/CMakeLists.txt index 8d5354212f..b72138b87c 100644 --- a/examples/dbus/chat/CMakeLists.txt +++ b/examples/dbus/chat/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/dbus/chat") @@ -20,6 +20,7 @@ qt_add_dbus_interface(chat_SRCS org.example.chat.xml chat_interface ) + qt_add_dbus_adaptor(chat_SRCS org.example.chat.xml qobject.h @@ -33,10 +34,12 @@ qt_add_executable(chat chatsetnickname.ui ${chat_SRCS} ) + set_target_properties(chat PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(chat PUBLIC Qt::Core Qt::DBus diff --git a/examples/dbus/listnames/CMakeLists.txt b/examples/dbus/listnames/CMakeLists.txt index 589c9ca269..fd18051484 100644 --- a/examples/dbus/listnames/CMakeLists.txt +++ b/examples/dbus/listnames/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/dbus/listnames") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core DBus) qt_add_executable(listnames listnames.cpp ) + set_target_properties(listnames PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(listnames PUBLIC Qt::Core Qt::DBus diff --git a/examples/dbus/remotecontrolledcar/car/CMakeLists.txt b/examples/dbus/remotecontrolledcar/car/CMakeLists.txt index a40213697e..05960b953d 100644 --- a/examples/dbus/remotecontrolledcar/car/CMakeLists.txt +++ b/examples/dbus/remotecontrolledcar/car/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/dbus/remotecontrolledcar/car") @@ -28,10 +28,12 @@ qt_add_executable(car main.cpp ${car_SRCS} ) + set_target_properties(car PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(car PUBLIC Qt::Core Qt::DBus diff --git a/examples/dbus/remotecontrolledcar/controller/CMakeLists.txt b/examples/dbus/remotecontrolledcar/controller/CMakeLists.txt index 716fa7fe0d..6fc18b4751 100644 --- a/examples/dbus/remotecontrolledcar/controller/CMakeLists.txt +++ b/examples/dbus/remotecontrolledcar/controller/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/dbus/remotecontrolledcar/controller") @@ -26,10 +26,12 @@ qt_add_executable(controller main.cpp ${controller_SRCS} ) + set_target_properties(controller PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(controller PUBLIC Qt::Core Qt::DBus diff --git a/examples/embedded/digiflip/CMakeLists.txt b/examples/embedded/digiflip/CMakeLists.txt index 2994662e14..297652a33b 100644 --- a/examples/embedded/digiflip/CMakeLists.txt +++ b/examples/embedded/digiflip/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/embedded/digiflip") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(digiflip digiflip.cpp ) + set_target_properties(digiflip PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(digiflip PUBLIC Qt::Core Qt::Gui diff --git a/examples/embedded/flickable/CMakeLists.txt b/examples/embedded/flickable/CMakeLists.txt index abe99377c6..fe23fabd33 100644 --- a/examples/embedded/flickable/CMakeLists.txt +++ b/examples/embedded/flickable/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/embedded/flickable") @@ -19,10 +19,12 @@ qt_add_executable(flickable flickable.cpp flickable.h main.cpp ) + set_target_properties(flickable PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(flickable PUBLIC Qt::Core Qt::Gui diff --git a/examples/embedded/flightinfo/CMakeLists.txt b/examples/embedded/flightinfo/CMakeLists.txt index 988bec4ee2..4d96c87242 100644 --- a/examples/embedded/flightinfo/CMakeLists.txt +++ b/examples/embedded/flightinfo/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/embedded/flightinfo") @@ -19,10 +19,12 @@ qt_add_executable(flightinfo flightinfo.cpp form.ui ) + set_target_properties(flightinfo PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(flightinfo PUBLIC Qt::Core Qt::Gui @@ -30,7 +32,6 @@ target_link_libraries(flightinfo PUBLIC Qt::Widgets ) - # Resources: set(flightinfo_resource_files "aircraft.png" diff --git a/examples/embedded/lightmaps/CMakeLists.txt b/examples/embedded/lightmaps/CMakeLists.txt index adbba07655..acfae85821 100644 --- a/examples/embedded/lightmaps/CMakeLists.txt +++ b/examples/embedded/lightmaps/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/embedded/lightmaps") @@ -21,10 +21,12 @@ qt_add_executable(lightmaps mapzoom.cpp mapzoom.h slippymap.cpp slippymap.h ) + set_target_properties(lightmaps PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(lightmaps PUBLIC Qt::Core Qt::Gui diff --git a/examples/embedded/raycasting/CMakeLists.txt b/examples/embedded/raycasting/CMakeLists.txt index e7c08ed54a..d94a716a37 100644 --- a/examples/embedded/raycasting/CMakeLists.txt +++ b/examples/embedded/raycasting/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/embedded/raycasting") @@ -18,17 +18,18 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(raycasting raycasting.cpp ) + set_target_properties(raycasting PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(raycasting PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(raycasting_resource_files "textures.png" diff --git a/examples/embedded/styleexample/CMakeLists.txt b/examples/embedded/styleexample/CMakeLists.txt index 340ce67133..4c836f0a36 100644 --- a/examples/embedded/styleexample/CMakeLists.txt +++ b/examples/embedded/styleexample/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/embedded/styleexample") @@ -19,17 +19,18 @@ qt_add_executable(styleexample main.cpp stylewidget.cpp stylewidget.h stylewidget.ui ) + set_target_properties(styleexample PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(styleexample PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(styleexample_resource_files "files/add.png" diff --git a/examples/gui/analogclock/CMakeLists.txt b/examples/gui/analogclock/CMakeLists.txt index 0cd882a722..57b73f4820 100644 --- a/examples/gui/analogclock/CMakeLists.txt +++ b/examples/gui/analogclock/CMakeLists.txt @@ -1,7 +1,6 @@ cmake_minimum_required(VERSION 3.16) project(analogclock LANGUAGES CXX) - set(CMAKE_INCLUDE_CURRENT_DIR ON) set(CMAKE_AUTOMOC ON) @@ -9,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/gui/gui_analogclock") @@ -20,13 +19,16 @@ qt_add_executable(gui_analogclock ../rasterwindow/rasterwindow.cpp ../rasterwindow/rasterwindow.h main.cpp ) + set_target_properties(gui_analogclock PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(gui_analogclock PUBLIC ../rasterwindow ) + target_link_libraries(gui_analogclock PUBLIC Qt::Gui ) diff --git a/examples/gui/rasterwindow/CMakeLists.txt b/examples/gui/rasterwindow/CMakeLists.txt index 8d3efdd9c9..0291591174 100644 --- a/examples/gui/rasterwindow/CMakeLists.txt +++ b/examples/gui/rasterwindow/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/gui/rasterwindow") @@ -19,13 +19,16 @@ qt_add_executable(rasterwindow main.cpp rasterwindow.cpp rasterwindow.h ) + set_target_properties(rasterwindow PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(rasterwindow PUBLIC ${CMAKE_CURRENT_SOURCE_DIR} ) + target_link_libraries(rasterwindow PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/blockingfortuneclient/CMakeLists.txt b/examples/network/blockingfortuneclient/CMakeLists.txt index 712b8a3185..b59367f69b 100644 --- a/examples/network/blockingfortuneclient/CMakeLists.txt +++ b/examples/network/blockingfortuneclient/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/blockingfortuneclient") @@ -20,10 +20,12 @@ qt_add_executable(blockingfortuneclient fortunethread.cpp fortunethread.h main.cpp ) + set_target_properties(blockingfortuneclient PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(blockingfortuneclient PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/broadcastreceiver/CMakeLists.txt b/examples/network/broadcastreceiver/CMakeLists.txt index 503626057b..998434b4e9 100644 --- a/examples/network/broadcastreceiver/CMakeLists.txt +++ b/examples/network/broadcastreceiver/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/broadcastreceiver") @@ -19,10 +19,12 @@ qt_add_executable(broadcastreceiver main.cpp receiver.cpp receiver.h ) + set_target_properties(broadcastreceiver PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(broadcastreceiver PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/broadcastsender/CMakeLists.txt b/examples/network/broadcastsender/CMakeLists.txt index 9c921de8b6..1b045766a7 100644 --- a/examples/network/broadcastsender/CMakeLists.txt +++ b/examples/network/broadcastsender/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/broadcastsender") @@ -19,10 +19,12 @@ qt_add_executable(broadcastsender main.cpp sender.cpp sender.h ) + set_target_properties(broadcastsender PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(broadcastsender PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/dnslookup/CMakeLists.txt b/examples/network/dnslookup/CMakeLists.txt index d4c869ea78..303d042aa5 100644 --- a/examples/network/dnslookup/CMakeLists.txt +++ b/examples/network/dnslookup/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/dnslookup") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Network) qt_add_executable(dnslookup dnslookup.cpp dnslookup.h ) + set_target_properties(dnslookup PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE FALSE ) + target_link_libraries(dnslookup PUBLIC Qt::Core Qt::Network diff --git a/examples/network/download/CMakeLists.txt b/examples/network/download/CMakeLists.txt index 9c987dd143..62db5c910f 100644 --- a/examples/network/download/CMakeLists.txt +++ b/examples/network/download/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/download") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Network) qt_add_executable(download main.cpp ) + set_target_properties(download PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE FALSE ) + target_link_libraries(download PUBLIC Qt::Core Qt::Network diff --git a/examples/network/downloadmanager/CMakeLists.txt b/examples/network/downloadmanager/CMakeLists.txt index 5ee773ae26..d268749e57 100644 --- a/examples/network/downloadmanager/CMakeLists.txt +++ b/examples/network/downloadmanager/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/downloadmanager") @@ -20,10 +20,12 @@ qt_add_executable(downloadmanager main.cpp textprogressbar.cpp textprogressbar.h ) + set_target_properties(downloadmanager PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE FALSE ) + target_link_libraries(downloadmanager PUBLIC Qt::Core Qt::Network diff --git a/examples/network/fortuneclient/CMakeLists.txt b/examples/network/fortuneclient/CMakeLists.txt index a1e763408c..f3d13c8a77 100644 --- a/examples/network/fortuneclient/CMakeLists.txt +++ b/examples/network/fortuneclient/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/fortuneclient") @@ -19,10 +19,12 @@ qt_add_executable(fortuneclient client.cpp client.h main.cpp ) + set_target_properties(fortuneclient PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(fortuneclient PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/fortuneserver/CMakeLists.txt b/examples/network/fortuneserver/CMakeLists.txt index f4dcfb5f98..7012ef645f 100644 --- a/examples/network/fortuneserver/CMakeLists.txt +++ b/examples/network/fortuneserver/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/fortuneserver") @@ -19,10 +19,12 @@ qt_add_executable(fortuneserver main.cpp server.cpp server.h ) + set_target_properties(fortuneserver PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(fortuneserver PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/googlesuggest/CMakeLists.txt b/examples/network/googlesuggest/CMakeLists.txt index 4346fde001..72b97dd478 100644 --- a/examples/network/googlesuggest/CMakeLists.txt +++ b/examples/network/googlesuggest/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/googlesuggest") @@ -20,10 +20,12 @@ qt_add_executable(googlesuggest main.cpp searchbox.cpp searchbox.h ) + set_target_properties(googlesuggest PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(googlesuggest PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/http/CMakeLists.txt b/examples/network/http/CMakeLists.txt index 3a1a1245bf..1b52950bef 100644 --- a/examples/network/http/CMakeLists.txt +++ b/examples/network/http/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/http") @@ -20,10 +20,12 @@ qt_add_executable(http httpwindow.cpp httpwindow.h main.cpp ) + set_target_properties(http PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(http PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/loopback/CMakeLists.txt b/examples/network/loopback/CMakeLists.txt index 0cf46e2cb9..d3531af3f3 100644 --- a/examples/network/loopback/CMakeLists.txt +++ b/examples/network/loopback/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/loopback") @@ -19,10 +19,12 @@ qt_add_executable(loopback dialog.cpp dialog.h main.cpp ) + set_target_properties(loopback PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(loopback PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/multicastreceiver/CMakeLists.txt b/examples/network/multicastreceiver/CMakeLists.txt index c5b8b5ed5e..e42a9cd1fb 100644 --- a/examples/network/multicastreceiver/CMakeLists.txt +++ b/examples/network/multicastreceiver/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/multicastreceiver") @@ -19,10 +19,12 @@ qt_add_executable(multicastreceiver main.cpp receiver.cpp receiver.h ) + set_target_properties(multicastreceiver PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(multicastreceiver PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/multicastsender/CMakeLists.txt b/examples/network/multicastsender/CMakeLists.txt index 9d14658ca1..dde7976d5f 100644 --- a/examples/network/multicastsender/CMakeLists.txt +++ b/examples/network/multicastsender/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/multicastsender") @@ -19,10 +19,12 @@ qt_add_executable(multicastsender main.cpp sender.cpp sender.h ) + set_target_properties(multicastsender PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(multicastsender PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/multistreamclient/CMakeLists.txt b/examples/network/multistreamclient/CMakeLists.txt index b530be5817..c4218d910a 100644 --- a/examples/network/multistreamclient/CMakeLists.txt +++ b/examples/network/multistreamclient/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/multistreamclient") @@ -23,10 +23,12 @@ qt_add_executable(multistreamclient movieconsumer.cpp movieconsumer.h timeconsumer.cpp timeconsumer.h ) + set_target_properties(multistreamclient PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(multistreamclient PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/multistreamserver/CMakeLists.txt b/examples/network/multistreamserver/CMakeLists.txt index 1417ef875c..4f7c17db27 100644 --- a/examples/network/multistreamserver/CMakeLists.txt +++ b/examples/network/multistreamserver/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/multistreamserver") @@ -23,10 +23,12 @@ qt_add_executable(multistreamserver server.cpp server.h timeprovider.cpp timeprovider.h ) + set_target_properties(multistreamserver PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(multistreamserver PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/network-chat/CMakeLists.txt b/examples/network/network-chat/CMakeLists.txt index bc07905c26..3c3220148a 100644 --- a/examples/network/network-chat/CMakeLists.txt +++ b/examples/network/network-chat/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/network-chat") @@ -23,10 +23,12 @@ qt_add_executable(network-chat peermanager.cpp peermanager.h server.cpp server.h ) + set_target_properties(network-chat PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(network-chat PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/securesocketclient/CMakeLists.txt b/examples/network/securesocketclient/CMakeLists.txt index b9f4aae116..6d957ade17 100644 --- a/examples/network/securesocketclient/CMakeLists.txt +++ b/examples/network/securesocketclient/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/securesocketclient") @@ -21,10 +21,12 @@ qt_add_executable(securesocketclient sslclient.cpp sslclient.h sslclient.ui sslerrors.ui ) + set_target_properties(securesocketclient PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(securesocketclient PUBLIC Qt::Core Qt::Gui @@ -32,7 +34,6 @@ target_link_libraries(securesocketclient PUBLIC Qt::Widgets ) - # Resources: set(securesocketclient_resource_files "encrypted.png" diff --git a/examples/network/secureudpclient/CMakeLists.txt b/examples/network/secureudpclient/CMakeLists.txt index b53e7f4a9b..9561ecc0b9 100644 --- a/examples/network/secureudpclient/CMakeLists.txt +++ b/examples/network/secureudpclient/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/secureudpclient") @@ -21,10 +21,12 @@ qt_add_executable(secureudpclient main.cpp mainwindow.cpp mainwindow.h mainwindow.ui ) + set_target_properties(secureudpclient PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(secureudpclient PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/secureudpserver/CMakeLists.txt b/examples/network/secureudpserver/CMakeLists.txt index 16d2a7fece..04f565437e 100644 --- a/examples/network/secureudpserver/CMakeLists.txt +++ b/examples/network/secureudpserver/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/secureudpserver") @@ -21,10 +21,12 @@ qt_add_executable(secureudpserver nicselector.cpp nicselector.h nicselector.ui server.cpp server.h ) + set_target_properties(secureudpserver PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(secureudpserver PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/threadedfortuneserver/CMakeLists.txt b/examples/network/threadedfortuneserver/CMakeLists.txt index f94f223273..b6861737ea 100644 --- a/examples/network/threadedfortuneserver/CMakeLists.txt +++ b/examples/network/threadedfortuneserver/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/threadedfortuneserver") @@ -21,10 +21,12 @@ qt_add_executable(threadedfortuneserver fortunethread.cpp fortunethread.h main.cpp ) + set_target_properties(threadedfortuneserver PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(threadedfortuneserver PUBLIC Qt::Core Qt::Gui diff --git a/examples/network/torrent/CMakeLists.txt b/examples/network/torrent/CMakeLists.txt index 4ddfcd1586..559d89633a 100644 --- a/examples/network/torrent/CMakeLists.txt +++ b/examples/network/torrent/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/network/torrent") @@ -30,10 +30,12 @@ qt_add_executable(torrent torrentserver.cpp torrentserver.h trackerclient.cpp trackerclient.h ) + set_target_properties(torrent PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(torrent PUBLIC Qt::Core Qt::Gui @@ -41,7 +43,6 @@ target_link_libraries(torrent PUBLIC Qt::Widgets ) - # Resources: set(icons_resource_files "icons/1downarrow.png" diff --git a/examples/opengl/2dpainting/CMakeLists.txt b/examples/opengl/2dpainting/CMakeLists.txt index b0b7dab982..2b2ff7aee9 100644 --- a/examples/opengl/2dpainting/CMakeLists.txt +++ b/examples/opengl/2dpainting/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/2dpainting") @@ -22,10 +22,12 @@ qt_add_executable(2dpainting widget.cpp widget.h window.cpp window.h ) + set_target_properties(2dpainting PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(2dpainting PUBLIC Qt::Core Qt::Gui diff --git a/examples/opengl/computegles31/CMakeLists.txt b/examples/opengl/computegles31/CMakeLists.txt index ac2636e09b..eca508f80a 100644 --- a/examples/opengl/computegles31/CMakeLists.txt +++ b/examples/opengl/computegles31/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/computegles31") @@ -19,17 +19,18 @@ qt_add_executable(computegles31 glwindow.cpp glwindow.h main.cpp ) + set_target_properties(computegles31 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(computegles31 PUBLIC Qt::Core Qt::Gui Qt::OpenGL ) - # Resources: set(computegles31_resource_files "Qt-logo-medium.png" diff --git a/examples/opengl/contextinfo/CMakeLists.txt b/examples/opengl/contextinfo/CMakeLists.txt index bddd46cd4e..ad11734e0d 100644 --- a/examples/opengl/contextinfo/CMakeLists.txt +++ b/examples/opengl/contextinfo/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/contextinfo") @@ -20,10 +20,12 @@ qt_add_executable(contextinfo renderwindow.cpp renderwindow.h widget.cpp widget.h ) + set_target_properties(contextinfo PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(contextinfo PUBLIC Qt::Core Qt::Gui diff --git a/examples/opengl/cube/CMakeLists.txt b/examples/opengl/cube/CMakeLists.txt index f901e2d0f5..ec5dfd4d50 100644 --- a/examples/opengl/cube/CMakeLists.txt +++ b/examples/opengl/cube/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/cube") @@ -20,10 +20,12 @@ qt_add_executable(cube main.cpp mainwidget.cpp mainwidget.h ) + set_target_properties(cube PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(cube PUBLIC Qt::Core Qt::Gui @@ -32,7 +34,6 @@ target_link_libraries(cube PUBLIC Qt::Widgets ) - # Resources: set(shaders_resource_files "fshader.glsl" @@ -45,6 +46,7 @@ qt6_add_resources(cube "shaders" FILES ${shaders_resource_files} ) + set(textures_resource_files "cube.png" ) diff --git a/examples/opengl/hellogl2/CMakeLists.txt b/examples/opengl/hellogl2/CMakeLists.txt index 00ae8693b7..8ce9a96560 100644 --- a/examples/opengl/hellogl2/CMakeLists.txt +++ b/examples/opengl/hellogl2/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/hellogl2") @@ -22,10 +22,12 @@ qt_add_executable(hellogl2 mainwindow.cpp mainwindow.h window.cpp window.h ) + set_target_properties(hellogl2 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(hellogl2 PUBLIC Qt::Core Qt::Gui diff --git a/examples/opengl/hellogles3/CMakeLists.txt b/examples/opengl/hellogles3/CMakeLists.txt index cf1f66c6e6..fdf6fa337a 100644 --- a/examples/opengl/hellogles3/CMakeLists.txt +++ b/examples/opengl/hellogles3/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/hellogles3") @@ -20,17 +20,18 @@ qt_add_executable(hellogles3 glwindow.cpp glwindow.h main.cpp ) + set_target_properties(hellogles3 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(hellogles3 PUBLIC Qt::Core Qt::Gui Qt::OpenGL ) - # Resources: set(hellogles3_resource_files "qtlogo.png" diff --git a/examples/opengl/hellowindow/CMakeLists.txt b/examples/opengl/hellowindow/CMakeLists.txt index 80bb291504..3217690de1 100644 --- a/examples/opengl/hellowindow/CMakeLists.txt +++ b/examples/opengl/hellowindow/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/hellowindow") @@ -19,10 +19,12 @@ qt_add_executable(hellowindow hellowindow.cpp hellowindow.h main.cpp ) + set_target_properties(hellowindow PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(hellowindow PUBLIC Qt::Core Qt::CorePrivate diff --git a/examples/opengl/openglwindow/CMakeLists.txt b/examples/opengl/openglwindow/CMakeLists.txt index a555608c8e..d9717daf00 100644 --- a/examples/opengl/openglwindow/CMakeLists.txt +++ b/examples/opengl/openglwindow/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/openglwindow") @@ -19,10 +19,12 @@ qt_add_executable(openglwindow main.cpp openglwindow.cpp openglwindow.h ) + set_target_properties(openglwindow PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(openglwindow PUBLIC ${CMAKE_CURRENT_SOURCE_DIR} ) diff --git a/examples/opengl/paintedwindow/CMakeLists.txt b/examples/opengl/paintedwindow/CMakeLists.txt index 632df35e20..a0cfbe0454 100644 --- a/examples/opengl/paintedwindow/CMakeLists.txt +++ b/examples/opengl/paintedwindow/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/paintedwindow") @@ -19,10 +19,12 @@ qt_add_executable(paintedwindow main.cpp paintedwindow.cpp paintedwindow.h ) + set_target_properties(paintedwindow PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(paintedwindow PUBLIC Qt::Core Qt::Gui diff --git a/examples/opengl/qopenglwidget/CMakeLists.txt b/examples/opengl/qopenglwidget/CMakeLists.txt index 56f985a454..88b04733db 100644 --- a/examples/opengl/qopenglwidget/CMakeLists.txt +++ b/examples/opengl/qopenglwidget/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/qopenglwidget") @@ -21,10 +21,12 @@ qt_add_executable(qopenglwidget main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(qopenglwidget PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(qopenglwidget PUBLIC Qt::Core Qt::Gui @@ -33,7 +35,6 @@ target_link_libraries(qopenglwidget PUBLIC Qt::Widgets ) - # Resources: set(texture_resource_files "qt.png" diff --git a/examples/opengl/qopenglwindow/CMakeLists.txt b/examples/opengl/qopenglwindow/CMakeLists.txt index 1236df6148..f4b01ebbb7 100644 --- a/examples/opengl/qopenglwindow/CMakeLists.txt +++ b/examples/opengl/qopenglwindow/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/qopenglwindow") @@ -19,10 +19,12 @@ qt_add_executable(qopenglwindow background_renderer.cpp background_renderer.h main.cpp ) + set_target_properties(qopenglwindow PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(qopenglwindow PUBLIC . ) @@ -33,7 +35,6 @@ target_link_libraries(qopenglwindow PUBLIC Qt::OpenGL ) - # Resources: set(shaders_resource_files "background.frag" diff --git a/examples/opengl/textures/CMakeLists.txt b/examples/opengl/textures/CMakeLists.txt index adf9049df4..7d67a892c7 100644 --- a/examples/opengl/textures/CMakeLists.txt +++ b/examples/opengl/textures/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/textures") @@ -20,10 +20,12 @@ qt_add_executable(textures main.cpp window.cpp window.h ) + set_target_properties(textures PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(textures PUBLIC Qt::Core Qt::Gui @@ -32,7 +34,6 @@ target_link_libraries(textures PUBLIC Qt::Widgets ) - # Resources: set(textures_resource_files "images/side1.png" diff --git a/examples/opengl/threadedqopenglwidget/CMakeLists.txt b/examples/opengl/threadedqopenglwidget/CMakeLists.txt index 7aea309b45..f6150748b9 100644 --- a/examples/opengl/threadedqopenglwidget/CMakeLists.txt +++ b/examples/opengl/threadedqopenglwidget/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/opengl/threadedqopenglwidget") @@ -20,10 +20,12 @@ qt_add_executable(threadedqopenglwidget main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(threadedqopenglwidget PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(threadedqopenglwidget PUBLIC Qt::Core Qt::Gui diff --git a/examples/qpa/qrasterwindow/CMakeLists.txt b/examples/qpa/qrasterwindow/CMakeLists.txt index b597a7e059..08e44c5102 100644 --- a/examples/qpa/qrasterwindow/CMakeLists.txt +++ b/examples/qpa/qrasterwindow/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/qpa/qrasterwindow") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui) qt_add_executable(qrasterwindow main.cpp ) + set_target_properties(qrasterwindow PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(qrasterwindow PUBLIC Qt::Core Qt::Gui diff --git a/examples/qpa/windows/CMakeLists.txt b/examples/qpa/windows/CMakeLists.txt index 89975e44e2..87987d00d1 100644 --- a/examples/qpa/windows/CMakeLists.txt +++ b/examples/qpa/windows/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/qpa/windows") @@ -19,10 +19,12 @@ qt_add_executable(windows main.cpp window.cpp window.h ) + set_target_properties(windows PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE TRUE ) + target_link_libraries(windows PUBLIC Qt::Core Qt::CorePrivate diff --git a/examples/qtconcurrent/imagescaling/CMakeLists.txt b/examples/qtconcurrent/imagescaling/CMakeLists.txt index a1f7dd4789..a696ea1fee 100644 --- a/examples/qtconcurrent/imagescaling/CMakeLists.txt +++ b/examples/qtconcurrent/imagescaling/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/qtconcurrent/imagescaling") @@ -20,10 +20,12 @@ qt_add_executable(imagescaling imagescaling.cpp imagescaling.h main.cpp ) + set_target_properties(imagescaling PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(imagescaling PUBLIC Qt::Concurrent Qt::Core diff --git a/examples/qtconcurrent/map/CMakeLists.txt b/examples/qtconcurrent/map/CMakeLists.txt index 1e0659dd36..e767a3067c 100644 --- a/examples/qtconcurrent/map/CMakeLists.txt +++ b/examples/qtconcurrent/map/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/qtconcurrent/map") @@ -18,15 +18,18 @@ find_package(Qt6 REQUIRED COMPONENTS Concurrent Core Gui) qt_add_executable(mapdemo main.cpp ) + set_target_properties(mapdemo PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE FALSE ) + target_link_libraries(mapdemo PUBLIC Qt::Concurrent Qt::Core Qt::Gui ) + install(TARGETS mapdemo RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" diff --git a/examples/qtconcurrent/progressdialog/CMakeLists.txt b/examples/qtconcurrent/progressdialog/CMakeLists.txt index 1a4f3b1440..3efe2fc6c8 100644 --- a/examples/qtconcurrent/progressdialog/CMakeLists.txt +++ b/examples/qtconcurrent/progressdialog/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/qtconcurrent/progressdialog") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Concurrent Core Gui Widgets) qt_add_executable(progressdialog main.cpp ) + set_target_properties(progressdialog PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE TRUE ) + target_link_libraries(progressdialog PUBLIC Qt::Concurrent Qt::Core diff --git a/examples/qtconcurrent/runfunction/CMakeLists.txt b/examples/qtconcurrent/runfunction/CMakeLists.txt index 47fe2bc1fa..a6e3684f39 100644 --- a/examples/qtconcurrent/runfunction/CMakeLists.txt +++ b/examples/qtconcurrent/runfunction/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/qtconcurrent/runfunction") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Concurrent Core Gui Widgets) qt_add_executable(runfunction main.cpp ) + set_target_properties(runfunction PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE FALSE ) + target_link_libraries(runfunction PUBLIC Qt::Concurrent Qt::Core diff --git a/examples/qtconcurrent/wordcount/CMakeLists.txt b/examples/qtconcurrent/wordcount/CMakeLists.txt index 60e7f80dd3..9a4f4344c6 100644 --- a/examples/qtconcurrent/wordcount/CMakeLists.txt +++ b/examples/qtconcurrent/wordcount/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/qtconcurrent/wordcount") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Concurrent Core Gui Widgets) qt_add_executable(wordcount main.cpp ) + set_target_properties(wordcount PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE FALSE ) + target_link_libraries(wordcount PUBLIC Qt::Concurrent Qt::Core diff --git a/examples/qtestlib/tutorial1/CMakeLists.txt b/examples/qtestlib/tutorial1/CMakeLists.txt index 4ef18bbc34..be7aa40e2c 100644 --- a/examples/qtestlib/tutorial1/CMakeLists.txt +++ b/examples/qtestlib/tutorial1/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial1") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Test Widgets) qt_add_executable(tutorial1 testqstring.cpp ) + set_target_properties(tutorial1 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(tutorial1 PUBLIC Qt::Core Qt::Gui diff --git a/examples/qtestlib/tutorial2/CMakeLists.txt b/examples/qtestlib/tutorial2/CMakeLists.txt index 99a52eda74..2a4ead9bd6 100644 --- a/examples/qtestlib/tutorial2/CMakeLists.txt +++ b/examples/qtestlib/tutorial2/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial2") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Test Widgets) qt_add_executable(tutorial2 testqstring.cpp ) + set_target_properties(tutorial2 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(tutorial2 PUBLIC Qt::Core Qt::Gui diff --git a/examples/qtestlib/tutorial3/CMakeLists.txt b/examples/qtestlib/tutorial3/CMakeLists.txt index 96adf6f476..bc3b3012bd 100644 --- a/examples/qtestlib/tutorial3/CMakeLists.txt +++ b/examples/qtestlib/tutorial3/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial3") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Test Widgets) qt_add_executable(tutorial3 testgui.cpp ) + set_target_properties(tutorial3 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(tutorial3 PUBLIC Qt::Core Qt::Gui diff --git a/examples/qtestlib/tutorial4/CMakeLists.txt b/examples/qtestlib/tutorial4/CMakeLists.txt index 88e2014ab0..d8771eb7ac 100644 --- a/examples/qtestlib/tutorial4/CMakeLists.txt +++ b/examples/qtestlib/tutorial4/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial4") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Test Widgets) qt_add_executable(tutorial4 testgui.cpp ) + set_target_properties(tutorial4 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(tutorial4 PUBLIC Qt::Core Qt::Gui diff --git a/examples/qtestlib/tutorial5/CMakeLists.txt b/examples/qtestlib/tutorial5/CMakeLists.txt index d1b15b4fdf..edab3c8178 100644 --- a/examples/qtestlib/tutorial5/CMakeLists.txt +++ b/examples/qtestlib/tutorial5/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/qtestlib/tutorial5") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Test Widgets) qt_add_executable(tutorial5 benchmarking.cpp ) + set_target_properties(tutorial5 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(tutorial5 PUBLIC Qt::Core Qt::Gui diff --git a/examples/sql/books/CMakeLists.txt b/examples/sql/books/CMakeLists.txt index bef0ad2cd6..74a6dc086c 100644 --- a/examples/sql/books/CMakeLists.txt +++ b/examples/sql/books/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/sql/books") @@ -21,10 +21,12 @@ qt_add_executable(books initdb.h main.cpp ) + set_target_properties(books PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(books PUBLIC . ) @@ -36,7 +38,6 @@ target_link_libraries(books PUBLIC Qt::Widgets ) - # Resources: set(books_resource_files "images/star.png" diff --git a/examples/sql/cachedtable/CMakeLists.txt b/examples/sql/cachedtable/CMakeLists.txt index bcfc7d1d3c..9e11d6e4a4 100644 --- a/examples/sql/cachedtable/CMakeLists.txt +++ b/examples/sql/cachedtable/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/sql/cachedtable") @@ -20,10 +20,12 @@ qt_add_executable(cachedtable main.cpp tableeditor.cpp tableeditor.h ) + set_target_properties(cachedtable PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(cachedtable PUBLIC Qt::Core Qt::Gui diff --git a/examples/sql/drilldown/CMakeLists.txt b/examples/sql/drilldown/CMakeLists.txt index dd83087eb6..ae7125f6dd 100644 --- a/examples/sql/drilldown/CMakeLists.txt +++ b/examples/sql/drilldown/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/sql/drilldown") @@ -22,10 +22,12 @@ qt_add_executable(drilldown main.cpp view.cpp view.h ) + set_target_properties(drilldown PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(drilldown PUBLIC Qt::Core Qt::Gui @@ -33,7 +35,6 @@ target_link_libraries(drilldown PUBLIC Qt::Widgets ) - # Resources: set(drilldown_resource_files "images/qt-creator.png" diff --git a/examples/sql/masterdetail/CMakeLists.txt b/examples/sql/masterdetail/CMakeLists.txt index 317b09dc7b..81ed7aced1 100644 --- a/examples/sql/masterdetail/CMakeLists.txt +++ b/examples/sql/masterdetail/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/sql/masterdetail") @@ -21,10 +21,12 @@ qt_add_executable(masterdetail main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(masterdetail PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(masterdetail PUBLIC Qt::Core Qt::Gui @@ -33,7 +35,6 @@ target_link_libraries(masterdetail PUBLIC Qt::Xml ) - # Resources: set(masterdetail_resource_files "images/icon.png" diff --git a/examples/sql/querymodel/CMakeLists.txt b/examples/sql/querymodel/CMakeLists.txt index 7d943a5193..806197c317 100644 --- a/examples/sql/querymodel/CMakeLists.txt +++ b/examples/sql/querymodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/sql/querymodel") @@ -21,10 +21,12 @@ qt_add_executable(querymodel editablesqlmodel.cpp editablesqlmodel.h main.cpp ) + set_target_properties(querymodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(querymodel PUBLIC Qt::Core Qt::Gui diff --git a/examples/sql/relationaltablemodel/CMakeLists.txt b/examples/sql/relationaltablemodel/CMakeLists.txt index 0f10cea239..1891d61c97 100644 --- a/examples/sql/relationaltablemodel/CMakeLists.txt +++ b/examples/sql/relationaltablemodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/sql/relationaltablemodel") @@ -19,10 +19,12 @@ qt_add_executable(relationaltablemodel ../connection.h relationaltablemodel.cpp ) + set_target_properties(relationaltablemodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(relationaltablemodel PUBLIC Qt::Core Qt::Gui diff --git a/examples/sql/sqlbrowser/CMakeLists.txt b/examples/sql/sqlbrowser/CMakeLists.txt index ca6d30741b..954782347e 100644 --- a/examples/sql/sqlbrowser/CMakeLists.txt +++ b/examples/sql/sqlbrowser/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/sql/sqlbrowser") @@ -22,10 +22,12 @@ qt_add_executable(sqlbrowser main.cpp qsqlconnectiondialog.cpp qsqlconnectiondialog.h qsqlconnectiondialog.ui ) + set_target_properties(sqlbrowser PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(sqlbrowser PUBLIC Qt::Core Qt::Gui diff --git a/examples/sql/sqlwidgetmapper/CMakeLists.txt b/examples/sql/sqlwidgetmapper/CMakeLists.txt index aebc25f106..3303cfba8b 100644 --- a/examples/sql/sqlwidgetmapper/CMakeLists.txt +++ b/examples/sql/sqlwidgetmapper/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/sql/sqlwidgetmapper") @@ -19,10 +19,12 @@ qt_add_executable(sqlwidgetmapper main.cpp window.cpp window.h ) + set_target_properties(sqlwidgetmapper PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(sqlwidgetmapper PUBLIC Qt::Core Qt::Gui diff --git a/examples/sql/tablemodel/CMakeLists.txt b/examples/sql/tablemodel/CMakeLists.txt index 245d4015e9..4c1ebdfe91 100644 --- a/examples/sql/tablemodel/CMakeLists.txt +++ b/examples/sql/tablemodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/sql/tablemodel") @@ -19,10 +19,12 @@ qt_add_executable(tablemodel ../connection.h tablemodel.cpp ) + set_target_properties(tablemodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(tablemodel PUBLIC Qt::Core Qt::Gui diff --git a/examples/vulkan/hellovulkancubes/CMakeLists.txt b/examples/vulkan/hellovulkancubes/CMakeLists.txt index f8999f3986..3321cb08e5 100644 --- a/examples/vulkan/hellovulkancubes/CMakeLists.txt +++ b/examples/vulkan/hellovulkancubes/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/vulkan/hellovulkancubes") @@ -24,10 +24,12 @@ qt_add_executable(hellovulkancubes shader.cpp shader.h vulkanwindow.cpp vulkanwindow.h ) + set_target_properties(hellovulkancubes PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(hellovulkancubes PUBLIC Qt::Concurrent Qt::Core @@ -35,14 +37,15 @@ target_link_libraries(hellovulkancubes PUBLIC Qt::Widgets ) - # Resources: set_source_files_properties("../shared/block.buf" PROPERTIES QT_RESOURCE_ALIAS "block.buf" ) + set_source_files_properties("../shared/qt_logo.buf" PROPERTIES QT_RESOURCE_ALIAS "qt_logo.buf" ) + set(hellovulkancubes_resource_files "../shared/block.buf" "../shared/qt_logo.buf" diff --git a/examples/vulkan/hellovulkantexture/CMakeLists.txt b/examples/vulkan/hellovulkantexture/CMakeLists.txt index 421a82a540..181f92f85d 100644 --- a/examples/vulkan/hellovulkantexture/CMakeLists.txt +++ b/examples/vulkan/hellovulkantexture/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/vulkan/hellovulkantexture") @@ -19,16 +19,17 @@ qt_add_executable(hellovulkantexture hellovulkantexture.cpp hellovulkantexture.h main.cpp ) + set_target_properties(hellovulkantexture PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(hellovulkantexture PUBLIC Qt::Core Qt::Gui ) - # Resources: set(hellovulkantexture_resource_files "qt256.png" diff --git a/examples/vulkan/hellovulkantriangle/CMakeLists.txt b/examples/vulkan/hellovulkantriangle/CMakeLists.txt index 5ca87cd893..01f2891d34 100644 --- a/examples/vulkan/hellovulkantriangle/CMakeLists.txt +++ b/examples/vulkan/hellovulkantriangle/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/vulkan/hellovulkantriangle") @@ -19,23 +19,26 @@ qt_add_executable(hellovulkantriangle ../shared/trianglerenderer.cpp ../shared/trianglerenderer.h main.cpp ) + set_target_properties(hellovulkantriangle PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(hellovulkantriangle PUBLIC Qt::Core Qt::Gui ) - # Resources: set_source_files_properties("../shared/color_frag.spv" PROPERTIES QT_RESOURCE_ALIAS "color_frag.spv" ) + set_source_files_properties("../shared/color_vert.spv" PROPERTIES QT_RESOURCE_ALIAS "color_vert.spv" ) + set(hellovulkantriangle_resource_files "../shared/color_frag.spv" "../shared/color_vert.spv" diff --git a/examples/vulkan/hellovulkanwidget/CMakeLists.txt b/examples/vulkan/hellovulkanwidget/CMakeLists.txt index e7adcc3ef1..cb5f836d0e 100644 --- a/examples/vulkan/hellovulkanwidget/CMakeLists.txt +++ b/examples/vulkan/hellovulkanwidget/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/vulkan/hellovulkanwidget") @@ -20,24 +20,27 @@ qt_add_executable(hellovulkanwidget hellovulkanwidget.cpp hellovulkanwidget.h main.cpp ) + set_target_properties(hellovulkanwidget PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(hellovulkanwidget PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set_source_files_properties("../shared/color_frag.spv" PROPERTIES QT_RESOURCE_ALIAS "color_frag.spv" ) + set_source_files_properties("../shared/color_vert.spv" PROPERTIES QT_RESOURCE_ALIAS "color_vert.spv" ) + set(hellovulkanwidget_resource_files "../shared/color_frag.spv" "../shared/color_vert.spv" diff --git a/examples/vulkan/hellovulkanwindow/CMakeLists.txt b/examples/vulkan/hellovulkanwindow/CMakeLists.txt index af98431a3a..aa4eea044b 100644 --- a/examples/vulkan/hellovulkanwindow/CMakeLists.txt +++ b/examples/vulkan/hellovulkanwindow/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/vulkan/hellovulkanwindow") @@ -19,10 +19,12 @@ qt_add_executable(hellovulkanwindow hellovulkanwindow.cpp hellovulkanwindow.h main.cpp ) + set_target_properties(hellovulkanwindow PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(hellovulkanwindow PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/animation/easing/CMakeLists.txt b/examples/widgets/animation/easing/CMakeLists.txt index 2067b0c0d3..1073e7eb4f 100644 --- a/examples/widgets/animation/easing/CMakeLists.txt +++ b/examples/widgets/animation/easing/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/animation/easing") @@ -21,17 +21,18 @@ qt_add_executable(easing main.cpp window.cpp window.h ) + set_target_properties(easing PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(easing PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(easing_resource_files "images/qt-logo.png" diff --git a/examples/widgets/desktop/screenshot/CMakeLists.txt b/examples/widgets/desktop/screenshot/CMakeLists.txt index 95bba7ee31..c3fce5efcf 100644 --- a/examples/widgets/desktop/screenshot/CMakeLists.txt +++ b/examples/widgets/desktop/screenshot/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/desktop/screenshot") @@ -19,10 +19,12 @@ qt_add_executable(screenshot main.cpp screenshot.cpp screenshot.h ) + set_target_properties(screenshot PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(screenshot PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/desktop/systray/CMakeLists.txt b/examples/widgets/desktop/systray/CMakeLists.txt index c2b0d859ba..4f87873bee 100644 --- a/examples/widgets/desktop/systray/CMakeLists.txt +++ b/examples/widgets/desktop/systray/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/desktop/systray") @@ -19,17 +19,18 @@ qt_add_executable(systray main.cpp window.cpp window.h ) + set_target_properties(systray PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(systray PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(systray_resource_files "images/bad.png" diff --git a/examples/widgets/dialogs/classwizard/CMakeLists.txt b/examples/widgets/dialogs/classwizard/CMakeLists.txt index c9c4b44f59..fb1ff096eb 100644 --- a/examples/widgets/dialogs/classwizard/CMakeLists.txt +++ b/examples/widgets/dialogs/classwizard/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/classwizard") @@ -19,17 +19,18 @@ qt_add_executable(classwizard classwizard.cpp classwizard.h main.cpp ) + set_target_properties(classwizard PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(classwizard PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(classwizard_resource_files "images/background.png" diff --git a/examples/widgets/dialogs/extension/CMakeLists.txt b/examples/widgets/dialogs/extension/CMakeLists.txt index 243fb13a47..ac443d27d1 100644 --- a/examples/widgets/dialogs/extension/CMakeLists.txt +++ b/examples/widgets/dialogs/extension/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/extension") @@ -19,10 +19,12 @@ qt_add_executable(extension finddialog.cpp finddialog.h main.cpp ) + set_target_properties(extension PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(extension PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/dialogs/findfiles/CMakeLists.txt b/examples/widgets/dialogs/findfiles/CMakeLists.txt index 4d870b193e..d93ad390e7 100644 --- a/examples/widgets/dialogs/findfiles/CMakeLists.txt +++ b/examples/widgets/dialogs/findfiles/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/findfiles") @@ -19,10 +19,12 @@ qt_add_executable(findfiles main.cpp window.cpp window.h ) + set_target_properties(findfiles PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(findfiles PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/dialogs/licensewizard/CMakeLists.txt b/examples/widgets/dialogs/licensewizard/CMakeLists.txt index c043ff18fd..cc4c48b3f0 100644 --- a/examples/widgets/dialogs/licensewizard/CMakeLists.txt +++ b/examples/widgets/dialogs/licensewizard/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/licensewizard") @@ -19,10 +19,12 @@ qt_add_executable(licensewizard licensewizard.cpp licensewizard.h main.cpp ) + set_target_properties(licensewizard PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(licensewizard PUBLIC Qt::Core Qt::Gui @@ -30,7 +32,6 @@ target_link_libraries(licensewizard PUBLIC Qt::Widgets ) - # Resources: set(licensewizard_resource_files "images/logo.png" diff --git a/examples/widgets/dialogs/standarddialogs/CMakeLists.txt b/examples/widgets/dialogs/standarddialogs/CMakeLists.txt index 5a709a5cee..d5b7705601 100644 --- a/examples/widgets/dialogs/standarddialogs/CMakeLists.txt +++ b/examples/widgets/dialogs/standarddialogs/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/standarddialogs") @@ -19,10 +19,12 @@ qt_add_executable(standarddialogs dialog.cpp dialog.h main.cpp ) + set_target_properties(standarddialogs PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(standarddialogs PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/dialogs/tabdialog/CMakeLists.txt b/examples/widgets/dialogs/tabdialog/CMakeLists.txt index 13d41ddee8..51f8ab8be9 100644 --- a/examples/widgets/dialogs/tabdialog/CMakeLists.txt +++ b/examples/widgets/dialogs/tabdialog/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/tabdialog") @@ -19,10 +19,12 @@ qt_add_executable(tabdialog main.cpp tabdialog.cpp tabdialog.h ) + set_target_properties(tabdialog PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(tabdialog PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/dialogs/trivialwizard/CMakeLists.txt b/examples/widgets/dialogs/trivialwizard/CMakeLists.txt index 9502ebbd78..eff5e5c33d 100644 --- a/examples/widgets/dialogs/trivialwizard/CMakeLists.txt +++ b/examples/widgets/dialogs/trivialwizard/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/trivialwizard") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(trivialwizard trivialwizard.cpp ) + set_target_properties(trivialwizard PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(trivialwizard PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/draganddrop/draggableicons/CMakeLists.txt b/examples/widgets/draganddrop/draggableicons/CMakeLists.txt index ee157bbf25..c73c54d32b 100644 --- a/examples/widgets/draganddrop/draggableicons/CMakeLists.txt +++ b/examples/widgets/draganddrop/draggableicons/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/draggableicons") @@ -19,17 +19,18 @@ qt_add_executable(draggableicons dragwidget.cpp dragwidget.h main.cpp ) + set_target_properties(draggableicons PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(draggableicons PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(draggableicons_resource_files "images/boat.png" diff --git a/examples/widgets/draganddrop/draggabletext/CMakeLists.txt b/examples/widgets/draganddrop/draggabletext/CMakeLists.txt index 7aba6ac56c..34758858e8 100644 --- a/examples/widgets/draganddrop/draggabletext/CMakeLists.txt +++ b/examples/widgets/draganddrop/draggabletext/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/draggabletext") @@ -19,17 +19,18 @@ qt_add_executable(draggabletext dragwidget.cpp dragwidget.h main.cpp ) + set_target_properties(draggabletext PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(draggabletext PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(draggabletext_resource_files "words.txt" diff --git a/examples/widgets/draganddrop/dropsite/CMakeLists.txt b/examples/widgets/draganddrop/dropsite/CMakeLists.txt index a3a4d0fbe8..e602f7c7f4 100644 --- a/examples/widgets/draganddrop/dropsite/CMakeLists.txt +++ b/examples/widgets/draganddrop/dropsite/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/dropsite") @@ -20,10 +20,12 @@ qt_add_executable(dropsite dropsitewindow.cpp dropsitewindow.h main.cpp ) + set_target_properties(dropsite PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(dropsite PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt b/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt index 2f2087fd3d..462c48254b 100644 --- a/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt +++ b/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/fridgemagnets") @@ -20,17 +20,18 @@ qt_add_executable(fridgemagnets dragwidget.cpp dragwidget.h main.cpp ) + set_target_properties(fridgemagnets PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(fridgemagnets PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(fridgemagnets_resource_files "words.txt" diff --git a/examples/widgets/draganddrop/puzzle/CMakeLists.txt b/examples/widgets/draganddrop/puzzle/CMakeLists.txt index cf6350f16d..221b152540 100644 --- a/examples/widgets/draganddrop/puzzle/CMakeLists.txt +++ b/examples/widgets/draganddrop/puzzle/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/draganddrop_puzzle") @@ -21,17 +21,18 @@ qt_add_executable(draganddrop_puzzle pieceslist.cpp pieceslist.h puzzlewidget.cpp puzzlewidget.h ) + set_target_properties(draganddrop_puzzle PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(draganddrop_puzzle PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(puzzle_resource_files "example.jpg" diff --git a/examples/widgets/effects/blurpicker/CMakeLists.txt b/examples/widgets/effects/blurpicker/CMakeLists.txt index 679b788ed8..b4f1c48306 100644 --- a/examples/widgets/effects/blurpicker/CMakeLists.txt +++ b/examples/widgets/effects/blurpicker/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/effects/blurpicker") @@ -20,17 +20,18 @@ qt_add_executable(blurpicker blurpicker.cpp blurpicker.h main.cpp ) + set_target_properties(blurpicker PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(blurpicker PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(blurpicker_resource_files "images/accessories-calculator.png" diff --git a/examples/widgets/effects/fademessage/CMakeLists.txt b/examples/widgets/effects/fademessage/CMakeLists.txt index c561189f5a..c81897b073 100644 --- a/examples/widgets/effects/fademessage/CMakeLists.txt +++ b/examples/widgets/effects/fademessage/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/effects/fademessage") @@ -19,17 +19,18 @@ qt_add_executable(fademessage fademessage.cpp fademessage.h main.cpp ) + set_target_properties(fademessage PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(fademessage PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(fademessage_resource_files "background.jpg" diff --git a/examples/widgets/gallery/CMakeLists.txt b/examples/widgets/gallery/CMakeLists.txt index 6cee5313b8..19f1dd053c 100644 --- a/examples/widgets/gallery/CMakeLists.txt +++ b/examples/widgets/gallery/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/gallery") @@ -19,10 +19,12 @@ qt_add_executable(gallery main.cpp widgetgallery.cpp widgetgallery.h ) + set_target_properties(gallery PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(gallery PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/gestures/imagegestures/CMakeLists.txt b/examples/widgets/gestures/imagegestures/CMakeLists.txt index 9094bfab3d..3380aac969 100644 --- a/examples/widgets/gestures/imagegestures/CMakeLists.txt +++ b/examples/widgets/gestures/imagegestures/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/gestures/imagegestures") @@ -20,10 +20,12 @@ qt_add_executable(imagegestures main.cpp mainwidget.cpp mainwidget.h ) + set_target_properties(imagegestures PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(imagegestures PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt b/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt index f4151c77b5..7ec2bcf31e 100644 --- a/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt +++ b/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/anchorlayout") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(anchorlayout main.cpp ) + set_target_properties(anchorlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(anchorlayout PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt b/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt index a788419124..2d3f57dbaf 100644 --- a/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt +++ b/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/basicgraphicslayouts") @@ -20,17 +20,18 @@ qt_add_executable(basicgraphicslayouts main.cpp window.cpp window.h ) + set_target_properties(basicgraphicslayouts PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(basicgraphicslayouts PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(basicgraphicslayouts_resource_files "images/block.png" diff --git a/examples/widgets/graphicsview/chip/CMakeLists.txt b/examples/widgets/graphicsview/chip/CMakeLists.txt index dc48cdd84f..d187ddeacf 100644 --- a/examples/widgets/graphicsview/chip/CMakeLists.txt +++ b/examples/widgets/graphicsview/chip/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/chip") @@ -24,17 +24,18 @@ qt_add_executable(chip mainwindow.cpp mainwindow.h view.cpp view.h ) + set_target_properties(chip PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(chip PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(images_resource_files "fileprint.png" diff --git a/examples/widgets/graphicsview/collidingmice/CMakeLists.txt b/examples/widgets/graphicsview/collidingmice/CMakeLists.txt index aab329528f..f45831533c 100644 --- a/examples/widgets/graphicsview/collidingmice/CMakeLists.txt +++ b/examples/widgets/graphicsview/collidingmice/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/collidingmice") @@ -19,17 +19,18 @@ qt_add_executable(collidingmice main.cpp mouse.cpp mouse.h ) + set_target_properties(collidingmice PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(collidingmice PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(mice_resource_files "images/cheese.jpg" diff --git a/examples/widgets/graphicsview/diagramscene/CMakeLists.txt b/examples/widgets/graphicsview/diagramscene/CMakeLists.txt index 5559f16dea..d2d056d2a6 100644 --- a/examples/widgets/graphicsview/diagramscene/CMakeLists.txt +++ b/examples/widgets/graphicsview/diagramscene/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/diagramscene") @@ -23,17 +23,18 @@ qt_add_executable(diagramscene main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(diagramscene PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(diagramscene PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(diagramscene_resource_files "images/background1.png" diff --git a/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt b/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt index eb4f8bf00f..f18037b25e 100644 --- a/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt +++ b/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/dragdroprobot") @@ -20,17 +20,18 @@ qt_add_executable(dragdroprobot main.cpp robot.cpp robot.h ) + set_target_properties(dragdroprobot PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(dragdroprobot PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(robot_resource_files "images/head.png" diff --git a/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt b/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt index 369ed964c5..f7aa44fc38 100644 --- a/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt +++ b/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/elasticnodes") @@ -21,10 +21,12 @@ qt_add_executable(elasticnodes main.cpp node.cpp node.h ) + set_target_properties(elasticnodes PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(elasticnodes PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt b/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt index 63eecd3be9..6f37c28b98 100644 --- a/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt +++ b/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/embeddeddialogs") @@ -20,17 +20,18 @@ qt_add_executable(embeddeddialogs embeddeddialog.cpp embeddeddialog.h embeddeddialog.ui main.cpp ) + set_target_properties(embeddeddialogs PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(embeddeddialogs PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(embeddeddialogs_resource_files "No-Ones-Laughing-3.jpg" diff --git a/examples/widgets/graphicsview/flowlayout/CMakeLists.txt b/examples/widgets/graphicsview/flowlayout/CMakeLists.txt index 9093f6303b..ffcbdb14c4 100644 --- a/examples/widgets/graphicsview/flowlayout/CMakeLists.txt +++ b/examples/widgets/graphicsview/flowlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview_flowlayout") @@ -20,10 +20,12 @@ qt_add_executable(graphicsview_flowlayout main.cpp window.cpp window.h ) + set_target_properties(graphicsview_flowlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(graphicsview_flowlayout PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt b/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt index 73f25bb156..24571d9533 100644 --- a/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt +++ b/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/simpleanchorlayout") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(simpleanchorlayout main.cpp ) + set_target_properties(simpleanchorlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(simpleanchorlayout PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt b/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt index 92056a1c51..6261c536ef 100644 --- a/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt +++ b/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/weatheranchorlayout") @@ -18,17 +18,18 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(weatheranchorlayout main.cpp ) + set_target_properties(weatheranchorlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(weatheranchorlayout PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(weatheranchorlayout_resource_files "images/5days.jpg" diff --git a/examples/widgets/itemviews/addressbook/CMakeLists.txt b/examples/widgets/itemviews/addressbook/CMakeLists.txt index e697186600..b8cbdce144 100644 --- a/examples/widgets/itemviews/addressbook/CMakeLists.txt +++ b/examples/widgets/itemviews/addressbook/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/addressbook") @@ -23,10 +23,12 @@ qt_add_executable(addressbook newaddresstab.cpp newaddresstab.h tablemodel.cpp tablemodel.h ) + set_target_properties(addressbook PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(addressbook PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt b/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt index 3046ab25b1..2540b04454 100644 --- a/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt +++ b/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/basicsortfiltermodel") @@ -19,10 +19,12 @@ qt_add_executable(basicsortfiltermodel main.cpp window.cpp window.h ) + set_target_properties(basicsortfiltermodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(basicsortfiltermodel PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/chart/CMakeLists.txt b/examples/widgets/itemviews/chart/CMakeLists.txt index 8e749211f2..7d79621dd7 100644 --- a/examples/widgets/itemviews/chart/CMakeLists.txt +++ b/examples/widgets/itemviews/chart/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/chart") @@ -20,17 +20,18 @@ qt_add_executable(chart mainwindow.cpp mainwindow.h pieview.cpp pieview.h ) + set_target_properties(chart PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(chart PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(chart_resource_files "qtdata.cht" diff --git a/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt b/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt index 0538d4ecd8..2f99f283b9 100644 --- a/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt +++ b/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/coloreditorfactory") @@ -20,10 +20,12 @@ qt_add_executable(coloreditorfactory main.cpp window.cpp window.h ) + set_target_properties(coloreditorfactory PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(coloreditorfactory PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt b/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt index 9bd809dab9..6fc429c966 100644 --- a/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt +++ b/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/combowidgetmapper") @@ -19,10 +19,12 @@ qt_add_executable(combowidgetmapper main.cpp window.cpp window.h ) + set_target_properties(combowidgetmapper PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(combowidgetmapper PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt b/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt index da4d4bdf0a..0c5f9be3b4 100644 --- a/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt +++ b/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/customsortfiltermodel") @@ -21,17 +21,18 @@ qt_add_executable(customsortfiltermodel mysortfilterproxymodel.cpp mysortfilterproxymodel.h window.cpp window.h ) + set_target_properties(customsortfiltermodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(customsortfiltermodel PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(customsortfiltermodel_resource_files "images/find.png" diff --git a/examples/widgets/itemviews/dirview/CMakeLists.txt b/examples/widgets/itemviews/dirview/CMakeLists.txt index cea54f5847..a371e8726b 100644 --- a/examples/widgets/itemviews/dirview/CMakeLists.txt +++ b/examples/widgets/itemviews/dirview/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/dirview") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(dirview main.cpp ) + set_target_properties(dirview PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(dirview PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt b/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt index 8dfaf171be..ddcd00b8f2 100644 --- a/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt +++ b/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/editabletreemodel") @@ -21,17 +21,18 @@ qt_add_executable(editabletreemodel treeitem.cpp treeitem.h treemodel.cpp treemodel.h ) + set_target_properties(editabletreemodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(editabletreemodel PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(editabletreemodel_resource_files "default.txt" diff --git a/examples/widgets/itemviews/fetchmore/CMakeLists.txt b/examples/widgets/itemviews/fetchmore/CMakeLists.txt index 2ea49fd210..f65c61ca0e 100644 --- a/examples/widgets/itemviews/fetchmore/CMakeLists.txt +++ b/examples/widgets/itemviews/fetchmore/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/fetchmore") @@ -20,10 +20,12 @@ qt_add_executable(fetchmore main.cpp window.cpp window.h ) + set_target_properties(fetchmore PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(fetchmore PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/flattreeview/CMakeLists.txt b/examples/widgets/itemviews/flattreeview/CMakeLists.txt index c15fe84734..9ba0a1e159 100644 --- a/examples/widgets/itemviews/flattreeview/CMakeLists.txt +++ b/examples/widgets/itemviews/flattreeview/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/flattreeview") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(flattreeview main.cpp ) + set_target_properties(flattreeview PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(flattreeview PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/frozencolumn/CMakeLists.txt b/examples/widgets/itemviews/frozencolumn/CMakeLists.txt index 6180a204ac..3351cdf409 100644 --- a/examples/widgets/itemviews/frozencolumn/CMakeLists.txt +++ b/examples/widgets/itemviews/frozencolumn/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/frozencolumn") @@ -19,17 +19,18 @@ qt_add_executable(frozencolumn freezetablewidget.cpp freezetablewidget.h main.cpp ) + set_target_properties(frozencolumn PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(frozencolumn PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(grades_resource_files "grades.txt" diff --git a/examples/widgets/itemviews/interview/CMakeLists.txt b/examples/widgets/itemviews/interview/CMakeLists.txt index 9574b24d50..0d88dbdb7d 100644 --- a/examples/widgets/itemviews/interview/CMakeLists.txt +++ b/examples/widgets/itemviews/interview/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/interview") @@ -19,17 +19,18 @@ qt_add_executable(interview main.cpp model.cpp model.h ) + set_target_properties(interview PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(interview PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(interview_resource_files "images/folder.png" diff --git a/examples/widgets/itemviews/pixelator/CMakeLists.txt b/examples/widgets/itemviews/pixelator/CMakeLists.txt index be4cb6afc1..0ccd085d8f 100644 --- a/examples/widgets/itemviews/pixelator/CMakeLists.txt +++ b/examples/widgets/itemviews/pixelator/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/pixelator") @@ -24,17 +24,18 @@ qt_add_executable(pixelator mainwindow.cpp mainwindow.h pixeldelegate.cpp pixeldelegate.h ) + set_target_properties(pixelator PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(pixelator PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(images_resource_files "images/qt.png" diff --git a/examples/widgets/itemviews/puzzle/CMakeLists.txt b/examples/widgets/itemviews/puzzle/CMakeLists.txt index 4761852664..b3e9f368fd 100644 --- a/examples/widgets/itemviews/puzzle/CMakeLists.txt +++ b/examples/widgets/itemviews/puzzle/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/puzzle") @@ -21,17 +21,18 @@ qt_add_executable(itemviews_puzzle piecesmodel.cpp piecesmodel.h puzzlewidget.cpp puzzlewidget.h ) + set_target_properties(itemviews_puzzle PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(itemviews_puzzle PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(puzzle_resource_files "example.jpg" diff --git a/examples/widgets/itemviews/simpledommodel/CMakeLists.txt b/examples/widgets/itemviews/simpledommodel/CMakeLists.txt index 47c26d1b2e..5b98f68848 100644 --- a/examples/widgets/itemviews/simpledommodel/CMakeLists.txt +++ b/examples/widgets/itemviews/simpledommodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/simpledommodel") @@ -21,10 +21,12 @@ qt_add_executable(simpledommodel main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(simpledommodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(simpledommodel PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt b/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt index f6d8aae118..8e6d40274f 100644 --- a/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt +++ b/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/simpletreemodel") @@ -20,17 +20,18 @@ qt_add_executable(simpletreemodel treeitem.cpp treeitem.h treemodel.cpp treemodel.h ) + set_target_properties(simpletreemodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(simpletreemodel PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(simpletreemodel_resource_files "default.txt" diff --git a/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt b/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt index 14ad9bd96c..d34149f224 100644 --- a/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt +++ b/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/simplewidgetmapper") @@ -19,10 +19,12 @@ qt_add_executable(simplewidgetmapper main.cpp window.cpp window.h ) + set_target_properties(simplewidgetmapper PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(simplewidgetmapper PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt b/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt index bcea33915c..a16eb0c53c 100644 --- a/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt +++ b/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/spinboxdelegate") @@ -19,10 +19,12 @@ qt_add_executable(spinboxdelegate delegate.cpp delegate.h main.cpp ) + set_target_properties(spinboxdelegate PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(spinboxdelegate PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/spreadsheet/CMakeLists.txt b/examples/widgets/itemviews/spreadsheet/CMakeLists.txt index e0089a0ed9..2fd1d6b52a 100644 --- a/examples/widgets/itemviews/spreadsheet/CMakeLists.txt +++ b/examples/widgets/itemviews/spreadsheet/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/spreadsheet") @@ -25,10 +25,12 @@ qt_add_executable(spreadsheet spreadsheetdelegate.cpp spreadsheetdelegate.h spreadsheetitem.cpp spreadsheetitem.h ) + set_target_properties(spreadsheet PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(spreadsheet PUBLIC Qt::Core Qt::Gui @@ -39,7 +41,6 @@ if (TARGET Qt::PrintSupport) target_link_libraries(spreadsheet PUBLIC Qt::PrintSupport) endif() - # Resources: set(spreadsheet_resource_files "images/interview.png" diff --git a/examples/widgets/itemviews/stardelegate/CMakeLists.txt b/examples/widgets/itemviews/stardelegate/CMakeLists.txt index 136dc7c83d..44fdd068c5 100644 --- a/examples/widgets/itemviews/stardelegate/CMakeLists.txt +++ b/examples/widgets/itemviews/stardelegate/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/stardelegate") @@ -21,10 +21,12 @@ qt_add_executable(stardelegate stareditor.cpp stareditor.h starrating.cpp starrating.h ) + set_target_properties(stardelegate PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(stardelegate PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/storageview/CMakeLists.txt b/examples/widgets/itemviews/storageview/CMakeLists.txt index 43a11e9f12..6338e214e9 100644 --- a/examples/widgets/itemviews/storageview/CMakeLists.txt +++ b/examples/widgets/itemviews/storageview/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/storageview") @@ -19,10 +19,12 @@ qt_add_executable(storageview main.cpp storagemodel.cpp storagemodel.h ) + set_target_properties(storageview PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(storageview PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/layouts/basiclayouts/CMakeLists.txt b/examples/widgets/layouts/basiclayouts/CMakeLists.txt index 52518163a1..40c27a4a9e 100644 --- a/examples/widgets/layouts/basiclayouts/CMakeLists.txt +++ b/examples/widgets/layouts/basiclayouts/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/layouts/basiclayouts") @@ -19,10 +19,12 @@ qt_add_executable(basiclayouts dialog.cpp dialog.h main.cpp ) + set_target_properties(basiclayouts PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(basiclayouts PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/layouts/borderlayout/CMakeLists.txt b/examples/widgets/layouts/borderlayout/CMakeLists.txt index 3c04f1b66a..4b725eb6a5 100644 --- a/examples/widgets/layouts/borderlayout/CMakeLists.txt +++ b/examples/widgets/layouts/borderlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/layouts/borderlayout") @@ -20,10 +20,12 @@ qt_add_executable(borderlayout main.cpp window.cpp window.h ) + set_target_properties(borderlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(borderlayout PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt b/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt index 565829c1c2..fc0f545baa 100644 --- a/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt +++ b/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/layouts/dynamiclayouts") @@ -19,10 +19,12 @@ qt_add_executable(dynamiclayouts dialog.cpp dialog.h main.cpp ) + set_target_properties(dynamiclayouts PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(dynamiclayouts PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/layouts/flowlayout/CMakeLists.txt b/examples/widgets/layouts/flowlayout/CMakeLists.txt index c28668fb49..762b95f64f 100644 --- a/examples/widgets/layouts/flowlayout/CMakeLists.txt +++ b/examples/widgets/layouts/flowlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/layouts/flowlayout") @@ -20,10 +20,12 @@ qt_add_executable(flowlayout main.cpp window.cpp window.h ) + set_target_properties(flowlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(flowlayout PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/mainwindows/application/CMakeLists.txt b/examples/widgets/mainwindows/application/CMakeLists.txt index 262548a6e1..297a8a31a8 100644 --- a/examples/widgets/mainwindows/application/CMakeLists.txt +++ b/examples/widgets/mainwindows/application/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/application") @@ -19,17 +19,18 @@ qt_add_executable(application main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(application PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(application PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(application_resource_files "images/copy.png" diff --git a/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt b/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt index 5dff006c70..599633909f 100644 --- a/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt +++ b/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/dockwidgets") @@ -22,10 +22,12 @@ qt_add_executable(dockwidgets main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(dockwidgets PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(dockwidgets PUBLIC Qt::Core Qt::Gui @@ -36,7 +38,6 @@ if (TARGET Qt::PrintSupport) target_link_libraries(dockwidgets PUBLIC Qt::PrintSupport) endif() - # Resources: set(dockwidgets_resource_files "images/new.png" diff --git a/examples/widgets/mainwindows/mainwindow/CMakeLists.txt b/examples/widgets/mainwindows/mainwindow/CMakeLists.txt index ee04a59d94..3eb634287e 100644 --- a/examples/widgets/mainwindows/mainwindow/CMakeLists.txt +++ b/examples/widgets/mainwindows/mainwindow/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/mainwindow") @@ -21,17 +21,18 @@ qt_add_executable(mainwindow mainwindow.cpp mainwindow.h toolbar.cpp toolbar.h ) + set_target_properties(mainwindow PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mainwindow PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(mainwindow_resource_files "qt.png" diff --git a/examples/widgets/mainwindows/mdi/CMakeLists.txt b/examples/widgets/mainwindows/mdi/CMakeLists.txt index 7a2efef80f..ce72767f1c 100644 --- a/examples/widgets/mainwindows/mdi/CMakeLists.txt +++ b/examples/widgets/mainwindows/mdi/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/mdi") @@ -20,17 +20,18 @@ qt_add_executable(mdi mainwindow.cpp mainwindow.h mdichild.cpp mdichild.h ) + set_target_properties(mdi PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mdi PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(mdi_resource_files "images/copy.png" diff --git a/examples/widgets/mainwindows/menus/CMakeLists.txt b/examples/widgets/mainwindows/menus/CMakeLists.txt index ee5eb4e616..61ccd76f16 100644 --- a/examples/widgets/mainwindows/menus/CMakeLists.txt +++ b/examples/widgets/mainwindows/menus/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/menus") @@ -19,10 +19,12 @@ qt_add_executable(menus main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(menus PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(menus PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/mainwindows/sdi/CMakeLists.txt b/examples/widgets/mainwindows/sdi/CMakeLists.txt index 89b3228293..616f096edf 100644 --- a/examples/widgets/mainwindows/sdi/CMakeLists.txt +++ b/examples/widgets/mainwindows/sdi/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/sdi") @@ -19,17 +19,18 @@ qt_add_executable(sdi main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(sdi PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(sdi PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(sdi_resource_files "images/copy.png" diff --git a/examples/widgets/painting/affine/CMakeLists.txt b/examples/widgets/painting/affine/CMakeLists.txt index 88792be8f0..bf27c49fce 100644 --- a/examples/widgets/painting/affine/CMakeLists.txt +++ b/examples/widgets/painting/affine/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/affine") @@ -23,10 +23,12 @@ qt_add_executable(affine main.cpp xform.cpp xform.h ) + set_target_properties(affine PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(affine PUBLIC ../shared ) @@ -42,7 +44,6 @@ target_link_libraries(affine PUBLIC painting_shared::painting_shared ) - # Resources: set(shared_resource_files "../shared/images/button_normal_cap_left.png" @@ -90,6 +91,7 @@ qt_add_resources(affine "shared" FILES ${shared_resource_files} ) + set(affine_resource_files "bg1.jpg" "xform.cpp" diff --git a/examples/widgets/painting/basicdrawing/CMakeLists.txt b/examples/widgets/painting/basicdrawing/CMakeLists.txt index 83faca559e..574f508412 100644 --- a/examples/widgets/painting/basicdrawing/CMakeLists.txt +++ b/examples/widgets/painting/basicdrawing/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/basicdrawing") @@ -20,17 +20,18 @@ qt_add_executable(basicdrawing renderarea.cpp renderarea.h window.cpp window.h ) + set_target_properties(basicdrawing PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(basicdrawing PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(basicdrawing_resource_files "images/brick.png" diff --git a/examples/widgets/painting/composition/CMakeLists.txt b/examples/widgets/painting/composition/CMakeLists.txt index 62156d45e4..ca8c2e0214 100644 --- a/examples/widgets/painting/composition/CMakeLists.txt +++ b/examples/widgets/painting/composition/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/composition") @@ -23,10 +23,12 @@ qt_add_executable(composition composition.cpp composition.h main.cpp ) + set_target_properties(composition PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(composition PUBLIC ../shared ) @@ -42,7 +44,6 @@ target_link_libraries(composition PUBLIC painting_shared::painting_shared ) - # Resources: set(shared_resource_files "../shared/images/button_normal_cap_left.png" @@ -90,6 +91,7 @@ qt_add_resources(composition "shared" FILES ${shared_resource_files} ) + set(composition_resource_files "composition.cpp" "composition.html" diff --git a/examples/widgets/painting/concentriccircles/CMakeLists.txt b/examples/widgets/painting/concentriccircles/CMakeLists.txt index 72ed7d8776..a37cc58b1f 100644 --- a/examples/widgets/painting/concentriccircles/CMakeLists.txt +++ b/examples/widgets/painting/concentriccircles/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/concentriccircles") @@ -20,10 +20,12 @@ qt_add_executable(concentriccircles main.cpp window.cpp window.h ) + set_target_properties(concentriccircles PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(concentriccircles PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/painting/deform/CMakeLists.txt b/examples/widgets/painting/deform/CMakeLists.txt index 1174cf5a27..12f48f7891 100644 --- a/examples/widgets/painting/deform/CMakeLists.txt +++ b/examples/widgets/painting/deform/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/deform") @@ -23,10 +23,12 @@ qt_add_executable(deform main.cpp pathdeform.cpp pathdeform.h ) + set_target_properties(deform PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(deform PUBLIC ../shared ) @@ -42,7 +44,6 @@ target_link_libraries(deform PUBLIC painting_shared::painting_shared ) - # Resources: set(shared_resource_files "../shared/images/button_normal_cap_left.png" @@ -90,6 +91,7 @@ qt_add_resources(deform "shared" FILES ${shared_resource_files} ) + set(deform_resource_files "pathdeform.cpp" "pathdeform.html" diff --git a/examples/widgets/painting/fontsampler/CMakeLists.txt b/examples/widgets/painting/fontsampler/CMakeLists.txt index e0b683ba33..5e92a51620 100644 --- a/examples/widgets/painting/fontsampler/CMakeLists.txt +++ b/examples/widgets/painting/fontsampler/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/fontsampler") @@ -23,10 +23,12 @@ qt_add_executable(fontsampler mainwindow.cpp mainwindow.h mainwindowbase.ui ) + set_target_properties(fontsampler PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(fontsampler PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/painting/gradients/CMakeLists.txt b/examples/widgets/painting/gradients/CMakeLists.txt index 6de1d3c47e..5df3d78ac1 100644 --- a/examples/widgets/painting/gradients/CMakeLists.txt +++ b/examples/widgets/painting/gradients/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/gradients") @@ -23,10 +23,12 @@ qt_add_executable(gradients gradients.cpp gradients.h main.cpp ) + set_target_properties(gradients PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(gradients PUBLIC ../shared ) @@ -42,7 +44,6 @@ target_link_libraries(gradients PUBLIC painting_shared::painting_shared ) - # Resources: set(shared_resource_files "../shared/images/button_normal_cap_left.png" @@ -90,6 +91,7 @@ qt_add_resources(gradients "shared" FILES ${shared_resource_files} ) + set(gradients_resource_files "gradients.cpp" "gradients.html" diff --git a/examples/widgets/painting/imagecomposition/CMakeLists.txt b/examples/widgets/painting/imagecomposition/CMakeLists.txt index 2887d84002..e5ff8cb82f 100644 --- a/examples/widgets/painting/imagecomposition/CMakeLists.txt +++ b/examples/widgets/painting/imagecomposition/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/imagecomposition") @@ -19,17 +19,18 @@ qt_add_executable(imagecomposition imagecomposer.cpp imagecomposer.h main.cpp ) + set_target_properties(imagecomposition PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(imagecomposition PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(imagecomposition_resource_files "images/butterfly.png" diff --git a/examples/widgets/painting/painterpaths/CMakeLists.txt b/examples/widgets/painting/painterpaths/CMakeLists.txt index f4530521dc..8bb43e775f 100644 --- a/examples/widgets/painting/painterpaths/CMakeLists.txt +++ b/examples/widgets/painting/painterpaths/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/painterpaths") @@ -20,10 +20,12 @@ qt_add_executable(painterpaths renderarea.cpp renderarea.h window.cpp window.h ) + set_target_properties(painterpaths PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(painterpaths PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/painting/pathstroke/CMakeLists.txt b/examples/widgets/painting/pathstroke/CMakeLists.txt index 9e28706529..63c804c7ce 100644 --- a/examples/widgets/painting/pathstroke/CMakeLists.txt +++ b/examples/widgets/painting/pathstroke/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/pathstroke") @@ -23,10 +23,12 @@ qt_add_executable(pathstroke main.cpp pathstroke.cpp pathstroke.h ) + set_target_properties(pathstroke PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(pathstroke PUBLIC ../shared ) @@ -42,7 +44,6 @@ target_link_libraries(pathstroke PUBLIC painting_shared::painting_shared ) - # Resources: set(shared_resource_files "../shared/images/button_normal_cap_left.png" @@ -90,6 +91,7 @@ qt_add_resources(pathstroke "shared" FILES ${shared_resource_files} ) + set(pathstroke_resource_files "pathstroke.cpp" "pathstroke.html" diff --git a/examples/widgets/painting/shared/CMakeLists.txt b/examples/widgets/painting/shared/CMakeLists.txt index bd1b2ef5c6..a81b1413c7 100644 --- a/examples/widgets/painting/shared/CMakeLists.txt +++ b/examples/widgets/painting/shared/CMakeLists.txt @@ -7,6 +7,7 @@ target_sources(painting_shared PRIVATE hoverpoints.cpp hoverpoints.h ${moc_files} ) + target_link_libraries(painting_shared PUBLIC Qt::Widgets) target_include_directories(painting_shared PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}") diff --git a/examples/widgets/painting/transformations/CMakeLists.txt b/examples/widgets/painting/transformations/CMakeLists.txt index 990871318f..7c1c6495d7 100644 --- a/examples/widgets/painting/transformations/CMakeLists.txt +++ b/examples/widgets/painting/transformations/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/transformations") @@ -20,10 +20,12 @@ qt_add_executable(transformations renderarea.cpp renderarea.h window.cpp window.h ) + set_target_properties(transformations PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(transformations PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/richtext/calendar/CMakeLists.txt b/examples/widgets/richtext/calendar/CMakeLists.txt index c883b30dcc..28b8249e84 100644 --- a/examples/widgets/richtext/calendar/CMakeLists.txt +++ b/examples/widgets/richtext/calendar/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/richtext/calendar") @@ -19,10 +19,12 @@ qt_add_executable(calendar main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(calendar PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(calendar PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/richtext/orderform/CMakeLists.txt b/examples/widgets/richtext/orderform/CMakeLists.txt index 32646d7b59..da099b79f1 100644 --- a/examples/widgets/richtext/orderform/CMakeLists.txt +++ b/examples/widgets/richtext/orderform/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/richtext/orderform") @@ -20,10 +20,12 @@ qt_add_executable(orderform main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(orderform PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(orderform PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt b/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt index d9a20cccd4..732c285cc6 100644 --- a/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt +++ b/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/richtext/syntaxhighlighter") @@ -20,10 +20,12 @@ qt_add_executable(syntaxhighlighter main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(syntaxhighlighter PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(syntaxhighlighter PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/richtext/textedit/CMakeLists.txt b/examples/widgets/richtext/textedit/CMakeLists.txt index 3a29d09a61..1e22a14614 100644 --- a/examples/widgets/richtext/textedit/CMakeLists.txt +++ b/examples/widgets/richtext/textedit/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/richtext/textedit") @@ -22,10 +22,12 @@ qt_add_executable(textedit main.cpp textedit.cpp textedit.h ) + set_target_properties(textedit PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(textedit PUBLIC Qt::Core Qt::Gui @@ -36,7 +38,6 @@ if (TARGET Qt::PrintSupport) target_link_libraries(textedit PUBLIC Qt::PrintSupport) endif() - # Resources: set(textedit_resource_files "example.html" diff --git a/examples/widgets/scroller/graphicsview/CMakeLists.txt b/examples/widgets/scroller/graphicsview/CMakeLists.txt index 5f768c8694..36721aeae0 100644 --- a/examples/widgets/scroller/graphicsview/CMakeLists.txt +++ b/examples/widgets/scroller/graphicsview/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/scroller/graphicsview") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(graphicsview main.cpp ) + set_target_properties(graphicsview PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(graphicsview PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tools/completer/CMakeLists.txt b/examples/widgets/tools/completer/CMakeLists.txt index 8ec960dafd..21cd750de8 100644 --- a/examples/widgets/tools/completer/CMakeLists.txt +++ b/examples/widgets/tools/completer/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/completer") @@ -20,17 +20,18 @@ qt_add_executable(completer main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(completer PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(completer PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(completer_resource_files "resources/countries.txt" diff --git a/examples/widgets/tools/customcompleter/CMakeLists.txt b/examples/widgets/tools/customcompleter/CMakeLists.txt index 9e0bbee241..558262f948 100644 --- a/examples/widgets/tools/customcompleter/CMakeLists.txt +++ b/examples/widgets/tools/customcompleter/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/customcompleter") @@ -20,17 +20,18 @@ qt_add_executable(customcompleter mainwindow.cpp mainwindow.h textedit.cpp textedit.h ) + set_target_properties(customcompleter PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(customcompleter PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(customcompleter_resource_files "resources/wordlist.txt" diff --git a/examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt b/examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt index 3fcbe17172..29183a7c1f 100644 --- a/examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt +++ b/examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt @@ -3,10 +3,12 @@ qt_add_executable(echopluginwindow echowindow.cpp echowindow.h main.cpp ) + set_target_properties(echopluginwindow PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(echopluginwindow PRIVATE Qt::Core Qt::Gui diff --git a/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt b/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt index fb727aa1d7..7d63180a87 100644 --- a/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt +++ b/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt @@ -1,12 +1,15 @@ qt_add_plugin(echoplugin CLASS_NAME EchoPlugin ) + target_sources(echoplugin PRIVATE echoplugin.cpp echoplugin.h ) + set_target_properties(echoplugin PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/echowindow" ) + target_include_directories(echoplugin PUBLIC ../echowindow ) diff --git a/examples/widgets/tools/i18n/CMakeLists.txt b/examples/widgets/tools/i18n/CMakeLists.txt index 0cb230a805..362fa96c8f 100644 --- a/examples/widgets/tools/i18n/CMakeLists.txt +++ b/examples/widgets/tools/i18n/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/i18n") @@ -20,17 +20,18 @@ qt_add_executable(i18n main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(i18n PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(i18n PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(i18n_resource_files "translations/i18n_ar.qm" diff --git a/examples/widgets/tools/plugandpaint/app/CMakeLists.txt b/examples/widgets/tools/plugandpaint/app/CMakeLists.txt index 3e46331f81..f2b5b4937f 100644 --- a/examples/widgets/tools/plugandpaint/app/CMakeLists.txt +++ b/examples/widgets/tools/plugandpaint/app/CMakeLists.txt @@ -5,10 +5,12 @@ qt_add_executable(plugandpaint paintarea.cpp paintarea.h plugindialog.cpp plugindialog.h ) + set_target_properties(plugandpaint PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(plugandpaint PRIVATE Qt::Widgets pnp_basictools diff --git a/examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt b/examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt index 0056205319..638bb53ef6 100644 --- a/examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt +++ b/examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt @@ -2,9 +2,11 @@ qt_add_plugin(pnp_basictools STATIC CLASS_NAME BasicToolsPlugin ) + target_sources(pnp_basictools PRIVATE basictoolsplugin.cpp basictoolsplugin.h ) + target_include_directories(pnp_basictools PUBLIC ../../app ) diff --git a/examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt b/examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt index 2332f84399..4a3dd45de9 100644 --- a/examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt +++ b/examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt @@ -1,12 +1,15 @@ qt_add_plugin(pnp_extrafilters CLASS_NAME ExtraFiltersPlugin ) + target_sources(pnp_extrafilters PRIVATE extrafiltersplugin.cpp extrafiltersplugin.h ) + set_target_properties(pnp_extrafilters PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/app" ) + target_include_directories(pnp_extrafilters PUBLIC ../../app ) diff --git a/examples/widgets/tools/regularexpression/CMakeLists.txt b/examples/widgets/tools/regularexpression/CMakeLists.txt index 85f9a81156..c249eda5ac 100644 --- a/examples/widgets/tools/regularexpression/CMakeLists.txt +++ b/examples/widgets/tools/regularexpression/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/regularexpression") @@ -19,17 +19,18 @@ qt_add_executable(regularexpression main.cpp regularexpressiondialog.cpp regularexpressiondialog.h ) + set_target_properties(regularexpression PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(regularexpression PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(regularexpression_resource_files "images/copy.png" diff --git a/examples/widgets/tools/settingseditor/CMakeLists.txt b/examples/widgets/tools/settingseditor/CMakeLists.txt index e1b6f95eb5..11795c260b 100644 --- a/examples/widgets/tools/settingseditor/CMakeLists.txt +++ b/examples/widgets/tools/settingseditor/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/settingseditor") @@ -22,10 +22,12 @@ qt_add_executable(settingseditor settingstree.cpp settingstree.h variantdelegate.cpp variantdelegate.h ) + set_target_properties(settingseditor PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(settingseditor PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tools/styleplugin/plugin/CMakeLists.txt b/examples/widgets/tools/styleplugin/plugin/CMakeLists.txt index 30a06231c1..fb2b877ca6 100644 --- a/examples/widgets/tools/styleplugin/plugin/CMakeLists.txt +++ b/examples/widgets/tools/styleplugin/plugin/CMakeLists.txt @@ -1,13 +1,16 @@ qt_add_plugin(simplestyleplugin CLASS_NAME SimpleStylePlugin ) + target_sources(simplestyleplugin PRIVATE simplestyle.cpp simplestyle.h simplestyleplugin.cpp simplestyleplugin.h ) + set_target_properties(simplestyleplugin PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/stylewindow/styles" ) + target_link_libraries(simplestyleplugin PRIVATE Qt::Core Qt::Gui diff --git a/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt b/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt index aab63afbf2..fe844aaf4b 100644 --- a/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt +++ b/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt @@ -2,15 +2,18 @@ qt_add_executable(styleplugin main.cpp stylewindow.cpp stylewindow.h ) + set_target_properties(styleplugin PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(styleplugin PRIVATE Qt::Core Qt::Gui Qt::Widgets ) + if(NOT QT6_IS_SHARED_LIBS_BUILD) target_link_libraries(styleplugin PRIVATE simplestyleplugin diff --git a/examples/widgets/tools/treemodelcompleter/CMakeLists.txt b/examples/widgets/tools/treemodelcompleter/CMakeLists.txt index 1e641fc5b2..64b5e67309 100644 --- a/examples/widgets/tools/treemodelcompleter/CMakeLists.txt +++ b/examples/widgets/tools/treemodelcompleter/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/treemodelcompleter") @@ -20,17 +20,18 @@ qt_add_executable(treemodelcompleter mainwindow.cpp mainwindow.h treemodelcompleter.cpp treemodelcompleter.h ) + set_target_properties(treemodelcompleter PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(treemodelcompleter PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(treemodelcompleter_resource_files "resources/treemodel.txt" diff --git a/examples/widgets/tools/undo/CMakeLists.txt b/examples/widgets/tools/undo/CMakeLists.txt index 113b3b5a6d..0b9e5047e6 100644 --- a/examples/widgets/tools/undo/CMakeLists.txt +++ b/examples/widgets/tools/undo/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/undo") @@ -21,17 +21,18 @@ qt_add_executable(undo main.cpp mainwindow.cpp mainwindow.h mainwindow.ui ) + set_target_properties(undo PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(undo PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(undo_resource_files "icons/background.png" diff --git a/examples/widgets/tools/undoframework/CMakeLists.txt b/examples/widgets/tools/undoframework/CMakeLists.txt index c142f5d863..0d43d4a669 100644 --- a/examples/widgets/tools/undoframework/CMakeLists.txt +++ b/examples/widgets/tools/undoframework/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/undoframework") @@ -22,17 +22,18 @@ qt_add_executable(undoframework main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(undoframework PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(undoframework PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(undoframework_resource_files "images/cross.png" diff --git a/examples/widgets/touch/dials/CMakeLists.txt b/examples/widgets/touch/dials/CMakeLists.txt index a7a6153631..36789c0714 100644 --- a/examples/widgets/touch/dials/CMakeLists.txt +++ b/examples/widgets/touch/dials/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/touch/dials") @@ -19,10 +19,12 @@ qt_add_executable(dials dials.ui main.cpp ) + set_target_properties(dials PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(dials PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/touch/fingerpaint/CMakeLists.txt b/examples/widgets/touch/fingerpaint/CMakeLists.txt index f2ed4be8df..d7f22940f3 100644 --- a/examples/widgets/touch/fingerpaint/CMakeLists.txt +++ b/examples/widgets/touch/fingerpaint/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/touch/fingerpaint") @@ -23,10 +23,12 @@ qt_add_executable(fingerpaint mainwindow.cpp mainwindow.h scribblearea.cpp scribblearea.h ) + set_target_properties(fingerpaint PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(fingerpaint PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/touch/knobs/CMakeLists.txt b/examples/widgets/touch/knobs/CMakeLists.txt index f92bb52a59..e921365791 100644 --- a/examples/widgets/touch/knobs/CMakeLists.txt +++ b/examples/widgets/touch/knobs/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/touch/knobs") @@ -19,10 +19,12 @@ qt_add_executable(knobs knob.cpp knob.h main.cpp ) + set_target_properties(knobs PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(knobs PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/touch/pinchzoom/CMakeLists.txt b/examples/widgets/touch/pinchzoom/CMakeLists.txt index 19a9fe6c67..d7528ea8f0 100644 --- a/examples/widgets/touch/pinchzoom/CMakeLists.txt +++ b/examples/widgets/touch/pinchzoom/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/touch/pinchzoom") @@ -20,17 +20,18 @@ qt_add_executable(pinchzoom main.cpp mouse.cpp mouse.h ) + set_target_properties(pinchzoom PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(pinchzoom PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(mice_resource_files "images/cheese.jpg" diff --git a/examples/widgets/tutorials/addressbook/part1/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part1/CMakeLists.txt index c7f30def59..d30c561486 100644 --- a/examples/widgets/tutorials/addressbook/part1/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part1/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part1") @@ -19,10 +19,12 @@ qt_add_executable(part1 addressbook.cpp addressbook.h main.cpp ) + set_target_properties(part1 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part1 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt index 9cb1ff02a9..16019b2d0a 100644 --- a/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part2") @@ -19,10 +19,12 @@ qt_add_executable(part2 addressbook.cpp addressbook.h main.cpp ) + set_target_properties(part2 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part2 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt index 56385d9d25..232fb299c7 100644 --- a/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part3") @@ -19,10 +19,12 @@ qt_add_executable(part3 addressbook.cpp addressbook.h main.cpp ) + set_target_properties(part3 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part3 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt index cf99c3b801..04f72d3450 100644 --- a/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part4") @@ -19,10 +19,12 @@ qt_add_executable(part4 addressbook.cpp addressbook.h main.cpp ) + set_target_properties(part4 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part4 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt index 96ac3257d7..343bc60657 100644 --- a/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part5") @@ -20,10 +20,12 @@ qt_add_executable(part5 finddialog.cpp finddialog.h main.cpp ) + set_target_properties(part5 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part5 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt index 673996b9a5..91d4c0cf8d 100644 --- a/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part6") @@ -20,10 +20,12 @@ qt_add_executable(part6 finddialog.cpp finddialog.h main.cpp ) + set_target_properties(part6 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part6 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt index 41a89a2753..dbd4e49d50 100644 --- a/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part7") @@ -20,10 +20,12 @@ qt_add_executable(part7 finddialog.cpp finddialog.h main.cpp ) + set_target_properties(part7 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part7 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt index 97bd513ef5..90cf464550 100644 --- a/examples/widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt +++ b/examples/widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part1") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(getting_started_part1 main.cpp ) + set_target_properties(getting_started_part1 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(getting_started_part1 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt index c10322046b..cdb39fd2b4 100644 --- a/examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt +++ b/examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part2") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(getting_started_part2 main.cpp ) + set_target_properties(getting_started_part2 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(getting_started_part2 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt index d5e5dfb603..6a4f3c4faf 100644 --- a/examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt +++ b/examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part3") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(getting_started_part3 main.cpp ) + set_target_properties(getting_started_part3 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(getting_started_part3 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt index 6531bce71c..f4a28f0f0b 100644 --- a/examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt +++ b/examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part4") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(getting_started_part4 main.cpp ) + set_target_properties(getting_started_part4 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(getting_started_part4 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt index 1cdc84dd71..71f4df16cc 100644 --- a/examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt +++ b/examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part5") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(getting_started_part5 main.cpp ) + set_target_properties(getting_started_part5 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(getting_started_part5 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt b/examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt index 045e6409d6..39f6753490 100644 --- a/examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/1_readonly") @@ -19,10 +19,12 @@ qt_add_executable(mv_readonly main.cpp mymodel.cpp mymodel.h ) + set_target_properties(mv_readonly PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_readonly PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt b/examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt index c3e9a29d54..7479df3cec 100644 --- a/examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/2_formatting") @@ -19,10 +19,12 @@ qt_add_executable(mv_formatting main.cpp mymodel.cpp mymodel.h ) + set_target_properties(mv_formatting PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_formatting PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt b/examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt index b8a4c9ba1f..99fcf9bbe7 100644 --- a/examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/3_changingmodel") @@ -19,10 +19,12 @@ qt_add_executable(mv_changingmodel main.cpp mymodel.cpp mymodel.h ) + set_target_properties(mv_changingmodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_changingmodel PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt b/examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt index 80d55f3096..1b3a4462b7 100644 --- a/examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/4_headers") @@ -19,10 +19,12 @@ qt_add_executable(mv_headers main.cpp mymodel.cpp mymodel.h ) + set_target_properties(mv_headers PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_headers PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt b/examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt index 61cffe039f..bcfaf4f539 100644 --- a/examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/5_edit") @@ -20,10 +20,12 @@ qt_add_executable(mv_edit mainwindow.cpp mainwindow.h mymodel.cpp mymodel.h ) + set_target_properties(mv_edit PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_edit PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt b/examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt index b4ba1d7256..8d269c53fb 100644 --- a/examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/6_treeview") @@ -19,10 +19,12 @@ qt_add_executable(mv_tree main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(mv_tree PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_tree PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt b/examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt index aef8718e5f..5ae8c349fc 100644 --- a/examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/7_selections") @@ -19,10 +19,12 @@ qt_add_executable(mv_selections main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(mv_selections PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_selections PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/notepad/CMakeLists.txt b/examples/widgets/tutorials/notepad/CMakeLists.txt index aa11c84a6b..cdfe9a7c54 100644 --- a/examples/widgets/tutorials/notepad/CMakeLists.txt +++ b/examples/widgets/tutorials/notepad/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/notepad") @@ -22,17 +22,18 @@ qt_add_executable(notepad main.cpp notepad.cpp notepad.h notepad.ui ) + set_target_properties(notepad PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(notepad PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(notepad_resource_files "images/bold.png" diff --git a/examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt b/examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt index e88197dc95..f0d619b99a 100644 --- a/examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt +++ b/examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/childwidget") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(childwidget main.cpp ) + set_target_properties(childwidget PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(childwidget PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt b/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt index e3b31cfa4e..c0fd8e402e 100644 --- a/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt +++ b/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/nestedlayouts") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(nestedlayouts main.cpp ) + set_target_properties(nestedlayouts PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(nestedlayouts PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt b/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt index 14bd7a63fa..8e396dd499 100644 --- a/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt +++ b/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/toplevel") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(toplevel main.cpp ) + set_target_properties(toplevel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(toplevel PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt b/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt index ae8b995868..0f5f8cac09 100644 --- a/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt +++ b/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/windowlayout") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(windowlayout main.cpp ) + set_target_properties(windowlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(windowlayout PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/analogclock/CMakeLists.txt b/examples/widgets/widgets/analogclock/CMakeLists.txt index b775b23485..c2272d1c58 100644 --- a/examples/widgets/widgets/analogclock/CMakeLists.txt +++ b/examples/widgets/widgets/analogclock/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/analogclock") @@ -19,10 +19,12 @@ qt_add_executable(analogclock analogclock.cpp analogclock.h main.cpp ) + set_target_properties(analogclock PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(analogclock PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/calculator/CMakeLists.txt b/examples/widgets/widgets/calculator/CMakeLists.txt index 419e4e3bd1..632b29830d 100644 --- a/examples/widgets/widgets/calculator/CMakeLists.txt +++ b/examples/widgets/widgets/calculator/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/calculator") @@ -20,10 +20,12 @@ qt_add_executable(calculator calculator.cpp calculator.h main.cpp ) + set_target_properties(calculator PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(calculator PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/calendarwidget/CMakeLists.txt b/examples/widgets/widgets/calendarwidget/CMakeLists.txt index b1ee4577f1..ded17a89b2 100644 --- a/examples/widgets/widgets/calendarwidget/CMakeLists.txt +++ b/examples/widgets/widgets/calendarwidget/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/calendarwidget") @@ -19,10 +19,12 @@ qt_add_executable(calendarwidget main.cpp window.cpp window.h ) + set_target_properties(calendarwidget PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(calendarwidget PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/charactermap/CMakeLists.txt b/examples/widgets/widgets/charactermap/CMakeLists.txt index 65956f7afd..5b04621e1c 100644 --- a/examples/widgets/widgets/charactermap/CMakeLists.txt +++ b/examples/widgets/widgets/charactermap/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/charactermap") @@ -20,10 +20,12 @@ qt_add_executable(charactermap main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(charactermap PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(charactermap PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/codeeditor/CMakeLists.txt b/examples/widgets/widgets/codeeditor/CMakeLists.txt index 9eb4f1a8bd..4d00611116 100644 --- a/examples/widgets/widgets/codeeditor/CMakeLists.txt +++ b/examples/widgets/widgets/codeeditor/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/codeeditor") @@ -19,10 +19,12 @@ qt_add_executable(codeeditor codeeditor.cpp codeeditor.h main.cpp ) + set_target_properties(codeeditor PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(codeeditor PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/digitalclock/CMakeLists.txt b/examples/widgets/widgets/digitalclock/CMakeLists.txt index e2e1c4a1e3..722a91245a 100644 --- a/examples/widgets/widgets/digitalclock/CMakeLists.txt +++ b/examples/widgets/widgets/digitalclock/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/digitalclock") @@ -19,10 +19,12 @@ qt_add_executable(digitalclock digitalclock.cpp digitalclock.h main.cpp ) + set_target_properties(digitalclock PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(digitalclock PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/elidedlabel/CMakeLists.txt b/examples/widgets/widgets/elidedlabel/CMakeLists.txt index feb46d9720..0b83c6f08b 100644 --- a/examples/widgets/widgets/elidedlabel/CMakeLists.txt +++ b/examples/widgets/widgets/elidedlabel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/elidedlabel") @@ -20,10 +20,12 @@ qt_add_executable(elidedlabel main.cpp testwidget.cpp testwidget.h ) + set_target_properties(elidedlabel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(elidedlabel PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/groupbox/CMakeLists.txt b/examples/widgets/widgets/groupbox/CMakeLists.txt index 9108a0a868..a77209454f 100644 --- a/examples/widgets/widgets/groupbox/CMakeLists.txt +++ b/examples/widgets/widgets/groupbox/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/groupbox") @@ -19,10 +19,12 @@ qt_add_executable(groupbox main.cpp window.cpp window.h ) + set_target_properties(groupbox PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(groupbox PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/icons/CMakeLists.txt b/examples/widgets/widgets/icons/CMakeLists.txt index 52a59c1d3d..5db4cf58e8 100644 --- a/examples/widgets/widgets/icons/CMakeLists.txt +++ b/examples/widgets/widgets/icons/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/icons") @@ -22,10 +22,12 @@ qt_add_executable(icons main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(icons PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_compile_definitions(icons PUBLIC SRCDIR="${CMAKE_CURRENT_SOURCE_DIR}" ) diff --git a/examples/widgets/widgets/imageviewer/CMakeLists.txt b/examples/widgets/widgets/imageviewer/CMakeLists.txt index 96b782b0cd..6fda6fbaeb 100644 --- a/examples/widgets/widgets/imageviewer/CMakeLists.txt +++ b/examples/widgets/widgets/imageviewer/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/imageviewer") @@ -22,10 +22,12 @@ qt_add_executable(imageviewer imageviewer.cpp imageviewer.h main.cpp ) + set_target_properties(imageviewer PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(imageviewer PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/lineedits/CMakeLists.txt b/examples/widgets/widgets/lineedits/CMakeLists.txt index 7cc503cdfc..6b42e04b43 100644 --- a/examples/widgets/widgets/lineedits/CMakeLists.txt +++ b/examples/widgets/widgets/lineedits/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/lineedits") @@ -19,10 +19,12 @@ qt_add_executable(lineedits main.cpp window.cpp window.h ) + set_target_properties(lineedits PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(lineedits PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/mousebuttons/CMakeLists.txt b/examples/widgets/widgets/mousebuttons/CMakeLists.txt index 8083642320..5e4067cafd 100644 --- a/examples/widgets/widgets/mousebuttons/CMakeLists.txt +++ b/examples/widgets/widgets/mousebuttons/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/mousebuttons") @@ -19,10 +19,12 @@ qt_add_executable(mousebuttons buttontester.cpp buttontester.h main.cpp ) + set_target_properties(mousebuttons PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mousebuttons PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/movie/CMakeLists.txt b/examples/widgets/widgets/movie/CMakeLists.txt index 37ff633a6a..74f6480667 100644 --- a/examples/widgets/widgets/movie/CMakeLists.txt +++ b/examples/widgets/widgets/movie/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/movie") @@ -19,10 +19,12 @@ qt_add_executable(movie main.cpp movieplayer.cpp movieplayer.h ) + set_target_properties(movie PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(movie PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/scribble/CMakeLists.txt b/examples/widgets/widgets/scribble/CMakeLists.txt index 92001b138f..9827312ccb 100644 --- a/examples/widgets/widgets/scribble/CMakeLists.txt +++ b/examples/widgets/widgets/scribble/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/scribble") @@ -23,10 +23,12 @@ qt_add_executable(scribble mainwindow.cpp mainwindow.h scribblearea.cpp scribblearea.h ) + set_target_properties(scribble PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(scribble PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/shapedclock/CMakeLists.txt b/examples/widgets/widgets/shapedclock/CMakeLists.txt index 5271bcf096..e941da0390 100644 --- a/examples/widgets/widgets/shapedclock/CMakeLists.txt +++ b/examples/widgets/widgets/shapedclock/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/shapedclock") @@ -19,10 +19,12 @@ qt_add_executable(shapedclock main.cpp shapedclock.cpp shapedclock.h ) + set_target_properties(shapedclock PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(shapedclock PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/sliders/CMakeLists.txt b/examples/widgets/widgets/sliders/CMakeLists.txt index 8354eef6af..615ecdf288 100644 --- a/examples/widgets/widgets/sliders/CMakeLists.txt +++ b/examples/widgets/widgets/sliders/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/sliders") @@ -20,10 +20,12 @@ qt_add_executable(sliders slidersgroup.cpp slidersgroup.h window.cpp window.h ) + set_target_properties(sliders PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(sliders PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/spinboxes/CMakeLists.txt b/examples/widgets/widgets/spinboxes/CMakeLists.txt index bc38a8f360..835cf9148f 100644 --- a/examples/widgets/widgets/spinboxes/CMakeLists.txt +++ b/examples/widgets/widgets/spinboxes/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/spinboxes") @@ -19,10 +19,12 @@ qt_add_executable(spinboxes main.cpp window.cpp window.h ) + set_target_properties(spinboxes PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(spinboxes PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/styles/CMakeLists.txt b/examples/widgets/widgets/styles/CMakeLists.txt index ca478eccaa..d472c1efd2 100644 --- a/examples/widgets/widgets/styles/CMakeLists.txt +++ b/examples/widgets/widgets/styles/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/styles") @@ -20,17 +20,18 @@ qt_add_executable(styles norwegianwoodstyle.cpp norwegianwoodstyle.h widgetgallery.cpp widgetgallery.h ) + set_target_properties(styles PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(styles PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(styles_resource_files "images/woodbackground.png" diff --git a/examples/widgets/widgets/stylesheet/CMakeLists.txt b/examples/widgets/widgets/stylesheet/CMakeLists.txt index 743859d5cb..b91fde9f74 100644 --- a/examples/widgets/widgets/stylesheet/CMakeLists.txt +++ b/examples/widgets/widgets/stylesheet/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/stylesheet") @@ -20,17 +20,18 @@ qt_add_executable(stylesheet mainwindow.cpp mainwindow.h mainwindow.ui stylesheeteditor.cpp stylesheeteditor.h stylesheeteditor.ui ) + set_target_properties(stylesheet PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(stylesheet PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(stylesheet_resource_files "images/checkbox_checked.png" diff --git a/examples/widgets/widgets/tablet/CMakeLists.txt b/examples/widgets/widgets/tablet/CMakeLists.txt index f2faeef3f9..ede90ce392 100644 --- a/examples/widgets/widgets/tablet/CMakeLists.txt +++ b/examples/widgets/widgets/tablet/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/tablet") @@ -21,17 +21,18 @@ qt_add_executable(qttablet tabletapplication.cpp tabletapplication.h tabletcanvas.cpp tabletcanvas.h ) + set_target_properties(qttablet PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(qttablet PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(images_resource_files "images/cursor-airbrush.png" diff --git a/examples/widgets/widgets/tetrix/CMakeLists.txt b/examples/widgets/widgets/tetrix/CMakeLists.txt index 6e76e5c9f0..b60c882d1d 100644 --- a/examples/widgets/widgets/tetrix/CMakeLists.txt +++ b/examples/widgets/widgets/tetrix/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/tetrix") @@ -21,10 +21,12 @@ qt_add_executable(tetrix tetrixpiece.cpp tetrixpiece.h tetrixwindow.cpp tetrixwindow.h ) + set_target_properties(tetrix PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(tetrix PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/tooltips/CMakeLists.txt b/examples/widgets/widgets/tooltips/CMakeLists.txt index 8126e7eb06..2172beba37 100644 --- a/examples/widgets/widgets/tooltips/CMakeLists.txt +++ b/examples/widgets/widgets/tooltips/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/tooltips") @@ -20,17 +20,18 @@ qt_add_executable(tooltips shapeitem.cpp shapeitem.h sortingbox.cpp sortingbox.h ) + set_target_properties(tooltips PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(tooltips PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(tooltips_resource_files "images/circle.png" diff --git a/examples/widgets/widgets/validators/CMakeLists.txt b/examples/widgets/widgets/validators/CMakeLists.txt index c6e9ea905f..0151d68d0e 100644 --- a/examples/widgets/widgets/validators/CMakeLists.txt +++ b/examples/widgets/widgets/validators/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/validators") @@ -22,17 +22,18 @@ qt_add_executable(validators validators.ui validatorwidget.cpp validatorwidget.h ) + set_target_properties(validators PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(validators PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(validators_resource_files "ledoff.png" diff --git a/examples/widgets/widgets/wiggly/CMakeLists.txt b/examples/widgets/widgets/wiggly/CMakeLists.txt index 26bd8d14e8..92b0b34156 100644 --- a/examples/widgets/widgets/wiggly/CMakeLists.txt +++ b/examples/widgets/widgets/wiggly/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/wiggly") @@ -20,10 +20,12 @@ qt_add_executable(wiggly main.cpp wigglywidget.cpp wigglywidget.h ) + set_target_properties(wiggly PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(wiggly PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/windowflags/CMakeLists.txt b/examples/widgets/widgets/windowflags/CMakeLists.txt index 914bfd60eb..697f72fcfb 100644 --- a/examples/widgets/widgets/windowflags/CMakeLists.txt +++ b/examples/widgets/widgets/windowflags/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/windowflags") @@ -20,10 +20,12 @@ qt_add_executable(windowflags main.cpp previewwindow.cpp previewwindow.h ) + set_target_properties(windowflags PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(windowflags PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/windowcontainer/CMakeLists.txt b/examples/widgets/windowcontainer/CMakeLists.txt index b4f948311f..5af9687b13 100644 --- a/examples/widgets/windowcontainer/CMakeLists.txt +++ b/examples/widgets/windowcontainer/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/windowcontainer") @@ -19,10 +19,12 @@ qt_add_executable(windowcontainer ../../opengl/openglwindow/openglwindow.cpp ../../opengl/openglwindow/openglwindow.h windowcontainer.cpp ) + set_target_properties(windowcontainer PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(windowcontainer PUBLIC ../../opengl/openglwindow ) diff --git a/examples/xml/dombookmarks/CMakeLists.txt b/examples/xml/dombookmarks/CMakeLists.txt index 0bac0afe66..7659cbb019 100644 --- a/examples/xml/dombookmarks/CMakeLists.txt +++ b/examples/xml/dombookmarks/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/xml/dombookmarks") @@ -20,10 +20,12 @@ qt_add_executable(dombookmarks mainwindow.cpp mainwindow.h xbeltree.cpp xbeltree.h ) + set_target_properties(dombookmarks PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(dombookmarks PUBLIC Qt::Core Qt::Gui diff --git a/examples/xml/htmlinfo/CMakeLists.txt b/examples/xml/htmlinfo/CMakeLists.txt index 55b1af2105..d07443c2cc 100644 --- a/examples/xml/htmlinfo/CMakeLists.txt +++ b/examples/xml/htmlinfo/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/xml/htmlinfo") @@ -18,15 +18,16 @@ find_package(Qt6 REQUIRED COMPONENTS Core) qt_add_executable(htmlinfo main.cpp ) + set_target_properties(htmlinfo PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE FALSE ) + target_link_libraries(htmlinfo PUBLIC Qt::Core ) - # Resources: set(resources_resource_files "apache_org.html" diff --git a/examples/xml/rsslisting/CMakeLists.txt b/examples/xml/rsslisting/CMakeLists.txt index b2ea3e342c..540baa6693 100644 --- a/examples/xml/rsslisting/CMakeLists.txt +++ b/examples/xml/rsslisting/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/xml/rsslisting") @@ -19,10 +19,12 @@ qt_add_executable(rsslisting main.cpp rsslisting.cpp rsslisting.h ) + set_target_properties(rsslisting PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(rsslisting PUBLIC Qt::Core Qt::Gui diff --git a/examples/xml/streambookmarks/CMakeLists.txt b/examples/xml/streambookmarks/CMakeLists.txt index 0b5f7b9f59..acf0176cd5 100644 --- a/examples/xml/streambookmarks/CMakeLists.txt +++ b/examples/xml/streambookmarks/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/xml/streambookmarks") @@ -21,10 +21,12 @@ qt_add_executable(streambookmarks xbelreader.cpp xbelreader.h xbelwriter.cpp xbelwriter.h ) + set_target_properties(streambookmarks PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(streambookmarks PUBLIC Qt::Core Qt::Gui diff --git a/examples/xml/xmlstreamlint/CMakeLists.txt b/examples/xml/xmlstreamlint/CMakeLists.txt index cda75d9f06..d839a5fb1d 100644 --- a/examples/xml/xmlstreamlint/CMakeLists.txt +++ b/examples/xml/xmlstreamlint/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/xml/xmlstreamlint") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Xml) qt_add_executable(xmlstreamlint main.cpp ) + set_target_properties(xmlstreamlint PROPERTIES WIN32_EXECUTABLE FALSE MACOSX_BUNDLE FALSE ) + target_link_libraries(xmlstreamlint PUBLIC Qt::Core Qt::Xml -- cgit v1.2.3