In macOS 11 (which comes pre-installed on new Macs), stack/GHC fails building anything using OpenGL or other system frameworks (GHC bug #18446).
It's already fixed in GHC HEAD, but not in any currently released version of GHC yet.
However the problem is work-aroundable. I already work around it using a DYLD_INSERT_LIBRARIES= library inserted to stack to emulate the behavior that GHC relied on.
But the workaround can be integrated into stack itself and then people won't need to even know about the problem in the first place!
If integrated into stack, the work-around can be more focused with DYLD_INSERT_LIBRARIES= done only to GHC and having a simpler implementation than my current one (which contains efforts to make sure that its hooking propagates from stack to the actual ghc being run within it)
In macOS 11 (which comes pre-installed on new Macs), stack/GHC fails building anything using OpenGL or other system frameworks (GHC bug #18446).
It's already fixed in GHC HEAD, but not in any currently released version of GHC yet.
However the problem is work-aroundable. I already work around it using a
DYLD_INSERT_LIBRARIES=library inserted tostackto emulate the behavior that GHC relied on.But the workaround can be integrated into
stackitself and then people won't need to even know about the problem in the first place!If integrated into
stack, the work-around can be more focused withDYLD_INSERT_LIBRARIES=done only to GHC and having a simpler implementation than my current one (which contains efforts to make sure that its hooking propagates fromstackto the actualghcbeing run within it)