summaryrefslogtreecommitdiff
path: root/Build/source/texk/kpathsea/win32lib.h
blob: beaf9f8d5cd4e87579764524bdee2c6989e84b10 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/* Public domain.  */

#ifndef _WIN32LIB_H_
#define _WIN32LIB_H_

#if !__STDC__
#if _MSC_VER>=1200
   #pragma warning(push)
#endif
#pragma warning(disable: 4668)
#pragma warning(disable: 4255)

#define boolean donotuse_boolean
#include <windows.h>	/* Somewhere here WIN32 gets defined */
#undef boolean

#if _MSC_VER>=1200
   #pragma warning(pop)
#else 
   #pragma warning(default: 4668)
   #pragma warning(default: 4255)
#endif

#else /*__STDC__*/
/* non-ansi definitions for an ANSI compliation with /Fa */
#define WIN32
#define off_t _off_t
#define putenv _putenv
#define getcwd _getcwd
#define getcw _getcw
#define putenv _putenv
#define strdup _strdup
#define vsnprintf _vsnprintf
#define fileno _fileno
#define strlwr _strlwr
#define isascii __isascii
#define mkdir _mkdir
#define stat _stat
#define stricmp _stricmp
#define MAX_PATH _MAX_PATH
#define S_IFREG _S_IFREG
#define S_IFMT _S_IFMT

#endif /*__STDC__*/

/*This is not defined even if !__STDC__*/
#define snprintf _snprintf

/*The gnu name is different*/
#define strcasecmp stricmp

#endif