diff options
author | Bruno Haible <bruno@clisp.org> | 2018-05-12 20:37:47 +0200 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2018-05-12 20:37:47 +0200 |
commit | ca1e86d127224617de04715b6e7080560f921158 (patch) | |
tree | 5abce2c33e76380675656830a0c8ab882139c068 /m4 | |
parent | 681f4961d0edc066be458a092b48cd4b529337ba (diff) | |
download | gnulib-ca1e86d127224617de04715b6e7080560f921158.tar.gz |
fseeko: On mingw, don't use the hidden function _fseeki64.
Reported by Eli Zaretskii <eliz@gnu.org>.
* m4/fseeko.m4 (gl_PREREQ_FSEEKO): Test whether _fseeki64 is declared.
* lib/fseeko.c (fseeko): Use _fseeki64 only if it is declared.
Diffstat (limited to 'm4')
-rw-r--r-- | m4/fseeko.m4 | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/m4/fseeko.m4 b/m4/fseeko.m4 index 8967cf1539..86c246e899 100644 --- a/m4/fseeko.m4 +++ b/m4/fseeko.m4 @@ -1,4 +1,4 @@ -# fseeko.m4 serial 18 +# fseeko.m4 serial 19 dnl Copyright (C) 2007-2018 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -68,7 +68,10 @@ AC_DEFUN([gl_STDIN_LARGE_OFFSET], # Prerequisites of lib/fseeko.c. AC_DEFUN([gl_PREREQ_FSEEKO], [ - dnl Native Windows has the function _fseeki64. mingw hides it, but mingw64 - dnl makes it usable again. + dnl Native Windows has the function _fseeki64. mingw hides it in some + dnl circumstances, but mingw64 makes it usable again. AC_CHECK_FUNCS([_fseeki64]) + if test $ac_cv_func__fseeki64 = yes; then + AC_CHECK_DECLS([_fseeki64]) + fi ]) |