[OE-core] [PATCH] glibc: Fix timestamp of plural.c after unpack

Mark Hatle mark.hatle at windriver.com
Tue Oct 11 08:37:52 UTC 2016


FYI this particular issue was observed by one of our customers.  Starting around
the YP 2.0 time period.  (We did not observe the problem prior to 2.0, but it
may be present.)

My understanding of the issue is that the extraction of the plural.c and
plural.y files happens so quickly that it is unclear to make if one is older
then the other -- so it sometimes uses bison to rebuild the plural.c.  This
produces a non-deterministic build.

The patch below addresses this by inserting a task between unpack and patch that
makes sure we use the plural.c from the archive.  If a later patch changes
plural.y -- it will then be reconstructed as expected from source.

--Mark

On 10/11/16 10:02 AM, Yuanjie Huang wrote:
> From: Yuanjie Huang <yuanjie.huang at windriver.com>
> 
> Source file plural.c might be updated with bison from plural.y, touch it
> before applying patches so that this file is consistent across builds.
> 
> Signed-off-by: Yuanjie Huang <yuanjie.huang at windriver.com>
> ---
>  meta/recipes-core/glibc/glibc.inc | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/meta/recipes-core/glibc/glibc.inc b/meta/recipes-core/glibc/glibc.inc
> index e85c704..5225dfc 100644
> --- a/meta/recipes-core/glibc/glibc.inc
> +++ b/meta/recipes-core/glibc/glibc.inc
> @@ -78,3 +78,10 @@ do_configure_prepend() {
>  }
>  
>  GLIBC_ADDONS ?= "nptl,libidn"
> +
> +# Ensure that plural.c is newer than its Bison source plural.y,
> +# unless the latter is patched.
> +do_unpack_workaround() {
> +	touch ${S}/intl/plural.c
> +}
> +addtask unpack_workaround after do_unpack before do_patch
> 




More information about the Openembedded-core mailing list