summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/ios
diff options
context:
space:
mode:
authorTor Arne Vestbø <tor.arne.vestbo@qt.io>2022-12-16 16:34:31 +0100
committerTor Arne Vestbø <tor.arne.vestbo@qt.io>2023-01-10 13:16:04 +0100
commitadb91d6afb9e25ffb180de53afff3de443696e36 (patch)
tree1a6f64c828488cd6133f1a426c2f5b632fc19c1c /src/plugins/platforms/ios
parentc0967bd288b4376e31c183438448e00065c66b75 (diff)
Enable shared library build of Qt for iOS
As of f68e2c92cc0ed2c1929140402c061359bc2363a5, and its follow up changes, we can now link individual plugins statically, even if the Qt build is generally a shared build. This allows us to build Qt for iOS as shared libraries, while still keeping the platform plugin as a static library, since this is harder to port over to a shared library. This gives the benefit of faster turnaround during development, as well as binary compatibility promises for the main Qt libraries, without having to go fully shared for all of Qt. Static builds are still the default, due to the downsides of larger application bundles and slower load times for shared builds. For now the user has to manually tick the "Embed & Sign" check box in Xcode for each Qt library, which is only available with Xcode projects generated by the qmake Xcode generator. Task-number: QTBUG-85974 Change-Id: Id2b7bd2823c8e7c79068dda95295b574ada8d7f2 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
Diffstat (limited to 'src/plugins/platforms/ios')
-rw-r--r--src/plugins/platforms/ios/CMakeLists.txt2
-rw-r--r--src/plugins/platforms/ios/optional/nsphotolibrarysupport/CMakeLists.txt1
2 files changed, 3 insertions, 0 deletions
diff --git a/src/plugins/platforms/ios/CMakeLists.txt b/src/plugins/platforms/ios/CMakeLists.txt
index 7b654af2a4..a822005b94 100644
--- a/src/plugins/platforms/ios/CMakeLists.txt
+++ b/src/plugins/platforms/ios/CMakeLists.txt
@@ -9,6 +9,7 @@
qt_internal_add_plugin(QIOSIntegrationPlugin
OUTPUT_NAME qios
+ STATIC # Force static, even in shared builds
DEFAULT_IF ${QT_QPA_DEFAULT_PLATFORM} MATCHES ios # special case
PLUGIN_TYPE platforms
SOURCES
@@ -36,6 +37,7 @@ qt_internal_add_plugin(QIOSIntegrationPlugin
${FWMetal}
${FWQuartzCore}
${FWUIKit}
+ ${FWCoreGraphics}
Qt::CorePrivate
Qt::GuiPrivate
)
diff --git a/src/plugins/platforms/ios/optional/nsphotolibrarysupport/CMakeLists.txt b/src/plugins/platforms/ios/optional/nsphotolibrarysupport/CMakeLists.txt
index 093e74c3e9..ab1e5b6c4a 100644
--- a/src/plugins/platforms/ios/optional/nsphotolibrarysupport/CMakeLists.txt
+++ b/src/plugins/platforms/ios/optional/nsphotolibrarysupport/CMakeLists.txt
@@ -9,6 +9,7 @@
qt_internal_add_plugin(QIosOptionalPlugin_NSPhotoLibraryPlugin
OUTPUT_NAME qiosnsphotolibrarysupport
+ STATIC # Force static, even in shared builds
PLUGIN_TYPE platforms/darwin
CLASS_NAME QIosOptionalPlugin_NSPhotoLibrary
DEFAULT_IF FALSE