LinuxQuestions.org
Help answer threads with 0 replies.
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 02-04-2012, 10:48 PM   #1
DrinkinHomeBrew
LQ Newbie
 
Registered: Oct 2011
Posts: 26

Rep: Reputation: Disabled
LFS chapter-by-chapter complete commands with notes


I did a successful build earlier last month, and this weekend I did another one. Something I really would have liked was a complete set of all commands that I could just cut-and-paste, so here it is.

In addition to having all of the commands (e.g. extracting source files) in a simple location to cut-and-paste from, I've added additional notes that I found useful along the way. I also made a few changes I found potentially useful like tee-ing output of many build commands so to review later for tracing errors.

I'm also including the .config files for both the vmware and virtualbox kernel configuration.

http://dl.dropbox.com/u/17108167/LFSv7.0_Commands.txt
http://dl.dropbox.com/u/17108167/vir...xkernel.config
http://dl.dropbox.com/u/17108167/vmw...xkernel.config
 
Click here to see the post LQ members have rated as the most helpful post in this thread.
Old 02-05-2012, 03:37 AM   #2
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi DrinkinHomeBrew,

Very nice of you to create and post this, some might find this handy.

A few remarks:
Quote:
Don't use 64-bit for the initial host, since it causes issues in the build
This isn't true for the recent LFS versions. I've been building LFS on 64 bit (multilib) systems without any problems.

I also notice you use the su command and not the su - command. The latter might be preferable because that one set a full root environment.

Quote:
ln -sf /bin/bash /bin/sh
You need to remove the link to dash before you create the link to bash.

Quote:
# ================================================

### Read Me

### To restart the process from this point (I didn't do this, so I don't know the process)
### ?? Remove all directories in $LFS except: lost+found, sources. Copy /tools from /root/lfs-tools ??
### ?? Anything else ??
The safest way to restart with chapter 6 is to create a backup of all that is done up to and including chapter 5.
As root user:
Code:
cd $LFS/..
tar jcf lfs.7.tmpenv.tar.bz2 lfs
If, for whatever reason you need to re-start with chapter 6 (as root user):
Code:
cd $LFS/..
rm -rf lfs
tar jxf lfs.7.tmpenv.tar.bz2
About using make's -jX option: The only time I had problems using it was when testing (make check/test) some packages.

Again: Nice job!

PS: I did not check each and every command, so other small issues might still be present.
 
2 members found this post helpful.
Old 02-06-2012, 09:20 AM   #3
DrinkinHomeBrew
LQ Newbie
 
Registered: Oct 2011
Posts: 26

Original Poster
Rep: Reputation: Disabled
Thanks for the feedback.

I took out the 64-bit statement because, in hindsight, that was from the first time I tried on a pre-7.0 version that I never completed. So I'll take your word for it that this is no longer an issue.

I'll try your other suggestions and update it. I really like the idea of making a tar archive of sources and tools instead of copying them as I've been doing. Probably a more efficient way to back those files up. Also, unlinked from dash before linking to bash wasn't necessary since the force switch does it automatically. At least in Mint it worked.

I'm going to build it a few more times, so I'll update it as I go along.
 
Old 02-14-2012, 04:40 AM   #4
kedar kapil
LQ Newbie
 
Registered: Feb 2012
Posts: 3

Rep: Reputation: Disabled
hey drinkinhomebrew.....my friend has been stuck with an error in the chroot environment during the installation of linux api headers and the error is as follows:

/bin/sh: perl: command not found
make[2]: *** [/sources/linux-3.1/usr/include/asm-generic/.install] Error 127
make[1]: *** [asm-generic] Error 2
make: *** [headers_install] Error 2


can you suggest me where the error is...by the way he has got some error while entering the chroot envi and so he reinstalled the complete toolchain carefully...despite doing that he still got the above error......so can you suggest me an answer....
 
Old 02-14-2012, 04:42 AM   #5
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Quote:
Originally Posted by kedar kapil View Post
hey drinkinhomebrew.....my friend has been stuck with an error in the chroot environment during the installation of linux api headers and the error is as follows:

/bin/sh: perl: command not found
make[2]: *** [/sources/linux-3.1/usr/include/asm-generic/.install] Error 127
make[1]: *** [asm-generic] Error 2
make: *** [headers_install] Error 2


can you suggest me where the error is...by the way he has got some error while entering the chroot envi and so he reinstalled the complete toolchain carefully...despite doing that he still got the above error......so can you suggest me an answer....
Cross-posting is against the LQ rules. Please post your thread in only one forum. Posting a single thread in the most relevant forum will make it easier for members to help you and will keep the discussion in one place.

Continue in the other/original thread: kedar kapil post #10.

Also: Please create your own threads, don't litter other threads with your issue's!

Last edited by druuna; 02-14-2012 at 04:43 AM.
 
Old 03-15-2012, 11:41 PM   #6
AdherentX
LQ Newbie
 
Registered: Mar 2012
Posts: 1

Rep: Reputation: Disabled
Smile hey! Would you mind upload the three file again?

hey!
I've run into some troubles when I make LFS.
The link you posted is invalid now. Would you mind upload the three file again?
 
Old 03-16-2012, 01:57 AM   #7
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi,
Quote:
Originally Posted by AdherentX View Post
I've run into some troubles when I make LFS.
The link you posted is invalid now. Would you mind upload the three file again?
I just checked all three links and they work nicely.
 
  


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
LFS 6.3, messed up somewhere prior to chapter 6.12 (gcc), how to restart chapter 6? Funkster Linux From Scratch 2 12-24-2008 06:30 AM
lfs chapter 6.12 deucedlt Linux From Scratch 1 08-13-2006 10:03 AM
LFS Book Chapter 6 - 1st step (chroot to /mnt/lfs) doens't work bauld Linux From Scratch 11 03-15-2006 12:31 AM
chapter 6.3 of LFS 6.1 Stamp Linux From Scratch 2 07-22-2005 07:10 AM
LFS 5.0 Chapter 5 cuco76 Linux From Scratch 1 11-23-2003 10:28 PM

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

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