New module 'unicase/ulc-casecoll'.
[pspp] / lib / dirent.in.h
index 40824c56b7bb1702003e14b63be291d8a74821b6..15f0245b0929efa68b39f57123ae1e9ba2daf0d9 100644 (file)
@@ -76,6 +76,19 @@ extern int scandir (const char *dir, struct dirent ***namelist,
      scandir (d, n, f, c))
 #endif
 
+#if @GNULIB_ALPHASORT@
+/* Compare two 'struct dirent' entries alphabetically.  */
+# if !@HAVE_ALPHASORT@
+extern int alphasort (const struct dirent **, const struct dirent **);
+# endif
+#elif defined GNULIB_POSIXCHECK
+# undef alphasort
+# define alphasort(a,b) \
+    (GL_LINK_WARNING ("alphasort is unportable - " \
+                      "use gnulib module alphasort for portability"), \
+     alphasort (a, b))
+#endif
+
 #ifdef __cplusplus
 }
 #endif