LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   problem with alsa drivers, unable to run ./configure (https://www.linuxquestions.org/questions/linux-newbie-8/problem-with-alsa-drivers-unable-to-run-configure-75468/)

mankeponken 07-24-2003 07:20 AM

problem with alsa drivers, unable to run ./configure
 
Ok here we go...

My problem:
Can't run ./configure for the alsa-driver

My system:
IBM Thinkpad 600E
Redhat 9 - 2.4.20-19.9

My error message:
"The file /lib/modules/2.4.20.19.9/build/include/linux/version.h does not exist"
"Please install the package with with full kernel sources for your distribution or use --with-kernel=dir option to specify another directory with kernel sources (default is /usr/src/linux)"

My question:
How do I install with the full kernel sources?
Or how do I find the optional kernel source ?

Magnus

acid_kewpie 07-24-2003 07:22 AM

on the distro cd's there will be a file called kernel-sources-2.4.20-19.9.something.blah.rpm. install it.

fancypiper 07-24-2003 07:28 AM

Open an x terminal and command: redhat-config-packages

# Redhat links
RedHat Linux Manuals
Get your mp3 support here
Maximum RPM
rpmfind
Easier software management: apt4rpm - Red Carpet
RedHat 8.0 Tips & Tricks

# Redhat 7.3 down configuration commands
setup leads to several configuration tools

# Redhat 7.3 up configuration commands
Configure soundcard:
redhat-config-soundcard
Configure X server:
redhat-config-xfree86
Configure network:
redhat-config-network
Manage software:
redhat-config-packages

# Handling NTFS
New Technology FileSystem (NTFS) HOWTOs
Linux NTFS project

mankeponken 07-24-2003 07:30 AM

Ok!

But I use redhat up2date so the CD is kind of old...
Tried to find the kernel on rpmfind but it's not there...

Any ideas?

fancypiper 07-24-2003 07:38 AM

Option 1 Install with the package management tool

Option 2 (command line)
Install apt4rpm
command:
apt-get install kernel-sources
If you gotta have pointy-clicky:
apt-get install synaptic

Option 3
Install Red Carpet (requires X to be running) and install using the Red Carpet gui.

mankeponken 07-24-2003 07:41 AM

I read about that nice software!

I also found the kernel at redhat's ftp...

Thank you for your fast replyes!

I'll probably be back in a few minutes!

Thank you

mankeponken 07-24-2003 07:57 AM

Ok, I'm back...

I downloaded the file: kernel-2.4.20-19.9.i686.rpm - is this a sourcefile?

When i rpm it it's allready installed!

fancypiper 07-24-2003 08:10 AM

Perhaps you are missing the symbolic link /usr/src/linux?

# Compiling/installing kernel modules
You will need to have installed:
1. The developmental packages (compiler)
2. The kernel source code that matches your running kernel
3. The module source or install code

Check out your system and see what's under the hood and see if you installed the stuff you need to do the job. Open an x terminal and type in this sequence of commands to see what kernel we are running and see if you have the kernel source installed:
Code:

[fancy@tinwhistle phil]$ su -
Password:
[root@tinwhistle root]# uname -r
2.4.18-3

I am running kernel version 2.4.18-3. Do I have the proper source code?
Code:

[root@tinwhistle root]# cd /usr/src
[root@tinwhistle src]# ls -alc
total 3
drwxr-xr-x    4 root    root          136 Jun 12 14:53 .
drwxr-xr-x  16 root    root          424 Jun  4 12:04 ..
lrwxrwxrwx    1 root    root          14 Jun  4 12:11 linux-2.4 -> linux-2.4.18-3
drwxr-xr-x  16 root    root          584 Jun  4 12:11 linux-2.4.18-3
drwxr-xr-x    7 root    root          168 Jun  4 12:08 redhat
[root@tinwhistle src]#

I do have the same kernel version source code installed in the directory /usr/src/linux-2.4.18-3 and there is a symbolic link named linux-2.4 pointing to it.

If you don't see something similiar to this (but in color), you will need to install the kernel source.

NOTE: I noticed that Red Hat didn't make the symbolic link /usr/src/linux that all of the INSTALL files that I have read mentioned that I need, so I may as well make one now to save editing the files in the source code to install.So, I'll make it just now:
Code:

[root@tinwhistle src]# ln -s linux-2.4.18-3 linux       
[root@tinwhistle src]# ls -alc
total 3
drwxr-xr-x    4 root    root          160 Jun 12 15:46 .
drwxr-xr-x  16 root    root          424 Jun  4 12:04 ..
lrwxrwxrwx    1 root    root          14 Jun 12 15:46 linux -> linux-2.4.18-3
lrwxrwxrwx    1 root    root          14 Jun  4 12:11 linux-2.4 -> linux-2.4.18-3
drwxr-xr-x  16 root    root          584 Jun  4 12:11 linux-2.4.18-3
drwxr-xr-x    7 root    root          168 Jun  4 12:08 redhat
[root@tinwhistle src]#

Ah, there it is, so that's done.

Next, did I install the compiler?
Code:

[root@tinwhistle src]# gcc -v         
Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/2.96/specs
gcc version 2.96 20000731 (Red Hat Linux 7.3 2.96-113)
[root@tinwhistle src]#

Yes, I have a compiler installed.

If you don't have those two things installed, you have to install them first off your install CD.

If they are installed, download the source and happy comiling. :tisk: Make sure you carefully read the README and INSTALL files after extracting and before compiling/installing. :study:

# Guides to software and installation and uninstallation
LNAG - How do I install a program I downloaded from the Internet?
Rute Guide's software explanation
You might want to check out CheckInstall to manage source code installations/uninstallation

mankeponken 07-24-2003 08:37 AM

I didn't have the symbolic link.

So i added one in /usr/src.... (ln -s /boot/vmlinuz-2.4.20-19.9 linux)

Same error when running ./configure ...

If I have the source on the disk what should I search for to find it?

I tried to install the kernel tools via the packet managment but I cant install any packages untill i have installed:
Krb5-libs 1.2.7-10
Openssl=0.9.7a-2

So I downloaded them... but when I rpm I found out that I allready have a newer version installed. Resulting in a conflict.

So I tried to rpm -U but it wont work - cant find the name...

fancypiper 07-24-2003 08:59 AM

Quote:

So i added one in /usr/src.... (ln -s /boot/vmlinuz-2.4.20-19.9 linux)
That is not your kernel source code, that is the kernel image file that is loaded into memory and runs. You need to point to the kernel source code directory, /usr/src/linux-<kernel version>

I.E., the symbolic link /usr/src/linux should point to /usr/src/linux-<kernel version>

When making the link,
1. Were you root?
2. Was your working directory /usr/src?
# What directory am I using
pwd
3. Was your typing correct?
ln -s linux-<kernel version> linux

mankeponken 07-24-2003 09:29 AM

I realized that flashing red wasnt a good sign, so I fixed it and edited my post but I guess you have a lot to do so maybe you missed that...

I wrote: ...in /usr/src.... ln -s /boot/vmlinuz-2.4.20-19.9 linux
(this is the same path as in lilo.conf and the color changed)

Same problem still....

How can I see if I have the sources? I want to use:
find|grep -w kernelsourcename
but I don't know the name of the files...

When I run ./configure the file /include/linux/version.h is missing.
Maybe it's the same file as in usr/include/linux ????

fancypiper 07-24-2003 09:47 AM

Code:

[fancy@tinwhistle phil]$ su -
Password:
[root@tinwhistle root]# uname -r
2.4.18-3

I am running kernel version 2.4.18-3. Do I have the proper source code?
Code:

[root@tinwhistle root]# cd /usr/src
[root@tinwhistle src]# ls -alc
total 3
drwxr-xr-x    4 root    root          136 Jun 12 14:53 .
drwxr-xr-x  16 root    root          424 Jun  4 12:04 ..
lrwxrwxrwx    1 root    root          14 Jun  4 12:11 linux-2.4 -> linux-2.4.18-3
drwxr-xr-x  16 root    root          584 Jun  4 12:11 linux-2.4.18-3
drwxr-xr-x    7 root    root          168 Jun  4 12:08 redhat
[root@tinwhistle src]#

I have the source code for linux-2.4.18-3 installed.

fancypiper 07-24-2003 09:52 AM

If you don't see the directory /usr/src/linux-2.4.20-19.9, you don't have kernel-sources installed.

mankeponken 07-25-2003 02:56 AM

I don't.

Earlier in this thread I asked if
kernel-2.4.20-19.9.i686.rpm is a sourcefile?

When i use rpm it it says that it's allready installed!
Help me with this one, I think it will solve things...

fancypiper 07-25-2003 07:47 AM

Install kernel-sources-2.4.20-19.9.i686.rpm


All times are GMT -5. The time now is 07:27 PM.