LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
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 12-15-2007, 09:24 AM   #1
gopi.d
Member
 
Registered: Feb 2006
Location: India
Distribution: Slackware 12, Fedora 7, Kubuntu-7.04
Posts: 172

Rep: Reputation: 30
compiling from source fails after kernel upgrade in slackware12


i did a full install of slackware 12 and upgraded the kernel to 2.6.23 from www.kernel.org to get my tvtuner working. all went fine and system works fine except i could not compile any package from source, when i try to compile and source package i get the below error.
root@gopi:/usr/src/kompile-0.3-beta3# ./configure
checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
checking target system type... i686-pc-linux-gnu
checking for a BSD-compatible install... /usr/bin/ginstall -c
checking for -p flag to install... yes
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for style of include used by make... GNU
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... /lib/cpp
configure: error: C preprocessor "/lib/cpp" fails sanity check
See `config.log' for more details.
root@gopi:/usr/src/kompile-0.3-beta3#

i tried re-installing gcc, gcc-cpp, libstdc++, but to vain the problem is not solved and still compiling quits with the same error. pls guide me to solve this problem.
 
Old 12-15-2007, 09:35 AM   #2
BCarey
Senior Member
 
Registered: Oct 2005
Location: New Mexico
Distribution: Slackware
Posts: 1,639

Rep: Reputation: Disabled
Which commands did you use to compile and install your kernel. More specifically, did you install the kernel headers? If so you should reinstall the kernel headers from Slack 12.

Brian
 
Old 12-15-2007, 09:49 AM   #3
gopi.d
Member
 
Registered: Feb 2006
Location: India
Distribution: Slackware 12, Fedora 7, Kubuntu-7.04
Posts: 172

Original Poster
Rep: Reputation: 30
i did make oldconfig, make menuconfig, make all, make modules_install, make install to install the new kernel and afer that i removed the old kernel, kernel-source, kernel headers in kpackage. will the old kernel headers work with new kernel.
 
Old 12-15-2007, 10:05 AM   #4
H_TeXMeX_H
LQ Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301
Reinstall the old kernel headers, don't ever remove them, they are necessary and it isn't a good idea to upgrade them due to issues with different versions of glibc, etc.
 
Old 12-15-2007, 10:16 AM   #5
gopi.d
Member
 
Registered: Feb 2006
Location: India
Distribution: Slackware 12, Fedora 7, Kubuntu-7.04
Posts: 172

Original Poster
Rep: Reputation: 30
i see the kernel headers in slackware 12 dvd is for the default kernel 2.6.21.5-smp, but i had upgraded the kernel to 2.6.23 will the old kernel headers work for the new kernel or i have to find new kernel headers for the new kernel?
 
Old 12-15-2007, 10:28 AM   #6
H_TeXMeX_H
LQ Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301
The old kernel headers, the ones that came with slackware, please reinstall them the '2.6.21.5' version.
 
Old 12-15-2007, 10:45 AM   #7
gopi.d
Member
 
Registered: Feb 2006
Location: India
Distribution: Slackware 12, Fedora 7, Kubuntu-7.04
Posts: 172

Original Poster
Rep: Reputation: 30
thanks for your guide had re-installed the kernel headers for install dvd. i'll give a try and comeback
 
Old 12-15-2007, 11:21 AM   #8
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928

Rep: Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612
The kernel-headers are *not supposed* to match the kernel version you are running. they are supposed to be the same ones used to compile the glibc version in use. When a distro version is originally created, the kernel version and kernel-headers vesrion will *usually* be the same. But the important thing is that the glibc version is compiled against the kernel-headers versions and all software compiled for the system later should be compile with the same version of kernel-headers -no matter which kernel you are running at the time. The kernel-headers are slightly mis-named and are sometimes called the libc headers. When you compile a kernel, the kernel sources supply their own headers and do not use the installed kernel(libc)-headers. As mentioned, you should never upgrade the kernel-headers package unless you are upgrading the whole system.
 
Old 12-16-2007, 01:06 AM   #9
gopi.d
Member
 
Registered: Feb 2006
Location: India
Distribution: Slackware 12, Fedora 7, Kubuntu-7.04
Posts: 172

Original Poster
Rep: Reputation: 30
Thanks a lot for your guide gnashley i re-installed the kernel headers and things are going fine now.
 
  


Reply



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
Compiling FlightGear from source fails cluelessnewb Linux - Software 5 07-17-2006 03:42 PM
insmod fails after compiling new kernel Brotherswing Linux - Hardware 4 02-17-2006 11:51 PM
10.1 install kernel and kernel-source different - build fails Feebles Mandriva 2 06-10-2005 06:58 PM
kernel upgrade fails, VFS error cragwolf Slackware 6 08-19-2004 01:17 AM
Upgrade KDE by compiling from source... Seph64 Slackware 6 05-15-2003 02:43 PM

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

All times are GMT -5. The time now is 05:39 PM.

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