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.
I'm having some trouble building a Linux from Scratch system using their own Live CD as a base OS.
I am using the Live CD version x84-6.2-2.
I have followed the book up to the beginning of Chapter 5 before getting stuck.
I have copied all the packages to my hard drive form the live CD using: cp -R /lfs-sources $LFS/sources
When trying to complie Binutils my problems arose. When entering: mkdir -v ../bintuils-build
I received a message sdaying that I can't do that because permission is denied. I then manually created $LFS/sources/binutils-build
When I entered ../lfs-sources/binutils-2.16.1/configure --prefix=/tools --disable-nls the promt returned that there was 'No such file or directory'
I am probably doing something really stupid but any help would be greatly appreciated.
All the chapters concerning installation assume that you have already unzipped/packed the archive and cd-ed to that directory. I.e:
cd $LFS/sources - this is where all the archives can be found. tar jxf <some.package>.tar.bz2 - unzip/unpack package. cd <some.package> - cd to package directory
Again: The book assumes that you have done the above already.
For most of the chapters all is done from here, but for some (binutils being one of those) it is needed to create a building dir (the source directory they talk about is the directory you are in at the moment). You do that as follows:
mkdir ../<some.package>-build - create build directory for package. cd ../<some.package>-build - goto build directory.
there is a massive list of all the packages and patches.
Does: less then pressing tab then y followed by enter, display all the files in the current workign directory?
ls does that. less and more (see man less/more) shows output, one screenfull at the time.
I don't know what you're trying to do with the tab and y.....
haha, what I meant was.... with ls, if there is more than a screenfull of files, then you can only see the last screenfull. Is there anyway I can slowly scroll through the contents of a folder allowing me to view each file name?
You need to use the appropriate options for the tar command.
This (tcl8.4.13-src.tar.gz) is a gzipped tar archive and needs the z option as in tar zxf tcl8.4.13-src.tar.gz.
*.tar.bz2 is a bzip2-ed tar archive and needs the j option as in tar jxf binutils-2.16.1.tar.bz2.
I solved this even easier. Maybe may tar is a special one, but I just do
Code:
tar -xvf
and it unpacks any .gz or .bz2 file without any complaints.
That's interesting. I've been using -xjf for .bz2 and -xzf for .gz (which are the correct options if you look in the man page for tar). But I guess tar can also automatically select the right option for the archive.
I solved this even easier. Maybe may tar is a special one, but I just do tar -xvf
and it unpacks any .gz or .bz2 file without any complaints.
Where did you get that tar version? Because what you are saying is very hard to believe and definitely untrue for the tar version i've worked with. You need the extra option if it is not a plain tar file. Without the j or z option the bz2/gz file will not be unpacked and extracted.
Not using the correct options causes errors (or strange behaviour at the least):
$ tar -xvf xawtv-3.95.tar.gz
tar: This does not look like a tar archive
tar: Skipping to next header
tar: Archive contains obsolescent base-64 headers
tar: Read 2771 bytes from xawtv-3.95.tar.gz
tar: Error exit delayed from previous errors
I have now got up to chapter 6 with no hiccups, until now.
I am trying to configure glibc using ../glibc-2.3.6 --prefix=/usr \
--disable-profile --enable-add-ons \
--enable-kernel=2.6.0 --libexecdir=/usr/lib/glibc
This returns however:
...........
checking for gcc... gcc
checking for suffix of object files... configure: error: cannot compute suffix of object files: cannot compile
See 'config.log' for more details.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.