C and CXX Compiler Unknown

My general MO for setting up a new machine is to install git for windows, visual studio, python for windows, and then Cmake. Following this sequence I’ve never had a problem to get my build chain using CMake to work without issue. I’m setting up a VM for build purposes and I unintentionally installed CMake before visual studio. It, of course, couldn’t find the compilers so I promptly installed the compilers and it still didn’t work. I uninstalled everything and this time installed Visual Studio first followed by CMake 3.27.7. Oh! I’ve already confirmed that I can build and compile a C++ project with Visual Studio (ran into that problem on previous occasions and confirmed that first). I used the —trace-expand and it turns out that for some reason I need to run my command line environment (Git Bash) as an administrator for it to work. Any ideas why this is happening? Again, I’ve never had this problem before. I’ll dump the first relevant error from --trace-expand here in reply. Thanks.

Here is relevant output from --trace-expand

C:/Program Files/CMake/share/cmake-3.27/Modules/CMakeDetermineCompilerId.cmake(538): if(CMAKE_VS_MSBUILD_COMMAND AND NOT lang STREQUAL Fortran )
C:/Program Files/CMake/share/cmake-3.27/Modules/CMakeDetermineCompilerId.cmake(539): set(command C:/Program Files (x86)/Microsoft Visual Studio/2019/Professional/MSBuild/Current/Bin/MSBuild.exe CompilerIdC.vcxproj /p:Configuration=Debug /p:Platform=x64 /p:VisualStudioVersion=16.0 )
C:/Program Files/CMake/share/cmake-3.27/Modules/CMakeDetermineCompilerId.cmake(547): if(command )
C:/Program Files/CMake/share/cmake-3.27/Modules/CMakeDetermineCompilerId.cmake(548): execute_process(COMMAND C:/Program Files (x86)/Microsoft Visual Studio/2019/Professional/MSBuild/Current/Bin/MSBuild.exe;CompilerIdC.vcxproj;/p:Configuration=Debug;/p:Platform=x64;/p:VisualStudioVersion=16.0 WORKING_DIRECTORY C:/Users/alamgrito/Documents/repos/libLaTeXUtility/build/CMakeFiles/3.27.7/CompilerIdC OUTPUT_VARIABLE CMAKE_C_COMPILER_ID_OUTPUT ERROR_VARIABLE CMAKE_C_COMPILER_ID_OUTPUT RESULT_VARIABLE CMAKE_C_COMPILER_ID_RESULT )
C:/Program Files/CMake/share/cmake-3.27/Modules/CMakeDetermineCompilerId.cmake(560): if(Microsoft (R) Build Engine version 16.11.2+f32259642 for .NET Framework
Copyright (C) Microsoft Corporation. All rights reserved.

Build started 11/8/2023 6:07:58 AM.
Project “C:\Users\alamogrito\Documents\repos\libLaTeXUtility\build\CMakeFiles\3.27.7\CompilerIdC\CompilerIdC.vcxproj” on node 1 (default targets).
PrepareForBuild:
Creating directory “Debug".
Creating directory “Debug\CompilerIdC.tlog".
InitializeBuildStatus:
Creating “Debug\CompilerIdC.tlog\unsuccessfulbuild” because “AlwaysCreate” was specified.
ClCompile:
C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\VC\Tools\MSVC\14.29.30133\bin\HostX64\x64\CL.exe /c /nologo /W0 /WX- /diagnostics:column /Od /D _MBCS /Gm- /EHsc /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo"Debug\” /Fd"Debug\vc142.pdb” /external:W0 /Gd /TC /FC /errorReport:queue CMakeCCompilerId.c
TRACKER : error TRK0002: Failed to execute command: ““C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\VC\Tools\MSVC\14.29.30133\bin\HostX64\x64\CL.exe” @C:\Users\alamogrito\AppData\Local\Temp\3\tmp75b40ac18dff457191ff7610d7483791.rsp”. The requested operation requires elevation. [C:\Users\alamogrito\Documents\repos\libLaTeXUtility\build\CMakeFiles\3.27.7\CompilerIdC\CompilerIdC.vcxproj]
Done Building Project “C:\Users\alamogrito\Documents\repos\libLaTeXUtility\build\CMakeFiles\3.27.7\CompilerIdC\CompilerIdC.vcxproj” (default targets) – FAILED.

Build FAILED.

I’m not sure what requires higher privileges; maybe Git Bash did some security work and dropped privileges in a new version? Without knowing the operation in question, it’s hard to say what might be the root cause here.