Fix warnings, use Makefiles