RFA: Fix basename function detection in cgen-cpu configure script
The port of SID to the MIPS target is failing to build in an
integrated source tree (one with include/libiberty.h) on a 32-bit
host, because of this compile time error:
/usr/include/string.h:602: error: new declaration 'const char* basename(const char*)'
.../include/libiberty.h:106: error: ambiguates old declaration 'char* basename(const char*)'
I traced this down to the fact that HAVE_DECL_BASENAME is defined to 0
in the config.h file in the sid/component/cgen-cpu build directory.
This macro should be defined to 1, but the test run by the configure
script is failing to compile because of this error:
conftest.cc:41: error: overloaded function with no contextual type information
This is line 41 of the conftest.cc file:
char *(*pfn) = (char *(*)) basename ;
The error is happening because G++ now complains about function
pointer casts without parameter type information. To fix the problem
it is necessary to add a parameter type like this: