LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
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 12-14-2012, 05:25 AM   #1
Prabhu.Are
LQ Newbie
 
Registered: Oct 2012
Posts: 24

Rep: Reputation: Disabled
(LFS2.7) Glibc make error "cant find -lgcc_eh"


Hi, I'm working on LFS7.2. I successfully compiled Binutils, GCC and LINUX API, while doing "make" for Glibc I'm getting this error

/mnt/lfs/tools/bin/../lib/gcc/i686-lfs-linux-gnu/4.7.2/../../../../i686-lfs-linux-gnu/bin/ld:
cannot find -lgcc_eh collect2:error: ld returned 1 exit status
make[2]: *** [/mnt/lfs/sources/glibc-build/elf/sln] Error 1
make[2]: Leaving directory `/mnt/lfs/sources/glibc-2.16.0/elf'
make[1]: *** [elf/others] Error 2
make[1]: Leaving directory `/mnt/lfs/sources/glibc-2.16.0'
make: *** [all] Error 2

Could someone assist me to resolve this.
 
Old 12-14-2012, 07:09 AM   #2
Lancelot1
Member
 
Registered: Dec 2007
Location: Amsterdam
Distribution: (K)Ubuntu
Posts: 102

Rep: Reputation: 15
is this in chapter 5 or 6?
 
Old 12-14-2012, 07:16 AM   #3
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: Ubuntu 12.04/12.10/13.04/LFS/Centos6.3/Debain/PCBSD/Mageia 3
Posts: 1,614
Blog Entries: 1

Rep: Reputation: 226Reputation: 226Reputation: 226
Hi

Post output of version-check
 
Old 12-14-2012, 08:41 AM   #4
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371
Quote:
Originally Posted by Prabhu.Are View Post
Hi, I'm working on LFS7.2. I successfully compiled Binutils, GCC and LINUX API, while doing "make" for Glibc I'm getting this error

/mnt/lfs/tools/bin/../lib/gcc/i686-lfs-linux-gnu/4.7.2/../../../../i686-lfs-linux-gnu/bin/ld:
cannot find -lgcc_eh collect2:error: ld returned 1 exit status
make[2]: *** [/mnt/lfs/sources/glibc-build/elf/sln] Error 1
make[2]: Leaving directory `/mnt/lfs/sources/glibc-2.16.0/elf'
make[1]: *** [elf/others] Error 2
make[1]: Leaving directory `/mnt/lfs/sources/glibc-2.16.0'
make: *** [all] Error 2

Could someone assist me to resolve this.
Are you sure you did not forget the last command from 5.5. GCC-4.7.1 - Pass 1

This command:
Code:
ln -vs libgcc.a `$LFS_TGT-gcc -print-libgcc-file-name | sed 's/libgcc/&_eh/'`
 
Old 12-14-2012, 02:34 PM   #5
Prabhu.Are
LQ Newbie
 
Registered: Oct 2012
Posts: 24

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Lancelot1 View Post
is this in chapter 5 or 6?
This is chapter 5.7.2 in LFS 7.2
 
Old 12-14-2012, 02:35 PM   #6
Prabhu.Are
LQ Newbie
 
Registered: Oct 2012
Posts: 24

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by spiky0011 View Post
Hi

Post output of version-check
MY version-check is

Quote:
bash, version 4.1.5(1)-release
/bin/sh -> /bin/bash
Binutils: (GNU Binutils for Ubuntu) 2.20.51-system.20100908
bison (GNU Bison) 2.6
yacc not found
bzip2, Version 1.0.5, 10-Dec-2007.
Coreutils: 8.5
diff (GNU diffutils) 3.0
find (GNU findutils) 4.4.2
GNU Awk 4.0.0
/usr/bin/awk -> /usr/bin/mawk
gcc (Ubuntu/Linaro 4.4.4-14ubuntu5) 4.4.5
(Ubuntu EGLIBC 2.12.1-0ubuntu6) 2.12.1
GNU grep 2.6.3
gzip 1.3.12
Linux version 2.6.35-22-generic (buildd@rothera) (gcc version 4.4.5 (Ubuntu/Linaro 4.4.4-14ubuntu4) ) #33-Ubuntu SMP Sun Sep 19 20:34:50 UTC 2010
m4 (GNU M4) 1.4.16
GNU Make 3.81
GNU patch 2.7
Perl version='5.10.1';
GNU sed version 4.2.1
tar (GNU tar) 1.23
Texinfo:
xz (XZ Utils) 4.999.9beta
gcc compilation OK
 
Old 12-14-2012, 02:45 PM   #7
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: Ubuntu 12.04/12.10/13.04/LFS/Centos6.3/Debain/PCBSD/Mageia 3
Posts: 1,614
Blog Entries: 1

Rep: Reputation: 226Reputation: 226Reputation: 226
Hi

Did you try what druuna has put and also mentioned in the mailing list
 
Old 12-14-2012, 03:16 PM   #8
Prabhu.Are
LQ Newbie
 
Registered: Oct 2012
Posts: 24

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by druuna View Post
Are you sure you did not forget the last command from 5.5. GCC-4.7.1 - Pass 1

This command:
Code:
ln -vs libgcc.a `$LFS_TGT-gcc -print-libgcc-file-name | sed 's/libgcc/&_eh/'`
druuna What you doubt is correct, last time I forgot to create a symbolic link after the compilation of GCC. So I rollback and I did it, now Glibc "make" is giving the expected output.

ln -vs libgcc.a `$LFS_TGT-gcc -print-libgcc-file-name | sed 's/libgcc/&_eh/'

Now I'm pursuing the pass2

Thanks a lot.
 
Old 12-14-2012, 03:19 PM   #9
Prabhu.Are
LQ Newbie
 
Registered: Oct 2012
Posts: 24

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Prabhu.Are View Post
MY version-check is
spiky0011, In my version-check textinfo is missing...

could you specify me which package I need to install.
 
Old 12-14-2012, 03:21 PM   #10
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: Ubuntu 12.04/12.10/13.04/LFS/Centos6.3/Debain/PCBSD/Mageia 3
Posts: 1,614
Blog Entries: 1

Rep: Reputation: 226Reputation: 226Reputation: 226
No that is installed dont worry. It gives a different output if not installed

Last edited by spiky0011; 12-14-2012 at 03:32 PM.
 
Old 12-14-2012, 03:29 PM   #11
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: Ubuntu 12.04/12.10/13.04/LFS/Centos6.3/Debain/PCBSD/Mageia 3
Posts: 1,614
Blog Entries: 1

Rep: Reputation: 226Reputation: 226Reputation: 226
Just looked through your version-check there are some problems.

/usr/bin/awk -> /usr/bin/mawk you need to install gawk

yacc not found

Also what is the output of
Code:
makeinfo --version
Sorry I missed these,
and on another note it wold be best to start again when fixed
 
Old 12-15-2012, 08:49 PM   #12
Prabhu.Are
LQ Newbie
 
Registered: Oct 2012
Posts: 24

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by spiky0011 View Post
Just looked through your version-check there are some problems.

/usr/bin/awk -> /usr/bin/mawk you need to install gawk

yacc not found

Also what is the output of
Code:
makeinfo --version
Sorry I missed these,
and on another note it wold be best to start again when fixed


Spiky0011, The output of the above code is referring me to install textinfo package, but while entering the
Code:
sudo apt-get install textinfo
It says
Code:
E: Unable to locate package textinfo


And now my /usr/bin/awk is pointing to /usr/bin/bison.yacc
is it okay..
 
Old 12-16-2012, 02:33 AM   #13
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: Ubuntu 12.04/12.10/13.04/LFS/Centos6.3/Debain/PCBSD/Mageia 3
Posts: 1,614
Blog Entries: 1

Rep: Reputation: 226Reputation: 226Reputation: 226
Hi

Try
Code:
sudo apt-get install texinfo
No awk dosn't point to yacc not sure what you have done there


/usr/bin/awk -> /usr/bin/mawk should be /usr/bin/awk -> /usr/bin/gawk
 
Old 12-16-2012, 12:18 PM   #14
Prabhu.Are
LQ Newbie
 
Registered: Oct 2012
Posts: 24

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by spiky0011 View Post
Hi

Try
Code:
sudo apt-get install texinfo
No awk dosn't point to yacc not sure what you have done there


/usr/bin/awk -> /usr/bin/mawk should be /usr/bin/awk -> /usr/bin/gawk


sorry, I made a typo in my last comment.

/usr/bin/awk is pointing to /usr/bin/gawk

but

/usr/bin/yacc is pointing to /usr/bin/bison.yacc

Shall I proceed with the same...
 
Old 12-16-2012, 12:24 PM   #15
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371Reputation: 2371
Just to make sure: Post the full output of the version-check.sh script.
 
  


Reply

Tags
gcc, gcc pass2, glibc, lfs, linux


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
Glibc 2.7 Build Error "ld: cannot find -lgcc" binzyw Linux From Scratch 8 06-25-2012 02:51 AM
Urgent help on "Glibc make error with clfs" rushadrenaline Linux From Scratch 11 03-01-2010 12:14 PM
glibc 2.9 "make check" fails on rt/tst-cputimer with "timer sig[12] invoked to soon" shachter Linux - Software 2 02-14-2009 01:24 PM
/tools/bin/ld: cannot find -lstdc++ -- Error in " make check " of Glibc lfs_rocks Linux From Scratch 1 02-15-2008 09:23 AM
glibc " make check " error in CHAPTER 6 lfs_rocks Linux From Scratch 5 02-12-2008 04:32 PM


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