Gerrit P. Haase wrote:
That being said, it is quite straightforward to build PDCurses for Cygwin and Mingw.
Then there should be an option for the user to decide whether she wants to use PD- or Ncurses.
Well, this option is just `USE_NCURSES'/`USE_PDCURSES' which I mentioned.
So, what your patch does is just to change the default under Cygwin from PDCurses to ncurses. I'd accept it if it's widely preferred (by Cygwin/GPC users), and/or ncurses is objectively better than PDCurses under Cygwin (less bugs, better performance, better support of special features, see comment in crt.pas, etc.).
I'll wait to hear of such preferences or evidence until I change anything.
What I meant in a previous mail is to automate this setting in the test suite. The affected test programs use a "curses detection" script, anyway, so it could set the respective flag. This will take a little effort (but probably not too much) in the scripts (crt.cmp etc.). Then at least the tests would work regardless of the default setting.
(BTW, your patch has a little problem: Due to the higher precedence of `&&' vs. `||' the `__CYGWIN__' test would only refer to `XCURSES'. And in fact the `&& !defined(__CYGWIN__)' is redundant since none of the other symbols should be defined on Cygwin, anyway.)
--- p/units/crt.inc~ 2003-10-07 22:56:39.884168000 +0200 +++ p/units/crt.inc 2003-10-07 22:56:45.512260800 +0200 @@ -449,7 +449,7 @@ #define X11 #endif #if !defined (USE_PDCURSES) && !defined (USE_NCURSES) -#if defined (MSDOS) || defined (_WIN32) || defined (__CYGWIN__) || defined (__EMX__) || defined (XCURSES) +#if defined (MSDOS) || defined (_WIN32) || defined (__EMX__) || defined (XCURSES) && !defined(__CYGWIN__) #define USE_PDCURSES #else #define USE_NCURSES
Frank