Cthulhu  0.2.10
Cthulhu compiler collection
os.inc
Go to the documentation of this file.
1 // SPDX-License-Identifier: LGPL-3.0-only
2 
3 #ifndef OS_ACCESS
4 # define OS_ACCESS(id, str, value)
5 #endif
6 
7 OS_ACCESS(eOsAccessNone, "none", 0)
8 OS_ACCESS(eOsAccessRead, "read", (1 << 0))
9 OS_ACCESS(eOsAccessWrite, "write", (1 << 1))
10 OS_ACCESS(eOsAccessTruncate, "truncate", (1 << 2))
11 
12 #undef OS_ACCESS
13 
14 #ifndef OS_PROTECT
15 # define OS_PROTECT(id, str, value)
16 #endif
17 
18 OS_PROTECT(eOsProtectNone, "none", 0)
19 OS_PROTECT(eOsProtectRead, "read", (1 << 0))
20 OS_PROTECT(eOsProtectWrite, "write", (1 << 1))
21 OS_PROTECT(eOsProtectExecute, "execute", (1 << 2))
22 
23 #undef OS_PROTECT
24 
25 #ifndef OS_DIRENT
26 # define OS_DIRENT(id, str)
27 #endif
28 
29 OS_DIRENT(eOsNodeNone, "unknown")
30 OS_DIRENT(eOsNodeFile, "file")
31 OS_DIRENT(eOsNodeDir, "directory")
32 OS_DIRENT(eOsNodeError, "error")
33 
34 #undef OS_DIRENT
#define OS_DIRENT(id, str)
Definition: os.inc:32
#define OS_ACCESS(id, str, value)
Definition: os.inc:4
#define OS_PROTECT(id, str, value)
Definition: os.inc:18