makensis: use correct compiler, force libstdc++

makensis only builds with libstdc++. This isn't a huge deal in itself
as it's just a binary, not a library, and has no deps in Homebrew.
More of a problem is the fact that it provides zero mechanism to
govern compiler choice, forcing us to patch the SCons/config.py in
order to make sure the right compiler gets used.

Fixes #23913.
Closes #24545.