2008-09-01 00:27:58 +02:00
|
|
|
#ifndef _UNISTD_H
|
2000-02-17 20:38:33 +01:00
|
|
|
/*
|
|
|
|
* This file is part of the Mingw32 package.
|
|
|
|
*
|
|
|
|
* unistd.h maps (roughly) to io.h
|
2008-09-01 00:27:58 +02:00
|
|
|
* Other headers included by unistd.h may be selectively processed;
|
|
|
|
* __UNISTD_H_SOURCED__ enables such selective processing.
|
2000-02-17 20:38:33 +01:00
|
|
|
*/
|
2004-03-11 10:41:08 +01:00
|
|
|
#define _UNISTD_H
|
2008-09-01 00:27:58 +02:00
|
|
|
#define __UNISTD_H_SOURCED__ 1
|
2003-03-03 02:19:42 +01:00
|
|
|
|
2000-02-17 20:38:33 +01:00
|
|
|
#include <io.h>
|
2002-08-14 23:08:43 +02:00
|
|
|
#include <process.h>
|
2003-03-03 02:19:42 +01:00
|
|
|
#include <getopt.h>
|
|
|
|
|
2007-01-19 04:21:09 +01:00
|
|
|
/* These are also defined in stdio.h. */
|
|
|
|
#ifndef SEEK_SET
|
|
|
|
#define SEEK_SET 0
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef SEEK_CUR
|
|
|
|
#define SEEK_CUR 1
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef SEEK_END
|
|
|
|
#define SEEK_END 2
|
|
|
|
#endif
|
|
|
|
|
2004-07-11 12:01:41 +02:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
2008-05-04 14:18:52 +02:00
|
|
|
#if !defined __NO_ISOCEXT
|
|
|
|
#include <sys/types.h> /* For useconds_t. */
|
|
|
|
|
|
|
|
int __cdecl __MINGW_NOTHROW usleep(useconds_t useconds);
|
|
|
|
#endif /* Not __NO_ISOCEXT */
|
2007-01-19 04:21:09 +01:00
|
|
|
|
2004-07-11 12:01:41 +02:00
|
|
|
/* This is defined as a real library function to allow autoconf
|
|
|
|
to verify its existence. */
|
|
|
|
int ftruncate(int, off_t);
|
|
|
|
__CRT_INLINE int ftruncate(int __fd, off_t __length)
|
|
|
|
{
|
|
|
|
return _chsize (__fd, __length);
|
|
|
|
}
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2008-09-01 00:27:58 +02:00
|
|
|
#undef __UNISTD_H_SOURCED__
|
2004-03-11 10:41:08 +01:00
|
|
|
#endif /* _UNISTD_H */
|