mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 01:55:19 +00:00
Untangled crtdll/msvcrt header mess.
svn path=/trunk/; revision=2029
This commit is contained in:
parent
0bbf23c333
commit
83e63dc11b
9 changed files with 392 additions and 0 deletions
8
reactos/include/msvcrt/sys/fcntl.h
Normal file
8
reactos/include/msvcrt/sys/fcntl.h
Normal file
|
@ -0,0 +1,8 @@
|
|||
/*
|
||||
* This file is part of the Mingw32 package.
|
||||
*
|
||||
* This fcntl.h maps to the root fcntl.h
|
||||
*/
|
||||
#ifndef __STRICT_ANSI__
|
||||
#include <msvcrt/fcntl.h>
|
||||
#endif
|
9
reactos/include/msvcrt/sys/file.h
Normal file
9
reactos/include/msvcrt/sys/file.h
Normal file
|
@ -0,0 +1,9 @@
|
|||
/*
|
||||
* This file is part of the Mingw32 package.
|
||||
*
|
||||
* This file.h maps to the root fcntl.h
|
||||
* TODO?
|
||||
*/
|
||||
#ifndef __STRICT_ANSI__
|
||||
#include <msvcrt/fcntl.h>
|
||||
#endif
|
38
reactos/include/msvcrt/sys/locking.h
Normal file
38
reactos/include/msvcrt/sys/locking.h
Normal file
|
@ -0,0 +1,38 @@
|
|||
/*
|
||||
* locking.h
|
||||
*
|
||||
* Constants for the mode parameter of the locking function.
|
||||
*
|
||||
* This file is part of the Mingw32 package.
|
||||
*
|
||||
* Contributors:
|
||||
* Created by Colin Peters <colin@bird.fu.is.saga-u.ac.jp>
|
||||
*
|
||||
* THIS SOFTWARE IS NOT COPYRIGHTED
|
||||
*
|
||||
* This source code is offered for use in the public domain. You may
|
||||
* use, modify or distribute it freely.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful but
|
||||
* WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
|
||||
* DISCLAMED. This includes but is not limited to warranties of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
*
|
||||
* $Revision: 1.1 $
|
||||
* $Author: ekohl $
|
||||
* $Date: 2001/07/03 13:07:12 $
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _LOCKING_H_
|
||||
#define _LOCKING_H_
|
||||
|
||||
/*
|
||||
* TODO: Define LK_... constants.
|
||||
*/
|
||||
|
||||
#endif /* Not _LOCKING_H_ */
|
||||
|
||||
#endif /* Not __STRICT_ANSI__ */
|
113
reactos/include/msvcrt/sys/stat.h
Normal file
113
reactos/include/msvcrt/sys/stat.h
Normal file
|
@ -0,0 +1,113 @@
|
|||
/*
|
||||
* stat.h
|
||||
*
|
||||
* Symbolic constants for opening and creating files, also stat, fstat and
|
||||
* chmod functions.
|
||||
*
|
||||
* This file is part of the Mingw32 package.
|
||||
*
|
||||
* Contributors:
|
||||
* Created by Colin Peters <colin@bird.fu.is.saga-u.ac.jp>
|
||||
*
|
||||
* THIS SOFTWARE IS NOT COPYRIGHTED
|
||||
*
|
||||
* This source code is offered for use in the public domain. You may
|
||||
* use, modify or distribute it freely.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful but
|
||||
* WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
|
||||
* DISCLAMED. This includes but is not limited to warranties of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
*
|
||||
* $Revision: 1.1 $
|
||||
* $Author: ekohl $
|
||||
* $Date: 2001/07/03 13:07:12 $
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _STAT_H_
|
||||
#define _STAT_H_
|
||||
|
||||
#include <msvcrt/sys/types.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Constants for the stat st_mode member.
|
||||
*/
|
||||
#define S_IFIFO 0x1000 /* FIFO */
|
||||
#define S_IFCHR 0x2000 /* Character */
|
||||
#define S_IFBLK 0x3000 /* Block */
|
||||
#define S_IFDIR 0x4000 /* Directory */
|
||||
#define S_IFREG 0x8000 /* Regular */
|
||||
|
||||
#define S_IFMT 0xF000 /* File type mask */
|
||||
|
||||
#define S_IEXEC 0x0040
|
||||
#define S_IWRITE 0x0080
|
||||
#define S_IREAD 0x0100
|
||||
|
||||
#define S_ISDIR(m) ((m) & S_IFDIR)
|
||||
#define S_ISFIFO(m) ((m) & S_IFIFO)
|
||||
#define S_ISCHR(m) ((m) & S_IFCHR)
|
||||
#define S_ISBLK(m) ((m) & S_IFBLK)
|
||||
#define S_ISREG(m) ((m) & S_IFREG)
|
||||
|
||||
#define S_IRWXU (S_IREAD | S_IWRITE | S_IEXEC)
|
||||
#define S_IXUSR S_IEXEC
|
||||
#define S_IWUSR S_IWRITE
|
||||
#define S_IRUSR S_IREAD
|
||||
|
||||
#define _S_IEXEC S_IEXEC
|
||||
#define _S_IREAD S_IREAD
|
||||
#define _S_IWRITE S_IWRITE
|
||||
|
||||
/*
|
||||
* The structure manipulated and returned by stat and fstat.
|
||||
*
|
||||
* NOTE: If called on a directory the values in the time fields are not only
|
||||
* invalid, they will cause localtime et. al. to return NULL. And calling
|
||||
* asctime with a NULL pointer causes an Invalid Page Fault. So watch it!
|
||||
*/
|
||||
struct stat
|
||||
{
|
||||
short st_dev; /* Equivalent to drive number 0=A 1=B ... */
|
||||
short st_ino; /* Always zero ? */
|
||||
short st_mode; /* See above constants */
|
||||
short st_nlink; /* Number of links. */
|
||||
int st_uid; /* User: Maybe significant on NT ? */
|
||||
short st_gid; /* Group: Ditto */
|
||||
short st_rdev; /* Seems useless (not even filled in) */
|
||||
long st_size; /* File size in bytes */
|
||||
time_t st_atime; /* Accessed date (always 00:00 hrs local
|
||||
* on FAT) */
|
||||
time_t st_mtime; /* Modified time */
|
||||
time_t st_ctime; /* Creation time */
|
||||
};
|
||||
|
||||
|
||||
int _fstat (int nFileNo, struct stat* pstat);
|
||||
int _chmod (const char* szPath, int nMode);
|
||||
int _stat (const char* szPath, struct stat* pstat);
|
||||
|
||||
|
||||
#ifndef _NO_OLDNAMES
|
||||
|
||||
#define fstat(nFileNo, pstat) _fstat(nFileNo, pstat)
|
||||
#define chmod(szPath,nMode) _chmod(szPath,nMode)
|
||||
#define stat(szPath,pstat) _stat(szPath,pstat)
|
||||
|
||||
#endif /* Not _NO_OLDNAMES */
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* Not _STAT_H_ */
|
||||
|
||||
#endif /* Not __STRICT_ANSI__ */
|
3
reactos/include/msvcrt/sys/time.h
Normal file
3
reactos/include/msvcrt/sys/time.h
Normal file
|
@ -0,0 +1,3 @@
|
|||
|
||||
#include <msvcrt/time.h>
|
||||
|
60
reactos/include/msvcrt/sys/timeb.h
Normal file
60
reactos/include/msvcrt/sys/timeb.h
Normal file
|
@ -0,0 +1,60 @@
|
|||
/*
|
||||
* timeb.h
|
||||
*
|
||||
* Support for the UNIX System V ftime system call.
|
||||
*
|
||||
* This file is part of the Mingw32 package.
|
||||
*
|
||||
* Contributors:
|
||||
* Created by Colin Peters <colin@bird.fu.is.saga-u.ac.jp>
|
||||
*
|
||||
* THIS SOFTWARE IS NOT COPYRIGHTED
|
||||
*
|
||||
* This source code is offered for use in the public domain. You may
|
||||
* use, modify or distribute it freely.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful but
|
||||
* WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
|
||||
* DISCLAMED. This includes but is not limited to warranties of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
*
|
||||
* $Revision: 1.1 $
|
||||
* $Author: ekohl $
|
||||
* $Date: 2001/07/03 13:07:12 $
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _TIMEB_H_
|
||||
#define _TIMEB_H_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
* TODO: Structure not tested.
|
||||
*/
|
||||
struct timeb
|
||||
{
|
||||
long time;
|
||||
short millitm;
|
||||
short _timezone;
|
||||
short dstflag;
|
||||
};
|
||||
|
||||
/* TODO: Not tested. */
|
||||
void _ftime (struct timeb* timebBuffer);
|
||||
|
||||
#ifndef _NO_OLDNAMES
|
||||
void ftime (struct timeb* timebBuffer);
|
||||
#endif /* Not _NO_OLDNAMES */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* Not _TIMEB_H_ */
|
||||
|
||||
#endif /* Not __STRICT_ANSI__ */
|
77
reactos/include/msvcrt/sys/types.h
Normal file
77
reactos/include/msvcrt/sys/types.h
Normal file
|
@ -0,0 +1,77 @@
|
|||
/*
|
||||
* types.h
|
||||
*
|
||||
* The definition of constants, data types and global variables.
|
||||
*
|
||||
* This file is part of the Mingw32 package.
|
||||
*
|
||||
* Contributors:
|
||||
* Created by Colin Peters <colin@bird.fu.is.saga-u.ac.jp>
|
||||
*
|
||||
* THIS SOFTWARE IS NOT COPYRIGHTED
|
||||
*
|
||||
* This source code is offered for use in the public domain. You may
|
||||
* use, modify or distribute it freely.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful but
|
||||
* WITHOUT ANY WARRANTY. ALL WARRENTIES, EXPRESS OR IMPLIED ARE HEREBY
|
||||
* DISCLAMED. This includes but is not limited to warrenties of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
*
|
||||
* $Revision: 1.1 $
|
||||
* $Author: ekohl $
|
||||
* $Date: 2001/07/03 13:07:12 $
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef _TYPES_H_
|
||||
#define _TYPES_H_
|
||||
|
||||
#ifndef _TIME_T_
|
||||
#define _TIME_T_
|
||||
typedef long time_t;
|
||||
#endif
|
||||
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _OFF_T_DEFINED
|
||||
typedef long _off_t;
|
||||
|
||||
#ifndef _NO_OLDNAMES
|
||||
#define off_t _off_t
|
||||
#endif
|
||||
|
||||
#define _OFF_T_DEFINED
|
||||
|
||||
#endif /* Not _OFF_T_DEFINED */
|
||||
|
||||
|
||||
#ifndef _DEV_T_DEFINED
|
||||
typedef short _dev_t;
|
||||
|
||||
#ifndef _NO_OLDNAMES
|
||||
#define dev_t _dev_t
|
||||
#endif
|
||||
|
||||
#define _DEV_T_DEFINED
|
||||
|
||||
#endif /* Not _DEV_T_DEFINED */
|
||||
|
||||
|
||||
#ifndef _INO_T_DEFINED
|
||||
typedef short _ino_t;
|
||||
|
||||
#ifndef _NO_OLDNAMES
|
||||
#define ino_t _ino_t
|
||||
#endif
|
||||
|
||||
#define _INO_T_DEFINED
|
||||
|
||||
#endif /* Not _INO_T_DEFINED */
|
||||
|
||||
|
||||
#endif /* Not __STRICT_ANSI__ */
|
||||
|
||||
|
||||
#endif /* Not _TYPES_H_ */
|
9
reactos/include/msvcrt/sys/unistd.h
Normal file
9
reactos/include/msvcrt/sys/unistd.h
Normal file
|
@ -0,0 +1,9 @@
|
|||
/*
|
||||
* This file is part of the Mingw32 package.
|
||||
*
|
||||
* unistd.h maps (roughly) to io.h
|
||||
*/
|
||||
#ifndef __STRICT_ANSI__
|
||||
#include <msvcrt/io.h>
|
||||
#endif
|
||||
|
75
reactos/include/msvcrt/sys/utime.h
Normal file
75
reactos/include/msvcrt/sys/utime.h
Normal file
|
@ -0,0 +1,75 @@
|
|||
/*
|
||||
* utime.h
|
||||
*
|
||||
* Support for the utime function.
|
||||
*
|
||||
* This file is part of the Mingw32 package.
|
||||
*
|
||||
* Contributors:
|
||||
* Created by Colin Peters <colin@bird.fu.is.saga-u.ac.jp>
|
||||
*
|
||||
* THIS SOFTWARE IS NOT COPYRIGHTED
|
||||
*
|
||||
* This source code is offered for use in the public domain. You may
|
||||
* use, modify or distribute it freely.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful but
|
||||
* WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
|
||||
* DISCLAMED. This includes but is not limited to warranties of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
*
|
||||
* $Revision: 1.1 $
|
||||
* $Author: ekohl $
|
||||
* $Date: 2001/07/03 13:07:12 $
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _UTIME_H_
|
||||
#define _UTIME_H_
|
||||
|
||||
#define __need_wchar_t
|
||||
#define __need_size_t
|
||||
#include <msvcrt/stddef.h>
|
||||
#include <msvcrt/sys/types.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Structure used by _utime function.
|
||||
*/
|
||||
struct _utimbuf
|
||||
{
|
||||
time_t actime; /* Access time */
|
||||
time_t modtime; /* Modification time */
|
||||
};
|
||||
|
||||
int _utime (const char* szFileName, struct _utimbuf* pTimes);
|
||||
int _futime (int nHandle, struct _utimbuf *pTimes);
|
||||
|
||||
/* Wide character version */
|
||||
int _wutime (const wchar_t *szFileName, struct _utimbuf *times);
|
||||
|
||||
#ifndef _NO_OLDNAMES
|
||||
|
||||
/* NOTE: Must be the same as _utimbuf above. */
|
||||
struct utimbuf
|
||||
{
|
||||
time_t actime;
|
||||
time_t modtime;
|
||||
};
|
||||
|
||||
int utime (const char* szFileName, struct utimbuf* pTimes);
|
||||
|
||||
#endif /* Not _NO_OLDNAMES */
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* Not _UTIME_H_ */
|
||||
#endif /* Not __STRICT_ANSI__ */
|
Loading…
Reference in a new issue