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 |
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.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
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.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
02-13-2010, 11:43 PM
|
#1
|
|
LQ Newbie
Registered: Feb 2010
Posts: 5
Rep:
|
LFS 6.5 : Step 6.7 Installing Linux API headers : make headers_check/install error
Hey everyone! This is my first LFS.
I built the system up to Chapter 6.7 now where I chrooted and created all the essential files and symlinks. And now I'm got problem starting to install the packages again.
The start of chap 6.7, I entered "make mrproper" and nothing happens, in which I assume its normal, but I when I entered "make headers_check" some error showed up indicating it "Can't locate strict.pm in @INC (@INC contains : .... )" where ... is probably the location of strict.pm. I've done getting in to those location and I found strict.pm. So, what did I do wrong? I think it is about where I extracted the tar to (which is the root) but I'm not positive. Can anyone help?? Thanks in advance. 
|
|
|
|
02-14-2010, 04:21 AM
|
#2
|
|
LQ Veteran
Registered: Sep 2003
Location: the Netherlands
Distribution: lfs, debian, rhel
Posts: 8,868
|
Hi,
Did you unpack the kernel package (/$LFS/sources/linux-2.6.30.2.tar.bz2), enter the created directory ($LFS/sources/linux-2.6.30.2/) and then enter the commands metioned in chapter 6.7?
Hope this helps.
|
|
|
|
02-14-2010, 06:43 AM
|
#3
|
|
LQ Newbie
Registered: Feb 2010
Posts: 5
Original Poster
Rep:
|
Yes, I did.
My error appear to be the same with this guy though:
Quote:
Originally Posted by Stachelsk
Hi, I just chroot-ed into my root account and I was setting things up according to the LFS document. I went to compile the Linux API headers (as before), and figured all would go well, as it did before. However, I got a nasty little error message.
Code:
root:/sources/linux-2.6.27# make headers_check
CHK include/linux/version.h
UPD include/linux/version.h
HOSTCC scripts/basic/fixdep
HOSTCC scripts/basic/docproc
HOSTCC scripts/unifdef
INSTALL include/asm-generic (12 files)
Can't locate strict.pm in @INC (@INC contains: /tools/lib/perl5/5.8./i686-linux
/tools/lib/perl5/5.8.8 /tools/lib/perl5/site_perl/5.8.8/i686-linux
/tools/lib/perl5/site_perl/5.8.8 /tools/lib/perl5/site_perl .)
at scripts/headers_install.pl line 19.
BEGIN failed--compilation aborted at scripts/headers_install.pl line 19.
make[2]: *** [/sources/linux-2.6.27/usr/include/asm-generic/.install] Error 2
make[1]: *** [asm-generic] Error 2
make: *** [headers_install] Error 2
I grabbed this from another user. My platform is actually x86-64, but oh well.
The funny thing is, is that I copied strict.pm from /tools/lib/perl5/5.8.8 to /sources/linux-2.6.27, and tried it again and it worked. I'm going alone fine now, I'm just kindof worried that I had to copy strict.pm to the Linux directory in order to get things to click...
Any input on how to really fix this problem?
|
The difference is my LFS is 6.5 and I'm pretty sure that my platform is x86.
Then you (druuna) said to Stachelsk...
Quote:
Originally Posted by druuna
Hi,
Are you sure you did not forget these steps?
- 5.26.1. Installation of Perl -
mkdir -pv /tools/lib/perl5/5.8.8
cp -Rv lib/* /tools/lib/perl5/5.8.8
BTW: You are building and 'older' LFS (6.2), you do know that 6.4 is available.....
|
...which I'm not really sure whether I forgot to do that or not...
But now since I chroot-ed, how can I go back to the previous environment and try to reinstall perl again?
|
|
|
|
02-14-2010, 07:42 AM
|
#4
|
|
LQ Veteran
Registered: Sep 2003
Location: the Netherlands
Distribution: lfs, debian, rhel
Posts: 8,868
|
Hi,
Going back to the previous environment is not an option, things changed when you started chapter 6 (chapter 5 builds a temp system, 6 builds the actual LFS system).
If you did make the backup (as suggested in 5.32), you can remove everything you did this far and restore the backup. Then (re-)install perl and continue (after making a fresh backup).
If you did not make a backup: You could try installing perl from where you are. Do have a good look at the steps you need to take and make sure they work in your current environment. I assume this needs to be done as user lfs (all of chapter 5 is done this way), but step 5.32 changed the ownership of $LFS/tools, so this might not work. I've never tried this and am not sure if this can be done this way, I would start from scratch if I were you.....
Hope this helps.
|
|
|
|
02-14-2010, 08:04 AM
|
#5
|
|
LQ Newbie
Registered: Feb 2010
Posts: 5
Original Poster
Rep:
|
I tried reinstalling from the current environment and it didn't work, and I forgot to make a backup in chapter 5, too. How stupid.
And about starting from scratch, that's what I've been doing while looking for solution anyway. Well, I guess that works! lolz
Much appreciated for the advise anyway. Thanks a lot. 
|
|
|
|
02-14-2010, 11:14 PM
|
#6
|
|
LQ Newbie
Registered: Feb 2010
Posts: 5
Original Poster
Rep:
|
WTF!?! Even though I started over, the same error still exists!! I'm 100% sure that I've copied the perl files, too.
Can anyone help me pls???
|
|
|
|
02-15-2010, 04:17 AM
|
#7
|
|
LQ Veteran
Registered: Sep 2003
Location: the Netherlands
Distribution: lfs, debian, rhel
Posts: 8,868
|
Hi,
Strange.
- Have you checked if strict.pm is actually present at the location the script expects it to be?
- Are you using the 2.6.30 linux kernel as stated in the book or another one?
- Are you sure your host (you don't mention which) is up to specs?
If you still have the info could you also post the actual error (including a handful of lines before it).
|
|
|
|
02-15-2010, 07:02 AM
|
#8
|
|
LQ Newbie
Registered: Feb 2010
Posts: 5
Original Poster
Rep:
|
Oh yeah, I'm sorry. I forgot to mention that I'm using the LFS LiveCD 6.3 r2160 as the host, since there are no 6.5 LiveCDs. However, I downloaded and used all the packages as specified in LFS book 6.5. Also, I can't copy and paste the errors since I'm doing it in a VM. It's actually my course's project. (If possible, is there anyway to copy and paste in and out of VMWare??)
I've done checking the strict.pm location already, and it's there. I tried copy the strict.pm file into the /linux-2.6.30.2 directory and it installs smoothly by the way. However, I ran into another problem when I install Glibc-2.10.1 (which I don't know whether is it related). I worked up to the part where I do the test suite:
Code:
cp -v ../glibc-2.10.1/iconvdata/gconv-modules iconvdata
make -k check 2>&1 | tee glibc-check-log
grep Error glibc-check-log
Although the book said that some errors are expected, none of mine ( posix/bug-regex{2,14,21}-mem , posix/tst-rxspencer-mem , posix/tst-pcre-mem , posix/tst-boost-mem , posix/tst-vfork3-mem , etc. ) fits with the files stated in the book ( nptl/tst-cancel1 , nptl/tst-clock2 , tst-attr3 ).
After that when I try to install the package with "make install", it just won't work. Is it possible that the strict.pm problem is related or did I just messed up somewhere before the compilation?
|
|
|
|
12-24-2012, 04:12 AM
|
#9
|
|
LQ Newbie
Registered: Nov 2012
Posts: 22
Rep: 
|
Quote:
Originally Posted by druuna
Hi,
Going back to the previous environment is not an option, things changed when you started chapter 6 (chapter 5 builds a temp system, 6 builds the actual LFS system).
If you did make the backup (as suggested in 5.32), you can remove everything you did this far and restore the backup. Then (re-)install perl and continue (after making a fresh backup).
If you did not make a backup: You could try installing perl from where you are. Do have a good look at the steps you need to take and make sure they work in your current environment. I assume this needs to be done as user lfs (all of chapter 5 is done this way), but step 5.32 changed the ownership of $LFS/tools, so this might not work. I've never tried this and am not sure if this can be done this way, I would start from scratch if I were you.....
Hope this helps.
|
Why we can't go back? I mean, he can exit first then, go as normal user, with sudo command lets just say he can change ownership of /tools back to lfs, and then as lfs user reinstall the packages, then again as normal user change the ownership of tools and start working in his root# environment? I am posting this since i reinstalled my tar package in tool chain doing all this, and it worked. But pity is, now i am having another error though tar is fine.
Do share why we can't do that? 
|
|
|
|
12-24-2012, 04:36 AM
|
#10
|
|
LQ Veteran
Registered: Sep 2003
Location: the Netherlands
Distribution: lfs, debian, rhel
Posts: 8,868
|
Quote:
Originally Posted by Lakhan Kumar
Why we can't go back? I mean, he can exit first then, go as normal user, with sudo command lets just say he can change ownership of /tools back to lfs, and then as lfs user reinstall the packages, then again as normal user change the ownership of tools and start working in his root# environment? I am posting this since i reinstalled my tar package in tool chain doing all this, and it worked. But pity is, now i am having another error though tar is fine.
Do share why we can't do that? 
|
Once the toolchain is adjusted (chap. 6.10 in LFS 7.2) you cannot go back, you can go back up to and including chapter 6.9.
The ownership isn't the real problem, changes in the toolchain are. Have a look here: 5.34. Changing Ownership (the Caution box) and here 6.10. Adjusting the Toolchain
I do realize that you could theoretically change all this back by hand, but that is prone to making errors. Just make a backup at the end of chapter 5, if something goes wrong in chapter 6: restore the backup and restart from the beginning of chapter 6.
BTW: Using sudo is _not_ a good idea when building LFS.
|
|
|
|
12-24-2012, 08:48 PM
|
#11
|
|
LQ Newbie
Registered: Nov 2012
Posts: 22
Rep: 
|
Quote:
Originally Posted by druuna
Once the toolchain is adjusted (chap. 6.10 in LFS 7.2) you cannot go back, you can go back up to and including chapter 6.9.
The ownership isn't the real problem, changes in the toolchain are. Have a look here: 5.34. Changing Ownership (the Caution box) and here 6.10. Adjusting the Toolchain
I do realize that you could theoretically change all this back by hand, but that is prone to making errors. Just make a backup at the end of chapter 5, if something goes wrong in chapter 6: restore the backup and restart from the beginning of chapter 6.
BTW: Using sudo is _not_ a good idea when building LFS.
|
Thank you for the insight druuna. Btw without using sudo, is there any other way? i can't even change permissions without this command. I am using ubuntu. I know its dangerous for a beginner like me, i have ruined up my whole system once  ... any alternative?
|
|
|
|
12-25-2012, 02:40 AM
|
#12
|
|
LQ Veteran
Registered: Sep 2003
Location: the Netherlands
Distribution: lfs, debian, rhel
Posts: 8,868
|
Quote:
Originally Posted by Lakhan Kumar
Btw without using sudo, is there any other way? i can't even change permissions without this command. I am using ubuntu. I know its dangerous for a beginner like me, i have ruined up my whole system once  ... any alternative?
|
You should enable full root access for Ubuntu:
Code:
# as a normal user, druuna in the below example
druuna@ubuntu-vm:~$ sudo passwd root
[sudo] password for druuna:
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully
# Now you can become root user:
druuna@ubuntu-vm:~$ su -
Password:
root@ubuntu-vm:~#
The sudo command will still work if you need to use it.
|
|
|
|
12-25-2012, 04:26 PM
|
#13
|
|
LQ Newbie
Registered: Nov 2012
Posts: 22
Rep: 
|
Quote:
Originally Posted by druuna
You should enable full root access for Ubuntu:
Code:
# as a normal user, druuna in the below example
druuna@ubuntu-vm:~$ sudo passwd root
[sudo] password for druuna:
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully
# Now you can become root user:
druuna@ubuntu-vm:~$ su -
Password:
root@ubuntu-vm:~#
The sudo command will still work if you need to use it.
|
Okay thankyou Drunna  .
|
|
|
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 10:59 PM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|