LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 02-16-2013, 12:31 PM   #1
luckylinuxluser
LQ Newbie
 
Registered: Feb 2013
Posts: 23

Rep: Reputation: Disabled
LFS V 7.2: Chapter 6.10: Issue w/ adjusting GCC specs file


Code:
gcc -dumpspecs | sed -e 's@/tools@@g' \
    -e '/\*startfile_prefix_spec:/{n;s@.*@/usr/lib/ @}' \
    -e '/\*cpp:/{n;s@$@ -isystem /usr/include@}' > \
    `dirname $(gcc --print-libgcc-file-name)`/specs
Output for this command is as follows:

Code:
bash: dirname $(gcc --print-libgcc-file-name)/specs: No such file or directory
I'm executing this code from the /sources directory. I already rm'ed the gcc-4.7.1 and gcc-build directory as per the General Compilation Instructions.

Any ideas on where I goofed?
 
Old 02-17-2013, 05:14 AM   #2
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374
There's not much to go on, but in general this points to a mistake made in this, or one of the previous chapters (yeah, I know that is rather general).

Have you checked if the directory that the command spits out does(n't) exist?
Code:
dirname $(gcc --print-libgcc-file-name)
 
Old 02-17-2013, 12:35 PM   #3
luckylinuxluser
LQ Newbie
 
Registered: Feb 2013
Posts: 23

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by druuna View Post
There's not much to go on, but in general this points to a mistake made in this, or one of the previous chapters (yeah, I know that is rather general).

Have you checked if the directory that the command spits out does(n't) exist?
Code:
dirname $(gcc --print-libgcc-file-name)
Yes I have checked that directory (/tools/lib/gcc/i686-pc-linux-gnu/4.7.1) and it does exist. It's only missing the ""/specs file.

Last edited by luckylinuxluser; 02-17-2013 at 12:40 PM.
 
Old 02-17-2013, 12:44 PM   #4
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374
Quote:
Originally Posted by luckylinuxluser View Post
Yes I have checked that directory and it does exist. It's only missing the ""/specs file.
That is correct (the missing specs part). This output: `dirname $(gcc --print-libgcc-file-name)`/specs is given to sed to be used as output file.

Are you 100% sure the command was copied correctly? I do get the feeling you might have used 'dirname $(gcc --print-libgcc-file-name)'/specs instead of `dirname $(gcc --print-libgcc-file-name)`/specs (single quotes vs back-ticks).
 
Old 02-17-2013, 12:57 PM   #5
luckylinuxluser
LQ Newbie
 
Registered: Feb 2013
Posts: 23

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by druuna View Post
That is correct (the missing specs part). This output: `dirname $(gcc --print-libgcc-file-name)`/specs is given to sed to be used as output file.

Are you 100% sure the command was copied correctly? I do get the feeling you might have used 'dirname $(gcc --print-libgcc-file-name)'/specs instead of `dirname $(gcc --print-libgcc-file-name)`/specs (single quotes vs back-ticks).
You're right. Thank you very much.

I had this very same issue before and can't believe I didn't check to make sure I was using the right characters... My host system doesn't have a GUI so I can't copy and paste.

Thank you.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
LFS7.2, problem when chapter 6.10: adjusting the toolchain, can not change gcc specs SuMZ Linux From Scratch 7 01-11-2013 07:31 PM
[SOLVED] LFS 7.0 - 6.10 Re-adjusting the toolchain - No specs file derstephen Linux From Scratch 2 12-01-2011 05:20 PM
[SOLVED] LFS Book 6.8 Chapter 6.10 Re-adjusting the toolchain eliadk Linux From Scratch 10 10-11-2011 04:50 AM
[SOLVED] gcc not reading specs file LFS Section 6.7.1 Bertical Linux From Scratch 1 10-16-2010 05:50 AM
LFS chapter 5 adjusting the tool chain JusCrzn Linux From Scratch 1 12-20-2004 06:32 PM


All times are GMT -5. The time now is 11:19 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration