[Clfs-support] problems with gcc-4.2.2-cross-compiler.../ now problems with chroot entry

Joe Ciccone jciccone at gmail.com
Tue Jan 15 16:06:16 PST 2008


Ken Moffat wrote:
> On Tue, Jan 15, 2008 at 10:55:20AM +0000, b-vol wrote:
>   
>> Greetings,
>>
>> thanks for your help.  the problem  with gcc not cross-compiling seems to be 
>> over. I am now having a problem with entering the chroot environment. I dont 
>> know if /tools/bin should be in the .bashrc search path.   Please find below 
>> details of the problem.
>>
>>
>> clfs:~$ echo $CLFS
>> /mnt/clfs
>> clfs:~$ su
>> Password:
>> root:/home/clfs# chroot "${CLFS}" /tools/bin/env -i \
>>     
>>>     HOME=/root TERM="${TERM}" PS1='\u:\w\$ ' \
>>>     PATH=/bin:/usr/bin:/sbin:/usr/sbin:/tools/bin \
>>>     /tools/bin/bash --login +h
>>>       
>> bash: chroot: command not found
>>
>>     
>  At this point, we use the version of chroot which is in root's PATH
> (using 'su' changes the PATH), so what that was set to in bashrc is not
> directly relevant.
>
>  Missing 'chroot' on the host ?
>
>  If that's the case, you *might* manage if you invoke
> /tools/bin/chroot instead of just 'chroot', don't know.  I think it
> ought to work, but I've never needed to try.
>   
Chroot is installed into /usr/sbin by default, so, doing a su from an
unprivileged user wouldn't have updated to path to include sbin.



More information about the Clfs-support mailing list