Commit 9c3af039 authored by Jonas Termansen's avatar Jonas Termansen

Fix <stdio.h> pulling in <pthread.h> through <FILE.h> when __is_sortix_libc.

parent b8a330af
......@@ -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>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment