Back to index

glibc  2.9
rpc.h
Go to the documentation of this file.
00001 /* @(#)rpc.h  2.3 88/08/10 4.0 RPCSRC; from 1.9 88/02/08 SMI */
00002 /*
00003  * Sun RPC is a product of Sun Microsystems, Inc. and is provided for
00004  * unrestricted use provided that this legend is included on all tape
00005  * media and as a part of the software program in whole or part.  Users
00006  * may copy or modify Sun RPC without charge, but are not authorized
00007  * to license or distribute it to anyone else except as part of a product or
00008  * program developed by the user.
00009  *
00010  * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
00011  * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
00012  * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
00013  *
00014  * Sun RPC is provided with no support and without any obligation on the
00015  * part of Sun Microsystems, Inc. to assist in its use, correction,
00016  * modification or enhancement.
00017  *
00018  * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
00019  * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
00020  * OR ANY PART THEREOF.
00021  *
00022  * In no event will Sun Microsystems, Inc. be liable for any lost revenue
00023  * or profits or other special, indirect and consequential damages, even if
00024  * Sun has been advised of the possibility of such damages.
00025  *
00026  * Sun Microsystems, Inc.
00027  * 2550 Garcia Avenue
00028  * Mountain View, California  94043
00029  */
00030 
00031 /*
00032  * rpc.h, Just includes the billions of rpc header files necessary to
00033  * do remote procedure calling.
00034  *
00035  * Copyright (C) 1984, Sun Microsystems, Inc.
00036  */
00037 
00038 #ifndef _RPC_RPC_H
00039 #define _RPC_RPC_H 1
00040 
00041 #include <rpc/types.h>             /* some typedefs */
00042 #include <netinet/in.h>
00043 
00044 /* external data representation interfaces */
00045 #include <rpc/xdr.h>        /* generic (de)serializer */
00046 
00047 /* Client side only authentication */
00048 #include <rpc/auth.h>              /* generic authenticator (client side) */
00049 
00050 /* Client side (mostly) remote procedure call */
00051 #include <rpc/clnt.h>              /* generic rpc stuff */
00052 
00053 /* semi-private protocol headers */
00054 #include <rpc/rpc_msg.h>    /* protocol for rpc messages */
00055 #include <rpc/auth_unix.h>  /* protocol for unix style cred */
00056 #include <rpc/auth_des.h>   /* protocol for des style cred */
00057 
00058 /* Server side only remote procedure callee */
00059 #include <rpc/svc.h>        /* service manager and multiplexer */
00060 #include <rpc/svc_auth.h>   /* service side authenticator */
00061 
00062 /*
00063  * COMMENT OUT THE NEXT INCLUDE IF RUNNING ON SUN OS OR ON A VERSION
00064  * OF UNIX BASED ON NFSSRC.  These systems will already have the structures
00065  * defined by <rpc/netdb.h> included in <netdb.h>.
00066  */
00067 /* routines for parsing /etc/rpc */
00068 #include <rpc/netdb.h>             /* structures and routines to parse /etc/rpc */
00069 
00070 __BEGIN_DECLS
00071 
00072 /* Global variables, protected for multi-threaded applications.  */
00073 extern fd_set *__rpc_thread_svc_fdset (void) __attribute__ ((__const__));
00074 #define svc_fdset (*__rpc_thread_svc_fdset ())
00075 
00076 extern struct rpc_createerr *__rpc_thread_createerr (void)
00077      __attribute__ ((__const__));
00078 #define get_rpc_createerr() (*__rpc_thread_createerr ())
00079 /* The people who "engineered" RPC should bee punished for naming the
00080    data structure and the variable the same.  We cannot always define the
00081    macro 'rpc_createerr' because this would prevent people from defining
00082    object of type 'struct rpc_createerr'.  So we leave it up to the user
00083    to select transparent replacement also of this variable.  */
00084 #ifdef _RPC_MT_VARS
00085 # define rpc_createerr (*__rpc_thread_createerr ())
00086 #endif
00087 
00088 extern struct pollfd **__rpc_thread_svc_pollfd (void)
00089      __attribute__ ((__const__));
00090 #define svc_pollfd (*__rpc_thread_svc_pollfd ())
00091 
00092 extern int *__rpc_thread_svc_max_pollfd (void) __attribute__ ((__const__));
00093 #define svc_max_pollfd (*__rpc_thread_svc_max_pollfd ())
00094 
00095 __END_DECLS
00096 
00097 #endif /* rpc/rpc.h */