[oe] gcc Recipes

Khem Raj raj.khem at gmail.com
Wed Mar 31 17:25:03 UTC 2010


On Wed, Mar 31, 2010 at 4:28 AM, Richard Purdie <rpurdie at rpsys.net> wrote:
> I've just been looking over OE's gcc recipes and they really depress
> me :(. People touch them just enough to tweak their specific problem
> with no real thought going into the overall architecture and its a
> sprawling mess. I tackled some of this a while back. Sadly its just
> getting worse again.
>
> I've spent some time looking at them trying to identify what I consider
> to be the main sources of ugliness and how we can try and improve the
> situation. I think it might help to set a high level goal for the gcc
> recipes which would be:
>
>   All configuration for a given gcc version should be contained
>   within the high level version specific .inc file(gcc-X.Y.Z.inc).
>
> We'd therefore be frowning on version specific hacks in say the cross
> recipes only.
>
> It would follow that there would be a clear set of include files and a
> clear include structure and that almost all of the variant gcc recipes
> (gcc-cross-initial, gcc-cross-intermediate, gcc-cross-kernel,
> gcc-cross-sdk, gcc) would be boilerplate includes.
>
> Note that information about flags for the cross builds can be included
> in the main common version specific include file.
>
> To illustrate the kind of thing I mean, have a look at this commit:
>
> http://git.openembedded.net/cgit.cgi/openembedded/commit/?h=rpurdie/work-in-progress&id=35481122d7e484fb740ad9440fb4c70cb01de48f
>

in one place you removed DEPENDS that may not be correct. Because
DEPENDS get overwritten in gcc-cross-initial.inc


diff --git a/recipes/gcc/gcc-cross-initial_4.0.0.bb
b/recipes/gcc/gcc-cross-initial_4.0.0.bb
index 976cd96..1639511 100644
--- a/recipes/gcc/gcc-cross-initial_4.0.0.bb
+++ b/recipes/gcc/gcc-cross-initial_4.0.0.bb
@@ -1,6 +1,2 @@
require gcc-cross_${PV}.bb
require gcc-cross-initial.inc
-
-DEPENDS += "gmp-native mpfr-native"
-
-EXTRA_OECONF += "--disable-multilib --disable-libssp --disable-libmudflap"




> The nice thing about this is all of a sudden we have all the flags in
> the same place and it becomes obvious if something is wrong. There are a
> few things that raise an eyebrow there. It also becomes easier to
> abstract some of the gcc-X.Y.Z.inc data into a common include file
> (maybe a gcc-4.3.X.inc for example).

I this this is a good idea. We could even capture some bugs like in
some recipes we use EXTRA_OECONF_BASE += and in some EXTRA_OECONF_BASE
=

>
> Does anyone else fancy helping trying to clean this mess up. I'm happy
> to review some cleanup patches?

I plan to do some of this restructuring when I am back from my time
off in end of april.

>
> Cheers,
>
> Richard
>
>
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel at lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel
>




More information about the Openembedded-devel mailing list