Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. Qt build from source failing on OS X 10.10 for iOS

Qt build from source failing on OS X 10.10 for iOS

Scheduled Pinned Locked Moved Installation and Deployment
iosyosemitebuild from sour
3 Posts 2 Posters 1.9k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • G Offline
    G Offline
    Gints
    wrote on 22 Sept 2015, 17:51 last edited by
    #1

    Hi,

    I'm having trouble building Qt5.5 from source on OS X 10.10 for iOS. Downloading the prebuilt Mac package from http://www.qt.io/download-open-source/#section-2 works fine, at least with the included QtCreator I can write/deploy/run iOS apps just fine, even debugging seems to be working, except for stepping into Qt functions and below - that does not have/find the source code, as expected probably, so I'm stuck with assembly there. However, I really need to be able to debug inside Qt source too, so I thought I'd build a debug version from source, which I also got from http://www.qt.io/download-open-source/#section-2 .

    After failing a couple of times (I did not think I was going to be posting this, so I haven't kept the exact error messages, but there were various failures during configure/make, depending on what exactly I did) and googling around, I realised this was probably because I just got the Mac, installed the latest Xcode 7, and with it SDK 10.11, which is probably new enough to be untested and probably not expected to work. So I downgraded to Xcode 6.4 with which come:

    $ xcodebuild -showsdks
    OS X SDKs:
       	OS X 10.9                     	-sdk macosx10.9
        OS X 10.10                    	-sdk macosx10.10
    iOS SDKs:
        iOS 8.4                       	-sdk iphoneos8.4
    

    Then I did:

    $ ./../qt-5.5.0/configure -prefix ~/Tests/qt-src/qt-5.5.0-iphoneos8.4-xcode6.4-macosx10.10-macx-ios-clang-debug-bin -debug -platform macx-clang -xplatform macx-ios-clang -nomake tests -nomake examples -opensource -confirm-license -no-framework -sdk iphoneos8.4
    

    ... which worked.

    After that:

    $ make
    

    ... which worked, although I did see many warnings of this pattern:

    /Users/gints/Tests/qt-src/qt-5.5.0/qtbase/include/QtCore/../../src/corelib/kernel/qcoreapplication.h:72:5: warning: unknown warning group '-Winconsistent-missing-override', ignored [-Wunknown-pragmas]
        Q_OBJECT
    /Users/gints/Tests/qt-src/qt-5.5.0/qtbase/include/QtCore/../../src/corelib/kernel/qobjectdefs.h:156:5: note: expanded from macro 'Q_OBJECT'
        Q_OBJECT_NO_OVERRIDE_WARNING \
    /Users/gints/Tests/qt-src/qt-5.5.0/qtbase/include/QtCore/../../src/corelib/kernel/qobjectdefs.h:146:45: note: expanded from macro 'Q_OBJECT_NO_OVERRIDE_WARNING'
    #  define Q_OBJECT_NO_OVERRIDE_WARNING      QT_WARNING_DISABLE_CLANG("-Winconsistent-missing-override")
    /Users/gints/Tests/qt-src/qt-5.5.0/qtbase/include/QtCore/../../src/corelib/global/qcompilerdetection.h:1125:49: note: expanded from macro 'QT_WARNING_DISABLE_CLANG'
    #  define QT_WARNING_DISABLE_CLANG(text)        QT_DO_PRAGMA(clang diagnostic ignored text)
    /Users/gints/Tests/qt-src/qt-5.5.0/qtbase/include/QtCore/../../src/corelib/global/qcompilerdetection.h:1096:49: note: expanded from macro 'QT_DO_PRAGMA'
    #  define QT_DO_PRAGMA(text)                      _Pragma(#text)
    <scratch space>:23:27: note: expanded from here
     clang diagnostic ignored "-Winconsistent-missing-override"
    

    And finally, I did:

    $ make install
    

    ... which, after working for a while, failed with:

    Undefined symbols for architecture armv7:
      "qt_static_plugin_QDDSPlugin()", referenced from:
      StaticQDDSPluginPluginInstance::StaticQDDSPluginPluginInstance() in qml_plugin_import.o
      "qt_static_plugin_QJp2Plugin()", referenced from:
      StaticQJp2PluginPluginInstance::StaticQJp2PluginPluginInstance() in qml_plugin_import.o
      "qt_static_plugin_QMngPlugin()", referenced from:
      StaticQMngPluginPluginInstance::StaticQMngPluginPluginInstance() in qml_plugin_import.o
      "qt_static_plugin_QTgaPlugin()", referenced from:
      StaticQTgaPluginPluginInstance::StaticQTgaPluginPluginInstance() in qml_plugin_import.o
      "qt_static_plugin_QICNSPlugin()", referenced from:
      StaticQICNSPluginPluginInstance::StaticQICNSPluginPluginInstance() in qml_plugin_import.o
      "qt_static_plugin_QTiffPlugin()", referenced from:
      StaticQTiffPluginPluginInstance::StaticQTiffPluginPluginInstance() in qml_plugin_import.o
      "qt_static_plugin_QWbmpPlugin()", referenced from:
      StaticQWbmpPluginPluginInstance::StaticQWbmpPluginPluginInstance() in qml_plugin_import.o
    ld: symbol(s) not found for architecture armv7
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    
    ** INSTALL FAILED **
    
    The following build commands failed:
    	Ld .obj/qml.build/Debug-iphoneos/qml.build/Objects-normal/armv7/qml normal armv7
    (1 failure)
    make[4]: *** [iphoneos-debug-install] Error 65
    make[3]: *** [iphoneos-install] Error 2
    make[2]: *** [sub-qml-install_subtargets] Error 2
    make[1]: *** [sub-tools-install_subtargets] Error 2
    make: *** [module-qtdeclarative-install_subtargets] Error 2
    

    Does anybody have any ideas on what's going wrong or suggestions on what to try next? Maybe an Xcode / SDK combo that has worked for you before, that I should try? Different version of the source?

    Thanks,
    Gints

    1 Reply Last reply
    0
    • S Offline
      S Offline
      SGaist
      Lifetime Qt Champion
      wrote on 22 Sept 2015, 19:22 last edited by
      #2

      Hi and welcome to devnet,

      The warning flood has been fixed for 5.5.1 you should rather try that version

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • G Offline
        G Offline
        Gints
        wrote on 23 Sept 2015, 10:05 last edited by
        #3

        Thanks. I haven't tried 5.5.1 yet, but my build ended up succeeding after I rebooted my Mac (maybe something needed to be reloaded after all the Xcode / SDK changing I did) and removed the -no-framework config option (it was probably not intended for iOS, I think I only included it after seeing some message for the OS X build, and it forgot about it for iOS). I still don't know what the original problem was, but maybe this will be useful for someone.

        1 Reply Last reply
        0

        3/3

        23 Sept 2015, 10:05

        • Login

        • Login or register to search.
        3 out of 3
        • First post
          3/3
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved