Qt XCode iOS entry point
I am trying to connect a QT5 app to iOS. It builds and works fine with QtCreator, but now I'm trying to make a manual XCode project. The following steps are collected from other threads, here is my final path:
It builds and runs, but I got a runtime error:
Error: You are creating QApplication before calling UIApplicationMain.
I found that I have to replace main -> qtmn, but then I got an error about no entry point.
The main declaration is inside libqios.a, but I can't tell the linker to "Take main () from libqios, not from cpp files".
I tried it with
-Wl,-force_load,$(QT_SDK)/plugins/platforms/libqios.a - but it does nothing.
I found that the QT preprocessor does something with the object files (renaming main to something else), but it looks too awful. How can this be solved?
0
source to share