gcc in chroot

Jeremy C. Reed reed at reedmedia.net
Thu Jun 15 14:27:45 MST 2006


On Thu, 15 Jun 2006, Eric "Shubes" wrote:

> When I try to build a source package in the chroot jail, I get the following
> message:
> 
> gcc: installation problem, cannot exec `cc1': No such file or directory
> 
> I can't figure out why gcc can't find cc1. It's in the same place in both
> environments:
> /usr/lib/gcc-lib/i386-redhat-linux/3.2.3/cc1
> /usr/libexec/gcc/i386-redhat-linux/3.4.3/cc1
> and permissions/owners are the same (I'm running as root anywise).

Use strace (or other tracing or debugger) to see which cc1 your gcc is 
trying to use. Although both above examples look good to me.

Also run gcc -v to see if you are using the same gcc version.

Also make sure you can run it while in the chroot, for example:

$ echo | /usr/lib/gcc-lib/i386-redhat-linux/3.2.3/cc1

Execution times (seconds)
 TOTAL                 :   0.01             0.00             0.00

I frequently do software (and package) builds in chroot jails on Linux.


 Jeremy C. Reed

echo '9,J8HD,fDGG8B@?:536FC5=8 at I;C5?@H5B0D at 5GBIELD54DL>@8L?:5GDEJ8LDG1' |\
sed ss,s50EBsg | tr 0-M 'p.wBt SgiIlxmLhan:o,erDsduv/cyP'


More information about the PLUG-discuss mailing list