annotate config.py @ 3182:0c07af110477 docs-changes

Ignore Sphinx-generated files
author Thomas Kluyver <takowl@gmail.com>
date Wed, 09 Jan 2013 22:35:43 +0000
parents 55a175eb7c7b
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
26
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
1 #!/usr/bin/env python
916
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
2 # For MinGW build requires Python 2.4 or better and win32api.
26
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
3
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
4 """Quick tool to help setup the needed paths and flags
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
5 in your Setup file. This will call the appropriate sub-config
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
6 scripts automatically.
50
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
7
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
8 each platform config file only needs a "main" routine
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
9 that returns a list of instances. the instances must
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
10 contain the following variables.
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
11 name: name of the dependency, as references in Setup (SDL, FONT, etc)
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
12 inc_dir: path to include
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
13 lib_dir: library directory
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
14 lib: name of library to be linked to
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
15 found: true if the dep is available
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
16 cflags: extra compile flags
26
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
17 """
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
18
916
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
19 import msysio
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
20 import mingwcfg
1553
ebd545641c8b merging with python3 branch r 2048
Lenard Lindstrom <len-l@telus.net>
parents: 1453
diff changeset
21 import sys, os, shutil
50
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
22
916
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
23 def print_(*args, **kwds):
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
24 """Simular to the Python 3.0 print function"""
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
25 # This not only supports MSYS but is also a head start on the move to
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
26 # Python 3.0. Also, this function can be overridden for testing.
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
27 msysio.print_(*args, **kwds)
26
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
28
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
29 def confirm(message):
50
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
30 "ask a yes/no question, return result"
916
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
31 reply = msysio.raw_input_("\n%s [Y/n]:" % message)
1553
ebd545641c8b merging with python3 branch r 2048
Lenard Lindstrom <len-l@telus.net>
parents: 1453
diff changeset
32 if reply and reply[0].lower() == 'n':
ebd545641c8b merging with python3 branch r 2048
Lenard Lindstrom <len-l@telus.net>
parents: 1453
diff changeset
33 return False
ebd545641c8b merging with python3 branch r 2048
Lenard Lindstrom <len-l@telus.net>
parents: 1453
diff changeset
34 return True
26
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
35
916
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
36 def is_msys_mingw():
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
37 """Return true if this in an MinGW/MSYS build
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
38
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
39 The user may prompted for confirmation so only call this function
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
40 once.
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
41 """
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
42 if msysio.is_msys():
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
43 return 1
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
44 if ('MINGW_ROOT_DIRECTORY' in os.environ or
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
45 os.path.isfile(mingwcfg.path)):
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
46 return confirm("Is this an mingw/msys build")
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
47 return 0
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
48
50
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
49 def prepdep(dep, basepath):
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
50 "add some vars to a dep"
807
3b0f4ccf23c4 Patches from Marcus for scrap. This gets windows bitmap support working.
Rene Dudfield <renesd@gmail.com>
parents: 585
diff changeset
51 if dep.libs:
3b0f4ccf23c4 Patches from Marcus for scrap. This gets windows bitmap support working.
Rene Dudfield <renesd@gmail.com>
parents: 585
diff changeset
52 dep.line = dep.name + ' ='
3b0f4ccf23c4 Patches from Marcus for scrap. This gets windows bitmap support working.
Rene Dudfield <renesd@gmail.com>
parents: 585
diff changeset
53 for lib in dep.libs:
3b0f4ccf23c4 Patches from Marcus for scrap. This gets windows bitmap support working.
Rene Dudfield <renesd@gmail.com>
parents: 585
diff changeset
54 dep.line += ' -l' + lib
356
e881b3e4f886 big config.py update
pygame
parents: 302
diff changeset
55 else:
e881b3e4f886 big config.py update
pygame
parents: 302
diff changeset
56 dep.line = dep.name + ' = -I.'
e881b3e4f886 big config.py update
pygame
parents: 302
diff changeset
57
56
a9f972d99300 config update
pygame
parents: 50
diff changeset
58 dep.varname = '$('+dep.name+')'
a9f972d99300 config update
pygame
parents: 50
diff changeset
59
50
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
60 if not dep.found:
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
61 if dep.name == 'SDL': #fudge if this is unfound SDL
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
62 dep.line = 'SDL = -I/NEED_INC_PATH_FIX -L/NEED_LIB_PATH_FIX -lSDL'
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
63 dep.varname = '$('+dep.name+')'
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
64 dep.found = 1
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
65 return
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
66
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
67 inc = lid = lib = ""
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
68 if basepath:
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
69 if dep.inc_dir: inc = ' -I$(BASE)'+dep.inc_dir[len(basepath):]
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
70 if dep.lib_dir: lid = ' -L$(BASE)'+dep.lib_dir[len(basepath):]
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
71 else:
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
72 if dep.inc_dir: inc = ' -I' + dep.inc_dir
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
73 if dep.lib_dir: lid = ' -L' + dep.lib_dir
807
3b0f4ccf23c4 Patches from Marcus for scrap. This gets windows bitmap support working.
Rene Dudfield <renesd@gmail.com>
parents: 585
diff changeset
74 libs = ''
3b0f4ccf23c4 Patches from Marcus for scrap. This gets windows bitmap support working.
Rene Dudfield <renesd@gmail.com>
parents: 585
diff changeset
75 for lib in dep.libs:
3b0f4ccf23c4 Patches from Marcus for scrap. This gets windows bitmap support working.
Rene Dudfield <renesd@gmail.com>
parents: 585
diff changeset
76 libs += ' -l' + lib
907
2d530d8fe54f In build process merged Setup.in and Setup_win.in
Lenard Lindstrom <len-l@telus.net>
parents: 896
diff changeset
77
2d530d8fe54f In build process merged Setup.in and Setup_win.in
Lenard Lindstrom <len-l@telus.net>
parents: 896
diff changeset
78 if dep.name.startswith('COPYLIB_'):
2d530d8fe54f In build process merged Setup.in and Setup_win.in
Lenard Lindstrom <len-l@telus.net>
parents: 896
diff changeset
79 dep.line = dep.name + libs + lid
2d530d8fe54f In build process merged Setup.in and Setup_win.in
Lenard Lindstrom <len-l@telus.net>
parents: 896
diff changeset
80 else:
2d530d8fe54f In build process merged Setup.in and Setup_win.in
Lenard Lindstrom <len-l@telus.net>
parents: 896
diff changeset
81 dep.line = dep.name+' =' + inc + lid + ' ' + dep.cflags + libs
50
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
82
1453
401c014117ad Removing PyObjC dependency
brian
parents: 916
diff changeset
83 def writesetupfile(deps, basepath, additional_lines):
50
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
84 "create a modified copy of Setup.in"
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
85 origsetup = open('Setup.in', 'r')
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
86 newsetup = open('Setup', 'w')
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
87 line = ''
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
88 while line.find('#--StartConfig') == -1:
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
89 newsetup.write(line)
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
90 line = origsetup.readline()
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
91 while line.find('#--EndConfig') == -1:
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
92 line = origsetup.readline()
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
93
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
94 if basepath:
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
95 newsetup.write('BASE = ' + basepath + '\n')
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
96 for d in deps:
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
97 newsetup.write(d.line + '\n')
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
98
1453
401c014117ad Removing PyObjC dependency
brian
parents: 916
diff changeset
99 lines = origsetup.readlines()
1981
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
100
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
101 # overwrite lines which already exist with new ones.
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
102 new_lines = []
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
103 for l in lines:
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
104 addit = 1
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
105 parts = l.split()
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
106 for al in additional_lines:
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
107 aparts = al.split()
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
108 if aparts and parts:
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
109 if aparts[0] == parts[0]:
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
110 #print ('the same!' + repr(aparts) + repr(parts))
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
111 #the same, we should not add the old one.
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
112 #It will be overwritten by the new one.
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
113 addit = 0
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
114 if addit:
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
115 new_lines.append(l)
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
116
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
117 new_lines.extend(additional_lines)
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
118 lines = new_lines
07cbe94f9ece Config from platform specific overwrites original if first word is the same.
Rene Dudfield <renesd@gmail.com>
parents: 1907
diff changeset
119
1453
401c014117ad Removing PyObjC dependency
brian
parents: 916
diff changeset
120 for line in lines:
50
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
121 useit = 1
59
22592aa68c3e smarter config
pygame
parents: 56
diff changeset
122 if not line.startswith('COPYLIB'):
22592aa68c3e smarter config
pygame
parents: 56
diff changeset
123 for d in deps:
22592aa68c3e smarter config
pygame
parents: 56
diff changeset
124 if line.find(d.varname)!=-1 and not d.found:
22592aa68c3e smarter config
pygame
parents: 56
diff changeset
125 useit = 0
22592aa68c3e smarter config
pygame
parents: 56
diff changeset
126 newsetup.write('#'+line)
22592aa68c3e smarter config
pygame
parents: 56
diff changeset
127 break
487
6e27a089e7c7 Removed legacy OS X support
bob
parents: 359
diff changeset
128 if useit:
1453
401c014117ad Removing PyObjC dependency
brian
parents: 916
diff changeset
129 newsetup.write(line)
50
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
130
26
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
131 def main():
1453
401c014117ad Removing PyObjC dependency
brian
parents: 916
diff changeset
132 additional_platform_setup = []
1553
ebd545641c8b merging with python3 branch r 2048
Lenard Lindstrom <len-l@telus.net>
parents: 1453
diff changeset
133 if (sys.platform == 'win32' and
ebd545641c8b merging with python3 branch r 2048
Lenard Lindstrom <len-l@telus.net>
parents: 1453
diff changeset
134 # Note that msys builds supported for 2.6 and greater. Use prebuilt.
ebd545641c8b merging with python3 branch r 2048
Lenard Lindstrom <len-l@telus.net>
parents: 1453
diff changeset
135 (sys.version_info >= (2, 6) or not is_msys_mingw())):
916
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
136 print_('Using WINDOWS configuration...\n')
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
137 import config_win as CFG
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
138 elif sys.platform == 'win32':
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
139 print_('Using WINDOWS mingw/msys configuration...\n')
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
140 import config_msys as CFG
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
141 elif sys.platform == 'darwin':
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
142 print_('Using Darwin configuration...\n')
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
143 import config_darwin as CFG
1907
b8387770f9f6 python3.1 support for OSX.
Rene Dudfield <renesd@gmail.com>
parents: 1553
diff changeset
144 additional_platform_setup = open("Setup_Darwin.in", "r").readlines()
916
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
145 else:
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
146 print_('Using UNIX configuration...\n')
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
147 import config_unix as CFG
2124
55a175eb7c7b reenable the camera module for linux
Nirav Patel <nrp@eclecti.cc>
parents: 1981
diff changeset
148 additional_platform_setup = open("Setup_Unix.in", "r").readlines()
916
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
149
26
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
150 if os.path.isfile('Setup'):
542
b98b1f4576e0 psuedo Makefile and configure
pygame
parents: 487
diff changeset
151 if "-auto" in sys.argv or confirm('Backup existing "Setup" file'):
26
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
152 shutil.copyfile('Setup', 'Setup.bak')
542
b98b1f4576e0 psuedo Makefile and configure
pygame
parents: 487
diff changeset
153 if not "-auto" in sys.argv and os.path.isdir('build'):
26
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
154 if confirm('Remove old build directory (force recompile)'):
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
155 shutil.rmtree('build', 0)
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
156
50
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
157 deps = CFG.main()
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
158 if deps:
122
1c2fef5eb63a distutil touch ups
pygame
parents: 59
diff changeset
159 basepath = None
50
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
160 for d in deps:
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
161 prepdep(d, basepath)
1453
401c014117ad Removing PyObjC dependency
brian
parents: 916
diff changeset
162 writesetupfile(deps, basepath, additional_platform_setup)
916
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
163 print_("""\nIf you get compiler errors during install, doublecheck
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
164 the compiler flags in the "Setup" file.\n""")
50
fb807c52437f surfarray cleanups
pygame
parents: 26
diff changeset
165 else:
916
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
166 print_("""\nThere was an error creating the Setup file, check for errors
8a7d9b2de067 MinGW/MSYS build process more automated and DLLs Win32 GUI by default
Lenard Lindstrom <len-l@telus.net>
parents: 907
diff changeset
167 or make a copy of "Setup.in" and edit by hand.""")
359
86649d342371 cleanups, especially for win32
pygame
parents: 356
diff changeset
168
26
6c23d683c30f ready for 0.3 (need more testing on new config.py)
pygame
parents:
diff changeset
169 if __name__ == '__main__': main()