preliminaries to adding POSIX semaphores

This commit is contained in:
Rich Felker 2011-03-03 18:32:26 -05:00
parent b480808a6a
commit 03dcc3417c
2 changed files with 8 additions and 1 deletions

View File

@ -29,6 +29,7 @@
#define PTHREAD_KEYS_MAX 1024
#define PTHREAD_STACK_MIN PAGE_SIZE
#define PTHREAD_DESTRUCTOR_ITERATIONS 4
#define SEM_VALUE_MAX 0x7fffffff
/* Arbitrary numbers... */

View File

@ -4,10 +4,16 @@
extern "C" {
#endif
#define __NEED_time_t
#define __NEED_struct_timespec
#include <bits/alltypes.h>
#include <fcntl.h>
#define SEM_FAILED ((sem_t *)0)
typedef struct {
long __val[4];
int __val[4*sizeof(long)/sizeof(int)];
} sem_t;
int sem_close(sem_t *);