LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 07-17-2005, 11:54 AM   #1
dimaash
LQ Newbie
 
Registered: Jul 2005
Posts: 6

Rep: Reputation: 0
samples of LFS build scripts


Hi everyone!

I am pretty sure that i am not the first one who thought about it, but anyway. Let's say, i am somewhere near the middle of LFS building process and by accident i destroyed newly created toolchain or temporary environment or something in that nature. Since i do not have required expereience to "fix" the problem i think it would be wiser to restart all over again. But as I go further in the building process, there are more and more commands to type. So, wouldn't it be easier to put them in some kinda of bash script and let it run up to the point where i "screwed up" ? If it does make sense, can anyone show me examples of their LFS build scripts? I do not have very good knowledge of bash scripting, but i think if i have some sample to look at, then i can handle it.

Thanks, appriciate in advance.
 
Old 07-17-2005, 12:02 PM   #2
zonk
Newbie
 
Registered: Jul 2005
Posts: 7

Rep: Reputation: 0
in the easiest version, simply type out all the commands you need in a text file, one command per line. make sure to use absolute paths instead of relative paths. copy&paste from the manual to make sure you don't get typos in there. then put

#!/bin/bash

as the first line of the script and change the permissions like this:

chmod +x file_name

to make it executable. then, when you run ./file_name it will execute all the lines in the file one by one. simplest version of scripting. if you look up bash faqs and tutorials you can find out how to test for things and use variables and stuff and make it much more fancy.
 
Old 07-17-2005, 12:09 PM   #3
madluther
Member
 
Registered: Aug 2004
Distribution: LFS
Posts: 350

Rep: Reputation: 31
There is a whole subproject of LFS called ALFS which stands for Automated LFS, it can build the complete system, or selectively build bits and pieces from an ncurses style menu. See http://www.linuxfromscratch.org/alfs/ for more info.
 
Old 07-20-2005, 09:35 PM   #4
Pestossimo
LQ Newbie
 
Registered: Jul 2005
Location: Evanston, IL
Posts: 7

Rep: Reputation: 0
Quote:
Originally posted by madluther
There is a whole subproject of LFS called ALFS which stands for Automated LFS, it can build the complete system, or selectively build bits and pieces from an ncurses style menu. See http://www.linuxfromscratch.org/alfs/ for more info.
Um, sounds a lot like Gentoo.
 
  


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.1 build on which linux distribution aneel Linux From Scratch 2 09-21-2005 08:24 AM
How to build LiveCD from LFS isilinux Linux From Scratch 1 08-24-2005 03:45 AM
Is it safe to build LFS as a root ? dimaash Linux From Scratch 3 07-29-2005 10:59 AM
Can I build LFS using Slackware10.1 sources? kornerr Linux From Scratch 9 07-01-2005 01:09 PM
Build LFS from dos partition? Phonics3k Linux From Scratch 7 07-05-2002 12:48 PM

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

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