LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux From Scratch (https://www.linuxquestions.org/questions/linux-from-scratch-13/)
-   -   (LFS2.7) Glibc make error "cant find -lgcc_eh" (https://www.linuxquestions.org/questions/linux-from-scratch-13/lfs2-7-glibc-make-error-cant-find-lgcc_eh-4175441427/)

Prabhu.Are 12-14-2012 05:25 AM

(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.

Lancelot1 12-14-2012 07:09 AM

is this in chapter 5 or 6?

spiky0011 12-14-2012 07:16 AM

Hi

Post output of version-check

druuna 12-14-2012 08:41 AM

Quote:

Originally Posted by Prabhu.Are (Post 4849179)
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/'`

Prabhu.Are 12-14-2012 02:34 PM

Quote:

Originally Posted by Lancelot1 (Post 4849229)
is this in chapter 5 or 6?

This is chapter 5.7.2 in LFS 7.2

Prabhu.Are 12-14-2012 02:35 PM

Quote:

Originally Posted by spiky0011 (Post 4849232)
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

spiky0011 12-14-2012 02:45 PM

Hi

Did you try what druuna has put and also mentioned in the mailing list

Prabhu.Are 12-14-2012 03:16 PM

Quote:

Originally Posted by druuna (Post 4849271)
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.

Prabhu.Are 12-14-2012 03:19 PM

Quote:

Originally Posted by Prabhu.Are (Post 4849471)
MY version-check is

spiky0011, In my version-check textinfo is missing...

could you specify me which package I need to install.

spiky0011 12-14-2012 03:21 PM

No that is installed dont worry. It gives a different output if not installed

spiky0011 12-14-2012 03:29 PM

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

Prabhu.Are 12-15-2012 08:49 PM

Quote:

Originally Posted by spiky0011 (Post 4849502)
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..

spiky0011 12-16-2012 02:33 AM

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

Prabhu.Are 12-16-2012 12:18 PM

Quote:

Originally Posted by spiky0011 (Post 4850233)
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...

druuna 12-16-2012 12:24 PM

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

Prabhu.Are 12-16-2012 01:19 PM

Quote:

Originally Posted by spiky0011 (Post 4850233)
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...

druuna 12-16-2012 01:37 PM

Post #16: You already posted that in post #14.

My reply: post #15

In other words: If you want us to check, post the full script output.

Prabhu.Are 12-18-2012 07:20 AM

Quote:

Originally Posted by druuna (Post 4850483)
Just to make sure: Post the full output of the version-check.sh script.

druuna 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
/usr/bin/yacc -> /usr/bin/bison.yacc
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/gawk
gcc (Ubuntu/Linaro 4.4.4-14ubuntu5.1) 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

spiky0011 12-18-2012 07:29 AM

Hi

You need texinfo
Code:

sudo apt-get install texinfo


All times are GMT -5. The time now is 10:35 PM.