Skip to contentSkip to conversation

Building Qt5 toolchain for windows

Yocto Joshua Watt 3 participants 3 messages Apr 21, 2020 – Apr 27, 2020 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw
Quoted 5 lines · On 4/21/20 1:00 PM, [email protected] wrote:

Hello,

I’m working on a project and I need to build a Qt5 toolchain for Windows,

Quoted 8 lines

I’m using meta-qt5 and meta-mingw and my build machine is an ubuntu 18.04

However I keep having errors when i execute « bitbake meta-toolchain-qt5 », very much like the one in below forum thread

https://www.yoctoproject.org/pipermail/yocto/2019-March/044512.html

Am I doing something wrong ? Could you help sending me some ideas on how I could accomplish what I want ?

I don't actually know a whole lot about cmake/qt5, so I'm not sure what would need to be done (other than what I've already stated in the message above). Samuli Piippo (cc'd) recently did some work to get cmake to build for MinGW, so he might have some insight.

Quoted 6 lines

Thanks,

Best regards,

David Fourdrigniez.

#2 lore raw

Hello Joshua,

Thank you for your reply,

Just for information, I put the following parameters in local.conf

MACHINE ?= "qemuarm"

SDKMACHINE = "i686-mingw32"

IMAGE_INSTALL_append = " gcc g++ binutils libgcc-dev libstdc++ libstdc++-dev libstdc++-staticdev qtbase qtcharts qtconnectivity qtdeclarative qtenginio qtgraphicaleffects qtlocation qtmultimedia qtscript qtsensors qtserialport qtsystems qttools qttranslations qtvirtualkeyboard qtwebsockets qtxmlpatterns openssh-sftp-server gdb gdbserver"

And here is the error I get when I run the command: bitbake meta-toolchain-qt5

| In file included from /home/david/yocto/poky/build/tmp/work/i686-nativesdk-mingw32-pokysdk-mingw32 /nativesdk-qtbase/5.13.2+gitAUTOINC+a7a24784ee-r0/recipe-sysroot/opt/poky/3. 0.2/sysroots/i686-pokysdk-mingw32/usr/include/winbase.h:18,

| from
/home/david/yocto/poky/build/tmp/work/i686-nativesdk-mingw32-pokysdk-mingw32 /nativesdk-qtbase/5.13.2+gitAUTOINC+a7a24784ee-r0/recipe-sysroot/opt/poky/3. 0.2/sysroots/i686-pokysdk-mingw32/usr/include/windows.h:70,

| from
/home/david/yocto/poky/build/tmp/work/i686-nativesdk-mingw32-pokysdk-mingw32 /nativesdk-qtbase/5.13.2+gitAUTOINC+a7a24784ee-r0/git/qmake/library/ioutils. cpp:35:

| /home/david/yocto/poky/build/tmp/work/i686-nativesdk-mingw32-pokysdk-mingw32 /nativesdk-qtbase/5.13.2+gitAUTOINC+a7a24784ee-r0/recipe-sysroot/opt/poky/3. 0.2/sysroots/i686-pokysdk-mingw32/usr/include/fileapi.h:53:48: note:
initializing argument 1 of 'void* CreateFileA(LPCSTR, DWORD, DWORD, LPSECURITY_ATTRIBUTES, DWORD, DWORD, HANDLE)'

| 53 | WINBASEAPI HANDLE WINAPI CreateFileA (LPCSTR lpFileName, DWORD
dwDesiredAccess, DWORD dwShareMode, LPSECURITY_ATTRIBUTES lpSecurityAttributes, DWORD dwCreationDisposition, DWORD dwFlagsAndAttributes, HANDLE hTemplateFile);

| | ~~~~~~~^~~~~~~~~~

| Makefile:212: recipe for target 'ioutils.o' failed

| make: *** [ioutils.o] Error 1

| WARNING: exit code 2 from a shell command.

|

ERROR: Task (/home/david/yocto/poky/meta-qt5/recipes-qt/qt5/nativesdk-qtbase_git.bb:do_c onfigure) failed with exit code '1'

NOTE: Tasks Summary: Attempted 3299 tasks of which 3161 didn't need to be rerun and 1 failed.

Summary: 1 task failed:

/home/david/yocto/poky/meta-qt5/recipes-qt/qt5/nativesdk-qtbase_git.bb:do_co nfigure

Summary: There was 1 ERROR message shown, returning a non-zero exit code.

Best regards,

David FOURDRIGNIEZ
Mobile +33 6 27 94 03 25

Email <mailto:[email protected]> [email protected]

From: Joshua Watt <[email protected]>
Sent: mardi 21 avril 2020 13:20
To: [email protected]
Cc: Samuli Piippo <[email protected]>; [email protected]
Subject: Re: [Yocto] Building Qt5 toolchain for windows

On 4/21/20 1:00 PM, [email protected]
<mailto:[email protected]> wrote:

Hello,

I'm working on a project and I need to build a Qt5 toolchain for Windows,

I'm using meta-qt5 and meta-mingw and my build machine is an ubuntu 18.04

However I keep having errors when i execute < bitbake meta-toolchain-qt5 >, very much like the one in below forum thread

https://www.yoctoproject.org/pipermail/yocto/2019-March/044512.html

Am I doing something wrong ? Could you help sending me some ideas on how I could accomplish what I want ?

I don't actually know a whole lot about cmake/qt5, so I'm not sure what would need to be done (other than what I've already stated in the message above). Samuli Piippo (cc'd) recently did some work to get cmake to build for MinGW, so he might have some insight.

Thanks,

Best regards,

David Fourdrigniez.

#3 lore raw

Hi,

Our changes for supporting mingw builds for Qt5 nativesdk tools are still part of the meta-boot2qt layer (https://code.qt.io/cgit/yocto/meta-boot2qt.git/), which is used in the Qt for Device Creation product. Some of these changes could be moved over to meta-qt5. CMake support is still partial and will only work with the Qt Creator integration.

-samuli

________________________________
From: [email protected] <[email protected]>
Sent: 22 April 2020 18:38
To: 'Joshua Watt' <[email protected]>
Cc: Samuli Piippo <[email protected]>; [email protected] <[email protected]>
Subject: RE: [Yocto] Building Qt5 toolchain for windows

Hello Joshua,

Thank you for your reply,

Just for information, I put the following parameters in local.conf

MACHINE ?= “qemuarm”

SDKMACHINE = “i686-mingw32”

IMAGE_INSTALL_append = “ gcc g++ binutils libgcc-dev libstdc++ libstdc++-dev libstdc++-staticdev qtbase qtcharts qtconnectivity qtdeclarative qtenginio qtgraphicaleffects qtlocation qtmultimedia qtscript qtsensors qtserialport qtsystems qttools qttranslations qtvirtualkeyboard qtwebsockets qtxmlpatterns openssh-sftp-server gdb gdbserver”

And here is the error I get when I run the command: bitbake meta-toolchain-qt5

| In file included from /home/david/yocto/poky/build/tmp/work/i686-nativesdk-mingw32-pokysdk-mingw32/nativesdk-qtbase/5.13.2+gitAUTOINC+a7a24784ee-r0/recipe-sysroot/opt/poky/3.0.2/sysroots/i686-pokysdk-mingw32/usr/include/winbase.h:18,

| from /home/david/yocto/poky/build/tmp/work/i686-nativesdk-mingw32-pokysdk-mingw32/nativesdk-qtbase/5.13.2+gitAUTOINC+a7a24784ee-r0/recipe-sysroot/opt/poky/3.0.2/sysroots/i686-pokysdk-mingw32/usr/include/windows.h:70,

| from /home/david/yocto/poky/build/tmp/work/i686-nativesdk-mingw32-pokysdk-mingw32/nativesdk-qtbase/5.13.2+gitAUTOINC+a7a24784ee-r0/git/qmake/library/ioutils.cpp:35:

| /home/david/yocto/poky/build/tmp/work/i686-nativesdk-mingw32-pokysdk-mingw32/nativesdk-qtbase/5.13.2+gitAUTOINC+a7a24784ee-r0/recipe-sysroot/opt/poky/3.0.2/sysroots/i686-pokysdk-mingw32/usr/include/fileapi.h:53:48: note: initializing argument 1 of 'void* CreateFileA(LPCSTR, DWORD, DWORD, LPSECURITY_ATTRIBUTES, DWORD, DWORD, HANDLE)'

| 53 | WINBASEAPI HANDLE WINAPI CreateFileA (LPCSTR lpFileName, DWORD dwDesiredAccess, DWORD dwShareMode, LPSECURITY_ATTRIBUTES lpSecurityAttributes, DWORD dwCreationDisposition, DWORD dwFlagsAndAttributes, HANDLE hTemplateFile);

| | ~~~~~~~^~~~~~~~~~

| Makefile:212: recipe for target 'ioutils.o' failed

| make: *** [ioutils.o] Error 1

| WARNING: exit code 2 from a shell command.

|

ERROR: Task (/home/david/yocto/poky/meta-qt5/recipes-qt/qt5/nativesdk-qtbase_git.bb:do_configure) failed with exit code '1'

NOTE: Tasks Summary: Attempted 3299 tasks of which 3161 didn't need to be rerun and 1 failed.

Summary: 1 task failed:

/home/david/yocto/poky/meta-qt5/recipes-qt/qt5/nativesdk-qtbase_git.bb:do_configure

Summary: There was 1 ERROR message shown, returning a non-zero exit code.

Best regards,

David FOURDRIGNIEZ
Mobile +33 6 27 94 03 25

Email [email protected]<mailto:[email protected]>

From: Joshua Watt <[email protected]>
Sent: mardi 21 avril 2020 13:20
To: [email protected]
Cc: Samuli Piippo <[email protected]>; [email protected]
Subject: Re: [Yocto] Building Qt5 toolchain for windows

On 4/21/20 1:00 PM, [email protected]<mailto:[email protected]> wrote:

Hello,

I’m working on a project and I need to build a Qt5 toolchain for Windows,

I’m using meta-qt5 and meta-mingw and my build machine is an ubuntu 18.04

However I keep having errors when i execute « bitbake meta-toolchain-qt5 », very much like the one in below forum thread

https://www.yoctoproject.org/pipermail/yocto/2019-March/044512.html

Am I doing something wrong ? Could you help sending me some ideas on how I could accomplish what I want ?

I don't actually know a whole lot about cmake/qt5, so I'm not sure what would need to be done (other than what I've already stated in the message above). Samuli Piippo (cc'd) recently did some work to get cmake to build for MinGW, so he might have some insight.

Thanks,

Best regards,

David Fourdrigniez.