summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog9
-rw-r--r--lib/same-inode.h2
-rw-r--r--m4/sys_types_h.m45
3 files changed, 14 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index ae9e39d06f..4294d512a5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2017-06-04 Paul Eggert <eggert@cs.ucla.edu>
+
+ same-inode: port better to VMS 8.2 and later
+ Problem reported by John E. Malmberg in:
+ http://lists.gnu.org/archive/html/bug-gnulib/2017-06/msg00005.html
+ * lib/same-inode.h (SAME_INODE) [__VMS && 80200000 <= __CRTL_VER]:
+ Use the usual POSIX definition.
+ * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Define _USE_STD_STAT.
+
2017-06-01 Paul Eggert <eggert@cs.ucla.edu>
error: fix POSIX violation for va_end
diff --git a/lib/same-inode.h b/lib/same-inode.h
index a08bc4ec0d..0c18563967 100644
--- a/lib/same-inode.h
+++ b/lib/same-inode.h
@@ -20,7 +20,7 @@
# include <sys/types.h>
-# ifdef __VMS
+# if defined __VMS && __CRTL_VER < 80200000
# define SAME_INODE(a, b) \
((a).st_ino[0] == (b).st_ino[0] \
&& (a).st_ino[1] == (b).st_ino[1] \
diff --git a/m4/sys_types_h.m4 b/m4/sys_types_h.m4
index e5906709f6..ec0860be90 100644
--- a/m4/sys_types_h.m4
+++ b/m4/sys_types_h.m4
@@ -1,4 +1,4 @@
-# sys_types_h.m4 serial 7
+# sys_types_h.m4 serial 8
dnl Copyright (C) 2011-2017 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -6,6 +6,9 @@ dnl with or without modifications, as long as this notice is preserved.
AC_DEFUN_ONCE([gl_SYS_TYPES_H],
[
+ dnl Use sane struct stat types in OpenVMS 8.2 and later.
+ AC_DEFINE([_USE_STD_STAT], 1, [For standard stat data types on VMS.])
+
AC_REQUIRE([gl_SYS_TYPES_H_DEFAULTS])
gl_NEXT_HEADERS([sys/types.h])