LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 04-18-2006, 12:32 PM   #1
alephnull
LQ Newbie
 
Registered: Jan 2005
Location: Washington, DC, on the edge of the stinking pit of decay (Capitol Hill)
Distribution: Slackware 10.2
Posts: 11

Rep: Reputation: 0
Kernel compilation problem


Greetings, all.

I recently installed Slackware 10.2 on my laptop. I got the source for kernel 2.6.16.5 and compiled, compilation works. After rebooting, I realize I got a few things wrong and need to re-compile. When I go to /usr/src/linux and type my normal 'make menuconfig', I get:

HOSTCC scripts/basic/fixdep
In file included from /usr/include/bits/posix1_lim.h:153,
from /usr/include/limits.h:144,
from /usr/lib/gcc-lib/i486-slackware-linux/3.3.6/include/limits.h:122,
from /usr/lib/gcc-lib/i486-slackware-linux/3.3.6/include/syslimits.h:7,
from /usr/lib/gcc-lib/i486-slackware-linux/3.3.6/include/limits.h:11,
from scripts/basic/fixdep.c:113:
/usr/include/bits/local_lim.h:36:26: linux/limits.h: No such file or directory
In file included from /usr/include/sys/socket.h:35,
from /usr/include/netinet/in.h:24,
from /usr/include/arpa/inet.h:23,
from scripts/basic/fixdep.c:115:
/usr/include/bits/socket.h:304:24: asm/socket.h: No such file or directory
scripts/basic/fixdep.c: In function `use_config':
scripts/basic/fixdep.c:214: error: `PATH_MAX' undeclared (first use in this function)
scripts/basic/fixdep.c:214: error: (Each undeclared identifier is reported only once
scripts/basic/fixdep.c:214: error: for each function it appears in.)
scripts/basic/fixdep.c:214: warning: unused variable `s'
scripts/basic/fixdep.c: In function `parse_dep_file':
scripts/basic/fixdep.c:310: error: `PATH_MAX' undeclared (first use in this function)
scripts/basic/fixdep.c:310: warning: unused variable `s'
make[1]: *** [scripts/basic/fixdep] Error 1
make: *** [scripts_basic] Error 2

and that's it.
I've seen posts elsewhere suggesting a (re)installation of libc6-dev; I can find no corresponding slackware package for this library. I've reinstalled cxxlib:
cxxlibs-6.0.3-i486-1 [inst=yes]: cxxlibs (C++ shared library compatibility package)
which I believe contains libc6, but no change.

Any ideas?

cheers,
~ben
 
Old 04-18-2006, 12:44 PM   #2
mdarby
Member
 
Registered: Nov 2004
Location: Columbus, Ohio
Distribution: Slackware-Current / Debian
Posts: 795

Rep: Reputation: 30
Try reinstalling glibc:
http://slackware.it/en/pb/package.ph...c-2.3.6-i486-2
 
Old 04-18-2006, 01:11 PM   #3
alephnull
LQ Newbie
 
Registered: Jan 2005
Location: Washington, DC, on the edge of the stinking pit of decay (Capitol Hill)
Distribution: Slackware 10.2
Posts: 11

Original Poster
Rep: Reputation: 0
Thanks for the quick response, mdarby.
OK, reinstalled glibc (upgraded, actually; my version was 2.3.5), still the same problem -- exactly the same output.
Anything else?

cheers,
~ben
 
Old 04-18-2006, 01:33 PM   #4
Alien_Hominid
Senior Member
 
Registered: Oct 2005
Location: Lithuania
Distribution: Hybrid
Posts: 2,247

Rep: Reputation: 53
I believe you hadn't uninstalled kernel headers after successful kernel compilation, because socket.h is form kernel headers package.
 
Old 04-18-2006, 02:08 PM   #5
alephnull
LQ Newbie
 
Registered: Jan 2005
Location: Washington, DC, on the edge of the stinking pit of decay (Capitol Hill)
Distribution: Slackware 10.2
Posts: 11

Original Poster
Rep: Reputation: 0
Ah-HA! <smacks head>

Well actually, I _did_ uninstall the kernel headers.

Specifically, I removed the package kernel-headers-2.4.31-i386-1.tgz, which is necessary for compilation... there's not a kernel-headers-2.6.xx yet (maybe in Slack 11?), AFAIK, so you have to keep this package around. I had known this at some time in the past, but forgot. I will not forget again

Thanks for the help!

cheers,
~ben
 
Old 04-18-2006, 02:11 PM   #6
alephnull
LQ Newbie
 
Registered: Jan 2005
Location: Washington, DC, on the edge of the stinking pit of decay (Capitol Hill)
Distribution: Slackware 10.2
Posts: 11

Original Poster
Rep: Reputation: 0
Sorry, I realize I was unclear. Reinstalling the package kernel-headers-2.4.31-i386-1.tgz fixed the problem.

~ben
 
Old 04-18-2006, 02:29 PM   #7
Alien_Hominid
Senior Member
 
Registered: Oct 2005
Location: Lithuania
Distribution: Hybrid
Posts: 2,247

Rep: Reputation: 53
My previous post was retorical question and not some kind of unquestionable statement. Sorry for confusing.
 
Old 04-18-2006, 08:07 PM   #8
tomdkat
Member
 
Registered: May 2003
Location: S.F. Bay Area
Distribution: Ubuntu 9.04 AMD64
Posts: 595

Rep: Reputation: 30
Quote:
Originally Posted by alephnull
Sorry, I realize I was unclear. Reinstalling the package kernel-headers-2.4.31-i386-1.tgz fixed the problem.
That's scary because that should NOT have fixed your problem.

You installed kernel headers from a 2.4 kernel yet you're building a 2.6 kernel? Doesn't sound right to me. Well, maybe it does. It sounds like there are links to the 2.4 kernel sources in your /usr/include directory. This practice is one that can lead to problems, other than what you've encountered.

According to the glibc maintainers, copies of the kernel headers should be placed in /usr/include (copies of the asm and linux directories from the kernel source) and not links.

Personally, I use sym links since I'm lazy BUT I have links to the kernel source for the kernel I'm actually running.

So, can you post the output from:

$ ls -ld /usr/include/asm
$ ls -ld /usr/include/linux

Thanks!

Peace...
 
Old 04-18-2006, 11:42 PM   #9
Alien_Hominid
Senior Member
 
Registered: Oct 2005
Location: Lithuania
Distribution: Hybrid
Posts: 2,247

Rep: Reputation: 53
Because he has installed kernel-headers package, real kernel headers reside in /usr/include (not their symlinks).
 
Old 04-19-2006, 03:40 PM   #10
tomdkat
Member
 
Registered: May 2003
Location: S.F. Bay Area
Distribution: Ubuntu 9.04 AMD64
Posts: 595

Rep: Reputation: 30
Quote:
Originally Posted by Alien_Hominid
Because he has installed kernel-headers package, real kernel headers reside in /usr/include (not their symlinks).
That's cool but my concern is he has kernel headers for a 2.4 kernel installed in /usr/include and not 2.6 headers.

Peace...
 
Old 04-19-2006, 05:32 PM   #11
quiescere
Member
 
Registered: Sep 2003
Distribution: Slackware64 14.2
Posts: 54

Rep: Reputation: 15
Quote:
Originally Posted by tomdkat
That's cool but my concern is he has kernel headers for a 2.4 kernel installed in /usr/include and not 2.6 headers.

Peace...
That's fine. As I understand it, headers in /usr/src/linux should be those against which glibc was compiled. This has nothing to do with the currently running kernel. See lkml post and other related info here, here, and here. I'm not sure it's been completely resolved even now.
 
Old 04-19-2006, 10:38 PM   #12
Alien_Hominid
Senior Member
 
Registered: Oct 2005
Location: Lithuania
Distribution: Hybrid
Posts: 2,247

Rep: Reputation: 53
Look here: http://www.slackware.at/data/slackwa...eaders.WARNING
 
  


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
kernel compilation problem vishalbutte Programming 6 02-07-2006 10:55 PM
Kernel compilation problem LinuxLover Linux - Enterprise 3 05-11-2005 11:03 AM
Kernel 2.6.8 compilation problem. Mingthefirst Debian 5 08-23-2004 01:57 PM
kernel compilation problem vishamr2000 Linux - Newbie 2 08-22-2004 04:35 AM
Kernel Compilation Problem 2.6.7 ultrix Slackware 4 08-11-2004 05:31 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 07:02 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
Open Source Consulting | Domain Registration