So I recently wanted to try out Unix Make or Ninja for building my cocos2d-x game, instead of as an Xcode project, using CMake for generating the Unix Make and Ninja files.
However, a fraction through the build process, it fails, giving me this message:
error: Objective-C was disabled in PCH file but is currently enabled
This is the file it was trying to build:
cocos2d/cocos/platform/apple/CCFileUtils-apple.mm
I’m assuming that it has something to do with Objective-C.
Now, I read the documentation of cocos2d-x 4.x and I’m aware of the fact that the Cocos2D team recommends us to use “Xcode” as the generator with CMake. Xcode as the generator works perfectly. However, I’m trying out Ninja and Make just out of curiosity. I mean, macOS is Unix-based and we should be able to use Make and Ninja just fine.
Is there any way to resolve this issue?