radare2/sys/python.sh

31 lines
663 B
Bash
Raw Normal View History

#!/bin/sh
# find root
cd `dirname $PWD/$0`
./clone-r2-bindings.sh
cd ..
. ./sys/CONFIG
2015-04-18 03:56:01 +08:00
echo "============="
cat sys/CONFIG
2015-04-18 03:56:01 +08:00
echo "============="
2011-12-05 08:09:15 +08:00
export PYTHON
2013-05-13 05:37:31 +08:00
export DESTDIR
export PYTHON_VERSION
export PYTHON_CONFIG
echo "Using PYTHON_VERSION ${PYTHON_VERSION}"
PYTHON_CONFIG="python${PYTHON_VERSION}-config"
echo "Using PYTHON_CONFIG ${PYTHON_CONFIG}"
echo
cd radare2-bindings
./configure --prefix=${PREFIX} --enable=python || exit 1
2013-05-13 05:37:31 +08:00
${SUDO} make install-vapi DESTDIR=${DESTDIR} || exit 1
cd python
make clean
2011-12-05 08:09:15 +08:00
make PYTHON=${PYTHON}
2013-06-10 06:28:55 +08:00
[ "$1" != '--no-install' ] && \
${SUDO} make install PYTHON=${PYTHON} \
PYTHON_VERSION=${PYTHON_VERSION} DESTDIR=${DESTDIR}