Summary: | ebuild.sh lets /etc/profile.env override /etc/portage/bashrc | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Ed Catmur <ed> |
Component: | [OLD] Core system | Assignee: | Portage team <dev-portage> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | robbat2, robmoss |
Priority: | High | Keywords: | InVCS |
Version: | unspecified | ||
Hardware: | All | ||
OS: | All | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 44209, 51061 |
Description
Ed Catmur
2004-05-14 15:16:54 UTC
Sorry, that should be =================================================================== RCS file: /usr/sbin/ebuild.sh,v retrieving revision 1.1 diff -up -r1.1 /usr/sbin/ebuild.sh --- /usr/sbin/ebuild.sh 2004/05/14 22:13:08 1.1 +++ /usr/sbin/ebuild.sh 2004/05/14 22:20:16 @@ -64,6 +64,10 @@ fi [ ! -z "$OCC" ] && export CC="$OCC" [ ! -z "$OCXX" ] && export CXX="$OCXX" +if [ -f /etc/portage/bashrc ]; then + source /etc/portage/bashrc +fi + export PATH="/sbin:/usr/sbin:/usr/lib/portage/bin:/bin:/usr/bin:${ROOTPATH}" [ ! -z "$PREROOTPATH" ] && export PATH="${PREROOTPATH%%:}:$PATH" Aargh, of course I did that against /usr/sbin/ebuild.sh not /usr/lib/portage/bin/ebuild.sh. Sorry for the bugspam. Also this patch puts it after PATH is munged as bashrc may wish to alter that as well. --- /usr/lib/portage/bin/ebuild.sh 2004/05/14 22:23:06 1.1 +++ /usr/lib/portage/bin/ebuild.sh 2004/05/14 22:23:54 @@ -67,6 +67,10 @@ fi export PATH="/sbin:/usr/sbin:/usr/lib/portage/bin:/bin:/usr/bin:${ROOTPATH}" [ ! -z "$PREROOTPATH" ] && export PATH="${PREROOTPATH%%:}:$PATH" +if [ -f /etc/portage/bashrc ]; then + source /etc/portage/bashrc +fi + # Grab our new utility functions. source /usr/lib/portage/bin/extra_functions.sh The problem is repetition... BASH_RC is an environment variable... and left alone it does bad things by using custom root user rc's. If you source it, you're duplicating the data. This potentially can cause inconsistencies if the variables are not solidly defined. It needs to be looked into further. Ok. /etc/portage/bashrc is now sourced immediately after profile.env.
>=portage-2.0.51_pre9
*** Bug 51552 has been marked as a duplicate of this bug. *** Bug has been fixed and released in stable portages on or before 2.0.51-r2 |