-
Notifications
You must be signed in to change notification settings - Fork 147
/
Copy pathINSTALL
95 lines (61 loc) · 2.59 KB
/
INSTALL
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
Installation, Dependencies and Compatibility
============================================
.. contents::
:local:
Dependencies
^^^^^^^^^^^^
most of functionality
______________________
+ six https://pypi.python.org/pypi/six/
+ pyglet https://github.com/pyglet/pyglet
particles support
_________________
+ numpy www.numpy.org
audio and video support by pyglet and ffmpeg
____________________________________________
+ for Windows and Mac the simplest is 'python -m pip install pyglet-ffmpeg2'
+ for Linux you should use your package manager to get ffmpeg, version 4.x or 5.x is the one tested with pyglet.
support for extra image file formats
____________________________________
+ python -m pip install pillow
+ if using pyglet < 1.5.9 then must be pillow<8
+ in windows, if using python > 3.9, pillow>8 and pyglet>=1.5.9 is needed
audio support by SDL
____________________
+ in Windows, pygame http://www.pygame.org
+ in unix-like OSes libraries sdl 1.2 and sdl-mixer 1.2; in debian/ubuntu their packages are libsdl1.2 and libsdl-mixer1.2
+ in Mac, there's no confirmed info. Should be similar to unix.
What explicit dependencies are declared in the setup.py ?
six and pyglet
Compatibility
^^^^^^^^^^^^^
Compatibility notes at the time of writing, July 2023
+ python : cocos needs python 3.6+ (2.7 and 3.3+ should still work but is unsupported)
+ pyglet : pyglet >= 1.4.10, < 2.0
+ Just for reference, pyglet 1.5.27, the last released pyglet in the 1.5.x series (atm) works fine.
+ cocos is not compatible with pyglet 2+
Installing
^^^^^^^^^^
Have a modern setuptools or pip installed.
While::
python -m pip install cocos2d
works, you will miss the docs and code samples. Its is therefore recommended to
+ install six and pyglet, pay attention to the pyglet version, see above
+ download cocos2d-0.6.10.zip (or cocos2d-0.6.10.tar.gz )
+ from https://pypi.python.org/pypi/cocos2d/
+ decompress to a convenient location, the top dir will be cocos2d-0.6.10
+ the html docs will be in cocos2d-0.6.10/doc/html
+ useful code samples will be in cocos2d-0.6.10/test, cocos2d-0.6.10/samples, cocos2d-0.6.10/utest
+ install by::
cd cocos2d-0.6.10
python -m pip install -e .
or alternatively by pointing that directory from a .pth or PYTHONPATH
+ All of cocos should be usable now, with the possible exceptions
- cocos particles
- SDL audio backend
- ffmpeg audio-video backend
If you want to add these, look at the dependencies section.
Using PYTHONPATH or .pth
^^^^^^^^^^^^^^^^^^^^^^^^
It is safe to point a checkout of cocos from a .pth or PYTHONPATH
The same is valid for pyglet.