Fix <stdio.h> pulling in <pthread.h> through <FILE.h> when __is_sortix_libc.
This commit is contained in:
parent
b8a330af3b
commit
9c3af039ca
3 changed files with 9 additions and 2 deletions
libc
|
@ -24,7 +24,7 @@
|
|||
|
||||
#include <sys/__/types.h>
|
||||
|
||||
#include <pthread.h>
|
||||
#include <__/pthread.h>
|
||||
|
||||
#if !defined(BUFSIZ)
|
||||
#include <stdio.h>
|
||||
|
@ -50,6 +50,11 @@ typedef __off_t off_t;
|
|||
typedef __ssize_t ssize_t;
|
||||
#endif
|
||||
|
||||
#ifndef __pthread_mutex_t_defined
|
||||
#define __pthread_mutex_t_defined
|
||||
typedef __pthread_mutex_t pthread_mutex_t;
|
||||
#endif
|
||||
|
||||
#ifndef __FILE_defined
|
||||
#define __FILE_defined
|
||||
typedef struct __FILE FILE;
|
||||
|
@ -94,7 +99,7 @@ struct __FILE
|
|||
/* Internally used by standard library. */
|
||||
#if defined(__is_sortix_libc)
|
||||
extern FILE* __first_file;
|
||||
extern __pthread_mutex_t __first_file_lock;
|
||||
extern pthread_mutex_t __first_file_lock;
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
|
|
@ -40,6 +40,7 @@
|
|||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <time.h>
|
||||
#include <timespec.h>
|
||||
|
||||
/* This implementation is adaptable to current computing power.
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
* After a FILE has been shut down, returns all fields to their default state.
|
||||
*/
|
||||
|
||||
#include <pthread.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
|
Loading…
Add table
Reference in a new issue