LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 02-27-2007, 12:16 PM   #1
shahgols
Member
 
Registered: Dec 2006
Posts: 97

Rep: Reputation: 15
newbie question


Hi all,

So I am in chapter 5.3.1 and I am doing my very first install of LFS. And I am on the very first step and I am confused, which can't be a good thing.

I have two questions:

1. The book says (chapter 5.3.1) "The Binutils doc. recommends building Binutils outside of the source directory in a dedicated build directory". It then instructs me to run "mkdir -v ../binutils-build". From which directory do I run this? Is it from / or is it from $LFS?

2. It then says "Now prepare Binutils for compilation". I guess that the book is assuming that I have unpacked this utility already and it's in the $LFS/sources directory right?

Thanks in advance.
 
Old 02-27-2007, 12:30 PM   #2
weibullguy
ReliaFree Maintainer
 
Registered: Aug 2004
Location: Kalamazoo, Michigan
Distribution: Slackware 14.2
Posts: 2,815
Blog Entries: 1

Rep: Reputation: 261Reputation: 261Reputation: 261
You really should read EVERYTHING, especially if it's your first time.

In a big box in section 5.1 it says,
Quote:
Before issuing the build instructions for a package, the package should be unpacked as user lfs, and a cd into the created directory should be performed. The build instructions assume that the bash shell is in use.
The answer to question 1 --> from $LFS/sources/binutils-2.16.1. The command as written will create (verbosely) $LFS/sources/binutils-build.

In addition to the previous quote, the answer to your second question is in section 3.1,
Quote:
Downloaded packages and patches will need to be stored somewhere that is conveniently available throughout the entire build. A working directory is also required to unpack the sources and build them. $LFS/sources can be used both as the place to store the tarballs and patches and as a working directory.
Good luck...
 
Old 02-27-2007, 12:52 PM   #3
shahgols
Member
 
Registered: Dec 2006
Posts: 97

Original Poster
Rep: Reputation: 15
Thanks Arow, I had read both quotes that you posted, but I had to double check. I am still trying to get used to the way this manual is written and I am a bit of a paranoid guy, so I double check everything. Thanks for your answer, I am off to have some LFS fun.
 
Old 02-27-2007, 01:32 PM   #4
shahgols
Member
 
Registered: Dec 2006
Posts: 97

Original Poster
Rep: Reputation: 15
Can I ask why we are creating the binutils-build directory? If I am running "./configure && make && make install" from $LFS/sources/binutils-2.16.1, then what is the use of the binutils-build directory? Is that directory going to be used later on?

Sorry for my newbie question. Believe me, it's embarrassing to even ask it.
 
Old 02-27-2007, 02:19 PM   #5
Dark_Helmet
Senior Member
 
Registered: Jan 2003
Posts: 2,786

Rep: Reputation: 374Reputation: 374Reputation: 374Reputation: 374
But you aren't running "./configure && make && make install" from the $LFS/sources/binutils-2.16.1 directory.

The build instructions give you two commands (after unpacking the binutils tarball and cd'ing into the binutils source tree):
Code:
mkdir ../binutils-build
cd ../binutils-build
Then later, you issue the configure command as (something like this):
Code:
../binutils-2.16.1/configure <arguments>
You are running the configure script, make, and make install from inside $LFS/sources/binutils-build (because you cd'ed into it earlier). All of this is done because the binutils developers suggest doing it this way. The instructions, followed to a 'T' will take care of you

EDIT:
This may sound mean, but that's not why I'm saying it, I promise! For your first-ever LFS build, don't think--just copy the commands exactly as provided. Don't tweak, don't modify, just plug-and-chug. Change things only when explicitly told to do so, and that usually happens toward the end of the project. You'll have a working system 99.9% of the time if you do that. Then, once you're comfortable with the process and know that it works, you can start customizing/modifying the steps. You'll have a much better idea of what you're doing, and if it breaks, you'll know one of your deviations from the book wasn't correct.

Last edited by Dark_Helmet; 02-27-2007 at 02:27 PM.
 
Old 02-27-2007, 02:22 PM   #6
shahgols
Member
 
Registered: Dec 2006
Posts: 97

Original Poster
Rep: Reputation: 15
Oh, yes, yes. I see now. Thank you!!

I am such a
 
Old 03-01-2007, 05:21 PM   #7
Vitalie Ciubotaru
Member
 
Registered: Dec 2005
Location: Osaka, Japan
Distribution: Ubuntu Trinity
Posts: 153

Rep: Reputation: 30
shahgols wrote:
Quote:
I am such a
No, you're already not if you asked such a question!
Technically speaking, you can run "./configure && make && make install" from $LFS/sources/binutils-2.16.1 and most probably it will work for you, but "The Binutils documentation recommends building Binutils outside of the source directory in a dedicated build directory". That's it!
 
  


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
Apache newbie question.. (very newbie question) tarballed Linux - Newbie 1 02-07-2003 08:41 PM
RE: Suse 8.0 hardware question {newbie question, pls help} Radiouk Linux - Distributions 2 06-04-2002 12:53 PM
RE: Samba question pls help {Newbie question} Radiouk Linux - Networking 4 06-03-2002 06:40 PM
Security question {newbie question} Radio Linux - Security 3 05-17-2002 06:32 PM

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

All times are GMT -5. The time now is 03:01 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
Open Source Consulting | Domain Registration