[Interest] Trouble compiling qt3d for qt6 on windows 10
mike.krus at kdab.com
Tue Feb 16 15:17:43 CET 2021
Assuming qt-configure-module.bat invokes qmake, the right way of passing the configure options is “-- -qt3d-simd=avx2”
If it’s invokes cmake, then try -DFEATURE_qt3d_simd_avx2=ON
Mike Krus | mike.krus at kdab.com | Senior Software Engineer & Teamlead
KDAB (UK) Ltd., a KDAB Group company
Tel: UK Office +44 1625 809908 Mobile +44 7833 491941
KDAB - The Qt Experts, C++, OpenGL Experts
> On 16 Feb 2021, at 13:31, Daniel Patel <danielpatel.no at gmail.com> wrote:
> Using a space didn't work either. I will try to use cmake though.
> The reason I wanted to use avx2 was to try to get rid of the compilation error: Project ERROR: Could not find feature qt3d-simd-avx2
> tir. 16. feb. 2021 kl. 14:22 skrev Paul Lemire <paul.lemire at kdab.com>:
> On 2/16/21 1:33 PM, Daniel Patel wrote:
>> Thanks a lot for the reply Paul, it was useful as always.
>> Copying the files made the qt3d examples work!
>> I realized that the compile error showed up because qt6 itself was only compiled in debug mode.
>> With the appropriate flag to the configure script, qt6 now compiles both in debug and in release.
>> However, now when compiling qt3d I ran into the error : "Could not find feature qt3d-simd-avx2" (I already configured and compiled qt6 with -avx2 flag)
>> I am just not able to tell/configure qt3d to use avx2 instead of sse2. Currently "qmake .." returns:
>> Use SSE2 instructions .................. yes
>> Use AVX2 instructions .................. no
>> After running configure for the qt6 build I got this text as output:
>> "To configure and build other Qt modules, you can use the following convenience script:
>> So i did a "c:\Qt\Qt-6.1\bin\qt-configure-module.bat qt3d-everywhere-src-6.0.0 --qt3d-simd=avx2" but that failed with "Unknown command line option '--qt3d-simd=avx2'" (I also tried -avx2-qt3d-simd and -qt3d-simd-avx2)
>> Anyone knows how to set configure flags for qt3d before compiling it?
> What about -qt3d-simd avx2 (just a space)? That's what I use when compiling on linux with qmake. For Qt 6, I've switched to cmake though, option to use is -DFEATURE_qt3d_simd_avx2=ON on the cmake command line.
> That being said, the avx2 option for Qt 3D essentially only yields better performance when we multiply matrices internally. The sse2 option is not much slower, a lot faster than relying on QMatrix4x4 (though this might have changed in Qt6, haven't checked).
>> On a side note I also was not able to get qt6 configure script to detect zlib libraries even though I set appropriate environment variables and sent in paths using both -D option as well as -I and -L option.
>> man. 15. feb. 2021 kl. 11:47 skrev Paul Lemire <paul.lemire at kdab.com>:
>> I can't really help about the compile issues. But I should be able to help regarding the plugin error.
>> You likely need to copy a few more things from the qt3d build dir to your Qt install dir:
>> qt3d_build_dir/qml/Qt3D into Qt_Install_Dir/qml/
>> qt3d_build_dir/qml/QtQuick/* into Qt_Install_Dir/qml/QtQuick/
>> qt3d_build_dir/plugins/* into Qt_Install_Dir/plugins/
>> (the plugins dir contains a renderers folder which contains the Qt3D render plugins)
>> I hope that helps,
>> On 2/15/21 11:03 AM, Daniel Patel wrote:
>>> I have compiled qt6.1 from source which works and now I am trying to compile qt3d also from source by downloading from https://download.qt.io/official_releases/additional_libraries/qt3d/6.0/6.0.0/ and following the qmake instructions from: https://www.kdab.com/getting-your-3d-ready-for-qt-6/
>>> I first tried to download and compile qt3d-everywhere-src-6.0.1 but got an error about missing zlib.h. Instead of trying to fix this I quickly instead tried with qt3d-everywhere-src-6.0.0 and this compiled fine.
>>> However it only compiled debug dlls and not release dlls. I tried to do nmake all and nmake release but the latter gave the error "NMAKE : fatal error U1073: don't know how to make 'C:\qtsrc\qt61\qt5\qtbase\lib\Qt6Gui.lib'"
>>> I then decided to try out the debug build. First I noticed that the qt3d dlls didnt seem to have been copied over to the correct folder when I did nmake install. So I copied them over manually and then started basicshapes-cpp.exe, but this showed the runtime error: Unable to find renderer plugin for opengl.
>>> Any hints for what to do?
>>> Interest mailing list
>>> Interest at qt-project.org
>> Paul Lemire |
>> paul.lemire at kdab.com
>> | Senior Software Engineer
>> KDAB (France) S.A.S., a KDAB Group company
>> Tel: France +33 (0)4 90 84 08 53,
>> KDAB - The Qt, C++ and OpenGL Experts
> Paul Lemire |
> paul.lemire at kdab.com
> | Senior Software Engineer
> KDAB (France) S.A.S., a KDAB Group company
> Tel: France +33 (0)4 90 84 08 53,
> KDAB - The Qt, C++ and OpenGL Experts
> Interest mailing list
> Interest at qt-project.org
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 4193 bytes
Desc: not available
More information about the Interest