1 |
# $Header: /magellan-cvs/smage/include/python.sminc,v 1.4 2007/01/23 20:46:41 niro Exp $ |
# $Id$ |
2 |
|
|
3 |
|
# needed for mbindir() |
4 |
|
sminclude mtools |
5 |
|
|
6 |
# get the major.minor current installed python version |
# get the major.minor current installed python version |
7 |
# -> ex 2.4 |
# -> ex 2.4 |
17 |
get_python_libdir() |
get_python_libdir() |
18 |
{ |
{ |
19 |
local pylib |
local pylib |
20 |
pylib=$(python -c 'from distutils import sysconfig; print sysconfig.get_python_version()') |
pylib=$(python -c 'from distutils import sysconfig; print sysconfig.get_python_lib()') |
21 |
echo "${pylib}" |
echo "${pylib}" |
22 |
return 0 |
return 0 |
23 |
} |
} |
53 |
|
|
54 |
if [[ -e setup.py ]] |
if [[ -e setup.py ]] |
55 |
then |
then |
56 |
python setup.py install --no-compile --root ${BINDIR} "$@" || die |
python setup.py install --no-compile --root $(mbindir) "$@" || die |
57 |
elif [[ -e waf ]] |
elif [[ -e waf ]] |
58 |
then |
then |
59 |
python waf install --destdir="${BINDIR}" "$@" || die |
python waf install --destdir="$(mbindir)" "$@" || die |
60 |
else |
else |
61 |
mmake DESTDIR=${BINDIR} install || die |
mmake DESTDIR=$(mbindir) install || die |
62 |
fi |
fi |
63 |
|
|
64 |
local i |
local i |