Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Qt6 (as well as Qt5) #261

Merged
merged 1 commit into from
Mar 15, 2024
Merged

Add support for Qt6 (as well as Qt5) #261

merged 1 commit into from
Mar 15, 2024

Conversation

chewi
Copy link
Contributor

@chewi chewi commented Mar 14, 2024

No actual code changes were necessary.

I have partly followed https://doc.qt.io/qt-6/cmake-qt5-and-qt6-compatibility.html, but the versionless targets only work from Qt 5.15 onwards. The suggested workaround chooses 5 over 6 and does not appear to work properly when one of the required components is missing. Using the versionless approach with an additional variable for the targets seems to work best.

If necessary, Qt 5 can be forced over 6 by passing -DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON.

I have tested this by tweaking the code to force the GUI to appear.

No actual code changes were necessary.

I have partly followed
https://doc.qt.io/qt-6/cmake-qt5-and-qt6-compatibility.html, but the
versionless targets only work from Qt 5.15 onwards. The suggested
workaround chooses 5 over 6 and does not appear to work properly when
one of the required components is missing. Using the versionless
approach with an additional variable for the targets seems to work best.

If necessary, Qt 5 can be forced over 6 by passing
`-DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON`.

I have tested this by tweaking the code to force the GUI to appear.
@Sude- Sude- merged commit 5cca5da into Sude-:master Mar 15, 2024
4 checks passed
@chewi chewi deleted the qt6 branch March 15, 2024 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants