From e910826c812fcde8d122990a1e43e17f46b6d03f Mon Sep 17 00:00:00 2001 From: Elliott Hughes Date: Sun, 18 Jan 2015 13:36:31 -0600 Subject: [PATCH] fix non-glibc basename(3) usage I considered a #else on the big #ifdef __GLIBC__ above, but that seemed harder to follow. --- lib/portability.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/portability.h b/lib/portability.h index f6f7672..bb1f5ae 100644 --- a/lib/portability.h +++ b/lib/portability.h @@ -141,6 +141,11 @@ int utimensat(int fd, const char *path, const struct timespec times[2], int flag #endif +#ifndef __GLIBC__ +// POSIX basename. +#include +#endif + #ifdef __MUSL__ #include // Without this "rm -r dir" fails with "is directory". -- 2.7.4