build: Remove unused includes.h reference to avoid build-time talloc dep
[Samba/bjacke.git] / install_with_python.sh
blob7b51e5c6691b450ab9e45e2dbe1bf691ed5e5f32
1 #!/bin/sh
3 # this script installs a private copy of python in the same prefix as Samba
5 if [ $# -lt 1 ]; then
6 cat <<EOF
7 Usage: install_with_python.sh PREFIX [CONFIGURE OPTIONS]
8 EOF
9 exit 1;
12 PREFIX="$1"
13 shift
15 PATH=$PREFIX/python/bin:$PATH
16 export PATH
17 LD_LIBRARY_PATH=$PREFIX/python/lib:$LD_LIBRARY_PATH
18 export LD_LIBRARY_PATH
20 VERSION="Python-2.6.5"
22 do_install_python() {
23 mkdir -p python_install || exit 1
24 rsync -avz samba.org::ftp/tridge/python/$VERSION.tar python_install || exit 1
25 cd python_install || exit 1;
26 rm -rf $VERSION || exit 1
27 tar -xf $VERSION.tar || exit 1
28 cd $VERSION || exit 1
29 ./configure --prefix=$PREFIX/python --enable-shared --disable-ipv6 || exit 1
30 make || exit 1
31 make install || exit 1
32 cd ../.. || exit 1
33 rm -rf python_install || exit 1
36 if [ ! -d $PREFIX/python ]; then
37 # needs to be installed
38 do_install_python
41 PYTHON=$PREFIX/python/bin/python
42 export PYTHON
44 `dirname $0`/configure --prefix=$PREFIX $@ || exit 1
45 make -j || exit 1
46 make install || exit 1