Thomas Pegg wrote:
>> On thing on about using XML for the profiles, I've begun to not like it
> myself which why I've stopped using it for my own purposes short of
> doing updates for the profiles and making sure everything works as it
> should within the profiles. But an idea to consider for a potential new
> format might be something similar to gentoo's ebuilds, which in most
> ways are just shell functions in a text file.
I don't think I've looked that closely at gentoo's files, so I don't
know exactly what you mean, but jhalfs employs something that's probably
similar. When it extracts the commmands in the book, they end up looking
something like this:
#!/bin/sh
set -e
cd $PKGDIR
mkdir -v ../gcc-build
cd ../gcc-build
../gcc-4.0.2/configure --prefix=/tools \
--with-local-prefix=/tools --disable-nls --enable-shared \
--enable-languages=c
make bootstrap
make install
ln -vs gcc /tools/bin/cc
exit
The variable PKGDIR is the name of the unpacked directory for that
particular package. That variable is set via the unpacking of the
tarball before the above scriptlet is run. If you wanted to have finer
control over the build process (like isolating the configure, make and
install parts) it would take some rethinking.
--
JH