File: bdist_mpkg_support.py

package info (click to toggle)
pygame 1.9.1release%2Bdfsg-10
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd, stretch
  • size: 7,280 kB
  • ctags: 6,685
  • sloc: ansic: 41,205; python: 21,987; cpp: 537; objc: 196; php: 92; sh: 77; makefile: 41
file content (36 lines) | stat: -rw-r--r-- 1,031 bytes parent folder | download | duplicates (2)
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
# only enable bdist_mpkg if it's installed already
import pkg_resources
try:
    pkg_resources.require('bdist_mpkg>=0.4.2')
except pkg_resources.DistributionNotFound:
    raise ImportError

try:
    unicode
except NameError:
    def unicode(s):
        return s

FRAMEWORKS = ['SDL', 'SDL_ttf', 'SDL_image', 'SDL_mixer', 'smpeg']

CUSTOM_SCHEMES = dict(
    examples=dict(
        description=unicode('(Optional) pygame example code'),
        prefix='/Developer/Python/pygame/Examples',
        source='examples',
    ),
    docs=dict(
        description=unicode('(Optional) pygame documentation'),
        prefix='/Developer/Python/pygame/Documentation',
        source='docs',
    ),
)

for framework in FRAMEWORKS:
    CUSTOM_SCHEMES[framework] = dict(
        description=unicode('(Required) %s.framework') % (framework,),
        prefix='/Library/Frameworks/%s.framework' % (framework,),
        source='/Library/Frameworks/%s.framework' % (framework,),
    )

options = dict(bdist_mpkg=dict(custom_schemes=CUSTOM_SCHEMES))