[oe] Staging - time to end the current mess - now with patches

Stanislav Brabec utx at penguin.cz
Wed Nov 4 12:15:19 UTC 2009


Richard Purdie wrote:

I agree with the new concept. I did not understand, why we need
do_stage, if we can mangle and stage DESTDIR directly.

> do_package takes a copy of ${D} into ${PKGD} and then runs the functions
> in PACKAGE_PREPROCESS_FUNCS which can alter this directory. The result
> is then packaged.

Maybe do_mangle and do_mangle_append or so may look better from an user
aspect and easier to port (just move extra commands from do_stage to
do_mangle_append). But PACKAGE_PREPROCESS_FUNCS should be OK as well.

> * Any do_stage where we do an autotools_stage_all can just be deleted.

And autotools_stage class will become just autotools.

> * Native packages with delete do_install should not anymore.

Thinking about it, do still make separate native recipes sense after
this change? Most of them could recycle nearly the same recipe then.
(Specially patched utilities would be an exception.)

I can imagine, that native build will be built from the host recipe,
just with a different setup.

> * Any do_stage function which installs extra things compared to
> do_install is very suspect and needs an explanation of why. Most likely
> do_install should be fixed and do_stage then deleted.

I agree. Shorter file list in do_stage might have had some sense to save
few megabytes of unused stuff in staging dir, but it is a small profit
from the double work.

> * If do_stage really needs to do something other than what is in
> do_install a function should be written to operate on SYSROOT_DESTDIR
> and that function should be appended to SYSROOT_PREPROCESS_FUNCS. There
> are some -native binary special cases which will need this but almost
> everything should *not* need this.

Example of special case may be guile. Mangling of guile-config must be
done in a special way (guile-config is a guile script, not shell
script). I cannot remember any other recipe, that needs it.

> Comments and experiments with the branch welcome. If I get some time
> I'll try and start adding a few conversions to the branch.

It's a bit unrelated, but I would like to see temp/run.do_... script for
splitting install dir to sub-package dirs and packages and
temp/log.do_... with QA output that warns about unpackaged files.

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





More information about the Openembedded-devel mailing list