LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 02-21-2011, 10:31 AM   #1
redkangaroo2055
LQ Newbie
 
Registered: Feb 2011
Posts: 3

Rep: Reputation: 0
Exclamation Error with compiling GCC-4.5.1 - Pass 1


Hello. This is my first time doing an LFS build. The page to which I am referring to in the book is:
http://www.nl.linuxfromscratch.org/l...gcc-pass1.html
I have tried to stay as true to the directions as possible. I untarred gmp, mpc, and mpfr into the gcc-4.5.1 directory. I followed the directions as best I could, but no matter what I do, and I can't get gcc to compile properly.
As an additional note, I compiled binutils properly (as far as I know).

After doing the configure, and make, I get the following errors:

checking format of `long double' floating point... IEEE extended, little endian
checking for gmp.h... no
configure: error: gmp.h can't be found, or is unusable.
make[1]: *** [configure-mpfr] Error 1
make[1]: Leaving directory `/mnt/lfs/gcc-build/gcc-4.5.1'
make: *** [all] Error 2

The configure always seems to go correctly. I get the error above after I do 'make'. I assume that the main problem is that it can't find gmp.h. I initially assumed that it could have been that I downloaded a corrupted gmp-5.0.1.tar.bz2 because I couldn't find a gmp.h in it. After downloading it again, I still couldn't find it. After several more tries I reformatted the lfs drives a few times, restarting the project, but still always get the same error. Below a person had nearly an identical problem:
http://www.linuxquestions.org/questi...-5-1-a-837108/

But, the solution of the above url does not work for me. I followed the directions almost exactly, but the user in the url above deviated slightly which was the error.

Any and all help is appreciated.

Thanks
 
Old 02-22-2011, 01:20 AM   #2
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,

You keep saying tried to, as best as and almost exactly...... With the LFS book it is very simple: You follow the book to the letter, if you do not things will go wrong.

Without knowing which host you are using (is it LFS compliant?) and if the previous steps taken went the way they should, I can only give you the first steps needed for chapter 5.5:
Code:
$ cd $LFS/sources

# remove possible left overs:
$ rm -rf gcc-4.5.1 gcc-build

# untar gcc + enter created directory:
$ tar xjf gcc-4.5.1.tar.bz2
$ cd gcc-4.5.1

# untar and move mpfr, gmp and mpc:
$ tar -jxf ../mpfr-3.0.0.tar.bz2
$ mv -v mpfr-3.0.0 mpfr
$ tar -jxf ../gmp-5.0.1.tar.bz2
$ mv -v gmp-5.0.1 gmp
$ tar -zxf ../mpc-0.8.2.tar.gz
$ mv -v mpc-0.8.2 mpc

# create and enter gcc build dir:
$ mkdir -v ../gcc-build
$ cd ../gcc-build
From this point on you start with ../gcc-4.5.1/configure \ .....

Hope this helps.
 
Old 02-24-2011, 12:18 PM   #3
dalekirkwood
LQ Newbie
 
Registered: Feb 2011
Posts: 1

Rep: Reputation: 0
Thanks ,That seems to be worded better than in the book.
 
  


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
ERROR: During Make of GCC-4.5.1 - Pass 1 gau190188 Linux From Scratch 1 01-02-2011 02:31 PM
5.4. GCC-4.0.3 - Pass 1 compilation error :( gothicbob Linux From Scratch 1 08-06-2007 05:21 PM
Error Compiling GCC (1st Pass) in LFS 6.0 TGWDNGHN Linux From Scratch 1 06-30-2005 08:57 PM
GCC pass 1 error mugwump84 Linux From Scratch 2 05-10-2005 05:21 PM
Error configuring GCC, First Pass lloyd_smart Linux From Scratch 8 10-29-2004 11:45 AM

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

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