LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
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 06-11-2008, 11:09 AM   #16
gerald_M2B
Member
 
Registered: Oct 2007
Posts: 34

Rep: Reputation: 15

This should not be the show-stopper.

The header files that are needed are in LINUX/include/linux/* and LINUX/include/asm.
You can recursively copy the headers to where they are destined to go.
I do not know about the value of the many other headers of various directories in the kernel. Look them over, and if in doubt, save them as a tar file.

Then continue on your journey through LFS.

Ideally, the makefile in the kernel should be corrected to work correctly for each arch, so the same problem you encountered would no longer exist.

Gerald
 
Old 06-11-2008, 06:09 PM   #17
emdog4
LQ Newbie
 
Registered: Feb 2008
Posts: 5

Rep: Reputation: 1
Hi! It seems as if you may have solved this problem already (see quote below), but for others, if you are using ubuntu and you have this error you can do
Code:
sudo apt-get install build-essentials
and this should fix the problem. I am a pretty big newb myself, and I'm not really sure what the package build-essentials contains, but I know it has something to do with compiling and the compiler and can fix alot of errors. hope that helps! Hail ubuntu!
Emery

-----------------

Quote:
Originally Posted by smoochie View Post
Really weird, I started over and now I can't even prepare Binutils for compilation:

Code:
smoochie@smoochie-desktop:/mnt/lfs/sources/binutils-build$ sudo CC="gcc -B/usr/bin/" ../binutils-2.17/configure \
>     --prefix=/tools --disable-nls --disable-werror
loading cache ./config.cache
checking host system type... i686-pc-linux-gnulibc1
checking target system type... i686-pc-linux-gnulibc1
checking build system type... i686-pc-linux-gnulibc1
checking for a BSD compatible install... /usr/bin/install -c
checking whether ln works... yes
checking whether ln -s works... yes
checking for gcc... gcc -B/usr/bin/
checking whether the C compiler (gcc -B/usr/bin/  ) works... no
configure: error: installation or configuration problem: C compiler cannot create executables.
Not sure why I keep hitting snags but at this rate I might be more successful writing my own OS from scratch :-/

Last edited by emdog4; 06-11-2008 at 06:11 PM.
 
Old 06-13-2008, 08:57 AM   #18
smoochie
LQ Newbie
 
Registered: May 2008
Posts: 10

Original Poster
Rep: Reputation: 0
Thank you everyone, it looks like I finally figured out the problem. Linux is case-sensitive, and some of the header files are in lower case when they should be in caps. The following commands should solve the problem:

Code:
cd $LFS/sources/linux-2.6.22.5/include/linux/netfilter
cp xt_connmark.h xt_CONNMARK.h
cp xt_dscp.h xt_DSCP.h
cp xt_mark.h xt_MARK.h
cp xt_tcpmss.h xt_TCPMSS.h

cd $LFS/sources/linux-2.6.22.5/include/linux/netfilter_ipv4
cp ipt_connmark.h ipt_CONNMARK.h
cp ipt_dscp.h ipt_DSCP.h
cp ipt_ecn.h ipt_ECN.h
cp ipt_mark.h ipt_MARK.h
cp ipt_tcpmss.h ipt_TCPMSS.h
cp ipt_tos.h ipt_TOS.h
cp ipt_ttl.h ipt_TTL.h

cd $LFS/sources/linux-2.6.22.5/include/linux/netfilter_ipv6
cp ip6t_hl.h ip6t_HL.h
cp ip6t_mark.h ip6t_MARK.h
 
Old 06-13-2008, 10:01 AM   #19
smoochie
LQ Newbie
 
Registered: May 2008
Posts: 10

Original Poster
Rep: Reputation: 0
Hmm, maybe I spoke too soon. Performing the very last command doesn't work because /tools/include doesn't exist:

Code:
cp -rv dest/include/* /tools/include
And when I try to prepare Glibc for compilation in the very next step, it says the installed linux files (in usr/include/linux and usr/include/asm) are too old.
 
Old 06-13-2008, 11:26 AM   #20
gerald_M2B
Member
 
Registered: Oct 2007
Posts: 34

Rep: Reputation: 15
When building LFS, the builder needs to follow the LFS book EXACTLY, and if
an error occurs, or an unexpected result is obtained, stop, and figure out
why. Do not continue on. Post if you cannot figure it out quickly.

When /tools/include directory does not exist, create the directory, then retry the command.

You should have the linux-2.6.22.5(or newer) header files in the directory
/tools/include/{linux,asm}
Then, continuing on into glibc, run the command EXACTLY.
You would not get the message that /usr/include/linux headers are too old because you gave the headers to use as /tools/include

Gerald
 
  


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
Installation of Linux API Headers... crik91 Linux From Scratch 7 01-05-2008 03:11 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 09:03 AM
Installation of Linux API Headers martinwprior Linux From Scratch 3 09-28-2007 01:19 AM
"make headers_check" gives errors during "5.5.1 Installation of Linux API headers " void_man() Linux From Scratch 3 09-26-2007 09:16 PM
LFS on PPC(linux-headers) DarthBane Linux From Scratch 1 06-05-2004 08:24 PM


All times are GMT -5. The time now is 10:13 AM.

Main Menu
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