Patchwork [1/3] autotools: fix multi-word arguments for EXTRA_OECONF

login
register
mail settings
Submitter Christopher Larson
Date Oct. 7, 2011, 9:02 p.m.
Message ID <bc7e830e85f9f5242e0178dee517d24cbdfc9fa3.1318021323.git.kergoth@gmail.com>
Download mbox | patch
Permalink /patch/12951/
State New, archived
Headers show

Comments

Christopher Larson - Oct. 7, 2011, 9:02 p.m.
This is needed to better support things like the following (with a
multi-word BUILD_CC):

    EXTRA_OECONF += '"ac_cv_prog_CC_FOR_BUILD=${BUILD_CC}"'

Signed-off-by: Christopher Larson <kergoth@gmail.com>
---
 meta/classes/autotools.bbclass |   14 ++++++--------
 1 files changed, 6 insertions(+), 8 deletions(-)
Koen Kooi - Oct. 7, 2011, 10:34 p.m.
Op 7 okt 2011, om 23:02 heeft Christopher Larson het volgende  
geschreven:

> This is needed to better support things like the following (with a
> multi-word BUILD_CC):
>
>    EXTRA_OECONF += '"ac_cv_prog_CC_FOR_BUILD=${BUILD_CC}"'
>
> Signed-off-by: Christopher Larson <kergoth@gmail.com>
> ---
> meta/classes/autotools.bbclass |   14 ++++++--------
> 1 files changed, 6 insertions(+), 8 deletions(-)
>
> diff --git a/meta/classes/autotools.bbclass b/meta/classes/ 
> autotools.bbclass
> index a4ce851..135be33 100644
> --- a/meta/classes/autotools.bbclass
> +++ b/meta/classes/autotools.bbclass
> @@ -70,14 +70,12 @@ CONFIGUREOPT_DEPTRACK = "--disable-dependency- 
> tracking"
>
>
> oe_runconf () {
> -	if [ -x ${S}/configure ] ; then
> -		cfgcmd="${S}/configure \
> -		${CONFIGUREOPTS} ${EXTRA_OECONF} $@"
> -		bbnote "Running $cfgcmd..."
> -		$cfgcmd || bbfatal "oe_runconf failed"
> -	else
> -		bbfatal "no configure script found"
> -	fi
> +       if [ -x ${S}/configure ] ; then
> +	       bbnote "Running ${S}/configure ${CONFIGUREOPTS} $ 
> {EXTRA_OECONF} $@"
> +	       ${S}/configure ${CONFIGUREOPTS} ${EXTRA_OECONF} "$@" ||  
> bbfatal "oe_runconf failed"
> +       else
> +	       bbfatal "no configure script found"
> +       f

Was the tab->spaces conversion intentional?
Chris Larson - Oct. 10, 2011, 2:58 p.m.
On Fri, Oct 7, 2011 at 3:34 PM, Koen Kooi <koen@beagleboard.org> wrote:
>>
>> oe_runconf () {
>> -       if [ -x ${S}/configure ] ; then
>> -               cfgcmd="${S}/configure \
>> -               ${CONFIGUREOPTS} ${EXTRA_OECONF} $@"
>> -               bbnote "Running $cfgcmd..."
>> -               $cfgcmd || bbfatal "oe_runconf failed"
>> -       else
>> -               bbfatal "no configure script found"
>> -       fi
>> +       if [ -x ${S}/configure ] ; then
>> +              bbnote "Running ${S}/configure ${CONFIGUREOPTS}
>> ${EXTRA_OECONF} $@"
>> +              ${S}/configure ${CONFIGUREOPTS} ${EXTRA_OECONF} "$@" ||
>> bbfatal "oe_runconf failed"
>> +       else
>> +              bbfatal "no configure script found"
>> +       f
>
> Was the tab->spaces conversion intentional?

Erm, nope, well spotted, thanks.

Patch

diff --git a/meta/classes/autotools.bbclass b/meta/classes/autotools.bbclass
index a4ce851..135be33 100644
--- a/meta/classes/autotools.bbclass
+++ b/meta/classes/autotools.bbclass
@@ -70,14 +70,12 @@  CONFIGUREOPT_DEPTRACK = "--disable-dependency-tracking"
 
 
 oe_runconf () {
-	if [ -x ${S}/configure ] ; then
-		cfgcmd="${S}/configure \
-		${CONFIGUREOPTS} ${EXTRA_OECONF} $@"
-		bbnote "Running $cfgcmd..."
-		$cfgcmd || bbfatal "oe_runconf failed" 
-	else
-		bbfatal "no configure script found"
-	fi
+       if [ -x ${S}/configure ] ; then
+	       bbnote "Running ${S}/configure ${CONFIGUREOPTS} ${EXTRA_OECONF} $@"
+	       ${S}/configure ${CONFIGUREOPTS} ${EXTRA_OECONF} "$@" || bbfatal "oe_runconf failed"
+       else
+	       bbfatal "no configure script found"
+       fi
 }
 
 autotools_do_configure() {