Joseph Myers <[email protected]> writes: > On Tue, 9 Jun 2026, Sam James wrote: > >> diff --git a/gcc/configure.ac b/gcc/configure.ac >> index 4360cb955662..88628647c881 100644 >> --- a/gcc/configure.ac >> +++ b/gcc/configure.ac >> @@ -7545,7 +7545,9 @@ AC_SUBST(enable_host_shared) >> # Enable --enable-host-pie >> AC_ARG_ENABLE(host-pie, >> [AS_HELP_STRING([--enable-host-pie], >> - [build host code as PIE])]) >> + [build host code as PIE])], >> + [enable_host_pie=$enableval], >> + [enable_host_pie=no]) >> AC_SUBST(enable_host_pie) > > I'm not convinced this change, or other similar ones where the third > argument wasn't previously present, is either necessary or correct. > > [...] > > In general, in cases that do AC_SUBST(enable_host_pie) you need to look at > what use is made of the substituted value, not just at the code in > configure.ac.
Yes, sorry, I'd fixed one case and apparently went ham on some others. Thank you for the review, I'll fix it properly. > And if you want the code to be more consistent about having > a third argument to AC_ARG_ENABLE whether or not it's used, maybe there > should be a GCC_ENABLE_HOST_PIE or similar macro defined in config/ rather > than separately using AC_ARG_ENABLE in lots of configure scripts (though > that might run into needing to deal with the differences between how > AC_ARG_ENABLE is used for this option in each subdirectory). Likewise for > other related configure options. Yes, fair point, though I think I'd rather leave that instead as in light of your other comments, I don't think it's much required. sam
signature.asc
Description: PGP signature
