version 1.30 | | version 1.31 |
---|
| | |
| | |
if test "x$cf_have_python_h" = "xyes" ; then | | if test "x$cf_have_python_h" = "xyes" ; then |
PYTHON_LIB="" | | PYTHON_LIB="" |
python=`echo $dir | awk -F/ '{print $NF}'`; | | |
as_ac_Lib=`echo "ac_cv_lib_$python''_PyArg_ParseTuple" | $as_tr_sh` | | for lib in python{,2.2,2.1,2.0} ; do |
echo "$as_me:$LINENO: checking for PyArg_ParseTuple in -l$python" >&5 | | as_ac_Lib=`echo "ac_cv_lib_$lib''_PyArg_ParseTuple" | $as_tr_sh` |
echo $ECHO_N "checking for PyArg_ParseTuple in -l$python... $ECHO_C" >&6 | | echo "$as_me:$LINENO: checking for PyArg_ParseTuple in -l$lib" >&5 |
| | echo $ECHO_N "checking for PyArg_ParseTuple in -l$lib... $ECHO_C" >&6 |
if eval "test \"\${$as_ac_Lib+set}\" = set"; then | | if eval "test \"\${$as_ac_Lib+set}\" = set"; then |
echo $ECHO_N "(cached) $ECHO_C" >&6 | | echo $ECHO_N "(cached) $ECHO_C" >&6 |
else | | else |
ac_check_lib_save_LIBS=$LIBS | | ac_check_lib_save_LIBS=$LIBS |
LIBS="-l$python $LIBS" | | LIBS="-l$lib $LIBS" |
cat >conftest.$ac_ext <<_ACEOF | | cat >conftest.$ac_ext <<_ACEOF |
#line $LINENO "configure" | | #line $LINENO "configure" |
#include "confdefs.h" | | #include "confdefs.h" |
| | |
echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Lib'}'`" >&5 | | echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Lib'}'`" >&5 |
echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6 | | echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6 |
if test `eval echo '${'$as_ac_Lib'}'` = yes; then | | if test `eval echo '${'$as_ac_Lib'}'` = yes; then |
PYTHON_LIB="-l$python" | | PYTHON_LIB="-l$lib" |
fi | | fi |
| | |
| | if test "x$PYTHON_LIB" != "x" ; then |
| | break |
| | fi |
| | done |
| | |
# These checks are a bit bogus - would be better to use AC_CHECK_LIB, | | # These checks are a bit bogus - would be better to use AC_CHECK_LIB, |
# but it caches the result of the first check, even if we run AC_CHECK_LIB | | # but it caches the result of the first check, even if we run AC_CHECK_LIB |
# with other options. | | # with other options. |
| | python=`echo $dir | awk -F/ '{print $NF}'`; |
| | if test "x$PYTHON_LIB" = "x" ; then |
echo "$as_me:$LINENO: checking For python lib in various places" >&5 | | echo "$as_me:$LINENO: checking For python lib in various places" >&5 |
echo $ECHO_N "checking For python lib in various places... $ECHO_C" >&6 | | echo $ECHO_N "checking For python lib in various places... $ECHO_C" >&6 |
if test -f /usr/lib/$python/lib$python.a ; then | | if test -f /usr/lib/$python/lib$python.a ; then |
| | |
echo "$as_me:$LINENO: result: found in /usr/lib/$python/config" >&5 | | echo "$as_me:$LINENO: result: found in /usr/lib/$python/config" >&5 |
echo "${ECHO_T}found in /usr/lib/$python/config" >&6 | | echo "${ECHO_T}found in /usr/lib/$python/config" >&6 |
fi | | fi |
if test "x$PYTHON_LIB" = "x" ; then | | |
PYTHON_LIB=`echo /usr/lib/python*/config/libpython*.a` | | |
if test ! -f $PYTHON_LIB ; then | | |
echo "$as_me:$LINENO: result: no" >&5 | | |
echo "${ECHO_T}no" >&6 | | |
PYTHON_LIB="" | | |
else | | |
echo "$as_me:$LINENO: result: yes" >&5 | | |
echo "${ECHO_T}yes" >&6 | | |
fi | | |
fi | | fi |
if test "x$PYTHON_LIB" != "x" ; then | | if test "x$PYTHON_LIB" != "x" ; then |
echo "$as_me:$LINENO: checking for main in -lpthread" >&5 | | echo "$as_me:$LINENO: checking for main in -lpthread" >&5 |