I am attempting, with varying amounts of success to use the Gentoo package system to manage embedded builds in Scratchbox. There are a number of interactions, and it's not always clear how to best go about fixing problems. Currently I am adopting the following strategy:

1. Use a stage 1 tarball to get the basic tools, put these into a scratchbox host compiler environment. This can somewhat poison the scratchbox environment, so a selective untarring might be a good idea.
2. Get a recent portage snapshot into /usr/portage in the host environment
3. In the target environment, link /usr/lib/portage and /usr/portage to the host elements
4. copy the /etc files to the target.
5. manually compile su for the host, scratchbox doesn't have it, and it's occasionally useful. 6. Add a 99local to /etc/env.d in the target, with all the useful scratchbox bin directories there.
7. do all emerging, etc using fakeroot
8. search the portage tools for absolute references to scripts, and link those to the real things (scripted search and link)

All portage and build tools are added to the host env, and become visible in the target via the paths.

It *nearly* works! Various gotchas show up to slow things down. In particular gcc -print-file-name=<library.so> doesn't work for libraries added by compilation in the target environment. Does anyone know how to fix this?

Is what I have outlined a reasonable approach? Is anyone doing anything similar?


_______________________________________________
Scratchbox-users mailing list
Scratchbox-users@lists.scratchbox.org
http://lists.scratchbox.org/cgi-bin/mailman/listinfo/scratchbox-users

Reply via email to