Quantcast
Channel: Cocos Forums - Latest topics
Viewing all articles
Browse latest Browse all 17076

Setup cocos2d-x on Mac

$
0
0

@flaxe wrote:

How to setup cmake to build cocos2d-x test application from command line, not from XCode?

cocos new cocos-test -p test -l cpp -d ~/Projects
cd ~/Projects/cocos-test
cmake .
make

Returns errors with Apple Foundation classes:

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


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

This problem exists in the last version 3.9, but not reproduced on 3.7.
Can this be fixed? Because it is very frustrating for newbies like me)

Posts: 8

Participants: 3

Read full topic


Viewing all articles
Browse latest Browse all 17076

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>