[SOLVED] Help about packages, patches, and binutils
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.
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.
Ok. Partition done, and now I'm at the chapter 5.3.
But when I try to decompress binutils-2.22.tar.bz2 it gives me:
lfs@giacomo-notebook:~$ tar -xvzf $LFS/sources/binutils-2.22.tar.bz2
tar (child): /mnt/lfs/sources/binutils-2.22.tar.bz2: Cannot open: No such file or directory
tar (child): Error is not recoverable: exiting now
tar: Child returned status 2
tar: Error is not recoverable: exiting now
And so I tried to see the directory "sources" with "ls $LFS" comand, and appear it doesn't exist. But if I use "ls $LFS/sources" I can see all the patches and packages..
With root I can see sources' content, and use the cd comand to enter in it. However, with lfs, none of this.
I read that I must be lfs user (and not root) to compile the packages.. is strictly required?
Well, found the mistake. The "sources" directory was in / and not in /mnt/lfs. I don't know why...
So I moved the directory in the right place. But now, when I tar the binutils archive, I read it can't do the various operations 'cause hasn't permission. I do it with lfs (no root, no myname user)
I would try running the chmod command on that directory again. See the introduction to Chapter 3 about creating the /sources directory.
P.S.: I just did a little experiment and discovered a possible explanation for the misplaced /sources directory. What you described happened when I ran the command mkdir $LFS/sources without the LFS variable set. No error occurred, and the directory was created in the / directory.
boo [ ~ ]$ echo $LFS
boo [ ~ ]$ sudo mkdir $LFS/sources2
boo [ ~ ]$ ls /
bin dev home lost+found mnt proc root sbin sources2 sys usr
boot etc lib media opt repo run sources srv tmp var
The book often mentions checking that variable. This is why, I guess. At least until you get to the chroot environment.