Move the sources to trunk
[opencv] / apps / cvenv / include / unistd.h
1 #ifndef UNISTDH_
2 #define UNISTDH_
3
4 #pragma push_safeptr
5
6 #include "sys/types.h"
7
8 /* Symbolic constants for the "access" routine: */
9 #define R_OK    4       /* Test for Read permission */
10 #define W_OK    2       /* Test for Write permission */
11 #define X_OK    1       /* Test for eXecute permission */
12 #define F_OK    0       /* Test for existence of File */
13
14 /* Standard file descriptors.  */
15 #define STDIN_FILENO    0       /* Standard input.  */
16 #define STDOUT_FILENO   1       /* Standard output.  */
17 #define STDERR_FILENO   2       /* Standard error output.  */
18
19
20 #ifndef SEEK_SET
21 #define SEEK_SET        0       /* Set file pointer to "offset" */
22 #endif
23
24 #ifndef SEEK_CUR
25 #define SEEK_CUR        1       /* Set file pointer to current plus "offset" */
26 #endif
27
28 #ifndef SEEK_END
29 #define SEEK_END        2       /* Set file pointer to EOF plus "offset" */
30 #endif
31
32 #ifndef NULL
33 #define NULL    (void*)0
34 #endif
35
36 int pause(void);
37 unsigned int alarm(unsigned int);
38 int access(const char *path, int mode);
39 int close(int handle);
40 int dup(int fd);
41 int dup2(int oldfd, int newfd);
42 pid_t fork(void);
43 int getpid(void);
44 int link(const char *oldpath, const char *newpath);
45 off_t lseek(int fildes, off_t offset, int whence);
46 int pipe(int *a);
47 ssize_t read(int fd, void  *buf, size_t count);
48 int rmdir(const char * path);
49 unsigned int sleep(unsigned int seconds);
50 int unlink(const char *fname);
51 ssize_t write(int fd, const void *buf, size_t count);
52 int chdir(const char *path);
53 char *getcwd(char *buf, size_t size);
54 pid_t tcgetpgrp(int);
55 int tcsetpgrp (int, pid_t);
56
57 #ifndef _EiC
58 /** not installed yet into EiC */
59 int execl(const char *s1, const char *s2, ...);
60
61 #endif
62
63 #pragma pop_ptr
64
65 #endif  /* end  UNISTDH_ */
66
67
68
69