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. Compilation with QT5.0 and Mac Os 10.8

Compilation with QT5.0 and Mac Os 10.8

Scheduled Pinned Locked Moved General and Desktop
4 Posts 3 Posters 3.1k 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.
  • C Offline
    C Offline
    csluikidikilest
    wrote on last edited by
    #1

    Hello all,

    I am writing an application with QT5 and Windows and this morning I am trying to build this application for Mac Os 10.8 but I am taking an error :

    /Users/csluikidikilest/Qt5.0.0/5.0.0/clang_64/include/QtCore/qisenum.h:53: erreur : token is not a valid binary operator in a preprocessor subexpression

    if __has_extension(is_enum)

        ~~~~~~~~~~~~~~~^
    

    I try to research google with error code and the file name (qisenum.h), I found some solution to update this file, but it is all ready up to date.

    Does someone found a solution to resolve this problem ?

    1 Reply Last reply
    0
    • C Offline
      C Offline
      ChrisW67
      wrote on last edited by
      #2

      I think the answer lies in the age of the clang version:
      http://comments.gmane.org/gmane.comp.lib.qt.user/4899

      1 Reply Last reply
      0
      • B Offline
        B Offline
        b4silio
        wrote on last edited by
        #3

        I have a similar error, although mine reads:

        @/Users/xxx/Qt5.2.0/5.2.0-beta1/clang_64/lib/QtGui.framework/Versions/5/Headers/qimage.h:52:24: error: token is not a valid binary operator in a preprocessor subexpression
        #if QT_DEPRECATED_SINCE(5, 0)
        ~~~~~~~~~~~~~~~~~~~^@

        This with the following version of clang
        @Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
        Target: x86_64-apple-darwin12.5.0
        Thread model: posix@

        I am using Qt Creator (not XCode) and I tried with Qt 5.0.1, Qt 5.0.2, Qt 5.1.1, Qt 5.2.0-beta1, obtaining the very same error each time.

        Is this still too outdated? I don't seem to be able to update to a newer version (using the xcode 5.0.1 "command-line tools" on Mountain Lion), should I try to recompile my own version of clang from source?

        Currently the only workable option to use Qt 5 i've found is to use GCC 4.2.

        1 Reply Last reply
        0
        • B Offline
          B Offline
          b4silio
          wrote on last edited by
          #4

          Solved it myself:

          I had a manually-compiled version of qt (4.8.3) that had installed links to its header folders in /usr/local/include. As I was manually including (INCLUDEPATH) within my .pro file, it was looking there instead of the proper Qt 5.x folders.

          Solved by removing the links in /usr/local/include. It now works perfectly!

          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