Known Linux Installation Issues

This page details some installation issues involving bugs either in Linux distributions or in libraries that libavg uses. We can't fix these ourselves, because they aren't libavg bugs - we do try to provide workarounds, however.

glibc invalid pointer

(!) Note: (!)
Libavg contains a workaround for this bug starting with version 1.7.

There is a bug involving libstdc++ and OpenGL libraries (Mesa and FGLRX) that causes libavg to crash with this (or similar) messages:

[*** glibc detected *** free(): invalid pointer: 0xb7dda678 ***

Or just:

[Segmentation fault (core dumped)

Note the opening "[" at the beginning of the line in both cases. If you don't have this, you're not being bitten by this bug.

This is a bug caused by incorrect packaging of Mesa. It appears, among others, in all versions of Ubuntu up to and including 10.10. It is fixed in 11.04.

Workaround

Make sure libstdc++ is loaded before the OpenGL driver:

1export LD_PRELOAD=<path-to-libstdc++>

You need to replace <path-to-libstdc++> with the actual path on your machine. Something like /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libstdc++.so.6.

The Details

This is the corresponding Ubuntu bug report:

1https://bugs.launchpad.net/ubuntu/+source/mesa/+bug/259219

OpenGL Support

Most libavg development is done using NVidia cards, so these should work. The quality of ATI and Intel OpenGL support has improved in the last years, and these mostly work (with a few issues) as well. With Intel chips, make sure you have the newest kernel - we've seen test failures disappear in the transition from Ubuntu 9.10 to 10.04, for instance.

For NVidia, you need to install the proprietary OpenGL drivers. Under Ubuntu, you can install these by clicking over the green card icon at the top of the screen just after the first logon.

To test if OpenGL is working, check the output of glxinfo. It needs to say

Direct Rendering: yes

Audio

Crackling or otherwise broken audio on Linux can come from a number of sources. Here are a few pointers for getting things to work:

  • Try disabling any soundservers like JACK, aRTs or ESD.
  • Change the audio buffer size in avgrc to a large number like 8192 to see if this fixes things. If it does, you can successively reduce the buffer size in powers of two until the interference happens again. If you need an unreasonably large buffer size, then some component in your system - possibly a driver - is hogging the CPU for extended amounts of time and preventing libavg from updating the sounds quickly enough.
  • Change the sampling rate in avgrc to the native rate of your sound card (44100 or 48000). If you don't know the native sampling rate, just try both. There are libSDL versions that have a bug ( http://bugzilla.libsdl.org/show_bug.cgi?id=649) in the sampling rate conversion, and you may be running into this bug.

Ubuntu Version-Specific Issues

11.10 to 10.04

No version-specific issues.

9.10 boost.python Bug

The version of boost.python in Ubuntu 9.10 is buggy - see https://bugs.launchpad.net/ubuntu/+source/boost1.38/+bug/457688. The symptom is that all libavg programs crash with an exception:

AttributeError: 'Boost.Python.StaticProperty' object attribute '__doc__' is read-only

A fixed package is available by adding

ppa:ajmitch/ppa

to the software sources. Also, configure needs to be called like this

1$ BOOST_PYTHON_LIBS=-lboost_python-mt ./configure

so the boost.python library is found.

9.10 libsdl Audio Problem

Ubuntu 9.10's version of libsdl uses Alsa by default. This causes libavg to use 100% CPU and hang on end of playback when the player is running on some machines.

If this happens to you, install the libsdl1.2debian-pulseaudio package to switch libsdl to using PulseAudio.

9.04 Firewire Video

The raw1394 device must be properly configured to let video-group users to access it in rw mode. In addition, there is a bug in the udev 141-1.1 configuration files (see https://bugs.launchpad.net/ubuntu/+bug/369817).

The following additions to /etc/udev/rules.d are a workaround:

50-raw1394.rules:

1KERNEL=="raw1394*", GROUP="video" 

50-video1394.rules:

1KERNEL=="dv1394-[0-9]*", GROUP="video" 
2KERNEL=="video1394-[0-9]*", NAME="video1394", GROUP="video" 

Make sure the user that wants to use the camera is in the video group:

1$ sudo adduser <username> video