Commit aeee8c09 authored by rswindell's avatar rswindell
Browse files

Kludges necessary for Cygwin compile (why? I have no idea...)

parent e7b34865
......@@ -43,7 +43,7 @@
/* Compensates for struct tm "weirdness" */
time_t sane_mktime(struct tm*);
#if defined(__BORLANDC__)
#if defined(__BORLANDC__) || defined(__CYGWIN__)
#define timezone _timezone
#endif
......
......@@ -67,6 +67,10 @@ extern "C" {
#include <glob.h> /* POSIX.2 directory pattern matching function */
#define MKDIR(dir) mkdir(dir,0777)
#if defined(__CYGWIN__)
#define DLLEXPORT /* CygWin's glob.h #undef's DLLEXPORT */
#endif
#else
#include <direct.h> /* mkdir() */
......
......@@ -80,8 +80,10 @@
#include <share.h>
#define L_SET SEEK_SET
#else
#ifndef O_TEXT
#define O_TEXT 0 /* all files in binary mode on Unix */
#define O_BINARY 0 /* all files in binary mode on Unix */
#endif
#undef O_DENYNONE
#define O_DENYNONE (1<<31) /* req'd for Baja/nopen compatibility */
......
......@@ -259,7 +259,7 @@ void DLLCALL unix_beep(int freq, int dur)
}
#endif
#if !defined(__GNU__) && !defined(__QNX__) && !defined(__OpenBSD__) && !defined(__NetBSD__) && !defined(__APPLE__)
#if !defined(__GNU__) && !defined(__QNX__) && !defined(__OpenBSD__) && !defined(__NetBSD__) && !defined(__APPLE__) && !defined(__CYGWIN__)
if(console_fd == -1)
console_fd = open("/dev/console", O_NOCTTY);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment