[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: fseeko, ftello: avoid inline function in include file
From: |
Bruno Haible |
Subject: |
Re: fseeko, ftello: avoid inline function in include file |
Date: |
Mon, 13 Jun 2011 17:38:46 +0200 |
User-agent: |
KMail/1.9.9 |
Eric Blake wrote:
> This looks reasonable to me (and no problem on the license change).
Good, I've applied it, together with the same change for fseeko:
2011-06-13 Bruno Haible <address@hidden>
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+.
--- lib/stdio.in.h.orig Mon Jun 13 17:35:25 2011
+++ lib/stdio.in.h Mon Jun 13 17:34:59 2011
@@ -461,25 +461,6 @@
_GL_CXXALIAS_SYS (fseeko, int, (FILE *fp, off_t offset, int whence));
# endif
_GL_CXXALIASWARN (fseeko);
-# if (@REPLACE_FSEEKO@ || address@hidden@) && address@hidden@
- /* 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
--- modules/fseek.orig Mon Jun 13 17:35:25 2011
+++ modules/fseek Mon Jun 13 17:34:59 2011
@@ -22,7 +22,7 @@
<stdio.h>
License:
-LGPL
+LGPLv2+
Maintainer:
Bruno Haible
--- modules/fseeko.orig Mon Jun 13 17:35:25 2011
+++ modules/fseeko Mon Jun 13 17:34:59 2011
@@ -10,6 +10,8 @@
extensions
lseek
stdio
+# Just to guarantee consistency between fseek() and fseeko().
+fseek
configure.ac-early:
AC_REQUIRE([AC_FUNC_FSEEKO])
--
In memoriam Anna Göldi <http://en.wikipedia.org/wiki/Anna_Göldi>