Before we can use the system C compiler, we have to force c++17 usage
for cxx builds. cxx's flag_if_supported does not get correctly passed
to the C compiler invocation. This is also needed because clang defaults to
C++03 unless otherwise specified.
Nix's clang compiler wasn't affected by this, as it would default to GCC12
behavior of using a more recent version.