-   Linux From Scratch (
-   -   Problem Adjusting the Toolchain (

Alex83 10-07-2010 12:36 PM

Problem Adjusting the Toolchain
Hi to all. I'm installing Linux from scratch using the LFS BOOK 6.7 and the the package LFS 6.7
I'm having a problem in Adjusting the Toolchain. When i type:

$LFS_TGT-gcc -dumpspecs | sed \
-e 's@/lib\(64\)\?/ld@/tools&@g' \
-e "/^\*cpp:$/{n;s,$, -isystem /tools/include,}" > $SPECS

i get this message:


[lfs@alex-laptop tools]$ sudo $LFS_TGT-gcc -dumpspecs | sed -e 's@/lib\(64\)\?/ld@/tools&@g' -e "/^\*cpp:$/{n;s,$, -isystem /tools/include,}" > $SPECS
bash: /mnt/lfs/tools/bin/../lib/gcc/i686-lfs-linux-gnu/4.5.1/specs: Permission denied

How can i resolve?

druuna 10-07-2010 12:41 PM


$ sudo $LFS_TGT-gcc -dumpspecs | sed -e 's@/lib\(64\)\?/ld@/tools&@g' -e "/^\*cpp:$/{n;s,$, -isystem /tools/include,}" > $SPECS


Where in the book does it say you have to use sudo? The whole LFS book is done by 2 users, without ever using sudo. These users are lfs for chapter 5 and root (from within a chrooted environment) for chapter 6.

Hope this helps.

Alex83 10-07-2010 12:46 PM

Without SUDO i have the same problem.

druuna 10-07-2010 12:57 PM


Then you forgot one or more steps leading up to this error. If you have to change any of the commands that are in the book to make things work then something is wrong and you should fix the problem before continuing.

Without knowing what you did and didn't do, I would suggest revisiting all the previous chapters to find out which mistake was made.

An educated guess would be the chown commands in 4.3. Adding the LFS User. If that is the case, you need to start over from 4.3 and remove all you already did from chapter 5.

Alex83 10-07-2010 01:01 PM

Thanks to all. I did the same things done in the book but i can't access it too

All times are GMT -5. The time now is 04:43 AM.