From 07065210cae8ae40fceeee4febf338e1f1aecd0c Mon Sep 17 00:00:00 2001 From: Rich Felker Date: Wed, 18 Jan 2012 23:28:48 -0500 Subject: [PATCH] alias basename to glibc name for it, to meet abi goals note that regardless of the name used, basename is always conformant. it never takes on the bogus gnu behavior, unlike glibc where basename is nonconformant when declared manually without including libgen.h. --- src/misc/basename.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/misc/basename.c b/src/misc/basename.c index c87e00cd..cc4f778c 100644 --- a/src/misc/basename.c +++ b/src/misc/basename.c @@ -1,5 +1,6 @@ #include #include +#include "libc.h" char *basename(char *s) { @@ -10,3 +11,5 @@ char *basename(char *s) for (; i&&s[i-1]!='/'; i--); return s+i; } + +weak_alias(basename, __xpg_basename); -- 2.25.1