Fix CMake
Reformat code.
Add CLion project.