Please stop overthinking this. Follow the documentation.
If you’ve got WSL2 and an Ubuntu distro already, follow these steps.
Pay particular attention to this install script, available once you’ve cloned the repository:
I suppose you could get away with not installing the STM32 toolchain, but there is no harm (other than a few MB of virtual machine bloat) in just saying yes to everything and letting the script do its job.
Your specific question is answered via a glance at the configuration script - it sets the build environment correctly by setting
toolchain = 'arm-linux-gnueabihf'.
You are overcomplicating this in a big way.
Also, if you’ve already built a binary, uploaded it, and connected to QGC, then your toolchain is set up correctly. You more likely have an onboard configuration problem that should be solved via setting parameters in QGC rather than reloading or rebuilding the firmware.