From 67c20d42b5ca06458b154356877f4ad5952736f4 Mon Sep 17 00:00:00 2001 From: rbuj Date: Fri, 27 Jun 2014 02:37:54 +0200 Subject: OS X: PYTHON_CFLAGS & PYTHON_LIBS (--enable-python=system) Use $FRAMEWORKSHOME instead of /Developer/SDKs/MacOSX${with_macosx_sdk}.sdk/System/Library/Frameworks. As of Xcode 5.0, Python has been moved outside the SDK, so it doesn't provide the Python framework. Now we have to use common unix parameters unlike older versions of Xcode. It is described in the technical note TN2328. Change-Id: Ib2a010e7c3839a8906acb2453c90ef2bd2f258d7 Reviewed-on: https://gerrit.libreoffice.org/9926 Reviewed-by: Norbert Thiebaud Tested-by: Norbert Thiebaud --- configure.ac | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index f05ed540b865..c20101d3675e 100644 --- a/configure.ac +++ b/configure.ac @@ -8076,8 +8076,13 @@ if test $enable_python = system; then python_version=2.7;; esac PYTHON=python$python_version - PYTHON_CFLAGS="-I/Developer/SDKs/MacOSX${with_macosx_sdk}.sdk/System/Library/Frameworks/Python.framework/Versions/${python_version}/include/python${python_version}" - PYTHON_LIBS="-framework Python" + if test -d "$FRAMEWORKSHOME/Python.framework/Versions/${python_version}/include/python${python_version}"; then + PYTHON_CFLAGS="-I$FRAMEWORKSHOME/Python.framework/Versions/${python_version}/include/python${python_version}" + PYTHON_LIBS="-framework Python" + else + PYTHON_CFLAGS="`$PYTHON-config --includes`" + PYTHON_LIBS="`$PYTHON-config --libs`" + fi fi if test -n "$PYTHON_CFLAGS" -a -n "$PYTHON_LIBS"; then # Fallback: Accept these in the environment, or as set above -- cgit v1.2.3