Build error QLC+ 4.xx Ubuntu 20.04 Qt6

Post Reply
User avatar
sbenejam
Posts: 550
Joined: Sun Apr 12, 2015 6:28 pm
Real Name: Santiago Benejam Torres
Contact:

I'm trying to build QLC+ 4.12.5-GIT on Ubuntu 20.04 against Qt6.2.4 and I get the errors posted below
OS: Ubuntu 20.04
Qt v6.2.4
gcc (Ubuntu 10.3.0-1ubuntu1~20.04) 10.3.0
I'm waiting for the new version of Ubuntu 22.04 in case there is a problem with Ubuntu 20.04.
Massimo, with what version of Ubuntu and Qt does it work to compile QLC +?

Code: Select all

g++ -c -pipe -Werror -Wno-unused-local-typedefs -g -std=gnu++1z -D_REENTRANT -Wall -Wextra -fPIC -DQT_MULTIMEDIAWIDGETS_LIB -DQT_WIDGETS_LIB -DQT_MULTIMEDIA_LIB -DQT_GUI_LIB -DQT_QML_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I. -Imonitor -Ishowmanager -Ivirtualconsole -I../../engine/src -I../../engine/audio/src -I../../plugins/interfaces -I../../webaccess -I../../../Qt/6.2.4/gcc_64/include -I../../../Qt/6.2.4/gcc_64/include/QtMultimediaWidgets -I../../../Qt/6.2.4/gcc_64/include/QtWidgets -I../../../Qt/6.2.4/gcc_64/include/QtMultimedia -I../../../Qt/6.2.4/gcc_64/include/QtGui -I../../../Qt/6.2.4/gcc_64/include/QtQml -I../../../Qt/6.2.4/gcc_64/include/QtNetwork -I../../../Qt/6.2.4/gcc_64/include/QtCore -I. -I. -I../../../Qt/6.2.4/gcc_64/mkspecs/linux-g++ -o vcclock.o virtualconsole/vcclock.cpp
In file included from ../../../Qt/6.2.4/gcc_64/include/QtCore/qarraydataops.h:45,
                 from ../../../Qt/6.2.4/gcc_64/include/QtCore/qarraydatapointer.h:43,
                 from ../../../Qt/6.2.4/gcc_64/include/QtCore/qbytearray.h:47,
                 from ../../../Qt/6.2.4/gcc_64/include/QtCore/qstringview.h:58,
                 from ../../../Qt/6.2.4/gcc_64/include/QtCore/qchar.h:666,
                 from ../../../Qt/6.2.4/gcc_64/include/QtCore/qstring.h:50,
                 from ../../../Qt/6.2.4/gcc_64/include/QtCore/qobject.h:47,
                 from ../../../Qt/6.2.4/gcc_64/include/QtCore/qsettings.h:43,
                 from ../../../Qt/6.2.4/gcc_64/include/QtCore/QSettings:1,
                 from virtualconsole/addvcbuttonmatrix.cpp:20:
../../../Qt/6.2.4/gcc_64/include/QtCore/qcontainertools_impl.h: In instantiation of ‘QtPrivate::sequential_erase<QList<unsigned int>, int>::<lambda(auto:22&)> [with auto:22 = unsigned int]’:
../../../Qt/6.2.4/gcc_64/include/QtCore/qcontainertools_impl.h:304:18:   required from ‘auto QtPrivate::sequential_erase_if(Container&, Predicate&) [with Container = QList<unsigned int>; Predicate = QtPrivate::sequential_erase<QList<unsigned int>, int>::<lambda(auto:22&)>]’
../../../Qt/6.2.4/gcc_64/include/QtCore/qcontainertools_impl.h:320:31:   required from ‘auto QtPrivate::sequential_erase(Container&, const T&) [with Container = QList<unsigned int>; T = int]’
../../../Qt/6.2.4/gcc_64/include/QtCore/qcontainertools_impl.h:328:28:   required from ‘auto QtPrivate::sequential_erase_with_copy(Container&, const T&) [with Container = QList<unsigned int>; T = int]’
../../../Qt/6.2.4/gcc_64/include/QtCore/qlist.h:540:53:   required from ‘qsizetype QList<T>::removeAll(const AT&) [with AT = int; T = unsigned int; qsizetype = long long int]’
virtualconsole/addvcbuttonmatrix.cpp:139:62:   required from here
../../../Qt/6.2.4/gcc_64/include/QtCore/qcontainertools_impl.h:319:40: error: comparison of integer expressions of different signedness: ‘unsigned int’ and ‘const int’ [-Werror=sign-compare]
  319 |     auto cmp = [&](auto &e) { return e == t; };
      |                                      ~~^~~~
g++ -c -pipe -Werror -Wno-unused-local-typedefs -g -std=gnu++1z -D_REENTRANT -Wall -Wextra -fPIC -DQT_MULTIMEDIAWIDGETS_LIB -DQT_WIDGETS_LIB -DQT_MULTIMEDIA_LIB -DQT_GUI_LIB -DQT_QML_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I. -Imonitor -Ishowmanager -Ivirtualconsole -I../../engine/src -I../../engine/audio/src -I../../plugins/interfaces -I../../webaccess -I../../../Qt/6.2.4/gcc_64/include -I../../../Qt/6.2.4/gcc_64/include/QtMultimediaWidgets -I../../../Qt/6.2.4/gcc_64/include/QtWidgets -I../../../Qt/6.2.4/gcc_64/include/QtMultimedia -I../../../Qt/6.2.4/gcc_64/include/QtGui -I../../../Qt/6.2.4/gcc_64/include/QtQml -I../../../Qt/6.2.4/gcc_64/include/QtNetwork -I../../../Qt/6.2.4/gcc_64/include/QtCore -I. -I. -I../../../Qt/6.2.4/gcc_64/mkspecs/linux-g++ -o vcclockproperties.o virtualconsole/vcclockproperties.cpp
../../../Qt/6.2.4/gcc_64/include/QtCore/qcontainertools_impl.h: In instantiation of ‘QtPrivate::sequential_erase<QList<unsigned int>, int>::<lambda(auto:22&)> [with auto:22 = const unsigned int]’:
/usr/include/c++/10/bits/predefined_ops.h:316:23:   required from ‘bool __gnu_cxx::__ops::_Iter_pred<_Predicate>::operator()(_Iterator) [with _Iterator = QList<unsigned int>::const_iterator; _Predicate = QtPrivate::sequential_erase<QList<unsigned int>, int>::<lambda(auto:22&)>]’
/usr/include/c++/10/bits/stl_algobase.h:1929:14:   required from ‘_RandomAccessIterator std::__find_if(_RandomAccessIterator, _RandomAccessIterator, _Predicate, std::random_access_iterator_tag) [with _RandomAccessIterator = QList<unsigned int>::const_iterator; _Predicate = __gnu_cxx::__ops::_Iter_pred<QtPrivate::sequential_erase<QList<unsigned int>, int>::<lambda(auto:22&)> >]’
/usr/include/c++/10/bits/stl_algobase.h:1974:23:   required from ‘_Iterator std::__find_if(_Iterator, _Iterator, _Predicate) [with _Iterator = QList<unsigned int>::const_iterator; _Predicate = __gnu_cxx::__ops::_Iter_pred<QtPrivate::sequential_erase<QList<unsigned int>, int>::<lambda(auto:22&)> >]’
/usr/include/c++/10/bits/stl_algo.h:3934:28:   required from ‘_IIter std::find_if(_IIter, _IIter, _Predicate) [with _IIter = QList<unsigned int>::const_iterator; _Predicate = QtPrivate::sequential_erase<QList<unsigned int>, int>::<lambda(auto:22&)>]’
../../../Qt/6.2.4/gcc_64/include/QtCore/qcontainertools_impl.h:288:35:   required from ‘auto QtPrivate::sequential_erase_if(Container&, Predicate&) [with Container = QList<unsigned int>; Predicate = QtPrivate::sequential_erase<QList<unsigned int>, int>::<lambda(auto:22&)>]’
../../../Qt/6.2.4/gcc_64/include/QtCore/qcontainertools_impl.h:320:31:   required from ‘auto QtPrivate::sequential_erase(Container&, const T&) [with Container = QList<unsigned int>; T = int]’
../../../Qt/6.2.4/gcc_64/include/QtCore/qcontainertools_impl.h:328:28:   required from ‘auto QtPrivate::sequential_erase_with_copy(Container&, const T&) [with Container = QList<unsigned int>; T = int]’
../../../Qt/6.2.4/gcc_64/include/QtCore/qlist.h:540:53:   required from ‘qsizetype QList<T>::removeAll(const AT&) [with AT = int; T = unsigned int; qsizetype = long long int]’
virtualconsole/addvcbuttonmatrix.cpp:139:62:   required from here
../../../Qt/6.2.4/gcc_64/include/QtCore/qcontainertools_impl.h:319:40: error: comparison of integer expressions of different signedness: ‘const unsigned int’ and ‘const int’ [-Werror=sign-compare]
cc1plus: all warnings being treated as errors
make[2]: *** [Makefile:37212: addvcbuttonmatrix.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory '/home/sbenejam/qlcqt6/ui/src'
make[1]: *** [Makefile:48: sub-src-make_first-ordered] Error 2
make[1]: Leaving directory '/home/sbenejam/qlcqt6/ui'
make: *** [Makefile:141: sub-ui-make_first-ordered] Error 2
User avatar
edogawa
Posts: 572
Joined: Thu May 07, 2015 10:34 am
Real Name: Edgar Aichinger

You can disable this specific warning being handled as error, by changing in variables.pri line 19 to:

Code: Select all

QMAKE_CXXFLAGS += -Werror -Wno-sign-compare
as this is buried inside Qt6 code... I was hit by the same error and with this change it continues to build.

Can't say for sure what this implies but as it's deep inside qt6 code, there's no other way to pass that warning/error currently, afaics.
User avatar
mcallegari
Posts: 4482
Joined: Sun Apr 12, 2015 9:09 am
Location: Italy
Real Name: Massimo Callegari
Contact:

i have successfully built QLC+ on Qt 6.2.3 on Ubuntu 20.04
Can't remember the GCC version right now.

I hope you're just experimenting, cause I cannot guaranteee anything on Qt6 at the moment
I haven't finished to review all the multimedia changes on every platform
User avatar
sbenejam
Posts: 550
Joined: Sun Apr 12, 2015 6:28 pm
Real Name: Santiago Benejam Torres
Contact:

Hi Massimo. I tried to compile with Qt 6 before and it always failed. I saw your commits to build with Qt6 in Git and did some testing. With Qt5.15.2 builds as expected.
User avatar
sbenejam
Posts: 550
Joined: Sun Apr 12, 2015 6:28 pm
Real Name: Santiago Benejam Torres
Contact:

I forgot to mention, I switched to Pipewire on Ubuntu 20.04 in my main laptop and on a spare laptop with Ubuntu 21.04 and all audio part seems to work well with QLC+ 4.12.5-GIT.
User avatar
sbenejam
Posts: 550
Joined: Sun Apr 12, 2015 6:28 pm
Real Name: Santiago Benejam Torres
Contact:

I had built QLC+ with Qt 6.2.3, audio don't work I have not tested anything else except that the NanoKontrol2 is working.
User avatar
mcallegari
Posts: 4482
Joined: Sun Apr 12, 2015 9:09 am
Location: Italy
Real Name: Massimo Callegari
Contact:

Audio playback on Linux is working now with Qt 6.4.1.
On Windows there's been a regression, so audio on Qt 6.4.0 should work while on 6.4.1 it doesn't. To be tested again when 6.4.2 is released on January 12th.
User avatar
sbenejam
Posts: 550
Joined: Sun Apr 12, 2015 6:28 pm
Real Name: Santiago Benejam Torres
Contact:

I tested building QLC+ 4.12.7 GIT with Qt6.4.1 on Ubuntu 22.04.
The audio play works. I create too some audio sinks in pipewire and this sinks are visible in QLC+ as audio devices that I can use to route in pipewire to desired audio output or insert audio plugins between sink and audio output.

I tested too video playing and is working too, only a little detail mpeg videos in function editor are not showing the resolution, shows 0x0, but mpeg videos are played correctly. Mp4 videos are showing the correct video resolution and are played correctly too.

The OSC plugin it's working too, I tested with a TouchOSC MK2 template that I'm building for controlling QLC+ widgets, I'll share this template when I get it complete. Using my 2 Nanokontrol2 seems to work as expected too.

I couldn't test DMX USB and Artnet DMX devices, I'll try tomorrow if I have a moment.
Post Reply