Fix build with Qt 5.9
ClosedPublic

Authored by wbauer on Apr 23 2020, 2:51 PM.

Details

Summary

qsizetype is only defined starting with Qt 5.10.
To avoid a compiler error, conditionally define it appropriately for older Qt versions (the actual line is copied from Qt 5.10's qglobal.h).

Test Plan

Together with commit aee9e90c1ce0257d12ea85029435db8ffa65a6a1 , compilation with Qt 5.9.7 succeeds now, still builds fine with newer versions as well (tested 5.12.7 and 5.14.1)

Before, I got this compiler error:

[  128s] In file included from /home/abuild/rpmbuild/BUILD/tellico-3.3/src/gui/imagewidget.cpp:27:0:
[  128s] /home/abuild/rpmbuild/BUILD/tellico-3.3/src/gui/../images/image.h:62:3: error: 'qsizetype' does not name a type; did you mean 'iswctype'?
[  128s]    qsizetype byteSize() const;
[  128s]    ^~~~~~~~~
[  128s]    iswctype

Diff Detail

Repository
R470 Tellico
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
wbauer requested review of this revision.Apr 23 2020, 2:51 PM
wbauer created this revision.
wbauer added a reviewer: rstephenson.
wbauer added a project: Tellico.
wbauer edited the summary of this revision. (Show Details)Apr 23 2020, 3:18 PM
wbauer edited the summary of this revision. (Show Details)Apr 23 2020, 3:29 PM
wbauer edited the test plan for this revision. (Show Details)Apr 23 2020, 4:19 PM
wbauer edited the summary of this revision. (Show Details)Apr 23 2020, 4:58 PM
rstephenson accepted this revision.Apr 23 2020, 9:26 PM

Good catch, thanks for the patch. Please commit

This revision is now accepted and ready to land.Apr 23 2020, 9:26 PM
This revision was automatically updated to reflect the committed changes.