summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/rpm/rpm-4.11.2/use-pkgconfig-for-python.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/rpm/rpm-4.11.2/use-pkgconfig-for-python.patch')
-rw-r--r--meta/recipes-devtools/rpm/rpm-4.11.2/use-pkgconfig-for-python.patch38
1 files changed, 38 insertions, 0 deletions
diff --git a/meta/recipes-devtools/rpm/rpm-4.11.2/use-pkgconfig-for-python.patch b/meta/recipes-devtools/rpm/rpm-4.11.2/use-pkgconfig-for-python.patch
new file mode 100644
index 0000000000..8d84cf8a11
--- /dev/null
+++ b/meta/recipes-devtools/rpm/rpm-4.11.2/use-pkgconfig-for-python.patch
@@ -0,0 +1,38 @@
1
2Use pkgconfig to get the correct include paths
3
4Upstream-Status: Pending
5
6Signed-off-by: Saul Wold <sgw@linux.intel.com>
7Signed-off-by: Ronan Le Martret <ronan.lemartret@open.eurogiciel.org>
8
9diff --git a/configure.ac b/configure.ac
10index e97f727..8179f44 100644
11--- a/configure.ac
12+++ b/configure.ac
13@@ -540,10 +540,10 @@ esac],
14
15 AS_IF([test "$enable_python" = yes],[
16 AM_PATH_PYTHON([2.6],[
17- WITH_PYTHON_INCLUDE=`${PYTHON} -c 'from distutils.sysconfig import *; import sys; sys.stdout.write(get_python_inc())'`
18+ WITH_PYTHON_INCLUDE=$(${PKG_CONFIG} --cflags-only-I python)
19 WITH_PYTHON_SUBPACKAGE=1
20 save_CPPFLAGS="$CPPFLAGS"
21- CPPFLAGS="$CPPFLAGS -I$WITH_PYTHON_INCLUDE"
22+ CPPFLAGS="$CPPFLAGS $WITH_PYTHON_INCLUDE"
23 AC_CHECK_HEADER([Python.h],[],
24 [AC_MSG_ERROR([missing Python.h])
25 ])
26diff --git a/python/Makefile.am b/python/Makefile.am
27index fff51ae..f37cb9d 100644
28--- a/python/Makefile.am
29+++ b/python/Makefile.am
30@@ -4,7 +4,7 @@ EXTRA_DIST = rpm/__init__.py rpm/transaction.py
31
32 AM_CPPFLAGS = -I$(top_builddir)/include/
33 AM_CPPFLAGS += -I$(top_srcdir)/python
34-AM_CPPFLAGS += -I@WITH_PYTHON_INCLUDE@
35+AM_CPPFLAGS += @WITH_PYTHON_INCLUDE@
36
37 pkgpyexec_LTLIBRARIES = _rpmmodule.la _rpmbmodule.la _rpmsmodule.la
38 pkgpyexec_DATA = rpm/__init__.py rpm/transaction.py