Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. How to build qtmultimedia for OS X

How to build qtmultimedia for OS X

Scheduled Pinned Locked Moved General and Desktop
7 Posts 4 Posters 2.5k Views 1 Watching
  • 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.
  • R Offline
    R Offline
    realrunner
    wrote on last edited by
    #1

    I've been unable to get qtmultimedia to build for OS X. This is what I tried:

    • cloned the git repository (git://gitorious.org/qt/qtmultimedia.git),
    • qmake -spec macx-clang ../qtmultimedia/qtmultimedia.pro
    • make

    It seems to compile the c/c++ code just fine but chokes on the objective c code. I get several errors. Some examples:
    @
    /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include/objc/NSObject.h:11:1: error: expected
    unqualified-id
    @class NSString, NSMethodSignature, NSInvocation;
    ^

    /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:377:43: error:
    unknown type name 'NSString'; did you mean 'QString'?
    FOUNDATION_EXPORT Class NSClassFromString(NSString *aClassName);@

    It appears to be trying to compile the objective c code as c++. What am I doing wrong? Any help?

    1 Reply Last reply
    0
    • sierdzioS Offline
      sierdzioS Offline
      sierdzio
      Moderators
      wrote on last edited by
      #2

      Qt Multimedia is part of Qt 5, you do not need to compile it separately. Which version of Qt are you using?

      (Z(:^

      1 Reply Last reply
      0
      • R Offline
        R Offline
        realrunner
        wrote on last edited by
        #3

        I'm using Qt 5.3.

        It is included and working fine but the AVFoundation plugin backend is severely lacking in some areas. My project requires a couple enhancements to the camera capture code so I am going to make those enhancements and submit patches back to the maintainers.

        I've already made these enhancements to the Windows (DirectShow) back end and it works great...just need to figure out how to get it to compile on OS X now.

        1 Reply Last reply
        0
        • sierdzioS Offline
          sierdzioS Offline
          sierdzio
          Moderators
          wrote on last edited by
          #4

          Ah, ok. It might be that you need some other modules present (definitely QtCore, so qtbase repo, plus probably QtGui). But if you compiled it on Windows successfully, then you probably know the drill.

          I suggest asking on development mailing list, or the IRC. Those are the 2 places where developers of Qt reside.

          (Z(:^

          1 Reply Last reply
          0
          • SGaistS Offline
            SGaistS Offline
            SGaist
            Lifetime Qt Champion
            wrote on last edited by
            #5

            Hi,

            Since you are adding new functionality, you should first checkout the dev branch

            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
            • ylopesY Offline
              ylopesY Offline
              ylopes
              wrote on last edited by
              #6

              Try building all of Qt5, you can find instructions there: http://qt-project.org/wiki/Building_Qt_5_from_Git

              You can skip QtWebkit with the option --no-webkit when running the init-repository script. You don't need it and it takes a while to build...

              As mentioned, if you plan to submit new features, you need to do it on the dev branch. You can find some instructions and guidelines there: http://qt-project.org/wiki/Qt-Contribution-Guidelines

              1 Reply Last reply
              0
              • R Offline
                R Offline
                realrunner
                wrote on last edited by
                #7

                I was being stupid. I added a file in the AVFoundation plugin with .cpp extension that also imported objective c headers. duh.

                After renaming it to .mm it compiles just fine.

                I've checked out the dev branch, read the contribution guidelines and will be submitting a patch for review shortly.

                Thanks!

                1 Reply Last reply
                0

                • Login

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