Compilation fixes

I had to make the following changes to get libphenom to build on ubuntu 12.04. These changes seem reasonable to me, but let me know if there's a better way to do this.