blob: 6c77b09a81d0b6727dd9627f57a94154d8f5d259 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
|
Index: libvirt-0.10.2/configure.ac
===================================================================
--- libvirt-0.10.2.orig/configure.ac 2012-10-29 11:59:27.091615491 +0200
+++ libvirt-0.10.2/configure.ac 2012-10-29 12:09:50.067603647 +0200
@@ -2397,6 +2397,11 @@
PYTHON_VERSION=
PYTHON_INCLUDES=
+
+AC_ARG_WITH(python-inc-dir,
+ AS_HELP_STRING([--with-python-inc-dir=DIR], [directory with Python include files]),
+ [PYTHON_INCLUDES="${withval}"], [])
+
if test "$with_python" != "no" ; then
if test -x "$with_python/bin/python"
then
@@ -2422,29 +2427,30 @@
AM_PATH_PYTHON(,, [:])
if test "$PYTHON" != : ; then
- PYTHON_CONFIG="$PYTHON-config"
-
- if test -x "$PYTHON_CONFIG"
- then
- PYTHON_INCLUDES=`$PYTHON_CONFIG --includes`
- else
- if test -r $PYTHON_EXEC_PREFIX/include/python$PYTHON_VERSION/Python.h
- then
- PYTHON_INCLUDES=-I$PYTHON_EXEC_PREFIX/include/python$PYTHON_VERSION
- else
- if test -r $prefix/include/python$PYTHON_VERSION/Python.h
- then
- PYTHON_INCLUDES=-I$prefix/include/python$PYTHON_VERSION
- else
- if test -r /usr/include/python$PYTHON_VERSION/Python.h
- then
- PYTHON_INCLUDES=-I/usr/include/python$PYTHON_VERSION
- else
- AC_MSG_ERROR([You must install python-devel to build Python bindings])
- fi
+ if ! test -n "$PYTHON_INCLUDES"; then
+ PYTHON_CONFIG="$PYTHON-config"
+ if test -x "$PYTHON_CONFIG"
+ then
+ PYTHON_INCLUDES=`$PYTHON_CONFIG --includes`
+ else
+ if test -r $PYTHON_EXEC_PREFIX/include/python$PYTHON_VERSION/Python.h
+ then
+ PYTHON_INCLUDES=-I$PYTHON_EXEC_PREFIX/include/python$PYTHON_VERSION
+ else
+ if test -r $prefix/include/python$PYTHON_VERSION/Python.h
+ then
+ PYTHON_INCLUDES=-I$prefix/include/python$PYTHON_VERSION
+ else
+ if test -r /usr/include/python$PYTHON_VERSION/Python.h
+ then
+ PYTHON_INCLUDES=-I/usr/include/python$PYTHON_VERSION
+ else
+ AC_MSG_ERROR([You must install python-devel to build Python bindings])
+ fi
+ fi
fi
fi
- fi
+ fi
else
AC_MSG_ERROR([You must install python to build Python bindings])
fi
|