This is exactly what was done already in gcc-11 and trunk by
89e95ad2e7679322b2f5ee9070ff2721d5ca1d6d but it would be great to apply
also to gcc-10. It is needed for the driver (compiled by C++) to find
cc1, cc1plus, etc. More details in
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101238
commit 89e95ad2e7679322b2f5ee9070ff2721d5ca1d6d
Author: Martin Storsjö <mar...@martin.st>
Date: Fri Apr 9 14:46:36 2021 +0300
mh-mingw: Set __USE_MINGW_ACCESS in missed C++ flags variables
This is similar to what was done in
eea4e2ff0a3f5e7f37df204c070cc5d9ef339e6e (where it was added to
STAGE*_CXXFLAGS), but this adds the flag to the CXXFLAGS and
BOOT_CXXFLAGS variables too (as it's already added to CFLAGS and
BOOT_CFLAGS).
2021-04-09 Martin Storsjö <mar...@martin.st>
config/ChangeLog:
* mh-mingw: Set __USE_MINGW_ACCESS in missed C++ flags
variables
Thanks
Tomas
diff -Nru gcc-10.2.0-orig/config/mh-mingw gcc-10.2.0-patched/config/mh-mingw
--- gcc-10.2.0-orig/config/mh-mingw 2020-07-23 02:35:16.916379838 -0400
+++ gcc-10.2.0-patched/config/mh-mingw 2021-07-04 03:36:49.987025066 -0400
@@ -1,7 +1,9 @@
# Add -D__USE_MINGW_ACCESS to enable the built compiler to work on Windows
# Vista (see PR33281 for details).
BOOT_CFLAGS += -D__USE_MINGW_ACCESS -Wno-pedantic-ms-format
+BOOT_CXXFLAGS += -D__USE_MINGW_ACCESS -Wno-pedantic-ms-format
CFLAGS += -D__USE_MINGW_ACCESS
+CXXFLAGS += -D__USE_MINGW_ACCESS
STAGE1_CXXFLAGS += -D__USE_MINGW_ACCESS
STAGE2_CXXFLAGS += -D__USE_MINGW_ACCESS
STAGE3_CXXFLAGS += -D__USE_MINGW_ACCESS