Qt 5.14.2 - compile issue - qt

Environment - RHEL 6, x86_64 machine / Also getting same error for MAC 10.12
qtbase/configure -top-level --prefix=/opt/local/Qt-5.13.2 -skip qtconnectivityy
-skip qtandroidextras -skip qtwayland -skip qtsensors -skip qtmacextras -skip qtwinextras -qt-xcb -opensource -confirm-license -icu -v -release -I /opt/local/include -L /opt/local/lib -skip qtmultimedia -skip qtdeclarative -skip qtcanvas3d
Project ERROR: Unknown module(s) in QT: 3dquick qml quick 3dquickextras
cd wireframe/ && ( test -e Makefile || qtbase/bin/qmake -o Makefile
qt3d/examples/qt3d/wireframe/wireframe.pro ) && make -f Makefile
Project ERROR: Unknown module(s) in QT: 3dquick qml quick 3dquickextras
make[3]: *** [sub-multiviewport-make_first] Error 3
make[3]: *** Waiting for unfinished jobs....
Project ERROR: Unknown module(s) in QT: 3dquick qml quick 3dquickextras
Project ERROR: Unknown module(s) in QT: 3dquick qml quick 3dquickextras
make[3]: *** [sub-simple-qml-make_first] Error 3
make[3]: *** [sub-wireframe-make_first] Error 3

The Qt3D example you are trying to build depends on 3dquick, qml, quick and 3dquickextras. I believe that you disabled them with -skip qtdeclarative. You can try adding -nomake examples to avoid building the examples.

Related

"fxc.exe: No such file or directory" When Compiling Qt on WSL

I'm attempting to build a cross-compiling Qt targeting Windows x64 with WSL as the host. I have succeeded in compiling the base parts of it, but I attempted to build a project to test it, only to find that it required qtdeclarative, which I had skipped as it was causing errors. No matter what I do, it always attempts to use fxc.exe to compile some shaders, and I am not sure if there is a way to circumvent this. I have tried reading the configure options to see if there is some way to skip DirectX-related things, but I have been unable to find anything. My configure was run as follows:
configure -opensource -no-compile-examples -platform linux-g++-64 -xplatform win32-g++ -device-option CROSS_COMPILE=/usr/bin/x86_64-w64-mingw32- -skip qtactiveqt -skip qtwebengine -skip wayland -skip qtandroidextras -skip qttranslations -skip qt3d -skip qtcanvas3d -skip qtgraphicaleffects -skip qtcharts -skip qtwebview -skip qtserialbus -skip qtdatavis3d -skip qtmultimedia -skip qtdeclarative -static -opengl desktop -prefix /usr/local/qt-5.15.2 -confirm-license
Does anyone know if there is a way around this, or at least what might be causing what is essentially Linux to be looking for .exe files?
Comment it out at "qtdeclarative/src/plugins/scenegraph/scenegraph.pro":
# qtConfig(d3d12): SUBDIRS += d3d12
Obviously it won't work on the target afterwards. Ask the "Qt" people why is it not excluded from cross-builds on unsupported hosts.

Cross compile QtWebEngine for Raspberry Pi 4

I use qt-everywhere-src-5.15.0.tar.xz and gcc-linaro-7.4.1-2019.02-x86_64_arm-
linux-gnueabihf toolchain on an Ubuntu 18 to cross compile Qt and especially
QtWebEngine.
I use the following configure:
../qt-everywhere-src-5.15.0/configure \
-opengl es2 -device linux-rasp-pi4-v3d-g++ \
-device-option CROSS_COMPILE=~/raspi/tools/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- \
-sysroot ~/raspi/sysroot \
-prefix /usr/local/qt5pi \
-opensource -confirm-license -no-gbm \
-skip qtscript -skip qtandroidextras -skip qtcanvas3d \
-skip qtgamepad -skip qtmacextras -skip qtpurchasing \
-skip qtwinextras -skip qtx11extras \
-nomake tests -nomake examples -make libs \
-pkg-config -no-use-gold-linker -v
If I include "-skip qtwebengine" in the configure command, all the compilation works well, but when I include qtwebengine the configuration fails with the following warning:
WARNING: Could not find all necessary libraries for qpa-xcb support in QtWebEngine.
WARNING: QtWebEngine will not be built.
After searching a while, I know the reason for this warning. QtWebEngine uses
pkg-config, to get the required libraries (e.g. xtst, xcomposite, ...) and take
the libraries on my host system instead of using the copied packages from the raspberry.
How can I configure it, to use the copied files from the raspberry sysroot?
If the only libraries that seem to be missing are xtst, xcomposite, xi, etc. Those are located on the Pi in /usr/share. So your sysroot has to sync that folder as well.

What are the configure options for Qt that enable dead keys usage?

I use a bare Ubuntu LTS 16.04 vm to create an AppImage for one of my projects. I create a minimalistic static Qt for this, so that the AppImage's size is as small as possible. I recently managed to build a static Qt 5.14.2 with the following configure options:
../configure -prefix ~/Qt/5.14.2_static -opensource -confirm-license -release -static -optimize-size -no-opengl -no-gif -no-ico -no-libjpeg -skip qt3d -skip qtactiveqt -skip qtandroidextras -skip qtcanvas3d -skip qtcharts -skip qtconnectivity -skip qtdatavis3d -skip qtdeclarative -skip qtdoc -skip qtgamepad -skip qtgraphicaleffects -skip qtimageformats -skip qtlocation -skip qtmacextras -skip qtmultimedia -skip qtnetworkauth -skip qtpurchasing -skip qtquickcontrols -skip qtquickcontrols2 -skip qtremoteobjects -skip qtscript -skip qtscxml -skip qtsensors -skip qtserialbus -skip qtserialport -skip qtspeech -skip qtvirtualkeyboard -skip qtwayland -skip qtwebchannel -skip qtwebengine -skip qtwebglplugin -skip qtwebsockets -skip qtwebview -skip qtwinextras -skip qtxmlpatterns -nomake examples -nomake tests -nomake tools -qt-zlib -sql-sqlite -qt-sqlite -qt-libpng -qt-pcre -qt-xcb
Building my program and an AppImage works, I noticed however, that dead keys don't work. I use a German locale here, and pressing accent keys does nothing. E. g. when I input an ´ and an e into a QLineEdit, I simply get an e instead of é.
I first thought this was due to something missing in the vm, but when I do the same Qt build on my Gentoo host (where dead keys always have been working in Qt programs), I get the same result: the dead keys don't work. So most probably, this is due to wrong configuration.
I experimented with the -libinput, -xkb, -xkbcommon and -qt-harfbuzz configure switches, but I can't get dead keys to work.
Which configure options have to be set when building Qt so that dead keys work?
Edit: When I build Qt with this exact configure statement, but the shared version instead of the static one, the dead keys work. What does cause this?
This happened due to a missing QTPLUGIN parameter. Imho this is almost impossible to figure out, but easy to solve:
Adding QTPLUGIN += composeplatforminputcontextplugin to the .pro file does the trick. Q_IMPORT_PLUGIN(QComposePlatformInputContextPlugin) appears automatically in project_plugin_import.cpp.
Doing so, the dead keys work as expected with a static build.

Can't qmake QtWebengine - "qtwebenginecore-config.pri: No such file or directory"

I built qt whit this configuration:
configure -v -release -opengl es2 -device linux-rasp-pi3-g++ -device-option CROSS_COMPILE=/home/doxa/raspi/gcc-linaro-6.3.1-2017.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -opensource -confirm-license -sysroot /home/doxa/raspi/sysroot -make libs -nomake tests -nomake tools -nomake examples -skip qt3d -skip qtgamepad -skip qtlocation -skip qtsensors -skip qtwayland -skip qtdeclarative -prefix /usr/local/doxas_5.12.4 -extprefix /usr/local/doxas_5.12.4 -hostprefix /usr/local/doxas_5.12.4 -qpa xcb -no-use-gold-linker
Everything done well but, QtWebengine didn't configure.
Now I want to build and install this module(I did with Qt 5.7), but qmake returns an error:
doxa#K43SD:/media/doxa/MCBK/rpi_build/websss$ /media/doxa/MCBK/rpi_build/qtbase/bin/qmake /usr/local/Qt5.12.4/5.12.4/Src/qtwebengine/
Info: creating cache file /media/doxa/MCBK/rpi_build/websss/.qmake.cache
Cannot read /media/doxa/MCBK/rpi_build/websss/src/core/qtwebenginecore-config.pri: No such file or directory
Project ERROR: Could not find feature webengine-v8-snapshot-support.
doxa#K43SD:/media/doxa/MCBK/rpi_build/websss$
the *-config.pri is not available in the source of any module and it has to build during the module build process. I don't know how to generate this file. which tools of Qt should I use?
Qt: 5.12.4
Host: Ubuntu 18.04_x64
Thanks in advance
I Just found where is the problem.
I should use the out of source qmake, where it is installed.
Qt forum
mkdir build_qtwebengine
cd buid_qtwebengine
/path/to/your/cross_compiled_Qt/bin/qmake /path/to/qtwebengine

How to disable the Qt Wayland module during QT build?

I am trying to build Qt on my raspberry pi with jessie on it.
The configure option that I have provided are as below for my build:
./configure -v -opengl es2 -device linux-rasp-pi-g''+ -device-option CROSS_COMPILE=/usr/bin/ -opensource -confirm-license -optimized-qmake -reduce-exports -release -qt-pcre -make libs -prefix /usr/local/qt5
However, I am getting the below error pertaining to QtWayland ...
Project ERROR: wayland-client development package not found
Makefile:54: recipe for target 'sub-brcm-egl-install_subtargets' failed
make[5]: *** [sub-brcm-egl-install_subtargets] Error 3
make[5]: Leaving directory '/home/pi/packages/qt5/qt-everywhere-opensource-src-5.5.1/qtwayland/src/plugins/hardwareintegration/client'
Makefile:54: recipe for target 'sub-client-install_subtargets' failed
make[4]: *** [sub-client-install_subtargets] Error 2
make[4]: Leaving directory '/home/pi/packages/qt5/qt-everywhere-opensource-src-5.5.1/qtwayland/src/plugins/hardwareintegration'
Makefile:81: recipe for target 'sub-hardwareintegration-install_subtargets' failed
make[3]: *** [sub-hardwareintegration-install_subtargets] Error 2
make[3]: Leaving directory '/home/pi/packages/qt5/qt-everywhere-opensource-src-5.5.1/qtwayland/src/plugins'
Makefile:107: recipe for target 'sub-plugins-install_subtargets' failed
make[2]: *** [sub-plugins-install_subtargets] Error 2
make[2]: Leaving directory '/home/pi/packages/qt5/qt-everywhere-opensource-src-5.5.1/qtwayland/src'
Makefile:56: recipe for target 'sub-src-install_subtargets' failed
make[1]: *** [sub-src-install_subtargets] Error 2
make[1]: Leaving directory '/home/pi/packages/qt5/qt-everywhere-opensource-src-5.5.1/qtwayland'
Makefile:737: recipe for target 'module-qtwayland-install_subtargets' failed
make: *** [module-qtwayland-install_subtargets] Error 2
Is there any way that I can disable the QtWayland option during Qt build?
You can skip it while doing configure
./configure -skip wayland.

Resources