How can I resolve the xcode12.4 build error: Use of undeclared identifier '_CTYPE_A'?

I have a project that previously built for x86_64 that includes objective C, C and C++ files using Xcode 11.7. I am now trying to upgrade my project so that it will build for both arm64 and x86_64 using xcode 12.4. However, when I attempt to build, I receive many errors relating to missing "CTYPE"s as well as functions missing from the global namespace.

/Applications/Xcode12.4.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.1.sdk/usr/include/_wctype.h:53:24: Use of undeclared identifier '_CTYPE_A'

/Applications/Xcode12.4.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.1.sdk/usr/include/_wctype.h:53:33: Use of undeclared identifier '_CTYPE_D'

/Applications/Xcode12.4.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.1.sdk/usr/include/_wctype.h:71:10: Use of undeclared identifier '__istype'

/Applications/Xcode12.4.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.1.sdk/usr/include/_wctype.h:89:24: Use of undeclared identifier '_CTYPE_L'

/Applications/Xcode12.4.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.1.sdk/usr/include/_wctype.h:125:17: Use of undeclared identifier '__tolower'; did you mean 'towlower'?

/Applications/Xcode12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/cctype:103:9: No member named 'isalnum' in the global namespace; did you mean 'iswalnum'?

/Applications/Xcode12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/cctype:104:9: No member named 'isalpha' in the global namespace; did you mean 'iswalpha'?

There are more errors than this present but this is the gist of what I am seeing. It should be noted that as far as I can tell I am not using any of the functions or definitions in my code and that these errors seem to be from functions and definitions deep in the SDK.

Is there anything I should be looking for in particular to resolve these build errors? Do I need to change a project setting?

Did you ever find a solution to this? I'm having the same problem after upgrading to Xcode 16.0.

How can I resolve the xcode12.4 build error: Use of undeclared identifier '_CTYPE_A'?
 
 
Q