2022-07-05 12:02:29 +00:00
|
|
|
# Copyright (C) 2022 The Qt Company Ltd.
|
2024-03-07 14:22:17 +00:00
|
|
|
# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
|
2022-07-05 12:02:29 +00:00
|
|
|
|
2021-02-15 05:34:46 +00:00
|
|
|
qt_internal_add_example(quick-accessibility)
|
|
|
|
qt_internal_add_example(animation)
|
|
|
|
qt_internal_add_example(draganddrop)
|
|
|
|
qt_internal_add_example(canvas)
|
2025-09-05 09:42:24 +00:00
|
|
|
if (NOT INTEGRITY AND NOT VXWORKS)
|
|
|
|
qt_internal_add_example(flexboxlayout)
|
|
|
|
endif()
|
2021-02-15 05:34:46 +00:00
|
|
|
qt_internal_add_example(imageelements)
|
|
|
|
qt_internal_add_example(keyinteraction)
|
|
|
|
qt_internal_add_example(layouts)
|
2023-01-25 10:01:20 +00:00
|
|
|
qt_internal_add_example(responsivelayouts)
|
2021-12-14 16:43:57 +00:00
|
|
|
qt_internal_add_example(localstorage)
|
2019-08-22 09:45:45 +00:00
|
|
|
add_subdirectory(models)
|
Fix top level builds where AUTOMOC_EXECUTABLE was unset on some targets
The qt_example_build_end() command tries to recursively find all build
system targets by descending into all source directories. Some sets of
examples re-use the same source directory multiple times with different
build directories, but this hides all but one of those re-used source
directories from the recursive search. This resulted in some targets
being missed, which in turn prevented qt_autogen_tools() from being
called on them. In top level builds, this meant AUTOMOC_EXECUTABLE
wasn't set, so CMake tried to verify the moc it wanted to use, which
doesn't exist for the first configure of a top level build, resulting
in a fatal error. Since we can't find all targets reliably with a
recursive search, manually handle the ones that could be missed.
There was a similar problem with qt_autogen_tools() not being called
for a target created to compile a doc snippet. The error message is
the same as the case above, the cause is again AUTOMOC_EXECUTABLE
not being set, but for a different reason. Apply the same fix and
call it manually, which should have been the case originally.
Fixes: QTBUG-96118
Fixes: QTBUG-96159
Pick-to: 6.2
Change-Id: I079c696cf74f77d7caa2c59e6263d3fb1c55d20e
Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-09-02 10:34:33 +00:00
|
|
|
qt_internal_add_example(views)
|
2019-08-22 09:45:45 +00:00
|
|
|
add_subdirectory(tableview)
|
2021-02-15 05:34:46 +00:00
|
|
|
qt_internal_add_example(mousearea)
|
|
|
|
qt_internal_add_example(positioners)
|
2019-08-22 09:45:45 +00:00
|
|
|
add_subdirectory(scenegraph)
|
2021-02-15 05:34:46 +00:00
|
|
|
qt_internal_add_example(shadereffects)
|
|
|
|
qt_internal_add_example(text)
|
2019-08-22 09:45:45 +00:00
|
|
|
add_subdirectory(tutorials)
|
|
|
|
add_subdirectory(customitems)
|
2021-02-15 05:34:46 +00:00
|
|
|
qt_internal_add_example(imageprovider)
|
|
|
|
qt_internal_add_example(imageresponseprovider)
|
Fix top level builds where AUTOMOC_EXECUTABLE was unset on some targets
The qt_example_build_end() command tries to recursively find all build
system targets by descending into all source directories. Some sets of
examples re-use the same source directory multiple times with different
build directories, but this hides all but one of those re-used source
directories from the recursive search. This resulted in some targets
being missed, which in turn prevented qt_autogen_tools() from being
called on them. In top level builds, this meant AUTOMOC_EXECUTABLE
wasn't set, so CMake tried to verify the moc it wanted to use, which
doesn't exist for the first configure of a top level build, resulting
in a fatal error. Since we can't find all targets reliably with a
recursive search, manually handle the ones that could be missed.
There was a similar problem with qt_autogen_tools() not being called
for a target created to compile a doc snippet. The error message is
the same as the case above, the cause is again AUTOMOC_EXECUTABLE
not being set, but for a different reason. Apply the same fix and
call it manually, which should have been the case originally.
Fixes: QTBUG-96118
Fixes: QTBUG-96159
Pick-to: 6.2
Change-Id: I079c696cf74f77d7caa2c59e6263d3fb1c55d20e
Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-09-02 10:34:33 +00:00
|
|
|
qt_internal_add_example(window)
|
2019-08-22 09:45:45 +00:00
|
|
|
add_subdirectory(particles)
|
2022-08-30 07:52:55 +00:00
|
|
|
qt_internal_add_example(itemvariablerefreshrate)
|
2022-11-11 13:39:29 +00:00
|
|
|
add_subdirectory(multieffect)
|
2019-08-22 09:45:45 +00:00
|
|
|
if(QT_FEATURE_opengl OR QT_FEATURE_opengles2 OR QT_FEATURE_opengles3)
|
|
|
|
add_subdirectory(rendercontrol)
|
|
|
|
endif()
|
2023-04-28 11:21:38 +00:00
|
|
|
if(TARGET Qt6::Widgets)
|
2021-02-15 05:34:46 +00:00
|
|
|
qt_internal_add_example(embeddedinwidgets)
|
2019-08-22 09:45:45 +00:00
|
|
|
endif()
|
2023-04-28 11:21:38 +00:00
|
|
|
if(TARGET Qt6::QuickWidgets AND TARGET Qt6::Widgets AND (QT_FEATURE_opengl OR QT_FEATURE_opengles2 OR QT_FEATURE_opengles3))
|
2019-08-22 09:45:45 +00:00
|
|
|
add_subdirectory(quickwidgets)
|
|
|
|
endif()
|
2024-01-31 15:59:02 +00:00
|
|
|
add_subdirectory(quickshapes)
|
2025-04-03 08:27:46 +00:00
|
|
|
qt_internal_add_example(advancedtext)
|
2025-09-15 12:35:35 +00:00
|
|
|
if(TARGET Qt6::Svg)
|
|
|
|
qt_internal_add_example(vectorimage)
|
|
|
|
endif()
|
Fix top level builds where AUTOMOC_EXECUTABLE was unset on some targets
The qt_example_build_end() command tries to recursively find all build
system targets by descending into all source directories. Some sets of
examples re-use the same source directory multiple times with different
build directories, but this hides all but one of those re-used source
directories from the recursive search. This resulted in some targets
being missed, which in turn prevented qt_autogen_tools() from being
called on them. In top level builds, this meant AUTOMOC_EXECUTABLE
wasn't set, so CMake tried to verify the moc it wanted to use, which
doesn't exist for the first configure of a top level build, resulting
in a fatal error. Since we can't find all targets reliably with a
recursive search, manually handle the ones that could be missed.
There was a similar problem with qt_autogen_tools() not being called
for a target created to compile a doc snippet. The error message is
the same as the case above, the cause is again AUTOMOC_EXECUTABLE
not being set, but for a different reason. Apply the same fix and
call it manually, which should have been the case originally.
Fixes: QTBUG-96118
Fixes: QTBUG-96159
Pick-to: 6.2
Change-Id: I079c696cf74f77d7caa2c59e6263d3fb1c55d20e
Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-09-02 10:34:33 +00:00
|
|
|
|
|
|
|
# qt_examples_build_end() misses at least some of these due to some
|
|
|
|
# source subdirectories being added multiple times. See QTBUG-96159.
|
|
|
|
set(reused_dir_targets
|
2021-09-07 04:31:05 +00:00
|
|
|
animation_shared
|
|
|
|
canvas_shared
|
|
|
|
views_shared
|
|
|
|
positioners_shared
|
|
|
|
text_shared
|
Fix top level builds where AUTOMOC_EXECUTABLE was unset on some targets
The qt_example_build_end() command tries to recursively find all build
system targets by descending into all source directories. Some sets of
examples re-use the same source directory multiple times with different
build directories, but this hides all but one of those re-used source
directories from the recursive search. This resulted in some targets
being missed, which in turn prevented qt_autogen_tools() from being
called on them. In top level builds, this meant AUTOMOC_EXECUTABLE
wasn't set, so CMake tried to verify the moc it wanted to use, which
doesn't exist for the first configure of a top level build, resulting
in a fatal error. Since we can't find all targets reliably with a
recursive search, manually handle the ones that could be missed.
There was a similar problem with qt_autogen_tools() not being called
for a target created to compile a doc snippet. The error message is
the same as the case above, the cause is again AUTOMOC_EXECUTABLE
not being set, but for a different reason. Apply the same fix and
call it manually, which should have been the case originally.
Fixes: QTBUG-96118
Fixes: QTBUG-96159
Pick-to: 6.2
Change-Id: I079c696cf74f77d7caa2c59e6263d3fb1c55d20e
Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-09-02 10:34:33 +00:00
|
|
|
window_shared
|
2021-09-07 07:07:43 +00:00
|
|
|
imageelements_shared
|
2021-09-06 19:40:18 +00:00
|
|
|
pointerhandlers_shared
|
2021-11-24 07:25:48 +00:00
|
|
|
affectors_shared
|
|
|
|
emitters_shared
|
|
|
|
imageparticle_shared
|
|
|
|
itemparticle_shared
|
|
|
|
system_shared
|
2021-09-06 09:25:52 +00:00
|
|
|
draganddrop_shared
|
2022-11-11 13:39:29 +00:00
|
|
|
testbed_shared
|
|
|
|
itemswitcher_shared
|
2025-02-17 10:00:53 +00:00
|
|
|
neumorphicpanel_shared
|
Fix top level builds where AUTOMOC_EXECUTABLE was unset on some targets
The qt_example_build_end() command tries to recursively find all build
system targets by descending into all source directories. Some sets of
examples re-use the same source directory multiple times with different
build directories, but this hides all but one of those re-used source
directories from the recursive search. This resulted in some targets
being missed, which in turn prevented qt_autogen_tools() from being
called on them. In top level builds, this meant AUTOMOC_EXECUTABLE
wasn't set, so CMake tried to verify the moc it wanted to use, which
doesn't exist for the first configure of a top level build, resulting
in a fatal error. Since we can't find all targets reliably with a
recursive search, manually handle the ones that could be missed.
There was a similar problem with qt_autogen_tools() not being called
for a target created to compile a doc snippet. The error message is
the same as the case above, the cause is again AUTOMOC_EXECUTABLE
not being set, but for a different reason. Apply the same fix and
call it manually, which should have been the case originally.
Fixes: QTBUG-96118
Fixes: QTBUG-96159
Pick-to: 6.2
Change-Id: I079c696cf74f77d7caa2c59e6263d3fb1c55d20e
Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-09-02 10:34:33 +00:00
|
|
|
)
|
2022-01-20 16:42:48 +00:00
|
|
|
|
Fix top level builds where AUTOMOC_EXECUTABLE was unset on some targets
The qt_example_build_end() command tries to recursively find all build
system targets by descending into all source directories. Some sets of
examples re-use the same source directory multiple times with different
build directories, but this hides all but one of those re-used source
directories from the recursive search. This resulted in some targets
being missed, which in turn prevented qt_autogen_tools() from being
called on them. In top level builds, this meant AUTOMOC_EXECUTABLE
wasn't set, so CMake tried to verify the moc it wanted to use, which
doesn't exist for the first configure of a top level build, resulting
in a fatal error. Since we can't find all targets reliably with a
recursive search, manually handle the ones that could be missed.
There was a similar problem with qt_autogen_tools() not being called
for a target created to compile a doc snippet. The error message is
the same as the case above, the cause is again AUTOMOC_EXECUTABLE
not being set, but for a different reason. Apply the same fix and
call it manually, which should have been the case originally.
Fixes: QTBUG-96118
Fixes: QTBUG-96159
Pick-to: 6.2
Change-Id: I079c696cf74f77d7caa2c59e6263d3fb1c55d20e
Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-09-02 10:34:33 +00:00
|
|
|
foreach(target IN LISTS reused_dir_targets)
|
|
|
|
if(TARGET ${target})
|
|
|
|
qt_autogen_tools(${target} ENABLE_AUTOGEN_TOOLS moc rcc)
|
2023-04-28 11:21:38 +00:00
|
|
|
if(TARGET Qt6::Widgets)
|
Fix top level builds where AUTOMOC_EXECUTABLE was unset on some targets
The qt_example_build_end() command tries to recursively find all build
system targets by descending into all source directories. Some sets of
examples re-use the same source directory multiple times with different
build directories, but this hides all but one of those re-used source
directories from the recursive search. This resulted in some targets
being missed, which in turn prevented qt_autogen_tools() from being
called on them. In top level builds, this meant AUTOMOC_EXECUTABLE
wasn't set, so CMake tried to verify the moc it wanted to use, which
doesn't exist for the first configure of a top level build, resulting
in a fatal error. Since we can't find all targets reliably with a
recursive search, manually handle the ones that could be missed.
There was a similar problem with qt_autogen_tools() not being called
for a target created to compile a doc snippet. The error message is
the same as the case above, the cause is again AUTOMOC_EXECUTABLE
not being set, but for a different reason. Apply the same fix and
call it manually, which should have been the case originally.
Fixes: QTBUG-96118
Fixes: QTBUG-96159
Pick-to: 6.2
Change-Id: I079c696cf74f77d7caa2c59e6263d3fb1c55d20e
Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-09-02 10:34:33 +00:00
|
|
|
qt_autogen_tools(${target} ENABLE_AUTOGEN_TOOLS uic)
|
|
|
|
endif()
|
|
|
|
endif()
|
|
|
|
endforeach()
|