From 182997ba0074a9e2d0f1c9780ed3baef938f7aaa Mon Sep 17 00:00:00 2001 From: "Kevin M. Rosenberg" Date: Thu, 11 May 2000 01:04:44 +0000 Subject: [PATCH] r48: Added Microsoft Windows compatibility --- include/ct.h | 15 ++++++++++++++- include/kstddef.h | 7 +++++-- 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/include/ct.h b/include/ct.h index 5e66c29..79c6ec8 100644 --- a/include/ct.h +++ b/include/ct.h @@ -2,8 +2,11 @@ ** This is part of the CTSim program ** Copyright (C) 1983-2000 Kevin Rosenberg ** -** $Id: ct.h,v 1.4 2000/05/03 19:51:41 kevin Exp $ +** $Id: ct.h,v 1.5 2000/05/11 01:04:44 kevin Exp $ ** $Log: ct.h,v $ +** Revision 1.5 2000/05/11 01:04:44 kevin +** Added Microsoft Windows compatibility +** ** Revision 1.4 2000/05/03 19:51:41 kevin ** function renaming for phantoms and phantom elements ** @@ -34,6 +37,16 @@ #ifndef CT_H #define CT_H +#ifdef _WIN32 +typedef long off_t; +#define HAVE_STRING_H 1 +#include +#define snprintf _snprintf +#define vsnprintf _vsnprintf +#define strcasecmp stricmp +#define strncasecmp strnicmp +#endif + #ifdef HAVE_CONFIG_H #include #endif diff --git a/include/kstddef.h b/include/kstddef.h index deb65fa..7b19338 100644 --- a/include/kstddef.h +++ b/include/kstddef.h @@ -2,8 +2,11 @@ ** This is part of the CTSim program ** Copyright (C) 1983-2000 Kevin Rosenberg ** -** $Id: kstddef.h,v 1.8 2000/05/08 20:00:48 kevin Exp $ +** $Id: kstddef.h,v 1.9 2000/05/11 01:04:44 kevin Exp $ ** $Log: kstddef.h,v $ +** Revision 1.9 2000/05/11 01:04:44 kevin +** Added Microsoft Windows compatibility +** ** Revision 1.8 2000/05/08 20:00:48 kevin ** ANSI C changes ** @@ -150,8 +153,8 @@ typedef struct timedate_st TIMEDATE; /*----------------------------------------------------------------------*/ -/* codes for open command */ +/* codes for open command */ #if MICROSOFT #define OPEN_RDONLY O_RDONLY /* other system use standard codes */ #define OPEN_WRONLY O_WRONLY /* for binary */ -- 2.34.1