1. 12 Nov, 2017 1 commit
    • Paul Eggert's avatar
      Merge from Gnulib · 7775c472
      Paul Eggert authored
      This incorporates:
      2017-11-11 faccessat: port to macOS (Bug#29231)
      2017-11-05 fstatat: pacify GCC on unusual platform
      * build-aux/config.guess, build-aux/config.sub:
      * doc/misc/texinfo.tex, lib/faccessat.c, lib/fstatat.c:
      * lib/unistd.in.h, m4/faccessat.m4, m4/unistd_h.m4:
      Copy from Gnulib.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      7775c472
  2. 30 Sep, 2017 1 commit
    • Paul Eggert's avatar
      Merge from gnulib · 3ab2f9bb
      Paul Eggert authored
      This incorporates:
      2017-09-28 string: code style
      2017-09-25 sys_types: update URL
      2017-09-23 install-sh: do not assume / = //
      2017-09-21 mktime: port to OpenVMS
      * build-aux/install-sh, m4/mktime.m4, m4/string_h.m4:
      * m4/sys_types_h.m4: Copy from Gnulib.
      * lib/gnulib.mk.in: Regenerate.
      3ab2f9bb
  3. 17 Sep, 2017 1 commit
    • Paul Eggert's avatar
      Merge from Gnulib · 6bbbc38b
      Paul Eggert authored
      This incorporates:
      2017-09-16 manywarnings: port to GCC on 64-bit MS-Windows
      2017-09-13 all: Replace many more http URLs by https URLs
      * build-aux/config.guess, build-aux/config.sub:
      * build-aux/gitlog-to-changelog, doc/misc/texinfo.tex:
      * lib/allocator.h, lib/count-leading-zeros.h:
      * lib/count-trailing-zeros.h, lib/dup2.c, lib/filevercmp.c:
      * lib/fstatat.c, lib/fsync.c, lib/ftoastr.c, lib/ftoastr.h:
      * lib/intprops.h, lib/signal.in.h, lib/stdio-impl.h, lib/stdio.in.h:
      * lib/unistd.in.h, lib/utimens.c, m4/alloca.m4, m4/extern-inline.m4:
      * m4/fstatat.m4, m4/gnulib-common.m4, m4/manywarnings.m4:
      * m4/std-gnu11.m4, m4/sys_types_h.m4, m4/vararrays.m4:
      Copy from Gnulib.
      * lib/gnulib.mk.in: Regenerate.
      6bbbc38b
  4. 13 Sep, 2017 1 commit
    • Paul Eggert's avatar
      Merge from Gnulib · a0202fdc
      Paul Eggert authored
      This incorporates:
      2017-09-13 all: prefer https: URLs
      This just changes http: to https: in comments,
      in files copied from Gnulib.
      a0202fdc
  5. 10 Sep, 2017 1 commit
    • Paul Eggert's avatar
      Merge from gnulib · b079ee72
      Paul Eggert authored
      This incorporates:
      2017-09-08 stddef: Avoid conflict with system-defined max_align_t
      2017-08-24 warnings: fix compilation with old autoconf
      2017-08-23 glob: merge from glibc with Zanella glob changes
      2017-08-17 random: Fix test compilation failure on Cygwin 1.5.25
      * doc/misc/texinfo.tex, lib/flexmember.h, lib/stddef.in.h:
      * lib/stdlib.in.h, m4/manywarnings.m4, m4/stdlib_h.m4:
      * m4/warnings.m4:
      Copy from Gnulib.
      * lib/gnulib.mk.in: Regenerate.
      b079ee72
  6. 16 Aug, 2017 1 commit
    • Paul Eggert's avatar
      Merge from Gnulib; use ‘open’ for O_CLOEXEC · 794c3cd3
      Paul Eggert authored
      This incorporates:
      2017-08-15 renameat: ensure declaration in <stdio.h> on NetBSD
      2017-08-15 extensions: enable NetBSD specific extensions
      2017-08-14 open: support O_CLOEXEC
      2017-08-13 reallocarray: new module
      * admin/merge-gnulib (AVOIDED_MODULES): Remove ‘open’, since
      it now supports O_CLOEXEC and this simplifies Emacs.
      * build-aux/config.guess, lib/fcntl.in.h, lib/stdio.in.h:
      * lib/stdlib.in.h, m4/extensions.m4, m4/stdlib_h.m4:
      Copy from Gnulib.
      * lib/cloexec.c, lib/cloexec.h, lib/open.c:
      * m4/mode_t.m4, m4/open-cloexec.m4, m4/open.m4:
      New files, copied from Gnulib.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      * lib-src/etags.c (O_CLOEXEC) [WINDOWSNT]:
      Remove, as Gnulib does this for us.
      * src/filelock.c (create_lock_file):
      * src/sysdep.c (emacs_open, emacs_pipe):
      Don’t worry about O_CLOEXEC == 0, as Gnulib no longer sets it to 0.
      794c3cd3
  7. 12 Aug, 2017 1 commit
    • Paul Eggert's avatar
      Improve make-temp-file performance on local files · a6ad98ad
      Paul Eggert authored
      For the motivation behind this patch, please see Bug#28023 and:
      http://emacshorrors.com/posts/make-temp-name.html
      Although, given the recent changes to Tramp, the related security
      problem in make-temp-file is already fixed, make-temp-file still has
      several unnecessary system calls.  In the typical case on GNU/Linux,
      this patch replaces 8 syscalls (symlink, open, close, readlinkat, uname,
      getpid, unlink, umask) by 2 (open, close).
      * admin/merge-gnulib (GNULIB_MODULES): Add tempname, now
      that Emacs is using it directly.
      * configure.ac (AUTO_DEPEND): Remove AC_SYS_LONG_FILE_NAMES;
      no longer needed.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      * lisp/files.el (files--make-magic-temp-file): Rename from
      make-temp-file.
      (make-temp-file): Use make-temp-file-internal for
      non-magic file names.
      * src/fileio.c: Include tempname.h.
      (make_temp_name_tbl, make_temp_name_count)
      (make_temp_name_count_initialized_p, make_temp_name): Remove.
      (Fmake_temp_file_internal): New function.
      (Fmake_temp_name): Use it.
      * src/filelock.c (get_boot_time): Use Fmake_temp_file_internal
      instead of make_temp_name.
      a6ad98ad
  8. 09 Aug, 2017 1 commit
    • Paul Eggert's avatar
      Merge from gnulib · 904be8c4
      Paul Eggert authored
      This incorporates:
      2017-08-09 tempname: do not depend on secure_getenv
      2017-08-08 extensions: add _OPENBSD_SOURCE
      2017-08-06 manywarnings: Add support for C++
      2017-08-06 warnings, manywarnings: Add support for multiple languages
      * admin/merge-gnulib: Don't use m4/manywarnings-c++.m4.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      * lib/secure_getenv.c, m4/secure_getenv.m4: Remove.
      * lib/tempname.c, m4/extensions.m4, m4/manywarnings.m4, m4/warnings.m4:
      Copy from gnulib.
      904be8c4
  9. 05 Aug, 2017 1 commit
    • Paul Eggert's avatar
      Merge from gnulib · b8748dd0
      Paul Eggert authored
      This incorporates:
      2017-08-04 manywarnings: port to 64-bit GCC builds of Emacs
      2017-08-01 manywarnings: port to 32-bit GCC bug
      * lib/gnulib.mk.in: Regenerate.
      * m4/manywarnings.m4: Copy from gnulib.
      b8748dd0
  10. 31 Jul, 2017 1 commit
    • Paul Eggert's avatar
      Avoid most stat calls when completing file names · 3a8d0cc8
      Paul Eggert authored
      * admin/merge-gnulib (GNULIB_MODULES): Add d-type.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      * m4/d-type.m4: New file, copied from gnulib.
      * src/dired.c (DT_UNKNOWN, DT_DIR, DT_LINK)
      [!HAVE_STRUCT_DIRENT_D_TYPE]: New constants.
      (dirent_type): New function.
      (file_name_completion): Use it, to avoid unnecessary calls to
      stat-like functions on GNU/Linux and other platforms with d_type.
      (file_name_completion_stat): Just follow the link; there is no
      need to try first with AT_SYMLINK_NOFOLLOW since the directory
      entry was already checked to exist.
      3a8d0cc8
  11. 24 Jul, 2017 1 commit
    • Paul Eggert's avatar
      Merge from gnulib · 9b971bdd
      Paul Eggert authored
      This incorporates:
      2017-07-23 Rename module 'strftime' to 'nstrftime'
      * admin/merge-gnulib (GNULIB_MODULES): Add nstrftime, remove strftime.
      * build-aux/config.guess: Copy from gnulib.
      * lib/nstrftime.c: Rename from lib/strftime.c.
      * m4/nstrftime.m4: Rename from m4/strftime.m4.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      9b971bdd
  12. 16 Jul, 2017 2 commits
    • Paul Eggert's avatar
      Use explicit_bzero to clear GnuTLS keys · 59f69721
      Paul Eggert authored
      * admin/merge-gnulib (GNULIB_MODULES): Add explicit_bzero.
      * lib/explicit_bzero.c, m4/explicit_bzero.m4: New files.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      * src/gnutls.c (clear_storage): New function.
      (gnutls_symmetric_aead): Use it instead of memset.
      59f69721
    • Paul Eggert's avatar
      Merge from gnulib · 252444aa
      Paul Eggert authored
      This incorporates:
      2017-07-16 explicit_bzero: new module
      2017-07-15 getdtablesize: Add minimal support for OpenVMS.
      * lib/getdtablesize.c, lib/string.in.h, m4/getdtablesize.m4:
      * m4/string_h.m4:
      Copy from Gnulib.
      * lib/gnulib.mk.in: Regenerate.
      252444aa
  13. 22 Jun, 2017 1 commit
    • Paul Eggert's avatar
      Use unlocked stdio more systematically · f6ef15cf
      Paul Eggert authored
      This can improve performance significantly on stdio-bottlenecked code.
      E.g., make-docfile is 3x faster on my Fedora 25 x86-64 desktop.
      * admin/merge-gnulib (GNULIB_MODULES): Add unlocked-io.
      * lib-src/ebrowse.c, lib-src/emacsclient.c, lib-src/etags.c:
      * lib-src/hexl.c, lib-src/make-docfile.c, lib-src/movemail.c:
      * lib-src/profile.c, lib-src/update-game-score.c:
      Include unlocked-io.h instead of stdio.h, since these programs are
      single-threaded.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      * lib/unlocked-io.h, m4/unlocked-io.m4: New files, copied from Gnulib.
      * src/charset.c, src/cm.c, src/emacs.c, src/image.c, src/keyboard.c:
      * src/lread.c, src/term.c:
      Include sysstdio.h, possibly instead of stdio.h, to define
      the unlocked functions if the system does not provide them.
      * src/charset.c, src/lread.c (getc_unlocked):
      Remove, since sysstdio.h now defines it if needed.
      * src/cm.c (cmputc, cmcheckmagic):
      * src/dispnew.c (update_frame, update_frame_with_menu)
      (update_frame_1, Fsend_string_to_terminal, Fding, bitch_at_user):
      * src/emacs.c (main, Fdump_emacs):
      * src/fileio.c (Fdo_auto_save, Fset_binary_mode):
      * src/image.c (slurp_file, png_read_from_file, png_load_body)
      (our_stdio_fill_input_buffer):
      * src/keyboard.c (record_char, kbd_buffer_get_event, handle_interrupt):
      * src/lread.c (readbyte_from_file):
      * src/minibuf.c (read_minibuf_noninteractive):
      * src/print.c (printchar_to_stream, strout)
      (Fredirect_debugging_output):
      * src/sysdep.c (reset_sys_modes, procfs_ttyname)
      (procfs_get_total_memory):
      * src/term.c (tty_ring_bell, tty_send_additional_strings)
      (tty_set_terminal_modes, tty_reset_terminal_modes)
      (tty_update_end, tty_clear_end_of_line, tty_write_glyphs)
      (tty_write_glyphs_with_face, tty_insert_glyphs)
      (tty_menu_activate):
      * src/xfaces.c (Fx_load_color_file):
      Use unlocked stdio when it should be safe.
      * src/sysstdio.h (clearerr_unlocked, feof_unlocked, ferror_unlocked)
      (fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked)
      (fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked)
      (putc_unlocked, putchar_unloced): Provide substitutes if not declared.
      f6ef15cf
  14. 17 Jun, 2017 1 commit
    • Philipp Stephani's avatar
      Add command to replace buffer contents · d682f0da
      Philipp Stephani authored
      Add a new command 'replace-buffer-contents' that uses the Myers diff
      algorithm to non-destructively replace the accessible portion of the
      current buffer.  The Myers algorithm is implemented in Gnulib.
      
      * src/editfns.c (Freplace_buffer_contents): New command.
      (set_bit, bit_is_set, buffer_chars_equal): New helper functions.
      (syms_of_editfns): Define new command.
      
      * test/src/editfns-tests.el (replace-buffer-contents-1)
      (replace-buffer-contents-2): New unit tests.
      
      * src/buffer.h (BUF_FETCH_CHAR_AS_MULTIBYTE): New helper macro.
      
      * admin/merge-gnulib (GNULIB_MODULES): Add diffseq.h and minmax.h.
      d682f0da
  15. 01 Jun, 2017 1 commit
    • Paul Eggert's avatar
      Improve performance by avoiding strtoumax · 178d0cb5
      Paul Eggert authored
      This made (string-to-number "10") 20% faster on my old desktop,
      an AMD Phenom II X4 910e running Fedora 25 x86-64.
      * admin/merge-gnulib (GNULIB_MODULES): Remove strtoumax.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      * lib/strtoul.c, lib/strtoull.c, lib/strtoumax.c, m4/strtoull.m4:
      * m4/strtoumax.m4: Remove.
      * src/editfns.c (str2num): New function.
      (styled_format): Use it instead of strtoumax.  Use ptrdiff_t
      instead of uintmax_t.  Check for integer overflow.
      * src/lread.c (LEAD_INT, DOT_CHAR, TRAIL_INT, E_EXP):
      Move to private scope and make them enums.
      (string_to_number): Compute integer value directly during
      first pass instead of revisiting it with strtoumax later.
      178d0cb5
  16. 30 May, 2017 1 commit
    • Paul Eggert's avatar
      Merge from gnulib · ebcc70ab
      Paul Eggert authored
      * build-aux/config.guess: Copy from gnulib.
      * lib/gnulib.mk.in: Regenerate.
      ebcc70ab
  17. 14 May, 2017 2 commits
    • Paul Eggert's avatar
      Merge from gnulib · 10037e4b
      Paul Eggert authored
      This incorporates:
      2017-05-14 same-inode: Adapt for windows-stat-inodes
      2017-05-14 windows-stat-inodes: New module
      2017-05-14 stat-time: Adapt for windows-stat-timespec
      * lib/gnulib.mk.in: Regenerate.
      * lib/stat-time.h, lib/sys_types.in.h, m4/sys_types_h.m4:
      Copy from gnulib.
      10037e4b
    • Paul Eggert's avatar
      Merge from gnulib · 4132bd74
      Paul Eggert authored
      This incorporates:
      2017-05-13 largefile: Simplify
      2017-05-13 largefile: Improve and document
      2017-05-13 truncate: New module
      2017-05-13 windows-stat-timespec: New module
      2017-05-13 windows-stat-override: New module
      2017-05-11 getopt-posix: port to mingw
      2017-05-11 gettimeofday: Increase precision on mingw
      2017-05-10 time: Fix missing initialization of HAVE_TIMEZONE_T
      2017-05-10 Implement a way to opt out from MSVC support
      2017-05-09 tzset: Expand comment about TZ problem on native Windows
      * build-aux/config.guess, lib/dup2.c, lib/fcntl.c, lib/fsync.c:
      * lib/getdtablesize.c, lib/getopt.c, lib/gettimeofday.c:
      * lib/mktime.c, lib/stat-time.h, lib/sys_stat.in.h, lib/unistd.in.h:
      * lib/utimens.c, m4/gettimeofday.m4, m4/largefile.m4:
      * m4/sys_stat_h.m4, m4/sys_time_h.m4, m4/time_h.m4, m4/time_rz.m4:
      * m4/unistd_h.m4: Copy from gnulib.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      4132bd74
  18. 01 May, 2017 1 commit
    • Paul Eggert's avatar
      Merge from gnulib · 634d0a90
      Paul Eggert authored
      This incorporates:
      2017-05-01 New module 'localtime-buffer'
      2017-04-30 utimens: Add support for native Windows
      * admin/merge-gnulib (AVOIDED_MODULES): Add tzset.
      * configure.ac (tzset): No need for Emacs itself to check now.
      * lib/gettimeofday.c, lib/time.in.h, lib/time_rz.c, lib/utimens.c:
      * m4/gettimeofday.m4, m4/time_h.m4, m4/time_rz.m4: Copy from gnulib.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      * lib/localtime-buffer.c, lib/localtime-buffer.h:
      * m4/localtime-buffer.m4: New files, copied from gnulib.
      * src/editfns.c (init_editfns): Assume tzset is callable.
      634d0a90
  19. 30 Apr, 2017 3 commits
    • Paul Eggert's avatar
      Merge from gnulib · b6aa3446
      Paul Eggert authored
      This incorporates:
      2017-04-30 strftime-fixes: New module
      2017-04-30 mktime: Work around TZ problem on native Windows
      2017-04-30 ctime, localtime: New modules
      2017-04-30 gettimeofday: Provide higher resolution on native Windows
      2017-04-29 utime-h: Modernize handling of 'struct utimbuf'
      2017-04-29 Make use of module 'utime-h'
      2017-04-30 Fix a few typos
      * admin/merge-gnulib (AVOIDED_MODULES): Avoid utime-h, too.
      * lib/gettimeofday.c, lib/mktime.c, lib/time.in.h, lib/utimens.c:
      * m4/gettimeofday.m4, m4/include_next.m4, m4/mktime.m4:
      * m4/strftime.m4, m4/time_h.m4, m4/timegm.m4, m4/utimens.m4:
      Copy from gnulib.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      b6aa3446
    • Paul Eggert's avatar
      Merge from gnulib · 7e4dae99
      Paul Eggert authored
      This avoids incorporating the following, which I suspect are
      more trouble for Emacs than they’re worth:
      2017-04-29 stat, fstat: fix time_t etc. on native Windows platforms
      * admin/merge-gnulib (AVOIDED_MODULES): Avoid stat, too.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      * lib/pathmax.h, lib/stat.c, m4/pathmax.m4, m4/stat.m4: Remove.
      7e4dae99
    • Paul Eggert's avatar
      Merge from gnulib · 7cc329fd
      Paul Eggert authored
      This incorporates:
      2017-04-29 getopt: port to Solaris 10 with circa-1997 glibc getopt.h
      * lib/getopt-pfx-ext.h: Copy from gnulib.
      * lib/gnulib.mk.in: Regenerate.
      7cc329fd
  20. 09 Apr, 2017 1 commit
    • Paul Eggert's avatar
      Merge from gnulib (Bug#26398) · 43bc45ba
      Paul Eggert authored
      This incorporates:
      2017-04-08 getopt: prefer - to _ in new file names
      2017-04-08 getopt: port recent getopt changes to macOS
      * .gitignore: Add lib/getopt-cdefs.h.
      * lib/getopt-cdefs.in.h: Rename from lib/getopt_cdefs.in.h.
      * lib/getopt-core.h: Rename from lib/getopt_core.h.
      * lib/getopt-ext.h: Rename from lib/getopt_ext.h.
      * lib/getopt-pfx-core.h: Rename from lib/getopt_pfx_core.h.
      * lib/getopt-pfx-ext.h: Rename from lib/getopt_pfx_ext.h.
      * lib/getopt.in.h, lib/unistd.in.h, m4/getopt.m4:
      Copy from Gnulib.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      43bc45ba
  21. 06 Apr, 2017 1 commit
    • Paul Eggert's avatar
      Merge from gnulib · 02275595
      Paul Eggert authored
      This merges some getopt fixes from Zack Weinberg, and affects only
      non-GNUish platforms.  It incorporates:
      2017-04-06 getopt-gnu: omit some duplicate code
      2017-04-06 getopt-posix: use angle-bracket include
      2017-04-06 getopt: annotate files with relationship to glibc
      2017-04-06 getopt: split up getopt.in.h and eliminate __need_getopt
      2017-04-06 getopt: better handling of ambiguous options
      2017-04-06 getopt: refactor long-option handling
      2017-04-06 getopt: tidy up _getopt_initialize a bit
      2017-04-06 getopt: merge from glibc: repetition reduction
      2017-04-06 getopt: clean up error reporting
      2017-04-06 getopt: fix fencepost error in ambiguous-W-option handling
      2017-04-06 getopt: clean up getopt.c and getopt1.c file headers
      2017-04-06 getopt: harmonize comments with glibc
      2017-04-06 getopt: remove USE_NONOPTION_FLAGS
      2017-04-06 getopt: tabify, in preparation for merge with glibc
      2017-04-06 md5, sha1, sha256, sha512: Add comments re correctness
      * build-aux/config.sub, doc/misc/texinfo.tex, lib/getopt.c:
      * lib/getopt.in.h, lib/getopt1.c, lib/getopt_int.h, lib/md5.c:
      * lib/md5.h, lib/sha1.c, lib/sha1.h, lib/sha256.c, lib/sha256.h:
      * lib/sha512.c, lib/sha512.h, lib/unistd.in.h, m4/getopt.m4:
      Copy from gnulib.
      * lib/getopt_cdefs.in.h, lib/getopt_core.h, lib/getopt_ext.h:
      * lib/getopt_pfx_core.h, lib/getopt_pfx_ext.h:
      New files, taken from gnulib.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4:
      Regenerate.
      02275595
  22. 23 Mar, 2017 1 commit
    • Paul Eggert's avatar
      Merge from gnulib · e6d3eaa6
      Paul Eggert authored
      This incorporates:
      2017-03-22 getopt: merge from glibc
      * build-aux/config.sub, lib/getopt.c, lib/getopt.in.h:
      * lib/getopt1.c, lib/getopt_int.h: Copy from gnulib.
      * lib/gnulib.mk.in: Regenerate.
      e6d3eaa6
  23. 19 Mar, 2017 1 commit
    • Paul Eggert's avatar
      Merge from gnulib · fa90c5e8
      Paul Eggert authored
      This gets Emacs working again with HP-UX Itanium cc.
      It incorporates:
      2017-03-19 stdalign: tweak version# and test for HP-UX IA64
      2017-03-18 stdalign: restore previous behavior for HP-UX IA64
      2017-03-17 stat-time, timespec: Support header files in C++ mode
      2017-03-17 stdalign: Make it work with HP-UX cc
      2017-03-17 flexmember: try to detect HP-UX 11.31 cc bug
      2017-03-16 stdint: Fix test compilation failure with HP-UX 11 cc.
      2017-03-14 gnulib-tool: don't produce tests with only snippets
      2017-03-14 limits-h: Make it work with HP-UX cc.
      * etc/PROBLEMS: Remove now-obsolete entry for HP-UX 11.31.
      * lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
      * lib/limits.in.h, lib/stat-time.h, lib/stdalign.in.h:
      * lib/stdint.in.h, lib/timespec.h, m4/flexmember.m4, m4/stdalign.m4:
      Copy from gnulib.
      fa90c5e8
  24. 17 Mar, 2017 1 commit
    • Paul Eggert's avatar
      Switch from Automake to GNU Make · 65faa7bc
      Paul Eggert authored
      Emacs assumes GNU Make, and GNU Make has much of the functionality of
      Automake built-in.  The Emacs build process uses Automake primarily
      because Emacs uses some Gnulib code and Gnulib formerly required
      Automake.  Now that Gnulib no longer requires Automake, Emacs can
      stop using Automake and this should simplify Emacs maintenance
      in the future (Bug#26100).  Although this patch may look long, most of
      it is generated automatically: the changes to build-aux/config.guess,
      build-aux/config.sub, build-aux/install-sh, and lib/gnulib.mk.in are
      all done by admin/merge-gnulib.
      * .gitignore: Remove build-aux/ar-lib, build-aux/compile,
      build-aux/config.guess, build-aux/config.sub, build-aux/depcomp,
      build-aux/install-sh, build-aux/missing, and lib/Makefile.in,
      as they are no longer built by autogen.sh.
      Add lib/gnulib.mk, as it is now built by 'configure'.
      Remove nt/gnulib.mk, as it is no longer built by 'make'.
      * INSTALL.REPO, README, admin/make-tarball.txt:
      Remove mention of Automake.
      * Makefile.in (AUTOCONF, AUTOMAKE, AUTOHEADER, ACLOCAL, lib)
      (AUTOCONF_INPUTS, ACLOCAL_PATH, ACLOCAL_INPUTS)
      ($(srcdir)/aclocal.m4, AUTOMAKE_INPUTS)
      ($(srcdir)/lib/Makefile.in, $(srcdir)/nt/gnulib.mk, am--refresh):
      Remove.
      ($(MAKEFILE_NAME)): Depend on lib/gnulib.mk.in.
      ($(srcdir)/configure, $(srcdir)/src/stamp-h.in)
      ($(srcdir)/src/config.in):
      Use autogen.sh instead of doing it by hand.
      * admin/merge-gnulib (AVOIDED_MODULES, avoided_flags)):
      New vars, to simplify processing of avoided modules.
      (GNULIB_TOOL_FLAGS): Move --avoid flags into AVOIDED_MODULES.
      Add --gnu-make, and change makefile name to gnulib.mk.in.
      Copy config.guess, config.sub, and install-sh too, since
      Automake no longer does that for us.
      * admin/notes/copyright:
      * admin/update_autogen (genfiles):
      Update list of files.
      Remove hack for nt/gnulib.mk, a file that is no longer needed.
      * autogen.sh (progs): Remove Automake.
      (automake_min): Remove.
      Build aclocal.m4 so that autoreconf need not use aclocal.
      * build-aux/config.guess, build-aux/config.sub:
      * build-aux/install-sh:
      New files, copied from Gnulib.  These are now updated by
      admin/merge-gnulib instead by autogen.sh.
      * configure.ac (AC_PROG_MAKE_SET, ACLOCAL_PATH, AM_CONDITIONAL):
      Remove.
      (AM_INIT_AUTOMAKE, AM_SILENT_RULES): Remove call.
      (AC_PROG_CC_C_O): Call this instead of AM_PROG_CC_C_O.
      (BUILDING_FOR_WINDOWSNT, HYBRID_MALLOC_LIB): Remove; no longer needed.
      (--disable-silent-rules): New option, since Automake no longer
      does this for us.
      (AM_V, AM_DEFAULT_V): Set unconditionally, and do not bother
      with AM_SUBST_NOTMAKE.
      (AC_PROG_INSTALL): Add call.
      (MAKEINFO): Do not bother with the 'missing' program.
      (MAKEINFO, SYSTEM_TYPE): AC_SUBST.
      (AC_CONFIG_FILES): Add Makefile, lib/gnulib.mk.
      (SUBDIR_MAKEFILES): Remove duplication.
      * lib/Makefile.am: Remove, replacing with:
      * lib/Makefile.in: New file, with the old Makefile.am contents
      and with the following changes:
      (AUTOMAKE_OPTIONS, BUILT_SOURCES, CLEANFILES, EXTRA_DIST)
      (MOSTLYCLEANDIRS, MOSTLYCLEANFILES, noinst_LIBRARIES, SUFFIXES)
      (AM_CFLAGS, DEFAULT_INCLUDES, libegnu_a_SOURCES, libegnu_a_LIBADD)
      (EXTRA_libegnu_a_SOURCES, libegnu_a_SHORTNAME, libegnu_a_CPPFLAGS):
      Remove.
      (VPATH, abs_top_builddir, top_builddir, top_srcdir, all, AM_V_AR)
      (AM_V_CC, AM_V_GEN, AM_V_at, DEPDIR, DEPFLAGS, MKDEPDIR, SYSTEM_TYPE)
      (libgnu.a, libegnu.a, ETAGS, $(ETAGS), tags, TAGS, clean)
      (mostlyclean, distclean, bootstrap-clean, maintainer-clean):
      New macros and rules, since Automake no longer does them.
      Include ../nt/gnulib-cfg.mk if SYSTEM_TYPE is windows-nt,
      instead of including ../nt/gnulib.mk if BUILDING_FOR_WINDOWS_NT.
      Include dependency files if AUTO_DEPEND.
      (ALL_CFLAGS, AUTOCONF_INPUTS, libgnu_a_OBJECTS, libegnu_a_OBJECTS):
      New macros.
      (bootstrap-clean): Depend on distclean, not maintainer-clean,
      and remove gnulib.mk.
      (AUTOCONF_INPUTS, $(top_srcdir)/configure, ../config.status, Makefile):
      New macros and rules, copied from ../Makefile.in.
      ($(libegnu_a_OBJECTS), $(libgnu_a_OBJECTS)): Depend on BUILT_SOURCES.
      (.c.o, e-%.o): New generic rules.
      * lib/gnulib.mk: Remove.
      * lib/gnulib.mk.in: New file, which is built by autogen.sh
      and contains much of what used to be in lib/gnulib.mk.
      * m4/gnulib-common.m4: Copy from gnulib.
      * make-dist: Do not distribute build-aux/compile, build-aux/depcomp,
      build-aux/missing, build-aux/ar-lib, lib/Makefile.am, nt/gnulib.mk,
      nt/gnulib-modules-to-delete.cfg.  Distribute lib/Makefile.in,
      lib/gnulib.mk.in, and nt/gnulib-cfg.mk instead.
      * nt/Makefile.in (AM_V_GEN, am__v_GEN_, am__v_GEN_0)
      (am__v_GEN_1, ${srcdir}/gnulib.mk): Remove.
      * nt/gnulib-cfg.mk: New file, which supersedes ...
      * nt/gnulib-modules-to-delete.cfg: ... this file, which is removed.
      * src/Makefile.in (ACLOCAL_INPUTS): Remove.
      (AUTOCONF_INPUTS): Merge ACLOCAL_INPUTS into it.
      ($(top_srcdir)/configure, ../config.status, config.in Makefile):
      Defer to parent Makefile.
      65faa7bc
  25. 14 Mar, 2017 1 commit
    • Paul Eggert's avatar
      Merge from gnulib · fac0bb9c
      Paul Eggert authored
      This incorporates:
      2017-03-14 snippets: move unadjusted snippet sources to lib
      2017-03-14 gnulib-tool: fix typo in comment output
      2017-03-14 snippets: work around GNU Make 3.82 VPATH
      2017-03-13 gnulib-tool: minor --gnu-make fixups
      2017-03-12 gnulib-tool: new option --gnu-make
      * .gitignore: Remove lib/arg-nonnull.h, lib/c++defs.h,
      lib/warn-on-use.h.  Change exception from
      build-aux/snippet/_Noreturn.h to lib/_Noreturn.h.
      * admin/authors.el (authors-renamed-files-regexps):
      * admin/notes/copyright, make-dist:
      The snippet files moved from build-aux/snippet to lib.
      * lib/_Noreturn.h: Rename from build-aux/snippet/_Noreturn.h.
      * lib/arg-nonnull.h: Rename from build-aux/snippet/arg-nonnull.h.
      * lib/c++defs.h: Rename from build-aux/snippet/c++defs.h.
      * lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
      * lib/warn-on-use.h: Rename from build-aux/snippet/warn-on-use.h.
      fac0bb9c
  26. 12 Mar, 2017 1 commit
    • Paul Eggert's avatar
      Remove some stray gnulib files · 026c2cbf
      Paul Eggert authored
      * admin/merge-gnulib: rm m4/gnulib-tool.m4 too.
      (GNULIB_MODULES): Remove unsetenv, as it is not needed and
      the --avoid=unsetenv option avoided most of it anyway.
      * lib/unsetenv.c, m4/gnulib-tool.m4, m4/setenv.m4: Remove.
      * lib/gnulib.mk: Regenerate.
      026c2cbf
  27. 03 Mar, 2017 1 commit
    • Paul Eggert's avatar
      logb now works correctly on large integers · 74f87fd1
      Paul Eggert authored
      * admin/merge-gnulib (GNULIB_MODULES): Add count-leading-zeros.
      * etc/NEWS: Document the change.
      * lib/count-leading-zeros.c, lib/count-leading-zeros.h:
      * m4/count-leading-zeros.m4: New files, copied from Gnulib.
      * lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
      * src/floatfns.c: Include count-leading-zeros.h.
      (Flogb): Do not convert fixnum to float before taking the log,
      as the rounding error can cause the answer to be off by 1.
      * src/lisp.h (EMACS_UINT_WIDTH): New constant.
      * test/src/floatfns-tests.el (logb-extreme-fixnum): New test.
      74f87fd1
  28. 01 Jan, 2017 2 commits
    • Paul Eggert's avatar
      Merge from gnulib · 5a59e28d
      Paul Eggert authored
      This incorporates:
      2016-12-19 stdint: Fix WINT_MAX to match wint_t on mingw
      2016-12-18 getopt: Fix link error for users of getopt() in <unistd.h>
      2016-12-17 getlogin: Port to newer mingw
      2016-12-17 stdint: Fix WINT_MAX to match wint_t on MSVC
      2016-12-17 Avoid redefinition errors on MSVC
      * lib/getopt.in.h, lib/stdint.in.h, lib/stdio.in.h, lib/unistd.in.h:
      * m4/stdint.m4, m4/unistd_h.m4:
      Copy from gnulib.
      * lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
      Plus, this commit updates the indenting on copyright notices to
      match that of gnulib.
      5a59e28d
    • Paul Eggert's avatar
      Update copyright year to 2017 · 5badc81c
      Paul Eggert authored
      Run admin/update-copyright.
      5badc81c
  29. 15 Dec, 2016 1 commit
    • Paul Eggert's avatar
      Merge from gnulib · 5942af61
      Paul Eggert authored
      This incorporates:
      2016-12-14 xalloc-oversized: check for PTRDIFF_MAX too
      2016-12-12 fpending: port to native Windows with MSVC
      * .gitignore: Do not ignore lib/stdio-impl.h.
      * lib/fpending.c, lib/xalloc-oversized.h, m4/fpending.m4:
      Copy from gnulib.
      * lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
      * lib/stdio-impl.h:
      New file, copied from gnulib.
      * nt/gnulib.mk (EXTRA_DIST): Add stdio-impl.h.
      5942af61
  30. 27 Oct, 2016 1 commit
    • Paul Eggert's avatar
      Update from gnulib · 63eebff3
      Paul Eggert authored
      This incorporates:
      2016-10-16 qsort_r: Fix macrology for platforms that lack the function.
      2016-10-13 stdint: port SIZE_MAX to glibc s390
      2016-10-11 maint: remove stray space after "." in AC_DEFINE comment.
      * lib/gnulib.mk: Regenerate.
      * lib/stdlib.in.h, m4/st_dm_mode.m4, m4/stdint.m4, m4/stdlib_h.m4:
      * m4/utimes.m4: Copy from gnulib.
      63eebff3
  31. 21 Sep, 2016 1 commit
    • Paul Eggert's avatar
      Port recent flexmember changes to NetBSD · c0603964
      Paul Eggert authored
      The NetBSD library supports localtime_rz directly, and without
      this change 'configure' omitted the flexmember test that is marked
      as conditional on localtime_rz.  Emacs now needs to use
      flexmember.m4 even when localtime_rz works.
      Problem reported by Thomas Klausner.
      * admin/merge-gnulib (GNULIB_MODULES): Add flexmember.
      * lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
      c0603964
  32. 15 Sep, 2016 1 commit
    • Paul Eggert's avatar
      Update from gnulib · 8f4b6a20
      Paul Eggert authored
      This incorporates:
      2016-09-15 stdint: support new _WIDTH macros
      2016-09-15 limits-h: new module
      2016-09-15 sys_types: avoid glibc 2.25 warnings about major()
      2016-09-15 extensions: port to more ISO C TSes
      2016-09-13 intprops: new macro TYPE_WIDTH
      2016-09-13 extensions: port to recent ISO C TRs
      * .gitignore: Add lib/limits.h.
      * doc/misc/texinfo.tex, lib/ftoastr.h, lib/intprops.h:
      * lib/stdint.in.h, m4/extensions.m4, m4/stdint.m4, m4/stdio_h.m4:
      * m4/sys_types_h.m4: Copy from gnulib.
      * lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
      * lib/limits.in.h, m4/limits-h.m4: New files, copie from gnulib.
      * nt/gnulib.mk: Merge changes from lib/gnulib.mk.
      8f4b6a20
  33. 08 Sep, 2016 1 commit
    • Paul Eggert's avatar
      Update from gnulib · 12a7e0f8
      Paul Eggert authored
      This incorporates:
      2016-09-07 flexmember: new macro FLEXALIGNOF
      2016-09-07 flexmember: port better to GCC + valgrind
      2016-08-18 Port modules to use getprogname explicitly
      2016-09-02 manywarnings: add -fno-common
      * admin/merge-gnulib (GNULIB_TOOL_FLAGS): Don’t avoid flexmember,
      since time_rz now uses part of it.  Instead, remove m4/flexmember.m4.
      * configure.ac (AC_C_FLEXIBLE_ARRAY_MEMBER): Define away,
      since Emacs assumes C99 and therefore removes m4/flexmember.m4.
      * lib/euidaccess.c, lib/group-member.c, lib/time_rz.c:
      * m4/manywarnings.m4: Copy from gnulib.
      * lib/flexmember.h: New file, from gnulib.
      * lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
      12a7e0f8
  34. 21 Feb, 2016 1 commit
    • Paul Eggert's avatar
      Use Gnulib filevercmp for version comparison · 1f7feeca
      Paul Eggert authored
      * admin/merge-gnulib (GNULIB_MODULES): Add filevercmp.
      * doc/lispref/strings.texi (Text Comparison):
      * etc/NEWS, src/fns.c:
      * test/src/fns-tests.el (fns-tests-string-version-lessp):
      Rename newly-introduced function to string-version-lessp, by
      analogy with strverscmp.
      * lib/filevercmp.c, lib/filevercmp.h: New files, copied from gnulib.
      * lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
      * src/fns.c: Include <filevercmp.h>.
      (gather_number_from_string): Remove.
      (Fstring_version_lessp): Reimplement via filevercmp.
      1f7feeca
  35. 02 Feb, 2016 1 commit
    • Paul Eggert's avatar
      Build with C11 if available · b50075dd
      Paul Eggert authored
      * admin/merge-gnulib (GNULIB_MODULES): Add std-gnu11.
      * m4/std-gnu11.m4: New file, from gnulib.
      * lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
      b50075dd