summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordoko@python.org <doko@python.org>2013-01-25 12:20:46 (GMT)
committerdoko@python.org <doko@python.org>2013-01-25 12:20:46 (GMT)
commit6951fea3abb64a3820d623efce182fefdcbae978 (patch)
tree3aa2c832db8a43b2d274737f1452f538d4f5a60c
parent35f284b75e7c4e35c57575b8839efc15fc12daad (diff)
parent0c77bf757f94945b9e11a3d1f44ee47466866fd0 (diff)
downloadcpython-6951fea3abb64a3820d623efce182fefdcbae978.zip
cpython-6951fea3abb64a3820d623efce182fefdcbae978.tar.gz
cpython-6951fea3abb64a3820d623efce182fefdcbae978.tar.bz2
- Issue #17029: Let h2py search the multiarch system include directory.
-rw-r--r--Makefile.pre.in4
-rw-r--r--Misc/NEWS2
-rwxr-xr-xTools/scripts/h2py.py5
-rwxr-xr-xconfigure4
-rw-r--r--configure.ac3
5 files changed, 18 insertions, 0 deletions
diff --git a/Makefile.pre.in b/Makefile.pre.in
index 97bb005..8297004 100644
--- a/Makefile.pre.in
+++ b/Makefile.pre.in
@@ -97,6 +97,9 @@ PY_CORE_CFLAGS= $(PY_CFLAGS) $(PY_CPPFLAGS) $(CFLAGSFORSHARED) -DPy_BUILD_CORE
# Machine-dependent subdirectories
MACHDEP= @MACHDEP@
+# Multiarch directory (may be empty)
+MULTIARCH= @MULTIARCH@
+
# Install prefix for architecture-independent files
prefix= @prefix@
@@ -1119,6 +1122,7 @@ $(srcdir)/Lib/$(PLATDIR):
export PYTHONPATH; PYTHONPATH="`pwd`/Lib"; \
export DYLD_FRAMEWORK_PATH; DYLD_FRAMEWORK_PATH="`pwd`"; \
export EXE; EXE="$(BUILDEXE)"; \
+ if [ -n "$(MULTIARCH)" ]; then export MULTIARCH; MULTIARCH=$(MULTIARCH); fi; \
cd $(srcdir)/Lib/$(PLATDIR); $(RUNSHARED) ./regen
python-config: $(srcdir)/Misc/python-config.in
diff --git a/Misc/NEWS b/Misc/NEWS
index a7c75f1..f4ff543 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -746,6 +746,8 @@ Tests
Build
-----
+- Issue #17029: Let h2py search the multiarch system include directory.
+
- Issue #16953: Fix socket module compilation on platforms with
HAVE_BROKEN_POLL. Patch by Jeffrey Armstrong.
diff --git a/Tools/scripts/h2py.py b/Tools/scripts/h2py.py
index 45aa439..4f871d9 100755
--- a/Tools/scripts/h2py.py
+++ b/Tools/scripts/h2py.py
@@ -50,6 +50,11 @@ except KeyError:
searchdirs=os.environ['INCLUDE'].split(';')
except KeyError:
searchdirs=['/usr/include']
+ try:
+ searchdirs.insert(0, os.path.join('/usr/include',
+ os.environ['MULTIARCH']))
+ except KeyError:
+ pass
def main():
global filedict
diff --git a/configure b/configure
index 2b52d51..3dc6c3a 100755
--- a/configure
+++ b/configure
@@ -684,6 +684,7 @@ BLDLIBRARY
DLLLIBRARY
LDLIBRARY
LIBRARY
+MULTIARCH
BUILDEXEEXT
EGREP
GREP
@@ -5351,6 +5352,9 @@ hp*|HP*)
esac;;
esac
+MULTIARCH=$($CC --print-multiarch 2>/dev/null)
+
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBRARY" >&5
diff --git a/configure.ac b/configure.ac
index 459141e..9379c04 100644
--- a/configure.ac
+++ b/configure.ac
@@ -764,6 +764,9 @@ hp*|HP*)
esac;;
esac
+MULTIARCH=$($CC --print-multiarch 2>/dev/null)
+AC_SUBST(MULTIARCH)
+
AC_SUBST(LIBRARY)
AC_MSG_CHECKING(LIBRARY)