Linux From ScratchThis 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
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: Debian Sid, SourceMage 0.9.5, & To be Continued on a TP
Posts: 800
Rep:
Command Syntax
I think I'm reading to try LFS, which I tried once before but gave up. Anyhow, when I did try, it was times that I followed the book instructions and some commands didn't work.
An example:
cd $LFS &&
mkdir -p bin boot dev/pts etc/opt home lib mnt proc root sbin tmp var opt &&
for dirname in $LFS/usr $LFS/usr/local
do
mkdir $dirname
cd $dirname
mkdir bin etc include lib sbin share src
ln -s share/man
ln -s share/doc
ln -s share/info
cd $dirname/share
mkdir dict doc info locale man nls misc terminfo zoneinfo
cd $dirname/share/man
mkdir man{1,2,3,4,5,6,7,8}
done &&
cd $LFS/var &&
mkdir -p lock log mail run spool tmp opt cache lib/misc local &&
cd $LFS/opt &&
mkdir bin doc include info lib man &&
cd $LFS/usr &&
ln -s ../var/tmp
I think the above commands was a problem for me. Now how do I type this? I'm sure its not all on one line, but I think some of them should be one line and some not!
maybe posting the problem and/or error messages you received will clarify things a bit...
im taking a guess here:
all of the commands listed are on their own line. type them in exactly as you see them(replacing the values with $īs in front of them (except for &dirname in the for loop) with their real values) and you should be set.
everything preceding the error gets done, so it is nice to know where it went wrong. from that point, you can check the line that wasn't working by running only that line's worth of commands (without the && at the end) you probably just have a typo or something.
if you run out of space on the screen there should be a \ at the end and the next line will be read as part of the origonal line.
if nothing works, copy from book & past into a file. run source file
Type it just like you see it. When there's a newline, put a newline. BASH takes care of the rest. It's knows that something must follow && so if that's at the end of a line, it will prompt you for more. Likewise with the for loop.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.