XBMC supports Airplay out of the box, but I don’t really want to run an entire media server just for one feature. Plus, I need the service to run in the background so I can do _work_.
I found a great tool called ShairPort that accomplishes what I need. It is easy enough to get started. On your Ubuntu machine you should install the following dependencies:
sudo apt-get install libssl-dev libavahi-client-dev libasound2-dev build-essential
Now install shairport. You will need git installed if you do not already have it for some reason.
git clone https://github.com/abrasive/shairport.git
At this point you should be able to run the app.
./shairport -a "My ShairPort"
To see a list of available parameters, run ./shairport -h.
You should see it show up on your Mac now. Go to System Preferences > Sound > Output. I named mine “roy-ubuntu ShAIRport”
I recommend moving the shairport directory someplace, like
Create a symlink to the app:
sudo ln -s /opt/shairport/shairport /usr/local/bin/shairport
That’s it! So far it’s working out pretty well. The defaults for shairport have been fine for me.