-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Eldad Zack wrote:
> Another detail I need to sort out - does portage use ${ROOT}/etc/ or
> just /etc ? Since I would need to store the useflags and customization for
> each remote host, it is a requirement.
There was some disagreement on bug 40302 as to whether or not some files (those
in /etc for example) should be relative to ROOT. We could have a config format
that works for multiple installations simultaneously (multiple values of ROOT)
or one that keeps them separate (different config files for each value of
ROOT). Given that make.conf, /etc/portage, and such were never designed to
work for multiple installations simultaneously, I think they should be relative
to ROOT.
> I've came across another problem as well.
> importing portage will go through its initialization, checking VDB and sorts,
> so that if I'd like in to switch a VDB I'll have to re-import portage. Since
> I do not know of a way to re-import portage in python, I've worked around
> this by changing ROOT env and then call portage via os.system calls.
> On my humble amd 2600 machine this yields a 8 seconds average per VDB change.
>
> Is there something I can do beside replicating the init code into a function,
> change root and recall the init function again?
>
> Is there a better way of doing this?
In python's built-in global function list you'll see one called reload(). If
you call reload(portage), it causes a re-import of the module.
Zac
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (GNU/Linux)
iD8DBQFEOUP2/ejvha5XGaMRAmTlAJ0ZuccDgmfvcKSyaDpgOvAD2hAYSwCg25X3
qKrPjkwQnh3IOY2bIvSUfJs=
=vG30
-----END PGP SIGNATURE-----
--
[email protected] mailing list