Run clang-tidy builds on clang
Run clang-tidy builds on clang

As-is, clang-tidy uses the default compile-commands.json from the gcc
build.  Unfortunately, gcc implements different flags than clang these
days, and clang-tidy requires the clang flags.  Because of that, we need
to use a clang-specific compile-commands.json.

This commit adds a new build dir named tidy-build, and runs the cmake
configure task in it against the clang compilers.

Note, the hope is that this change allows something like this:
https://gerrit.openbmc-project.xyz/c/openbmc/bmcweb/+/36888

To succeed in CI.

Having this build run correctly will help me as a maintainer.  I'm
guessing that clang-tidy will correctly flag 50% of the common mistakes
people make in bmcweb.  I intend to get this running on entity-manager
and dbus-sensors repos as well.

Tested:
Ran ./openbmc-build-scripts/run-unit-test-docker.sh against this
patchset: https://gerrit.openbmc-project.xyz/c/openbmc/bmcweb/+/36888

... and observed clang-tidy run correctly.  clang-tidy did not pass
because of actual found issues (most of which are in review to be
fixed), but correctly ran clang-tidy, and identified a bunch of issues,
which is glorious.

Signed-off-by: Ed Tanous <a162caffcb6897220f4d1cf28164d73cb91993a8@tanous.net>
Change-Id: I0f0754f2026e1cf2ae9ca7df868f9022d6585c32

openbmc/openbmc-build-scripts,openbmc/openbmc-build-scripts