Fixed all clang/gcc warnings and added -Werror