changeset 38234:1f7f312e4bb3

link: fix test to declare use of rename() The test in link.m4 needs to include <stdio.h> to provide a declaration for the rename function. The test fails if building with GCC's -Werror=implicit-function-declaration option. This was reported as part of a bug with building Octave on Fedora, which now uses -Werror=implicit-function-declaration by default. * m4/link.m4 (gl_FUNC_LINK): Include <stdio.h>. https://savannah.gnu.org/bugs/?49782
author John W. Eaton <gnu@jweaton.org>
date Tue, 13 Dec 2016 12:43:09 -0500
parents 0ab656ac6e8e
children 5debeeaf0598
files ChangeLog m4/link.m4
diffstat 2 files changed, 7 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Tue Dec 13 11:19:35 2016 +0100
+++ b/ChangeLog	Tue Dec 13 12:43:09 2016 -0500
@@ -1,3 +1,9 @@
+2016-12-13  John W. Eaton  <gnu@jweaton.org>
+
+	link: fix test to declare use of rename()
+	* m4/link.m4 (gl_FUNC_LINK): Include <stdio.h> needed with
+	-Werror=implicit-function-declaration
+
 2016-12-12  Bruno Haible  <bruno@clisp.org>
 
 	fpending: Port to native Windows with MSVC.
--- a/m4/link.m4	Tue Dec 13 11:19:35 2016 +0100
+++ b/m4/link.m4	Tue Dec 13 12:43:09 2016 -0500
@@ -22,6 +22,7 @@
        AC_RUN_IFELSE(
          [AC_LANG_PROGRAM(
            [[#include <unistd.h>
+             #include <stdio.h>
            ]],
            [[int result = 0;
              if (!link ("conftest.a", "conftest.b/"))