summaryrefslogtreecommitdiffstats
path: root/examples/widgets/painting/affine/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'examples/widgets/painting/affine/CMakeLists.txt')
-rw-r--r--examples/widgets/painting/affine/CMakeLists.txt27
1 files changed, 18 insertions, 9 deletions
diff --git a/examples/widgets/painting/affine/CMakeLists.txt b/examples/widgets/painting/affine/CMakeLists.txt
index c1ee72d15b..c3323693b8 100644
--- a/examples/widgets/painting/affine/CMakeLists.txt
+++ b/examples/widgets/painting/affine/CMakeLists.txt
@@ -37,11 +37,17 @@ target_include_directories(affine PUBLIC
../shared
)
+# special case begin
+if(NOT TARGET painting_shared::painting_shared)
+ add_subdirectory(../shared painting_shared)
+endif()
+# special case end
+
target_link_libraries(affine PUBLIC
Qt::Core
Qt::Gui
Qt::Widgets
- painting_shared # special case
+ painting_shared::painting_shared # special case
)
@@ -210,15 +216,18 @@ qt6_add_resources(affine "affine"
${affine_resource_files}
)
-if(QT_FEATURE_opengl)
- target_sources(affine PUBLIC
- ../shared/fbopaintdevice.cpp ../shared/fbopaintdevice.h
- )
+# special case begin
+# remove files from ../shared
+#if(QT_FEATURE_opengl)
+ #target_sources(affine PUBLIC
+ #../shared/fbopaintdevice.cpp ../shared/fbopaintdevice.h
+ #)
- target_link_libraries(affine PUBLIC
- Qt::OpenGL
- )
-endif()
+ #target_link_libraries(affine PUBLIC
+ #Qt::OpenGL
+ #)
+#endif()
+# special case end
install(TARGETS affine
RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"