GCC on Windows ignores this flag completely [0] which some build systems sadly rely on when compiling for Windows using MinGW. The current behaviour of clang however is to error out as -fPIC & friends has no effect on Windows.
This patch instead changes the behaviour for MinGW to ignore the option for the sake of compatibility
Fixes https://github.com/llvm/llvm-project/issues/52947
[0] https://gcc.gnu.org/legacy-ml/gcc-patches/2015-08/msg00836.html