开发者

Compile errors after adding a new target to Xcode project

开发者 https://www.devze.com 2023-02-13 21:25 出处:网络
I added a new target to my project开发者_如何学Python, however when I compile, I get thousands of errors pointing to appkit.h. These are precompile errors. I have .c, .h and .m files in the project. W

I added a new target to my project开发者_如何学Python, however when I compile, I get thousands of errors pointing to appkit.h. These are precompile errors. I have .c, .h and .m files in the project. What can be the cause?

Thanks for the suggestions.


You are including AppKit.h in a C file. This is impossible as AppKit.h is an Objective-C header file.

Change all c files to m files (or force the compiler to use Objective-C).

0

精彩评论

暂无评论...
验证码 换一张
取 消