Bug 415081 - Increase minimum required Qt version to 5.11
Summary: Increase minimum required Qt version to 5.11
Status: RESOLVED FIXED
Alias: None
Product: Rocs
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Neon Linux
: NOR normal
Target Milestone: ---
Assignee: Rocs Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-12-12 06:20 UTC by Juan Carlos Torres
Modified: 2019-12-13 17:45 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Juan Carlos Torres 2019-12-12 06:20:30 UTC
SUMMARY

Commit c44c4ae2 (https://cgit.kde.org/rocs.git/commit/?id=c44c4ae2baf149a0517b59844a6a9d44160e9056) introduced the QFontMetrics::horizontalAdvance method that was added only in Qt 5.11 (https://doc.qt.io/qt-5/qfontmetrics.html#horizontalAdvance). The ROCS CMakeLists.txt still lists 5.4 as the required minimum version so it fails to build with anything lower than 5.11.

STEPS TO REPRODUCE
1. Have a system with Qt 5.10 or older
2. Run cmake (works correctly)
3. Run make

OBSERVED RESULT

Error in compiling: ‘class QFontMetrics’ has no member named ‘horizontalAdvance’     const int charWidth = fm.horizontalAdvance(QLatin1Char('x'));   

EXPECTED RESULT

CMake should fail when using any Qt version older than 5.11.

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
Comment 1 Andreas Cord-Landwehr 2019-12-13 17:45:12 UTC
Git commit 765c85bac6abbf659c2201f870f1ae5f6ac624d0 by Andreas Cord-Landwehr.
Committed on 13/12/2019 at 17:43.
Pushed by cordlandwehr into branch 'master'.

Set minimal Qt version according to used Qt API to 5.11

M  +1    -1    CMakeLists.txt

https://invent.kde.org/kde/rocs/commit/765c85bac6abbf659c2201f870f1ae5f6ac624d0