LinuxQuestions.org
Help answer threads with 0 replies.
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 09-17-2010, 01:36 AM   #1
basheer
Member
 
Registered: Mar 2009
Location: Bangalore, India
Distribution: CentOS6.5, CentOS7, Ubuntu14.04
Posts: 182

Rep: Reputation: 29
Unhappy binutils - error during make


Hi All,
I was trying to build LFS a few months back, I had to leave it because of not having enough time. Now I have started on it again.

I have an acer aspire amd 64x2 turion laptop. I did not get any problems till the 4th chapter. But now in the 5th chapter till confiure of binutils it's ok,but during make it is giving an error. I have pasted the error below....

mv -f .deps/emul_vanilla.Tpo .deps/emul_vanilla.Po
/bin/sh ./libtool --tag=CC --mode=link gcc -W -Wall -Wstrict-prototypes -Wmissing-prototypes -g -O2 -o ar arparse.o arlex.o ar.o not-ranlib.o arsup.o rename.o binemul.o emul_vanilla.o bucomm.o version.o filemode.o ../bfd/libbfd.la ../libiberty/libiberty.a -lfl -lz
libtool: link: gcc -W -Wall -Wstrict-prototypes -Wmissing-prototypes -g -O2 -o ar arparse.o arlex.o ar.o not-ranlib.o arsup.o rename.o binemul.o emul_vanilla.o bucomm.o version.o filemode.o ../bfd/.libs/libbfd.a ../libiberty/libiberty.a -lfl -lz
collect2: ld returned 1 exit status
make[4]: *** [ar] Error 1
make[4]: Leaving directory `/home/lfs/binutils-build/binutils'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/home/lfs/binutils-build/binutils'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/home/lfs/binutils-build/binutils'
make[1]: *** [all-binutils] Error 2
make[1]: Leaving directory `/home/lfs/binutils-build'
make: *** [all] Error 2
lfs:~/binutils-build$

I'm using the LFS livecd as the host.
Can some one please tell me what is wrong.

Thanks in advance.
 
Old 09-17-2010, 01:48 AM   #2
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392
Hi,

Are you building from the home directory of the LFS user (lfs:~/binutils-build$) ? That doesn't look right. The lfs user you created in chapter 4 is part of your host and not part of the temporary system you are building in chapter 5.

You should have a $LFS/sources directory (probably /mnt/lfs/sources). After you become the lfs user (last command of chapter 4.3) and created the environment for that user (chapter 4.4), you need to go to $LFS/sources and do the building from there.

The book also assumes that you have already untarred the file and entered the created directory. In case of bintuils that would look something like this:
Code:
cd $LFS/sources
tar jxf binutils-2.20.tar.bz2
cd binutils-2.20
From this point on you can follow what the book tells you to do, which would be the following when using binutils as an example:
Code:
mkdir -v ../binutils-build
cd ../binutils-build
Hope this helps.
 
1 members found this post helpful.
Old 09-17-2010, 02:13 AM   #3
basheer
Member
 
Registered: Mar 2009
Location: Bangalore, India
Distribution: CentOS6.5, CentOS7, Ubuntu14.04
Posts: 182

Original Poster
Rep: Reputation: 29
Thanx druuna, Now I'm getting a different error, is it because i'm installing i386 on i686. How do I rectify the problem?

I have pasted the last few lines.

mv -f .deps/eelf_i386.Tpo .deps/eelf_i386.Po
LIB_PATH='' /bin/sh ../../binutils-2.20/ld/genscripts.sh "../../binutils-2.20/ld" "/tools/lib" "/tools" "/tools" i686-pc-linux-gnu i686-lfs-linux-gnu i686-lfs-linux-gnu "elf_i386" "/usr/local/lib /lib /usr/lib" no i386linux "i686-lfs-linux-gnuaout"
gcc -DHAVE_CONFIG_H -I. -I../../binutils-2.20/ld -I. -I../../binutils-2.20/ld -I../bfd -I../../binutils-2.20/ld/../bfd -I../../binutils-2.20/ld/../include -g -O2 -DLOCALEDIR="\"/tools/share/locale\"" -W -Wall -Wstrict-prototypes -Wmissing-prototypes -g -O2 -MT ei386linux.o -MD -MP -MF .deps/ei386linux.Tpo -c -o ei386linux.o ei386linux.c
mv -f .deps/ei386linux.Tpo .deps/ei386linux.Po
/bin/sh ./libtool --tag=CC --mode=link gcc -W -Wall -Wstrict-prototypes -Wmissing-prototypes -g -O2 -o ld-new ldgram.o ldlex.o lexsup.o ldlang.o mri.o ldctor.o ldmain.o ldwrite.o ldexp.o ldemul.o ldver.o ldmisc.o ldfile.o ldcref.o eelf_i386.o ei386linux.o ../bfd/libbfd.la ../libiberty/libiberty.a -lz
libtool: link: gcc -W -Wall -Wstrict-prototypes -Wmissing-prototypes -g -O2 -o ld-new ldgram.o ldlex.o lexsup.o ldlang.o mri.o ldctor.o ldmain.o ldwrite.o ldexp.o ldemul.o ldver.o ldmisc.o ldfile.o ldcref.o eelf_i386.o ei386linux.o ../bfd/.libs/libbfd.a ../libiberty/libiberty.a -lz
make[4]: Leaving directory `/mnt/lfs/sources/binutils-build/ld'
make[3]: Leaving directory `/mnt/lfs/sources/binutils-build/ld'
make[2]: Leaving directory `/mnt/lfs/sources/binutils-build/ld'
make[1]: Nothing to be done for `all-target'.
make[1]: Leaving directory `/mnt/lfs/sources/binutils-build'
lfs:/mnt/lfs/sources/binutils-build$
 
Old 09-17-2010, 08:35 AM   #4
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392
Hi,

I don't see any errors in the above posted output, why do you think one has occurred?

If there was an actual error:
- post the error and the lines before it.
- Which LFS version are you building? Is it 6.6 Stable?
- What does the uname -m command show (see chapter 4.4, it is part of the .bashrc file for the lfs user), also what does echo $LFS_TGT show?
- Chapter 5.2 has an "important" box: What does the ./config.guess command show that is mentioned?

BTW: Building LFS, which is 32 bit, on a 64 bit machine works (one of my boxes is 64 bit, running LFS 6.6).

Hope this helps.
 
1 members found this post helpful.
Old 09-17-2010, 11:49 AM   #5
basheer
Member
 
Registered: Mar 2009
Location: Bangalore, India
Distribution: CentOS6.5, CentOS7, Ubuntu14.04
Posts: 182

Original Poster
Rep: Reputation: 29
Smile

Thankx druuna, it was a silly mistake by me. Thanks a lot again.
 
Old 09-17-2010, 11:58 AM   #6
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392
You're welcome

BTW: Can you put the SOLVED tag on this thread (above the first post -> click Thread Tools -> select the SOLVED option).
 
Old 09-25-2010, 06:25 PM   #7
JediDrunk
LQ Newbie
 
Registered: Aug 2003
Posts: 29

Rep: Reputation: 15
Perhaps you could elaborate on your "silly mistake"? I seem to be making the same mistake.
 
Old 09-26-2010, 02:20 AM   #8
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392Reputation: 2392
@JediDrunk: This issue was already solved (see the [SOLVED] tag in front of the thread title).

The "mistake" was that there was no error, the posted output looks the way it should be.
 
Old 09-26-2010, 11:22 AM   #9
basheer
Member
 
Registered: Mar 2009
Location: Bangalore, India
Distribution: CentOS6.5, CentOS7, Ubuntu14.04
Posts: 182

Original Poster
Rep: Reputation: 29
Quote:
Originally Posted by druuna View Post
@JediDrunk: This issue was already solved (see the [SOLVED] tag in front of the thread title).

The "mistake" was that there was no error, the posted output looks the way it should be.
Yes there is no error in the output.

JediDrunk are you getting any sort of errors?
 
Old 09-26-2010, 11:58 AM   #10
JediDrunk
LQ Newbie
 
Registered: Aug 2003
Posts: 29

Rep: Reputation: 15
I was, but I got it working. My binutils tar was not owned by user lfs; chown fixed the problem.
 
Old 09-26-2010, 11:47 PM   #11
basheer
Member
 
Registered: Mar 2009
Location: Bangalore, India
Distribution: CentOS6.5, CentOS7, Ubuntu14.04
Posts: 182

Original Poster
Rep: Reputation: 29
Glad you got it solved.
 
  


Reply


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
Binutils: make install error 4L3CS Linux From Scratch 9 04-27-2009 08:57 AM
make error for binutils 2.17 uberapa Linux - Software 0 06-08-2007 09:11 AM
error in binutils make gobi_dgm Linux - Software 4 09-21-2006 09:58 AM
binutils make install error priya001 Linux From Scratch 3 05-29-2006 09:41 AM
make error with binutils gravesb Linux From Scratch 2 10-15-2005 02:48 PM

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

All times are GMT -5. The time now is 06:09 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration