configure problem (was: dbus-python 0.82.1)

Simon McVittie simon.mcvittie at collabora.co.uk
Thu Jul 12 06:00:26 PDT 2007


On Thu, 12 Jul 2007 at 15:28:54 +0300, Eyal Ben David wrote:
> checking for headers required to compile python extensions... not found
> configure: error: could not find Python headers
> 
> Here is the patch (reverting back to 0.81):
> 
> -----------------------
> 
> diff -ru dbus-python-0.82.0/configure dbus-python-0.82.0-configure-
> fixed/configure
> --- dbus-python-0.82.0/configure	2007-06-19 19:50:06.000000000 +0300
> +++ dbus-python-0.82.0-configure-fixed/configure	2007-07-03
> 07:59:27.000000000 +0300
> @@ -9711,7 +9711,10 @@
>  echo $ECHO_N "checking for headers required to compile python
> extensions... $ECHO_C" >&6; }
>  py_prefix=`$PYTHON -c "import sys; print sys.prefix"`
>  py_exec_prefix=`$PYTHON -c "import sys; print sys.exec_prefix"`
> -PYTHON_INCLUDES=`$PYTHON-config --includes 2>/dev/null`
> +PYTHON_INCLUDES="-I${py_prefix}/include/python${PYTHON_VERSION}"
> +if test "$py_prefix" != "$py_exec_prefix"; then
> +  PYTHON_INCLUDES="$PYTHON_INCLUDES -I${py_exec_prefix}/include/python
> ${PYTHON_VERSION}"
> +fi

I'm told this change is needed for Ubuntu's python2.4-dbg etc.
packages, which are the same version as the normal build but are built
differently and use different paths. Could you let me know what the following
commands output on your system?

which python
which python-config
python-config --prefix
python-config --exec-prefix
python-config --includes
python-config --cflags
python-config --libs
python-config --ldflags
python -c 'import sys; print sys.version_info'
python -c 'import sys; print sys.prefix'
python -c 'import sys; print sys.exec_prefix'

Replace python with whatever version of Python you're using as
appropriate (e.g. python2.4-config and python2.4).

Thanks,
	Simon


More information about the dbus mailing list