This makes clang-format useful on those. Also add a bunch of forgotten transitive includes, which otherwise prevented compilation.
Closes #2049. Signed-off-by: MerryMage <MerryMage@users.noreply.github.com>