Lots of hacks later, it builds