summaryrefslogtreecommitdiffstats
path: root/newlib/libc/include/dirent.h
diff options
context:
space:
mode:
authorYaakov Selkowitz <yselkowi@redhat.com>2016-03-14 16:17:38 -0500
committerYaakov Selkowitz <yselkowi@redhat.com>2016-03-17 21:08:51 -0500
commitd2937299fad043fa91cdf7f56eef914558be4077 (patch)
tree52e6ad5760f6b7ef66d48e9ae60237639f7a01b0 /newlib/libc/include/dirent.h
parent575608b2021227f51beaf286cf71a27f4616cdcf (diff)
downloadcygnal-d2937299fad043fa91cdf7f56eef914558be4077.tar.gz
cygnal-d2937299fad043fa91cdf7f56eef914558be4077.tar.bz2
cygnal-d2937299fad043fa91cdf7f56eef914558be4077.zip
Feature test macros overhaul: dirent.h
MAXNAMLEN is a BSDism. Use the proper internal macros instead of !_POSIX_SOURCE. telldir and seekdir are XSI, scandir and alphasort are POSIX.1-2008, and scandirat is GNU. Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>
Diffstat (limited to 'newlib/libc/include/dirent.h')
-rw-r--r--newlib/libc/include/dirent.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/newlib/libc/include/dirent.h b/newlib/libc/include/dirent.h
index 6fefc03cb..6135b9f6e 100644
--- a/newlib/libc/include/dirent.h
+++ b/newlib/libc/include/dirent.h
@@ -3,9 +3,10 @@
#ifdef __cplusplus
extern "C" {
#endif
+#include <sys/cdefs.h>
#include <sys/dirent.h>
-#if !defined(MAXNAMLEN) && !defined(_POSIX_SOURCE)
+#if !defined(MAXNAMLEN) && __BSD_VISIBLE
#define MAXNAMLEN 1024
#endif