aboutsummaryrefslogtreecommitdiffstats
path: root/tools/tests/regression/scripts/build_python.sh
blob: b9b6f9ff14effcdbef38b731b2962ffbc5a1cc88 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/bash
#
# This script builds python in the dir 
# installed/python-${DEST} from package downloads/Python-{PKG_VERS}.tgz
#

set -e

XEN_ROOT=$1
DEST=$2
PKG_VERS=$3

SUB_MAKES_MINUS_J=-j4

BUILD_DIR=${XEN_ROOT}/tests/build

mkdir -p ${BUILD_DIR}
(cd ${BUILD_DIR} && tar -xf ${XEN_ROOT}/tests/downloads/Python-$PKG_VERS.tgz)
(cd ${BUILD_DIR}/Python-$PKG_VERS &&
 ./configure --enable-shared --enable-ipv6 --without-cxx \
       --with-threads --prefix=${XEN_ROOT}/tests/installed/python-$DEST &&
make ${SUB_MAKES_MINUS_J} &&
make install)
rm -fr ${BUILD_DIR}/Python-$PKG_VERS