summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorTor Arne Vestbø <tor.arne.vestbo@digia.com>2013-06-06 13:48:36 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-06-12 12:35:02 +0200
commit5c8aa27111fd51c8dff78fd0a276648aea08d4c1 (patch)
tree07edb235ab9c733f8f20490b01289a53f804d374 /tools
parente99fc91c585d5a5a6ec9e9196874f18b69254a5a (diff)
iOS: Remove need for separate qtiosmain library
We can combine the hybrid and non-hybrid use-cases into a single static library if we are careful about which symbols are included in which object files. By limiting the main() and qt_user_main() functions to their own translation units, the linker will only pick them up if they are missing at link time (the user's program do not provide them). This technique is resilient to the -ObjC linker flag, which includes all object files that implement an ObjectiveC class or category, but will fail if the -all_load flag is passed to the linker, as we'll then have duplicate symbols for either main() or qt_user_main(). The latter should not happen unless the user provides the flag manually, and in the case he or she does, there's ways to work around it by providing less global flags such as -ObjC or -force_load. Change-Id: Ie2f8e10a7265d007bf45cb1dd83f19cff0693551 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
Diffstat (limited to 'tools')
0 files changed, 0 insertions, 0 deletions