CMake build support

It's not quite as optimal as just using a script file (slower and may
create larger files), but distributions and platform diversity approve.

Signed-off-by: GreatEmerald <pastas4@gmail.com>