qtbase5-dev 5.15 seems not incompatible with X11 on debian11
-
Env:
lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 11 (bullseye)
Release: 11
Codename: bullseye
qtbase5-dev/stable,now 5.15.2+dfsg-9 amd64 [installed]Hi everyone.I met a compile issue on qtbase5-dev 5.15 and there is no issue on qtbase5-dev 5.12 .Seems None is defined in enum type on qactiongroup.h:64 and there is anothor None MACRO def in /usr/include/X11/X.h which caused conflict.
The error list as below:
In file included from /usr/include/X11/Xlib.h:44,
from /usr/include/X11/extensions/Xfixes.h:52,
from /code/src/hdx/gfx/gfxindicator/main.cpp:15:
/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qactiongroup.h: At global scope:
/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qactiongroup.h:64:9: error: expected identifier before numeric constant
64 | None,
| ^~~~
/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qactiongroup.h:64:9: error: expected '}' before numeric constant
In file included from /usr/include/x86_64-linux-gnu/qt5/QtWidgets/qaction.h:221,
from /usr/include/x86_64-linux-gnu/qt5/QtWidgets/QAction:1,
I'd appreciate any help!Thanks!
-
Undef the macro after you included the X11 headers or include the headers after the Qt headers or don't include them at all.
-
Undef the macro after you included the X11 headers or include the headers after the Qt headers or don't include them at all.
@Christian-Ehrlicher many thanks just using undef to avoid this issue