Building now works with Qt5

I've "ported" the codebase to work with Qt5. Is this of any use to you?