Topic: How can i build in Windows

Hi

[left]how can I generate the exe in Windows?
I have install
QMake version 3.1
Using Qt version 5.13.0 in C:/Qt/5.13.0/mingw73_64/lib

When I start qmake always comes
Project ERROR: Unknown module (s) in QT: KWidgetsAddons KCoreAddons
[/left]

Re: How can i build in Windows

Hi,

I don't use Windows but MXE and Digikam scripts for cross-compiling Windows package with KF5 modules under my Debian machine.


Perhaps Joshua can help you, he just did it recently in a Windows VM.


This tutorial could help you :
https://github.com/drawpile/Drawpile/wi … om-sources

See : Windows dependencies (MinGW), or  Windows dependencies (Visual Studio),
cmake-extra-modules, and karchive example.

https://api.kde.org/frameworks/kcoreadd … index.html
https://api.kde.org/frameworks/kwidgets … index.html

windeployqt :
https://doc.qt.io/qt-5/windows-deployment.
                     

Btw, KDE devel use Craft for Windows compile :
https://community.kde.org/Craft#Using_C … Qt_Creator

"Le jour où tu découvres le Libre, tu sais que tu ne pourras jamais plus revenir en arrière..."

Re: How can i build in Windows

thanks,  I will try it. I think the drawpile link brings me back.

Re: How can i build in Windows

ok, its build with Error

sources\ui\ui_alignmenttextdialog.h:13:10: fatal error: QtGui/QAction: No such file or directory
 #include <QtGui/QAction>
          ^~~~~~~~~~~~~~~
compilation terminated.
mingw32-make[1]: *** [Makefile.Release:75071: release/alignmenttextdialog.o] Error 1
mingw32-make[1]: Leaving directory 'C:/temp/0.70rc2'
mingw32-make: *** [Makefile:38: release] Error 2

someone an idea

Re: How can i build in Windows

I think you compile it with Qt 4 and not with Qt 5 ?

https://git.tuxfamily.org/qet/qet.git/t … xtdialog.h

https://stackoverflow.com/questions/215 … ui-qaction

"Le jour où tu découvres le Libre, tu sais que tu ne pourras jamais plus revenir en arrière..."

6 (edited by stromie 2019-07-10 21:34:14)

Re: How can i build in Windows

thanks scorpio810



the build was successful. What amazes me, your * .exe is about 33MB in size. My only 5MB.

is it the differenc static to dynamic?


In the next few days I write a tutorial how I did it. This can benefit others.

Re: How can i build in Windows

Yes, .exe files contain dll in static mode, that's why it's bigger than you in shared mode, but if you count dll size is the same thing.
Maybe if you could provide a guide for those who wants to compile it under Windows, it could be useful.

"Le jour où tu découvres le Libre, tu sais que tu ne pourras jamais plus revenir en arrière..."

Re: How can i build in Windows

I have build qt without erros. But the build of kcoreaddons and kwidgetsaddons have link error. Because it will link dynamic. How can cmake say link static ?

Re: How can i build in Windows

Maybe the problem is if KF5 libraries isn't builded with the same Qt version than you compile QET?

"Le jour où tu découvres le Libre, tu sais que tu ne pourras jamais plus revenir en arrière..."

Re: How can i build in Windows

What do you want to do make it in static? For packaging In shared mode, just create a bin directory and copy DLLs them in, like this old example :
https://qelectrotech.org/wiki_new/doc/d … mande_tree

Or use https://doc.qt.io/qt-5/windows-deployment.html

"Le jour où tu découvres le Libre, tu sais que tu ne pourras jamais plus revenir en arrière..."

11 (edited by stromie 2019-07-14 18:33:19)

Re: How can i build in Windows

thanks for the links. very interesting

I still have an understanding problem. If I want to create Qelectrotech static, then I have to generate the KwidgetAddons KcoreAddons also static. Or?

However, I miss the setting of cmake so that KwidgetAddons KcoreAddons also static link.