[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[SCM] GNU gnutls branch, master, updated. gnutls_2_9_7-12-g8c44633
From: |
Simon Josefsson |
Subject: |
[SCM] GNU gnutls branch, master, updated. gnutls_2_9_7-12-g8c44633 |
Date: |
Thu, 15 Oct 2009 06:36:26 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU gnutls".
http://git.savannah.gnu.org/cgit/gnutls.git/commit/?id=8c4463309584836a77cf35d5acf7a94b37b1acd9
The branch, master has been updated
via 8c4463309584836a77cf35d5acf7a94b37b1acd9 (commit)
via 5f30b74679828c8f0e18f42096d9651b00772aff (commit)
from 55aa014dffb9b95bc3ad55a3d17f92668e416088 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 8c4463309584836a77cf35d5acf7a94b37b1acd9
Author: Simon Josefsson <address@hidden>
Date: Thu Oct 15 08:36:07 2009 +0200
Update gnulib files.
commit 5f30b74679828c8f0e18f42096d9651b00772aff
Author: Simon Josefsson <address@hidden>
Date: Thu Oct 15 08:34:52 2009 +0200
Update gnulib files.
-----------------------------------------------------------------------
Summary of changes:
gl/Makefile.am | 31 +++++++++++++++++++++++++++++++
gl/m4/gnulib-comp.m4 | 6 +++++-
gl/m4/sys_stat_h.m4 | 5 ++++-
{lib/gl => gl}/m4/time_h.m4 | 0
gl/sys_stat.in.h | 26 ++++++++++++++++++++++++++
gl/tests/Makefile.am | 9 +++++++++
gl/tests/test-sys_stat.c | 27 ++++++++++++++++++++++++++-
{lib/gl => gl}/tests/test-time.c | 0
{lib/gl => gl}/time.in.h | 8 ++++----
gl/unistd.in.h | 4 ++--
lib/gl/Makefile.am | 3 +++
lib/gl/m4/gnulib-comp.m4 | 2 +-
lib/gl/m4/sys_stat_h.m4 | 5 ++++-
lib/gl/sys_stat.in.h | 26 ++++++++++++++++++++++++++
lib/gl/tests/test-sys_stat.c | 27 ++++++++++++++++++++++++++-
lib/gl/unistd.in.h | 4 ++--
16 files changed, 169 insertions(+), 14 deletions(-)
copy {lib/gl => gl}/m4/time_h.m4 (100%)
copy {lib/gl => gl}/tests/test-time.c (100%)
copy {lib/gl => gl}/time.in.h (92%)
diff --git a/gl/Makefile.am b/gl/Makefile.am
index 78642d6..e7e93d4 100644
--- a/gl/Makefile.am
+++ b/gl/Makefile.am
@@ -1014,6 +1014,7 @@ sys/stat.h: sys_stat.in.h
-e 's|@''NEXT_SYS_STAT_H''@|$(NEXT_SYS_STAT_H)|g' \
-e 's|@''GNULIB_FCHMODAT''@|$(GNULIB_FCHMODAT)|g' \
-e 's|@''GNULIB_FSTATAT''@|$(GNULIB_FSTATAT)|g' \
+ -e 's|@''GNULIB_FUTIMENS''@|$(GNULIB_FUTIMENS)|g' \
-e 's|@''GNULIB_LCHMOD''@|$(GNULIB_LCHMOD)|g' \
-e 's|@''GNULIB_LSTAT''@|$(GNULIB_LSTAT)|g' \
-e 's|@''GNULIB_MKDIRAT''@|$(GNULIB_MKDIRAT)|g' \
@@ -1022,6 +1023,7 @@ sys/stat.h: sys_stat.in.h
-e 's|@''GNULIB_STAT''@|$(GNULIB_STAT)|g' \
-e 's|@''HAVE_FCHMODAT''@|$(HAVE_FCHMODAT)|g' \
-e 's|@''HAVE_FSTATAT''@|$(HAVE_FSTATAT)|g' \
+ -e 's|@''HAVE_FUTIMENS''@|$(HAVE_FUTIMENS)|g' \
-e 's|@''HAVE_LCHMOD''@|$(HAVE_LCHMOD)|g' \
-e 's|@''HAVE_LSTAT''@|$(HAVE_LSTAT)|g' \
-e 's|@''HAVE_MKDIRAT''@|$(HAVE_MKDIRAT)|g' \
@@ -1029,6 +1031,7 @@ sys/stat.h: sys_stat.in.h
-e 's|@''HAVE_MKNODAT''@|$(HAVE_MKNODAT)|g' \
-e 's|@''REPLACE_FSTAT''@|$(REPLACE_FSTAT)|g' \
-e 's|@''REPLACE_FSTATAT''@|$(REPLACE_FSTATAT)|g' \
+ -e 's|@''REPLACE_FUTIMENS''@|$(REPLACE_FUTIMENS)|g' \
-e 's|@''REPLACE_LSTAT''@|$(REPLACE_LSTAT)|g' \
-e 's|@''REPLACE_MKDIR''@|$(REPLACE_MKDIR)|g' \
-e 's|@''REPLACE_STAT''@|$(REPLACE_STAT)|g' \
@@ -1068,6 +1071,34 @@ EXTRA_DIST += sys_time.in.h
## end gnulib module sys_time
+## begin gnulib module time
+
+BUILT_SOURCES += time.h
+
+# We need the following in order to create <time.h> when the system
+# doesn't have one that works with the given compiler.
+time.h: time.in.h
+ $(AM_V_GEN)rm -f address@hidden $@ && \
+ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \
+ sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \
+ -e 's|@''PRAGMA_SYSTEM_HEADER''@|@PRAGMA_SYSTEM_HEADER@|g' \
+ -e 's|@NEXT_TIME_H''@|$(NEXT_TIME_H)|g' \
+ -e 's|@REPLACE_LOCALTIME_R''@|$(REPLACE_LOCALTIME_R)|g' \
+ -e 's|@REPLACE_MKTIME''@|$(REPLACE_MKTIME)|g' \
+ -e 's|@REPLACE_NANOSLEEP''@|$(REPLACE_NANOSLEEP)|g' \
+ -e 's|@REPLACE_STRPTIME''@|$(REPLACE_STRPTIME)|g' \
+ -e 's|@REPLACE_TIMEGM''@|$(REPLACE_TIMEGM)|g' \
+ -e
's|@SYS_TIME_H_DEFINES_STRUCT_TIMESPEC''@|$(SYS_TIME_H_DEFINES_STRUCT_TIMESPEC)|g'
\
+ -e
's|@TIME_H_DEFINES_STRUCT_TIMESPEC''@|$(TIME_H_DEFINES_STRUCT_TIMESPEC)|g' \
+ < $(srcdir)/time.in.h; \
+ } > address@hidden && \
+ mv address@hidden $@
+MOSTLYCLEANFILES += time.h time.h-t
+
+EXTRA_DIST += time.in.h
+
+## end gnulib module time
+
## begin gnulib module unistd
BUILT_SOURCES += unistd.h
diff --git a/gl/m4/gnulib-comp.m4 b/gl/m4/gnulib-comp.m4
index fa0a089..045b826 100644
--- a/gl/m4/gnulib-comp.m4
+++ b/gl/m4/gnulib-comp.m4
@@ -190,6 +190,7 @@ AC_SUBST([LTALLOCA])
AC_PROG_MKDIR_P
gl_HEADER_SYS_TIME_H
AC_PROG_MKDIR_P
+ gl_HEADER_TIME_H
gl_UNISTD_H
gl_FUNC_VASNPRINTF
gl_VERSION_ETC
@@ -252,7 +253,7 @@ AC_SUBST([LTALLOCA])
gt_TYPE_WINT_T
gl_SYS_IOCTL_H
AC_PROG_MKDIR_P
- AC_CHECK_FUNCS([shutdown])
+ AC_CHECK_FUNCS_ONCE([shutdown])
abs_aux_dir=`cd "$ac_aux_dir"; pwd`
AC_SUBST([abs_aux_dir])
m4_ifval(gltests_LIBSOURCES_LIST, [
@@ -432,6 +433,7 @@ AC_DEFUN([gl_FILE_LIST], [
lib/sys_socket.in.h
lib/sys_stat.in.h
lib/sys_time.in.h
+ lib/time.in.h
lib/unistd.in.h
lib/vasnprintf.c
lib/vasnprintf.h
@@ -505,6 +507,7 @@ AC_DEFUN([gl_FILE_LIST], [
m4/sys_socket_h.m4
m4/sys_stat_h.m4
m4/sys_time_h.m4
+ m4/time_h.m4
m4/ungetc.m4
m4/unistd_h.m4
m4/vasnprintf.m4
@@ -552,6 +555,7 @@ AC_DEFUN([gl_FILE_LIST], [
tests/test-sys_socket.c
tests/test-sys_stat.c
tests/test-sys_time.c
+ tests/test-time.c
tests/test-unistd.c
tests/test-vasnprintf.c
tests/test-vc-list-files-cvs.sh
diff --git a/gl/m4/sys_stat_h.m4 b/gl/m4/sys_stat_h.m4
index d37fea8..6004890 100644
--- a/gl/m4/sys_stat_h.m4
+++ b/gl/m4/sys_stat_h.m4
@@ -1,4 +1,4 @@
-# sys_stat_h.m4 serial 17 -*- Autoconf -*-
+# sys_stat_h.m4 serial 18 -*- Autoconf -*-
dnl Copyright (C) 2006-2009 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -41,6 +41,7 @@ AC_DEFUN([gl_SYS_STAT_H_DEFAULTS],
AC_REQUIRE([gl_UNISTD_H_DEFAULTS]) dnl for REPLACE_FCHDIR
GNULIB_FCHMODAT=0; AC_SUBST([GNULIB_FCHMODAT])
GNULIB_FSTATAT=0; AC_SUBST([GNULIB_FSTATAT])
+ GNULIB_FUTIMENS=0; AC_SUBST([GNULIB_FUTIMENS])
GNULIB_LCHMOD=0; AC_SUBST([GNULIB_LCHMOD])
GNULIB_LSTAT=0; AC_SUBST([GNULIB_LSTAT])
GNULIB_MKDIRAT=0; AC_SUBST([GNULIB_MKDIRAT])
@@ -50,6 +51,7 @@ AC_DEFUN([gl_SYS_STAT_H_DEFAULTS],
dnl Assume proper GNU behavior unless another module says otherwise.
HAVE_FCHMODAT=1; AC_SUBST([HAVE_FCHMODAT])
HAVE_FSTATAT=1; AC_SUBST([HAVE_FSTATAT])
+ HAVE_FUTIMENS=1; AC_SUBST([HAVE_FUTIMENS])
HAVE_LCHMOD=1; AC_SUBST([HAVE_LCHMOD])
HAVE_LSTAT=1; AC_SUBST([HAVE_LSTAT])
HAVE_MKDIRAT=1; AC_SUBST([HAVE_MKDIRAT])
@@ -57,6 +59,7 @@ AC_DEFUN([gl_SYS_STAT_H_DEFAULTS],
HAVE_MKNODAT=1; AC_SUBST([HAVE_MKNODAT])
REPLACE_FSTAT=0; AC_SUBST([REPLACE_FSTAT])
REPLACE_FSTATAT=0; AC_SUBST([REPLACE_FSTATAT])
+ REPLACE_FUTIMENS=0; AC_SUBST([REPLACE_FUTIMENS])
REPLACE_LSTAT=0; AC_SUBST([REPLACE_LSTAT])
REPLACE_MKDIR=0; AC_SUBST([REPLACE_MKDIR])
REPLACE_STAT=0; AC_SUBST([REPLACE_STAT])
diff --git a/lib/gl/m4/time_h.m4 b/gl/m4/time_h.m4
similarity index 100%
copy from lib/gl/m4/time_h.m4
copy to gl/m4/time_h.m4
diff --git a/gl/sys_stat.in.h b/gl/sys_stat.in.h
index b2a7df9..492fbb6 100644
--- a/gl/sys_stat.in.h
+++ b/gl/sys_stat.in.h
@@ -38,6 +38,9 @@
/* Get nlink_t. */
#include <sys/types.h>
+/* Get struct timespec. */
+#include <time.h>
+
/* The include_next requires a split double-inclusion guard. */
address@hidden@ @NEXT_SYS_STAT_H@
@@ -278,6 +281,12 @@
# define S_IRWXUGO (S_IRWXU | S_IRWXG | S_IRWXO)
#endif
+/* Macros for futimens and utimensat. */
+#ifndef UTIME_NOW
+# define UTIME_NOW (-1)
+# define UTIME_OMIT (-2)
+#endif
+
#ifdef __cplusplus
extern "C" {
@@ -349,6 +358,23 @@ extern int fstatat (int fd, char const *name, struct stat
*st, int flags);
#endif
+#if @GNULIB_FUTIMENS@
+# if @REPLACE_FUTIMENS@
+# undef futimens
+# define futimens rpl_futimens
+# endif
+# if address@hidden@ || @REPLACE_FUTIMENS@
+extern int futimens (int fd, struct timespec const times[2]);
+# endif
+#elif defined GNULIB_POSIXCHECK
+# undef futimens
+# define futimens(f,t) \
+ (GL_LINK_WARNING ("futimens is not portable - " \
+ "use gnulib module futimens for portability"), \
+ futimens (f, t))
+#endif
+
+
#if @GNULIB_MKDIRAT@
# if address@hidden@
extern int mkdirat (int fd, char const *file, mode_t mode);
diff --git a/gl/tests/Makefile.am b/gl/tests/Makefile.am
index e782748..9491893 100644
--- a/gl/tests/Makefile.am
+++ b/gl/tests/Makefile.am
@@ -369,6 +369,15 @@ EXTRA_DIST += test-sys_time.c
## end gnulib module sys_time-tests
+## begin gnulib module time-tests
+
+TESTS += test-time
+check_PROGRAMS += test-time
+
+EXTRA_DIST += test-time.c
+
+## end gnulib module time-tests
+
## begin gnulib module unistd-tests
TESTS += test-unistd
diff --git a/gl/tests/test-sys_stat.c b/gl/tests/test-sys_stat.c
index 4b5eb76..a73f9b8 100644
--- a/gl/tests/test-sys_stat.c
+++ b/gl/tests/test-sys_stat.c
@@ -1,5 +1,5 @@
/* Test of <sys/stat.h> substitute.
- Copyright (C) 2007-2008 Free Software Foundation, Inc.
+ Copyright (C) 2007-2009 Free Software Foundation, Inc.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -253,9 +253,34 @@ verify (!S_ISWHT (S_IFLNK));
verify (!S_ISWHT (S_IFSOCK));
#endif
+/* POSIX 2008 requires traditional encoding of permission constants. */
+verify (S_IRWXU == 00700);
+verify (S_IRUSR == 00400);
+verify (S_IWUSR == 00200);
+verify (S_IXUSR == 00100);
+verify (S_IRWXG == 00070);
+verify (S_IRGRP == 00040);
+verify (S_IWGRP == 00020);
+verify (S_IXGRP == 00010);
+verify (S_IRWXO == 00007);
+verify (S_IROTH == 00004);
+verify (S_IWOTH == 00002);
+verify (S_IXOTH == 00001);
+verify (S_ISUID == 04000);
+verify (S_ISGID == 02000);
+verify (S_ISVTX == 01000);
+
+#if ((0 <= UTIME_NOW && UTIME_NOW < 1000000000) \
+ || (0 <= UTIME_OMIT && UTIME_OMIT < 1000000000) \
+ || UTIME_NOW == UTIME_OMIT)
+invalid UTIME macros
+#endif
+
/* Check the existence of some types. */
nlink_t t1;
+struct timespec t2;
+
int
main ()
{
diff --git a/lib/gl/tests/test-time.c b/gl/tests/test-time.c
similarity index 100%
copy from lib/gl/tests/test-time.c
copy to gl/tests/test-time.c
diff --git a/lib/gl/time.in.h b/gl/time.in.h
similarity index 92%
copy from lib/gl/time.in.h
copy to gl/time.in.h
index 6b218e8..ef8d0ba 100644
--- a/lib/gl/time.in.h
+++ b/gl/time.in.h
@@ -3,16 +3,16 @@
Copyright (C) 2007-2009 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU Lesser General Public License as published by
- the Free Software Foundation; either version 2.1, or (at your option)
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 3, or (at your option)
any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU Lesser General Public License for more details.
+ GNU General Public License for more details.
- You should have received a copy of the GNU Lesser General Public License
+ You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */
diff --git a/gl/unistd.in.h b/gl/unistd.in.h
index 34da936..c755467 100644
--- a/gl/unistd.in.h
+++ b/gl/unistd.in.h
@@ -49,7 +49,7 @@
#endif
/* Get getopt(), optarg, optind, opterr, optopt. */
-#if @GNULIB_UNISTD_H_GETOPT@
+#if @GNULIB_UNISTD_H_GETOPT@ && !defined _GL_SYSTEM_GETOPT
# include <getopt.h>
#endif
@@ -239,7 +239,7 @@ extern char **environ;
#if @GNULIB_EUIDACCESS@
# if address@hidden@
-/* Like access(), except that is uses the effective user id and group id of
+/* Like access(), except that it uses the effective user id and group id of
the current process. */
extern int euidaccess (const char *filename, int mode);
# endif
diff --git a/lib/gl/Makefile.am b/lib/gl/Makefile.am
index b631277..c1e87e2 100644
--- a/lib/gl/Makefile.am
+++ b/lib/gl/Makefile.am
@@ -738,6 +738,7 @@ sys/stat.h: sys_stat.in.h
-e 's|@''NEXT_SYS_STAT_H''@|$(NEXT_SYS_STAT_H)|g' \
-e 's|@''GNULIB_FCHMODAT''@|$(GNULIB_FCHMODAT)|g' \
-e 's|@''GNULIB_FSTATAT''@|$(GNULIB_FSTATAT)|g' \
+ -e 's|@''GNULIB_FUTIMENS''@|$(GNULIB_FUTIMENS)|g' \
-e 's|@''GNULIB_LCHMOD''@|$(GNULIB_LCHMOD)|g' \
-e 's|@''GNULIB_LSTAT''@|$(GNULIB_LSTAT)|g' \
-e 's|@''GNULIB_MKDIRAT''@|$(GNULIB_MKDIRAT)|g' \
@@ -746,6 +747,7 @@ sys/stat.h: sys_stat.in.h
-e 's|@''GNULIB_STAT''@|$(GNULIB_STAT)|g' \
-e 's|@''HAVE_FCHMODAT''@|$(HAVE_FCHMODAT)|g' \
-e 's|@''HAVE_FSTATAT''@|$(HAVE_FSTATAT)|g' \
+ -e 's|@''HAVE_FUTIMENS''@|$(HAVE_FUTIMENS)|g' \
-e 's|@''HAVE_LCHMOD''@|$(HAVE_LCHMOD)|g' \
-e 's|@''HAVE_LSTAT''@|$(HAVE_LSTAT)|g' \
-e 's|@''HAVE_MKDIRAT''@|$(HAVE_MKDIRAT)|g' \
@@ -753,6 +755,7 @@ sys/stat.h: sys_stat.in.h
-e 's|@''HAVE_MKNODAT''@|$(HAVE_MKNODAT)|g' \
-e 's|@''REPLACE_FSTAT''@|$(REPLACE_FSTAT)|g' \
-e 's|@''REPLACE_FSTATAT''@|$(REPLACE_FSTATAT)|g' \
+ -e 's|@''REPLACE_FUTIMENS''@|$(REPLACE_FUTIMENS)|g' \
-e 's|@''REPLACE_LSTAT''@|$(REPLACE_LSTAT)|g' \
-e 's|@''REPLACE_MKDIR''@|$(REPLACE_MKDIR)|g' \
-e 's|@''REPLACE_STAT''@|$(REPLACE_STAT)|g' \
diff --git a/lib/gl/m4/gnulib-comp.m4 b/lib/gl/m4/gnulib-comp.m4
index 7f3142d..9265e44 100644
--- a/lib/gl/m4/gnulib-comp.m4
+++ b/lib/gl/m4/gnulib-comp.m4
@@ -143,7 +143,7 @@ AC_DEFUN([lgl_INIT],
gl_FUNC_UNGETC_WORKS
gt_TYPE_WCHAR_T
gt_TYPE_WINT_T
- AC_CHECK_FUNCS([shutdown])
+ AC_CHECK_FUNCS_ONCE([shutdown])
m4_ifval(lgltests_LIBSOURCES_LIST, [
m4_syscmd([test ! -d ]m4_defn([lgltests_LIBSOURCES_DIR])[ ||
for gl_file in ]lgltests_LIBSOURCES_LIST[ ; do
diff --git a/lib/gl/m4/sys_stat_h.m4 b/lib/gl/m4/sys_stat_h.m4
index d37fea8..6004890 100644
--- a/lib/gl/m4/sys_stat_h.m4
+++ b/lib/gl/m4/sys_stat_h.m4
@@ -1,4 +1,4 @@
-# sys_stat_h.m4 serial 17 -*- Autoconf -*-
+# sys_stat_h.m4 serial 18 -*- Autoconf -*-
dnl Copyright (C) 2006-2009 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -41,6 +41,7 @@ AC_DEFUN([gl_SYS_STAT_H_DEFAULTS],
AC_REQUIRE([gl_UNISTD_H_DEFAULTS]) dnl for REPLACE_FCHDIR
GNULIB_FCHMODAT=0; AC_SUBST([GNULIB_FCHMODAT])
GNULIB_FSTATAT=0; AC_SUBST([GNULIB_FSTATAT])
+ GNULIB_FUTIMENS=0; AC_SUBST([GNULIB_FUTIMENS])
GNULIB_LCHMOD=0; AC_SUBST([GNULIB_LCHMOD])
GNULIB_LSTAT=0; AC_SUBST([GNULIB_LSTAT])
GNULIB_MKDIRAT=0; AC_SUBST([GNULIB_MKDIRAT])
@@ -50,6 +51,7 @@ AC_DEFUN([gl_SYS_STAT_H_DEFAULTS],
dnl Assume proper GNU behavior unless another module says otherwise.
HAVE_FCHMODAT=1; AC_SUBST([HAVE_FCHMODAT])
HAVE_FSTATAT=1; AC_SUBST([HAVE_FSTATAT])
+ HAVE_FUTIMENS=1; AC_SUBST([HAVE_FUTIMENS])
HAVE_LCHMOD=1; AC_SUBST([HAVE_LCHMOD])
HAVE_LSTAT=1; AC_SUBST([HAVE_LSTAT])
HAVE_MKDIRAT=1; AC_SUBST([HAVE_MKDIRAT])
@@ -57,6 +59,7 @@ AC_DEFUN([gl_SYS_STAT_H_DEFAULTS],
HAVE_MKNODAT=1; AC_SUBST([HAVE_MKNODAT])
REPLACE_FSTAT=0; AC_SUBST([REPLACE_FSTAT])
REPLACE_FSTATAT=0; AC_SUBST([REPLACE_FSTATAT])
+ REPLACE_FUTIMENS=0; AC_SUBST([REPLACE_FUTIMENS])
REPLACE_LSTAT=0; AC_SUBST([REPLACE_LSTAT])
REPLACE_MKDIR=0; AC_SUBST([REPLACE_MKDIR])
REPLACE_STAT=0; AC_SUBST([REPLACE_STAT])
diff --git a/lib/gl/sys_stat.in.h b/lib/gl/sys_stat.in.h
index 501a82c..298985b 100644
--- a/lib/gl/sys_stat.in.h
+++ b/lib/gl/sys_stat.in.h
@@ -38,6 +38,9 @@
/* Get nlink_t. */
#include <sys/types.h>
+/* Get struct timespec. */
+#include <time.h>
+
/* The include_next requires a split double-inclusion guard. */
address@hidden@ @NEXT_SYS_STAT_H@
@@ -278,6 +281,12 @@
# define S_IRWXUGO (S_IRWXU | S_IRWXG | S_IRWXO)
#endif
+/* Macros for futimens and utimensat. */
+#ifndef UTIME_NOW
+# define UTIME_NOW (-1)
+# define UTIME_OMIT (-2)
+#endif
+
#ifdef __cplusplus
extern "C" {
@@ -349,6 +358,23 @@ extern int fstatat (int fd, char const *name, struct stat
*st, int flags);
#endif
+#if @GNULIB_FUTIMENS@
+# if @REPLACE_FUTIMENS@
+# undef futimens
+# define futimens rpl_futimens
+# endif
+# if address@hidden@ || @REPLACE_FUTIMENS@
+extern int futimens (int fd, struct timespec const times[2]);
+# endif
+#elif defined GNULIB_POSIXCHECK
+# undef futimens
+# define futimens(f,t) \
+ (GL_LINK_WARNING ("futimens is not portable - " \
+ "use gnulib module futimens for portability"), \
+ futimens (f, t))
+#endif
+
+
#if @GNULIB_MKDIRAT@
# if address@hidden@
extern int mkdirat (int fd, char const *file, mode_t mode);
diff --git a/lib/gl/tests/test-sys_stat.c b/lib/gl/tests/test-sys_stat.c
index 4b5eb76..a73f9b8 100644
--- a/lib/gl/tests/test-sys_stat.c
+++ b/lib/gl/tests/test-sys_stat.c
@@ -1,5 +1,5 @@
/* Test of <sys/stat.h> substitute.
- Copyright (C) 2007-2008 Free Software Foundation, Inc.
+ Copyright (C) 2007-2009 Free Software Foundation, Inc.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -253,9 +253,34 @@ verify (!S_ISWHT (S_IFLNK));
verify (!S_ISWHT (S_IFSOCK));
#endif
+/* POSIX 2008 requires traditional encoding of permission constants. */
+verify (S_IRWXU == 00700);
+verify (S_IRUSR == 00400);
+verify (S_IWUSR == 00200);
+verify (S_IXUSR == 00100);
+verify (S_IRWXG == 00070);
+verify (S_IRGRP == 00040);
+verify (S_IWGRP == 00020);
+verify (S_IXGRP == 00010);
+verify (S_IRWXO == 00007);
+verify (S_IROTH == 00004);
+verify (S_IWOTH == 00002);
+verify (S_IXOTH == 00001);
+verify (S_ISUID == 04000);
+verify (S_ISGID == 02000);
+verify (S_ISVTX == 01000);
+
+#if ((0 <= UTIME_NOW && UTIME_NOW < 1000000000) \
+ || (0 <= UTIME_OMIT && UTIME_OMIT < 1000000000) \
+ || UTIME_NOW == UTIME_OMIT)
+invalid UTIME macros
+#endif
+
/* Check the existence of some types. */
nlink_t t1;
+struct timespec t2;
+
int
main ()
{
diff --git a/lib/gl/unistd.in.h b/lib/gl/unistd.in.h
index fd2747c..c7a0dc9 100644
--- a/lib/gl/unistd.in.h
+++ b/lib/gl/unistd.in.h
@@ -49,7 +49,7 @@
#endif
/* Get getopt(), optarg, optind, opterr, optopt. */
-#if @GNULIB_UNISTD_H_GETOPT@
+#if @GNULIB_UNISTD_H_GETOPT@ && !defined _GL_SYSTEM_GETOPT
# include <getopt.h>
#endif
@@ -239,7 +239,7 @@ extern char **environ;
#if @GNULIB_EUIDACCESS@
# if address@hidden@
-/* Like access(), except that is uses the effective user id and group id of
+/* Like access(), except that it uses the effective user id and group id of
the current process. */
extern int euidaccess (const char *filename, int mode);
# endif
hooks/post-receive
--
GNU gnutls
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [SCM] GNU gnutls branch, master, updated. gnutls_2_9_7-12-g8c44633,
Simon Josefsson <=