https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119218
--- Comment #2 from Iain Sandoe <iains at gcc dot gnu.org> --- it seems that liberty's declaration is in conflict with the POSIX one viz: https://pubs.opengroup.org/onlinepubs/9699919799/ has: [XSI] #include <libgen.h> char *dirname(char *path); Maybe there's a reason for the libiberty difference?