diff options
author | Bruno Haible <bruno@clisp.org> | 2011-06-13 17:36:39 +0200 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2011-06-13 17:36:39 +0200 |
commit | 68fa085404c2047a7b7bc398d54a56ed6f32ce02 (patch) | |
tree | 2172b216f7889425f0dcbab1b59948e165100c5e | |
parent | 28b78430edd4230b709985803d942c98614caa9b (diff) | |
download | gnulib-68fa085404c2047a7b7bc398d54a56ed6f32ce02.tar.gz |
fseeko: Provide a non-inline replacement of fseek().
* lib/stdio.in.h (fseek): Don't provide if module 'fseek' is not used.
* modules/fseeko (Depends-on): Add fseek.
* modules/fseek (License): Change to LGPLv2+.
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | lib/stdio.in.h | 19 | ||||
-rw-r--r-- | modules/fseek | 2 | ||||
-rw-r--r-- | modules/fseeko | 2 |
4 files changed, 10 insertions, 20 deletions
@@ -1,5 +1,12 @@ 2011-06-13 Bruno Haible <bruno@clisp.org> + fseeko: Provide a non-inline replacement of fseek(). + * lib/stdio.in.h (fseek): Don't provide if module 'fseek' is not used. + * modules/fseeko (Depends-on): Add fseek. + * modules/fseek (License): Change to LGPLv2+. + +2011-06-13 Bruno Haible <bruno@clisp.org> + ftello: Provide a non-inline replacement of ftell(). * lib/stdio.in.h (ftell): Don't provide if module 'ftell' is not used. * m4/ftell.m4 (gl_FUNC_FTELL): Replace ftell also if the system does diff --git a/lib/stdio.in.h b/lib/stdio.in.h index fee5b65cff..edf521a8bb 100644 --- a/lib/stdio.in.h +++ b/lib/stdio.in.h @@ -461,25 +461,6 @@ _GL_FUNCDECL_SYS (fseeko, int, (FILE *fp, off_t offset, int whence) _GL_CXXALIAS_SYS (fseeko, int, (FILE *fp, off_t offset, int whence)); # endif _GL_CXXALIASWARN (fseeko); -# if (@REPLACE_FSEEKO@ || !@HAVE_FSEEKO@) && !@GNULIB_FSEEK@ - /* Provide an fseek function that is consistent with fseeko. */ - /* In order to avoid that fseek gets defined as a macro here, the - developer can request the 'fseek' module. */ -# if !GNULIB_defined_fseek_function -# undef fseek -# define fseek rpl_fseek -static inline int _GL_ARG_NONNULL ((1)) -rpl_fseek (FILE *fp, long offset, int whence) -{ -# if @REPLACE_FSEEKO@ - return rpl_fseeko (fp, offset, whence); -# else - return fseeko (fp, offset, whence); -# endif -} -# define GNULIB_defined_fseek_function 1 -# endif -# endif #elif defined GNULIB_POSIXCHECK # define _GL_FSEEK_WARN /* Category 1, above. */ # undef fseek diff --git a/modules/fseek b/modules/fseek index ef0d4bb8d7..87ab89ecb0 100644 --- a/modules/fseek +++ b/modules/fseek @@ -22,7 +22,7 @@ Include: <stdio.h> License: -LGPL +LGPLv2+ Maintainer: Bruno Haible diff --git a/modules/fseeko b/modules/fseeko index 62464e64cb..07f78e5550 100644 --- a/modules/fseeko +++ b/modules/fseeko @@ -10,6 +10,8 @@ Depends-on: extensions lseek stdio +# Just to guarantee consistency between fseek() and fseeko(). +fseek configure.ac-early: AC_REQUIRE([AC_FUNC_FSEEKO]) |