LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.

Notices


Reply
  Search this Thread
Old 11-07-2011, 02:54 AM   #1
devilboy09
Member
 
Registered: Nov 2011
Location: Iran
Distribution: Debian, CentOS, LFS, CloudLinux
Posts: 377

Rep: Reputation: 10
ToolChain error


i have a problem with adjusting toolchain process
i'm reading LFS 7 and my dist is debian squeeze

also im in /mnt/lfs/sources directory with lfs account
when i issue this command:
SPECS=`dirname $($LFS_TGT-gcc -print-libgcc-file-name)`/specs
i got this error:
bash: i686-lfs-linux-gnu-gcc: command not found
dirname: missing operand
Try `dirname --help' for more information.

what's wrong guys?
 
Old 11-07-2011, 05:16 AM   #2
devilboy09
Member
 
Registered: Nov 2011
Location: Iran
Distribution: Debian, CentOS, LFS, CloudLinux
Posts: 377

Original Poster
Rep: Reputation: 10
i did a few things and when i issue this command:
cat /specs | grep ':/tools'
here's the output:
%{muclibc:/tools/lib/ld-uClibc.so.0;:%{mbionic:/system/bin/linker;:/tools/lib/ld-linux.so.2}}

is this correct?
 
Old 11-07-2011, 07:38 AM   #3
onebuck
Moderator
 
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: SlackwareŽ
Posts: 13,925
Blog Entries: 44

Rep: Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159
Moved: This thread is more suitable in <Linux From Scratch> and has been moved accordingly to help your thread/question get the exposure it deserves.
 
Old 11-07-2011, 08:30 AM   #4
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi,
Quote:
Originally Posted by devilboy09 View Post
when i issue this command:
SPECS=`dirname $($LFS_TGT-gcc -print-libgcc-file-name)`/specs
i got this error:
bash: i686-lfs-linux-gnu-gcc: command not found
If this executable cannot be found then you probably messed up the previous step (5.7. Glibc-2.14.1), which installed it.

Assuming you did not make a typo in the SPECS=`dirname $($LFS_TGT-gcc -print-libgcc-file-name)`/specs, it looks ok and the content of $LFS_TGT also seems ok (i686-lfs-linux-gnu). Run uname -m to check the i686 part.

If I look at your LFS post history I see you had a lot of problems. My advise: Start from scratch again to make sure all your previous problems are solved.

Hope this helps.
 
Old 11-07-2011, 08:58 AM   #5
devilboy09
Member
 
Registered: Nov 2011
Location: Iran
Distribution: Debian, CentOS, LFS, CloudLinux
Posts: 377

Original Poster
Rep: Reputation: 10
thanks for your answer
content of LFS_TGT is equal to $(uname -m)-lfs-linux-gnu
i found i686-pc-linux-gnu-gcc under /tools/bin, but there was no i686-lfs-linux-gnu-gcc.i'm sure i did everything right so far.
could you tell me where should i look for i686-lfs-linux-gnu-gcc.i'm confuse aboute the location of i686-lfs-linux-gnu-gcc.
 
Old 11-07-2011, 09:14 AM   #6
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi,
Quote:
Originally Posted by devilboy09
i found i686-pc-linux-gnu-gcc under /tools/bin, but there was no i686-lfs-linux-gnu-gcc.i'm sure i did everything right so far.
could you tell me where should i look for i686-lfs-linux-gnu-gcc.i'm confuse aboute the location of i686-lfs-linux-gnu-gcc.
Although I cannot check it at this moment, I do believe it should reside in (/mnt/lfs)/tools/bin.

You do mention having this one: i686-pc-linux-gnu-gcc. If that is the case than you did make a mistake somewhere down the road.

PS: I made a mistake in my previous reply: i686-lfs-linux-gnu-gcc is installed during the build of gcc, and _not_ glibc as mentioned before!

Hope this helps.
 
Old 11-07-2011, 03:42 PM   #7
devilboy09
Member
 
Registered: Nov 2011
Location: Iran
Distribution: Debian, CentOS, LFS, CloudLinux
Posts: 377

Original Poster
Rep: Reputation: 10
i'm doing LFS from begining.i'm in chapter 5 compiling gcc.i issued make and make install command and they went well.but when i want to create the symbolic link i got this error:

root@ubuntu:/mnt/lfs/sources/gcc-build# ln -vs libgcc.a `$LFS_TGT-gcc -print-libgcc-file-name | \
> sed 's/libgcc/&_eh/'`
No command '-gcc' found, did you mean:
Command 'cgcc' from package 'sparse' (multiverse)
Command 'gcc' from package 'gcc' (main)
Command 'gcc' from package 'pentium-builder' (universe)
-gcc: command not found

what should i do,should i put a "./" before $LFS_TGT-gcc"?
 
Old 11-07-2011, 03:47 PM   #8
devilboy09
Member
 
Registered: Nov 2011
Location: Iran
Distribution: Debian, CentOS, LFS, CloudLinux
Posts: 377

Original Poster
Rep: Reputation: 10
i sat the LFS_TGT as root and issued the command again(as you may know i can't issue this command as lfs ):

root@ubuntu:/mnt/lfs/sources/gcc-build# ln -vs libgcc.a `$LFS_TGT-gcc -print-libgcc-file-name | \
sed 's/libgcc/&_eh/'`
i686-lfs-linux-gnu-gcc: command not found
`./libgcc.a' -> `libgcc.a'

is this correct?
 
Old 11-07-2011, 04:44 PM   #9
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: /LFS/Debian
Posts: 2,511
Blog Entries: 1

Rep: Reputation: 412Reputation: 412Reputation: 412Reputation: 412Reputation: 412
In post7 it shows you as root
Code:
root@ubuntu:/mnt/lfs/sources/gcc-build# ln -vs libgcc.a `$LFS_TGT-gcc -print-libgcc-file-name | \
the packages should be built as user "lfs"
If this is true have you rebuilt the previous as lfs or root?

Last edited by spiky0011; 11-07-2011 at 04:50 PM.
 
Old 11-08-2011, 12:48 AM   #10
devilboy09
Member
 
Registered: Nov 2011
Location: Iran
Distribution: Debian, CentOS, LFS, CloudLinux
Posts: 377

Original Poster
Rep: Reputation: 10
i unzip,configure and make the packages as lfs user and make install it as root
i can't make sym link as lfs. permission denied!

Last edited by devilboy09; 11-08-2011 at 01:18 AM.
 
Old 11-08-2011, 01:30 AM   #11
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi,
Quote:
Originally Posted by devilboy09 View Post
i unzip,configure and make the packages as lfs user and make install it as root
i can't make sym link as lfs. permission denied!
All the steps in chapter 5 should be done as user lfs!

Hope this helps.
 
Old 11-08-2011, 05:13 AM   #12
devilboy09
Member
 
Registered: Nov 2011
Location: Iran
Distribution: Debian, CentOS, LFS, CloudLinux
Posts: 377

Original Poster
Rep: Reputation: 10
i konw and i did everything as lfs ,so far.but i can't make sym link.maybe i don't have permission.what should i do?
 
Old 11-08-2011, 06:09 AM   #13
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: /LFS/Debian
Posts: 2,511
Blog Entries: 1

Rep: Reputation: 412Reputation: 412Reputation: 412Reputation: 412Reputation: 412
Are you sure there was no problem in chapter 4.3 with chown the directories
 
Old 11-08-2011, 06:16 AM   #14
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi,
Quote:
Originally Posted by devilboy09 View Post
i konw and i did everything as lfs ,so far.but i can't make sym link.maybe i don't have permission.what should i do?
I really doubt that:
Quote:
Originally Posted by devilboy09
i unzip,configure and make the packages as lfs user and make install it as root
You either used root to do the make install step, or you gave us the wrong information. The permission denied message points to doing the make install step as root user.....

Hope this helps.
 
Old 11-08-2011, 07:28 AM   #15
devilboy09
Member
 
Registered: Nov 2011
Location: Iran
Distribution: Debian, CentOS, LFS, CloudLinux
Posts: 377

Original Poster
Rep: Reputation: 10
sure i did make install as root . because i don't have the permission. you mean i have to be able to make install as lfs user?
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Toolchain skeeters Programming 3 12-11-2009 02:33 PM
Chap 5.2 make embryo toolchain error teraphex Linux From Scratch 2 03-20-2007 11:31 PM
about toolchain nesta Linux - Kernel 4 01-23-2007 05:30 AM
Possible Error in Book -- Adjusting Toolchain suma17 Linux From Scratch 9 10-13-2005 04:06 AM
5.9. Adjusting the Toolchain - Error Spudds Linux From Scratch 6 02-23-2005 09:22 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 11:10 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration