Fwd: qt6, autoconf and lyx: help wanted
Cor Blom
cornelisbb at gmail.com
Sat Aug 26 12:11:59 UTC 2023
Hi,
Below the answer on my request for help.
osc build is what I have used throughout and what is used to build the
packages for openSUSE. Adding qt6-gui-private-devel does solve the error
and the package now builds fine.
Configure should probably fail if that library is not found.
Thanks,
Cor
-------- Doorgestuurd bericht --------
Onderwerp: Re: qt6, autoconf and lyx: help wanted
Datum: Sat, 26 Aug 2023 13:51:52 +0200
Van: Fabian Vogt <fvogt at suse.de>
Aan: factory at lists.opensuse.org
CC: Cor Blom <cornelisbb at gmail.com>
Moin,
Am Samstag, 26. August 2023, 11:00:58 CEST schrieb Cor Blom:
> Hi all,
>
> I have a problem compiling lyx against qt6, both locally on my machine
> and in the buildservice. You can find the project here:
>
> https://build.opensuse.org/package/show/home:cornelisbb:lyx-unstable/lyx-qt6
I tried to build it locally with the same ./configure and it worked fine,
only in an osc build it failed. My hypothesis was that it somehow relied on
more devel packages implicitly, maybe private headers. I patched
config/qt.m4
to not delete the test.pro file and the error became obvious:
abuild at fabians-envy:/tmp/tmp.StnZiPAtl6> qmake6 test.pro
Project ERROR: Unknown module(s) in QT: gui-private
This is because of:
qtHaveModule(gui) {QT += gui gui-private} else {MISSING +=
gui}
Does LyX really need gui-private? If not, just remove the "gui-private" part
here. If it does, use
qtHaveModule(gui-private) {QT += gui-private} else {MISSING +=
gui-private}
and add BuildRequires: qt6-gui-private-devel
There's another bug FWICT:
[ 16s] checking for QtGui/qtgui-config.h... yes
[ 16s] checking for QtGui/private/qtgui-config_p.h... no
[ 16s] checking whether Qt uses the X Window system... no
but
~> grep -R QT_FEATURE_xcb /usr/include/qt6
/usr/include/qt6/QtGui/qtgui-config.h:#define QT_FEATURE_xcb 1
Cheers,
Fabian
> I have asked the lyx devs for help, but they are baffled. It seems that
> qt6 on openSUSE behaves unexpected. It works find with cmake, though.
> (Yes, lyx supports both.)
>
> In the end I was asked to execute "qmake6 test.pro" (test.pro was a file
> they provided). It should provide a Makefile, but it did not. Nothing
> happened.
>
> Can someone provide some insight here? Are there programs in qt6 in OBS
> that use autoconf, so that I have something to compare? It seems there
> is something wrong with autoconf.
>
> The specific error is that files in the subdirectories of
> /usr/include/qt6 cannot be found. If I link the files into
> /usr/include/qt6 itself, they are found. Nothing strange is found in the
> config phase. Only during compilation. The error message is:
>
> [ 38s] GEN moc_Validator.cpp
> [ 38s] make all-am
> [ 38s] make[6]: Entering directory
> '/home/abuild/rpmbuild/BUILD/lyx-qt6-2.4.1692654261.fe74c24da9/src/frontends/qt'
> [ 38s] CXX ButtonPolicy.o
> [ 38s] CXX Dialog.o
> [ 38s] CXX DialogFactory.o
> [ 38s] CXX Action.o
> [ 38s] In file included from FindAndReplace.h:15,
> [ 38s] from DialogFactory.cpp:14:
> [ 38s] DockView.h:17:10: fatal error: QDockWidget: No such file or
> directory
> [ 38s] 17 | #include <QDockWidget>
> [ 38s] | ^~~~~~~~~~~~~
> [ 38s] In file included from Dialog.cpp:15:
> [ 38s] GuiView.h:22:10: fatal error: QMainWindow: No such file or
> directory
> [ 38s] 22 | #include <QMainWindow>
> [ 38s] | ^~~~~~~~~~~~~
> [ 38s] compilation terminated.
>
> Any help would be much appreciated.
>
> Thanks,
>
> Cor
>
More information about the lyx-devel
mailing list