diff options
author | Tor Arne Vestbø <tor.arne.vestbo@qt.io> | 2020-11-09 15:42:05 +0100 |
---|---|---|
committer | Tor Arne Vestbø <tor.arne.vestbo@qt.io> | 2020-11-10 16:53:31 +0100 |
commit | 4b063c8467071e1c2d40f5fc493b7e3ec5a08520 (patch) | |
tree | 1b5f214ae39c7786e285cc78ab637e124eb8635b /mkspecs | |
parent | 6e9a0f6688bd8554321f8eff10af2c9d9db564a0 (diff) |
Move iOS entrypoint logic to entrypoint library
Change-Id: Ie0fc8368953a59d06a31847ed417bc3c35f29b90
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'mkspecs')
-rw-r--r-- | mkspecs/features/entrypoint.prf | 12 | ||||
-rw-r--r-- | mkspecs/features/uikit/default_pre.prf | 2 | ||||
-rw-r--r-- | mkspecs/features/uikit/qt.prf | 14 |
3 files changed, 12 insertions, 16 deletions
diff --git a/mkspecs/features/entrypoint.prf b/mkspecs/features/entrypoint.prf index fbe637326e..98c41161a0 100644 --- a/mkspecs/features/entrypoint.prf +++ b/mkspecs/features/entrypoint.prf @@ -1,2 +1,10 @@ -qt:!console:contains(TEMPLATE, ".*app"): \ - QT_PRIVATE += entrypoint_private +!qt: return() + +win32 { + !console:contains(TEMPLATE, ".*app"): \ + QT_PRIVATE += entrypoint_private +} else:uikit { + qt_depends = $$resolve_depends(QT, "QT.") + !watchos:equals(TEMPLATE, app):contains(qt_depends, gui(-private)?): \ + QT_PRIVATE += entrypoint_private +} diff --git a/mkspecs/features/uikit/default_pre.prf b/mkspecs/features/uikit/default_pre.prf index ea6882fbc8..bc72936520 100644 --- a/mkspecs/features/uikit/default_pre.prf +++ b/mkspecs/features/uikit/default_pre.prf @@ -16,6 +16,8 @@ $$sim_and_dev { DEFINES += QT_COMPILER_SUPPORTS_SSE2 } +CONFIG += entrypoint + unset(sim_and_dev) load(default_pre) diff --git a/mkspecs/features/uikit/qt.prf b/mkspecs/features/uikit/qt.prf deleted file mode 100644 index a1720c1535..0000000000 --- a/mkspecs/features/uikit/qt.prf +++ /dev/null @@ -1,14 +0,0 @@ - -qt_depends = $$resolve_depends(QT, "QT.") -!watchos:equals(TEMPLATE, app):contains(qt_depends, gui(-private)?) { - !no_main_wrapper { - # The LC_MAIN load command available in iOS 6.0 and above allows dyld to - # directly call the entrypoint instead of going through _start in crt.o. - # Passing -e to the linker changes the entrypoint from _main to our custom - # wrapper that calls UIApplicationMain and dispatches back to main() once - # the application has started up and is ready to initialize QApplication. - QMAKE_LFLAGS += -Wl,-e,_qt_main_wrapper - } -} - -load(qt) |