diff options
author | Jean-Michaël Celerier <jean-michael.celerier@kdab.com> | 2019-07-05 11:55:05 +0200 |
---|---|---|
committer | Jean-Michaël Celerier <jean-michael.celerier@kdab.com> | 2019-07-05 14:58:52 +0000 |
commit | a5b78a3660d9b92d12c950eddb4cb3ccc43893b1 (patch) | |
tree | 019e58a9aadc37ea5dc4afcc40fa98a2a73dca9b /src | |
parent | 5769e1a2f6016cf807d20e09083b893f0c628d07 (diff) |
cmake: implement default qpa plugin behavior for static builds
This is done by adding a DEFAULT_IF argument to add_qt_plugin, which accepts
if-evaluated expressions.
e.g.
add_qt_plugin(myplugin
DEFAULT_IF ${foo} STREQUAL ${bar}
...
)
so that this mechanism can be reused later if necessary.
Change-Id: I7eba9adaaa28e55a4f0f94cf206e868b990027e6
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'src')
-rw-r--r-- | src/plugins/platforms/android/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/plugins/platforms/cocoa/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/plugins/platforms/eglfs/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/plugins/platforms/linuxfb/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/plugins/platforms/minimal/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/plugins/platforms/minimalegl/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/plugins/platforms/offscreen/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/plugins/platforms/vnc/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/plugins/platforms/windows/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/plugins/platforms/xcb/CMakeLists.txt | 1 |
10 files changed, 10 insertions, 0 deletions
diff --git a/src/plugins/platforms/android/CMakeLists.txt b/src/plugins/platforms/android/CMakeLists.txt index 5b91a733f1..f0da443481 100644 --- a/src/plugins/platforms/android/CMakeLists.txt +++ b/src/plugins/platforms/android/CMakeLists.txt @@ -6,6 +6,7 @@ add_qt_plugin(qtforandroid TYPE platforms + DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES android # special case SOURCES androidcontentfileengine.cpp androidcontentfileengine.h androiddeadlockprotector.cpp androiddeadlockprotector.h diff --git a/src/plugins/platforms/cocoa/CMakeLists.txt b/src/plugins/platforms/cocoa/CMakeLists.txt index 61b7c367af..9b546990ba 100644 --- a/src/plugins/platforms/cocoa/CMakeLists.txt +++ b/src/plugins/platforms/cocoa/CMakeLists.txt @@ -9,6 +9,7 @@ qt_find_package(Cups PROVIDED_TARGETS Cups::Cups) add_qt_plugin(qcocoa TYPE platforms + DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES cocoa # special case CLASS_NAME QCocoaIntegrationPlugin SOURCES main.mm diff --git a/src/plugins/platforms/eglfs/CMakeLists.txt b/src/plugins/platforms/eglfs/CMakeLists.txt index d7ca11acb6..6705e40e0d 100644 --- a/src/plugins/platforms/eglfs/CMakeLists.txt +++ b/src/plugins/platforms/eglfs/CMakeLists.txt @@ -80,6 +80,7 @@ extend_target(EglFSDeviceIntegration CONDITION QT_FEATURE_opengl add_qt_plugin(qeglfs TYPE platforms CLASS_NAME QEglFSIntegrationPlugin + DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES eglfs # special case SOURCES qeglfsmain.cpp DEFINES diff --git a/src/plugins/platforms/linuxfb/CMakeLists.txt b/src/plugins/platforms/linuxfb/CMakeLists.txt index 623a5296c9..463c66989f 100644 --- a/src/plugins/platforms/linuxfb/CMakeLists.txt +++ b/src/plugins/platforms/linuxfb/CMakeLists.txt @@ -7,6 +7,7 @@ add_qt_plugin(qlinuxfb TYPE platforms CLASS_NAME QLinuxFbIntegrationPlugin + DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES linuxfb # special case SOURCES main.cpp qlinuxfbintegration.cpp qlinuxfbintegration.h diff --git a/src/plugins/platforms/minimal/CMakeLists.txt b/src/plugins/platforms/minimal/CMakeLists.txt index 7f5ff13b27..6a2bda464d 100644 --- a/src/plugins/platforms/minimal/CMakeLists.txt +++ b/src/plugins/platforms/minimal/CMakeLists.txt @@ -7,6 +7,7 @@ add_qt_plugin(qminimal TYPE platforms CLASS_NAME QMinimalIntegrationPlugin + DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES minimal # special case SOURCES main.cpp qminimalbackingstore.cpp qminimalbackingstore.h diff --git a/src/plugins/platforms/minimalegl/CMakeLists.txt b/src/plugins/platforms/minimalegl/CMakeLists.txt index 8118bef4c5..a37b4f9a25 100644 --- a/src/plugins/platforms/minimalegl/CMakeLists.txt +++ b/src/plugins/platforms/minimalegl/CMakeLists.txt @@ -7,6 +7,7 @@ add_qt_plugin(qminimalegl TYPE platforms CLASS_NAME QMinimalEglIntegrationPlugin + DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES minimalegl # special case SOURCES main.cpp qminimaleglintegration.cpp qminimaleglintegration.h diff --git a/src/plugins/platforms/offscreen/CMakeLists.txt b/src/plugins/platforms/offscreen/CMakeLists.txt index a81b3b434f..98fa916445 100644 --- a/src/plugins/platforms/offscreen/CMakeLists.txt +++ b/src/plugins/platforms/offscreen/CMakeLists.txt @@ -7,6 +7,7 @@ add_qt_plugin(qoffscreen TYPE platforms CLASS_NAME QOffscreenIntegrationPlugin + DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES offscreen # special case SOURCES main.cpp qoffscreencommon.cpp qoffscreencommon.h diff --git a/src/plugins/platforms/vnc/CMakeLists.txt b/src/plugins/platforms/vnc/CMakeLists.txt index 8a294a09fb..cdb2be39d8 100644 --- a/src/plugins/platforms/vnc/CMakeLists.txt +++ b/src/plugins/platforms/vnc/CMakeLists.txt @@ -7,6 +7,7 @@ add_qt_plugin(qvnc TYPE platforms CLASS_NAME QVncIntegrationPlugin + DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES vnc # special case SOURCES main.cpp qvnc.cpp qvnc_p.h diff --git a/src/plugins/platforms/windows/CMakeLists.txt b/src/plugins/platforms/windows/CMakeLists.txt index 44a1698994..f4989649e2 100644 --- a/src/plugins/platforms/windows/CMakeLists.txt +++ b/src/plugins/platforms/windows/CMakeLists.txt @@ -7,6 +7,7 @@ add_qt_plugin(qwindows TYPE platforms CLASS_NAME QWindowsIntegrationPlugin + DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES windows # special case SOURCES main.cpp qtwindowsglobal.h diff --git a/src/plugins/platforms/xcb/CMakeLists.txt b/src/plugins/platforms/xcb/CMakeLists.txt index 6849c75e2e..92c0a842ad 100644 --- a/src/plugins/platforms/xcb/CMakeLists.txt +++ b/src/plugins/platforms/xcb/CMakeLists.txt @@ -190,6 +190,7 @@ extend_target(XcbQpa CONDITION QT_FEATURE_fontconfig AND QT_FEATURE_xcb_native_p add_qt_plugin(qxcb TYPE platforms CLASS_NAME QXcbIntegrationPlugin + DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES xcb # special case SOURCES qxcbmain.cpp DEFINES |