build system: add optional cppcheck.
  Currently just checks the default platform.