On 1/18/20 5:46 AM, Bruno Haible wrote: > This code in Emacs configure.ac: > > # Use the system putenv even if it lacks GNU features, as we don't need them, > # and the gnulib replacement runs afoul of a FreeBSD 10.1 bug; see Bug#19874. > AC_CHECK_FUNCS_ONCE([putenv]) > AC_DEFUN([gl_FUNC_PUTENV], > [test "$ac_cv_func_putenv" = yes || REPLACE_PUTENV=1]) > > appears to be extra convoluted. All platforms have the putenv function. > Therefore REPLACE_PUTENV=1 is never executed here. If Emacs does not need > the putenv override, the simpler way is to invoke gnulib-tool with > '--avoid=putenv'. Thanks for suggesting that. I installed the attached patch to Emacs master to implement something along the lines you suggested. I am cc'ing Ashish Shukla who reported Bug#19874 ("25.0.50; encode-time not working as expected"), as well as Wolfgang Jenkner who helped debug that, to give them a heads-up that the fix for Bug#19874 has changed.