[SOLVED] alsa-source will not compile with m-a

Everything about X, Gnome, KDE, ... and everything running on it

[SOLVED] alsa-source will not compile with m-a

Postby mrrhq » 2012-01-17 05:20

Hello,

I'm not sure what is wrong, because I removed ConsoleKit and about several other packages with it, it seems to have broken my sound modules. Now I am trying to get alsa-source to make modules for snd_hda_intel. I was trying to compile by following instructions from ALSA Wiki originally: http://www.alsa-project.org/main/index. ... -hda-intel

But I figured out that module-assistant could auto-install it. However, after trying both methods, something about the kernel-headers package may be broken.
Here's the last few lines of errors that m-a has logged:

hwdep32.c:3:27: fatal error: linux/version.h: No such file or directory
│ compilation terminated.
│ seq32.c:3:27: fatal error: linux/version.h: No such file or directory
│ compilation terminated.
│ make[5]: *** [fastdep] Error 1
│ make[5]: Leaving directory `/usr/src/modules/alsa-driver/acore/ioctl32'
│ make[4]: *** [_sfdep_ioctl32] Error 2
│ make[4]: Leaving directory `/usr/src/modules/alsa-driver/acore'
│ make[3]: *** [dep] Error 1
│ make[3]: Leaving directory `/usr/src/modules/alsa-driver'
│ make[2]: *** [include/sndversions.h] Error 2
│ make[2]: Leaving directory `/usr/src/modules/alsa-driver'
│ make[1]: *** [build-stamp] Error 2
│ make[1]: Leaving directory `/usr/src/modules/alsa-driver'
│ make: *** [kdist_image] Error 2


I already installed and reinstalled kernel-headers-amd64.

Here's some up to date diagnostic errors and information relating to what's going on:

# uname -a
Linux pc-main 3.1.0-1-amd64 #1 SMP Tue Jan 10 05:01:58 UTC 2012 x86_64 GNU/Linux


$ alsamixer
cannot open mixer: No such file or directory


# lspci -v | grep Audio
[ . . . ]
00:1b.0 Audio device: Intel Corporation N10/ICH 7 Family High Definition Audio Controller (rev 01)
Subsystem: Hewlett-Packard Company Device 2a5e
Flags: bus master, fast devsel, latency 0, IRQ 5
Memory at fdff8000 (64-bit, non-prefetchable) [size=16K]
Capabilities: [50] Power Management version 2
Capabilities: [60] MSI: Enable- Count=1/1 Maskable- 64bit+
Capabilities: [70] Express Root Complex Integrated Endpoint, MSI 00
Capabilities: [100] Virtual Channel
Capabilities: [130] Root Complex Link
[ . . . ]


# dpkg-query -l | grep alsa
ii alsa-base 1.0.23+dfsg-4 ALSA driver configuration files
ii alsa-oss 1.0.17-5 ALSA wrapper for OSS applications
ii alsa-source 1.0.23+dfsg-4 ALSA driver sources
ii alsa-tools 1.0.24.1-3 Console based ALSA utilities for specific hardware
ii alsa-utils 1.0.24.2-4 Utilities for configuring and using ALSA
ii bluez-alsa 4.96-3 Bluetooth ALSA support
ii gstreamer0.10-alsa 0.10.35-1 GStreamer plugin for ALSA
rc libsdl1.2debian-alsa 1.2.14-6.1 Simple DirectMedia Layer (with X11 and ALSA options)

# alsactl init
alsactl: init:1743: No soundcards found...


# cat /etc/modprobe.d/alsa-base.conf
# autoloader aliases
install sound-slot-0 /sbin/modprobe snd-card-0
install sound-slot-1 /sbin/modprobe snd-card-1
install sound-slot-2 /sbin/modprobe snd-card-2
install sound-slot-3 /sbin/modprobe snd-card-3
install sound-slot-4 /sbin/modprobe snd-card-4
install sound-slot-5 /sbin/modprobe snd-card-5
install sound-slot-6 /sbin/modprobe snd-card-6
install sound-slot-7 /sbin/modprobe snd-card-7
# Cause optional modules to be loaded above generic modules
install snd /sbin/modprobe --ignore-install snd && { /sbin/modprobe --quiet snd-ioctl32 ; /sbin/modprobe --quiet snd-seq ; }
install snd-rawmidi /sbin/modprobe --ignore-install snd-rawmidi && { /sbin/modprobe --quiet snd-seq-midi ; : ; }
install snd-emu10k1 /sbin/modprobe --ignore-install snd-emu10k1 && { /sbin/modprobe --quiet snd-emu10k1-synth ; : ; }

# Prevent abnormal drivers from grabbing index 0
options bt87x index=-2
options cx88_alsa index=-2
options snd-atiixp-modem index=-2
options snd-intel8x0m index=-2
options snd-via82xx-modem index=-2
# Keep snd-pcsp from beeing loaded as first soundcard
options snd-pcsp index=-2
# Keep snd-usb-audio from beeing loaded as first soundcard
options snd-usb-audio index=-2
# Custom added line
options snd-hda-intel probe_mask=1 model=auto

# lsmod | grep snd; echo end of output
end of output

# cat /proc/asound
cat: /proc/asound: No such file or directory

# /etc/init.d/alsa-utils start
Setting up ALSA...done (none loaded).


So first and foremost, I have to compile the kernel modules, but I can't figure out why the version.h or other header files aren't there.
Any suggestions.
Oh, and please, keep solutions "Debian Free Software" limited -- I don't use non-free or contrib.
Last edited by mrrhq on 2012-01-20 20:36, edited 1 time in total.
mrrhq
 
Posts: 20
Joined: 2011-04-26 19:38

Re: alsa-source will not compile with m-a

Postby vbrummond » 2012-01-17 05:25

The alsa source is a far older version than the one already compiled into the 3.0 kernel, thus it will never work. In fact I think it only compiles on the stock Squeeze 2.6.32, unless they made a newer alsa-source package.
Always on Debian Testing
vbrummond
 
Posts: 4468
Joined: 2010-03-02 01:42

Re: alsa-source will not compile with m-a

Postby mrrhq » 2012-01-17 05:29

vbrummond wrote:The alsa source is a far older version than the one already compiled into the 3.0 kernel, thus it will never work. In fact I think it only compiles on the stock Squeeze 2.6.32, unless they made a newer alsa-source package.


I still have the 2.6.x.x kernel image installed. I could fall back to that one for now.

But back to the problem, I think the alsa-utils version is the same. Maybe alsa-lib and alsa-drivers are newer? Would removing alsa-source and compiling alsa-lib and alsa-driver work?

Edit:

Again, I also had problems compiling alsa-drivers with the Wiki instructions. So I may be without sound for a while until I can figure out what is causing the problem. I will try again and post any errors.
mrrhq
 
Posts: 20
Joined: 2011-04-26 19:38

Re: alsa-source will not compile with m-a

Postby vbrummond » 2012-01-17 05:48

If you think you broke the drivers, perhaps just reinstall the alsa packages and kernel image. Compiling would end up the same as just installing the deb package unless you need to change the source.
Always on Debian Testing
vbrummond
 
Posts: 4468
Joined: 2010-03-02 01:42

Re: alsa-source will not compile with m-a

Postby mrrhq » 2012-01-17 05:54

Okay, so here is the error with compiling alsa-driver-1.0.24 with make.
Code: Select all
patching file memalloc.c
gcc -D__KERNEL__ -DMODULE=1 -I/usr/src/alsa/alsa-driver-1.0.24/include  -I/lib/modules/3.1.0-1-amd64/build/include -I/lib/modules/3.1.0-1-amd64/source/include -I/lib/modules/3.1.0-1-amd64/source/arch/x86/include -O2 -mno-red-zone -mcmodel=kernel -fno-reorder-blocks -fno-strength-reduce -finline-limit=2000 -Wdeclaration-after-statement -Wno-pointer-sign -D__SMP__ -DCONFIG_SMP -DLINUX -Wall -Wstrict-prototypes -fomit-frame-pointer -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common -pipe -DALSA_BUILD -nostdinc -iwithprefix include -DMODVERSIONS -include /lib/modules/3.1.0-1-amd64/source/include/linux/modversions.h   -DEXPORT_SYMTAB -c hwdep.c
cc1: fatal error: /lib/modules/3.1.0-1-amd64/source/include/linux/modversions.h: No such file or directory
compilation terminated.
make[1]: *** [hwdep.o] Error 1
make[1]: Leaving directory `/usr/src/alsa/alsa-driver-1.0.24/acore'
make: *** [compile] Error 1
[1]    4074 exit 2     make

I'll try the Git repository one too.

vbrummond wrote:If you think you broke the drivers, perhaps just reinstall the alsa packages and kernel image. Compiling would end up the same as just installing the deb package unless you need to change the source.

I did apt-get --reinstall install alsa-[. . .] so something else is causing this issue. I'll try the kernel image too.

EDIT:
Reinstalling the kernel image and rebooting did not work. I'm still baffled here.
mrrhq
 
Posts: 20
Joined: 2011-04-26 19:38

Re: alsa-source will not compile with m-a

Postby vbrummond » 2012-01-17 06:13

Glad you sorted it out, sorry I do not know much about compiling alsa except that it is not supported to work from 'alsa-source' except when using 2.6.32. I think the alsa-source package in testing is still lingering practically from when Squeeze went stable.
Always on Debian Testing
vbrummond
 
Posts: 4468
Joined: 2010-03-02 01:42

Re: alsa-source will not compile with m-a

Postby mrrhq » 2012-01-19 08:24

Even after compiling alsa-driver, alsa-lib, and alsa-utils, it is still not working the way I want it too. I will also try alsa-tools and alsa-oss.

This is really weird and frustrating. I've entirely given up on the ALSA package from the Debian Team, which means I've purged every alsa-* Debian package, and have just, at least on one occasion, got alsamixer to show information, even though sound still did not play, but that is still a step forward unlike this "alsa-base" and "alsa-source", which aren't even listed on ALSA's website.

So I've established that using m-a and alsaconf is probably outdated. What is really puzzling me is, since I have extremely no diagnostic experience with Linux, I really cannot seem to find out what caused this issue in the first place. That information would be really helpful at this moment. I cannot just expect not to run into problems when compiling ALSA and expecting the utilities and sound to work (I did compile the aforementioned three packages, but the sound still did not work even after reloading ALSA and the sound modules.) I also think that my udev configuration may be broken. There are devices for ALSA that are not showing up in /dev, like /dev/sequencer and /dev/midi.

I'll keep trying, but I feel like I've really given up with the sound and the on-board HDA Intel entirely. The dmesg utility is useless for diagnosing this, and I don't know what else to do. I'm stuck.
For the first time in all of my computing history, I think I will need to buy an external sound card.

I won't give up, however. If needed, I can still provide more diagnostic information.

modprobe snd-hda-intel ; modprobe snd-pcm-oss ; modprobe snd-mixer-oss ; modprobe snd-seq-oss [12-01-19][0:08:20]
FATAL: Module snd_seq_oss not found.


EDIT:
Okay I found something that might help greatly, I can use sudo alsamixer but not alsamixer. It seems as if I can only use certain parts of alsa as root. I can start mpd as a normal user and hear the music playing, but I think the problem was with how ALSA was configured. How should I fix this? I think I just used su to log in as root when using configure and make.

By that way, this happened when switching back to kernel version 2.6.32-5. I'll see if the some situations occur in 3.1.0-1
mrrhq
 
Posts: 20
Joined: 2011-04-26 19:38

Re: alsa-source will not compile with m-a

Postby mrrhq » 2012-01-20 20:36

Mr. R wrote:Even after compiling alsa-driver, alsa-lib, and alsa-utils, it is still not working the way I want it too. I will also try alsa-tools and alsa-oss.

This is really weird and frustrating. I've entirely given up on the ALSA package from the Debian Team, which means I've purged every alsa-* Debian package, and have just, at least on one occasion, got alsamixer to show information, even though sound still did not play, but that is still a step forward unlike this "alsa-base" and "alsa-source", which aren't even listed on ALSA's website.

So I've established that using m-a and alsaconf is probably outdated. What is really puzzling me is, since I have extremely no diagnostic experience with Linux, I really cannot seem to find out what caused this issue in the first place. That information would be really helpful at this moment. I cannot just expect not to run into problems when compiling ALSA and expecting the utilities and sound to work (I did compile the aforementioned three packages, but the sound still did not work even after reloading ALSA and the sound modules.) I also think that my udev configuration may be broken. There are devices for ALSA that are not showing up in /dev, like /dev/sequencer and /dev/midi.

I'll keep trying, but I feel like I've really given up with the sound and the on-board HDA Intel entirely. The dmesg utility is useless for diagnosing this, and I don't know what else to do. I'm stuck.
For the first time in all of my computing history, I think I will need to buy an external sound card.

I won't give up, however. If needed, I can still provide more diagnostic information.

modprobe snd-hda-intel ; modprobe snd-pcm-oss ; modprobe snd-mixer-oss ; modprobe snd-seq-oss [12-01-19][0:08:20]
FATAL: Module snd_seq_oss not found.


EDIT:
Okay I found something that might help greatly, I can use sudo alsamixer but not alsamixer. It seems as if I can only use certain parts of alsa as root. I can start mpd as a normal user and hear the music playing, but I think the problem was with how ALSA was configured. How should I fix this? I think I just used su to log in as root when using configure and make.

By that way, this happened when switching back to kernel version 2.6.32-5. I'll see if the some situations occur in 3.1.0-1


EDIT2:
I am sorry. The issue is now solved. It turns out that the user was not added to the audio group. Maybe removing ConsoleKit or other utilities it depended on caused this. Here's what I did:

Code: Select all
groups

To show all groups that the user is in. Then just add any missing groups from /etc/group.
Code: Select all
cat /etc/group

By using gpasswd:
Code: Select all
sudo gpasswd  -a <user> <group>

So I have also solved this by not using Debian's ALSA packages and instead using alsa-lib, alsa-driver instead of alsa-base, etc...
mrrhq
 
Posts: 20
Joined: 2011-04-26 19:38


Return to Desktop & Multimedia

Who is online

Users browsing this forum: No registered users and 7 guests

fashionable