QQ登录

只需一步,快速开始

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 1882|回复: 35

安装声卡时的问题?在线等?

[复制链接]
发表于 2004-9-15 10:08:39 | 显示全部楼层 |阅读模式
我下了alsa1.0.5的驱动,在driver目录中执行./configure时没有什么,但执行make时出现了下面的情况,请指教。
make all-deps
make[1]:Entering directory '/home/down/soft/alsa-1.0.5/alsa-driver-1.0.5a'
make[1]:Nothing to be do for 'all-deps'
make[1]: leaving directory'/home/down/soft/alsa-1.0.5/alsa-driver-1.0.5a'
please,run the configure script at first /home/down/soft/alsa-1.0.5/alsa-driver-1.0.5a'/home/down/soft/alsa-1.0.5/alsa-driver-1.0.5a'
发表于 2004-9-15 10:35:24 | 显示全部楼层
Nothing to be do...由于你没有做任何初始化设置,什么也没有做。
回复

使用道具 举报

 楼主| 发表于 2004-9-15 14:32:50 | 显示全部楼层
bwb,哪如何做啊?能说仔细一点吗?
回复

使用道具 举报

发表于 2004-9-15 15:13:46 | 显示全部楼层
你做过configure吗?没有就在安装目录下先做一下:#./configure
回复

使用道具 举报

 楼主| 发表于 2004-9-15 16:52:01 | 显示全部楼层
做了, 先做./configure
                make
                 make install
                 ./snndevices
不行,在做第二行时就出现了上面的错误,是不是和我的目录有关。
谢谢你不厌其烦的回答我。
回复

使用道具 举报

发表于 2004-9-15 22:54:16 | 显示全部楼层
Make a directory to store the alsa source code in.

cd /usr/src
mkdir alsa
cd alsa
cp /downloads/alsa-* .

Now unzip and install the alsa-driver package

bunzip2 alsa-driver-xxx
tar -xf alsa-driver-xxx
cd alsa-driver-xxx
./configure --with-cards=au8820 --with-sequencer=yes;make;make install

NB. If you are using drivers before 0.9.4 then you need to run

./snddevices

If you use devfs then you should not run the snddevices script

The snddevices script sets the permissions for the devices it creates to root. You should

chmod a+rw /dev/dsp /dev/mixer /dev/sequencer /dev/midi

Now unzip and install the alsa-lib package

cd ..
bunzip2 alsa-lib-xxx
tar -xf alsa-lib-xxx
cd alsa-lib-xxx
./configure;make;make install

Now unzip and install the alsa-utils package

cd ..
bunzip2 alsa-utils-xxx
tar -xf alsa-utils-xxx
cd alsa-utils-xxx
./configure;make;make install

Now insert the modules into the kernel.

modprobe snd-au8820;modprobe snd-pcm-oss;modprobe snd-mixer-oss;modprobe snd-seq-oss

NB. For drivers older than 0.9.0beta11 use:

modprobe snd-card-au8820

Now adjust your soundcards volume levels. All mixer channels are muted by default. You must use a native mixer program to unmute appropriate channels, for example alsamixer from the alsa-utils package. Note that some usb-audio devices do not have internal mixer controls.

alsamixer

You can also look at the utils/alsasound file. This script is designed for the RedHat distribution, but it can be used with other distributions which use System V style rc init scripts. This will allow you to load your modules at boot time. If you want to do this you could just compile them into the kernel instead and save yourself the hassle of coming to terms with the rc init scripts.

Setting up modprobe and kmod support

Before you send a mail complaining that "I don't have /etc/modules.conf, where do I find it ....." ,The /etc/conf.modules has been deprecated with a few distro's so in your case, it may still be /etc/conf.modules. Basically they are both the same, but recent version of modutils uses /etc/modules.conf instead. Nothing to worry about as such, optionally please update to latest version of modutils. This should solve your problem.

Here's the example for this card. Copy and paste this to the bottom of your /etc/modules.conf file.

Note to debian users: You need to save this information into a file in the /etc/modutils/ directory (Eg. /etc/modutils/alsa) and run update-modules

# ALSA portion
alias char-major-116 snd
alias snd-card-0 snd-au8820
# module options should go here

# OSS/Free portion
alias char-major-14 soundcore
alias sound-slot-0 snd-card-0

# card #1
alias sound-service-0-0 snd-mixer-oss
alias sound-service-0-1 snd-seq-oss
alias sound-service-0-3 snd-pcm-oss
alias sound-service-0-8 snd-seq-oss
alias sound-service-0-12 snd-pcm-oss


NB. For drivers older than 0.9.0beta11 use:

snd-card-au8820

To copy and paste the above to your /etc/modules.conf file follow these instructions.

A short explanation of what happens in the /etc/modules.conf file

Native Devices

After the main multiplexer is loaded, its code requests top level sound card module. String snd-card-%i is requested for native devices where %i is sound card number from zero to seven. String sound-slot-%i is requested for native devices where %i is slot number for ALSA owner this means sound card number. The options line allows you to set various config options before the module is loaded. String snd_id lets you set the name of the card which is returned in the /proc/asound/cards file. Other options may be available which are card specific. The options for these are found in the INSTALL file or above.

xyz@localhost#pico /etc/modules.conf

# ALSA portion
alias snd-card-0 snd-interwave
alias snd-card-1 snd-cmipci
options snd-cmipci id="first" enable_midi="1"

# OSS/Free portion
alias sound-slot-0 snd-card-0
alias sound-slot-1 snd-card-1


NB. For drivers older than 0.9.0rc5 use:

options snd-cmipci snd_id="first" snd_enable_midi="1"

The "snd_" prefix has been removed from the "module options" to fit with the kernel standard.

Autoloading OSS/free emulation

We are finished at this point with the configuration for ALSA native devices, but you may also need autoloading for ALSA add-on OSS/Free emulation modules. At this time only one module does not depend on any others, thus must be loaded separately, snd-pcm1-oss.o. String sound-service-%i-%i is requested for OSS/Free service where first %i means slot number e.g. card number and second %i means service number.

xyz@localhost#pico
/etc/modules.conf

# OSS/Free portion - card #1
alias sound-slot-0 snd-card-0
alias sound-service-0-0 snd-mixer-oss
alias sound-service-0-1 snd-seq-oss
alias sound-service-0-3 snd-pcm-oss
alias sound-service-0-8 snd-seq-oss
alias sound-service-0-12 snd-pcm-oss

# OSS/Free portion - card #2 (cmipci)
alias sound-slot-1 snd-card-1
alias sound-service-1-0 snd-mixer-oss
alias sound-service-1-3 snd-pcm-oss
alias sound-service-1-12 snd-pcm-oss

The alias for snd-seq-oss is not necessary on the second device, because there is only one /dev/sequencer, regardless how many devices you have.

The .asoundrc file

Find out more about this file here.

This file allows the you to have more advanced control over your card/device. Some very useful applications will not work without it. The .asoundrc file consists of definitions of the various cards available in your system. It also gives you access to the pcm plugins in alsa-lib. These allow you to do tricky things like combine your cards into one or access multiple i/o's on your mulitchannel card.

Below is the most basic definition.

Make a file called .asoundrc in your home and/or root directory.

vi /home/xxx/.asoundrc

copy and paste the following into the file then save it.

pcm.au8820 {
type hw
card 0
}

ctl.au8820 {
type hw
card 0
}
_________________
回复

使用道具 举报

 楼主| 发表于 2004-9-16 08:11:12 | 显示全部楼层
非常感谢!
回复

使用道具 举报

 楼主| 发表于 2004-9-16 08:37:52 | 显示全部楼层
linky_fan:
         救命啊。我已经在/usr/src中建了目录,然后将三个文件拷到其中,但在driver目录中做make命令时就遇到
make all-deps
make[1]:Entering directory '/usr/src/alsa/alsa-driver-1.0.5a'
make[1]:Nothing to be do for 'all-deps'
make[1]: leaving directory'/usr/src/alsa/alsa-driver-1.0.5a'
please,run the configure script at first
郁闷!!
回复

使用道具 举报

 楼主| 发表于 2004-9-16 10:24:33 | 显示全部楼层
我发现了新问题,在我做./configure时就出现了问题,它说检查kernel version,在它默认的目录/lib/modules/2.4.18-14/build/include/linux中没有version.h这个文件,它说可以在做./configure时指定目录,请问如何在./configure 后加目录。我发现这个文件在/usr/src/linux/include/linux里面。
还有,我如何能将version.h这个文件让它出现在它默认的目录中能。
3x


我在alsa-driver目录里执行了./configure --with-kernel=/usr/src/linux/indulde/linux
出现的命令比刚才多了,但是到最后它仍说找不到version.h文件,然后又说它上deafult 女目录在(/usr/src/linux)中。不知为何,请救命.
回复

使用道具 举报

发表于 2004-9-16 10:33:18 | 显示全部楼层
./configure --help
或看看安装目录下的INSTALL
回复

使用道具 举报

 楼主| 发表于 2004-9-16 10:38:33 | 显示全部楼层
我看了,它只说了如何安装,但没讲这个问题,我刚才将version.h文件拷到时/usr/src/linux中,./confiugre算是通过了,但make时,它又不对了.
bwb ,请教我吧!

这是install文件的一段,
Note that module option names were changed in 0.9.0rc4. The 'snd_' prefix
was removed. You may use script in utils directory (module-options) to
convert your older /etc/modules.conf to newer one.
我已在/usr/src/alsa-driver-1.0.5a/utils目录中找到了module-options,它的内容如下:
#!/bin/bash

if [ -z "$1" ]; then
  file=/etc/modules.conf
else
  file=$1
fi

if [ ! -f $file ]; then
    echo "file $file not found"
    exit 1
fi

rm -f $file.new
sed -e 's/snd_//g' < $file > $file.new
if cmp -s $file $file.new; then
    # nothing changed
    rm -f $file.new
    echo "Nothing to be changed."
else
    diff -u $file $file.new | less
    echo "Please, check and copy $file.new to $file"
fi
exit 0


还有,这是modules.conf的文件:
alias parport_lowlevel parport_pc
alias eth0 eepro100
alias eth1 via-rhine
alias usb-controller ehci-hcd
alias sound-slot-0 ad1881(我自已改掉的)
post-install sound-slot-0 /bin/aumix-minimal -f /etc/.aumixrc -L >/dev/null 2>&1 || :
pre-remove sound-slot-0 /bin/aumix-minimal -f /etc/.aumixrc -S >/dev/null 2>&1 || :
alias usb-controller1 usb-uhci
我是不是要将module.option中的内容复制品到modules.conf中能。
3x
回复

使用道具 举报

发表于 2004-9-16 11:24:13 | 显示全部楼层
下面我也没做过,因为我对声音无要求,所以没有下过这方面的工夫,就我所知咱们讨论吧。
1.感觉不用将module.option的内容考入modules.conf
2.modules.conf
...
alias sound-slot-0 新模块
3.重起,再试试。
回复

使用道具 举报

 楼主| 发表于 2004-9-16 11:30:53 | 显示全部楼层
我看不懂第二句,是在modules.conf中加一句alias sound-slot-0 新声卡名称。?
回复

使用道具 举报

发表于 2004-9-16 11:40:28 | 显示全部楼层
就是你编好的模块名称,应该类似:
alias sound-service-0-0 snd-mixer-oss
alias sound-service-0-1 snd-seq-oss
alias sound-service-0-3 snd-pcm-oss
alias sound-service-0-8 snd-seq-oss
alias sound-service-0-12 snd-pcm-oss
回复

使用道具 举报

 楼主| 发表于 2004-9-16 17:02:19 | 显示全部楼层
我将modules.conf换成了如下的内容:
# ISA PnP support (don't use IRQs 9,10,11,12,13)
options isapnp isapnp_reserve_irq=9,10,11,12,13
# ALSA native device support
alias char-major-116 snd
options snd major=116 cards_limit=1
alias snd-card-0 snd-AD1881
options snd-AD1881 index=0 id="87654321"
# OSS/Free setup
alias char-major-14 soundcore
alias sound-slot-0 snd-card-0
alias sound-service-0-0 snd-mixer-oss
alias sound-service-0-1 snd-seq-oss
alias sound-service-0-3 snd-pcm-oss
alias sound-service-0-8 snd-seq-oss
alias sound-service-0-12 snd-pcm-oss


重启后,我的鼠标找不到了。做make操作时仍然是错误。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

GMT+8, 2024-11-8 05:32 , Processed in 0.076034 second(s), 15 queries .

© 2021 Powered by Discuz! X3.5.

快速回复 返回顶部 返回列表