Hi!

I've made a small patch to make it possible to enable BSD extensions
although _POSIX_SOURCE, _POSIX_C_SOURCE or _XOPEN_SOURCE has been
defined. This is made with a new define _BSD_SOURCE right after the 
XOPEN_SOURCE handling. It sets __XSI_VISIBLE 600 and __BSD_VISIBLE 1.
This is needed for some programs. For example for Python 2.3cvs sets
(among others) _POSIX_C_SOURCE 199506L, but also expects to have chroot
and friends.

Regards,
Marc


--- cdefs.h.orig        Tue Oct 22 11:44:42 2002
+++ cdefs.h     Mon Nov 11 12:47:49 2002
@@ -333,6 +333,12 @@
 #endif
 #endif
 
+/* Allow BSD extensions to POSIX. */
+#if defined(_BSD_SOURCE) && (defined(_POSIX_SOURCE) || defined(_POSIX_C_SOURCE))
+#define        __XSI_VISIBLE           600
+#define        __BSD_VISIBLE           1
+#endif
+
 /*
  * Deal with all versions of POSIX.  The ordering relative to the tests above is
  * important.

Reply via email to