Patchwork [meta-fsl-arm,v2] linux-fslc: kernel build now needs GNU bc to work

login
register
mail settings
Submitter Lucas Dutra Nunes
Date Oct. 30, 2013, 3:46 p.m.
Message ID <1383147986-27406-1-git-send-email-ldnunes@ossystems.com.br>
Download mbox | patch
Permalink /patch/60791/
State Accepted
Delegated to: Otavio Salvador
Headers show

Comments

Lucas Dutra Nunes - Oct. 30, 2013, 3:46 p.m.
The kernel now needs to use GNU bc to be built since version 3.9. The following
commit message from the kernel explains the reason:

commit 70730bca1331fc50c3caacaea00439de1325bd6e
Author: H. Peter Anvin <hpa@zytor.com>
Date:   Thu Feb 14 15:13:55 2013 -0800

    kernel: Replace timeconst.pl with a bc script

    bc is the standard tool for multi-precision arithmetic.  We switched
    to Perl because akpm reported a hard-to-reproduce build hang, which
    was very odd because affected and unaffected machines were all running
    the same version of GNU bc.

    Unfortunately switching to Perl required a really ugly "canning"
    mechanism to support Perl < 5.8 installations lacking the Math::BigInt
    module.

    It was recently pointed out to me that some very old versions of GNU
    make had problems with pipes in subshells, which was indeed the
    construct used in the Makefile rules in that version of the patch;
    Perl didn't need it so switching to Perl fixed the problem for
    unrelated reasons.  With the problem (hopefully) root-caused, we can
    switch back to bc and do the arbitrary-precision arithmetic naturally.

    Signed-off-by: H. Peter Anvin <hpa@zytor.com>
    Cc: Andrew Morton <akpm@linux-foundation.org>
    Acked-by: Sam Ravnborg <sam@ravnborg.org>
    Signed-off-by: Michal Marek <mmarek@suse.cz>

Change-Id: I09ec3629bf47aa4768bd21b0cfb1ca6fb6f5b18f
Signed-off-by: Lucas Dutra Nunes <ldnunes@ossystems.com.br>
---
 recipes-kernel/linux/linux-fslc.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Otavio Salvador - Oct. 30, 2013, 3:52 p.m.
On Wed, Oct 30, 2013 at 1:46 PM, Lucas Dutra Nunes
<ldnunes@ossystems.com.br> wrote:
> The kernel now needs to use GNU bc to be built since version 3.9. The following
> commit message from the kernel explains the reason:
>
> commit 70730bca1331fc50c3caacaea00439de1325bd6e
> Author: H. Peter Anvin <hpa@zytor.com>
> Date:   Thu Feb 14 15:13:55 2013 -0800
>
>     kernel: Replace timeconst.pl with a bc script
>
>     bc is the standard tool for multi-precision arithmetic.  We switched
>     to Perl because akpm reported a hard-to-reproduce build hang, which
>     was very odd because affected and unaffected machines were all running
>     the same version of GNU bc.
>
>     Unfortunately switching to Perl required a really ugly "canning"
>     mechanism to support Perl < 5.8 installations lacking the Math::BigInt
>     module.
>
>     It was recently pointed out to me that some very old versions of GNU
>     make had problems with pipes in subshells, which was indeed the
>     construct used in the Makefile rules in that version of the patch;
>     Perl didn't need it so switching to Perl fixed the problem for
>     unrelated reasons.  With the problem (hopefully) root-caused, we can
>     switch back to bc and do the arbitrary-precision arithmetic naturally.
>
>     Signed-off-by: H. Peter Anvin <hpa@zytor.com>
>     Cc: Andrew Morton <akpm@linux-foundation.org>
>     Acked-by: Sam Ravnborg <sam@ravnborg.org>
>     Signed-off-by: Michal Marek <mmarek@suse.cz>
>
> Change-Id: I09ec3629bf47aa4768bd21b0cfb1ca6fb6f5b18f
> Signed-off-by: Lucas Dutra Nunes <ldnunes@ossystems.com.br>

I applied this to dora and master branches; thanks.

Patch

diff --git a/recipes-kernel/linux/linux-fslc.inc b/recipes-kernel/linux/linux-fslc.inc
index 6ebf833..20e1237 100644
--- a/recipes-kernel/linux/linux-fslc.inc
+++ b/recipes-kernel/linux/linux-fslc.inc
@@ -4,7 +4,7 @@ 
 DESCRIPTION = "Freescale Community mainline based Linux kernel"
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
-DEPENDS += "lzop-native"
+DEPENDS += "lzop-native bc-native"
 PROVIDES = "virtual/kernel linux-mainline"
 
 inherit kernel