From: Tony Jones Subject: Include libgen.h Upstream: yes Include libgen.h. This forces C++ to use xpg definition of basename which matches what libiberty expects (default is ISO C++ version in string.h) Otherwise build fails with: /usr/include/libiberty.h:105: error: new declaration char* basename(const char*) /usr/include/string.h:599: error: ambiguates old declaration const char* basename(const char*) --- oprofile-0.9.4/configure.in.orig 2009-04-08 13:43:42.000000000 -0400 +++ oprofile-0.9.4/configure.in 2009-04-08 13:43:45.000000000 -0400 @@ -15,6 +15,7 @@ AC_INIT(libop/op_config.h) AM_INIT_AUTOMAKE(oprofile, 0.9.4) AM_CONFIG_HEADER(config.h) +AC_CHECK_DECLS([basename], [], [], [[#include ]]) AC_PROG_RANLIB AC_PROG_LIBTOOL