#include #include #include #include #include #include #include #include /* Modula-2 foreign module: DEFINITION MODULE FOR "C" Posix. Symbol naming: _ (as generated by GNU Modula-2). */ long Posix_read(int fd, void *buf, unsigned long n) { return read(fd, buf, n); } long Posix_write(int fd, void *buf, unsigned long n) { return write(fd, buf, n); } int Posix_open(void *path, int oflag, unsigned long mode) { return open(path, oflag, (mode_t)mode); } int Posix_close(int fd) { return close(fd); } int Posix_unlink(void *path) { return unlink(path); } int Posix_rename(void *oldp, void *newp) { return rename(oldp, newp); } void *Posix_getcwd(void *buf, unsigned long size) { return getcwd(buf, size); } int Posix_chdir(void *path) { return chdir(path); } void *Posix_opendir(void *path) { return opendir(path); } void *Posix_readdir(void *d) { return readdir(d); } int Posix_closedir(void *d) { return closedir(d); } int Posix_statvfs(void *path, void *buf) { return statvfs(path, buf); } int Posix_tcgetattr(int fd, void *t) { return tcgetattr(fd, (struct termios *)t); } int Posix_tcsetattr(int fd, int opt, void *t) { return tcsetattr(fd, opt, (struct termios *)t); } void Posix_cfmakeraw(void *t) { cfmakeraw((struct termios *)t); } int Posix_poll(void *fds, unsigned long nfds, int timeout) { return poll(fds, nfds, timeout); }