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. Moc_ ...problem

Moc_ ...problem

Scheduled Pinned Locked Moved General and Desktop
14 Posts 6 Posters 5.0k 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.
  • D Offline
    D Offline
    drFox
    wrote on last edited by
    #3

    yes...

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

      Hi,

      Could you post a more complete error log ? From this it's not easy at all to see the problem, there should be more lines above that says what caused the error.

      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
      • D Offline
        D Offline
        drFox
        wrote on last edited by
        #5

        1:50:53: Running steps for project QtNIFallDetection...
        21:50:53: Configuration unchanged, skipping qmake step.
        21:50:53: Starting: "/usr/bin/make"
        /home/alessio/Qt5.0.2/5.0.2/gcc_64/bin/moc -DQT_QML_DEBUG -DQT_DECLARATIVE_DEBUG -DQT_WIDGETS_LIB -DQT_XML_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I../Qt5.0.2/5.0.2/gcc_64/mkspecs/linux-g++-64 -I../QtNIFallDetection -I/usr/include/ni -I../Qt5.0.2/5.0.2/gcc_64/include -I../Qt5.0.2/5.0.2/gcc_64/include/QtWidgets -I../Qt5.0.2/5.0.2/gcc_64/include/QtXml -I../Qt5.0.2/5.0.2/gcc_64/include/QtGui -I../Qt5.0.2/5.0.2/gcc_64/include/QtCore -I. -I. -I. ../QtNIFallDetection/qtnifalldetection.h -o moc_qtnifalldetection.cpp
        /usr/include/ni/XnCppWrapper.h:10019: Error: Macro argument mismatch.
        make: *** [moc_qtnifalldetection.cpp] Error 1
        21:50:53: The process "/usr/bin/make" exited with code 2.
        Error while building/deploying project QtNIFallDetection (kit: Desktop Qt 5.0.2 GCC 64bit)
        When executing step 'Make'
        21:50:53: Elapsed time: 00:00.


        Thanks for the help

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

          There seems to be a collision between a macro in XnCppWrapper.h and a Qt macro.

          Have a look in XnCppWrapper, search for a macro/function name (i.e signal, slot etc...) that could also be found in Qt.

          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
          • D Offline
            D Offline
            dtmoodie
            wrote on last edited by
            #7

            Hi,
            Was this ever solved? I'm struggling with the same issue.

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

              Hi,

              Good question, what you can try to do is add:

              @ CONFIG += no_keywords@

              to your pro file and use Q_SIGNAL, Q_SLOT, Q_EMIT etc... in your code (you can learn more in the "Signals & Slots" documentation chapter

              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
              • jiapei100J Offline
                jiapei100J Offline
                jiapei100
                wrote on last edited by
                #9

                I've got exactly the same problem here on my computer...
                @/usr/include/ni/XnCppWrapper.h:10019: Error: Macro argument mismatch.@

                Welcome to Longer Vision
                https://www.longervision.com

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

                  Did you try what I suggested ?

                  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
                  • jiapei100J Offline
                    jiapei100J Offline
                    jiapei100
                    wrote on last edited by
                    #11

                    Hi, SGaist:

                    Thank you for your prompt reply. I investigated the line 10019 of file /usr/include/ni/XnCppWrapper.h , it is @XN_VALIDATE_NEW(pTrans, StateChangedCallbackTranslator, handler, pCookie);@ I really can't tell

                    which Marco in OpenNI-1.5.4 conflicts with Qt-5.0.1?

                    If it is a Macro conflict issue, hHow to solve this kind of Macro conflict problem? I remember in my code, if there is such Macro conflict, the compiler will* take the one defined later without error message*.

                    Well, anyway, I'm still trying your
                    @ CONFIG += no_keywords@, but this will take some time. I've got a big project here....

                    Anyway, thank you so much...

                    Cheers
                    Pei

                    [quote author="SGaist" date="1375794678"]Did you try what I suggested ?[/quote]

                    Welcome to Longer Vision
                    https://www.longervision.com

                    1 Reply Last reply
                    0
                    • jiapei100J Offline
                      jiapei100J Offline
                      jiapei100
                      wrote on last edited by
                      #12

                      Hi, SGaist:

                      I've already tested your suggested method, but unfortunately, your suggestion doesn't solve my problem for the time being. What I can ascertain is: all the QT keywords in my former project have all being replace by Q_SIGNAL, Q_SLOT, Q_EMIT ...

                      Question is still:
                      /usr/include/ni/XnCppWrapper.h:10019: Error: Macro argument mismatch.
                      make: *** [../Output/mocs/moc_mainwindow.cpp] Error 1

                      [quote author="SGaist" date="1375794678"]Did you try what I suggested ?[/quote]

                      Welcome to Longer Vision
                      https://www.longervision.com

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

                        Are you using OpenNI ? If so I've stumbled upon "this":http://code.google.com/p/qtkinectwrapper/ that might help

                        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
                        • T Offline
                          T Offline
                          tiagocc0
                          wrote on last edited by
                          #14

                          Like I have posted here: http://qt-project.org/forums/viewthread/27125/#151289

                          The issue is with the moc.exe file, in Qt 5.2 beta they have changed it from error to warning, so now you can compile.
                          You can either upgrade to 5.2 or you can just get the moc.exe file and put it in the 5.1.1 bin folder like I did, it works.

                          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