LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
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 08-17-2004, 02:09 PM   #1
hmonster
LQ Newbie
 
Registered: May 2004
Location: Lake Worth, Fl.
Distribution: FC 1,2&3 Libranet 2.8.1
Posts: 6

Rep: Reputation: 0
Installation of binutils....can't mkdir...../binutils-build


Hey all
trouble at first command of chapter 5
Have followed the book all the way, w/ a prompt of
lfs:~$
pwd= /home/lfs
error= mkdir: cannot create directory '../binutils-build': Permission denied
last completed command was source ~/.bash_profile
way to early to be screwing up!

ps just noticed that /home/lfs is on host system...if that right?

Last edited by hmonster; 08-17-2004 at 02:15 PM.
 
Old 08-18-2004, 03:46 AM   #2
Cerbere
Member
 
Registered: Dec 2002
Location: California
Distribution: Slackware & LFS
Posts: 799

Rep: Reputation: 33
From Chapter 5 Introduction:
Quote:
The build instructions assume that you are using the bash shell. There is also a general expectation that you have already unpacked the sources for a package and have performed a cd into the unpacked source directory before issuing the build commands.
For each of the sections, you must first extract the package and cd into the directory that is created. So you should be in /home/lfs/binutils-### when you issue the 'mkdir ../binutils-build' command.

Quote:
ps just noticed that /home/lfs is on host system...if that right?
That depends on the value of $LFS. If you follow the book, then $LFS=/mnt/lfs, so having /home/lfs on the host system (partition) is no problem. If you're going out on your own and have set $LFS=/home/lfs, then this should be the mount point for your new partition. Read back through Chap.3 'Mounting the New Partition'.

Enjoy!
--- Cerbere

[edit] And Welcome to LQ.org! [/edit]

Last edited by Cerbere; 08-18-2004 at 03:47 AM.
 
Old 08-18-2004, 03:30 PM   #3
hmonster
LQ Newbie
 
Registered: May 2004
Location: Lake Worth, Fl.
Distribution: FC 1,2&3 Libranet 2.8.1
Posts: 6

Original Poster
Rep: Reputation: 0
Thanks for a little clarity,

>>For each of the sections, you must first extract the package and cd into the directory that is created. So you should be in /home/lfs/binutils-### when you >issue the 'mkdir ../binutils-build' command.

Since I got an error about permissions in /home/lfs on my host, and I figured I was in the wrong place anyway, I went to /mnt/lfs/sources (where i had DL'd the sources, I made directories off there. (still am not sure if I should of untar'd from /mnt/lfs/sources, as your responce suggests, or untar into the directories the book said to make, ie ../binutils-build, ../gcc-build, and so on.) which is what I did.

>>That depends on the value of $LFS. If you follow the book, then $LFS=/mnt/lfs, so having /home/lfs on the host system (partition) is no problem. If you're going >out on your own and have set $LFS=/home/lfs, then this should be the mount point for your new partition. Read back through Chap.3 'Mounting the New >Partition'.

I may have done an 'export $LFS=/mnt/lfs', which I see now should of been 'export LFS=/mnt/lfs', wherein may lie the problem.

At Part II: Preparing the build, it read," you are expected to have already unpacked it (explained shortly) as user lfs." I still of yet haven't seen the 'explained shortly' part, so having some familarity with GNU/OS, tried to read the authors mind, I was reading from 5.1.1, but went back to 5.0 which clarified things a little,
and am going back further.

thanks for your time
 
Old 08-19-2004, 03:42 AM   #4
Cerbere
Member
 
Registered: Dec 2002
Location: California
Distribution: Slackware & LFS
Posts: 799

Rep: Reputation: 33
You're a little closer, but just shy of the mark. You do want to extract the packages within /mnt/lfs/sources and then cd to the directory that this extraction will create, namely: /mnt/lfs/sources/binutils-2.14.

That is where you execute the command 'mkdir ../binutils-build' which will create /mnt/lfs/sources/binutils-build.

Then the next command is 'cd ../binutils-build', so you should then be in /mnt/lfs/sources/binutils-build which is where you run the configure, make, and make install, etc.

Notice that the actual configure command is:
../binutils-2.14/configure --prefix=/tools --disable-nls

Since you are executing this from within /mnt/lfs/sources/binutils-build, this is the same as:
/mnt/lfs/sources/binutils-2.14/configure --prefix=/tools --disable-nls

The /mnt/lfs/sources/binutils-build directory is where the actual build will take place, but it will be building from the source which you extracted to /mnt/lfs/sources/binutils-2.14.

I hope this makes things clearer. Sometimes when I finish an explanation, even I'm more confused than when I began :-)

Enjoy!
--- Cerbere
 
Old 08-19-2004, 11:05 AM   #5
hmonster
LQ Newbie
 
Registered: May 2004
Location: Lake Worth, Fl.
Distribution: FC 1,2&3 Libranet 2.8.1
Posts: 6

Original Poster
Rep: Reputation: 0
Thanks,
Sometimes I really doubt my reading comprehension skills, your explaination makes it more than clear.

>> You do want to extract the packages within /mnt/lfs/sources and then cd to the directory that this extraction will create, namely: /mnt/lfs/sources/binutils-2.14.
>>That is where you execute the command 'mkdir ../binutils-build' which will create /mnt/lfs/sources/binutils-build.
>>Then the next command is 'cd ../binutils-build', so you should then be in /mnt/lfs/sources/binutils-build which is where you run the configure, make, and make install, etc.
 
Old 08-21-2004, 04:51 PM   #6
kjordan
Member
 
Registered: Jul 2004
Distribution: LFS, I felt the itch and scratched it
Posts: 227

Rep: Reputation: 31
I'm actually not sure they say which directory to be in when you execute that. I guess they assume you know to be in the extracted folder.
 
Old 08-22-2004, 04:07 AM   #7
Cerbere
Member
 
Registered: Dec 2002
Location: California
Distribution: Slackware & LFS
Posts: 799

Rep: Reputation: 33
Like I said before,
Quote:
Originally posted by Cerbere
From Chapter 5 Introduction:
Quote:
The build instructions assume that you are using the bash shell. There is also a general expectation that you have already unpacked the sources for a package and have performed a cd into the unpacked source directory before issuing the build commands.
That's from LFS Book 5.0.

In 5.1.1, Chapter 5 Introduction:
Quote:
Before issuing the build instructions for a package, you are expected to have already unpacked it (explained shortly) as user lfs, and to have performed a cd into the created directory. The build instructions assume that you are using the bash shell.
Don't really know why so many people miss this.

Enjoy!
--- Cerbere
 
  


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
5.3.1 Installation of Binutils microsoft/linux Linux From Scratch 8 10-22-2005 12:41 PM
mkdir ../binutils-build gives me "Permission Denied"!!! matthewa Linux From Scratch 16 06-29-2005 07:00 AM
Problem with binutils first pass / bison & flex installation peristaltic Linux From Scratch 3 03-20-2005 10:17 AM
oops-deleted binutils-build Barnette Linux From Scratch 2 01-14-2005 05:23 PM
mkdir ../binutils-build permission denied TheBman Linux From Scratch 11 02-16-2004 08:39 AM


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