bug-autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Error processing nested quote


From: Prakash, Punya
Subject: RE: Error processing nested quote
Date: Wed, 4 May 2011 16:55:11 -0500

$embffmpeg_configure_args is being computed using $ac_cs_config, use of eval 
fixed the issue. Thank you.

Regards,
Punya

-----Original Message-----
From: Eric Blake [mailto:address@hidden 
Sent: Tuesday, May 03, 2011 9:14 AM
To: Prakash, Punya
Cc: address@hidden
Subject: Re: Error processing nested quote

On 05/03/2011 07:53 AM, Prakash, Punya wrote:
> All,
> 
> When we pass parameters with nested quotes, autoconf does not reconstruct the 
> parameters correct. I have particularly tested single quotes with-in double 
> quotes: " ' ' "
> 
> For more details please refer: 
> https://bugzilla.gnome.org/show_bug.cgi?id=648816

Please post details in this thread rather than making everyone chase a link.  
From that bug report:

> works: --with-ffmpeg-extra-configure=" --target-os=linux 
> --extra-cflags=-mfpu=neon"
> - Result: --extra-cflags='-mcpu=cortex-a8'
> Does not work: --with-ffmpeg-extra-configure=" --target-os=linux 
> --extra-cflags='-mfpu=neon -mfloat-abi=softfp'"
> - Result: --extra-cflags=''\''-mfpu=neon' -mfloat-abi='softfp'\'''
> (Should and does) not work: --with-ffmpeg-extra-configure=" 
> --target-os=linux --extra-cflags=-mfpu=neon -mfloat-abi=softfp"
> - Result: --extra-cflags='-mcpu=cortex-a8' -mfpu=neon 
> -mfloat-abi=softfp
> 
> The looked at the command in gst-ffmpeg configure file which is 
> attempting to configure ./gst-lib/ext/ffmpeg/configure, it looks 
> right. It is passing in the right parameters (as you have suggested). 
> I cant seem to figure out where in the configuration procedure the extra 
> quotes are being appended.
> 
> gst-ffmpeg/configure.ac
> cd "$ac_top_build_prefix"gst-libs/ext/ffmpeg &&
>          $confcmd $embffmpeg_configure_args *all the parameters here 
> look right*

But how is $embffmpeg_configure_args being computed?

> 
> ac_cs_config in config.status appends single quotes to every compiler option.
> Looks like it is not re-constructed correctly when it detects a single 
> quote being passed in. Could this issue be related to autoconf? Please advice.
> 
> ac_cs_config="'--build=i686-linux' '--host=arm-none-linux-gnueabi'
> '--target=arm-none-linux-gnueabi' '--prefix=/usr' '--exec_prefix=/usr'
> '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--libexecdir=/usr/libexec'
> '--datadir=/usr/share' '--sysconfdir=/etc' '--sharedstatedir=/com'
> '--localstatedir=/var' '--libdir=/usr/lib' '--includedir=/usr/include'
> '--oldincludedir=/usr/include' '--infodir=/usr/share/info'
> '--mandir=/usr/share/man' '--enable-largefile' '--disable-nls' '--enable-ipv6'
> '--with-ffmpeg-extra-configure=  --target-os=linux 
> --extra-cflags='\\''-mfpu=neon -mfloat-abi=softfp'\\'''
> 'build_alias=i686-linux' 'host_alias=arm-none-linux-gnueabi'
> 'target_alias=arm-none-linux-gnueabi' 'CC=arm-none-linux-gnueabi-gcc 
> -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp 
> -mthumb-interwork -mno-thumb 
> --sysroot=/home/pprakash/arago/arago-tmp/sysroots/armv7a-none-linux-gnueabi'
> 'CFLAGS=-fexpensive-optimizations -frename-registers 
> -fomit-frame-pointer -O2 -ggdb2' 'LDFLAGS=-Wl,-O1 
> -Wl,--hash-style=gnu' 'CPP=arm-none-linux-gnueabi-gcc -E 
> --sysroot=/home/pprakash/arago/arago-tmp/sysroots/armv7a-none-linux-gnueabi'"

This is correct from autoconf's point of view - ac_cs_config is an internal 
variable which is appropriately quoted to be passed through an eval.

If you are computing $embffmpeg_configure_args from $ac_cs_config, then you 
have to use an eval statement.

I don't see how this could be an autoconf bug; more likely it is a bug in the 
configure.ac script for abusing autoconf internals incorrectly, since 
ac_cs_config is not a documented variable.

-- 
Eric Blake   address@hidden    +1-801-349-2682
Libvirt virtualization library http://libvirt.org




reply via email to

[Prev in Thread] Current Thread [Next in Thread]