Allow deprecated declarations

These changes were needed in order for it to compile on Arch Linux. There may be better ways.