LinuxQuestions.org
Help answer threads with 0 replies.
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 05-22-2010, 10:04 AM   #1
ukiuki
Senior Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 1,030

Rep: Reputation: 371Reputation: 371Reputation: 371Reputation: 371
Post LFS 6.6 - chap6.7 - Linux-2.6.32.8 API Headers (problems in this step)


I just got lost here i assumed it should be done as in chap. 5,
so i untar the package into source directory and cd to there:

Code:
root:/sources/linux-2.6.32.8# make mrproper
/bin/sh: find: command not found
/bin/sh: line 5: xargs: command not found
make: *** [clean] Error 127
root:/sources/linux-2.6.32.8#
This is my 1st LFS and i dunno what is wrong , everything else been fine so far. I need some help here.

Thanks in advance
 
Old 05-22-2010, 10:20 AM   #2
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374
Hi,

After finishing chapter 5, did you enter the chrooted env correctly (chap 6.4)? Looks like a PATH problem at first glance.

BTW:
Quote:
I just got lost here i assumed it should be done as in chap. 5
Forget chap 5 and the way things are done there. Focus on 6. Some of the things are done the same as in chapter 5 but chapter 5 and 6 build different environments and should not be compared.

Hope this helps.
 
Old 05-22-2010, 11:01 AM   #3
ukiuki
Senior Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 1,030

Original Poster
Rep: Reputation: 371Reputation: 371Reputation: 371Reputation: 371
I checked all the steps through 6.2 - 6.6, all commands been done correctly,
yes i did enter the chroot environment:

Code:
dbox:~# chroot "$LFS" /tools/bin/env -i \
> HOME=/root TERM="$TERM" PS1='\u:\w\$ ' \
> PATH=/bin:/usr/bin:/sbin:/usr/sbin:/tools/bin \
> /tools/bin/bash --login +h
I have no name!:/#
I'm not sure what is wrong. I copied all the commands done through 6.2-6.6
and attached txt file.

Thanks in advance
Attached Files
File Type: txt chap6.2-6.6.txt (6.6 KB, 4 views)
 
Old 05-22-2010, 11:40 AM   #4
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374
Hi,

All the commands in the attachment and the chroot command look ok.

What does ls -l /bin and echo $PATH show (from inside the chrooted env)?

BTW: If ls also doesn't work: cd /bin && echo *
 
Old 05-22-2010, 12:12 PM   #5
ukiuki
Senior Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 1,030

Original Poster
Rep: Reputation: 371Reputation: 371Reputation: 371Reputation: 371
Here is the output:

Code:
root:/# ls -l /bin
total 0
lrwxrwxrwx 1 root root 15 May 22 09:03 bash -> /tools/bin/bash
lrwxrwxrwx 1 root root 14 May 22 09:03 cat -> /tools/bin/cat
lrwxrwxrwx 1 root root 15 May 22 09:03 echo -> /tools/bin/echo
lrwxrwxrwx 1 root root 14 May 22 09:03 pwd -> /tools/bin/pwd
lrwxrwxrwx 1 root root  4 May 22 09:08 sh -> bash
lrwxrwxrwx 1 root root 15 May 22 09:03 stty -> /tools/bin/stty
root:/# echo $PATH
/bin:/usr/bin:/sbin:/usr/sbin:/tools/bin
root:/# cd /bin && echo *
bash cat echo pwd sh stty
root:/bin#
Thanks in advance
 
Old 05-22-2010, 12:36 PM   #6
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374
Hi again,

That output looks ok.

What about the /tools/bin directory? Are the "missing" executables present (find and xargs two name just 2).
 
Old 05-22-2010, 01:47 PM   #7
ukiuki
Senior Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 1,030

Original Poster
Rep: Reputation: 371Reputation: 371Reputation: 371Reputation: 371
Hi !

Looks like that is the problem, what did i miss ?

Code:
root:/tools/bin# ls f*
factor	false  fgrep  fmt  fold
root:/tools/bin# ls x*
xtrace
root:/tools/bin#

Thanks in advance !
 
Old 05-22-2010, 02:27 PM   #8
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374
Hi,

Both find and xargs are part of the Findutils package. Guess something went wrong during the build/install (or did you unintentionally skip it?).

You are just starting chapter 6 so going back to 5 should still be possible:

- Leave the chrooted env (if you haven't already),
- Switch to the lfs user (su - lfs),
- Check if the LFS variable is still set (echo $LFS),
- Goto the sources directory (cd $LFS/sources),
- Unpack the Findutils package (tar zxf findutils-4.4.2.tar.gz)
- Enter the newly created directory and execute the steps in 5.19. Findutils-4.4.2

After that log out again and start with chap 6 again: If you did not reboot the mounts etc from chap 6.2 should still be in place, so start with chap 6.4.

Hope this helps.
 
Old 05-22-2010, 03:08 PM   #9
ukiuki
Senior Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 1,030

Original Poster
Rep: Reputation: 371Reputation: 371Reputation: 371Reputation: 371
Hi

Ok yes i have skipped that by accident, i look at lfs user bash_history i just saw that,
ill go back and do as you said.

here my history file: diffutils is step 5.18 and gawk 5.20 oops!
Code:
tar -zxf diffutils-2.8.1.tar.gz 
cd diffutils-2.8.1
./configure --prefix=/tools
make
make check
make install
cd ..
rm -Rf diffutils-2.8.1
ls
tar -jxf gawk-3.1.7.tar.bz2 
cd gawk-3.1.7
./configure --prefix=/tools
make
make install
cd ..
rm -Rf gawk-3.1.7
ls
Thanks in advance !
 
Old 05-22-2010, 03:20 PM   #10
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374
That happens......

Glad to see you've figured out what was wrong.
 
Old 05-23-2010, 03:42 AM   #11
ukiuki
Senior Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 1,030

Original Poster
Rep: Reputation: 371Reputation: 371Reputation: 371Reputation: 371
Hi

Well not as easy as i was hopping, im having problem to install findutils
i saw the permission denied line to /tools i gave the owner back to user lfs
but after that i still have the same problem.

Code:
test -z "/tools/bin" || /tools/bin/mkdir -p "/tools/bin"
  /tools/bin/install -c 'find' '/tools/bin/find'
/tools/bin/install: cannot create regular file `/tools/bin/find': Permission denied
make[3]: *** [install-binPROGRAMS] Error 1
make[3]: Leaving directory `/mnt/lfs/sources/findutils-4.4.2/find'
make[2]: *** [install-am] Error 2
make[2]: Leaving directory `/mnt/lfs/sources/findutils-4.4.2/find'
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory `/mnt/lfs/sources/findutils-4.4.2/find'
make: *** [install-recursive] Error 1
lfs@dbox:/mnt/lfs/sources/findutils-4.4.2$
Thanks in advance !
 
Old 05-23-2010, 04:52 AM   #12
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374
Hi,

Going back to chapter 5 once you started chapter 6 isn't always possible, it depends a bit on where you are in chapter 6. I do believe it should be possible for you in this case. Worst case scenario: You need to start all over again. But lets try something else first!


The reason for the problems: One of the last steps in chapter 5 (5.32) is changing the ownership of $LFS/tools (chown -R root:root $LFS/tools), which means that the tools dir and everything inside it is given to root (owner and group) and user lfs doesn't have access anymore.

Possible solution for the problem:

- As root (normal root, not the chrooted env root) change $LFS/tools to user LFS: chown -R lfs $LFS/tools,

- Execute the findutils install steps as user lfs (chapter 5.19.) also see post #8,

- As (normal) root change the $LFS/tools permissions back to root: chown -R root:root $LFS/tools (chapter 5.32).

From tis point on you can start with chapter 6. I'm not sure if you rebooted in the meantime, so start with chapter 6.2. You will get some error messages which you can probably ignore (some of the directories already exist due to your previous visit to chapter 6).

Before you start: Remove the unpacked findutils directory first!

Hope this gets you going agagin.

Last edited by druuna; 05-23-2010 at 04:54 AM.
 
Old 05-23-2010, 05:13 AM   #13
ukiuki
Senior Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 1,030

Original Poster
Rep: Reputation: 371Reputation: 371Reputation: 371Reputation: 371
Hi

I was doing this: chown -v lfs $LFS/tools , that is why it didn't work,
I got the findutils installed , got a backup of /tools, permissions are set back
to normal root and no restarts on system so i can go back to chap6 steps i guess, is it possible to just enter in the chroot invironment (6.4)
since nothing else changed?
Anything else i should be concerned about ?

Thanks in advance !

Last edited by ukiuki; 05-23-2010 at 05:23 AM.
 
Old 05-23-2010, 05:43 AM   #14
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374Reputation: 2374
Hi,

If, as you mention, all is still set (especially the mounts), you can start with 6.4.

I assume you checked to see if you haven't skipped any other packages, which means you can continue. The only thing you need to be concerned about is following the book to the letter.

Have fun!
 
Old 05-23-2010, 06:31 AM   #15
ukiuki
Senior Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 1,030

Original Poster
Rep: Reputation: 371Reputation: 371Reputation: 371Reputation: 371
I did check for the package installation, none else missed.

Thank you very much !!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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.5 : Step 6.7 Installing Linux API headers : make headers_check/install error tsong99 Linux From Scratch 12 12-25-2012 05:26 PM
LFS 6.7 Linux API Headers - make headers_check fails gmontjr Linux - Newbie 4 01-26-2009 02:56 AM
LFS newbie stuck in Linux API headers step 5.5 LFS book 6.3 Vxplus Linux From Scratch 2 11-10-2008 09:13 PM
Another LFS newb is stuck: Linux API headers won't install smoochie Linux From Scratch 19 06-13-2008 12:26 PM
make headers_check errors [LFS V6.3, Sect 6.7 Linux-2.6.22.5 API Headers] michealoc Linux From Scratch 1 10-11-2007 10:03 AM


All times are GMT -5. The time now is 11:17 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration