Summary: | ROOT configuration file support | ||
---|---|---|---|
Product: | Portage Development | Reporter: | Shannon Glenn Barber <shannon.barber> |
Component: | Core | Assignee: | Portage team <dev-portage> |
Status: | RESOLVED DUPLICATE | ||
Severity: | minor | CC: | eldad, foxtrott, radek, sascha-gentoo-bugzilla |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: | patch to allow different config files than /etc/make.conf |
Description
Shannon Glenn Barber
2004-02-03 10:58:22 UTC
*** Bug 36652 has been marked as a duplicate of this bug. *** Created attachment 25226 [details, diff]
patch to allow different config files than /etc/make.conf
Ok, this patch adds the following logic:
1. check for a PORTAGE_CONFIGFILE environment variable, if present use that
file instead of make.conf
2. check if we have a ROOT env variable that is not "/", if so use
$ROOT+/make.conf as configfile
3. if 1) and 2) don't apply use /etc/make.conf
Anything more that's needed ?
For 2, shouldn't it be $ROOT/etc/make.conf? Yep, it's right in the code, just wrong in the description ;) IMO, emerge should use /etc/make.conf even if ROOT is set. Because ROOT is not chroot.. And I agree with Nakano. I agree with the logic of the patch. If you're cross compiling and merging to a $ROOT to create a embedded image, the arch, chost, cflags, use flags, etc. will most likely be different. Otherwise, it becomes problematic overriding all of the host machine's settings everytime you do some merging. When you merge to $ROOT, the /var/db/pkg entries go to $ROOT/var/db/pkg already, so it seems logical that a $ROOT/etc/make.conf be used if it exists. Chris is right. I've almost gone crazy when trying to compile for arm and it failed with some weird error which I found (after hours) was caused by improper CFLAGS (-march=pentium3)... I've heard some rumours about CONFIG_ROOT var which would drive this but I cannot find it in bugzilla now... :-( (In reply to comment #7) > When you merge to $ROOT, the /var/db/pkg entries go to $ROOT/var/db/pkg already, so it seems logical that a $ROOT/etc/make.conf be used if it exists. Add /etc/make.profile and /etc/portage/** to the list. It seems that /var/cache/edb and /var/lib/portage already work properly. Regardless of portage support, proper $ROOT support (especially for including/linking of libraries) seems to be lacking in many ebuilds and/or upstream build systems. VDB, though is not working correctly. I've filed a bug 129054 about this. Config files will likely be controlled by a separate variable so that they can be stored at a location separate from $ROOT if desired. See bug 73350. *** This bug has been marked as a duplicate of 73350 *** |