Patchwork [1/4] classes/autotools-autoreconf: Allow owerwrite the autoreconf command

login
register
mail settings
Submitter Morten Svendsen
Date Oct. 5, 2012, 9:51 a.m.
Message ID <cd0f1c36cb8daaaf639a3ae73b0319b5d7992027.1349430062.git.morten.thunbergsvendsen@prevas.dk>
Download mbox | patch
Permalink /patch/189453/
State Accepted
Delegated to: Esben Haabendal
Headers show

Comments

Morten Svendsen - Oct. 5, 2012, 9:51 a.m.
Allows for recipes needing special auto tools command sequence
---
 classes/autotools-autoreconf.oeclass |    8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
Esben Haabendal - Oct. 5, 2012, 3:03 p.m.
Morten Thunberg Svendsen <morten.thunbergsvendsen@prevas.dk> writes:

> Allows for recipes needing special auto tools command sequence
> ---
>  classes/autotools-autoreconf.oeclass |    8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/classes/autotools-autoreconf.oeclass b/classes/autotools-autoreconf.oeclass
> index 825e8e4..6ff7469 100644
> --- a/classes/autotools-autoreconf.oeclass
> +++ b/classes/autotools-autoreconf.oeclass
> @@ -6,6 +6,10 @@ CLASS_DEPENDS += "${DEPENDS_AUTORECONF}"
>  DEPENDS_AUTORECONF ?= "native:glib-dev"
>  
>  EXTRA_AUTORECONF = ""
> +AUTORECONF ?= "autoreconf --verbose --install --force \
> +               ${EXTRA_AUTORECONF} $acpaths \
> +               "
> +
>  acpaths = "__default__"
>  
>  pkgltdldir = "${STAGE_DIR}/${HOST_CROSS}${stage_datadir}/libtool"
> @@ -76,9 +80,7 @@ do_autoreconf () {
>              export _lt_pkgdatadir="${pkgltdldir}"
>          fi
>          oenote Executing autoreconf
> -        autoreconf --verbose --install --force \
> -            ${EXTRA_AUTORECONF} $acpaths \
> -            || oefatal "autoreconf execution failed."
> +        eval "${AUTORECONF}" || oefatal 'autoreconf execution failed.'
>          if grep "^[[:space:]]*[AI][CT]_PROG_INTLTOOL" $CONFIGURE_AC >/dev/null; then
>              oenote Executing intltoolize
>              intltoolize --copy --force --automake

Do you want/need to change the command/path or the arguments or both?

/Esben
Morten Svendsen - Oct. 8, 2012, 3:43 p.m.
On 2012-10-05 17:03, Esben Haabendal wrote:
> Morten Thunberg Svendsen <morten.thunbergsvendsen@prevas.dk> writes:
>
>> Allows for recipes needing special auto tools command sequence
>> ---
>>   classes/autotools-autoreconf.oeclass |    8 +++++---
>>   1 file changed, 5 insertions(+), 3 deletions(-)
>>
>> diff --git a/classes/autotools-autoreconf.oeclass b/classes/autotools-autoreconf.oeclass
>> index 825e8e4..6ff7469 100644
>> --- a/classes/autotools-autoreconf.oeclass
>> +++ b/classes/autotools-autoreconf.oeclass
>> @@ -6,6 +6,10 @@ CLASS_DEPENDS += "${DEPENDS_AUTORECONF}"
>>   DEPENDS_AUTORECONF ?= "native:glib-dev"
>>
>>   EXTRA_AUTORECONF = ""
>> +AUTORECONF ?= "autoreconf --verbose --install --force \
>> +               ${EXTRA_AUTORECONF} $acpaths \
>> +               "
>> +
>>   acpaths = "__default__"
>>
>>   pkgltdldir = "${STAGE_DIR}/${HOST_CROSS}${stage_datadir}/libtool"
>> @@ -76,9 +80,7 @@ do_autoreconf () {
>>               export _lt_pkgdatadir="${pkgltdldir}"
>>           fi
>>           oenote Executing autoreconf
>> -        autoreconf --verbose --install --force \
>> -            ${EXTRA_AUTORECONF} $acpaths \
>> -            || oefatal "autoreconf execution failed."
>> +        eval "${AUTORECONF}" || oefatal 'autoreconf execution failed.'
>>           if grep "^[[:space:]]*[AI][CT]_PROG_INTLTOOL" $CONFIGURE_AC >/dev/null; then
>>               oenote Executing intltoolize
>>               intltoolize --copy --force --automake
>
> Do you want/need to change the command/path or the arguments or both?
>


I'll fx. set it to

inherit autotools-autoreconf
AUTORECONF = " \
    ${LIBTOOLIZE} --force --copy \
&& aclocal -I . $acpaths --force \
&& automake -a --copy --force --gnu \
&& autoconf -I . $acpaths --force \
"

/Morten
Esben Haabendal - Oct. 10, 2012, 1:04 p.m.
Morten Thunberg Svendsen <Morten.ThunbergSvendsen@prevas.dk> writes:

> On 2012-10-05 17:03, Esben Haabendal wrote:
>> Morten Thunberg Svendsen <morten.thunbergsvendsen@prevas.dk> writes:
>>
>>> Allows for recipes needing special auto tools command sequence
>>> ---
>>>   classes/autotools-autoreconf.oeclass |    8 +++++---
>>>   1 file changed, 5 insertions(+), 3 deletions(-)
>>>
>>> diff --git a/classes/autotools-autoreconf.oeclass b/classes/autotools-autoreconf.oeclass
>>> index 825e8e4..6ff7469 100644
>>> --- a/classes/autotools-autoreconf.oeclass
>>> +++ b/classes/autotools-autoreconf.oeclass
>>> @@ -6,6 +6,10 @@ CLASS_DEPENDS += "${DEPENDS_AUTORECONF}"
>>>   DEPENDS_AUTORECONF ?= "native:glib-dev"
>>>
>>>   EXTRA_AUTORECONF = ""
>>> +AUTORECONF ?= "autoreconf --verbose --install --force \
>>> +               ${EXTRA_AUTORECONF} $acpaths \
>>> +               "
>>> +
>>>   acpaths = "__default__"
>>>
>>>   pkgltdldir = "${STAGE_DIR}/${HOST_CROSS}${stage_datadir}/libtool"
>>> @@ -76,9 +80,7 @@ do_autoreconf () {
>>>               export _lt_pkgdatadir="${pkgltdldir}"
>>>           fi
>>>           oenote Executing autoreconf
>>> -        autoreconf --verbose --install --force \
>>> -            ${EXTRA_AUTORECONF} $acpaths \
>>> -            || oefatal "autoreconf execution failed."
>>> +        eval "${AUTORECONF}" || oefatal 'autoreconf execution failed.'
>>>           if grep "^[[:space:]]*[AI][CT]_PROG_INTLTOOL" $CONFIGURE_AC >/dev/null; then
>>>               oenote Executing intltoolize
>>>               intltoolize --copy --force --automake
>>
>> Do you want/need to change the command/path or the arguments or both?
>
> I'll fx. set it to
>
> inherit autotools-autoreconf
> AUTORECONF = " \
>    ${LIBTOOLIZE} --force --copy \
> && aclocal -I . $acpaths --force \
> && automake -a --copy --force --gnu \
> && autoconf -I . $acpaths --force \
> "

Ah, I see.

As we typically use the name of the class as a prefix to such variables,
could we rename the variable to something like AUTORECONF_CMD instead of
just AUTORECONF?

/Esben
Morten Svendsen - Oct. 11, 2012, 6:18 a.m.
On 2012-10-10 15:04, Esben Haabendal wrote:
> As we typically use the name of the class as a prefix to such variables,
> could we rename the variable to something like AUTORECONF_CMD instead of
> just AUTORECONF?

Ok

/Morten
Esben Haabendal - Oct. 11, 2012, 6:53 a.m.
Morten Thunberg Svendsen <Morten.ThunbergSvendsen@prevas.dk> writes:

> On 2012-10-10 15:04, Esben Haabendal wrote:
>> As we typically use the name of the class as a prefix to such variables,
>> could we rename the variable to something like AUTORECONF_CMD instead of
>> just AUTORECONF?
>
> Ok

Merged to master branch.

/Esben

Patch

diff --git a/classes/autotools-autoreconf.oeclass b/classes/autotools-autoreconf.oeclass
index 825e8e4..6ff7469 100644
--- a/classes/autotools-autoreconf.oeclass
+++ b/classes/autotools-autoreconf.oeclass
@@ -6,6 +6,10 @@  CLASS_DEPENDS += "${DEPENDS_AUTORECONF}"
 DEPENDS_AUTORECONF ?= "native:glib-dev"
 
 EXTRA_AUTORECONF = ""
+AUTORECONF ?= "autoreconf --verbose --install --force \
+               ${EXTRA_AUTORECONF} $acpaths \
+               "
+
 acpaths = "__default__"
 
 pkgltdldir = "${STAGE_DIR}/${HOST_CROSS}${stage_datadir}/libtool"
@@ -76,9 +80,7 @@  do_autoreconf () {
             export _lt_pkgdatadir="${pkgltdldir}"
         fi
         oenote Executing autoreconf
-        autoreconf --verbose --install --force \
-            ${EXTRA_AUTORECONF} $acpaths \
-            || oefatal "autoreconf execution failed."
+        eval "${AUTORECONF}" || oefatal 'autoreconf execution failed.'
         if grep "^[[:space:]]*[AI][CT]_PROG_INTLTOOL" $CONFIGURE_AC >/dev/null; then
             oenote Executing intltoolize
             intltoolize --copy --force --automake