[Development] allow Qt for iOS to be built as shared libraries

Petroules Jake Jake.Petroules at theqtcompany.com
Mon Dec 28 00:18:48 CET 2015


On Dec 27, 2015, at 2:56 PM, Mike Krus <mike.krus at kdab.com<mailto:mike.krus at kdab.com>> wrote:

Hi

has anybody taken this any further?

Just pushed a new patch set which should be mergeable now pending no further complaints.

Enabling dynamic builds as frameworks causes link errors. For example, when linking QtNetwork.framework for the simulator, I get:
ld: warning: ignoring file /.../qt5_ios/qtbase/lib/QtCore.framework/QtCore, missing required architecture i386 in file /.../qt5_ios/qtbase/lib/QtCore.framework/QtCore (2 slices)

This is because QtCore.framework/QtCore is a device build (armv7 arm64). However, QtCore.framework/QtCore_iphonesimulator does exist but ld does not know to use it at that point.

Tried restricting the build to one platform only, restricting sdk to iphoneos works, but not iphonesimulator:
Project ERROR: iOS simulator is handled automatically for iphonesimulator_and_iphoneos

At this point, only -sdk iphoneos will work, yes.

May need to do separate device and simulator builds or at least build into separate bundles (at the cost of duplicating headers).
Thought we could use lipo to build a fat binary but I believe that functionality has been removed from qt’s build system.
(plus the SDKs aren’t the same so I’m not sure it can be made to work anyway)

iOS and iOS Simulator are two different platforms on the Apple side. They should NOT be lipo'ed together and the fact that we've been trying to pretend they are one platform adds a ton of complexity of the build system. It should have never been done this way.

It may not even be worth fixing until Qbs is Qt's build system.

Other options? things I missed?


Mike

On 13 Sep 2015, at 22:28, Jake Petroules <jake.petroules at petroules.com<mailto:jake.petroules at petroules.com>> wrote:


On Sep 13, 2015, at 4:26 AM, Robin Lobel <divide at divideconcept.net<mailto:divide at divideconcept.net>> wrote:

Hi Jake,

Do you have any update on this ?
https://codereview.qt-project.org/#/c/123023/

I agree It'd be great to have such option starting with iOS 8.

thanks
Robin Lobel

Yes, I'm going to do some more testing on this today.
--
Jake Petroules - jake.petroules at petroules.com<http://petroules.com>

_______________________________________________
Development mailing list
Development at qt-project.org<mailto:Development at qt-project.org>
http://lists.qt-project.org/mailman/listinfo/development

--
Mike Krus | mike.krus at kdab.com<mailto:mike.krus at kdab.com> | Senior Software Engineer
KDAB (UK) Ltd., a KDAB Group company
Tel: UK Office +44 1625 809908   Mobile +44 7833 491941
KDAB - The Qt Experts


--
Jake Petroules - jake.petroules at theqtcompany.com<mailto:jake.petroules at theqtcompany.com>
Consulting Services Engineer - The Qt Company

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/development/attachments/20151227/6f8c9195/attachment.html>


More information about the Development mailing list