diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index 3afc779ce90d..60fb328c9a87 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -38,6 +38,8 @@ # xargs -n1 | sort | uniq -d; # done +# 20171208: Remove basename_r(3) +OLD_FILES+=usr/share/man/man3/basename_r.3.gz # 20171204: Move fdformat man page from volume 1 to volume 8. OLD_FILES+=usr/share/man/man1/fdformat.1.gz # 20171203: libproc version bump diff --git a/include/libgen.h b/include/libgen.h index ffbb77f3ed6b..615d1dd6202e 100644 --- a/include/libgen.h +++ b/include/libgen.h @@ -37,7 +37,6 @@ __BEGIN_DECLS char *basename(char *); -char *basename_r(const char *, char *); char *dirname(char *); __END_DECLS diff --git a/lib/libc/gen/Makefile.inc b/lib/libc/gen/Makefile.inc index b8a969276c5e..d6e73ecaf087 100644 --- a/lib/libc/gen/Makefile.inc +++ b/lib/libc/gen/Makefile.inc @@ -312,7 +312,6 @@ MLINKS+=arc4random.3 arc4random_addrandom.3 \ arc4random.3 arc4random_stir.3 \ arc4random.3 arc4random_buf.3 \ arc4random.3 arc4random_uniform.3 -MLINKS+=basename.3 basename_r.3 MLINKS+=ctermid.3 ctermid_r.3 MLINKS+=devname.3 devname_r.3 MLINKS+=devname.3 fdevname.3 diff --git a/lib/libc/gen/Symbol.map b/lib/libc/gen/Symbol.map index 459657cf4535..d11815c05fa3 100644 --- a/lib/libc/gen/Symbol.map +++ b/lib/libc/gen/Symbol.map @@ -332,7 +332,6 @@ FBSD_1.1 { }; FBSD_1.2 { - basename_r; cfmakesane; endutxent; getpagesizes; diff --git a/lib/libc/gen/basename_compat.c b/lib/libc/gen/basename_compat.c index f6ce7f9a1f43..282cc6fd4923 100644 --- a/lib/libc/gen/basename_compat.c +++ b/lib/libc/gen/basename_compat.c @@ -26,7 +26,7 @@ __FBSDID("$FreeBSD$"); #include char * -basename_r(const char *path, char *bname) +__freebsd11_basename_r(const char *path, char *bname) { const char *endp, *startp; size_t len; @@ -75,7 +75,8 @@ __freebsd11_basename(char *path) if (bname == NULL) return (NULL); } - return (basename_r(path, bname)); + return (__freebsd11_basename_r(path, bname)); } +__sym_compat(basename_r, __freebsd11_basename_r, FBSD_1.2); __sym_compat(basename, __freebsd11_basename, FBSD_1.0);