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. setting up qt with zynq
Forum Update on Monday, May 27th 2025

setting up qt with zynq

Scheduled Pinned Locked Moved Unsolved Installation and Deployment
26 Posts 4 Posters 7.4k 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.
  • E Offline
    E Offline
    elliottal
    wrote on 15 Jan 2019, 16:11 last edited by elliottal
    #1

    Hello,

    Im working with a zynqzc702 board and trying to develop a UI. I have followed the instructions given here to build QT 5.4.2 and QWT 6.1.2. I have set up a kit where I'm using the arm-xilinx-linux-gnueabi-gcc compiler found in the Xilinx 2015.4 tools, and the Qt version (5.4.2) is pointing to the qmake file that was installed using link that I previously mentioned above. Also the qt mkspec in the kit was set to linux-arm-gnueabi-g++. Hopefully all of that makes sense.

    first question, Is that all that needs to be done for qt and qwt to work properly in qt creator? After following directions I linked to and then pointing to the qmake file will qt and qwt both work or is there something separate needed to be done for qwt?

    also I am getting an error when i try to build a project using the kit i set up. It gives me an error that says "arm-linux-gnueabi-g++: Command not found." I have the compiler set to arm-xilinx-linux-gnueabi-gcc so i'm not sure why I am seeing this error.

    Here is the kit I have setup:
    0_1547582195470_Petalinux_kit.png

    Here is the compiler I have set:
    0_1547582234134_cross_compiler.png

    Here is the error:
    0_1547582248579_qt_error.png

    any help with this would be appreciated and thanks for your time,

    elliottal

    1 Reply Last reply
    0
    • S Offline
      S Offline
      SGaist
      Lifetime Qt Champion
      wrote on 15 Jan 2019, 22:08 last edited by
      #2

      Hi,

      What about the mkspec ?
      Why no make one for your board ?

      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
      • E Offline
        E Offline
        elliottal
        wrote on 16 Jan 2019, 12:19 last edited by elliottal
        #3

        In the link I included in the first post that shows the build instructions for qt 5.4.2 and qwt 6.1.2 it has directions for adding a mkspec and those are what I followed. I added two files (qmake.conf and qplatformdefs.h) under arm-xilinx-linux-gnueabi-g++ in qtbase/mkspecs/ and this is what i followed:

        0_1547641125910_Prepare_mkspec.PNG
        Hopefully that answers your question. Thanks for the reply!

        P 1 Reply Last reply 16 Jan 2019, 13:48
        0
        • E elliottal
          16 Jan 2019, 12:19

          In the link I included in the first post that shows the build instructions for qt 5.4.2 and qwt 6.1.2 it has directions for adding a mkspec and those are what I followed. I added two files (qmake.conf and qplatformdefs.h) under arm-xilinx-linux-gnueabi-g++ in qtbase/mkspecs/ and this is what i followed:

          0_1547641125910_Prepare_mkspec.PNG
          Hopefully that answers your question. Thanks for the reply!

          P Offline
          P Offline
          Pablo J. Rogina
          wrote on 16 Jan 2019, 13:48 last edited by
          #4

          @elliottal from the error image in your first post, it looks like the compiler is not in the path...

          make: arm-linux-gnueabi-g++: Command not found

          Upvote the answer(s) that helped you solve the issue
          Use "Topic Tools" button to mark your post as Solved
          Add screenshots via postimage.org
          Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

          E 1 Reply Last reply 16 Jan 2019, 14:05
          1
          • P Pablo J. Rogina
            16 Jan 2019, 13:48

            @elliottal from the error image in your first post, it looks like the compiler is not in the path...

            make: arm-linux-gnueabi-g++: Command not found

            E Offline
            E Offline
            elliottal
            wrote on 16 Jan 2019, 14:05 last edited by
            #5

            @Pablo-J.-Rogina thanks for the reply.

            From what I understand that compiler (arm-linux-gnueabi-g++) should not even be used since I set the compiler as the arm-xilinx-linux-gnueabi-gcc as shown in the second pic of my first post. That is the cross compiler I am suppose to use per this xilinx write up, and it shows it as the second to last screenshot near the bottom of the page. Maybe I'm wrong but I'm trying to understand and figure this out.

            thanks

            P 1 Reply Last reply 16 Jan 2019, 14:10
            0
            • E elliottal
              16 Jan 2019, 14:05

              @Pablo-J.-Rogina thanks for the reply.

              From what I understand that compiler (arm-linux-gnueabi-g++) should not even be used since I set the compiler as the arm-xilinx-linux-gnueabi-gcc as shown in the second pic of my first post. That is the cross compiler I am suppose to use per this xilinx write up, and it shows it as the second to last screenshot near the bottom of the page. Maybe I'm wrong but I'm trying to understand and figure this out.

              thanks

              P Offline
              P Offline
              Pablo J. Rogina
              wrote on 16 Jan 2019, 14:10 last edited by
              #6

              @elliottal said in setting up qt with zynq:

              I set the compiler as the arm-xilinx-linux-gnueabi-gcc

              Ok, I cannot argue about that but if that's the case something is wrong in your new mkspec file since make is still calling the other compiler

              Upvote the answer(s) that helped you solve the issue
              Use "Topic Tools" button to mark your post as Solved
              Add screenshots via postimage.org
              Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

              1 Reply Last reply
              1
              • E Offline
                E Offline
                elliottal
                wrote on 16 Jan 2019, 15:01 last edited by
                #7

                I believe I see my error now and the problem is with the mkspec like you said and what SGaist was probably talking about too. I created a new mkspec and called it arm-xilinx-linux-gnueabi-g++ and added the qmake.conf and qplatformdefs.h files to that. However I referenced linux-arm-gnueabi-g++ as the mkspec for the kit i set up which was the wrong mkspec to reference so I think that answers that question.

                I changed the mkspec to be arm-xilinx-linux-gnueabi-g++ instead of linux-arm-gnueabi-g++ but now when i hit apply the mkspec input area clears itself. The screenshot below is after I type in "arm-xilinx-linux-gnueabi-g++" as the Qt mkspec and hit apply:
                I also did notice that when i hover over the qt mkspec input area it says "The mkspec to use when building the project with qmake. This setting is ignored when using other build systems." Is this why the input area just clears itself after i type in the new mkspec? 0_1547650257782_Screenshot from 2019-01-16 12-29-25.png

                I do have the mkspec set up as seen here in the file list for mkspec under qt install directory.
                0_1547650365837_Screenshot from 2019-01-16 12-30-33.png

                Should I just edit the mkspec files for the linux-arm-gnueabi-g++ mkspec instead and reference that mkspec file?

                thanks again for your help.

                1 Reply Last reply
                0
                • E Offline
                  E Offline
                  elliottal
                  wrote on 16 Jan 2019, 18:07 last edited by
                  #8

                  OK, I went ahead and changed the mkspec files associated with linux-arm-gnueabi-g++ to point to the arm-xilinx-linux-gnueabi-g++ compiler and now all seems well with that, however I'm met with another error unfortunately when trying to build a sample project which is: Unknown module(s) in QT: quick. I have researched this error and from what I have found the qtdeclarative package needs to be installed.

                  Just to be clear, I downloaded qt-opensource-opensource-src-5.4.2 from qt website which had all of the packages and I configured it to make and install all of those packages when I installed qt-5.4.2. The image below shows the contents of qt-everywhere-opensource-src-5.4.2. As you can see qtdeclarative along with other modules are a part of the file list. I ran ./configure then make and make install. This should have installed qt along with all the modules correct? 0_1547661558940_Screenshot from 2019-01-16 15-32-51.png

                  P 1 Reply Last reply 16 Jan 2019, 18:46
                  0
                  • E elliottal
                    16 Jan 2019, 18:07

                    OK, I went ahead and changed the mkspec files associated with linux-arm-gnueabi-g++ to point to the arm-xilinx-linux-gnueabi-g++ compiler and now all seems well with that, however I'm met with another error unfortunately when trying to build a sample project which is: Unknown module(s) in QT: quick. I have researched this error and from what I have found the qtdeclarative package needs to be installed.

                    Just to be clear, I downloaded qt-opensource-opensource-src-5.4.2 from qt website which had all of the packages and I configured it to make and install all of those packages when I installed qt-5.4.2. The image below shows the contents of qt-everywhere-opensource-src-5.4.2. As you can see qtdeclarative along with other modules are a part of the file list. I ran ./configure then make and make install. This should have installed qt along with all the modules correct? 0_1547661558940_Screenshot from 2019-01-16 15-32-51.png

                    P Offline
                    P Offline
                    Pablo J. Rogina
                    wrote on 16 Jan 2019, 18:46 last edited by
                    #9

                    @elliottal said in setting up qt with zynq:

                    I ran ./configure then make and make install

                    Did you pay attention to step 3.3 Configure the Target Build from the instructions you linked?

                    Within the bunch of modules skipped, it's Qt Quick (-skip qtquick1)

                    Upvote the answer(s) that helped you solve the issue
                    Use "Topic Tools" button to mark your post as Solved
                    Add screenshots via postimage.org
                    Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

                    1 Reply Last reply
                    0
                    • E Offline
                      E Offline
                      elliottal
                      wrote on 16 Jan 2019, 18:51 last edited by elliottal
                      #10

                      yes, I saw step 3.3 and everything that was skipped. I did not want to skip anything and wanted everything included so i ran ./configure without adding any "-skip".

                      My ./configure command looked like this: ./configure -xplatform arm-xilinx-linux-gnueabi-g++ -prefix $ZYNQ_QT_INSTALL. I ran make and make install after that.

                      1 Reply Last reply
                      0
                      • S Offline
                        S Offline
                        SGaist
                        Lifetime Qt Champion
                        wrote on 16 Jan 2019, 21:45 last edited by
                        #11

                        So you did build all modules ?

                        Did you check that your Kit and Qt version properly points to your newly built version of 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
                        • E Offline
                          E Offline
                          elliottal
                          wrote on 17 Jan 2019, 13:11 last edited by
                          #12

                          I am assuming that I did. I downloaded qt-everywhere-opensource-5.4.2 which appears to have all of the modules included.
                          I ran
                          ./configure -xplatform arm-xilinx-linux-gnueabi-g++ -prefix $ZYNQ_QT_INSTALL
                          then
                          make
                          then
                          make install

                          I'm assuming that all the modules were built and installed. I don't see in the documentation where it says you need to explicitly state which modules you want built but I only see where it gives options for skipping modules when building.
                          Here is where I set the Qt version. I manually pointed to the qmake in the install directory which is where i set 5.4.2 to be installed with the -prefix option when running ./configure.

                          0_1547730473437_Screenshot from 2019-01-17 10-44-41.png

                          1 Reply Last reply
                          0
                          • S Offline
                            S Offline
                            SGaist
                            Lifetime Qt Champion
                            wrote on 17 Jan 2019, 20:08 last edited by
                            #13

                            Can you build a project if you do it from the command line directly ?

                            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
                            • E Offline
                              E Offline
                              elliottal
                              wrote on 18 Jan 2019, 15:59 last edited by
                              #14

                              Ok, I believe I figured out my problem again but just to answer @SGaist question real quick, I did navigate to the examples directory and found the "clocks.pro" file and ran "qmake clocks.pro" (not sure why those highlighting in blue and displaying as a link) which produced the same error as before but I am about to explain why I think that is.

                              Im going to go through my process again just to be clear and not sure if it matters but I've been doing this on a standalone linux machine running centos 7 without a network connection.

                              I installed qt-everywhere-opensource-src-5.4.2 as I have already described. I also downloaded and installed qt-opensource-linux-x64-5.4.2.run which gave me qt creator since i didn't see it when I installed qt-everywhere-opensource-src-5.4.2. I opened qt creator and set it up as I have also already described. So I have two "versions" of qt 5.4.2 installed on my linux machine. one in the install directory and another in Qt5.4.2 directory which has the qtcreator program.

                              So my first question is does that process sound right to you or am I doing something weird and should have qt creator in my install directory already although I don't see it anywhere in there?

                              Secondly, and this is where I see my mistake regarding my last post. In the screenshot I provided below, the dropdown menu between projects and the search in examples was set to Qt 5.4.2 GCC 64bit which did show all of the example programs and I had selected one of them and then tried to configure it on my Petalinux kit which was set up to use a different qmake so I believe this is why I saw that error. I can run the example fine when using my desktop kit and don't see the unknown module error.

                              However, as can be seen in the screenshot I changed the dropdown to use the Qt 5.4.2 (install) location but now there are't any example projects displayed. Again i didn't run -nomake examples, the only options I used were the -xplatform and -prefix when I configured qt-everywhere-opensource-src-5.4.2. Should I be seeing the examples when I have Qt 5.4.2 (install) selected in the dropdown or is this normal?

                              0_1547823630167_Screenshot from 2019-01-18 12-31-28.png

                              P 1 Reply Last reply 18 Jan 2019, 16:21
                              0
                              • E elliottal
                                18 Jan 2019, 15:59

                                Ok, I believe I figured out my problem again but just to answer @SGaist question real quick, I did navigate to the examples directory and found the "clocks.pro" file and ran "qmake clocks.pro" (not sure why those highlighting in blue and displaying as a link) which produced the same error as before but I am about to explain why I think that is.

                                Im going to go through my process again just to be clear and not sure if it matters but I've been doing this on a standalone linux machine running centos 7 without a network connection.

                                I installed qt-everywhere-opensource-src-5.4.2 as I have already described. I also downloaded and installed qt-opensource-linux-x64-5.4.2.run which gave me qt creator since i didn't see it when I installed qt-everywhere-opensource-src-5.4.2. I opened qt creator and set it up as I have also already described. So I have two "versions" of qt 5.4.2 installed on my linux machine. one in the install directory and another in Qt5.4.2 directory which has the qtcreator program.

                                So my first question is does that process sound right to you or am I doing something weird and should have qt creator in my install directory already although I don't see it anywhere in there?

                                Secondly, and this is where I see my mistake regarding my last post. In the screenshot I provided below, the dropdown menu between projects and the search in examples was set to Qt 5.4.2 GCC 64bit which did show all of the example programs and I had selected one of them and then tried to configure it on my Petalinux kit which was set up to use a different qmake so I believe this is why I saw that error. I can run the example fine when using my desktop kit and don't see the unknown module error.

                                However, as can be seen in the screenshot I changed the dropdown to use the Qt 5.4.2 (install) location but now there are't any example projects displayed. Again i didn't run -nomake examples, the only options I used were the -xplatform and -prefix when I configured qt-everywhere-opensource-src-5.4.2. Should I be seeing the examples when I have Qt 5.4.2 (install) selected in the dropdown or is this normal?

                                0_1547823630167_Screenshot from 2019-01-18 12-31-28.png

                                P Offline
                                P Offline
                                Pablo J. Rogina
                                wrote on 18 Jan 2019, 16:21 last edited by
                                #15

                                @elliottal given the scenario that you describe, I think that you may want to install standalone Qt Creator

                                Upvote the answer(s) that helped you solve the issue
                                Use "Topic Tools" button to mark your post as Solved
                                Add screenshots via postimage.org
                                Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

                                1 Reply Last reply
                                1
                                • S Offline
                                  S Offline
                                  SGaist
                                  Lifetime Qt Champion
                                  wrote on 18 Jan 2019, 21:06 last edited by
                                  #16

                                  @elliottal said in setting up qt with zynq:

                                  qt-everywhere-opensource-src-5.4.2

                                  As the name suggests, it's the sources of Qt which is unrelated to installing any pre-built. But that's what you need in order to build Qt yourself.

                                  My question regarding building a project on command line implied that you would use the full path to your cross-compile Qt qmake executable. Otherwise you are likely using your distribution proved Qt.

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

                                  E 1 Reply Last reply 22 Jan 2019, 13:36
                                  1
                                  • S SGaist
                                    18 Jan 2019, 21:06

                                    @elliottal said in setting up qt with zynq:

                                    qt-everywhere-opensource-src-5.4.2

                                    As the name suggests, it's the sources of Qt which is unrelated to installing any pre-built. But that's what you need in order to build Qt yourself.

                                    My question regarding building a project on command line implied that you would use the full path to your cross-compile Qt qmake executable. Otherwise you are likely using your distribution proved Qt.

                                    E Offline
                                    E Offline
                                    elliottal
                                    wrote on 22 Jan 2019, 13:36 last edited by
                                    #17

                                    @SGaist I have already set the path variable to include the qmake from my install directory.
                                    If I type "qmake -v" in the command line then the output I get is this:

                                    QMake version 3.0
                                    Using Qt version 5.4.2 in /home/dragon/Qt/install/lib

                                    also when I type "which qmake" in the command line the output is:

                                    /home/dragon/install/bin/qmake

                                    So it appears that I am using the correct qmake according to that output.

                                    I did navigate to the examples in my install directory again and found the clocks.pro file. I ran "/home/dragon/Qt/install/qmake clocks.pro" which has given me this output:

                                    "Failure to open file: /home/dragon/Qt/install/examples/declarative/toys/clocks/Makefile
                                    unable to generate makefile for: clocks.pro"

                                    Also just to note I removed my other Qt5.4.2 directory that was installed when i ran qt-opensource-linux-x64-5.4.2.run so now the only qt I have installed is from the qt-everywhere-opensource-src-5.4.2 files which I installed to the install folder that I have already mentioned multiple times. I took @Pablo-J-Rogina advice and installed just Qt creator using the link he provided. So now all i have on my computer is qt-creator and qt5.4.2 that I installed in my ~/Qt/install directory.

                                    1 Reply Last reply
                                    0
                                    • E Offline
                                      E Offline
                                      elliottal
                                      wrote on 22 Jan 2019, 20:25 last edited by elliottal
                                      #18

                                      I did realize that my install directory was owned by root when I ran "ls -l" so I decided to to do a fresh install. I deleted the install directory and installed it again. Now I can see that the files are not owned by root so that should help. I opened up qt creator and made sure all the settings were still good and tried to run an example program, but still there are no example programs that show up when I click the examples button on the welcome screen. I decided to just open the project manually by opening the file in the example project's directory. Build executed with no problems this time which was good, however now when I click the run button I am met with yet another error that says:

                                      /home/dragon/Qt/install/examples/declarative/toys/clocks/clocks: error while loading shared libraries: libQt5declarative.so.5: libQt5declarative.so.5: cannot open shared object file: No such file or directory

                                      I am trying to research this now but if you could provide any insight that would be helpful.

                                      also I just noticed when I open the QML files and click the "design" button, I'm also getting errors that say cannot open this QML document because of an error in the QML file: Line 0: Unsupported QtQuick version...

                                      thanks again for your time.

                                      P 1 Reply Last reply 23 Jan 2019, 13:13
                                      0
                                      • S Offline
                                        S Offline
                                        SGaist
                                        Lifetime Qt Champion
                                        wrote on 22 Jan 2019, 22:08 last edited by
                                        #19

                                        @elliottal said in setting up qt with zynq:

                                        libQt5declarative.so.5

                                        Where is that file located ?

                                        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
                                        • E Offline
                                          E Offline
                                          elliottal
                                          wrote on 23 Jan 2019, 13:08 last edited by
                                          #20

                                          @SGaist It is located in my install directory under install/lib

                                          1 Reply Last reply
                                          0

                                          1/26

                                          15 Jan 2019, 16:11

                                          • Login

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