https://sourceware.org/bugzilla/show_bug.cgi?id=18022
Bug ID: 18022 Summary: change in libiberty.h prevents compilation by IBM C compiler Product: binutils Version: 2.25 Status: NEW Severity: critical Priority: P2 Component: admin Assignee: unassigned at sourceware dot org Reporter: aixtools at gmail dot com I was able to compile and build binutils-2.24 without any real issues. However, version 2.25 will not build. make stops with the following error Details: +103 /* HAVE_DECL_* is a three-state macro: undefined, 0 or 1. If it is +104 undefined, we haven't run the autoconf check so provide the +105 declaration without arguments. If it is 0, we checked and failed +106 to find the declaration so provide a fully prototyped one. If it +107 is 1, we found it so don't provide any declaration at all. */ +108 #if !HAVE_DECL_BASENAME +109 #if defined (__GNU_LIBRARY__ ) || defined (__linux__) \ +110 || defined (__FreeBSD__) || defined (__OpenBSD__) || defined (__NetBSD__) \ +111 || defined (__CYGWIN__) || defined (__CYGWIN32__) || defined (__MINGW32__) \ +112 || defined (__DragonFly__) || defined (HAVE_DECL_BASENAME) +113 extern char *basename (const char *) ATTRIBUTE_RETURNS_NONNULL ATTRIBUTE_NONNULL(1); +114 #else +115 /* Do not allow basename to be used if there is no prototype seen. We +116 either need to use the above prototype or have one from +117 autoconf which would result in HAVE_DECL_BASENAME being set. */ +118 #define basename basename_cannot_be_used_without_a_prototype +119 #endif +120 #endif The important part of the diff for this file between 2.24 and 2.25 is: --- ./binutils-2.24/include/libiberty.h 2013-11-04 15:33:39 +0000 +++ ./binutils-2.25/include/libiberty.h 2014-10-14 07:32:04 +0000 ... @@ -106,8 +106,11 @@ to find the declaration so provide a fully prototyped one. If it is 1, we found it so don't provide any declaration at all. */ #if !HAVE_DECL_BASENAME -#if defined (__GNU_LIBRARY__ ) || defined (__linux__) || defined (__FreeBSD__) || defined (__OpenBSD__) || defined(__NetBSD__) || defined (__CYGWIN__) || defined (__CYGWIN32__) || defined (__MINGW32__) || defined (HAVE_DECL_BASENAME) -extern char *basename (const char *); +#if defined (__GNU_LIBRARY__ ) || defined (__linux__) \ + || defined (__FreeBSD__) || defined (__OpenBSD__) || defined (__NetBSD__) \ + || defined (__CYGWIN__) || defined (__CYGWIN32__) || defined (__MINGW32__) \ + || defined (__DragonFly__) || defined (HAVE_DECL_BASENAME) +extern char *basename (const char *) ATTRIBUTE_RETURNS_NONNULL ATTRIBUTE_NONNULL(1); #else /* Do not allow basename to be used if there is no prototype seen. We either need to use the above prototype or have one from ... Hopefully, this will not be too difficult to correct. If you need any additional info (e.g., config.log) - just ask. Michael -- You are receiving this mail because: You are on the CC list for the bug. _______________________________________________ bug-binutils mailing list bug-binutils@gnu.org https://lists.gnu.org/mailman/listinfo/bug-binutils