From: Keaton Mowery Date: Fri, 22 Jan 2010 01:19:21 +0000 (-0800) Subject: Configure: clean up flags from `python-config --cflags'. X-Git-Tag: release/2.13.12-1~68 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=1dfbb145818a4bd6cfdad8130183c1553232e37b;p=lilypond.git Configure: clean up flags from `python-config --cflags'. The sed command used to strip the unnecessary flags from the command `python-config --cflags' was not working. This commit (slightly amended from the original) fixes the issue. Signed-off-by: Patrick McCarty --- diff --git a/stepmake/aclocal.m4 b/stepmake/aclocal.m4 index cdb6dc3cfb..e4a4cb65b2 100644 --- a/stepmake/aclocal.m4 +++ b/stepmake/aclocal.m4 @@ -989,7 +989,8 @@ AC_DEFUN(STEPMAKE_PYTHON_DEVEL, [ if test -z "$PYTHON_CFLAGS" -a "$PYTHON_CONFIG" != "no"; then # Clean out junk: http://bugs.python.org/issue3290 # Python headers may need some -f* flags, leave them in. - PYTHON_CFLAGS=`$PYTHON_CONFIG --cflags | sed -e 's/ -\(W\|D\|O\|m\)\(\w\|-\|=\|,\)\+//g'` + # We want the sed commands to look like 's/-[WDOm][[:alnum:][:punct:]][[:alnum:][:punct:]]*//g' and 's/-arch [^[:space:]]*//g', but automake eats brackets. + PYTHON_CFLAGS=`$PYTHON_CONFIG --cflags | sed -e 's/-[[WDOm]][[[:alnum:][:punct:]]][[[:alnum:][:punct:]]]*//g' | sed -e 's/-arch @<:@^@<:@:space:@:>@@:>@*//g'` PYTHON_LDFLAGS=`$PYTHON_CONFIG --ldflags` fi