]> git.saurik.com Git - wxWidgets.git/blame - wxPython/b.win32
always return something in GetCommandForVerb() second argument, even if verb not...
[wxWidgets.git] / wxPython / b.win32
CommitLineData
bdac31ba
RD
1#!/bin/bash
2# ----------------------------------------------------------------------
3
5e66e38e
KO
4# To Robin: I tried to avoid making any changes to the existing
5# build scripts, but my env requires me to specify Windows paths...
6# if this breaks something at your end, let me know and we can
7# figure out some solution for both of us.
8if [ "$SWIGDIR" = "" ]; then
214c4fbe 9 SWIGDIR=$PROJECTS\\SWIG-1.3.27
5e66e38e
KO
10fi
11
bdac31ba
RD
12
13# Use non-default python?
f60a22bd 14case $1 in
e2b154e3
RD
15 21 | 2.1) VER=21; shift ;;
16 22 | 2.2) VER=22; shift ;;
17 23 | 2.3) VER=23; shift ;;
18 24 | 2.4) VER=24; shift ;;
f60a22bd 19
e2b154e3 20 *) VER=24
f60a22bd
RD
21esac
22
23PYTHON=$TOOLS/python$VER/python.exe
bdac31ba
RD
24
25SETUP="$PYTHON -u setup.py"
26$PYTHON -c "import sys;print '\n', sys.version, '\n'"
27
28
454a21e9
RD
29FLAGS="USE_SWIG=1 SWIG=$SWIGDIR\\swig.exe"
30UNIFLAG="UNICODE=1"
31
32for p in $*; do
33 if [ "$p" = "UNICODE=0" -o "$p" = "UNICODE=1" ]; then
34 UNIFLAG=""
35 break
36 fi
37done
38
39FLAGS="$FLAGS $UNIFLAG"
40
41
42
43
44
bdac31ba
RD
45
46# "c" --> clean
47if [ "$1" = "c" ]; then
48 shift
49 CMD="$SETUP $FLAGS clean $@"
50 OTHERCMD="rm wx/*.pyd"
51
52# just remove the *.pyd's
53elif [ "$1" = "d" ]; then
54 shift
55 CMD="rm wx/*.pyd"
56
57# touch all the *.i files so swig will regenerate
58elif [ "$1" = "t" ]; then
59 shift
60 CMD=
61 find . -name "*.i" | xargs -l touch
62
63# "i" --> install
64elif [ "$1" = "i" ]; then
65 shift
66 CMD="$SETUP build install"
67
68# "r" --> make installer
69elif [ "$1" = "r" ]; then
70 shift
71 CMD="$PYTHON -u distrib\make_installer.py $@"
72
73# "s" --> source dist
74elif [ "$1" = "s" ]; then
75 shift
76 CMD="$SETUP sdist"
77
78# "f" --> FINAL
79elif [ "$1" == "f" ]; then
80 shift
81 CMD="$SETUP $FLAGS FINAL=1 build_ext --inplace $@"
82
83# "h" --> HYBRID
84elif [ "$1" = "h" ]; then
85 shift
86 CMD="$SETUP $FLAGS HYBRID=1 build_ext --inplace $@"
87
88# "a" --> make all installers
89elif [ "$1" = "a" ]; then
90 shift
91 CMD=
92
1d84f787
RD
93 $0 23 d UNICODE=0
94 $0 23 h UNICODE=0
95 $0 23 r UNICODE=0
bdac31ba
RD
96 $0 23 d UNICODE=1
97 $0 23 h UNICODE=1
98 $0 23 r UNICODE=1
99
1d84f787
RD
100 $0 24 d UNICODE=0
101 $0 24 h UNICODE=0
102 $0 24 r UNICODE=0
103 $0 24 d UNICODE=1
104 $0 24 h UNICODE=1
105 $0 24 r UNICODE=1
106
bdac31ba
RD
107
108# "b" --> both debug and hybrid builds
109elif [ "$1" = "b" ]; then
110 shift
111 CMD="echo Finished!"
112 $0 $VER $@
113 $0 $VER h $@
114
cb56afc4 115# (no command arg) --> normal debug build for development
bdac31ba
RD
116else
117 CMD="$SETUP $FLAGS HYBRID=0 build_ext --inplace --debug $@"
118fi
119
120
121
122if [ "$CMD" != "" ]; then
123 echo $CMD
124 $CMD
125fi
126
127if [ "$OTHERCMD" != "" ]; then
128 echo $OTHERCMD
129 $OTHERCMD
130fi
131