Fix some warnings.
Fix compile error.
Fix editor linking with CMake.