Include py_curses.h *after* defining _XOPEN_SOURCE_EXTENDED.
authorGuido van Rossum <guido@python.org>
Tue, 10 Apr 2001 19:53:37 +0000 (19:53 +0000)
committerGuido van Rossum <guido@python.org>
Tue, 10 Apr 2001 19:53:37 +0000 (19:53 +0000)
Michael Hudson suggested this fox for the Tru64 problem (SF bug
232597).  It looks reasonable, it works on Tru64, and it doesn't beak
anything on Linux, so I say go for it.

Modules/_cursesmodule.c

index aa0b4f08ce20d501741f8aa6cc07f7116d55270a..0cc04370c3c0d61e0efaf4e54c3c8639805d1df8 100644 (file)
@@ -100,14 +100,15 @@ char *PyCursesVersion = "2.1";
 /* Includes */
 
 #include "Python.h"
-#define CURSES_MODULE
-#include "py_curses.h"
 
 #ifdef __osf__
 #define _XOPEN_SOURCE_EXTENDED  /* Define macro for OSF/1 */
 #define STRICT_SYSV_CURSES      /* Don't use ncurses extensions */
 #endif
 
+#define CURSES_MODULE
+#include "py_curses.h"
+
 /*  These prototypes are in <term.h>, but including this header 
     #defines many common symbols (such as "lines") which breaks the 
     curses module in other ways.  So the code will just specify