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. Cross Compile QT 5.11 for Raspberry pi 3
Forum Updated to NodeBB v4.3 + New Features

Cross Compile QT 5.11 for Raspberry pi 3

Scheduled Pinned Locked Moved Solved Installation and Deployment
7 Posts 2 Posters 4.9k 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.
  • Z Offline
    Z Offline
    zhmh
    wrote on 24 Sept 2018, 18:45 last edited by zhmh 10 Jan 2018, 07:48
    #1

    My cross compiled QT version is old and I deiced to compile new one
    I want to use this link
    And this link says: The tested Configurations is Qt 5.10.1 with Raspbian stretch in the Raspberry 3 B model
    Can I compile a newer QT like 5.11 without error?
    And in one part of it,said:

    Missing EGLFS Fix
    
    On recent versions of Qt (e.g. 5.10.1), the qmake.conf file for linux-rasp-pi3-g++ doesn't work, however, linux-rasp-pi-g++ does. Create a new qmake.conf based on linux-rasp-pi-g++ with the build flags from the Pi 3 spec copied over.
    

    I don't understand what is it mean and what should I do?

    1 Reply Last reply
    0
    • S Offline
      S Offline
      sierdzio
      Moderators
      wrote on 24 Sept 2018, 19:30 last edited by
      #2

      @zhmh said in Cross Compile QT for Raspberry pi 3:

      linux-rasp-pi3-g++

      They talk about mkspecs, you can see the definitions for them in <qtdir>/qtbase/mkspecs.

      However, you don't have to use linux-rasp-pi-g++. You can pick the EGLFS native mkspecs instead: linux-rasp-pi3-vc4-g++.

      (Z(:^

      Z 1 Reply Last reply 24 Sept 2018, 20:41
      1
      • S sierdzio
        24 Sept 2018, 19:30

        @zhmh said in Cross Compile QT for Raspberry pi 3:

        linux-rasp-pi3-g++

        They talk about mkspecs, you can see the definitions for them in <qtdir>/qtbase/mkspecs.

        However, you don't have to use linux-rasp-pi-g++. You can pick the EGLFS native mkspecs instead: linux-rasp-pi3-vc4-g++.

        Z Offline
        Z Offline
        zhmh
        wrote on 24 Sept 2018, 20:41 last edited by
        #3

        @sierdzio how can I pick the EGLFS native mkspecs and where should I use it?

        1 Reply Last reply
        0
        • S Offline
          S Offline
          sierdzio
          Moderators
          wrote on 24 Sept 2018, 20:45 last edited by
          #4

          Pass these flags to configure:

           -opengl es2 -device linux-rasp-pi3-vc4-g++
          

          (Z(:^

          Z 1 Reply Last reply 29 Sept 2018, 18:19
          1
          • S sierdzio
            24 Sept 2018, 20:45

            Pass these flags to configure:

             -opengl es2 -device linux-rasp-pi3-vc4-g++
            
            Z Offline
            Z Offline
            zhmh
            wrote on 29 Sept 2018, 18:19 last edited by
            #5

            @sierdzio I Run

            ./configure -release -opengl es2 -device linux-rasp-pi3-vc4-g++ -device-option CROSS_COMPILE=/root/raspi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf- -sysroot /root/raspi/sysroot -opensource -confirm-license -make libs -prefix /usr/local/qt5pi -extprefix /root/raspi/qt5pi -hostprefix /root/raspi/qt5  -no-use-gold-linker -v
            

            for QT 5.11 and the output is :

            EGLFS ................ yes
                  ...
                  EGLFS Raspberry Pi ......... no
            

            EGLFS is Missing?or it's fine?

            1 Reply Last reply
            0
            • S Offline
              S Offline
              sierdzio
              Moderators
              wrote on 30 Sept 2018, 14:48 last edited by
              #6

              Yes that's fine.

              (Z(:^

              1 Reply Last reply
              0
              • Z Offline
                Z Offline
                zhmh
                wrote on 30 Sept 2018, 19:29 last edited by
                #7

                also I Run:

                ./configure -release -opengl es2 -device linux-rasp-pi3-g++ -device-option CROSS_COMPILE=/root/raspi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf- -sysroot /root/raspi/sysroot -opensource -confirm-license -make libs -prefix /usr/local/qt5pi -extprefix /root/raspi/qt5pi -hostprefix /root/raspi/qt5  -no-use-gold-linker -v
                

                for QT 5.11 and the output is :

                EGLFS ................ yes
                ...
                EGLFS Raspberry Pi ......... yes

                and when make it, I get :

                vc/include -I=/opt/vc/include/interface/vcos/pthreads -I=/opt/vc/include/interface/vmcs_host/linux -isystem /usr/include/libdrm -I/media/pi/BC1/qt-everywhere-src-5.11.0/qtbase/mkspecs/devices/linux-rasp-pi3-g++ -o .obj/qeglfskmsgbmwindow.o /media/pi/BC1/qt-everywhere-src-5.11.0/qtbase/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmwindow.cpp
                /media/pi/BC1/qt-everywhere-src-5.11.0/qtbase/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmwindow.cpp: In member function ‘virtual void QEglFSKmsGbmWindow::resetSurface()’:
                /media/pi/BC1/qt-everywhere-src-5.11.0/qtbase/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmwindow.cpp:58:5: error: ‘PFNEGLCREATEPLATFORMWINDOWSURFACEEXTPROC’ was not declared in this scope
                     PFNEGLCREATEPLATFORMWINDOWSURFACEEXTPROC createPlatformWindowSurface = nullptr;
                     ^
                /media/pi/BC1/qt-everywhere-src-5.11.0/qtbase/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmwindow.cpp:61:9: error: ‘createPlatformWindowSurface’ was not declared in this scope
                         createPlatformWindowSurface = reinterpret_cast<PFNEGLCREATEPLATFORMWINDOWSURFACEEXTPROC>(
                         ^
                /media/pi/BC1/qt-everywhere-src-5.11.0/qtbase/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmwindow.cpp:61:56: error: ‘PFNEGLCREATEPLATFORMWINDOWSURFACEEXTPROC’ does not name a type
                         createPlatformWindowSurface = reinterpret_cast<PFNEGLCREATEPLATFORMWINDOWSURFACEEXTPROC>(
                                                                        ^
                /media/pi/BC1/qt-everywhere-src-5.11.0/qtbase/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmwindow.cpp:65:9: error: ‘createPlatformWindowSurface’ was not declared in this scope
                     if (createPlatformWindowSurface) {
                         ^
                Makefile:2794: recipe for target '.obj/qeglfskmsgbmwindow.o' failed
                make[7]: *** [.obj/qeglfskmsgbmwindow.o] Error 1
                make[7]: Leaving directory '/media/pi/BC1/qt-everywhere-src-5.11.0/build/qtbase/src/plugins/platforms/eglfs/deviceintegration/eglfs_kms'
                Makefile:72: recipe for target 'sub-eglfs_kms-make_first' failed
                make[6]: *** [sub-eglfs_kms-make_first] Error 2
                make[6]: Leaving directory '/media/pi/BC1/qt-everywhere-src-5.11.0/build/qtbase/src/plugins/platforms/eglfs/deviceintegration'
                Makefile:104: recipe for target 'sub-deviceintegration-make_first-ordered' failed
                make[5]: *** [sub-deviceintegration-make_first-ordered] Error 2
                make[5]: Leaving directory '/media/pi/BC1/qt-everywhere-src-5.11.0/build/qtbase/src/plugins/platforms/eglfs'
                Makefile:125: recipe for target 'sub-eglfs-make_first' failed
                make[4]: *** [sub-eglfs-make_first] Error 2
                make[4]: Leaving directory '/media/pi/BC1/qt-everywhere-src-5.11.0/build/qtbase/src/plugins/platforms'
                Makefile:102: recipe for target 'sub-platforms-make_first' failed
                make[3]: *** [sub-platforms-make_first] Error 2
                make[3]: Leaving directory '/media/pi/BC1/qt-everywhere-src-5.11.0/build/qtbase/src/plugins'
                Makefile:776: recipe for target 'sub-plugins-make_first' failed
                make[2]: *** [sub-plugins-make_first] Error 2
                make[2]: Leaving directory '/media/pi/BC1/qt-everywhere-src-5.11.0/build/qtbase/src'
                Makefile:48: recipe for target 'sub-src-make_first' failed
                make[1]: *** [sub-src-make_first] Error 2
                make[1]: Leaving directory '/media/pi/BC1/qt-everywhere-src-5.11.0/build/qtbase'
                Makefile:81: recipe for target 'module-qtbase-make_first' failed
                make: *** [module-qtbase-make_first] Error 2
                

                So I clear everything with:
                git clean -dfx and
                add -no-gbm to configure.

                ./configure -release -opengl es2 -device linux-rasp-pi3-g++ -device-option CROSS_COMPILE=/root/raspi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf- -sysroot /root/raspi/sysroot -opensource -confirm-license -make libs -prefix /usr/local/qt5pi -extprefix /root/raspi/qt5pi -hostprefix /root/raspi/qt5  -no-use-gold-linker -v -no-gbm
                

                and make again ,it's work

                1 Reply Last reply
                1

                1/7

                24 Sept 2018, 18:45

                • Login

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