Bug#461330: Does not start on system without sound card
Emanuele Rocca
ema at debian.org
Sat Jul 26 10:26:25 UTC 2008
Hi,
* Ronny Standtke <Ronny.Standtke at gmx.net>, [2008-01-17 21:08 +0100]:
> I tried running pathological on a system without sound card. This failed with
> the following error message:
> ---------------------
> $ pathological
> ALSA lib confmisc.c:768:(parse_card) cannot find card '0'
> ALSA lib conf.c:3510:(_snd_config_evaluate) function snd_func_card_driver
> returned error: No such device
> ALSA lib confmisc.c:392:(snd_func_concat) error evaluating strings
> ALSA lib conf.c:3510:(_snd_config_evaluate) function snd_func_concat returned
> error: No such device
> ALSA lib confmisc.c:1251:(snd_func_refer) error evaluating name
> ALSA lib conf.c:3510:(_snd_config_evaluate) function snd_func_refer returned
> error: No such device
> ALSA lib conf.c:3982:(snd_config_expand) Evaluate error: No such device
> ALSA lib pcm.c:2145:(snd_pcm_open_noupdate) Unknown PCM default
> Traceback (most recent call last):
> File "/usr/share/games/pathological/pathological.py", line 2205, in ?
> setup_everything()
> File "/usr/share/games/pathological/pathological.py", line 2188, in
> setup_everything
> pygame.mixer.init()
> pygame.error: No available audio device
> ---------------------
Ubuntu uses the following patch to fix this bug:
diff -pruN 1.1.3-8/pathological.py 1.1.3-8ubuntu2/pathological.py
--- 1.1.3-8/pathological.py 2008-06-01 14:14:45.000000000 +0100
+++ 1.1.3-8ubuntu2/pathological.py 2008-06-01 14:13:03.000000000 +0100
@@ -2185,7 +2185,12 @@ def setup_everything():
# Initialize the game module
pygame.display.init()
- pygame.mixer.init()
+ try:
+ pygame.mixer.init()
+ except:
+ print "error on pygame.mixer.init() inside setup_everything():"
+ print sys.exc_info()[0],":",sys.exc_info()[1]
+ print "...ignoring it"
pygame.font.init()
pygame.key.set_repeat(500, 30)
http://patches.ubuntu.com/p/pathological/pathological_1.1.3-8ubuntu2.patch
ciao,
ema
More information about the Pkg-games-devel
mailing list