Thomas de Grenier de Latour wrote:
Hi,
I'm currently working on a project that involve distribution of a
custom profile for portage. I've recently switched it to cascading
whereas it was flat before. No doubt that's much more convenient,
but i still have a problem for the "parent" file. What i would
like is a way to make it reference "default-linux/ppc/2004.3",
wherever the user install my profile and wherever his portage tree
actually is.
That has already briefly been discussed on gentoo-dev, but the
question was left opened:
http://thread.gmane.org/gmane.linux.gentoo.devel/23508
My idea was be to make portage support parent files with paths
like "${PORTDIR}/profiles/default-linux/ppc/2004.3". Currently,
that doesn't work for two reasons:
- absolute paths are not supported, but that's really a one line
change to fix it (see attached patch for a possible solution)
- the "${PORTDIR}" should be evaluated to "/usr/portage" or
something else depending if the user changed it in his make.conf.
The portage_utils.py "varexpand()" function seems to be a good
candidate for that task, but the problem is that when the profiles
list is built, $PORTDIR value is not known yet (the obvious
reason being that it can be defined and redefined by profiles,
so that's basically a chicken and egg dilemma).
So, does anyone has ideas on how parent's handling could be
modified so that it's possible to distribute custom profiles that
work for everybody? (if possible without hacks like requirering
that the user has a symlink to his portage tree at a well known
place or things like that)
Thanks,
Have make.profile point to whatever parent profile you like ( base,
default-linux, whatever ) and put all the custom stuff in
/etc/portage/profile. No nasty portage hacks, and I'm pretty sure all
of the files are supported. However, confirmation from a dev would be
handy ;) This way you get the benifits of whichever parent profile you
choose, but you get all your custom stuff as well.
<snip code>
--
[email protected] mailing list
--
Alec Warner
Spartasoft Secretary ( spartasoft.msu.edu )
Junior Computer Science
Michigan State University
[EMAIL PROTECTED]
--
[email protected] mailing list