diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2017-07-13 19:24:06 -0700 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2017-07-13 19:24:49 -0700 |
commit | 3128d5d10e702ccb0732d947370e539a54046fc9 (patch) | |
tree | a2a3c95dcf1263d55ca63fb4675b43286a8351de /lib | |
parent | ab87dbad1d26fba4e33b62b4b5a840be77ae9aa5 (diff) | |
download | emacs-3128d5d10e702ccb0732d947370e539a54046fc9.tar.gz |
Merge from gnulib
This incorporates:
2017-07-13 Improve cross-compilation guesses for native Windows
2017-07-11 More systematic m4 quoting and indentation
2017-07-10 Make sure $host and $host_os are defined when used
2017-07-03 stdioext: Port to OpenVMS
2017-06-24 xalloc-oversized: port to icc
* doc/misc/texinfo.tex, lib/fpending.c, lib/stdio-impl.h:
* lib/xalloc-oversized.h, m4/dirfd.m4, m4/gettimeofday.m4:
* m4/lstat.m4, m4/mktime.m4, m4/pselect.m4, m4/putenv.m4:
* m4/stdint.m4, m4/strtoimax.m4, m4/utimes.m4:
Copy from Gnulib.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/fpending.c | 4 | ||||
-rw-r--r-- | lib/stdio-impl.h | 2 | ||||
-rw-r--r-- | lib/xalloc-oversized.h | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/lib/fpending.c b/lib/fpending.c index c9b77866858..02602a1c27f 100644 --- a/lib/fpending.c +++ b/lib/fpending.c @@ -41,7 +41,7 @@ __fpending (FILE *fp) return fp->_ptr - fp->_buffer; #elif defined __minix /* Minix */ return fp_->_ptr - fp_->_buf; -#elif defined _IOERR /* AIX, HP-UX, IRIX, OSF/1, Solaris, OpenServer, mingw, MSVC, NonStop Kernel */ +#elif defined _IOERR /* AIX, HP-UX, IRIX, OSF/1, Solaris, OpenServer, mingw, MSVC, NonStop Kernel, OpenVMS */ return (fp_->_ptr ? fp_->_ptr - fp_->_base : 0); #elif defined __UCLIBC__ /* uClibc */ return (fp->__modeflags & __FLAG_WRITING ? fp->__bufpos - fp->__bufstart : 0); @@ -51,8 +51,6 @@ __fpending (FILE *fp) return fp->__bufp - fp->__buffer; #elif defined EPLAN9 /* Plan9 */ return fp->wp - fp->buf; -#elif defined __VMS /* VMS */ - return (*fp)->_ptr - (*fp)->_base; #else # error "Please port gnulib fpending.c to your platform!" return 1; diff --git a/lib/stdio-impl.h b/lib/stdio-impl.h index 75a945eb724..d5b5943fd7c 100644 --- a/lib/stdio-impl.h +++ b/lib/stdio-impl.h @@ -99,6 +99,8 @@ int _file; \ unsigned int _flag; \ } *) fp) +# elif defined __VMS /* OpenVMS */ +# define fp_ ((struct _iobuf *) fp) # else # define fp_ fp # endif diff --git a/lib/xalloc-oversized.h b/lib/xalloc-oversized.h index ff0efc6ba40..2e09bab0be2 100644 --- a/lib/xalloc-oversized.h +++ b/lib/xalloc-oversized.h @@ -44,7 +44,7 @@ typedef size_t __xalloc_count_type; #if 7 <= __GNUC__ # define xalloc_oversized(n, s) \ __builtin_mul_overflow_p (n, s, (__xalloc_count_type) 1) -#elif 5 <= __GNUC__ && !__STRICT_ANSI__ +#elif 5 <= __GNUC__ && !defined __ICC && !__STRICT_ANSI__ # define xalloc_oversized(n, s) \ (__builtin_constant_p (n) && __builtin_constant_p (s) \ ? __xalloc_oversized (n, s) \ |