Unknown type name 'NSPoint' when compiling with CLion on Mac

I try to build Cocos2d-x “Hello World” application on Mac.
Project normally start from the MyGame.xcodeproj or from command line:

cocos run -p mac

But when I try to build framework:

mkdir macbuild && cd macbuild
cmake -G "Unix Makefiles" -DBUILD_CPP_TESTS=OFF -DBUILD_LUA_LIBS=OFF ..
make

Or launch MyGame from CLion I have some errors with Apple classes:

In file included from cocos2d-x/cocos/ui/UIEditBox/UIEditBoxImpl-mac.mm:26:
cocos2d-x/cocos/ui/UIEditBox/UIEditBoxImpl-mac.h:90:5: error: 
    unknown type name 'NSPoint'; did you mean 'Point'?
    NSPoint    convertDesignCoordToScreenCoord(const Vec2& designCoord, ...
    ^~~~~~~

In file included from cocos2d-x/cocos/ui/UIEditBox/UIEditBoxImpl-mac.mm:26:
cocos2d-x/cocos/ui/UIEditBox/UIEditBoxImpl-mac.h:92:5: error: 
    unknown type name 'NSFont'
    NSFont*    constructFont(const char* fontName, int fontSize);
    ^

How I can fix it?

Will anybody from the cocos2d-x team actually respond properly to any of the CMAKE related threads? There have been issues with these builds for so long! Either tell us its not working yet, or tell us what we’re not getting.

Hey, did you manage to sort out your error?
@flaxe

@Nick_E No, I am using an older version 3.7 from GitHub