Although I understand that autoconf is designed for the portability and expecting a dictionary of compiler-specific options in there is out of the scope, I'm interested in the appropriate place to collect such. Recently there are several softwares that requires C99, C++0x, POSIX200x features unexpectedly, because most GNU/Linux (and most BSD variants?) enables such modern features by default. On the platforms where the modern features are enabled optionally, sometimes I have to check the availability with -std=xxx flags or -D_XOPEN_SOURCE=xxx. If there is a right place to put reusable macros for such, I'm interested in. Regards, mpsuzuki John X wrote: > On Sun, May 6, 2012 at 2:58 AM, Paul Eggert <eggert@xxxxxxxxxxx> wrote: >> On 05/05/2012 02:49 PM, John X wrote: >>> How should I set up Autoconf in order to make the compiler enforce >>> that? >> >> Autoconf is about making programs more portable. >> In contrast, requiring each builder to use -pedantic would >> make programs less likely to compile, i.e., it'd make them >> less portable. >> >> I'm not saying it can't be done, just that it's not really >> Autoconf's goal, which is why the topic doesn't come up much >> and why Autoconf doesn't have builtin support for this sort >> of thing. > > Thanks for the answer. > > It's not that I necessarily want -pedantic, just that it should pick > what is the most strict C99 that the compiler supports and in the case > of gcc it would probably be something like that. But I don't know > which options other compilers like for example clang or icc have in > order to accomplish the same thing, I assume that they may not be > exactly the same. > > So in order to keep the program portable I would would like the > compiler to generate warnings when various compiler-specific > extensions is used. > > - John > > _______________________________________________ > Autoconf mailing list > Autoconf@xxxxxxx > https://lists.gnu.org/mailman/listinfo/autoconf _______________________________________________ Autoconf mailing list Autoconf@xxxxxxx https://lists.gnu.org/mailman/listinfo/autoconf