Had a wierd issue that caused a fresh build of XBMC to crash every time I played something.
To fix the issue I did the following :
1) Log into ubuntu
2) Open up a terminal session
3) run the command
aplay -L
4) The above should error with an error message
5) Type
sudo nano .asoundrc
6) change the first line from
pcm.default {
to
pcm.!default {
Save the file and exit. Reboot. Should now all work.