try_compile: Record propagated CMake variables in configure log

These provide more detailed information about how the test project was
configured.

Issue: #23200
9 files changed