Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Makefile:412: recipe for target 'ui_mainwindow.h' failed
QtWS25 Last Chance

Makefile:412: recipe for target 'ui_mainwindow.h' failed

Scheduled Pinned Locked Moved Unsolved Qt Creator and other tools
11 Posts 3 Posters 2.0k 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.
  • M Offline
    M Offline
    Momeneh
    wrote on last edited by
    #1

    Hi,
    I tried to compile and run my code on Raspberry Pi. I used "qmake /usr/local/qt5pi/LED/" command to compile my code, after that this command done, a Makefile created. now when i use "make" command, bellow error apear :

    /usr/lib/arm-linux-gnueabihf/qt5/bin/uic mainwindow.ui -o ui_mainwindow.h
    /usr/lib/arm-linux-gnueabihf/qt5/bin/uic: relocation error: /usr/lib/arm-linux-gnueabihf/qt5/bin/uic: symbol qt_qhash_seed, version Qt_5 not defined in file libQt5Core.so.5 with link time reference
    Makefile:412: recipe for target 'ui_mainwindow.h' failed
    make: *** [ui_mainwindow.h] Error 127

    please help me!!

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

      Hi,

      What version of Qt are you using ?
      How did you install it ?

      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
      • M Offline
        M Offline
        Momeneh
        wrote on last edited by
        #3

        I used bellow link for cross compile Qt 5.11 on Raspberry Pi :
        https://wiki.qt.io/RaspberryPi2EGLFS

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

          Since you cross-compiled Qt, how did you got qmake on your Raspberry Pi ?

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

            I used "sudo apt-get install qt5-default" command to get qmake.

            jsulmJ 1 Reply Last reply
            0
            • M Momeneh

              I used "sudo apt-get install qt5-default" command to get qmake.

              jsulmJ Offline
              jsulmJ Offline
              jsulm
              Lifetime Qt Champion
              wrote on last edited by
              #6

              @Momeneh said in Makefile:412: recipe for target 'ui_mainwindow.h' failed:

              I used "sudo apt-get install qt5-default" command to get qmake.

              This qmake does NOT belong to your cross-compiled Qt but to Qt provided by Raspbian!

              https://forum.qt.io/topic/113070/qt-code-of-conduct

              M 1 Reply Last reply
              0
              • jsulmJ jsulm

                @Momeneh said in Makefile:412: recipe for target 'ui_mainwindow.h' failed:

                I used "sudo apt-get install qt5-default" command to get qmake.

                This qmake does NOT belong to your cross-compiled Qt but to Qt provided by Raspbian!

                M Offline
                M Offline
                Momeneh
                wrote on last edited by
                #7

                @jsulm
                Ok, thanks, but now i don't know what should i do?

                jsulmJ 1 Reply Last reply
                0
                • M Momeneh

                  @jsulm
                  Ok, thanks, but now i don't know what should i do?

                  jsulmJ Offline
                  jsulmJ Offline
                  jsulm
                  Lifetime Qt Champion
                  wrote on last edited by
                  #8

                  @Momeneh You should compile Qt directly on your RaspberryPi, then you will have qmake there.
                  If you cross compile then tools like qmake are built for the host machine, because they are needed there.

                  https://forum.qt.io/topic/113070/qt-code-of-conduct

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

                    In addition to @jsulm, if the Qt version provided by Raspbian (or whatever distribution you are running) is enough, just install the corresponding development packages.

                    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
                    1
                    • jsulmJ jsulm

                      @Momeneh You should compile Qt directly on your RaspberryPi, then you will have qmake there.
                      If you cross compile then tools like qmake are built for the host machine, because they are needed there.

                      M Offline
                      M Offline
                      Momeneh
                      wrote on last edited by
                      #10

                      @jsulm
                      I should connect to RaspberryPi remotely with ssh and i use wiringPi library in my code, now i want to compile and run it on RaspberryPi and i don't know how to do it without qmake command.

                      jsulmJ 1 Reply Last reply
                      0
                      • M Momeneh

                        @jsulm
                        I should connect to RaspberryPi remotely with ssh and i use wiringPi library in my code, now i want to compile and run it on RaspberryPi and i don't know how to do it without qmake command.

                        jsulmJ Offline
                        jsulmJ Offline
                        jsulm
                        Lifetime Qt Champion
                        wrote on last edited by jsulm
                        #11

                        @Momeneh

                        1. You cross compiled Qt for Raspberry Pi, right? Then you can build your app on your PC, copy the binary to your Raspberry Pi and run it there (you will need to copy cross compiled Qt libs, which are used by your app, to Raspberry Pi as well).

                        2. If you really want to build directly on Raspberry Pi, then install Qt provided by Raspbian as @SGaist said and use it, no need to build Qt by yourself.

                        You should decide first whether you want 1 or 2...

                        https://forum.qt.io/topic/113070/qt-code-of-conduct

                        1 Reply Last reply
                        1

                        • Login

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