[LyX/master] Allow compiling with Qt6
Stephan Witt
st.witt at gmx.net
Tue Mar 16 07:01:33 UTC 2021
Am 16.03.2021 um 07:38 schrieb Andreas Nicolai <andreas.nicolai at gmx.net>:
>
> Hi All,
>
> just looked into Qt6 for another project of mine and noticed that there
> is actually nothing in Qt6 new, that's really needed. Same for Lyx - or
> is there really any feature of Qt6 necessary?
Hi Andreas,
thank you for your mail.
> So, I was wondering - Lyx is being used by a lot of people with not so
> brand-new notebooks, and hardware, that won't even support upgrading to
> newer os (talk about the older Macs for example, and quite a few 6
> +years Linux boxes). Now, Qt6 has a compatibility limit and some of
> these systems won't be able to run Lyx anylonger.
>
> My suggestions would be to make Qt6 compilation an optional thing, but
> keep code compilable with at least a sufficiently "old" and supported Qt
> version.
Yes, LyX will be compilable with older Qt versions in the future.
> In my other projects we have set MacOS El Capitan as compability limit,
> and the newest Qt version running on that system appears to be 5.11.3.
> So, that's what we stick to during development and, honestly, a lot of
> the newer features of Qt (or bug fixes) aren't really needed.
That’s interesting. My plan was to go with the LTS versions of Qt.
So I had the plan to use either 5.9.x or 5.12.x. I noticed already
the incompatibility of 5.12.x with El Capitan. What can you say
about the pros and cons of Qt 5.11 versus Qt 5.12? Are you confident
with 5.11?
> How about Lyx? Given the rather solid and standard Qt feature set used
> in Lyx, why not impose such a compatibility limit as well (at least let
> the code be compiling on those systems)? In case this is already
> considered, just ignore my rambling :-)
The option to compile LyX with elder Qt versions is one point. The other
question is wich version to use for regular package distribution. Here
we had some discussion in the past. I tend to be conservative here and
use the version usable on elder systems too.
Stephan
> Anyway, just a though...
>
> -Andreas
>
> Am 16.03.21 um 03:52 schrieb Scott Kostyshak:
>> On Mon, Mar 15, 2021 at 05:33:49PM +0100, Enrico Forestieri wrote:
>>> commit 635a7d77ddc94c63d52494dc4d68a930faccf45f
>>> Author: Enrico Forestieri <forenr at lyx.org>
>>> Date: Mon Mar 15 17:09:09 2021 +0100
>>>
>>> Allow compiling with Qt6
>>>
>>> This commit allows compiling LyX with Qt6 when using autotools.
>>> For a successful compilation the following 2 conditions must be met.
>>>
>>> 1) The Qt6 qmake has to come first in PATH, so that the command
>>> "qmake -v | grep -o 'Qt version .'" returns "Qt version 6".
>>> 2) The --enable-qt6 switch has to be passed to the configure command.
>>>
>>> If --enable-qt6 is used but Qt6 is not found, Qt5 is tried as a fallback.
>>> If also Qt5 is not found, configuring for Qt4 is attempted.
>>> If --enable-qt6 is not used, then things go as usual. This means that Qt5
>>> is tried first and then Qt4, unless --disable-qt5 is used, in which case
>>> Qt4 is directly attempted. This means that existing scripts should
>>> continue working unmodified.
>>>
>>> LyX should compile with Qt6 on windows and linux, and possibly also on
>>> mac, but I could not test that. However, it is not guaranteed that it
>>> works as it should. In particular I am not sure that I got right the
>>> conversion from QRegExp to QRegularExpression. For sure, the syntax
>>> highlighting seems to not work right. Someone in the know should take
>>> a look at that. I am able to load documents and compile them but some
>>> thourough testing is needed. However, when compiling for Qt5 or Qt4,
>>> I tried to make sure that the functionality is preserved.
>>> ---
>>
>> Are there still QRegExp that need to be changed? I got an error from
>> src/support/qstring_helpers.cpp.
>>
>> Also, why use
>>
>> #include <QtCore5Compat/QRegExp>
>>
>> in CategorizedCombo.cpp, but not other places?
>>
>> Scott
>>
>>
>
> --
> lyx-devel mailing list
> lyx-devel at lists.lyx.org
> http://lists.lyx.org/mailman/listinfo/lyx-devel
More information about the lyx-devel
mailing list