LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux From Scratch (http://www.linuxquestions.org/questions/linux-from-scratch-13/)
-   -   GCC first build for LFS, bootstrap error (http://www.linuxquestions.org/questions/linux-from-scratch-13/gcc-first-build-for-lfs-bootstrap-error-131850/)

Blibblob 01-05-2004 07:04 PM

GCC first build for LFS, bootstrap error
 
I have followed the LFS book 5.0 closely, and when I compile GCC-3.3.1, it says there is an error, first there are warnings about undefined references, then it says:
make[2]: *** [cc1] Error 1
make[2]: Leaving directory '/mnt/lfs/sources/gcc-build/gcc'
make[1]: *** [stage1_build] Error 2
make[1]: Leaving directory '/mnt/lfs/sources/gcc-build/gcc'
make: *** [bootstrap] Error 2

I have absolutely no idea what happened. I had built GCC just fine the first time(I restarted the process when Glibc wouldn't build at all), maybe there were errors the first time. I saw a few threads about this from before, but none really got answered as far as I could tell.

leonscape 01-05-2004 09:44 PM

What was the error directly before what you've put here. We need the lines with "error:" in them to help.

Danleff 01-06-2004 04:57 AM

Are you using Mandrake 9.0 or above as your host system?

Blibblob 01-06-2004 01:46 PM

Those are the only lines with error in them. Before that were a bunch of C files with undefined references. Most of what it tries to compile has undefined references. There shouldn't be anything wrong with the downloaded file, as it compiled previously without a problem(I restarted the process when Glibc couldn't find the rest of the information)

I am using Suse 8.2 as my host system.

cjcuk 01-06-2004 02:16 PM

Quote:

Originally posted by Blibblob
Those are the only lines with error in them. Before that were a bunch of C files with undefined references. Most of what it tries to compile has undefined references. There shouldn't be anything wrong with the downloaded file, as it compiled previously without a problem(I restarted the process when Glibc couldn't find the rest of the information)
This allows us to get a further idea. You see, saying there are undefined references does not really tell us what has happened - is it not finding headers or linking failing or x? Do you have any more details, ie, what it is unable to find?

leonscape 01-06-2004 05:19 PM

Undefined refrences, could be missing enviromental variables, or incorrect ones. what does
echo $PATH
echo $LD_LIBRARY_PATH
produce?

Are they pointing to the right places? do you have the sources in these places that the code is asking for. What about -L and -I paths, are they pointing to the right places?

Blibblob 01-06-2004 06:37 PM

The undefined references that I can see at the bottom are "targetm" and "regclass_map", before that I think I saw the x86 architecture.

$PATH is correct, it has the temporary folder for the new system at the front, and then the correct rest. And the book told me to unset LD_LIBRARY_PATH in my bash profile. And I, uh, don't understand what you mean by the two options.

leonscape 01-06-2004 06:57 PM

Yep, They refer to the x86 definitions for gcc, targetm = target machine, and regclass_map is the register map. It seems if these are the definitions it can't find, then there is some missing files in your source, or there in the wrong place.

Your looking for i386.h and similar.

Blibblob 01-07-2004 05:50 PM

Ah, I guess that make sense, they are missing(well, I can't find them), so I'll re-extract the file, see if that works.


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