]>
Commit | Line | Data |
---|---|---|
c368d904 | 1 | @echo off |
bf705731 RD |
2 | REM ---------------------------------------------------------------------- |
3 | REM Note: This is a 4NT script | |
4 | REM ---------------------------------------------------------------------- | |
c368d904 RD |
5 | setlocal |
6 | ||
7 | set FLAGS=USE_SWIG=1 IN_CVS_TREE=1 | |
8 | ||
9 | ||
10 | rem Use non-default python? | |
bf705731 | 11 | iff "%1" == "15" .or. "%1" == "20" .or. "%1" == "21" .or. "%1" == "22" then |
4309b812 | 12 | set VER=%1 |
c6b4bf32 | 13 | set PYTHON=c:\tools\python%1%\python.exe |
c368d904 RD |
14 | shift |
15 | else | |
9416aa89 RD |
16 | beep |
17 | echo You must specify Python version as first parameter. | |
18 | quit | |
c368d904 | 19 | endiff |
c6b4bf32 | 20 | set SETUP=%PYTHON% -u setup.py |
c368d904 RD |
21 | |
22 | ||
c6b4bf32 RD |
23 | %PYTHON% -c "import sys;print '\n', sys.version, '\n'" |
24 | ||
c368d904 RD |
25 | |
26 | rem "c" --> clean | |
27 | iff "%1" == "c" then | |
28 | shift | |
29 | set CMD=%SETUP% %FLAGS% clean | |
30 | set OTHERCMD=del wxPython\*.pyd | |
31 | ||
32 | rem just remove the *.pyd's | |
33 | elseiff "%1" == "d" then | |
34 | shift | |
35 | set CMD=del wxPython\*.pyd | |
36 | ||
493f1553 RD |
37 | rem touch all the *.i files so swig will regenerate |
38 | elseiff "%1" == "t" then | |
39 | shift | |
40 | set CMD=touch src\*.i & touch contrib\glcanvas\*.i & touch contrib\ogl\*.i & touch contrib\stc\*.i | |
41 | ||
c368d904 RD |
42 | rem "i" --> install |
43 | elseiff "%1" == "i" then | |
44 | shift | |
45 | set CMD=%SETUP% build install | |
46 | ||
d7ec6564 RD |
47 | rem "r" --> make installer |
48 | elseiff "%1" == "r" then | |
49 | shift | |
50 | set CMD=%PYTHON% distrib\make_installer.py | |
51 | ||
c368d904 RD |
52 | rem "s" --> source dist |
53 | elseiff "%1" == "s" then | |
54 | shift | |
55 | set CMD=%SETUP sdist | |
56 | ||
57 | rem "f" --> FINAL | |
58 | elseiff "%1" == "f" then | |
59 | shift | |
60 | set CMD=%SETUP% %FLAGS% FINAL=1 build_ext --inplace %1 %2 %3 %4 %5 %6 %7 %8 %9 | |
61 | ||
de20db99 RD |
62 | rem "h" --> HYBRID |
63 | elseiff "%1" == "h" then | |
64 | shift | |
65 | set CMD=%SETUP% %FLAGS% HYBRID=1 build_ext --inplace %1 %2 %3 %4 %5 %6 %7 %8 %9 | |
66 | ||
25832b3f RD |
67 | rem "a" --> make all installers |
68 | elseiff "%1" == "a" then | |
69 | shift | |
70 | set CMD=echo Finished! | |
25832b3f | 71 | |
25832b3f RD |
72 | call b.bat 21 c |
73 | call b.bat 21 f | |
74 | call b.bat 21 r | |
75 | call b.bat 21 c | |
76 | call b.bat 21 h | |
77 | call b.bat 21 r | |
78 | ||
4309b812 RD |
79 | call b.bat 22 c |
80 | call b.bat 22 f | |
81 | call b.bat 22 r | |
82 | call b.bat 22 c | |
83 | call b.bat 22 h | |
84 | call b.bat 22 r | |
bf705731 RD |
85 | |
86 | ||
4309b812 RD |
87 | rem "b" --> both debug and hybrid builds |
88 | elseiff "%1" == "b" then | |
89 | shift | |
90 | set CMD=echo Finished! | |
91 | call b.bat %VER% h | |
92 | call b.bat %VER% | |
25832b3f | 93 | |
c368d904 RD |
94 | rem (no command arg) --> normal build for development |
95 | else | |
de20db99 | 96 | set CMD=%SETUP% %FLAGS% HYBRID=0 build_ext --inplace --debug %1 %2 %3 %4 %5 %6 %7 %8 %9 |
c368d904 RD |
97 | endiff |
98 | ||
99 | ||
100 | ||
101 | echo %CMD% | |
102 | %CMD% | |
103 | ||
104 | iff "%OTHERCMD%" != "" then | |
185d7c3e | 105 | echo %OTHERCMD% |
c368d904 RD |
106 | %OTHERCMD% |
107 | endiff | |
108 |