Gentoo Archives: gentoo-alt

From: Marshall McMullen <marshall.mcmullen@×××××.com>
To: gentoo-alt@l.g.o
Subject: Re: [gentoo-alt] Re: gcc: binary path
Date: Fri, 20 Apr 2007 21:26:19
Message-Id: ecea57780704201425o207b001fme18317ad0d8d85cd@mail.gmail.com
In Reply to: Re: [gentoo-alt] Re: gcc: binary path by Fabian Groffen
1 Yep, that one works better for me, thanks for that! Incidently, I just
2 added something like this to the top of my ~/.bashrc file:
3
4 #!/bin/bash
5
6 # What is our prefix?
7 EPREFIX="$HOME/.overlay"
8
9 if [ -z ${IN_EPREFIX} ]; then
10 echo "Entering Gentoo Prefix ${EPREFIX}"
11
12 # set the prefix shell in the environment
13 SHELL=${SHELL##*/}
14 export SHELL=${EPREFIX}/bin/${SHELL}
15 export IN_EPREFIX=1
16 $SHELL -l || echo "Failed to start the Prefix shell, this is
17 probably because you didn't emerge the shell $SHELL" > /dev/stderr
18 fi
19
20
21
22 On 4/20/07, Fabian Groffen <grobian@g.o> wrote:
23 > Ok, what about attached patch?
24 >
25 > On 20-04-2007 22:38:31 +0200, Fabian Groffen wrote:
26 > > On 20-04-2007 15:21:45 -0500, Marshall McMullen wrote:
27 > > > I know this is an old thread, but what I was trying to say is that
28 > > > this script assumes that the shell used outside of prefix is in the
29 > > > same path as the one inside prefix. Specifically, there is no
30 > > > "/bin/bash" on our AIX 5.2, only /usr/bin/bash. Whereas in the
31 > > > prefix, it's looking for $EPREFIX/bin/bash. This line fouls things
32 > > > up:
33 > > >
34 > > > export SHELL=${EPREFIX}${SHELL}
35 > > >
36 > > > Since my shell is /usr/bin/bash It's going to look for
37 > > > $EPREFIX/usr/bin/bash, which is not installed in $EPREFIX, it's at
38 > > > $EPREFIX/bin/bash.
39 > >
40 > > Ok, you got a valid point there...
41 >
42 > --
43 > Fabian Groffen
44 > Gentoo on a different level
45 >
46 >
47
48
49 --
50 Marshall McMullen
51 marshall.mcmullen@×××××.com
52 mjmcmullen@×××××.net
53 mdmcmullen@××××××.com
54
55 In France, there's a popular saying about Linux that essentially translates as:
56 "Linux? You can get a less powerful system, but it will cost you more."
57 --
58 gentoo-alt@g.o mailing list