On Wed, 13 Jul 2011 11:54:40 +0100, Ed W wrote:
On 07/07/2011 16:27, Christopher Harvey wrote:
I was wondering if there was any interest in adding a script that
could
generate a bootable linux filesystem from a cross compiled target
directory.
I would be happy to work with you on this - however, I also saw on
Planet Gentoo something about a gentoaster project - possibly
related?
http://hexxeh.net/?p=328117725
possibly, but I don't understand the whole web based thing.
What I have is a very simple portage-a-like to support the case that
I
have several stages to my script.
- Mounting all necessary sources
- Building a base system
- Copying base to target ready to be imaged
- Image
- Unmount
Additionally I am trying a packaging system using aufs + squashfs, so
I
am building more than one target image and the whole gets stacked
together at the end
The scripting is fairly simple, but I guess this could develop into
some
best practices..?
yeah my script is a mess, but I still think it useful because it gets
all the basic steps down which I know would help some people.
Arguably this is re-inventing catalyst, but speaking from
inexperience,
catalyst appears to work best when the ebuilds are perfect and need
to
micro patching - for embedded builds some flexibility is very
helpful.
Well, catalyst was designed to build a gentoo image. I want to build
embedded images that have nothing gentoo specific about them. No
portage, no python, no eselect or anything else like that.
Patching ebuilds in mind: I have been experimenting with
/etc/portage/patches and also the bashrc for broad patching, eg where
some long standing patch or config customisation is necessary (eg
delete
some openrc file which makes no sense, or customise some udev config,
etc)
I've never heard of that file, '/etc/portage/patches', and can't find
it in man portage.
I guess if we could get this well written up then it would encourage
others to look at gentoo for embedded development? At the moment
it's
very powerful, but I sense there is a steep learning curve while you
develop your own build environment?
How do you think we should proceed?
There always is a learning curve for embedded and it will be impossible
to support every single configuration for every single board. Basically
my plan was to try to logically split all the steps in making a
filesystem image and put them into a clear well documented bash script,
then let users tweak it by calling hooks at each step. Hopefully after a
while if people start adding steps and options it would support most
base filesystem images people want to boot a machine with.
I can drop what a have so far into a git repo and we can go from there
taking the best from each of our scripts. Do you want to make the repo
or should I?
Ed W
-Chris