Configuring Your Laptop for GNOME and Sound
If you followed my tutorial, “Setting Up a Base Linux Install on a Laptop”, you should have a base Linux install up and running Window Maker, Debian's default window manager. Although Window Maker is useful, I find the feature-rich environments of GNOME and KDE to be more useful in a desktop/laptop configuration. In this article I'm going to discuss how to further configure your Debian laptop with GNOME 2.2 and enable sound using the basic modules that come stock with the 2.4 kernel.
Let us start by installing GNOME 2.2. There are multiple ways to install it, but really only one way is viable for a Debian user. All that you have to do is run apt-get install gnome-core. Debian's apt-get system goes out to the Sid repositories listed in /etc/apt/source.list and downloads Debian's latest build of GNOME and all of its many required packages. This automation saves you tons of time. Although I have found a couple of missing packages here and there, the convenience of an apt-get install by far outweighs the downside of compiling it from source. Using apt-get, the entire process takes a matter of minutes; if you were to do a source compile from scratch it could take you hours. For those of you who need to have the absolutely newest build of GNOME, you're stuck with a source install. Fortunately, a utility called Gargnome can assist you with a source compile. Although Gargnome is no apt-get, it is a heck of a lot better then messing with each individual package.
Once apt-get has finished installing GNOME, you need to change the default window manager from Window Maker to Metacity. If Metacity is not made the default default window manager, GNOME does not work correctly; windows and menus pop up in funny spots and its overall appearance is a mess. To change the default window manager run update-alternatives --config x-window-manager. This lists all of the available window managers available on your system and allows you to pick which one should be the default. After you have made the selection, run startx and prepare for the amazement of what is known as GNOME 2.2.
The first time GNOME 2.2 runs, you will receive errors about xscreensaver being missing and /dev/sound/mixer not existing. apt-get install xscreensaver fixes the screensaver error. The mixer popup occurs when you have yet to configure sound support. Due to the wide variety of available embedded chipsets, there is no way I can go through every variation in this article. What I can do is go through configuring one of the more popular sound chipsets, the i810. In my next article I'm going to explain how to set up the Alsa modules, which offer a more standardized configuration. If you don't want to wait, here's some direction to get your sound cranking using the stock kernel modules:
1. Compile the kernel with support for the i810 chipset. Here's the settings to be made for the 2.4 kernel:
Sound card support
Intel ICH (i8xx)
OSS sound modules
Persistent DMA buffers
Crystal CS4232 based (PnP) cards
2. After you recompile the kernel to incorporate the changes made in the previous step, the sound-oriented modules are created. We need to load two of them, i810_audio and ac97_codec. If you want to load the modules by hand you could run insmod $module_name. Or, to have the system load them at boot time, add them both to /etc/modules. In addition, for i810_audio to load properly, ac97_codec must be loaded first.
3. Add the following lines to /etc/modules/aliases. This step is dependent on your sound card; for the i810 you should add these to the bottom of the file:
alias sound-slot-0 i810_audio alias sound-service-0-0 i810_audio alias sound-slot-2 off alias sound-service-0-2 off alias sound-slot-3 i810_audio alias sound-service-0-3 i810_audio alias sound-slot-4 i810_audio alias sound-service-0-4 i810_audio
4. Run update-modules
5. Create a group called audio, and add to it all users that are to implement sound. Make sure that /dev/dsp belongs to the audio group as well.
If all went correctly, after a reboot you should have sound in GNOME. A good way to test this is to try to play a music CD. This will avoid any possible problems you may be having with ESD, GNOME's sound dæmon. Which brings us to one of the problems I found to be an outcome of apt-getting GNOME 2.2, in regards to missing packages. Four multimedia related packages are missing: esound, esound-clients, gnome-audio and gstreamer-plugins. If you want to use your machine for any type of multimedia, you should apt-get these packages yourself. This may not necessarily be a problem with the install itself, because not all GNOME 2.2 users are interested in sound. But, if you don't specifically know to install them, it can be difficult to troubleshoot the cause of the resulting problems.
Getting Started with DevOps - Including New Data on IT Performance from Puppet Labs 2015 State of DevOps Report
August 27, 2015
12:00 PM CDT
DevOps represents a profound change from the way most IT departments have traditionally worked: from siloed teams and high-anxiety releases to everyone collaborating on uneventful and more frequent releases of higher-quality code. It doesn't matter how large or small an organization is, or even whether it's historically slow moving or risk averse — there are ways to adopt DevOps sanely, and get measurable results in just weeks.
Free to Linux Journal readers.Register Now!
- August 2015 Issue of Linux Journal: Programming
- Django Models and Migrations
- Hacking a Safe with Bash
- Secure Server Deployments in Hostile Territory, Part II
- The Controversy Behind Canonical's Intellectual Property Policy
- Huge Package Overhaul for Debian and Ubuntu
- Shashlik - a Tasty New Android Simulator
- Embed Linux in Monitoring and Control Systems
- KDE Reveals Plasma Mobile
- diff -u: What's New in Kernel Development