Qt, QGLWidget and Xcode 11 = fail?



  • Hi all. So we have this app. It has a QGLWidget rendering on a separate thread for video. This has been working fine through Mac OS Mojave.
    Here comes Catalina. We take our latest build r2330, it was build in Xcode 10. It still work fine in Catalina. Somewhere along the way Xcode updated to 11 on both my Mojave dev machine and Catalina (bootcamp). I can still compile and run it on Mojave. However, if I compile run it in Catalina, or even export and package it on Mojave, then run in Catalina, I get this GLContext crash (EXC_BAD_INSTRUCTION) when the thread tries to start.
    I realize that OpenGL is now completely removed from Catalina but it's my understanding Qt has taken care of this (app is based on 5.12.0 BTW, I have also tried 5.13.1) and that makes sense since older versions (2330 built on Xcode 10 and even our last major version based on 5.9.6 run just fine on Catalina.
    So, the only factor that has changed here is Xcode (and I assume that means Base SDK!)
    I don't get it. I'm at a loss here. Why?! We even tried opening a technical support ticket with Apple as this still feels like early Catalina problems (we ran through a LOT of them turning out to be Apple) and they seem to want to push this back on Qt, so I'm putting this her pin case anyone has ideas. Still looking for the button to attach my crash report. ;)



  • I have a similar crash with a Qt3DQuickWindow. Before Catalina this was reported as a warning but now it causes a crash:

    Crashed Thread: 44 Qt3DRender::Render::RenderThread

    Exception Type: EXC_BAD_INSTRUCTION (SIGILL)
    Exception Note: EXC_CORPSE_NOTIFY

    Application Specific Information:
    -[NSOpenGLContext setView:] must be called from the main thread.

    I'm guessing this is the same problem right?


  • Lifetime Qt Champion

    Hi,

    I would rather bring this to the internet mailing list. You'll find there Qt's developers/maintainers. This forum is more user oriented.

    As for the crash report, you should check the bug report system.



  • Do you have to use XCode? Have you tried other OpenGL libraries and a different C++ compiler?


  • Lifetime Qt Champion

    @CroCo Xcode is the only officially supported compiler on macOS.



  • @SGaist what do you mean? Other C++ compilers can't guarantee same performance, I'm talking about g++.


  • Lifetime Qt Champion

    I mean that Qt is built and tested only with Xcode as it is the only officially supported compiler on macOS.

    Other compilers may work, however, they are not supported.



  • But this is "Qt Development" forum no? I don't know that it's a bug, I think it's Apple and was asking in case there was just a config or some other thing I had to do to get around it.
    I do have an update. The problem is the new SDK. If I go back to a carbon copy backup I have with Xcode 10 (therefore 10.14 SDK) and build, I can run the built package in Catalina too. If I build on Xcode 11 (so SDK 10.15) it builds and runs on Mojave, but has the crash on Catalina. The problem appears to be a bug in SDK 10.15, or a compatibility issue between Qt and SDK 10.15


Log in to reply