Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

Some programs don't have sound, in particular ZSNES and anything I run from the command line. So my question has two parts:

  1. How can I diagnose this problem? (I'm thinking of a command like lspci that will display the idiosyncracies of my system setup... would that be lsmod?)

  2. What do I need to install/modify to fix this?

share|improve this question

1 Answer 1

up vote 1 down vote accepted

There are several different sound framework under many unix variants. Typically the framework used by the program talks to the framework that can talk to the hardware. If some programs have sound and others don't, the most likely explanation is that the non-working programs are using a sound system that is not working. Commands like lspci and lsmod might be helpful if you had a hardware problem, but they're not likely to be relevant if you have a sound framework problem.

Common sound frameworks include OSS (older Linux kernel interface), ALSA (newer Linux kernel interface), Pulseaudio (the default on Ubuntu, supported by more and more programs), aRts (mostly used by older versions of KDE), ESound (esd) (older versions of Gnome and many older programs), JACK (supported directly only by a few high-end applications), and more.

Here is some information that you should include in a question like this one.

  • Your operating system (e.g. Ubuntu 10.04, OpenBSD 4.7, …). This is something you should always indicate when asking a unix question (even on a distribution-specific forum, indicate the version).
  • What sound framework(s) you've installed and how you configured it/them. (“Whatever is installed by default, I didn't knowingly change anything” is a valid answer.)
  • What sound framework the non-working program is using. This may be hard for you to figure out; if you can't find the answer, give as much data as you can (e.g. “I'm using the binary downloaded from http://​example.com/foo.zip”), so that people can look it up for themselves or suggest more places for you to look.
    • This may be mentioned in the program's documentation.
    • It may depend on compile-time options, so check the place where you got the program.
    • The program may have a way to switch between sound frameworks on the command line or in a configuration file.
    • If the program came in a package (deb, rpm, pkg, etc.), the package's dependencies should include a sound framework.
    • Try ldd /path/to/executable. This command will display the shared libraries the program is using; hopefully one of them corresponds to the sound framework.
  • If there are any error messages, report them (copy and paste). Check if the program has a log file somewhere, or if there's an option for it to produce more detailed error messages.

If you give more information and I have more to contribute, I'll edit this answer.

share|improve this answer
    
This particular distro is Debian 5. I managed to get sound to work in both programs by installing libsdl1.2-debian. I have no idea why cplay would use SDL. –  ixtmixilix Nov 3 '10 at 1:12

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.