Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
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.


  Search this Thread
Old 01-04-2004, 11:47 AM   #1
LQ Newbie
Registered: Jan 2003
Distribution: Slackware
Posts: 22

Rep: Reputation: 15
linux 2.6.0 kernel hedders

Hi, I am going to install lfs system again after remove by mistake and now I'm going to use 2.6 kernel from beginning and I was wondering if it would be better to use 2.6.0 kernel headers? Is there any functions that is missing in glibc when I use 2.4 kernel header?
Another thing, when I installed lfs I followed the book completely and now I was planing to use gcc 3.3.2 and I was wondering if that was going to be a trouble, and is there any speed improvement in gcc 3.3.2 in compiling or in the system after compiling when using gcc 3.3.2?
Old 01-04-2004, 12:04 PM   #2
Senior Member
Registered: Dec 2002
Location: Mosquitoville
Distribution: RH 6.2, Gen2, Knoppix,arch, bodhi, studio, suse, mint
Posts: 3,304

Rep: Reputation: 65
the newer gcc's have better optimizations for p4's. if you really want it
the best for a p4, you should use icc<intel's c compiler> for a bunch of
stuff<not the kernel>. for other cpu's, there is rarely a difference.

i've got 2.95.3, and 3.3.2 on my current system, and often compile stuff
with each, to see if 3.3.2 is faster. 3.3.2 is often slower than 2.95.3.
I've got an athlon xp though, and it's about as fast at p5 and p6 code as
it is at code optimized for itself. at least with gcc anyway.
Old 01-04-2004, 12:06 PM   #3
Registered: Dec 2003
Distribution: Openwall, ~LFS
Posts: 128

Rep: Reputation: 15
the cvs lfs book uses gcc 3.3.2. if you never intend to use a 2.4 kernel on this system, then you should use the 2.6 headers. be sure to check the hints site as someone is keeping track of problems when migrating to the 2.6 kernel, also check out the nptl hint as i seem to remember that correcting issues with building against 2.6 headers.
Old 01-16-2004, 12:56 AM   #4
Registered: Nov 2002
Location: Melbourne, Australia
Distribution: (C)LFS (x86_64, ix86, sparcv9, ppc)
Posts: 122

Rep: Reputation: 16
If you're gonna use 2.6 -

1) Compile glibc against the 2.6 kernel headers regardless (use the --with-headers switch)

2) Unless you know what you are doing and don't mind fixing source as you go DON'T copy the raw 2.6 kernel headers ( include/{asm,linux} ) into your /usr/include (or /tools/usr/include), use RH's Fedora kernel headers.

Hints tips and advice can be sought from the lfs-hackers mailing list.
Old 01-16-2004, 03:54 AM   #5
Registered: Jun 2003
Location: Reading, UK
Distribution: Debian 3.0, LFS
Posts: 524

Rep: Reputation: 37
Straight from the LFS FAQ:
Currently, you can't build an LFS system by using linux-2.6.x instead of linux-2.4.x. This is because the kernel headers from 2.6.x are incompatible with other programs in LFS-5.x and will lead to compile errors. It is recommended to use linux-2.4.x in your build until LFS releases a new version which includes the 2.6.x kernel; according to the roadmap this will be LFS-6.0.

Of course, you are free to install the 2.6.x kernel after you've finished building the LFS system. For this, the kernel-2_6-migration hint will be an excellent guide.

If you really want to use linux-2.6.x while building LFS, please read the archives of lfs-hackers (and possibly subscribe to it) and read the excellent NPTL hint.
Old 01-17-2004, 05:08 AM   #6
Registered: Nov 2002
Location: Melbourne, Australia
Distribution: (C)LFS (x86_64, ix86, sparcv9, ppc)
Posts: 122

Rep: Reputation: 16
Wise advice in that there FAQ :-)

Don't stuff with 2.6 base builds unless you know what you are doing :-)

I may be putting some scripts up sometime in the next week or so
( will be under http://www.linuxfromscratch/~ryan ) for the adventurous
( will be plfs v 2.3.1b8 ), kernel 2.6.1, glibc 2.3.3 w NPTL.

Most everything works beautifully :-)

Not for the faint of heart yet though :-)

If you want to help out with development come join us on lfs-hackers.



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
smp kernel: uncompressing Linux ..ok booting the kernel krissb Linux - General 1 11-16-2005 06:31 PM
Debian patched kernel vs official Linux Kernel gerald45 Debian 7 10-12-2005 04:45 AM
Linux kernel debugging and Linux kernel module programming Igor007 Programming 2 08-13-2005 05:12 AM
Linux kernel debugging and Linux kernel module programming Igor007 Linux - Enterprise 3 08-12-2005 02:47 PM
Linux Kernel Problem -- Kernel panic: CPU context corrupt crcooney Linux - Distributions 0 01-15-2004 08:48 AM > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 09:25 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration