[oe] [PATCH] base.bbclass: introduce COMPATIBLE_TARGET_SYS

Frans Meulenbroeks fransmeulenbroeks at gmail.com
Mon Jul 12 06:24:29 UTC 2010


2010/7/11 Phil Blundell <philb at gnu.org>:
> On Sat, 2010-07-10 at 18:19 +0200, Frans Meulenbroeks wrote:
>> This patch introduces COMPATIBLE_TARGET_SYS
>> It is similar to COMPATIBLE_MACHINE but where COMPATIBLE_MACHINE
>> is used to specify that a certain recipe is for a certain machine
>> COMPATIBLE_TARGET_SYS can be used to specify that a certain recipe
>> is for a certain architecture.
>>
>> Signed-off-by: Frans Meulenbroeks <fransmeulenbroeks at gmail.com>
>
> Per our IRC discussion, I am still not totally comfortable with
> introducing this extra overhead to all users of base.bbclass.  In the
> vast majority of cases (i.e. essentially all packages apart from
> toolchain ones), TARGET_SYS == HOST_SYS and hence checking both of them
> is just a waste of time.  But I do take your point about wanting to mop
> up both cross and regular gcc.

Wrt the additional overhead. That is indeed a pity. Then again the
overhead is not that big (but ofc every penny counts).

A possible solution would be to rewrite the complete way variables are
stored and compared.
E.g. if the constraints would be hashed adding an additional variable
and constraint would simply be an extension to the hash table
(and not take up cpu cycles expect if there is hash clash).

But imho this is not something done overnight.

BTW: there are other ways to reduce parsing time, but people do not
like it if I mention them :-)
>
> I think I would prefer to see the TARGET_SYS check placed in some common
> place which can be included by all toolchain recipes (and, possibly, a
> general ongoing effort to reduce the number of non-cross recipes which
> refer explicitly to TARGET_xx when HOST_xx would do).  But I don't have
> a very strong view on the matter and, if there is a general consensus in
> favour of putting this in base.bbclass, I will go along with that.

Thanks.

Any other opinions? Acks ?

BTW: i did a quick peek at the cross stuff that we have: currently
there are four recipes that have a cross variant:
gcc, binutils, gdb and libtool.
For nios2 I didn't even have a look at the last two.

Have fun! Frans




More information about the Openembedded-devel mailing list