LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
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 01-01-2013, 07:21 PM   #1
kevstev
LQ Newbie
 
Registered: Jan 2013
Posts: 2

Rep: Reputation: Disabled
LFS 7.1 errors in chapter 6 when building gcc in 6.17


I ran into some issues building gcc the second time around. Everything was going very smoothly. I had built gcc, ran the tests, which ran mostly clean aside from mudflap, but then it would not install, it said it could not find a library- unfortunately I am not sure which, as I figured i just made a mistake and forgot to run make install on one of gmp, mpfr, or mpc. I double checked my steps, and ran it again. Still issues. I went back and ran the tests on mpfr, and gmp, and everything was good. I ran them on mpc, and it could not find libmpfr. I did a little searching on the net, and tried to EXPORT LD_LIBRARY_PATH=/usr/lib:/usr/lib64. This made the tests pass. I didn't feel good about having to change that, but pressed on.

I tried to clean build gcc at this point, deleting the gcc-build dir and recreating it, then ran the configure script. That ran ok, but when building I got the following error:

checking for x86_64-unknown-linux-gnu-gcc... /sources/gcc-build/./gcc/xgcc -B/sources/gcc-build/./gcc/ -B/usr/x86_64-unknown-linux-gnu/bin/ -B/usr/x86_64-unknown-linux-gnu/lib/ -isystem /usr/x86_64-unknown-linux-gnu/include -isystem /usr/x86_64-unknown-linux-gnu/sys-include
checking for suffix of object files... configure: error: in `/sources/gcc-build/x86_64-unknown-linux-gnu/libgcc':
configure: error: cannot compute suffix of object files: cannot compile'

I tried to really back things up at this point and unset LD_LIBRARY_PATH, and now when I run the configure script for gcc, it sats the C compiler cannot create executables. What a mess.

I checked that /tools/bin/gcc is there and is version 4.7.1, /usr/bin/gcc is there and is reporting as version 4.6.3

not sure where I went wrong or how to proceed here. How can I fix this?
 
Old 01-02-2013, 03:32 AM   #2
business_kid
Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware & Android
Posts: 6,136

Rep: Reputation: 526Reputation: 526Reputation: 526Reputation: 526Reputation: 526Reputation: 526
If you're in chapter 6, you have the static, and are building the dynamic. Can you go back to the beginning of ch. 6? It's been so long since I did it I forget.

Go back and wipe anyhow, that's my advice. It's quicker in the long run. With LFS, it's quicker even in the short run.
 
Old 01-02-2013, 10:19 AM   #3
kevstev
LQ Newbie
 
Registered: Jan 2013
Posts: 2

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by business_kid View Post
If you're in chapter 6, you have the static, and are building the dynamic. Can you go back to the beginning of ch. 6? It's been so long since I did it I forget.

Go back and wipe anyhow, that's my advice. It's quicker in the long run. With LFS, it's quicker even in the short run.
I tried that. Did not work unfortunately. I guess I will give this another stab from the beginning, but make an archive after chapter 5 is completed, so I can always return to that state if need be. Up until this point, I was actually shocked at how smooth everything was going.
 
Old 01-02-2013, 12:31 PM   #4
business_kid
Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware & Android
Posts: 6,136

Rep: Reputation: 526Reputation: 526Reputation: 526Reputation: 526Reputation: 526Reputation: 526
I only had that happen once. I ran it down to the gcc in the host operating system, or at least the binutils/glibc/headers/gcc combination.
 
  


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
LFS 7.0 - Chapter 6.9 building glibc jimmy_page_89 Linux From Scratch 5 11-27-2011 05:31 AM
libgcc Compile errors during LFS 6.8 chapter 5.5 (GCC pass 1) 1nKoGn17o Linux From Scratch 7 08-03-2011 03:07 AM
errors while building gcc-4.4.1 from lfs livecd with kernel 2.6.16.38 lucsar Linux From Scratch 5 01-13-2010 06:15 PM
LFS 6.3, messed up somewhere prior to chapter 6.12 (gcc), how to restart chapter 6? Funkster Linux From Scratch 2 12-24-2008 06:30 AM
Chapter 6 Building the LFS System brayden516 Linux From Scratch 1 05-01-2008 11:41 AM


All times are GMT -5. The time now is 08:20 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