2012-09-28 22:36:46 +00:00
|
|
|
/*******************************************************************************
|
2011-08-05 12:25:00 +00:00
|
|
|
|
2013-01-09 15:07:27 +00:00
|
|
|
Copyright(C) Jonas 'Sortie' Termansen 2011, 2012, 2013.
|
2011-08-05 12:25:00 +00:00
|
|
|
|
2013-07-10 13:26:01 +00:00
|
|
|
This file is part of the Sortix C Library.
|
2011-08-05 12:25:00 +00:00
|
|
|
|
2013-07-10 13:26:01 +00:00
|
|
|
The Sortix C Library is free software: you can redistribute it and/or modify
|
|
|
|
it under the terms of the GNU Lesser General Public License as published by
|
|
|
|
the Free Software Foundation, either version 3 of the License, or (at your
|
|
|
|
option) any later version.
|
2011-08-05 12:25:00 +00:00
|
|
|
|
2013-07-10 13:26:01 +00:00
|
|
|
The Sortix C Library is distributed in the hope that it will be useful, but
|
|
|
|
WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
|
|
|
or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
|
|
|
|
License for more details.
|
2011-08-05 12:25:00 +00:00
|
|
|
|
2013-07-10 13:26:01 +00:00
|
|
|
You should have received a copy of the GNU Lesser General Public License
|
|
|
|
along with the Sortix C Library. If not, see <http://www.gnu.org/licenses/>.
|
2011-08-05 12:25:00 +00:00
|
|
|
|
2013-07-10 13:26:01 +00:00
|
|
|
sys/types.h
|
|
|
|
Data types.
|
2011-08-05 12:25:00 +00:00
|
|
|
|
2012-09-28 22:36:46 +00:00
|
|
|
*******************************************************************************/
|
2011-08-05 12:25:00 +00:00
|
|
|
|
2013-04-21 20:46:44 +00:00
|
|
|
#ifndef INCLUDE_SYS_TYPES_H
|
|
|
|
#define INCLUDE_SYS_TYPES_H
|
2011-08-05 12:25:00 +00:00
|
|
|
|
2013-10-13 11:04:27 +00:00
|
|
|
#include <sys/cdefs.h>
|
2013-09-23 14:37:33 +00:00
|
|
|
|
2013-01-16 00:45:51 +00:00
|
|
|
#include <sys/__/types.h>
|
2013-08-31 11:15:53 +00:00
|
|
|
#if __STDC_HOSTED__
|
|
|
|
#include <__/pthread.h>
|
|
|
|
#endif
|
2011-08-05 12:25:00 +00:00
|
|
|
|
|
|
|
__BEGIN_DECLS
|
|
|
|
|
2013-12-27 00:44:03 +00:00
|
|
|
#ifndef __blkcnt_t_defined
|
|
|
|
#define __blkcnt_t_defined
|
|
|
|
typedef __blkcnt_t blkcnt_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __blksize_t_defined
|
|
|
|
#define __blksize_t_defined
|
|
|
|
typedef __blksize_t blksize_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __clock_t_defined
|
|
|
|
#define __clock_t_defined
|
|
|
|
typedef __clock_t clock_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __clockid_t_defined
|
|
|
|
#define __clockid_t_defined
|
|
|
|
typedef __clockid_t clockid_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __dev_t_defined
|
|
|
|
#define __dev_t_defined
|
|
|
|
typedef __dev_t dev_t;
|
|
|
|
#endif
|
|
|
|
|
2013-12-29 22:03:11 +00:00
|
|
|
#ifndef __fsblkcnt_t_defined
|
|
|
|
#define __fsblkcnt_t_defined
|
|
|
|
typedef __fsblkcnt_t fsblkcnt_t;
|
|
|
|
#endif
|
2013-12-27 00:44:03 +00:00
|
|
|
|
2013-12-29 22:03:11 +00:00
|
|
|
#ifndef __fsfilcnt_t_defined
|
|
|
|
#define __fsfilcnt_t_defined
|
|
|
|
typedef __fsfilcnt_t fsfilcnt_t;
|
|
|
|
#endif
|
2013-12-27 00:44:03 +00:00
|
|
|
|
|
|
|
#ifndef __gid_t_defined
|
|
|
|
#define __gid_t_defined
|
|
|
|
typedef __gid_t gid_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __id_t_defined
|
|
|
|
#define __id_t_defined
|
|
|
|
typedef __id_t id_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __ino_t_defined
|
|
|
|
#define __ino_t_defined
|
|
|
|
typedef __ino_t ino_t;
|
|
|
|
#endif
|
|
|
|
|
2012-03-12 01:00:00 +00:00
|
|
|
/* TODO: key_t */
|
2013-12-27 00:44:03 +00:00
|
|
|
|
|
|
|
#ifndef __mode_t_defined
|
|
|
|
#define __mode_t_defined
|
|
|
|
typedef __mode_t mode_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __nlink_t_defined
|
|
|
|
#define __nlink_t_defined
|
|
|
|
typedef __nlink_t nlink_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __off_t_defined
|
|
|
|
#define __off_t_defined
|
|
|
|
typedef __off_t off_t;
|
|
|
|
#endif
|
2013-12-29 22:12:32 +00:00
|
|
|
#if defined(__is_sortix_kernel) || defined(__is_sortix_libc)
|
|
|
|
#define OFF_MIN __OFF_MIN
|
|
|
|
#define OFF_MAX __OFF_MAX
|
|
|
|
#endif
|
2013-12-27 00:44:03 +00:00
|
|
|
|
|
|
|
#ifndef __pid_t_defined
|
|
|
|
#define __pid_t_defined
|
|
|
|
typedef __pid_t pid_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __size_t_defined
|
|
|
|
#define __size_t_defined
|
|
|
|
#define __need_size_t
|
|
|
|
#include <stddef.h>
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __ssize_t_defined
|
|
|
|
#define __ssize_t_defined
|
|
|
|
typedef __ssize_t ssize_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __suseconds_t_defined
|
|
|
|
#define __suseconds_t_defined
|
|
|
|
typedef __suseconds_t suseconds_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __time_t_defined
|
|
|
|
#define __time_t_defined
|
|
|
|
typedef __time_t time_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __timer_t_defined
|
|
|
|
#define __timer_t_defined
|
|
|
|
typedef __timer_t timer_t;
|
|
|
|
#endif
|
|
|
|
|
2012-03-12 01:00:00 +00:00
|
|
|
/* TODO: trace*_t */
|
2013-12-27 00:44:03 +00:00
|
|
|
|
|
|
|
#ifndef __uid_t_defined
|
|
|
|
#define __uid_t_defined
|
|
|
|
typedef __uid_t uid_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __useconds_t_defined
|
|
|
|
#define __useconds_t_defined
|
|
|
|
typedef __useconds_t useconds_t;
|
|
|
|
#endif
|
2011-08-05 12:25:00 +00:00
|
|
|
|
2013-08-31 11:15:53 +00:00
|
|
|
#if __STDC_HOSTED__
|
|
|
|
|
|
|
|
#ifndef __pthread_attr_t_defined
|
|
|
|
#define __pthread_attr_t_defined
|
|
|
|
typedef __pthread_attr_t pthread_attr_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __pthread_barrier_t_defined
|
|
|
|
#define __pthread_barrier_t_defined
|
|
|
|
typedef __pthread_barrier_t pthread_barrier_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __pthread_barrierattr_t_defined
|
|
|
|
#define __pthread_barrierattr_t_defined
|
|
|
|
typedef __pthread_barrierattr_t pthread_barrierattr_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __pthread_cond_t_defined
|
|
|
|
#define __pthread_cond_t_defined
|
|
|
|
typedef __pthread_cond_t pthread_cond_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __pthread_condattr_t_defined
|
|
|
|
#define __pthread_condattr_t_defined
|
|
|
|
typedef __pthread_condattr_t pthread_condattr_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __pthread_key_t_defined
|
|
|
|
#define __pthread_key_t_defined
|
|
|
|
typedef __pthread_key_t pthread_key_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __pthread_mutex_t_defined
|
|
|
|
#define __pthread_mutex_t_defined
|
|
|
|
typedef __pthread_mutex_t pthread_mutex_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __pthread_mutexattr_t_defined
|
|
|
|
#define __pthread_mutexattr_t_defined
|
|
|
|
typedef __pthread_mutexattr_t pthread_mutexattr_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __pthread_once_t_defined
|
|
|
|
#define __pthread_once_t_defined
|
|
|
|
typedef __pthread_once_t pthread_once_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __pthread_rwlock_t_defined
|
|
|
|
#define __pthread_rwlock_t_defined
|
|
|
|
typedef __pthread_rwlock_t pthread_rwlock_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __pthread_rwlockattr_t_defined
|
|
|
|
#define __pthread_rwlockattr_t_defined
|
|
|
|
typedef __pthread_rwlockattr_t pthread_rwlockattr_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __pthread_spinlock_t_defined
|
|
|
|
#define __pthread_spinlock_t_defined
|
|
|
|
typedef __pthread_spinlock_t pthread_spinlock_t;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef __pthread_t_defined
|
|
|
|
#define __pthread_t_defined
|
|
|
|
typedef __pthread_t pthread_t;
|
|
|
|
#endif
|
|
|
|
|
2013-01-16 00:45:51 +00:00
|
|
|
#endif
|
|
|
|
|
2011-08-05 12:25:00 +00:00
|
|
|
__END_DECLS
|
|
|
|
|
|
|
|
#endif
|