WidgetKit is not available when building for Mac Catalyst

I have built an iOS app that supports iOS and iPad including a Widget on iOS 14. I have enabled Mac Catalyst support. In Xcode 12 GM, I am no longer able to build for Mac Catalyst. I was able to do this in previous Xcode versions.

I get the error: "WidgetKit is not available when building for Mac Catalyst. You may need to restrict the platforms for which this framework should be linked in the target editor."

Has anyone seen this? Any way to resolve this?
It seems that Xcode 12 GM completely breaks builds of Mac Catalyst apps which have iOS 14 features. Code that would build fine in Xcode 12 beta 6 no longer builds. It's as if the GM thinks Mac Catalyst is only capable of iOS 13 features.

You can prevent the widget from being included in the Catalyst build (which probably isn't what you want): https://stackoverflow.com/questions/59795971/extension-is-not-available-when-building-for-mac-catalyst

That will get you past that particular error. But you will probably then find code that won't compile for Catalyst. Xcode complains that iOS 14 symbols just don't exist: https://developer.apple.com/forums/thread/660274?page=1#632760022
WidgetKit is not available when building for Mac Catalyst
 
 
Q