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. Project ERROR: Unknown module(s) in QT: designer
Forum Updated to NodeBB v4.3 + New Features

Project ERROR: Unknown module(s) in QT: designer

Scheduled Pinned Locked Moved Unsolved Installation and Deployment
22 Posts 3 Posters 18.9k Views 2 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.
  • G Offline
    G Offline
    GeorgeIoak
    wrote on 20 Jun 2017, 13:38 last edited by
    #1

    I have downloaded 5.9.1 source files using the installer and cross compiled for Raspberry Pi 3 using a Ubuntu 17.04 Host. If I start an example project and add

    QT       += designer
    

    to my .pro file I can compile for the Desktop but when I try to compile for the Raspberry Pi I get this error. I have compiled all the source modules (specifically qttools which I believe has the designer module) so I'm not sure what I need to add in order for the cross compile to find the designer module.

    I have tested other projects and core, gui, and widgets all can be successfully cross compiled.

    Thanks in advance for your help.

    1 Reply Last reply
    0
    • S Offline
      S Offline
      SGaist
      Lifetime Qt Champion
      wrote on 20 Jun 2017, 22:02 last edited by
      #2

      Hi,

      IIRC, the designer related classes are not available when cross-compiling as it is a host tool.

      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
      • G Offline
        G Offline
        GeorgeIoak
        wrote on 21 Jun 2017, 01:10 last edited by
        #3

        Thanks for that. What my ultimate goal was to install and use Qwt widgets and in order to use it the install instructions said you need to add designer to your Pro file. Is there another way to do this?

        1 Reply Last reply
        0
        • S Offline
          S Offline
          SGaist
          Lifetime Qt Champion
          wrote on 21 Jun 2017, 08:07 last edited by
          #4

          Only if you plan to use designer to create your widgets and in that case, it's still a "host plugin" so just don't build it when cross-compiling.

          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
          • G Offline
            G Offline
            GeorgeIoak
            wrote on 21 Jun 2017, 16:52 last edited by
            #5

            I'm sorry but I'm a little confused by your reply. If I want to use the Qwt plugin to add one of their widgets I need to use designer to place the widget and then I would need to cross compile and transfer to the Raspberry Pi to run on the Pi.

            Could you add some details on how I would install, use, and cross compile for the Pi?

            Thanks,
            George

            1 Reply Last reply
            0
            • S Offline
              S Offline
              SGaist
              Lifetime Qt Champion
              wrote on 21 Jun 2017, 22:16 last edited by
              #6

              I mean that the plugin must be compiled for the same architecture as Designer is running on. So for development you need to build Qwt twice: once for your desktop machine and once for your Pi.

              When cross-compiling you'll be linking to your cross-compiled Qwt the same way you'd be linking with your Desktop build of Qwt while building your application on your desktop machine.

              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
              • G Offline
                G Offline
                GeorgeIoak
                wrote on 22 Jun 2017, 00:21 last edited by
                #7

                OK, I think I'm getting there, thanks. so for the Host build I would issue:

                qmake qwt.pro -spec linux-g++
                make
                sudo make install
                

                which would install it at /usr/local/qwt-6.3.1 on the Ubunutu Host

                and then for the Raspberry Pi I would issue:

                qmake qwt.pro -spec device/linux-rasp-pi3-g++
                make
                make install
                

                But I need to direct the output to go into the ~/raspi/sysroot/usr or some other place like ~raspi/build/qt5.9/bin?

                When I ran the .config for cross compiling on the Ubuntu Host the configure used these values:

                -sysroot ~/raspi/sysroot
                -prefix /usr/local/qt5.9
                -extprefix ~/raspi/build/qt5.9
                -hostprefix ~/raspi/build/qt5.9-host
                
                1 Reply Last reply
                0
                • S Offline
                  S Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on 22 Jun 2017, 06:57 last edited by
                  #8

                  Use the full path to the qmake binary of the version of Qt you want to use.

                  As for cross-compilation, again, use the the full path to the qmake binary from your cross-compiled 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
                  1
                  • H Offline
                    H Offline
                    Hiloshi
                    wrote on 24 Jun 2017, 06:41 last edited by
                    #9

                    Dear Sirs,

                    I am facing the same issue. I also stop at Project ERROR: Unknown module(s) in QT: designer

                    My procedure is:

                    1. Use QT creator open qwt.pro
                    2. select Desktop QT5.8.0 GCC 64bit to build project
                    3. result is OK.(no error)
                    4. switch to "Raspberry Pi" then build project. (/rpi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf-g++)
                    5. result is " Unknown module(s) in QT: designer"

                    According to this discussion: http://www.qtcentre.org/threads/59011-Error-building-qwt-6-1-0-with-qmake-3-0
                    It same as @SGaist 's suggestion, it needs to compiler qwt.pro twice(if using cross-compiler).
                    Do I have to comment out designer for the fourth step (the 2nd compiler) ?
                    How to do it ? Does it means QT+=designer in qwt.pro (manual add for step2) or the

                    QWT_INSTALL_PLUGINS   = $${QWT_INSTALL_PREFIX}/plugins/designer 
                    

                    in qwtconfig.pri ??

                    Is there anyone have similar experience ?

                    Thanks for any help.

                    1 Reply Last reply
                    0
                    • S Offline
                      S Offline
                      SGaist
                      Lifetime Qt Champion
                      wrote on 24 Jun 2017, 22:51 last edited by
                      #10

                      IIRC, you need to disable the QWT_CONFIG += QwtDesigner line in qwtconfig.pri.

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

                      H 1 Reply Last reply 27 Jun 2017, 02:25
                      0
                      • S SGaist
                        24 Jun 2017, 22:51

                        IIRC, you need to disable the QWT_CONFIG += QwtDesigner line in qwtconfig.pri.

                        H Offline
                        H Offline
                        Hiloshi
                        wrote on 27 Jun 2017, 02:25 last edited by
                        #11

                        Dear @SGaist ,

                        Yes, your suggestion is correct. After comment out

                        QWT_CONFIG += QwtDesigner
                        

                        I can use rpi(/arm-linux-gnueabihf-g++) compiler the qwt project without error.

                        Though I still don't know how to add qwt into designer correctly, this may belong to different topic. I will arrange my test procedure and create different topic.

                        Thanks.

                        1 Reply Last reply
                        0
                        • S Offline
                          S Offline
                          SGaist
                          Lifetime Qt Champion
                          wrote on 27 Jun 2017, 06:47 last edited by
                          #12

                          The plugin for Designer must be built with the same version of Qt than Designer/Creator was built with (on Windows this includes compiler version).

                          That's why it's recommended to split the plugin project in two:

                          • One is a library with all the widget(s)
                          • One is the plugin itself

                          The plugin will be used to design your widget while the library will be used to link the application thus when you cross-compile you only need the library for the target.

                          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
                          • H Offline
                            H Offline
                            Hiloshi
                            wrote on 27 Jun 2017, 13:43 last edited by
                            #13

                            I installed QT Creator into the ubuntu 16.04,

                            After first compiler by linux-g++, libqwt_designer_plugin.so was created.
                            and then I open terminal and run "sudo make install" in /build-qwt-Desktop_Qt_5_8_0_GCC_64bit-Debug/. Then I can see qwt-6.1.3 folder was generated to /usr/local

                            then as @SGaist said, I comment out qwtdesigner, then run 2nd compiler.
                            2nd compiler is linux-rasp-pi-g++, then generate ../build-qwt-Raspberry_Pi-Debug.

                            1. Where should I copy libqwt_designer_plugin.so to ??
                              I expect after this process, I should able to see qwt widget in designer, right ?
                              I had tried copy to ~/Qt5.8.0/5.8/gcc_64/plugins/designer , but not working.

                            2. Should I do sudo make install in the ../build-qwt-Raspberry_Pi-Debug after 2nd compiler ?

                            3. After 2nd compiler, I think I should copy all ../build-qwt-Raspberry_Pi-Debug/lib to some place, but where ?? Replace everything in the /usr/local/qwt-6.1.3/lib ??

                            Appreciate for any help~

                            1 Reply Last reply
                            0
                            • S Offline
                              S Offline
                              SGaist
                              Lifetime Qt Champion
                              wrote on 27 Jun 2017, 21:18 last edited by
                              #14

                              The plugin should go within the installation of Qt Creator

                              You should have your cross-compiled Qwt in it's own folder.

                              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
                              • H Offline
                                H Offline
                                Hiloshi
                                wrote on 28 Jun 2017, 14:30 last edited by
                                #15

                                Dear Sirs,

                                I want to make qwt widget show on designer first, so I copy libqwt_designer_plugin.so to below foler, one by one.

                                /Qt5.8.0/5.8/gcc_64/plugins/designer
                                /Qt5.8.0/Tools/QtCreator/lib/qtcreator/plugins
                                /Qt5.8.0/Tools/QtCreator/lib/Qt/plugins/designer
                                /Qt5.8.0/Tools/QtCreator/lib/qtcreator/plugins/qbs/plugins
                                /Qt5.8.0/Tools/QtCreator/bin/designer <--manual create bin/designer folder
                                /usr/local/qwt-6.1.3/plugins/designer <--manual create plugins/designer folder

                                Unfortunately, none of them work... Any idea ?

                                PS. I re-open Qt Creator after copy to the folder each time.

                                1 Reply Last reply
                                0
                                • S Offline
                                  S Offline
                                  SGaist
                                  Lifetime Qt Champion
                                  wrote on 28 Jun 2017, 20:49 last edited by
                                  #16

                                  Did you check that you are using the same version of Qt that was used to build Qt Creator ?

                                  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
                                  • H Offline
                                    H Offline
                                    Hiloshi
                                    wrote on 29 Jun 2017, 15:21 last edited by
                                    #17

                                    Dear @SGaist ,

                                    I think they are the same, when I install qt creator I just download *.run file to complete the installation, so I think it use default make to build qt creator. Default gcc version is:
                                    x86_64-linux-gnu

                                    When compiler qwt desktop(ubuntu) version, I didn't export different compiler. So Qwt and qt creator should use the same make and gcc version.

                                    Is there any point I can check ?

                                    1 Reply Last reply
                                    0
                                    • S Offline
                                      S Offline
                                      SGaist
                                      Lifetime Qt Champion
                                      wrote on 29 Jun 2017, 22:40 last edited by
                                      #18

                                      You can start Qt Creator on the command line after setting the QT_DEBUG_PLUGINS environment variable to 1 so you can see what is happening with your plugin.

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

                                      H 1 Reply Last reply 6 Jul 2017, 01:31
                                      1
                                      • S SGaist
                                        29 Jun 2017, 22:40

                                        You can start Qt Creator on the command line after setting the QT_DEBUG_PLUGINS environment variable to 1 so you can see what is happening with your plugin.

                                        H Offline
                                        H Offline
                                        Hiloshi
                                        wrote on 6 Jul 2017, 01:31 last edited by
                                        #19

                                        Dear @SGaist ,

                                        I reinstall QT Creator and copy libqwt_designer_plugin.so to
                                        ~/Qt5.8.0/Tools/QtCreator/lib/Qt/plugins/designer/, then I can see qwt widget in the designer.

                                        I have not complete the whole process, but this is a good start. Thanks.

                                        1 Reply Last reply
                                        0
                                        • S Offline
                                          S Offline
                                          SGaist
                                          Lifetime Qt Champion
                                          wrote on 6 Jul 2017, 19:54 last edited by
                                          #20

                                          What do you mean by "all process" ?

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

                                          H 1 Reply Last reply 7 Jul 2017, 09:31
                                          0

                                          1/22

                                          20 Jun 2017, 13:38

                                          • Login

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