diff options
author | ph10 <ph10@2f5784b3-3f2a-0410-8824-cb99058d5e15> | 2008-04-21 16:30:37 +0000 |
---|---|---|
committer | ph10 <ph10@2f5784b3-3f2a-0410-8824-cb99058d5e15> | 2008-04-21 16:30:37 +0000 |
commit | c56899761c2908caab683fa89937860551c8652f (patch) | |
tree | 663a6fc70cf5ead9eb191b5cc092be77afbc944b | |
parent | 83ba2e28b44dd516ba5e7734a2f9972482a9214c (diff) | |
download | pcre-c56899761c2908caab683fa89937860551c8652f.tar.gz |
Fixes to pcretest for readline support on Windows.
git-svn-id: svn://vcs.exim.org/pcre/code/trunk@343 2f5784b3-3f2a-0410-8824-cb99058d5e15
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | pcretest.c | 5 |
2 files changed, 9 insertions, 0 deletions
@@ -93,6 +93,10 @@ Version 7.7 05-Mar-08 improvement to matching performance by compiling OP_ALLANY instead of OP_ANY for "." when DOTALL was set, and then removing the runtime tests on the OP_ANY path. + +17. Compiling pcretest on Windows with readline support failed without the + following two fixes: (1) Make the unistd.h include conditional on + HAVE_UNISTD_H; (2) #define isatty and fileno as _isatty and _fileno. Version 7.6 28-Jan-08 @@ -49,7 +49,9 @@ POSSIBILITY OF SUCH DAMAGE. #include <errno.h> #ifdef SUPPORT_LIBREADLINE +#ifdef HAVE_UNISTD_H #include <unistd.h> +#endif #include <readline/readline.h> #include <readline/history.h> #endif @@ -69,6 +71,9 @@ input mode under Windows. */ #define INPUT_MODE "r" #define OUTPUT_MODE "wb" +#define isatty _isatty /* This is what Windows calls them, I'm told */ +#define fileno _fileno + #else #include <sys/time.h> /* These two includes are needed */ #include <sys/resource.h> /* for setrlimit(). */ |