Move warning flags to top-level cmakelist.txt
Move most of typedefs to main.cpp, define couple of useful template aliases, wipe out some unnecessary code