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 12-23-2004, 07:55 PM   #1
cheema
Member
 
Registered: Oct 2003
Distribution: Debian Sarge
Posts: 50

Rep: Reputation: 15
ld: cannot find -lc while compiling gcc


I'm trying LFS for the first time on mandrake 10.1 official. While building gcc during pass 1 i get the following error:
/tools/i686-pc-linux-gnu/bin/ld: cannot find -lc

A more complete error message is the following:

stage1/xgcc -Bstage1/ -B/tools/i686-pc-linux-gnu/bin/ -g -O2 -DIN_GCC -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -pedantic -Wno-long-long -Wold-style-definition -DHAVE_CONFIG_H -DGENERATOR_FILE -static -o genmodes \
genmodes.o errors.o ../libiberty/libiberty.a
/tools/i686-pc-linux-gnu/bin/ld: cannot find -lc
collect2: ld returned 1 exit status
make[2]: *** [genmodes] Error 1
make[2]: Leaving directory `/lfs/sources/gcc-build/gcc'
make[1]: *** [stage2_build] Error 2
make[1]: Leaving directory `/lfs/sources/gcc-build/gcc'
make: *** [bootstrap] Error 2

My binutils compiled without any problem. Any ideas?
 
Old 12-24-2004, 05:48 AM   #2
Edgington
LQ Newbie
 
Registered: Dec 2004
Location: Sassenheim
Distribution: FC 3
Posts: 6

Rep: Reputation: 0
Check the LFS FAQ the answer can be found
 
Old 12-24-2004, 04:21 PM   #3
cheema
Member
 
Registered: Oct 2003
Distribution: Debian Sarge
Posts: 50

Original Poster
Rep: Reputation: 15
thnx Edgington. That was exactly what I needed
 
Old 02-28-2005, 02:06 PM   #4
VinceF
LQ Newbie
 
Registered: Feb 2005
Location: Bordeaux
Distribution: OpenBSD minislack
Posts: 5

Rep: Reputation: 0
I have exactly the same problem but I can't find the glibc-static-devel that fit with my glibc-devel version( 2.3.3-20)

Does someone know where I can find it, (or how can I upgrade my glibc-devel (all my attempts have failed )) ?
 
Old 02-28-2005, 03:38 PM   #5
jerutley
LQ Newbie
 
Registered: Feb 2005
Posts: 3

Rep: Reputation: 0
glibc-static-devel is on the third cd of the Mandrake releases. You should also be able to find the RPM on your favorite mandrake mirror.
 
Old 02-28-2005, 03:59 PM   #6
VinceF
LQ Newbie
 
Registered: Feb 2005
Location: Bordeaux
Distribution: OpenBSD minislack
Posts: 5

Rep: Reputation: 0
Quote:
Originally posted by jerutley
glibc-static-devel is on the third cd of the Mandrake releases. You should also be able to find the RPM on your favorite mandrake mirror.
I have read the fac, thanks

It's not on mine(mdk10.1 community)

and mirrors, rpm search ,google search and all the traditionnal things gave no(satisfying) result for glib-static-devel-2.3.3-20. I tryed with other versions but it didn't work (logicaly... my glibc-devel is 2.3.3-20)

Please help me
 
Old 02-28-2005, 04:05 PM   #7
jerutley
LQ Newbie
 
Registered: Feb 2005
Posts: 3

Rep: Reputation: 0
I can't find the one to match that either. As a work around, you can safely build your first 2 packages (binutils pass 1 and gcc pass 1) as dynamic instead of static, and you should be ok.
 
Old 02-28-2005, 04:09 PM   #8
VinceF
LQ Newbie
 
Registered: Feb 2005
Location: Bordeaux
Distribution: OpenBSD minislack
Posts: 5

Rep: Reputation: 0
Ok I'll try that. thank
 
Old 03-10-2005, 04:20 AM   #9
aerendil
LQ Newbie
 
Registered: Mar 2005
Location: Grenoble
Distribution: Mandrake 10.1
Posts: 1

Rep: Reputation: 0
Question

Hi,

I had the same problem as you.
Did the proposed solution work for you ?

Does dynamicaly compiling gcc pass 1 occure problems in later LFS building steps ?

I want to be sure before continuing with Mandrake or not.

Thanks

Aerendil
 
Old 03-20-2005, 07:09 AM   #10
VinceF
LQ Newbie
 
Registered: Feb 2005
Location: Bordeaux
Distribution: OpenBSD minislack
Posts: 5

Rep: Reputation: 0
No, It's the last problem i've had during the rest of the process... You could continue easily after this step
 
  


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
Compiling using gcc Damitha Mandriva 1 12-17-2004 05:11 AM
Kernel compiling: gcc-3.3 is 586, should be gcc-3.3 386 Erik Plaggenmar Linux - Software 0 10-01-2004 11:38 AM
Various Compiling Errors (GCC compiling Openal, GUIlib, xmms-wma) gregorya Linux - Software 2 08-27-2004 05:03 AM
Compiling GCC (pass1):ld cannot find -lc Dargason Linux From Scratch 2 07-15-2004 02:48 AM
Compiling gcc CuteBug Linux - Software 2 02-22-2004 09:19 AM

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

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