Tizen 2.1 base
[framework/web/webkit-efl.git] / Tools / CygwinDownloader / make-zip.sh
1 #!/bin/sh
2
3 PYTHONEXE=$(cygpath -u "${SYSTEMDRIVE}\\Python25\\python.exe")
4 ZIPNAME="cygwin-downloader.zip"
5
6 if [[ ! -f "${PYTHONEXE}" ]]; then
7         echo "Couldn't find python.exe at ${PYTHONEXE}" 1>&2
8         exit 1
9 fi
10
11 "${PYTHONEXE}" setup.py py2exe || {
12         echo "Failed executing setup.py" 1>&2
13         exit 1
14 }
15
16 rm -f "${ZIPNAME}"
17
18 cd dist
19
20 zip -r ../"${ZIPNAME}" * || {
21         echo "Failed to create cygwin-downloader" 1>&2
22         exit 1
23 }
24
25 cd ..
26
27 rm -rf build dist || {
28         echo "Failed to cleanup cygwin-downloader and build directories" 1>&2
29         exit 1
30 }