1. 同上篇win7中安裝的基本步驟一樣。先下載並安裝pyglet1.2alpha版本。不過請使用root權限來安裝。如果不清楚root密碼,請按如下進行密碼更改。
MacBook-Air:~ python$ sudo bash
bash-3.2# passwd root
Changing password for root.
New password:
Retype new password:
然後如圖進行安裝操作。
bash-3.2# python setup.py install
running install
running build
running build_py
running install_lib
.....
2. 下載cocos2d。最新版下載地址:https://github.com/los-cocos/cocos/archive/master.zip, 並鍵入python
setup.py install 進行安裝操作就完成了。
Installed /Library/Python/2.7/site-packages/six-1.9.0-py2.7.egg
Searching for pyglet==1.2alpha1
Best match: pyglet 1.2alpha1
Adding pyglet 1.2alpha1 to easy-install.pth file
Using /Library/Python/2.7/site-packages
Finished processing dependencies for cocos2d==0.6.0
bash-3.2#