1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100
|
/* decl.h -- Declarations for non-ANSI hosts
* Created: Sun Nov 19 14:04:27 1995 by faith@cs.unc.edu
* Revised: Tue Mar 11 11:13:32 1997 by faith@cs.unc.edu
* Copyright 1995, 1996 Rickard E. Faith (faith@cs.unc.edu)
*
* This library is free software; you can redistribute it and/or modify it
* under the terms of the GNU Library General Public License as published
* by the Free Software Foundation; either version 2 of the License, or (at
* your option) any later version.
*
* This 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
* Library General Public License for more details.
*
* You should have received a copy of the GNU Library General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*
* $Id: decl.h,v 1.5 1998/01/16 03:51:55 faith Exp $
*
*/
#ifndef _DECL_H_
#define _DECL_H_
/* System dependent declarations: Many brain damaged systems don't provide
declarations for standard library calls. We provide them here for
situations that we know about. */
#if defined(__sparc__) && !defined(__linux__)
/* Both SunOS and Solaris */
extern int getrusage( int who, struct rusage * );
extern void bcopy( const void *, void *, int );
extern long random( void );
extern int srandom( unsigned );
extern char *index( const char *, int c );
#if defined(__svr4__)
/* Just Solaris */
extern int gethostname(char *name, int namelen);
extern int getdtablesize(void);
extern pid_t wait3(int *statusp, int options, struct rusage *rusage);
#include <termios.h>
#else
/* Old braindamage for SunOS only */
extern char *memset( void *, int, int );
extern char *strchr( const char *, int );
extern char *strdup( const char * );
extern char *strrchr( const char *, int );
extern char *strtok( char *, const char * );
extern int _filbuf( FILE * );
extern int _flsbuf( unsigned char, FILE * );
extern int fflush( FILE * );
extern int fprintf( FILE *, const char *, ... );
extern int fputc( char, FILE * );
extern int fputs( const char *, FILE * );
extern int fread( char *, int, int, FILE * );
extern int fscanf( FILE *, const char *, ... );
extern int fseek( FILE *, long, int );
extern int fwrite( char *, int, int, FILE * );
extern int gettimeofday( struct timeval *, struct timezone * );
extern int on_exit( void (*)(), caddr_t );
extern int pclose( FILE * );
extern int printf( const char *, ... );
extern int scanf( const char *, ... );
extern int sscanf( const char *, const char *, ... );
extern int unlink( const char * );
extern int vfprintf( FILE *, const char *, ... );
extern int vsprintf( char *, const char *, ... );
extern long strtol( const char *, char **, int );
extern time_t time( time_t * );
extern void fclose( FILE * );
extern void perror( const char * );
extern void rewind( FILE * );
extern int gethostname( const char *, int );
extern int tolower( int );
extern int accept( int s, struct sockaddr *, int * );
extern int socket( int, int, int );
extern int bind( int, struct sockaddr *, int );
extern int listen( int, int );
extern int wait3( union wait *, int, struct rusage * );
extern int getdtablesize( void );
extern int ioctl( int, int, caddr_t );
extern caddr_t mmap( caddr_t, size_t, int, int, int, off_t );
extern int munmap( caddr_t, int );
#endif
#endif /* __sparc__ */
#if defined(__ultrix__) && defined(__MIPSEL__)
extern long random( void );
extern void srandom( int );
#endif
#ifdef __hpux__
extern int strncmp(const char *s1, const char *s2, size_t n);
extern void bcopy(const void *s1, void *s2, size_t n);
#endif
#endif
|