Solved Can't Build QT on Monterey: qiosurfacegraphicsbuffer.h:54:32: error: unknown type name 'CGColorSpaceRef'; did you mean 'QColorSpace'?
-
I'm on MacOS 12.2.1 with QT 5.15.2.
I get these errors when I try to build QT.
qiosurfacegraphicsbuffer.h:54:32: error: unknown type name 'CGColorSpaceRef'; did you mean 'QColorSpace'?
qiosurfacegraphicsbuffer.mm:90:32: error: out-of-line definition of 'setColorSpace' does not match any declaration in 'QIOSurfaceGraphicsBuffer'
Here's the complete output.
https://pastebin.com/raw/R9zdmdN9
I'd appreciate any help!
Thanks! -
Hi,
Which version of Xcode are you using ?
With which SDK ? -
@SGaist Thanks for your reply. I'm using xcode 13.2.1.
How do I find out which sdk I'm using? -
@SGaist said in Can't Build QT on Monterey: qiosurfacegraphicsbuffer.h:54:32: error: unknown type name 'CGColorSpaceRef'; did you mean 'QColorSpace'?:
which SDK
xcrun -sdk macosx --show-sdk-path
It says MacOSX12.1.sdk -
Hi, had the same issue.
This helped me:
https://codereview.qt-project.org/c/qt/qtbase/+/378706
Also following this:
https://wiki.qt.io/Building_Qt_5_from_Git
And exclude qtwebengine from the build, this does not work with 5.15.2 anymore.Best Regards.
Erik -
@erikmiers how do apply that patch? I did exclude webengine when building.
-
v6.3.0-beta2 builds without an error on Monterey 12.2.1 Xcode 13.2.1.