forked from KolibriOS/kolibrios
Temporarily removing menuetlibc
git-svn-id: svn://kolibrios.org@4799 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
@@ -1,92 +0,0 @@
|
||||
/*
|
||||
* bitypes.h,v 1.4 1995/08/24 01:58:54 hjl Exp
|
||||
*/
|
||||
|
||||
/*
|
||||
* ++Copyright++ 1993
|
||||
* -
|
||||
* Copyright (c) 1993 Regents of the University of California.
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
* are met:
|
||||
* 1. Redistributions of source code must retain the above copyright
|
||||
* notice, this list of conditions and the following disclaimer.
|
||||
* 2. Redistributions in binary form must reproduce the above copyright
|
||||
* notice, this list of conditions and the following disclaimer in the
|
||||
* documentation and/or other materials provided with the distribution.
|
||||
* 3. All advertising materials mentioning features or use of this software
|
||||
* must display the following acknowledgement:
|
||||
* This product includes software developed by the University of
|
||||
* California, Berkeley and its contributors.
|
||||
* 4. Neither the name of the University nor the names of its contributors
|
||||
* may be used to endorse or promote products derived from this software
|
||||
* without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
||||
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||||
* ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
||||
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
* -
|
||||
* Portions Copyright (c) 1993 by Digital Equipment Corporation.
|
||||
*
|
||||
* Permission to use, copy, modify, and distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
* copyright notice and this permission notice appear in all copies, and that
|
||||
* the name of Digital Equipment Corporation not be used in advertising or
|
||||
* publicity pertaining to distribution of the document or software without
|
||||
* specific, written prior permission.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS" AND DIGITAL EQUIPMENT CORP. DISCLAIMS ALL
|
||||
* WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL DIGITAL EQUIPMENT
|
||||
* CORPORATION BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
|
||||
* DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
|
||||
* PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
|
||||
* ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
|
||||
* SOFTWARE.
|
||||
* -
|
||||
* --Copyright--
|
||||
*/
|
||||
|
||||
/*
|
||||
#ifdef __USE_BSD
|
||||
*/
|
||||
|
||||
#ifndef __BIT_TYPES_DEFINED__
|
||||
# if (defined(BSD) && (BSD >= 199306)) || \
|
||||
(defined(_BSDI_VERSION) && (_BSDI_VERSION >= 199312))
|
||||
# define __BIT_TYPES_DEFINED__
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifndef __BIT_TYPES_DEFINED__
|
||||
#define __BIT_TYPES_DEFINED__
|
||||
|
||||
/*
|
||||
* Basic integral types. Omit the typedef if
|
||||
* not possible for a machine/compiler combination.
|
||||
*/
|
||||
typedef /*signed*/ char int8_t;
|
||||
typedef unsigned char u_int8_t;
|
||||
typedef short int16_t;
|
||||
typedef unsigned short u_int16_t;
|
||||
typedef int int32_t;
|
||||
typedef unsigned int u_int32_t;
|
||||
|
||||
# if __GNUC__ >= 2
|
||||
typedef long long int64_t;
|
||||
typedef unsigned long long u_int64_t;
|
||||
# endif
|
||||
|
||||
#endif /* __BIT_TYPES_DEFINED__ */
|
||||
|
||||
/* #endif __USE_BSD */
|
@@ -1,38 +0,0 @@
|
||||
/* Copyright (C) 1998 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1994 DJ Delorie, see COPYING.DJ for details */
|
||||
#undef __P
|
||||
#if defined(__STDC__) || defined(__cplusplus)
|
||||
#define __P(p) p
|
||||
#else
|
||||
#define __P(p)
|
||||
#endif
|
||||
#define _PTR void *
|
||||
#define _AND ,
|
||||
#define _NOARGS void
|
||||
#define _CONST const
|
||||
#define _VOLATILE volatile
|
||||
#define _SIGNED signed
|
||||
#define _DOTS , ...
|
||||
#define _VOID void
|
||||
#define _EXFUN(name, proto) name proto
|
||||
#define _DEFUN(name, arglist, args) name(args)
|
||||
#define _DEFUN_VOID(name) name(_NOARGS)
|
||||
#define _CAST_VOID (void)
|
||||
#ifndef _LONG_DOUBLE
|
||||
#define _LONG_DOUBLE long double
|
||||
#endif
|
||||
#ifndef _PARAMS
|
||||
#define _PARAMS(paramlist) paramlist
|
||||
#endif
|
||||
|
||||
/* Support gcc's __attribute__ facility. */
|
||||
|
||||
#define _ATTRIBUTE(attrs) __attribute__ ((attrs))
|
||||
|
||||
#if defined(__cplusplus)
|
||||
#define __BEGIN_DECLS extern "C" {
|
||||
#define __END_DECLS }
|
||||
#else
|
||||
#define __BEGIN_DECLS
|
||||
#define __END_DECLS
|
||||
#endif
|
@@ -1,612 +0,0 @@
|
||||
/* Copyright (C) 1999 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1998 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1996 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_config_h_
|
||||
#define __dj_include_sys_config_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
/* config.h for DJGPP.
|
||||
|
||||
This is usually generated automatically from config.h.in by the
|
||||
configure script. However, it is very hard to run that script under
|
||||
MS-DOS, because of its extensive use of Unix shell features. This
|
||||
header file is provided so you can skip the autoconfigure step
|
||||
altogether and go directly to the compilation step (after copying
|
||||
Makefile.in to Makefile and setting the defaults there).
|
||||
|
||||
There are several parts in this header file, which closely follow the
|
||||
GNU Autoconf procedures.
|
||||
|
||||
The first part checks for things which depend on the specific programs
|
||||
from your programming environment which you use to compile a package.
|
||||
|
||||
The second part mentions all the header files in the include hierarchy,
|
||||
even those which every C installation must have. The only headers
|
||||
files which are omitted are those which are specific to the PC
|
||||
architecture or to DJGPP, because no GNU package should ever look for
|
||||
those. (Some header files which DJGPP includes only for compatibility,
|
||||
and which could cause a conflict with the mainstream header file, are
|
||||
also excluded.)
|
||||
|
||||
The third part mentions all the library functions which aren't included
|
||||
in every C library. Obviously, it isn't practical to mention every
|
||||
library function here, so this part has somewhat ad-hoc nature in that
|
||||
the macros which should go there were assembled by actually porting
|
||||
some GNU packages.
|
||||
|
||||
The fourth part defines macros which are related to the header files,
|
||||
like definitions of some structures and specific member fields in some
|
||||
structures.
|
||||
|
||||
The fifth part deals with some typedefs which aren't standardized
|
||||
enough between different systems, or might be missing from your header
|
||||
files.
|
||||
|
||||
The sixth part defines some macros necessary to deal with differences
|
||||
between compiler and architectural characteristics of various systems.
|
||||
|
||||
In the seventh part, some system services which might be required by
|
||||
some packages, are mentioned.
|
||||
|
||||
The last part includes all kinds if miscellaneous macros required by
|
||||
some GNU packages to be successfully compiled under DJGPP.
|
||||
|
||||
Prepared by Eli Zaretskii <eliz@is.elta.co.il>
|
||||
with help from Morten Welinder <terra@diku.dk>
|
||||
and using some information from GNU Autoconf package.
|
||||
*/
|
||||
|
||||
/* ---------------------------------------------------------------------
|
||||
Program-related stuff.
|
||||
--------------------------------------------------------------------- */
|
||||
|
||||
/* Define if `yytext' is a `char *' instead of a `char []'. This is
|
||||
true if you use Flex. */
|
||||
#undef YYTEXT_POINTER
|
||||
#define YYTEXT_POINTER 1
|
||||
|
||||
/* ---------------------------------------------------------------------
|
||||
Header files.
|
||||
--------------------------------------------------------------------- */
|
||||
|
||||
/* Define if you have the ANSI C header files. */
|
||||
#undef STDC_HEADERS
|
||||
#define STDC_HEADERS 1
|
||||
|
||||
/* Define if you have the <ar.h> header file. */
|
||||
#undef HAVE_AR_H
|
||||
#define HAVE_AR_H 1
|
||||
|
||||
/* Define if you have the <assert.h> header file. */
|
||||
#undef HAVE_ASSERT_H
|
||||
#define HAVE_ASSERT_H 1
|
||||
|
||||
/* Define if you have the <coff.h> header file. */
|
||||
#undef HAVE_COFF_H
|
||||
#define HAVE_COFF_H 1
|
||||
|
||||
/* Define if you have the <ctype.h> header file. */
|
||||
#undef HAVE_CTYPE_H
|
||||
#define HAVE_CTYPE_H 1
|
||||
|
||||
/* Define if you have the <dirent.h> header file. */
|
||||
#undef DIRENT
|
||||
#define DIRENT 1
|
||||
|
||||
#undef HAVE_DIRENT_H
|
||||
#define HAVE_DIRENT_H 1
|
||||
|
||||
/* Define if you have the <errno.h> header file. */
|
||||
#undef HAVE_ERRNO_H
|
||||
#define HAVE_ERRNO_H 1
|
||||
|
||||
/* Define if you have the <fcntl.h> header file. */
|
||||
#undef HAVE_FCNTL_H
|
||||
#define HAVE_FCNTL_H 1
|
||||
|
||||
/* Define if you have the <float.h> header file. */
|
||||
#undef HAVE_FLOAT_H
|
||||
#define HAVE_FLOAT_H 1
|
||||
|
||||
/* Define if you have the <fnmatch.h> header file. */
|
||||
#undef HAVE_FNMATCH_H
|
||||
#define HAVE_FNMATCH_H 1
|
||||
|
||||
/* Define if you have the <ftw.h> header file. */
|
||||
#undef HAVE_FTW_H
|
||||
#define HAVE_FTW_H 1
|
||||
|
||||
/* Define if you have the <glob.h> header file. */
|
||||
#undef HAVE_GLOB_H
|
||||
#define HAVE_GLOB_H 1
|
||||
|
||||
/* Define if you have the <grp.h> header file. */
|
||||
#undef HAVE_GRP_H
|
||||
#define HAVE_GRP_H 1
|
||||
|
||||
/* Define if you have the <io.h> header file. */
|
||||
#undef HAVE_IO_H
|
||||
#define HAVE_IO_H 1
|
||||
|
||||
/* Define if you have the <limits.h> header file. */
|
||||
#undef HAVE_LIMITS_H
|
||||
#define HAVE_LIMITS_H 1
|
||||
|
||||
/* Define if you have the <locale.h> header file. */
|
||||
#undef HAVE_LOCALE_H
|
||||
#define HAVE_LOCALE_H 1
|
||||
|
||||
/* Define if you have the <math.h> header file. */
|
||||
#undef HAVE_MATH_H
|
||||
#define HAVE_MATH_H 1
|
||||
|
||||
/* Define if you have the <mntent.h> header file. */
|
||||
#undef HAVE_MNTENT_H
|
||||
#define HAVE_MNTENT_H 1
|
||||
|
||||
/* Define if you have the <pwd.h> header file. */
|
||||
#undef HAVE_PWD_H
|
||||
#define HAVE_PWD_H 1
|
||||
|
||||
/* Define if you have the <search.h> header file. */
|
||||
#undef HAVE_SEARCH_H
|
||||
#define HAVE_SEARCH_H 1
|
||||
|
||||
/* Define if you have the <setjmp.h> header file. */
|
||||
#undef HAVE_SETJMP_H
|
||||
#define HAVE_SETJMP_H 1
|
||||
|
||||
/* Define if you have the <signal.h> header file. */
|
||||
#undef HAVE_SIGNAL_H
|
||||
#define HAVE_SIGNAL_H 1
|
||||
|
||||
#undef HAVE_SYS_SIGLIST
|
||||
#define HAVE_SYS_SIGLIST 1
|
||||
|
||||
/* Define if you have the <stdarg.h> header file. */
|
||||
#undef HAVE_STDARG_H
|
||||
#define HAVE_STDARG_H 1
|
||||
|
||||
/* Define if you have the <stddef.h> header file. */
|
||||
#undef HAVE_STDDEF_H
|
||||
#define HAVE_STDDEF_H 1
|
||||
|
||||
/* Define if you have the <stdio.h> header file (is there ANY C
|
||||
installation that doesn't??). */
|
||||
#undef HAVE_STDIO_H
|
||||
#define HAVE_STDIO_H 1
|
||||
|
||||
/* Define if you have the <stdlib.h> header file. */
|
||||
#undef HAVE_STDLIB_H
|
||||
#define HAVE_STDLIB_H 1
|
||||
|
||||
/* Define if you have the <string.h> header file. */
|
||||
#undef HAVE_STRING_H
|
||||
#define HAVE_STRING_H 1
|
||||
|
||||
/* Define if you have the <termios.h> header file. */
|
||||
#undef HAVE_TERMIOS_H /* we have, but the functions aren't implemented */
|
||||
/* #define HAVE_TERMIOS_H 1 */
|
||||
|
||||
/* Define if you have the <time.h> header file. */
|
||||
#undef HAVE_TIME_H
|
||||
#define HAVE_TIME_H 1
|
||||
|
||||
/* Define if you have the <sys/time.h> header file. */
|
||||
#undef HAVE_SYS_TIME_H
|
||||
#define HAVE_SYS_TIME_H 1
|
||||
|
||||
/* Define this if your <time.h> and <sys/time.h> can both be
|
||||
included with no conflicts. */
|
||||
#undef TIME_WITH_SYS_TIME
|
||||
#define TIME_WITH_SYS_TIME 1
|
||||
|
||||
/* Define if you have the <unistd.h> header file. */
|
||||
#undef HAVE_UNISTD_H
|
||||
#define HAVE_UNISTD_H 1
|
||||
|
||||
/* Define if you have the <utime.h> header file. */
|
||||
#undef HAVE_UTIME_H
|
||||
#define HAVE_UTIME_H 1
|
||||
|
||||
/* Define if you have the values.h header file. */
|
||||
#undef HAVE_VALUES_H
|
||||
#define HAVE_VALUES_H 1
|
||||
|
||||
/* Define if you have the <varargs.h> header file. */
|
||||
#undef HAVE_VARARGS_H
|
||||
#define HAVE_VARARGS_H 1
|
||||
|
||||
/* Define if you have the <netinet/in.h> header file. */
|
||||
#undef HAVE_NETINET_IN_H
|
||||
#define HAVE_NETINET_IN_H 1
|
||||
|
||||
/* Define if you have the <sys/file.h> header file. */
|
||||
#undef HAVE_SYS_FILE_H
|
||||
#define HAVE_SYS_FILE_H 1
|
||||
|
||||
/* Define if you have the <sys/ioctl.h> header file. */
|
||||
#undef HAVE_SYS_IOCTL_H
|
||||
#define HAVE_SYS_IOCTL_H 1
|
||||
|
||||
/* Define if you have the <sys/param.h> header file. */
|
||||
#undef HAVE_SYS_PARAM_H
|
||||
#define HAVE_SYS_PARAM_H 1
|
||||
|
||||
/* Define if you have the <sys/resource.h> header file. */
|
||||
#undef HAVE_SYS_RESOURCE_H
|
||||
#define HAVE_SYS_RESOURCE_H 1
|
||||
|
||||
/* Define if you have the <sys/stat.h> header file. */
|
||||
#undef HAVE_SYS_STAT_H
|
||||
#define HAVE_SYS_STAT_H 1
|
||||
|
||||
/* Define if you have the <sys/time.h> header file. */
|
||||
#undef HAVE_SYS_TIME_H
|
||||
#define HAVE_SYS_TIME_H 1
|
||||
|
||||
/* Define if you have the <sys/timeb.h> header file. */
|
||||
#undef HAVE_SYS_TIMEB_H
|
||||
#define HAVE_SYS_TIMEB_H 1
|
||||
|
||||
/* Define if you have the <sys/times.h> header file. */
|
||||
#undef HAVE_SYS_TIMES_H
|
||||
#define HAVE_SYS_TIMES_H 1
|
||||
|
||||
/* Define if you have the <sys/types.h> header file. */
|
||||
#undef HAVE_SYS_TYPES_H
|
||||
#define HAVE_SYS_TYPES_H 1
|
||||
|
||||
/* Define if you have the <sys/utsname.h> header file. */
|
||||
#undef HAVE_SYS_UTSNAME_H
|
||||
#define HAVE_SYS_UTSNAME_H 1
|
||||
|
||||
/* Define if you have the <sys/vfs.h> header file. */
|
||||
#undef HAVE_SYS_VFS_H
|
||||
#define HAVE_SYS_VFS_H 1
|
||||
|
||||
/* Define if you have the <sys/wait.h> header file. */
|
||||
#undef HAVE_SYS_WAIT_H
|
||||
#define HAVE_SYS_WAIT_H 1
|
||||
|
||||
|
||||
/* ---------------------------------------------------------------------
|
||||
Library functions and related stuff.
|
||||
--------------------------------------------------------------------- */
|
||||
|
||||
/* Define if using alloca.c. */
|
||||
#undef C_ALLOCA
|
||||
|
||||
/* Define if you have bcmp() and bcopy() library functions. */
|
||||
#undef HAVE_BCMP
|
||||
#define HAVE_BCMP 1
|
||||
#undef HAVE_BCOPY
|
||||
#define HAVE_BCOPY 1
|
||||
|
||||
/* Define if you have closedir() function in your library. */
|
||||
#undef HAVE_CLOSEDIR
|
||||
#define HAVE_CLOSEDIR 1
|
||||
|
||||
/* Define if you have dup2() library function. */
|
||||
#undef HAVE_DUP2
|
||||
#define HAVE_DUP2 1
|
||||
|
||||
/* Define if you have the endgrent function. */
|
||||
#undef HAVE_ENDGRENT
|
||||
#define HAVE_ENDGRENT 1
|
||||
|
||||
/* Define if you have the endpwent function. */
|
||||
#undef HAVE_ENDPWENT
|
||||
#define HAVE_ENDPWENT 1
|
||||
|
||||
/* Define if you have fnmatch() function in your library. */
|
||||
#undef HAVE_FNMATCH
|
||||
#define HAVE_FNMATCH 1
|
||||
|
||||
/* Define if you have frexp() function in your library. */
|
||||
#undef HAVE_FREXP
|
||||
#define HAVE_FREXP 1
|
||||
|
||||
/* Define if you have ftime() function in your library. */
|
||||
#undef HAVE_FTIME
|
||||
#define HAVE_FTIME 1
|
||||
|
||||
/* Define if you have the the ftruncate() library function. */
|
||||
#undef HAVE_FTRUNCATE
|
||||
#define HAVE_FTRUNCATE 1
|
||||
|
||||
/* Define if you have ftw() function in your library. */
|
||||
#undef HAVE_FTW
|
||||
#define HAVE_FTW 1
|
||||
|
||||
/* Define if you have getcwd() function in your library. */
|
||||
#undef HAVE_GETCWD
|
||||
#define HAVE_GETCWD 1
|
||||
|
||||
/* Define if you have getdtablesize() function in your library. */
|
||||
#undef HAVE_GETDTABLESIZE
|
||||
#define HAVE_GETDTABLESIZE 1
|
||||
|
||||
/* Define if you have the getgroups function. */
|
||||
#undef HAVE_GETGROUPS
|
||||
#define HAVE_GETGROUPS 1
|
||||
|
||||
/* Define if you have gethostname() function in your library. */
|
||||
#undef HAVE_GETHOSTNAME
|
||||
#define HAVE_GETHOSTNAME 1
|
||||
|
||||
/* Define if you have getmntent() function in your library. */
|
||||
#undef HAVE_GETMNTENT
|
||||
#define HAVE_GETMNTENT 1
|
||||
|
||||
/* Define if you have getpagesize() function in your library. */
|
||||
#undef HAVE_GETPAGESIZE
|
||||
#define HAVE_GETPAGESIZE 1
|
||||
|
||||
/* Define this if your getpgrp() function takes no argument (the
|
||||
POSIX.1 version). */
|
||||
#undef GETPGRP_VOID
|
||||
#define GETPGRP_VOID 1
|
||||
|
||||
/* Define if your getmntent() function accepts one argument. */
|
||||
#undef MOUNTED_GETMNTENT1
|
||||
#define MOUNTED_GETMNTENT1 1
|
||||
|
||||
/* Define if you have gettimeofday() function in your library. */
|
||||
#undef HAVE_GETTIMEOFDAY
|
||||
#define HAVE_GETTIMEOFDAY 1
|
||||
|
||||
/* Define if you have the glob() function in your library. */
|
||||
#undef HAVE_GLOB
|
||||
#define HAVE_GLOB 1
|
||||
|
||||
/* Define if you have the isascii function. */
|
||||
#undef HAVE_ISASCII
|
||||
#define HAVE_ISASCII 1
|
||||
|
||||
/* Define if you have memchr() in your library. */
|
||||
#undef HAVE_MEMCHR
|
||||
#define HAVE_MEMCHR 1
|
||||
|
||||
/* Define if you have the memcpy function. */
|
||||
#undef HAVE_MEMCPY
|
||||
#define HAVE_MEMCPY 1
|
||||
|
||||
/* Define if you have mkdir() function in your library. */
|
||||
#undef HAVE_MKDIR
|
||||
#define HAVE_MKDIR 1
|
||||
|
||||
/* Define if you have the mkfifo function. */
|
||||
#undef HAVE_MKFIFO
|
||||
#define HAVE_MKFIFO 1
|
||||
|
||||
/* Define if you have mktime() function in your library. */
|
||||
#undef HAVE_MKTIME
|
||||
#define HAVE_MKTIME 1
|
||||
|
||||
/* Define if you have the pow function. */
|
||||
#undef HAVE_POW
|
||||
#define HAVE_POW 1
|
||||
|
||||
/* Define if you have the putenv function. */
|
||||
#undef HAVE_PUTENV
|
||||
#define HAVE_PUTENV 1
|
||||
|
||||
/* Define if you have random() function in your library. */
|
||||
#undef HAVE_RANDOM
|
||||
#define HAVE_RANDOM 1
|
||||
|
||||
/* Define if you have rename() function in your library. */
|
||||
#undef HAVE_RENAME
|
||||
#define HAVE_RENAME 1
|
||||
|
||||
/* Define if you have rmdir() function in your library. */
|
||||
#undef HAVE_RMDIR
|
||||
#define HAVE_RMDIR 1
|
||||
|
||||
/* Define if you have the setenv function. */
|
||||
#undef HAVE_SETENV
|
||||
#define HAVE_SETENV 1
|
||||
|
||||
/* Define if you have setlinebuf() function in your library. */
|
||||
#undef HAVE_SETLINEBUF
|
||||
#define HAVE_SETLINEBUF 1
|
||||
|
||||
/* Define if you have the setlocale function. */
|
||||
#undef HAVE_SETLOCALE
|
||||
#define HAVE_SETLOCALE 1
|
||||
|
||||
/* Define if you have sigaction() function in your library. */
|
||||
#undef HAVE_SIGACTION
|
||||
#define HAVE_SIGACTION 1
|
||||
|
||||
/* Define if your statfs() function accepts 2 arguments and
|
||||
struct statfs has f_bsize field. */
|
||||
#undef STAT_STATFS2_BSIZE
|
||||
#define STAT_STATFS2_BSIZE 1
|
||||
|
||||
/* Define if you have the stpcpy function. */
|
||||
#undef HAVE_STPCPY
|
||||
#define HAVE_STPCPY 1
|
||||
|
||||
/* Define if you have strcasecmp() function in your library. */
|
||||
#undef HAVE_STRCASECMP
|
||||
#define HAVE_STRCASECMP 1
|
||||
|
||||
/* Define if you have strchr() function in your library. */
|
||||
#undef HAVE_STRCHR
|
||||
#define HAVE_STRCHR 1
|
||||
|
||||
/* Define if you have strrchr() function in your library. */
|
||||
#undef HAVE_STRRCHR
|
||||
#define HAVE_STRRCHR 1
|
||||
|
||||
/* Define if you have strcoll() function in your library. */
|
||||
#undef HAVE_STRCOLL
|
||||
#define HAVE_STRCOLL 1
|
||||
|
||||
/* Define if you have strdup() function in your library. */
|
||||
#undef HAVE_STRDUP
|
||||
#define HAVE_STRDUP 1
|
||||
|
||||
/* Define if you have strftime() function in your library. */
|
||||
#undef HAVE_STRFTIME
|
||||
#define HAVE_STRFTIME 1
|
||||
|
||||
/* Define if you have strerror. */
|
||||
#undef HAVE_STRERROR
|
||||
#define HAVE_STRERROR 1
|
||||
|
||||
/* Define if your utime() library function accepts NULL as its second
|
||||
argument (meaning use current time). */
|
||||
#undef HAVE_UTIME_NULL
|
||||
#define HAVE_UTIME_NULL 1
|
||||
|
||||
/* Define vfork as fork if vfork() does not work. */
|
||||
#undef vfork
|
||||
#define vfork fork
|
||||
|
||||
/* Define if you have the vprintf() library function. */
|
||||
#undef HAVE_VPRINTF
|
||||
#define HAVE_VPRINTF 1
|
||||
|
||||
/* Define if you have waitpid. */
|
||||
#undef HAVE_WAITPID /* we do, but it always fails :-( */
|
||||
|
||||
/* ---------------------------------------------------------------------
|
||||
Structures
|
||||
--------------------------------------------------------------------- */
|
||||
|
||||
/* Define if your struct stat has st_blksize. */
|
||||
#undef HAVE_ST_BLKSIZE
|
||||
#define HAVE_ST_BLKSIZE 1
|
||||
|
||||
/* Define if your struct stat has st_blocks. */
|
||||
#undef HAVE_ST_BLOCKS
|
||||
|
||||
/* Define if your struct stat has st_rdev member. */
|
||||
#undef HAVE_ST_RDEV
|
||||
#define HAVE_ST_RDEV 1
|
||||
|
||||
/* Define if you have `struct utimbuf' declared in <utime.h>. */
|
||||
#undef HAVE_STRUCT_UTIMBUF
|
||||
#define HAVE_STRUCT_UTIMBUF 1
|
||||
|
||||
/* Define if you have struct timeval defined in your <time.h> header file. */
|
||||
#undef HAVE_TIMEVAL
|
||||
#define HAVE_TIMEVAL 1
|
||||
|
||||
/* Define if you have tm_zone field in your struct tm definition (in
|
||||
<time.h> header file). */
|
||||
#undef HAVE_TM_ZONE
|
||||
#define HAVE_TM_ZONE 1
|
||||
|
||||
/* ---------------------------------------------------------------------
|
||||
Typedefs
|
||||
--------------------------------------------------------------------- */
|
||||
|
||||
/* Define to the type of elements in the array set by `getgroups'.
|
||||
Usually this is either `int' or `gid_t'. */
|
||||
#undef GETGROUPS_T
|
||||
#define GETGROUPS_T gid_t
|
||||
|
||||
/* Define as the return type of signal handlers (int or void). */
|
||||
#undef RETSIGTYPE
|
||||
#define RETSIGTYPE void
|
||||
|
||||
|
||||
/* ---------------------------------------------------------------------
|
||||
Compiler Characteristics
|
||||
--------------------------------------------------------------------- */
|
||||
|
||||
/* Define `inline' to `__inline__' if your compiler accepts it. */
|
||||
#undef inline
|
||||
#define inline __inline__
|
||||
|
||||
/* Define this if the C compiler supports the `long double' type. */
|
||||
#undef HAVE_LONG_DOUBLE
|
||||
#define HAVE_LONG_DOUBLE 1
|
||||
|
||||
/* Sizes of built-in types and pointers known to the compiler. */
|
||||
#define SIZEOF_CHAR 1
|
||||
#define SIZEOF_CHAR_P 4
|
||||
#define SIZEOF_SHORT 2
|
||||
#define SIZEOF_SHORT_P 4
|
||||
#define SIZEOF_INT 4
|
||||
#define SIZEOF_INT_P 4
|
||||
#define SIZEOF_LONG 4
|
||||
#define SIZEOF_LONG_P 4
|
||||
#define SIZEOF_LONG_LONG 8
|
||||
#define SIZEOF_LONG_LONG_P 4
|
||||
#define SIZEOF_FLOAT 4
|
||||
#define SIZEOF_FLOAT_P 4
|
||||
#define SIZEOF_DOUBLE 8
|
||||
#define SIZEOF_DOUBLE_P 4
|
||||
#define SIZEOF_LONG_DOUBLE 10
|
||||
#define SIZEOF_LONG_DOUBLE_P 4
|
||||
#define SIZEOF_VOID_P 4
|
||||
|
||||
/* If using the C implementation of alloca, define if you know the
|
||||
direction of stack growth for your system; otherwise it will be
|
||||
automatically deduced at run-time.
|
||||
STACK_DIRECTION > 0 => grows toward higher addresses
|
||||
STACK_DIRECTION < 0 => grows toward lower addresses
|
||||
STACK_DIRECTION = 0 => direction of growth unknown
|
||||
*/
|
||||
#undef STACK_DIRECTION
|
||||
|
||||
/* Define to empty if the `const' keyword does not work. */
|
||||
#undef const
|
||||
|
||||
/* ---------------------------------------------------------------------
|
||||
System Services
|
||||
--------------------------------------------------------------------- */
|
||||
|
||||
/* Define this to be the name of your NULL device. */
|
||||
#undef NULL_DEVICE
|
||||
#define NULL_DEVICE "nul"
|
||||
|
||||
/* Do we have long filenames? */
|
||||
#undef HAVE_LONG_FILE_NAMES /* not yet, but Win95 might have them... */
|
||||
|
||||
/* ---------------------------------------------------------------------
|
||||
Misc definitions
|
||||
--------------------------------------------------------------------- */
|
||||
|
||||
/* Define both _LIBC and __GNU_LIBRARY__ if you use GNU C library,
|
||||
but want link in the version of getopt, regex, fnmatch (and other
|
||||
routines which are part of GNU C library) which came with the
|
||||
package. Define _LIBC alone if you use non-GNU C library which
|
||||
might be incompatible with GNU (e.g., getopt()). Define __GNU_LIBRARY__
|
||||
alone if you want the code for the above functions to be effectively
|
||||
commented out, so you will get the code from the GNU C library.
|
||||
*/
|
||||
#undef _LIBC
|
||||
#undef __GNU_LIBRARY__
|
||||
/* #define _LIBC 1 */
|
||||
/* #define __GNU_LIBRARY__ 1 */
|
||||
|
||||
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_config_h_ */
|
@@ -1,32 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_dir_h_
|
||||
#define __dj_include_sys_dir_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
/* WARNING! This file is obsolete! Use <dirent.h> */
|
||||
|
||||
#define dirent direct
|
||||
#include <dirent.h>
|
||||
#undef dirent
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_dir_h_ */
|
@@ -1,34 +0,0 @@
|
||||
/* Copyright (C) 2002 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1999 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1998 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1994 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __DJ_sys_djtypes_h_
|
||||
#define __DJ_sys_djtypes_h_
|
||||
|
||||
#define __DJ_clock_t typedef int clock_t;
|
||||
#define __DJ_gid_t typedef int gid_t;
|
||||
#define __DJ_off_t typedef int off_t;
|
||||
#define __DJ_pid_t typedef int pid_t;
|
||||
#define __DJ_size_t typedef unsigned int size_t;
|
||||
#define __DJ_ssize_t typedef int ssize_t;
|
||||
#define __DJ_time_t typedef unsigned int time_t;
|
||||
#define __DJ_uid_t typedef int uid_t;
|
||||
|
||||
/* For GCC 3.00 or later we use its builtin va_list. */
|
||||
#if __GNUC__ >= 3
|
||||
#define __DJ_va_list typedef __builtin_va_list va_list;
|
||||
#else
|
||||
#define __DJ_va_list typedef void *va_list;
|
||||
#endif
|
||||
|
||||
#if defined(__cplusplus) && ( (__GNUC_MINOR__ >= 8 && __GNUC__ == 2 ) || __GNUC__ >= 3 || defined(_MSC_VER))
|
||||
/* wchar_t is now a keyword in C++ */
|
||||
#define __DJ_wchar_t
|
||||
#else
|
||||
/* but remains a typedef in C */
|
||||
#define __DJ_wchar_t typedef unsigned short wchar_t;
|
||||
#endif
|
||||
|
||||
#define __DJ_wint_t typedef int wint_t;
|
||||
|
||||
#endif
|
@@ -1,24 +0,0 @@
|
||||
/* Copyright (C) 1995 Charles Sandmann (sandmann@clio.rice.edu)
|
||||
This software may be freely distributed with above copyright, no warranty.
|
||||
Based on code by DJ Delorie, it's really his, enhanced, bugs fixed. */
|
||||
|
||||
typedef struct {
|
||||
long magic;
|
||||
long symbol_offset;
|
||||
long element_size;
|
||||
long nrelocs;
|
||||
} dxe_header;
|
||||
|
||||
#define DXE_MAGIC 0x31455844
|
||||
|
||||
/* data stored after dxe_header in file; then relocs, 4 bytes each */
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
void *_dxe_load(char *filename);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
@@ -1,28 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_errno_h_
|
||||
#define __dj_include_sys_errno_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_errno_h_ */
|
@@ -1,77 +0,0 @@
|
||||
/* Copyright (C) 1999 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1998 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_exceptn_h__
|
||||
#define __dj_include_sys_exceptn_h__
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#ifdef __dj_include_setjmp_h_
|
||||
extern jmp_buf *__djgpp_exception_state_ptr; /* Must include setjmp.h first */
|
||||
#define __djgpp_exception_state (*__djgpp_exception_state_ptr)
|
||||
#endif
|
||||
|
||||
extern unsigned short __djgpp_our_DS;
|
||||
extern unsigned short __djgpp_app_DS; /* Data selector invalidated by HW ints */
|
||||
extern unsigned short __djgpp_ds_alias; /* Data selector always valid */
|
||||
extern unsigned short __djgpp_dos_sel; /* Linear mem selector copy in locked mem */
|
||||
/* Hardware Interrupt Flags:
|
||||
|
||||
1 = Disable INTR and QUIT keys (Ctrl-C and Ctrl-\);
|
||||
2 = Count Ctrl-Break (don't kill);
|
||||
4 = IRET from our timer interrupt handler, don't chain */
|
||||
extern unsigned short __djgpp_hwint_flags;
|
||||
extern unsigned __djgpp_cbrk_count; /* Count of CTRL-BREAK hits */
|
||||
extern int __djgpp_exception_inprog; /* Nested exception count */
|
||||
|
||||
extern unsigned short __djgpp_sigint_key; /* key that raises SIGINT */
|
||||
extern unsigned short __djgpp_sigquit_key; /* key that raises SIGQUIT */
|
||||
extern unsigned short __djgpp_sigint_mask; /* kb mask for SIGINT key */
|
||||
extern unsigned short __djgpp_sigquit_mask;/* kb mask for SIGQUIT key */
|
||||
|
||||
void __djgpp_exception_toggle(void);
|
||||
int __djgpp_set_ctrl_c(int __enable); /* On by default */
|
||||
int __djgpp_set_sigint_key(int new_key); /* Set key which raises SIGINT */
|
||||
int __djgpp_set_sigquit_key(int new_key); /* Set key which raises SIGQUIT */
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_exceptn_h__ */
|
@@ -1,247 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (c) 1995 DJ Delorie. Permission granted to use for any
|
||||
purpose, provided this copyright remains attached and unmodified.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
|
||||
IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
|
||||
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
|
||||
|
||||
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͻ
|
||||
<EFBFBD> Far Pointer Simulation Functions <09>
|
||||
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͼ
|
||||
|
||||
This file attempts to make up for the lack of a "far" keyword in GCC.
|
||||
Although it doesn't provide access to far call APIs (like Windows), it
|
||||
does allow you to do far pointer data access without the overhead of
|
||||
movedata() or dosmemget/dosmemput().
|
||||
|
||||
You should *always* include this file when using these functions and
|
||||
compile with optimization enabled. They don't exist as normal functions
|
||||
in any library, and they compile down to only a few opcodes when used
|
||||
this way. They are almost as fast as native pointer operations, and
|
||||
about as fast as far pointers can get.
|
||||
|
||||
If you don't use optimization, this file becomes prototypes for
|
||||
farptr.c, which generates real functions for these when not optimizing.
|
||||
When optimizing, farptr.c compiles to nothing.
|
||||
|
||||
There are two types of functions here - standalone and invariant. The
|
||||
standalone functions take a selector and offset. These are used when
|
||||
you need only a few accesses, time isn't critical, or you don't know
|
||||
what's in the %fs register. The invariant ones don't take a selector,
|
||||
they only take an offset. These are used inside loops and in
|
||||
time-critical accesses where the selector doesn't change. To specify
|
||||
the selector, use the farsetsel() function. That selector is used for
|
||||
all farns*() functions until changed. You can use _fargetsel() if you
|
||||
want to temporary change the selector with _farsetsel() and restore
|
||||
it afterwards.
|
||||
|
||||
The farpoke* and farpeek* take selectors.
|
||||
|
||||
The farnspoke* and farnspeek* don't (note the `ns' for `no selector').
|
||||
|
||||
Warning: These routines all use the %fs register for their accesses.
|
||||
GCC normally uses only %ds and %es, and libc functions (movedata,
|
||||
dosmemget, dosmemput) use %gs. Still, you should be careful about
|
||||
assumptions concerning whether or not the value you put in %fs will be
|
||||
preserved across calls to other functions. If you guess wrong, your
|
||||
program will crash. Better safe than sorry.
|
||||
|
||||
*/
|
||||
|
||||
#ifndef __dj_include_sys_farptr_h_
|
||||
#define __dj_include_sys_farptr_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
void _farpokeb(unsigned short, unsigned long, unsigned char);
|
||||
void _farpokew(unsigned short, unsigned long, unsigned short);
|
||||
void _farpokel(unsigned short, unsigned long, unsigned long);
|
||||
unsigned char _farpeekb(unsigned short, unsigned long);
|
||||
unsigned short _farpeekw(unsigned short, unsigned long);
|
||||
unsigned long _farpeekl(unsigned short, unsigned long);
|
||||
void _farsetsel(unsigned short);
|
||||
unsigned short _fargetsel(void);
|
||||
void _farnspokeb(unsigned long, unsigned char);
|
||||
void _farnspokew(unsigned long, unsigned short);
|
||||
void _farnspokel(unsigned long, unsigned long);
|
||||
unsigned char _farnspeekb(unsigned long);
|
||||
unsigned short _farnspeekw(unsigned long);
|
||||
unsigned long _farnspeekl(unsigned long);
|
||||
|
||||
extern __inline__ void
|
||||
_farpokeb(unsigned short selector,
|
||||
unsigned long offset,
|
||||
unsigned char value)
|
||||
{
|
||||
__asm__ __volatile__ ("movw %w0,%%fs\n"
|
||||
" .byte 0x64 \n"
|
||||
" movb %b1,(%k2)"
|
||||
:
|
||||
: "rm" (selector), "qi" (value), "r" (offset));
|
||||
}
|
||||
|
||||
extern __inline__ void
|
||||
_farpokew(unsigned short selector,
|
||||
unsigned long offset,
|
||||
unsigned short value)
|
||||
{
|
||||
__asm__ __volatile__ ("movw %w0,%%fs \n"
|
||||
" .byte 0x64 \n"
|
||||
" movw %w1,(%k2)"
|
||||
:
|
||||
: "rm" (selector), "ri" (value), "r" (offset));
|
||||
}
|
||||
|
||||
extern __inline__ void
|
||||
_farpokel(unsigned short selector,
|
||||
unsigned long offset,
|
||||
unsigned long value)
|
||||
{
|
||||
__asm__ __volatile__ ("movw %w0,%%fs \n"
|
||||
" .byte 0x64 \n"
|
||||
" movl %k1,(%k2)"
|
||||
:
|
||||
: "rm" (selector), "ri" (value), "r" (offset));
|
||||
}
|
||||
|
||||
extern __inline__ unsigned char
|
||||
_farpeekb(unsigned short selector,
|
||||
unsigned long offset)
|
||||
{
|
||||
unsigned char result;
|
||||
__asm__ __volatile__ ("movw %w1,%%fs \n"
|
||||
" .byte 0x64 \n"
|
||||
" movb (%k2),%b0"
|
||||
: "=q" (result)
|
||||
: "rm" (selector), "r" (offset));
|
||||
return result;
|
||||
}
|
||||
|
||||
extern __inline__ unsigned short
|
||||
_farpeekw(unsigned short selector,
|
||||
unsigned long offset)
|
||||
{
|
||||
unsigned short result;
|
||||
__asm__ __volatile__ ("movw %w1, %%fs \n"
|
||||
" .byte 0x64 \n"
|
||||
" movw (%k2),%w0 \n"
|
||||
: "=r" (result)
|
||||
: "rm" (selector), "r" (offset));
|
||||
return result;
|
||||
}
|
||||
|
||||
extern __inline__ unsigned long
|
||||
_farpeekl(unsigned short selector,
|
||||
unsigned long offset)
|
||||
{
|
||||
unsigned long result;
|
||||
__asm__ __volatile__ ("movw %w1,%%fs\n"
|
||||
" .byte 0x64\n"
|
||||
" movl (%k2),%k0"
|
||||
: "=r" (result)
|
||||
: "rm" (selector), "r" (offset));
|
||||
return result;
|
||||
}
|
||||
|
||||
extern __inline__ void
|
||||
_farsetsel(unsigned short selector)
|
||||
{
|
||||
__asm__ __volatile__ ("movw %w0,%%fs"
|
||||
:
|
||||
: "rm" (selector));
|
||||
}
|
||||
|
||||
extern __inline__ unsigned short
|
||||
_fargetsel(void)
|
||||
{
|
||||
unsigned short selector;
|
||||
__asm__ __volatile__ ("movw %%fs,%w0 \n"
|
||||
: "=r" (selector)
|
||||
: );
|
||||
return selector;
|
||||
}
|
||||
|
||||
extern __inline__ void
|
||||
_farnspokeb(unsigned long offset,
|
||||
unsigned char value)
|
||||
{
|
||||
__asm__ __volatile__ (".byte 0x64\n"
|
||||
" movb %b0,(%k1)"
|
||||
:
|
||||
: "qi" (value), "r" (offset));
|
||||
}
|
||||
|
||||
extern __inline__ void
|
||||
_farnspokew(unsigned long offset,
|
||||
unsigned short value)
|
||||
{
|
||||
__asm__ __volatile__ (".byte 0x64\n"
|
||||
" movw %w0,(%k1)"
|
||||
:
|
||||
: "ri" (value), "r" (offset));
|
||||
}
|
||||
|
||||
extern __inline__ void
|
||||
_farnspokel(unsigned long offset,
|
||||
unsigned long value)
|
||||
{
|
||||
__asm__ __volatile__ (".byte 0x64\n"
|
||||
" movl %k0,(%k1)"
|
||||
:
|
||||
: "ri" (value), "r" (offset));
|
||||
}
|
||||
|
||||
extern __inline__ unsigned char
|
||||
_farnspeekb(unsigned long offset)
|
||||
{
|
||||
unsigned char result;
|
||||
__asm__ __volatile__ (".byte 0x64\n"
|
||||
" movb (%k1),%b0"
|
||||
: "=q" (result)
|
||||
: "r" (offset));
|
||||
return result;
|
||||
}
|
||||
|
||||
extern __inline__ unsigned short
|
||||
_farnspeekw(unsigned long offset)
|
||||
{
|
||||
unsigned short result;
|
||||
__asm__ __volatile__ (".byte 0x64\n"
|
||||
" movw (%k1),%w0"
|
||||
: "=r" (result)
|
||||
: "r" (offset));
|
||||
return result;
|
||||
}
|
||||
|
||||
extern __inline__ unsigned long
|
||||
_farnspeekl(unsigned long offset)
|
||||
{
|
||||
unsigned long result;
|
||||
__asm__ __volatile__ (".byte 0x64\n"
|
||||
" movl (%k1),%k0"
|
||||
: "=r" (result)
|
||||
: "r" (offset));
|
||||
return result;
|
||||
}
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_farptr_h_ */
|
@@ -1,28 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_fcntl_h_
|
||||
#define __dj_include_sys_fcntl_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#include <fcntl.h>
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_fcntl_h_ */
|
@@ -1,33 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_file_h_
|
||||
#define __dj_include_sys_file_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <unistd.h>
|
||||
#define L_SET 0
|
||||
#define L_CURR 1
|
||||
#define L_INCR 1
|
||||
#define L_XTND 2
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_file_h_ */
|
@@ -1,69 +0,0 @@
|
||||
/* Copyright (C) 1998 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_fsext_h_
|
||||
#define __dj_include_sys_fsext_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#include <stdarg.h>
|
||||
|
||||
typedef enum {
|
||||
__FSEXT_nop,
|
||||
__FSEXT_open,
|
||||
__FSEXT_creat,
|
||||
__FSEXT_read,
|
||||
__FSEXT_write,
|
||||
__FSEXT_ready,
|
||||
__FSEXT_close,
|
||||
__FSEXT_fcntl,
|
||||
__FSEXT_ioctl,
|
||||
__FSEXT_lseek,
|
||||
__FSEXT_link,
|
||||
__FSEXT_unlink,
|
||||
__FSEXT_dup,
|
||||
__FSEXT_dup2,
|
||||
__FSEXT_fstat,
|
||||
__FSEXT_stat
|
||||
} __FSEXT_Fnumber;
|
||||
|
||||
/* _ready gets passed a fd and should return a mask of these,
|
||||
as if we were emulating "int ready(int fd)" */
|
||||
#define __FSEXT_ready_read 1
|
||||
#define __FSEXT_ready_write 2
|
||||
#define __FSEXT_ready_error 4
|
||||
|
||||
/* The return value is nonzero if the function has overridden the
|
||||
caller's functionality. */
|
||||
typedef int (__FSEXT_Function)(__FSEXT_Fnumber _function_number,
|
||||
int *_rv, /*va_list*/void* _args);
|
||||
|
||||
int __FSEXT_alloc_fd(__FSEXT_Function *_function);
|
||||
int __FSEXT_set_function(int _fd, __FSEXT_Function *_function);
|
||||
__FSEXT_Function *__FSEXT_get_function(int _fd);
|
||||
void *__FSEXT_set_data(int _fd, void *_data);
|
||||
void *__FSEXT_get_data(int _fd);
|
||||
|
||||
int __FSEXT_add_open_handler(__FSEXT_Function *_function);
|
||||
int __FSEXT_call_open_handlers(__FSEXT_Fnumber _function_number,
|
||||
int *rv, /*va_list*/void* _args);
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_fsext_h_ */
|
@@ -1,361 +0,0 @@
|
||||
/* Copyright (C) 1996 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_ioctl_h_
|
||||
#define __dj_include_sys_ioctl_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"{
|
||||
#endif
|
||||
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
/*
|
||||
** plain ioctl functions. Do not use them.
|
||||
** Never. Really _N_E_V_E_R_. Unless you really know what
|
||||
** you are doing.
|
||||
**
|
||||
*/
|
||||
#define DOS_PLAIN_GETDEVDATA 0x00
|
||||
#define DOS_PLAIN_SETDEVDATA 0x01
|
||||
#define DOS_PLAIN_RCVDATA 0x02
|
||||
#define DOS_PLAIN_SNDDATA 0x03
|
||||
#define DOS_PLAIN_RCVCTLDATA 0x04
|
||||
#define DOS_PLAIN_SNDCTLDATA 0x05
|
||||
#define DOS_PLAIN_CHKINSTAT 0x06
|
||||
#define DOS_PLAIN_CHKOUTSTAT 0x07
|
||||
#define DOS_PLAIN_ISCHANGEABLE 0x08
|
||||
#define DOS_PLAIN_ISREDIRBLK 0x09
|
||||
#define DOS_PLAIN_ISREDIRHND 0x0a
|
||||
#define DOS_PLAIN_SETRETRY 0x0b
|
||||
#define DOS_PLAIN_GENCHARREQ 0x0c
|
||||
#define DOS_PLAIN_GENBLKREQ 0x0d
|
||||
#define DOS_PLAIN_GLDRVMAP 0x0e
|
||||
#define DOS_PLAIN_SLDRVMAP 0x0f
|
||||
#define DOS_PLAIN_QGIOCTLCAPH 0x10
|
||||
#define DOS_PLAIN_QGIOCTLCAPD 0x11
|
||||
/*
|
||||
** Flags for DOS commands
|
||||
*/
|
||||
#define DOS_XFER 0x8000 /* use xfer buffer */
|
||||
#define DOS_RETMASK 0x7000 /* Here we put the bits to tell */
|
||||
/* what to return. 8 possible values */
|
||||
#define DOS_BRAINDEAD 0x0400 /* CX does not hold the number of */
|
||||
/* bytes to transfer */
|
||||
|
||||
#define DOS_XINARGS(a) ((a & 3)<<12) /* How many extra args we expect. */
|
||||
#define DOS_RETAX 0x1000 /* return AX as result */
|
||||
#define DOS_RETDX 0x2000 /* return DX as result */
|
||||
#define DOS_RETDISI 0x3000 /* return DI SI as result */
|
||||
/*
|
||||
** DOS ioctls we support:
|
||||
*/
|
||||
#define DOS_GETDEVDATA (DOS_PLAIN_GETDEVDATA| DOS_RETDX|DOS_XINARGS(0))
|
||||
#define DOS_SETDEVDATA (DOS_PLAIN_SETDEVDATA| DOS_XINARGS(1))
|
||||
#define DOS_RCVDATA (DOS_PLAIN_RCVDATA |DOS_XFER|DOS_RETAX|DOS_XINARGS(1))
|
||||
#define DOS_SNDDATA (DOS_PLAIN_SNDDATA |DOS_XFER|DOS_RETAX|DOS_XINARGS(1))
|
||||
#define DOS_RCVCTLDATA (DOS_PLAIN_RCVCTLDATA|DOS_XFER|DOS_RETAX|DOS_XINARGS(1))
|
||||
#define DOS_SNDCTLDATA (DOS_PLAIN_SNDCTLDATA|DOS_XFER|DOS_RETAX|DOS_XINARGS(1))
|
||||
#define DOS_CHKINSTAT (DOS_PLAIN_CHKINSTAT | DOS_RETAX)
|
||||
#define DOS_CHKOUTSTAT (DOS_PLAIN_CHKOUTSTAT| DOS_RETAX)
|
||||
#define DOS_ISCHANGEABLE (DOS_PLAIN_ISCHANGEABLE| DOS_RETAX)
|
||||
#define DOS_ISREDIRBLK (DOS_PLAIN_ISREDIRBLK| DOS_RETDX)
|
||||
#define DOS_ISREDIRHND (DOS_PLAIN_ISREDIRHND| DOS_RETDX)
|
||||
#define DOS_SETRETRY (DOS_PLAIN_SETRETRY| DOS_XINARGS(1))
|
||||
/*
|
||||
These ones do not fit into my scheme, because they _DO_NOT_ put the size
|
||||
of the xfer buffer in CX. Aaaaargh
|
||||
*/
|
||||
#define DOS_GENCHARREQ (DOS_PLAIN_GENCHARREQ|DOS_BRAINDEAD|DOS_RETDISI)
|
||||
#define DOS_GENBLKREQ (DOS_PLAIN_GENBLKREQ |DOS_BRAINDEAD|DOS_RETAX)
|
||||
#define DOS_GLDRVMAP (DOS_PLAIN_GLDRVMAP| DOS_RETAX)
|
||||
#define DOS_SLDRVMAP (DOS_PLAIN_SLDRVMAP| DOS_RETAX)
|
||||
#define DOS_QGIOCTLCAPH (DOS_PLAIN_QGIOCTLCAPH| DOS_RETAX)
|
||||
#define DOS_QGIOCTLCAPD (DOS_PLAIN_QGIOCTLCAPD| DOS_RETAX)
|
||||
|
||||
|
||||
#define __IS_UNIX_IOCTL(a) ((a) & 0xd0000000U)
|
||||
#if 0
|
||||
/*
|
||||
** UNIX stuff
|
||||
**
|
||||
** This is subject to major changes in the near future.
|
||||
** Do not use it yet.
|
||||
*/
|
||||
|
||||
/*
|
||||
** __WARNING__ :
|
||||
** This ifdef works for DJGPP, because its io.h
|
||||
** defines __djgpp_include_io_h_
|
||||
*/
|
||||
#ifndef _IO
|
||||
/*
|
||||
* Ioctl's have the command encoded in the lower word,
|
||||
* and the size of any in or out parameters in the upper
|
||||
* word. The high 2 bits of the upper word are used
|
||||
* to encode the in/out status of the parameter; for now
|
||||
* we restrict parameters to at most 128 bytes.
|
||||
*/
|
||||
#define IOCPARM_MASK 0x7f /* parameters must be < 128 bytes */
|
||||
#define IOC_VOID 0x20000000 /* no parameters */
|
||||
#define IOC_OUT 0x40000000 /* copy out parameters */
|
||||
#define IOC_IN 0x80000000 /* copy in parameters */
|
||||
#define IOC_INOUT (IOC_IN|IOC_OUT)
|
||||
/* the 0x20000000 is so we can distinguish new ioctl's from old */
|
||||
#define _IO(x,y) (IOC_VOID|(x<<8)|y)
|
||||
#define _IOR(x,y,t) (IOC_OUT|((sizeof(t)&IOCPARM_MASK)<<16)|(x<<8)|y)
|
||||
#define _IOW(x,y,t) (IOC_IN|((sizeof(t)&IOCPARM_MASK)<<16)|(x<<8)|y)
|
||||
/* this should be _IORW, but stdio got there first */
|
||||
#define _IOWR(x,y,t) (IOC_INOUT|((sizeof(t)&IOCPARM_MASK)<<16)|(x<<8)|y)
|
||||
#endif /* _IO */
|
||||
/* Common ioctl's for all disciplines which are handled in ttiocom */
|
||||
enum tty_ioctl {
|
||||
TXISATTY = ('X'<<8), /* quick path for isatty */
|
||||
TXTTYNAME, /* quick path for ttyname */
|
||||
TXGETLD, /* get line discipline */
|
||||
TXSETLD, /* set line discipline */
|
||||
TXGETCD, /* get control disciplines */
|
||||
TXADDCD, /* add control discipline */
|
||||
TXDELCD, /* delete control discipline */
|
||||
TXSBAUD, /* set integer baud rate */
|
||||
TXGBAUD, /* get integer baud rate */
|
||||
TXSETIHOG, /* set the input buffer limit */
|
||||
TXSETOHOG, /* set the output buffer limit */
|
||||
TXGPGRP, /* get p grp with posix security */
|
||||
TXSPGRP /* set p grp with posix security */
|
||||
};
|
||||
|
||||
#define TTNAMEMAX 32 /* used with TXGETLD, et al */
|
||||
|
||||
union txname { /* used with TXGETCD */
|
||||
int tx_which; /* which name to get -- inbound */
|
||||
char tx_name[TTNAMEMAX];/* the name -- outbound */
|
||||
};
|
||||
|
||||
/*
|
||||
* window size structure used with TXSETWIN and TXGETWIN. This is
|
||||
* exactly the same as the Berkeley structure and can be used with
|
||||
* TIOCSWINSZ and TIOCGWINSZ -- in fact they are defined to be the
|
||||
* same.
|
||||
*/
|
||||
struct winsize {
|
||||
unsigned short ws_row; /* rows, in characters */
|
||||
unsigned short ws_col; /* columns, in characters */
|
||||
unsigned short ws_xpixel; /* horizontal size, pixels */
|
||||
unsigned short ws_ypixel; /* vertical size, pixels */
|
||||
};
|
||||
|
||||
struct tchars {
|
||||
char t_intrc; /* interrupt */
|
||||
char t_quitc; /* quit */
|
||||
char t_startc; /* start output */
|
||||
char t_stopc; /* stop output */
|
||||
char t_eofc; /* end-of-file */
|
||||
char t_brkc; /* input delimiter (like nl) */
|
||||
};
|
||||
struct ltchars {
|
||||
char t_suspc; /* stop process signal */
|
||||
char t_dsuspc; /* delayed stop process signal */
|
||||
char t_rprntc; /* reprint line */
|
||||
char t_flushc; /* flush output (toggles) */
|
||||
char t_werasc; /* word erase */
|
||||
char t_lnextc; /* literal next character */
|
||||
};
|
||||
|
||||
/*
|
||||
* Structure for TIOCGETP and TIOCSETP ioctls.
|
||||
*/
|
||||
|
||||
struct sgttyb {
|
||||
char sg_ispeed; /* input speed */
|
||||
char sg_ospeed; /* output speed */
|
||||
char sg_erase; /* erase character */
|
||||
char sg_kill; /* kill character */
|
||||
short sg_flags; /* mode flags */
|
||||
};
|
||||
|
||||
/*
|
||||
* Pun for SUN.
|
||||
*/
|
||||
struct ttysize {
|
||||
unsigned short ts_lines;
|
||||
unsigned short ts_cols;
|
||||
unsigned short ts_xxx;
|
||||
unsigned short ts_yyy;
|
||||
};
|
||||
#define TIOCGSIZE TIOCGWINSZ
|
||||
#define TIOCSSIZE TIOCSWINSZ
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#define TIOCGETD _IOR('t', 0, int) /* get line discipline */
|
||||
#define TIOCSETD _IOW('t', 1, int) /* set line discipline */
|
||||
#define TIOCHPCL _IO('t', 2) /* hang up on last close */
|
||||
#define TIOCMODG _IOR('t', 3, int) /* get modem control state */
|
||||
#define TIOCMODS _IOW('t', 4, int) /* set modem control state */
|
||||
#define TIOCM_LE 0001 /* line enable */
|
||||
#define TIOCM_DTR 0002 /* data terminal ready */
|
||||
#define TIOCM_RTS 0004 /* request to send */
|
||||
#define TIOCM_ST 0010 /* secondary transmit */
|
||||
#define TIOCM_SR 0020 /* secondary receive */
|
||||
#define TIOCM_CTS 0040 /* clear to send */
|
||||
#define TIOCM_CAR 0100 /* carrier detect */
|
||||
#define TIOCM_CD TIOCM_CAR
|
||||
#define TIOCM_RNG 0200 /* ring */
|
||||
#define TIOCM_RI TIOCM_RNG
|
||||
#define TIOCM_DSR 0400 /* data set ready */
|
||||
#define TIOCGETP _IOR('t', 8,struct sgttyb) /* get parameters -- gtty */
|
||||
#define TIOCSETP _IOW('t', 9,struct sgttyb) /* set parameters -- stty */
|
||||
#define TIOCSETN _IOW('t',10,struct sgttyb) /* as above, but no flushtty */
|
||||
#define TIOCEXCL _IO('t', 13) /* set exclusive use of tty */
|
||||
#define TIOCNXCL _IO('t', 14) /* reset exclusive use of tty */
|
||||
#define TIOCFLUSH _IOW('t', 16, int) /* flush buffers */
|
||||
#define TIOCSETC _IOW('t',17,struct tchars) /* set special characters */
|
||||
#define TIOCGETC _IOR('t',18,struct tchars) /* get special characters */
|
||||
#define TANDEM 0x00000001 /* send stopc on out q full */
|
||||
#define CBREAK 0x00000002 /* half-cooked mode */
|
||||
#define LCASE 0x00000004 /* simulate lower case */
|
||||
#define ECHO 0x00000008 /* echo input */
|
||||
#define CRMOD 0x00000010 /* map \r to \r\n on output */
|
||||
#define RAW 0x00000020 /* no i/o processing */
|
||||
#define ODDP 0x00000040 /* get/send odd parity */
|
||||
#define EVENP 0x00000080 /* get/send even parity */
|
||||
#define ANYP 0x000000c0 /* get any parity/send none */
|
||||
#define CRDELAY 0x00000300 /* \r delay */
|
||||
#define CR0 0x00000000
|
||||
#define CR1 0x00000100 /* tn 300 */
|
||||
#define CR2 0x00000200 /* tty 37 */
|
||||
#define CR3 0x00000300 /* concept 100 */
|
||||
#define TBDELAY 0x00000c00 /* horizontal tab delay */
|
||||
#define TAB0 0x00000000
|
||||
#define TAB1 0x00000400 /* tty 37 */
|
||||
#define TAB2 0x00000800
|
||||
#define XTABS 0x00000c00 /* expand tabs on output */
|
||||
#define BSDELAY 0x00001000 /* \b delay */
|
||||
#define BS0 0x00000000
|
||||
#define BS1 0x00001000
|
||||
#define VTDELAY 0x00002000 /* vertical tab delay */
|
||||
#define FF0 0x00000000
|
||||
#define FF1 0x00002000 /* tty 37 */
|
||||
#define NLDELAY 0x0000c000 /* \n delay */
|
||||
#define NL0 0x00000000
|
||||
#define NL1 0x00004000 /* tty 37 */
|
||||
#define NL2 0x00008000 /* vt05 */
|
||||
#define NL3 0x0000c000
|
||||
#define ALLDELAY (NLDELAY|TBDELAY|CRDELAY|VTDELAY|BSDELAY)
|
||||
#define TOSTOP 0x00010000 /* SIGSTOP on bckgnd output */
|
||||
#define PRTERA 0x00020000 /* \ ... / erase */
|
||||
#define CRTERA 0x00040000 /* " \b " to wipe out char */
|
||||
#define TILDE 0x00080000 /* hazeltine tilde kludge */
|
||||
#define FLUSHO 0x00100000 /* flush output to terminal */
|
||||
#define LITOUT 0x00200000 /* literal output */
|
||||
#define CRTBS 0x00400000 /* do backspacing for crt */
|
||||
#define MDMBUF 0x00800000 /* dtr pacing */
|
||||
#define NOHANG 0x01000000 /* no SIGHUP on carrier drop */
|
||||
#define L001000 0x02000000
|
||||
#define CRTKIL 0x04000000 /* kill line with " \b " */
|
||||
#define PASS8 0x08000000
|
||||
#define CTLECH 0x10000000 /* echo control chars as ^X */
|
||||
#define PENDIN 0x20000000 /* tp->t_rawq needs reread */
|
||||
#define DECCTQ 0x40000000 /* only ^Q starts after ^S */
|
||||
#define NOFLUSH 0x80000000 /* no output flush on signal */
|
||||
#define TIOCCONS _IOW('t', 98, int) /* become virtual console */
|
||||
#ifdef _BSD_INCLUDES
|
||||
/*
|
||||
* Added for 4.3 BSD.
|
||||
*/
|
||||
#define NOFLSH NOFLUSH /* no output flush on signal */
|
||||
#endif /* _BSD_INCLUDES */
|
||||
|
||||
/* locals, from 127 down */
|
||||
#define TIOCLBIS _IOW('t', 127, int) /* bis local mode bits */
|
||||
#define TIOCLBIC _IOW('t', 126, int) /* bic local mode bits */
|
||||
#define TIOCLSET _IOW('t', 125, int) /* set entire mode word */
|
||||
#define TIOCLGET _IOR('t', 124, int) /* get local modes */
|
||||
#define LCRTBS (CRTBS>>16)
|
||||
#define LPRTERA (PRTERA>>16)
|
||||
#define LCRTERA (CRTERA>>16)
|
||||
#define LTILDE (TILDE>>16)
|
||||
#define LMDMBUF (MDMBUF>>16)
|
||||
#define LLITOUT (LITOUT>>16)
|
||||
#define LTOSTOP (TOSTOP>>16)
|
||||
#define LFLUSHO (FLUSHO>>16)
|
||||
#define LNOHANG (NOHANG>>16)
|
||||
#define LCRTKIL (CRTKIL>>16)
|
||||
#define LPASS8 (PASS8>>16)
|
||||
#define LCTLECH (CTLECH>>16)
|
||||
#define LPENDIN (PENDIN>>16)
|
||||
#define LDECCTQ (DECCTQ>>16)
|
||||
#define LNOFLSH (NOFLUSH>>16)
|
||||
#define TIOCSBRK _IO('t', 123) /* set break bit */
|
||||
#define TIOCCBRK _IO('t', 122) /* clear break bit */
|
||||
#define TIOCSDTR _IO('t', 121) /* set data terminal ready */
|
||||
#define TIOCCDTR _IO('t', 120) /* clear data terminal ready */
|
||||
#define TIOCGPGRP _IOR('t', 119, int) /* get process group */
|
||||
#define TIOCSPGRP _IOW('t', 118, int) /* set process gorup */
|
||||
#define TIOCSLTC _IOW('t',117,struct ltchars) /* set local special chars */
|
||||
#define TIOCGLTC _IOR('t',116,struct ltchars) /* get local special chars */
|
||||
#define TIOCOUTQ _IOR('t', 115, int) /* output queue size */
|
||||
#define TIOCSTI _IOW('t', 114, char) /* simulate terminal input */
|
||||
#define TIOCNOTTY _IO('t', 113) /* void tty association */
|
||||
#define TIOCPKT _IOW('t', 112, int) /* pty: set/clear packet mode */
|
||||
#define TIOCPKT_DATA 0x00 /* data packet */
|
||||
#define TIOCPKT_FLUSHREAD 0x01 /* flush packet */
|
||||
#define TIOCPKT_FLUSHWRITE 0x02 /* flush packet */
|
||||
#define TIOCPKT_STOP 0x04 /* stop output */
|
||||
#define TIOCPKT_START 0x08 /* start output */
|
||||
#define TIOCPKT_NOSTOP 0x10 /* no more ^S, ^Q */
|
||||
#define TIOCPKT_DOSTOP 0x20 /* now do ^S ^Q */
|
||||
#define TIOCSTOP _IO('t', 111) /* stop output, like ^S */
|
||||
#define TIOCSTART _IO('t', 110) /* start output, like ^Q */
|
||||
#define TIOCMSET _IOW('t', 109, int) /* set all modem bits */
|
||||
#define TIOCMBIS _IOW('t', 108, int) /* bis modem bits */
|
||||
#define TIOCMBIC _IOW('t', 107, int) /* bic modem bits */
|
||||
#define TIOCMGET _IOR('t', 106, int) /* get all modem bits */
|
||||
#define TIOCREMOTE _IOW('t', 105, int) /* remote input editing */
|
||||
#define TIOCGWINSZ _IOR('t', 104, struct winsize) /* get window size */
|
||||
#define TIOCSWINSZ _IOW('t', 103, struct winsize) /* set window size */
|
||||
#define TIOCUCNTL _IOW('t', 102, int) /* pty: set/clr usr cntl mode */
|
||||
#define UIOCCMD(n) _IO('u', n) /* usr cntl op "n" */
|
||||
|
||||
#define OTTYDISC 0 /* old, v7 std tty driver */
|
||||
#define NETLDISC 1 /* line discip for berk net */
|
||||
#define NTTYDISC 2 /* new tty discipline */
|
||||
#define TABLDISC 3 /* tablet discipline */
|
||||
#define SLIPDISC 4 /* serial IP discipline */
|
||||
|
||||
#define FIOCLEX _IO('f', 1) /* set exclusive use on fd */
|
||||
#define FIONCLEX _IO('f', 2) /* remove exclusive use */
|
||||
/* another local */
|
||||
|
||||
#define FIONREAD _IOR('f', 127, int) /* get # bytes to read */
|
||||
#define FIONBIO _IOW('f', 126, int) /* set/clear non-blocking i/o */
|
||||
#define FIOASYNC _IOW('f', 125, int) /* set/clear async i/o */
|
||||
|
||||
#define FIOSETOWN _IOW('f', 124, int) /* set owner */
|
||||
#define FIOGETOWN _IOR('f', 123, int) /* get owner */
|
||||
|
||||
|
||||
#endif /* 0 */
|
||||
|
||||
int ioctl( int fd, int cmd, ...);
|
||||
|
||||
|
||||
#endif /* ! _POSIX_SOURCE */
|
||||
#endif /* ! __STRICT_ANSI__ */
|
||||
#endif /* ! __dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_ioctl_h_ */
|
||||
|
@@ -1,34 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_mman_h_
|
||||
#define __dj_include_sys_mman_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
/* protections are chosen from these bits, or-ed together */
|
||||
#define PROT_NONE 0 /* no access to these pages */
|
||||
#define PROT_READ 0x1 /* pages can be read */
|
||||
#define PROT_WRITE 0x2 /* pages can be written */
|
||||
#define PROT_EXEC 0 /* pages can be executed - not used */
|
||||
|
||||
extern int mprotect(void *addr, size_t len, int prot);
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_mman_h_ */
|
@@ -1,30 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_mono_h_
|
||||
#define __dj_include_sys_mono_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
void _mono_clear(void);
|
||||
void _mono_printf(const char *fmt, ...) __attribute__((format(printf,1,2)));
|
||||
void _mono_putc(int c);
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_mono_h_ */
|
@@ -1,60 +0,0 @@
|
||||
/* Copyright (C) 1998 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_movedata_h_
|
||||
#define __dj_include_sys_movedata_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#include <sys/djtypes.h>
|
||||
|
||||
__DJ_size_t
|
||||
#undef __DJ_size_t
|
||||
#define __DJ_size_t
|
||||
|
||||
/* This header is intended to be included only by other
|
||||
headers, like <go32.h> and <string.h>. You may
|
||||
include this directly, but it will be non-portable. */
|
||||
|
||||
/* These lengths are in bytes, optimized for speed */
|
||||
void dosmemget(unsigned long _offset, size_t _length, void *_buffer);
|
||||
void dosmemput(const void *_buffer, size_t _length, unsigned long _offset);
|
||||
|
||||
/* The lengths here are in TRANSFERS, not bytes! */
|
||||
void _dosmemgetb(unsigned long _offset, size_t _xfers, void *_buffer);
|
||||
void _dosmemgetw(unsigned long _offset, size_t _xfers, void *_buffer);
|
||||
void _dosmemgetl(unsigned long _offset, size_t _xfers, void *_buffer);
|
||||
void _dosmemputb(const void *_buffer, size_t _xfers, unsigned long _offset);
|
||||
void _dosmemputw(const void *_buffer, size_t _xfers, unsigned long _offset);
|
||||
void _dosmemputl(const void *_buffer, size_t _xfers, unsigned long _offset);
|
||||
|
||||
|
||||
/* This length is in bytes, optimized for speed */
|
||||
void movedata(unsigned _source_selector, unsigned _source_offset,
|
||||
unsigned _dest_selector, unsigned _dest_offset,
|
||||
size_t _length);
|
||||
|
||||
/* The lengths here are in TRANSFERS, not bytes! */
|
||||
void _movedatab(unsigned, unsigned, unsigned, unsigned, size_t);
|
||||
void _movedataw(unsigned, unsigned, unsigned, unsigned, size_t);
|
||||
void _movedatal(unsigned, unsigned, unsigned, unsigned, size_t);
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_movedata_h_ */
|
@@ -1,37 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_nearptr_h_
|
||||
#define __dj_include_sys_nearptr_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
/* Functions to enable "near" pointer access to DOS memory under DPMI
|
||||
CW Sandmann 7-95 NO WARRANTY: WARNING, since these functions disable
|
||||
memory protection, they MAY DESTROY EVERYTHING ON YOUR COMPUTER! */
|
||||
|
||||
int __djgpp_nearptr_enable(void); /* Returns 0 if feature not avail */
|
||||
void __djgpp_nearptr_disable(void); /* Enables protection */
|
||||
extern int __djgpp_selector_limit; /* Limit on CS and on DS if prot */
|
||||
extern int __djgpp_base_address; /* Used in calculation below */
|
||||
|
||||
#define __djgpp_conventional_base (-__djgpp_base_address)
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_nearptr_h_ */
|
@@ -1,31 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_param_h_
|
||||
#define __dj_include_sys_param_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#include <limits.h>
|
||||
|
||||
#define MAXPATHLEN PATH_MAX
|
||||
#define MAXGETHOSTNAME 128
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_param_h_ */
|
@@ -1,73 +0,0 @@
|
||||
/* Copyright (C) 1996 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_resource_h_
|
||||
#define __dj_include_sys_resource_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#include <time.h>
|
||||
|
||||
#define RUSAGE_SELF 0 /* calling process */
|
||||
#define RUSAGE_CHILDREN -1 /* terminated child processes */
|
||||
|
||||
struct rusage {
|
||||
struct timeval ru_utime; /* user time used */
|
||||
struct timeval ru_stime; /* system time used */
|
||||
long ru_maxrss; /* integral max resident set size */
|
||||
long ru_ixrss; /* integral shared text memory size */
|
||||
long ru_idrss; /* integral unshared data size */
|
||||
long ru_isrss; /* integral unshared stack size */
|
||||
long ru_minflt; /* page reclaims */
|
||||
long ru_majflt; /* page faults */
|
||||
long ru_nswap; /* swaps */
|
||||
long ru_inblock; /* block input operations */
|
||||
long ru_oublock; /* block output operations */
|
||||
long ru_msgsnd; /* messages sent */
|
||||
long ru_msgrcv; /* messages received */
|
||||
long ru_nsignals; /* signals received */
|
||||
long ru_nvcsw; /* voluntary context switches */
|
||||
long ru_nivcsw; /* involuntary context switches */
|
||||
};
|
||||
|
||||
#define RLIMIT_CPU 0 /* cpu time in milliseconds */
|
||||
#define RLIMIT_FSIZE 1 /* maximum file size */
|
||||
#define RLIMIT_DATA 2 /* data size */
|
||||
#define RLIMIT_STACK 3 /* stack size */
|
||||
#define RLIMIT_CORE 4 /* core file size */
|
||||
#define RLIMIT_RSS 5 /* resident set size */
|
||||
#define RLIMIT_MEMLOCK 6 /* locked-in-memory address space */
|
||||
#define RLIMIT_NPROC 7 /* number of processes */
|
||||
#define RLIMIT_NOFILE 8 /* number of open files */
|
||||
|
||||
#define RLIM_NLIMITS 9 /* number of resource limits */
|
||||
#define RLIM_INFINITY ((long) ((1UL << 31) - 1UL))
|
||||
|
||||
struct rlimit {
|
||||
long rlim_cur; /* current (soft) limit */
|
||||
long rlim_max; /* maximum value for rlim_cur */
|
||||
};
|
||||
|
||||
int getrusage(int _who, struct rusage *_rusage);
|
||||
int getrlimit(int _rltype, struct rlimit *_rlimit);
|
||||
int setrlimit(int _rltype, const struct rlimit *_rlimit);
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_resource_h_ */
|
@@ -1,52 +0,0 @@
|
||||
/* Copyright (C) 1999 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1998 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_segments_h_
|
||||
#define __dj_include_sys_segments_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
static __inline__ int
|
||||
_my_cs(void)
|
||||
{
|
||||
unsigned short result;
|
||||
__asm__("movw %%cs,%0" : "=r" (result));
|
||||
return result;
|
||||
}
|
||||
|
||||
static __inline__ int
|
||||
_my_ds(void)
|
||||
{
|
||||
unsigned short result;
|
||||
__asm__("movw %%ds,%0" : "=r" (result));
|
||||
return result;
|
||||
}
|
||||
|
||||
static __inline__ int
|
||||
_my_ss(void)
|
||||
{
|
||||
unsigned short result;
|
||||
__asm__("movw %%ss,%0" : "=r" (result));
|
||||
return result;
|
||||
}
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_segment_h_ */
|
@@ -1,410 +0,0 @@
|
||||
#ifndef _SYS_SOCKET_H
|
||||
#define _SYS_SOCKET_H
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
#include <sys/types.h>
|
||||
#include <inttypes.h>
|
||||
|
||||
__BEGIN_DECLS
|
||||
|
||||
#define SOL_SOCKET 1
|
||||
|
||||
#define SO_DEBUG 1
|
||||
#define SO_REUSEADDR 2
|
||||
#define SO_TYPE 3
|
||||
#define SO_ERROR 4
|
||||
#define SO_DONTROUTE 5
|
||||
#define SO_BROADCAST 6
|
||||
#define SO_SNDBUF 7
|
||||
#define SO_RCVBUF 8
|
||||
#define SO_KEEPALIVE 9
|
||||
#define SO_OOBINLINE 10
|
||||
#define SO_NO_CHECK 11
|
||||
#define SO_PRIORITY 12
|
||||
#define SO_LINGER 13
|
||||
#define SO_BSDCOMPAT 14
|
||||
/* To add :#define SO_REUSEPORT 15 */
|
||||
#define SO_PASSCRED 16
|
||||
#define SO_PEERCRED 17
|
||||
#define SO_RCVLOWAT 18
|
||||
#define SO_SNDLOWAT 19
|
||||
#define SO_RCVTIMEO 20
|
||||
#define SO_SNDTIMEO 21
|
||||
#define SO_ACCEPTCONN 30
|
||||
|
||||
/* Security levels - as per NRL IPv6 - don't actually do anything */
|
||||
#define SO_SECURITY_AUTHENTICATION 22
|
||||
#define SO_SECURITY_ENCRYPTION_TRANSPORT 23
|
||||
#define SO_SECURITY_ENCRYPTION_NETWORK 24
|
||||
|
||||
#define SO_BINDTODEVICE 25
|
||||
|
||||
/* Socket filtering */
|
||||
#define SO_ATTACH_FILTER 26
|
||||
#define SO_DETACH_FILTER 27
|
||||
|
||||
#define SO_PEERNAME 28
|
||||
#define SO_TIMESTAMP 29
|
||||
#define SCM_TIMESTAMP SO_TIMESTAMP
|
||||
|
||||
/* Socket types. */
|
||||
#define SOCK_STREAM 1 /* stream (connection) socket */
|
||||
#define SOCK_DGRAM 2 /* datagram (conn.less) socket */
|
||||
#define SOCK_RAW 3 /* raw socket */
|
||||
#define SOCK_RDM 4 /* reliably-delivered message */
|
||||
#define SOCK_SEQPACKET 5 /* sequential packet socket */
|
||||
#define SOCK_PACKET 10 /* linux specific way of */
|
||||
/* getting packets at the dev */
|
||||
/* level. For writing rarp and */
|
||||
/* other similar things on the */
|
||||
/* user level. */
|
||||
|
||||
struct sockaddr {
|
||||
sa_family_t sa_family;
|
||||
char sa_data[14];
|
||||
};
|
||||
|
||||
struct linger {
|
||||
int l_onoff;
|
||||
int l_linger;
|
||||
};
|
||||
|
||||
struct iovec {
|
||||
void* iov_base; /* BSD uses caddr_t (1003.1g requires void *) */
|
||||
size_t iov_len; /* Must be size_t (1003.1g) */
|
||||
};
|
||||
|
||||
struct msghdr {
|
||||
void* msg_name; /* Socket name */
|
||||
int msg_namelen; /* Length of name */
|
||||
struct iovec* msg_iov; /* Data blocks */
|
||||
size_t msg_iovlen; /* Number of blocks */
|
||||
void* msg_control; /* Per protocol magic (eg BSD file descriptor passing) */
|
||||
size_t msg_controllen; /* Length of cmsg list */
|
||||
unsigned msg_flags;
|
||||
};
|
||||
|
||||
struct cmsghdr {
|
||||
size_t cmsg_len; /* data byte count, including hdr */
|
||||
int cmsg_level; /* originating protocol */
|
||||
int cmsg_type; /* protocol-specific type */
|
||||
};
|
||||
|
||||
#define UIO_FASTIOV 8
|
||||
#define UIO_MAXIOV 1024
|
||||
|
||||
/* "Socket"-level control message types: */
|
||||
|
||||
#define SCM_RIGHTS 0x01 /* rw: access rights (array of int) */
|
||||
#define SCM_CREDENTIALS 0x02 /* rw: struct ucred */
|
||||
#define SCM_CONNECT 0x03 /* rw: struct scm_connect */
|
||||
|
||||
struct ucred {
|
||||
unsigned int pid;
|
||||
unsigned int uid;
|
||||
unsigned int gid;
|
||||
};
|
||||
|
||||
/* Supported address families. */
|
||||
#define AF_UNSPEC 0
|
||||
#define AF_UNIX 1 /* Unix domain sockets */
|
||||
#define AF_LOCAL 1 /* POSIX name for AF_UNIX */
|
||||
#define AF_INET 2 /* Internet IP Protocol */
|
||||
#define AF_AX25 3 /* Amateur Radio AX.25 */
|
||||
#define AF_IPX 4 /* Novell IPX */
|
||||
#define AF_APPLETALK 5 /* AppleTalk DDP */
|
||||
#define AF_NETROM 6 /* Amateur Radio NET/ROM */
|
||||
#define AF_BRIDGE 7 /* Multiprotocol bridge */
|
||||
#define AF_ATMPVC 8 /* ATM PVCs */
|
||||
#define AF_X25 9 /* Reserved for X.25 project */
|
||||
#define AF_INET6 10 /* IP version 6 */
|
||||
#define AF_ROSE 11 /* Amateur Radio X.25 PLP */
|
||||
#define AF_DECnet 12 /* Reserved for DECnet project */
|
||||
#define AF_NETBEUI 13 /* Reserved for 802.2LLC project*/
|
||||
#define AF_SECURITY 14 /* Security callback pseudo AF */
|
||||
#define AF_KEY 15 /* PF_KEY key management API */
|
||||
#define AF_NETLINK 16
|
||||
#define AF_ROUTE AF_NETLINK /* Alias to emulate 4.4BSD */
|
||||
#define AF_PACKET 17 /* Packet family */
|
||||
#define AF_ASH 18 /* Ash */
|
||||
#define AF_ECONET 19 /* Acorn Econet */
|
||||
#define AF_ATMSVC 20 /* ATM SVCs */
|
||||
#define AF_SNA 22 /* Linux SNA Project (nutters!) */
|
||||
#define AF_IRDA 23 /* IRDA sockets */
|
||||
#define AF_PPPOX 24 /* PPPoX sockets */
|
||||
#define AF_WANPIPE 25 /* Wanpipe API Sockets */
|
||||
#define AF_MAX 32 /* For now.. */
|
||||
|
||||
/* Protocol families, same as address families. */
|
||||
#define PF_UNSPEC AF_UNSPEC
|
||||
#define PF_UNIX AF_UNIX
|
||||
#define PF_LOCAL AF_LOCAL
|
||||
#define PF_INET AF_INET
|
||||
#define PF_AX25 AF_AX25
|
||||
#define PF_IPX AF_IPX
|
||||
#define PF_APPLETALK AF_APPLETALK
|
||||
#define PF_NETROM AF_NETROM
|
||||
#define PF_BRIDGE AF_BRIDGE
|
||||
#define PF_ATMPVC AF_ATMPVC
|
||||
#define PF_X25 AF_X25
|
||||
#define PF_INET6 AF_INET6
|
||||
#define PF_ROSE AF_ROSE
|
||||
#define PF_DECnet AF_DECnet
|
||||
#define PF_NETBEUI AF_NETBEUI
|
||||
#define PF_SECURITY AF_SECURITY
|
||||
#define PF_KEY AF_KEY
|
||||
#define PF_NETLINK AF_NETLINK
|
||||
#define PF_ROUTE AF_ROUTE
|
||||
#define PF_PACKET AF_PACKET
|
||||
#define PF_ASH AF_ASH
|
||||
#define PF_ECONET AF_ECONET
|
||||
#define PF_ATMSVC AF_ATMSVC
|
||||
#define PF_SNA AF_SNA
|
||||
#define PF_IRDA AF_IRDA
|
||||
#define PF_PPPOX AF_PPPOX
|
||||
#define PF_WANPIPE AF_WANPIPE
|
||||
#define PF_MAX AF_MAX
|
||||
|
||||
/* Maximum queue length specifiable by listen. */
|
||||
#define SOMAXCONN 128
|
||||
|
||||
/* Flags we can use with send/ and recv.
|
||||
Added those for 1003.1g not all are supported yet */
|
||||
#define MSG_OOB 1
|
||||
#define MSG_PEEK 2
|
||||
#define MSG_DONTROUTE 4
|
||||
#define MSG_TRYHARD 4 /* Synonym for MSG_DONTROUTE for DECnet */
|
||||
#define MSG_CTRUNC 8
|
||||
#define MSG_PROBE 0x10 /* Do not send. Only probe path f.e. for MTU */
|
||||
#define MSG_TRUNC 0x20
|
||||
#define MSG_DONTWAIT 0x40 /* Nonblocking io */
|
||||
#define MSG_EOR 0x80 /* End of record */
|
||||
#define MSG_WAITALL 0x100 /* Wait for a full request */
|
||||
#define MSG_FIN 0x200
|
||||
#define MSG_EOF MSG_FIN
|
||||
#define MSG_SYN 0x400
|
||||
#define MSG_CONFIRM 0x800 /* Confirm path validity */
|
||||
#define MSG_RST 0x1000
|
||||
#define MSG_ERRQUEUE 0x2000 /* Fetch message from error queue */
|
||||
#define MSG_NOSIGNAL 0x4000 /* Do not generate SIGPIPE */
|
||||
#define MSG_MORE 0x8000 /* Sender will send more */
|
||||
|
||||
/* Setsockoptions(2) level. Thanks to BSD these must match IPPROTO_xxx */
|
||||
#define SOL_IP 0
|
||||
/* #define SOL_ICMP 1 No-no-no! Due to Linux :-) we cannot use SOL_ICMP=1 */
|
||||
#define SOL_TCP 6
|
||||
#define SOL_UDP 17
|
||||
#define SOL_IPV6 41
|
||||
#define SOL_ICMPV6 58
|
||||
#define SOL_RAW 255
|
||||
#define SOL_IPX 256
|
||||
#define SOL_AX25 257
|
||||
#define SOL_ATALK 258
|
||||
#define SOL_NETROM 259
|
||||
#define SOL_ROSE 260
|
||||
#define SOL_DECNET 261
|
||||
#define SOL_X25 262
|
||||
#define SOL_PACKET 263
|
||||
#define SOL_ATM 264 /* ATM layer (cell level) */
|
||||
#define SOL_AAL 265 /* ATM Adaption Layer (packet level) */
|
||||
#define SOL_IRDA 266
|
||||
|
||||
/* IPX options */
|
||||
#define IPX_TYPE 1
|
||||
|
||||
#define CMSG_ALIGN(len) ( ((len)+sizeof(long)-1) & ~(sizeof(long)-1) )
|
||||
#define __CMSG_NXTHDR(ctl, len, cmsg) __cmsg_nxthdr((ctl),(len),(cmsg))
|
||||
#define CMSG_NXTHDR(mhdr, cmsg) cmsg_nxthdr((mhdr), (cmsg))
|
||||
|
||||
static inline struct cmsghdr* __cmsg_nxthdr(void *__ctl, size_t __size, struct cmsghdr *__cmsg)
|
||||
{
|
||||
struct cmsghdr * __ptr;
|
||||
__ptr = (struct cmsghdr*)(((unsigned char *) __cmsg) + CMSG_ALIGN(__cmsg->cmsg_len));
|
||||
if ((unsigned long)((char*)(__ptr+1) - (char *) __ctl) > __size)
|
||||
return (struct cmsghdr *)0;
|
||||
return __ptr;
|
||||
}
|
||||
|
||||
static inline struct cmsghdr* cmsg_nxthdr (struct msghdr *__msg, struct cmsghdr *__cmsg)
|
||||
{
|
||||
return __cmsg_nxthdr(__msg->msg_control, __msg->msg_controllen, __cmsg);
|
||||
}
|
||||
|
||||
#define CMSG_DATA(cmsg) ((void *)((char *)(cmsg) + CMSG_ALIGN(sizeof(struct cmsghdr))))
|
||||
#define CMSG_SPACE(len) (CMSG_ALIGN(sizeof(struct cmsghdr)) + CMSG_ALIGN(len))
|
||||
#define CMSG_LEN(len) (CMSG_ALIGN(sizeof(struct cmsghdr)) + (len))
|
||||
|
||||
#define __CMSG_FIRSTHDR(ctl,len) ((len) >= sizeof(struct cmsghdr) ? \
|
||||
(struct cmsghdr *)(ctl) : \
|
||||
(struct cmsghdr *)NULL)
|
||||
#define CMSG_FIRSTHDR(msg) __CMSG_FIRSTHDR((msg)->msg_control, (msg)->msg_controllen)
|
||||
|
||||
struct sockaddr_storage {
|
||||
sa_family_t ss_family;
|
||||
uint32_t __ss_align;
|
||||
char __ss_padding[(128 - (2 * sizeof (uint32_t ))) ];
|
||||
};
|
||||
|
||||
#ifndef SOCK_DGRAM
|
||||
/* the Linux kernel headers suck really badly on non-x86 */
|
||||
#define SOCK_STREAM 1 /* stream (connection) socket */
|
||||
#define SOCK_DGRAM 2 /* datagram (conn.less) socket */
|
||||
#define SOCK_RAW 3 /* raw socket */
|
||||
#define SOCK_RDM 4 /* reliably-delivered message */
|
||||
#define SOCK_SEQPACKET 5 /* sequential packet socket */
|
||||
#define SOCK_PACKET 10 /* linux specific way of */
|
||||
#endif
|
||||
|
||||
int socket(int domain, int type, int protocol) ;
|
||||
int accept(int s, struct sockaddr *addr, socklen_t *addrlen) ;
|
||||
int connect(int sockfd, const struct sockaddr *serv_addr, socklen_t addrlen) ;
|
||||
int bind(int sockfd, const struct sockaddr *my_addr, socklen_t addrlen) ;
|
||||
int recv(int s, void *buf, size_t len, int flags) ;
|
||||
int recvfrom(int s, void *buf, size_t len, int flags, struct sockaddr *from, socklen_t *fromlen) ;
|
||||
int recvmsg(int s, struct msghdr *msg, int flags) ;
|
||||
int send(int s, const void *msg, size_t len, int flags) ;
|
||||
int sendto(int s, const void *msg, size_t len, int flags, const struct sockaddr *to, socklen_t tolen) ;
|
||||
int sendmsg(int s, const struct msghdr *msg, int flags) ;
|
||||
|
||||
int getpeername(int s, struct sockaddr *name, socklen_t *namelen) ;
|
||||
int getsockname(int s , struct sockaddr * name , socklen_t * namelen) ;
|
||||
|
||||
int getsockopt(int s, int level, int optname, void *optval, socklen_t *optlen) ;
|
||||
int setsockopt(int s, int level, int optname, const void *optval, socklen_t optlen) ;
|
||||
|
||||
int listen(int s, int backlog) ;
|
||||
|
||||
#define SHUT_RD 0
|
||||
#define SHUT_WR 1
|
||||
#define SHUT_RDWR 2
|
||||
int shutdown(int s, int how) ;
|
||||
|
||||
int socketpair(int d, int type, int protocol, int sv[2]);
|
||||
|
||||
/* currently not supported: */
|
||||
#define NI_NOFQDN 1
|
||||
|
||||
#define NI_NUMERICHOST 2
|
||||
#define NI_NAMEREQD 4
|
||||
#define NI_NUMERICSERV 8
|
||||
#define NI_DGRAM 16
|
||||
|
||||
struct addrinfo {
|
||||
int ai_flags;
|
||||
int ai_family;
|
||||
int ai_socktype;
|
||||
int ai_protocol;
|
||||
size_t ai_addrlen;
|
||||
struct sockaddr *ai_addr;
|
||||
char *ai_canonname;
|
||||
struct addrinfo *ai_next;
|
||||
};
|
||||
|
||||
int getnameinfo(const struct sockaddr *sa, socklen_t salen, char *host,
|
||||
size_t hostlen, char *serv, size_t servlen, int flags) ;
|
||||
int getaddrinfo(const char *node, const char *service, const struct
|
||||
addrinfo *hints, struct addrinfo **res) ;
|
||||
void freeaddrinfo(struct addrinfo *res) ;
|
||||
const char *gai_strerror(int errcode) ;
|
||||
|
||||
#define EAI_FAMILY -1
|
||||
#define EAI_SOCKTYPE -2
|
||||
#define EAI_BADFLAGS -3
|
||||
#define EAI_NONAME -4
|
||||
#define EAI_SERVICE -5
|
||||
#define EAI_ADDRFAMILY -6
|
||||
#define EAI_NODATA -7
|
||||
#define EAI_MEMORY -8
|
||||
#define EAI_FAIL -9
|
||||
#define EAI_AGAIN -10
|
||||
#define EAI_SYSTEM -11
|
||||
|
||||
#define AI_NUMERICHOST 1
|
||||
#define AI_CANONNAME 2
|
||||
#define AI_PASSIVE 4
|
||||
|
||||
/* Linux-specific socket ioctls */
|
||||
#define SIOCINQ FIONREAD
|
||||
#define SIOCOUTQ TIOCOUTQ
|
||||
|
||||
/* Routing table calls. */
|
||||
#define SIOCADDRT 0x890B /* add routing table entry */
|
||||
#define SIOCDELRT 0x890C /* delete routing table entry */
|
||||
#define SIOCRTMSG 0x890D /* call to routing system */
|
||||
|
||||
/* Socket configuration controls. */
|
||||
#define SIOCGIFNAME 0x8910 /* get iface name */
|
||||
#define SIOCSIFLINK 0x8911 /* set iface channel */
|
||||
#define SIOCGIFCONF 0x8912 /* get iface list */
|
||||
#define SIOCGIFFLAGS 0x8913 /* get flags */
|
||||
#define SIOCSIFFLAGS 0x8914 /* set flags */
|
||||
#define SIOCGIFADDR 0x8915 /* get PA address */
|
||||
#define SIOCSIFADDR 0x8916 /* set PA address */
|
||||
#define SIOCGIFDSTADDR 0x8917 /* get remote PA address */
|
||||
#define SIOCSIFDSTADDR 0x8918 /* set remote PA address */
|
||||
#define SIOCGIFBRDADDR 0x8919 /* get broadcast PA address */
|
||||
#define SIOCSIFBRDADDR 0x891a /* set broadcast PA address */
|
||||
#define SIOCGIFNETMASK 0x891b /* get network PA mask */
|
||||
#define SIOCSIFNETMASK 0x891c /* set network PA mask */
|
||||
#define SIOCGIFMETRIC 0x891d /* get metric */
|
||||
#define SIOCSIFMETRIC 0x891e /* set metric */
|
||||
#define SIOCGIFMEM 0x891f /* get memory address (BSD) */
|
||||
#define SIOCSIFMEM 0x8920 /* set memory address (BSD) */
|
||||
#define SIOCGIFMTU 0x8921 /* get MTU size */
|
||||
#define SIOCSIFMTU 0x8922 /* set MTU size */
|
||||
#define SIOCSIFNAME 0x8923 /* set interface name */
|
||||
#define SIOCSIFHWADDR 0x8924 /* set hardware address */
|
||||
#define SIOCGIFENCAP 0x8925 /* get/set encapsulations */
|
||||
#define SIOCSIFENCAP 0x8926
|
||||
#define SIOCGIFHWADDR 0x8927 /* Get hardware address */
|
||||
#define SIOCGIFSLAVE 0x8929 /* Driver slaving support */
|
||||
#define SIOCSIFSLAVE 0x8930
|
||||
#define SIOCADDMULTI 0x8931 /* Multicast address lists */
|
||||
#define SIOCDELMULTI 0x8932
|
||||
#define SIOCGIFINDEX 0x8933 /* name -> if_index mapping */
|
||||
#define SIOGIFINDEX SIOCGIFINDEX /* misprint compatibility :-) */
|
||||
#define SIOCSIFPFLAGS 0x8934 /* set/get extended flags set */
|
||||
#define SIOCGIFPFLAGS 0x8935
|
||||
#define SIOCDIFADDR 0x8936 /* delete PA address */
|
||||
#define SIOCSIFHWBROADCAST 0x8937 /* set hardware broadcast addr */
|
||||
#define SIOCGIFCOUNT 0x8938 /* get number of devices */
|
||||
|
||||
#define SIOCGIFBR 0x8940 /* Bridging support */
|
||||
#define SIOCSIFBR 0x8941 /* Set bridging options */
|
||||
|
||||
#define SIOCGIFTXQLEN 0x8942 /* Get the tx queue length */
|
||||
#define SIOCSIFTXQLEN 0x8943 /* Set the tx queue length */
|
||||
|
||||
#define SIOCGIFDIVERT 0x8944 /* Frame diversion support */
|
||||
#define SIOCSIFDIVERT 0x8945 /* Set frame diversion options */
|
||||
|
||||
#define SIOCETHTOOL 0x8946 /* Ethtool interface */
|
||||
|
||||
/* ARP cache control calls. */
|
||||
/* 0x8950 - 0x8952 * obsolete calls, don't re-use */
|
||||
#define SIOCDARP 0x8953 /* delete ARP table entry */
|
||||
#define SIOCGARP 0x8954 /* get ARP table entry */
|
||||
#define SIOCSARP 0x8955 /* set ARP table entry */
|
||||
|
||||
/* RARP cache control calls. */
|
||||
#define SIOCDRARP 0x8960 /* delete RARP table entry */
|
||||
#define SIOCGRARP 0x8961 /* get RARP table entry */
|
||||
#define SIOCSRARP 0x8962 /* set RARP table entry */
|
||||
|
||||
/* Driver configuration calls */
|
||||
|
||||
#define SIOCGIFMAP 0x8970 /* Get device parameters */
|
||||
#define SIOCSIFMAP 0x8971 /* Set device parameters */
|
||||
|
||||
/* DLCI configuration calls */
|
||||
|
||||
#define SIOCADDDLCI 0x8980 /* Create new DLCI device */
|
||||
#define SIOCDELDLCI 0x8981 /* Delete DLCI device */
|
||||
|
||||
#define SIOCDEVPRIVATE 0x89F0 /* to 89FF */
|
||||
|
||||
#define _LINUX_SOCKET_H
|
||||
|
||||
__END_DECLS
|
||||
|
||||
#endif
|
@@ -1,127 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_stat_h_
|
||||
#define __dj_include_sys_stat_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#define S_ISBLK(m) (((m) & 0xf000) == 0x1000)
|
||||
#define S_ISCHR(m) (((m) & 0xf000) == 0x2000)
|
||||
#define S_ISDIR(m) (((m) & 0xf000) == 0x3000)
|
||||
#define S_ISFIFO(m) (((m) & 0xf000) == 0x4000)
|
||||
#define S_ISREG(m) (((m) & 0xf000) == 0x0000)
|
||||
|
||||
#define S_ISUID 0x80000000
|
||||
#define S_ISGID 0x40000000
|
||||
|
||||
#define S_IRUSR 00400
|
||||
#define S_IRGRP 00040
|
||||
#define S_IROTH 00004
|
||||
#define S_IWUSR 00200
|
||||
#define S_IWGRP 00020
|
||||
#define S_IWOTH 00002
|
||||
#define S_IXUSR 00100
|
||||
#define S_IXGRP 00010
|
||||
#define S_IXOTH 00001
|
||||
#define S_IRWXU 00700
|
||||
#define S_IRWXG 00070
|
||||
#define S_IRWXO 00007
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/djtypes.h>
|
||||
__DJ_time_t
|
||||
#undef __DJ_time_t
|
||||
#define __DJ_time_t
|
||||
|
||||
struct stat {
|
||||
time_t st_atime;
|
||||
time_t st_ctime;
|
||||
dev_t st_dev;
|
||||
gid_t st_gid;
|
||||
ino_t st_ino;
|
||||
mode_t st_mode;
|
||||
time_t st_mtime;
|
||||
nlink_t st_nlink;
|
||||
off_t st_size;
|
||||
off_t st_blksize;
|
||||
uid_t st_uid;
|
||||
dev_t st_rdev; /* unused */
|
||||
};
|
||||
|
||||
int chmod(const char *_path, mode_t _mode);
|
||||
int fstat(int _fildes, struct stat *_buf);
|
||||
int mkdir(const char *_path, mode_t _mode);
|
||||
int mkfifo(const char *_path, mode_t _mode);
|
||||
int stat(const char *_path, struct stat *_buf);
|
||||
mode_t umask(mode_t _cmask);
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
/* POSIX.1 doesn't mention these at all */
|
||||
|
||||
#define S_IFMT 0xf000
|
||||
|
||||
#define S_IFREG 0x0000
|
||||
#define S_IFBLK 0x1000
|
||||
#define S_IFCHR 0x2000
|
||||
#define S_IFDIR 0x3000
|
||||
#define S_IFIFO 0x4000
|
||||
#define S_IFFIFO S_IFIFO
|
||||
|
||||
#define S_IFLABEL 0x5000
|
||||
#define S_ISLABEL(m) (((m) & 0xf000) == 0x5000)
|
||||
|
||||
void _fixpath(const char *, char *);
|
||||
unsigned short _get_magic(const char *, int);
|
||||
int _is_executable(const char *, int, const char *);
|
||||
int mknod(const char *_path, mode_t _mode, dev_t _dev);
|
||||
char * _truename(const char *, char *);
|
||||
|
||||
/* Bit-mapped variable _djstat_flags describes what expensive
|
||||
f?stat() features our application needs. If you don't need a
|
||||
feature, set its bit in the variable. By default, all the
|
||||
bits are cleared (i.e., you get the most expensive code). */
|
||||
#define _STAT_INODE 1 /* should we bother getting inode numbers? */
|
||||
#define _STAT_EXEC_EXT 2 /* get execute bits from file extension? */
|
||||
#define _STAT_EXEC_MAGIC 4 /* get execute bits from magic signature? */
|
||||
#define _STAT_DIRSIZE 8 /* compute directory size? */
|
||||
#define _STAT_ROOT_TIME 0x10 /* try to get root dir time stamp? */
|
||||
#define _STAT_WRITEBIT 0x20 /* fstat() needs write bit? */
|
||||
|
||||
extern unsigned short _djstat_flags;
|
||||
|
||||
/* Bit-mapped variable _djstat_fail_bits describes which individual
|
||||
undocumented features f?stat() failed to use. To get a human-
|
||||
readable description of the bits, call _djstat_describe_lossage(). */
|
||||
#define _STFAIL_SDA 1 /* Get SDA call failed */
|
||||
#define _STFAIL_OSVER 2 /* Unsupported DOS version */
|
||||
#define _STFAIL_BADSDA 4 /* Bad pointer to SDA */
|
||||
#define _STFAIL_TRUENAME 8 /* _truename() failed */
|
||||
#define _STFAIL_HASH 0x10 /* inode defaults to hashing */
|
||||
#define _STFAIL_LABEL 0x20 /* Root dir, but no volume label */
|
||||
#define _STFAIL_DCOUNT 0x40 /* dirent_count ridiculously large */
|
||||
#define _STFAIL_WRITEBIT 0x80 /* fstat() failed to get write access bit */
|
||||
#define _STFAIL_DEVNO 0x100 /* fstat() failed to get device number */
|
||||
#define _STFAIL_BADSFT 0x200 /* SFT entry found, but can't be trusted */
|
||||
#define _STFAIL_SFTIDX 0x400 /* bad SFT index in JFT */
|
||||
#define _STFAIL_SFTNF 0x800 /* file entry not found in SFT array */
|
||||
|
||||
extern unsigned short _djstat_fail_bits;
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_stat_h_ */
|
@@ -1,31 +0,0 @@
|
||||
/* Copyright (C) 1998 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_sysmacros_h_
|
||||
#define __dj_include_sys_sysmacros_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#define major(x) ((int)(((unsigned)(x) >> 8) & 0xff))
|
||||
#define minor(x) ((int)((x) & 0xff))
|
||||
|
||||
#define makedev(x,y) ((dev_t)(((x) << 8) | (y)))
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_sysmacros_h_ */
|
@@ -1,74 +0,0 @@
|
||||
/* Copyright (C) 1998 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_system_h__
|
||||
#define __dj_include_sys_system_h__
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
extern int _shell_command (const char *_prog, const char *_cmdline);
|
||||
extern int _is_unixy_shell (const char *_prog);
|
||||
extern int _is_dos_shell (const char *_prog);
|
||||
|
||||
/* Checking for special executable formats */
|
||||
|
||||
typedef struct {
|
||||
char magic[16];
|
||||
int struct_length;
|
||||
char go32[16];
|
||||
unsigned char buffer[0];
|
||||
} _v1_stubinfo;
|
||||
|
||||
|
||||
typedef struct {
|
||||
union {
|
||||
unsigned version:8; /* The version of DJGPP created that COFF exe */
|
||||
struct {
|
||||
unsigned minor:4; /* The minor version of DJGPP */
|
||||
unsigned major:4; /* The major version of DJGPP */
|
||||
} v;
|
||||
} version;
|
||||
|
||||
unsigned object_format:4; /* What an object format */
|
||||
# define _V2_OBJECT_FORMAT_UNKNOWN 0x00
|
||||
# define _V2_OBJECT_FORMAT_COFF 0x01
|
||||
|
||||
unsigned exec_format:4; /* What an executable format */
|
||||
# define _V2_EXEC_FORMAT_UNKNOWN 0x00
|
||||
# define _V2_EXEC_FORMAT_COFF 0x01
|
||||
# define _V2_EXEC_FORMAT_STUBCOFF 0x02
|
||||
# define _V2_EXEC_FORMAT_EXE 0x03
|
||||
# define _V2_EXEC_FORMAT_UNIXSCRIPT 0x04
|
||||
|
||||
unsigned valid:1; /* Only when nonzero all the information is valid */
|
||||
|
||||
unsigned has_stubinfo:1; /* When nonzero the stubinfo info is valid */
|
||||
|
||||
unsigned unused:14;
|
||||
|
||||
_v1_stubinfo *stubinfo;
|
||||
} _v2_prog_type;
|
||||
|
||||
/* When program == NULL you have to pass a valid file handle
|
||||
in fd, otherwise the file is opened and closed by the function */
|
||||
const _v2_prog_type *_check_v2_prog(const char *program, int fd);
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __dj_include_sys_system_h__ */
|
@@ -1,47 +0,0 @@
|
||||
/* Copyright (C) 1999 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_time_h_
|
||||
#define __dj_include_sys_time_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#include <time.h>
|
||||
|
||||
#define ITIMER_REAL 0
|
||||
#define ITIMER_PROF 1
|
||||
|
||||
struct itimerval {
|
||||
struct timeval it_interval; /* timer interval */
|
||||
struct timeval it_value; /* current value */
|
||||
};
|
||||
|
||||
/* Applications should set this to the number of microseconds between
|
||||
timer ticks if they reprogram the system clock. By default, it is
|
||||
set to -1, which causes setitimer to use the default 54.925 msec
|
||||
clock granularity. */
|
||||
extern long __djgpp_clock_tick_interval;
|
||||
|
||||
int getitimer(int _which, struct itimerval *_value);
|
||||
int setitimer(int _which, struct itimerval *_value, struct itimerval *_ovalue);
|
||||
int utimes(const char *_file, struct timeval _tvp[2]);
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_time_h_ */
|
@@ -1,42 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_timeb_h_
|
||||
#define __dj_include_sys_timeb_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#include <sys/djtypes.h>
|
||||
|
||||
__DJ_time_t
|
||||
#undef __DJ_time_t
|
||||
#define __DJ_time_t
|
||||
|
||||
struct timeb
|
||||
{
|
||||
time_t time; /* Seconds since the epoch */
|
||||
unsigned short millitm;
|
||||
short timezone;
|
||||
short dstflag;
|
||||
};
|
||||
|
||||
extern int ftime(struct timeb *);
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_timeb_h_ */
|
@@ -1,40 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_times_h_
|
||||
#define __dj_include_sys_times_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#include <sys/djtypes.h>
|
||||
__DJ_clock_t
|
||||
#undef __DJ_clock_t
|
||||
#define __DJ_clock_t
|
||||
|
||||
struct tms {
|
||||
clock_t tms_utime;
|
||||
clock_t tms_cstime;
|
||||
clock_t tms_cutime;
|
||||
clock_t tms_stime;
|
||||
};
|
||||
|
||||
clock_t times(struct tms *buffer);
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_times_h_ */
|
@@ -1,63 +0,0 @@
|
||||
/* Copyright (C) 1999 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1997 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_types_h_
|
||||
#define __dj_include_sys_types_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include <sys/djtypes.h>
|
||||
|
||||
typedef int dev_t;
|
||||
typedef int ino_t;
|
||||
typedef int mode_t;
|
||||
typedef int nlink_t;
|
||||
|
||||
__DJ_gid_t
|
||||
#undef __DJ_gid_t
|
||||
#define __DJ_gid_t
|
||||
__DJ_off_t
|
||||
#undef __DJ_off_t
|
||||
#define __DJ_off_t
|
||||
__DJ_pid_t
|
||||
#undef __DJ_pid_t
|
||||
#define __DJ_pid_t
|
||||
__DJ_size_t
|
||||
#undef __DJ_size_t
|
||||
#define __DJ_size_t
|
||||
__DJ_ssize_t
|
||||
#undef __DJ_ssize_t
|
||||
#define __DJ_ssize_t
|
||||
__DJ_uid_t
|
||||
#undef __DJ_uid_t
|
||||
#define __DJ_uid_t
|
||||
|
||||
/* Allow including program to override. */
|
||||
#ifndef FD_SETSIZE
|
||||
#define FD_SETSIZE 256
|
||||
#endif
|
||||
|
||||
typedef struct fd_set {
|
||||
unsigned char fd_bits [((FD_SETSIZE) + 7) / 8];
|
||||
} fd_set;
|
||||
|
||||
#define FD_SET(n, p) ((p)->fd_bits[(n) / 8] |= (1 << ((n) & 7)))
|
||||
#define FD_CLR(n, p) ((p)->fd_bits[(n) / 8] &= ~(1 << ((n) & 7)))
|
||||
#define FD_ISSET(n, p) ((p)->fd_bits[(n) / 8] & (1 << ((n) & 7)))
|
||||
#define FD_ZERO(p) memset ((void *)(p), 0, sizeof (*(p)))
|
||||
|
||||
__DJ_time_t
|
||||
#undef __DJ_time_t
|
||||
#define __DJ_time_t
|
||||
|
||||
#define __socklen_t_defined
|
||||
typedef unsigned int socklen_t;
|
||||
typedef unsigned short sa_family_t;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_types_h_ */
|
@@ -1,103 +0,0 @@
|
||||
/* Copyright (C) 1998, 2000 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU 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 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU 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.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, write to the Free
|
||||
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
|
||||
02111-1307 USA. */
|
||||
|
||||
#ifndef _SYS_USER_H
|
||||
#define _SYS_USER_H 1
|
||||
|
||||
/* The whole purpose of this file is for GDB and GDB only. Don't read
|
||||
too much into it. Don't use it for anything other than GDB unless
|
||||
you know what you are doing. */
|
||||
|
||||
struct user_fpregs_struct
|
||||
{
|
||||
long int cwd;
|
||||
long int swd;
|
||||
long int twd;
|
||||
long int fip;
|
||||
long int fcs;
|
||||
long int foo;
|
||||
long int fos;
|
||||
long int st_space [20];
|
||||
};
|
||||
|
||||
struct user_fpxregs_struct
|
||||
{
|
||||
unsigned short int cwd;
|
||||
unsigned short int swd;
|
||||
unsigned short int twd;
|
||||
unsigned short int fop;
|
||||
long int fip;
|
||||
long int fcs;
|
||||
long int foo;
|
||||
long int fos;
|
||||
long int mxcsr;
|
||||
long int reserved;
|
||||
long int st_space[32]; /* 8*16 bytes for each FP-reg = 128 bytes */
|
||||
long int xmm_space[32]; /* 8*16 bytes for each XMM-reg = 128 bytes */
|
||||
long int padding[56];
|
||||
};
|
||||
|
||||
struct user_regs_struct
|
||||
{
|
||||
long int ebx;
|
||||
long int ecx;
|
||||
long int edx;
|
||||
long int esi;
|
||||
long int edi;
|
||||
long int ebp;
|
||||
long int eax;
|
||||
long int xds;
|
||||
long int xes;
|
||||
long int xfs;
|
||||
long int xgs;
|
||||
long int orig_eax;
|
||||
long int eip;
|
||||
long int xcs;
|
||||
long int eflags;
|
||||
long int esp;
|
||||
long int xss;
|
||||
};
|
||||
|
||||
struct user
|
||||
{
|
||||
struct user_regs_struct regs;
|
||||
int u_fpvalid;
|
||||
struct user_fpregs_struct i387;
|
||||
unsigned long int u_tsize;
|
||||
unsigned long int u_dsize;
|
||||
unsigned long int u_ssize;
|
||||
unsigned long start_code;
|
||||
unsigned long start_stack;
|
||||
long int signal;
|
||||
int reserved;
|
||||
struct user_regs_struct* u_ar0;
|
||||
struct user_fpregs_struct* u_fpstate;
|
||||
unsigned long int magic;
|
||||
char u_comm [32];
|
||||
int u_debugreg [8];
|
||||
};
|
||||
|
||||
#define PAGE_SHIFT 12
|
||||
#define PAGE_SIZE (1UL << PAGE_SHIFT)
|
||||
#define PAGE_MASK (~(PAGE_SIZE-1))
|
||||
#define NBPG PAGE_SIZE
|
||||
#define UPAGES 1
|
||||
#define HOST_TEXT_START_ADDR (u.start_code)
|
||||
#define HOST_STACK_END_ADDR (u.start_stack + u.u_ssize * NBPG)
|
||||
|
||||
#endif /* _SYS_USER_H */
|
@@ -1,36 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_utsname_h_
|
||||
#define __dj_include_sys_utsname_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
struct utsname {
|
||||
char machine[9];
|
||||
char nodename[32];
|
||||
char release[9];
|
||||
char sysname[9];
|
||||
char version[9];
|
||||
};
|
||||
|
||||
int uname(struct utsname *name);
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_utsname_h_ */
|
@@ -1,19 +0,0 @@
|
||||
/* Copyright (C) 1999 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1998 DJ Delorie, see COPYING.DJ for details */
|
||||
|
||||
#undef DJGPP
|
||||
#undef __DJGPP
|
||||
#undef __DJGPP__
|
||||
|
||||
#define DJGPP 2
|
||||
#define __DJGPP 2
|
||||
#define __DJGPP__ 2
|
||||
|
||||
#undef DJGPP_MINOR
|
||||
#undef __DJGPP_MINOR
|
||||
#undef __DJGPP_MINOR__
|
||||
|
||||
#define DJGPP_MINOR 3
|
||||
#define __DJGPP_MINOR 3
|
||||
#define __DJGPP_MINOR__ 3
|
||||
|
@@ -1,50 +0,0 @@
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_vfs_h_
|
||||
#define __dj_include_sys_vfs_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
typedef long fsid_t[2];
|
||||
|
||||
#define MOUNT_UFS 0
|
||||
#define MOUNT_NFS 1 /* Not possible on DOS */
|
||||
#define MOUNT_CDFS 2 /* Not possible on DOS */
|
||||
|
||||
#define FS_MAGIC 0x11954 /* Taken from HP-UX */
|
||||
|
||||
struct statfs
|
||||
{
|
||||
long f_type;
|
||||
long f_bsize;
|
||||
long f_blocks;
|
||||
long f_bfree;
|
||||
long f_bavail;
|
||||
long f_files;
|
||||
long f_ffree;
|
||||
fsid_t f_fsid;
|
||||
long f_magic;
|
||||
};
|
||||
|
||||
extern int statfs(const char *, struct statfs *);
|
||||
extern int fstatfs(int, struct statfs *);
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_vfs_h_ */
|
@@ -1,45 +0,0 @@
|
||||
/* Copyright (C) 1998 DJ Delorie, see COPYING.DJ for details */
|
||||
/* Copyright (C) 1995 DJ Delorie, see COPYING.DJ for details */
|
||||
#ifndef __dj_include_sys_wait_h_
|
||||
#define __dj_include_sys_wait_h_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef __dj_ENFORCE_ANSI_FREESTANDING
|
||||
|
||||
#ifndef __STRICT_ANSI__
|
||||
|
||||
#include <sys/djtypes.h>
|
||||
|
||||
#define WEXITSTATUS(stat_val) ( (stat_val) & 0x000ff)
|
||||
#define WIFEXITED(stat_val) (!((stat_val) & 0x3ff00))
|
||||
#define WIFSIGNALED(stat_val) ( ((stat_val) & 0x3ff00))
|
||||
#define WIFSTOPPED(stat_val) 0
|
||||
#define WNOHANG 1
|
||||
#define WSTOPSIG(stat_val) 0
|
||||
#define WTERMSIG(stat_val) ( ((stat_val) >> 8 ) & 0x3ff)
|
||||
#define WUNTRACED 0
|
||||
|
||||
__DJ_pid_t
|
||||
#undef __DJ_pid_t
|
||||
#define __DJ_pid_t
|
||||
|
||||
pid_t wait(int *stat_loc);
|
||||
pid_t waitpid(pid_t pid, int *stat_loc, int options);
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
|
||||
#endif /* !_POSIX_SOURCE */
|
||||
#endif /* !__STRICT_ANSI__ */
|
||||
#endif /* !__dj_ENFORCE_ANSI_FREESTANDING */
|
||||
|
||||
#ifndef __dj_ENFORCE_FUNCTION_CALLS
|
||||
#endif /* !__dj_ENFORCE_FUNCTION_CALLS */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* !__dj_include_sys_wait_h_ */
|
Reference in New Issue
Block a user