+2005-12-13 Michael Poole <mdpoole@troilus.org>
+
+ * configure.in: Define a macro when compiling on Solaris.
+
+ * ircd/ircd_crypt_native.c (_XOPEN_SOURCE): Turn down to 500 so
+ that Solaris doesn't complain that SUSv3 requires C99.
+
+ * ircd/os_generic.c (_XOPEN_SOURCE): Likewise, but leave it at 600
+ on non-Solaris platforms so that IPv6 stays supported.
+
2005-12-13 Michael Poole <mdpoole@troilus.org>
* ircd/m_join.c (ms_join): Prevent net rides allowed by moving the
else
unet_poll_syscall=no
fi
+ AC_DEFINE([IRCU_SOLARIS], 1, [Define if building on Solaris])
;;
*-sunos*)
* function (typically a DES encryption routine, but can be anything nowadays).
*
*/
-#define _XOPEN_SOURCE 600
+#define _XOPEN_SOURCE 500
#include "config.h"
#include "ircd_crypt.h"
*/
#include "config.h"
-#define _XOPEN_SOURCE 600 /**< make limits.h #define IOV_MAX */
-#define __EXTENSIONS__ 1 /**< make Solaris netinet/in.h know IPv6 */
+#ifdef IRCU_SOLARIS
+/* Solaris requires C99 support for SUSv3, but C99 support breaks other
+ * parts of the build. So fall back to SUSv2, but request IPv6 support
+ * by defining __EXTENSIONS__.
+ */
+#define _XOPEN_SOURCE 500
+#define __EXTENSIONS__ 1
+#else
+/* FreeBSD 6.0 requires SUSv3 to support IPv6. Apparently some other
+ * OS requires SUSv3 to define IOV_MAX, but its identity is lost for
+ * the time being.
+ */
+#define _XOPEN_SOURCE 600
+#endif
#include "ircd_osdep.h"
#include "msgq.h"