[oe] binconfig.bbclass breaks packages QA

Stanislav Brabec utx at penguin.cz
Fri Mar 28 11:16:05 UTC 2008


Richard Purdie wrote:

> I don't think you understand the way sysroot works properly. It changes
> the way gcc works internally, it looks in the sysroot instead
> of /usr/include. It does not mangle paths passed in externally though.

Sorry. You are true. It's sad non-feature.

> I've had a quick look and the problem is from cups which doesn't have
> a .pc file. The two solutions that spring to mind are:
> 
> 1. Add a .pc file to cups and have libgnomecups use it
> 2. Add some sed to the libgnomecups recipe to fix the bad paths after
> the compile completes.

We have many foo-config files embedded to other fooo-config or .pc.
System wide solution would be nicer.

3. Wrap gcc.

Never call cross-gcc directly, but use small wrapper, which will replace
any -I dir by -I sysroot/dir (if sysroot is not already a part of dir)
etc.

I am ready to write such wrapper, either in bash, or in shell+sed, or
possibly in C. I already sent one in bash to the list last year.

4. Move to -isysroot for cross builds and change the mangling style:
Replace -Idir by -I=dir and -I dir by -I =dir.

       -I dir
           ... If dir begins
           with "=", then the "=" will be replaced by the sysroot prefix; see
           --sysroot and -isysroot.

5. Patch gcc to implement 3 on gcc level.

-- 
Stanislav Brabec
http://www.penguin.cz/~utx/zaurus





More information about the Openembedded-devel mailing list