Import Upstream version 1.8.5
[hcoop/debian/openafs.git] / src / config / param.i64_w2k.h
1 #ifndef UKERNEL
2 /* This section for kernel libafs compiles only */
3
4 /*
5 * Copyright 2000, International Business Machines Corporation and others.
6 * All Rights Reserved.
7 *
8 * This software has been released under the terms of the IBM Public
9 * License. For details, see the LICENSE file in the top-level source
10 * directory or online at http://www.openafs.org/dl/license10.html
11 */
12
13 #ifndef AFS_PARAM_H
14 #define AFS_PARAM_H
15
16
17 #define AFS_NT40_ENV 1
18 #define AFSLITTLE_ENDIAN 1
19 #define AFS_64BIT_IOPS_ENV 1
20 #define AFS_NAMEI_ENV 1 /* User space interface to file system */
21 #define AFS_HAVE_STATVFS 0 /* System doesn't support statvfs */
22 #define HAVE_INT64TOINT32 1
23
24 #include <afs/afs_sysnames.h>
25 #define SYS_NAME_ID SYS_NAME_ID_i64_w2k
26
27 #include <stdlib.h>
28 #include <string.h>
29 #include <stddef.h>
30
31 /*
32 * NT makes size_t a typedef for unsigned int (e.g. in <stddef.h>)
33 * and has no typedef for ssize_t (a signed size_t).
34 * So, we make our own.
35 */
36 typedef __int64 ssize_t;
37
38 /* these macros define Unix-style functions missing in VC++5.0/NT4.0 */
39 #define MAXPATHLEN _MAX_PATH
40
41 /* map lstat calls to _stat, until an AFS-aware lstat wrapper
42 * can be written */
43 #if (_MSC_VER < 1400)
44 #define lstat(a, b) _stat((a), (struct _stat *)(b))
45 #else
46 #ifdef _USE_32BIT_TIME_T
47 #define lstat(a, b) _stat((a), (struct _stat32 *)(b))
48 #else
49 #define lstat(a, b) _stat((a), (struct _stat64i32 *)(b))
50 #endif
51 #endif
52
53 #define strcasecmp(s1,s2) _stricmp(s1,s2)
54 #define strncasecmp(s1,s2,n) _strnicmp(s1,s2,n)
55 #define sleep(seconds) Sleep((seconds) * 1000)
56 #define fsync(fileno) _commit(fileno)
57 #define ftruncate(fd, size) _chsize((fd), (long)(size))
58
59 #define random() rand()
60 #define srandom(a) srand(a)
61
62 #define popen(cmd, mode) _popen((cmd), (mode))
63 #define pclose(stream) _pclose(stream)
64 typedef char *caddr_t;
65
66 #define pipe(fdp) _pipe(fdp, 4096, _O_BINARY)
67
68 #define snprintf _snprintf
69 #endif /* AFS_PARAM_H */
70
71 #else /* !defined(UKERNEL) */
72
73 /* This section for user space compiles only */
74
75
76 #endif /* !defined(UKERNEL) */