Eli Zaretskii wrote: > Which to me sounds like lib/limits.h is not a good place to define > these constants, or at least Emacs shouldn't rely on Gnulib's limits.h > to do its magic on all systems. The ISO technical spec says the settings should go into , and if we put them somewhere else that will just make things more confusing in the long run. I installed the attached patch, which should fix the immediate problem. The fundamental problem here is that Emacs over the years has bloated to contain many things that it should not. should always be included first -- this is a key assumption of Autoconf and Gnulib -- and should contain only stuff that can appear in an included-first file. It should therefore not contain things like "#include " that can cause trouble in the cases we're talking about. It's understandable why config.h has bloated, as it's a convenient catchall for stuff that has to be visible "everywhare" at the C level. The visibility-"everywhere" problem needs to be addressed in some other way, that's all. I'll look into fixing this.