updated to minix 1.5

This commit is contained in:
ceriel 1991-09-03 12:00:30 +00:00
parent c44e30af8b
commit 7512bdd33b
6 changed files with 88 additions and 0 deletions

View file

@ -9,3 +9,4 @@ signal.h
string.h
time.h
utime.h
sys

View file

@ -0,0 +1,3 @@
dir.h
times.h
wait.h

View file

@ -0,0 +1,17 @@
/* The <dir.h> header gives the layout of a directory. */
#ifndef _DIR_H
#define _DIR_H
#define DIRBLKSIZ 512 /* size of directory block */
#ifndef DIRSIZ
#define DIRSIZ 14
#endif
struct direct {
ino_t d_ino;
char d_name[DIRSIZ];
};
#endif /* _DIR_H */

View file

@ -0,0 +1,26 @@
/* The <times.h> header is for time times() system call. */
#ifndef _TIMES_H
#define _TIMES_H
#ifndef _CLOCK_T
#define _CLOCK_T
typedef long clock_t; /* time in ticks since process started */
#endif
struct tms {
clock_t tms_utime;
clock_t tms_stime;
clock_t tms_cutime;
clock_t tms_cstime;
};
/* Function Prototypes. */
#ifndef _ANSI_H
#include <ansi.h>
#endif
_PROTOTYPE( clock_t times, (struct tms *_buffer) );
#endif /* _TIMES_H */

View file

@ -0,0 +1,40 @@
/* The <sys/wait.h> header contains macros related to wait(). The value
* returned by wait() and waitpid() depends on whether the process
* terminated by an exit() call, was killed by a signal, or was stopped
* due to job control, as follows:
*
* High byte Low byte
* +---------------------+
* exit(status) | status | 0 |
* +---------------------+
* killed by signal | 0 | signal |
* +---------------------+
* stopped (job control) | signal | 0177 |
* +---------------------+
*/
#ifndef _WAIT_H
#define _WAIT_H
#define _LOW(v) ( (v) & 0377)
#define _HIGH(v) ( ((v) >> 8) & 0377)
#define WNOHANG 1 /* do not wait for child to exit */
#define WUNTRACED 2 /* for job control; not implemented */
#define WIFEXITED(s) (_LOW(s) == 0) /* normal exit */
#define WEXITSTATUS(s) (_HIGH(s)) /* exit status */
#define WTERMSIG(s) (_LOW(s) & 0177) /* sig value */
#define WIFSIGNALED(s) (((unsigned int)(s)-1 & 0xFFFF) < 0xFF) /* signaled */
#define WIFSTOPPED(s) (_LOW(s) == 0177) /* stopped */
#define WSTOPSIG(s) (_HIGH(s) & 0377) /* stop signal */
/* Function Prototypes. */
#ifndef _ANSI_H
#include <ansi.h>
#endif
_PROTOTYPE( pid_t wait, (int *_stat_loc) );
_PROTOTYPE( pid_t waitpid, (pid_t _pid, int *_stat_loc, int _options) );
#endif /* _WAIT_H */

View file

@ -9,3 +9,4 @@ signal.h
string.h
time.h
utime.h
sys