The built-in `afplay` shell command works for mp3s and for the stock aiff sounds under /System/Library/Sounds.
I use this after my long-running Maven builds to play either a happy sound if the build succeeds or a sad (mocking) sound if it fails, based on the value of $?.