Change __signed to signed.
[dragonfly.git] / crypto / kerberosIV / include / protos.H
1 /* -*- C -*-
2  * Copyright (c) 1995, 1996, 1997 Kungliga Tekniska Högskolan
3  * (Royal Institute of Technology, Stockholm, Sweden).
4  * All rights reserved.
5  * 
6  * Redistribution and use in source and binary forms, with or without
7  * modification, are permitted provided that the following conditions
8  * are met:
9  * 
10  * 1. Redistributions of source code must retain the above copyright
11  *    notice, this list of conditions and the following disclaimer.
12  * 
13  * 2. Redistributions in binary form must reproduce the above copyright
14  *    notice, this list of conditions and the following disclaimer in the
15  *    documentation and/or other materials provided with the distribution.
16  * 
17  * 3. Neither the name of the Institute nor the names of its contributors
18  *    may be used to endorse or promote products derived from this software
19  *    without specific prior written permission.
20  * 
21  * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
22  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24  * ARE DISCLAIMED.  IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE
25  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
26  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31  * SUCH DAMAGE.
32  */
33
34 /*
35  * Add here functions that don't have a prototype on your system.
36  *
37  * $Id: protos.H,v 1.46 1999/12/02 16:58:36 joda Exp $
38  */
39
40 #ifdef NEED_CRYPT_PROTO
41 char *crypt(const char*, const char*);
42 #endif
43
44 #ifdef NEED_STRTOK_R_PROTO
45 char *strtok_r (char *s1, const char *s2, char **lasts);
46 #endif
47
48 #ifndef HAVE_OPTARG_DECLARATION
49 extern char *optarg;
50 #endif
51 #ifndef HAVE_OPTERR_DECLARATION
52 extern int opterr;
53 #endif
54 #ifndef HAVE_OPTIND_DECLARATION
55 extern int optind;
56 #endif
57 #ifndef HAVE_OPTOPT_DECLARATION
58 extern int optopt;
59 #endif
60
61 #if defined(__GNUC__) && SunOS == 4
62
63 /* To get type fd_set */
64 #include <sys/types.h>
65 #include <sys/time.h>
66
67 /* To get struct sockaddr, struct in_addr and struct hostent */
68 #include <sys/socket.h>
69 #include <netinet/in.h>
70 #include <netdb.h>
71
72 /* To get struct stat */
73 #include <sys/stat.h>
74
75 /* To get struct utimbuf */
76 #include <utime.h>
77
78 #if !defined(HAVE_ATEXIT) && defined(HAVE_ON_EXIT)
79 #define atexit(X) on_exit(X, NULL)
80 #define HAVE_ATEXIT 1
81 #endif
82 #ifdef NEED_UTIME_PROTO
83 int utime(const char *, const struct utimbuf *);
84 #endif
85 int syscall(int, ...);
86 pid_t getpid(void);
87 int ftruncate(int, off_t);
88 int fchmod(int, mode_t);
89 int fchown(int fd, int owner, int group);
90 int fsync(int);
91 int seteuid(uid_t);
92 int setreuid(int, int);
93 int flock(int, int);
94 int gettimeofday(struct timeval *tp, struct timezone *tzp);
95 int lstat(const char *, struct stat *);
96 int ioctl(int, int, void *); 
97 int getpriority(int which, int who);
98 int setpriority(int which, int who, int priority);
99 int getdtablesize(void);
100 int initgroups(const char *name, int basegid);
101 long ulimit(int cmd, long newlimit);
102 int vhangup(void);
103
104 int sigblock(int);
105 int sigsetmask(int);
106 int setitimer(int which, struct itimerval *value, struct itimerval *ovalue);
107
108 int munmap(caddr_t addr, int len);
109
110 int socket(int, int, int);
111 int setsockopt(int, int, int, void *, int);
112 int bind(int, void *, int);
113 int getsockname(int, struct sockaddr *, int *);
114 int accept(int, struct sockaddr *, int *);
115 int connect(int, struct sockaddr *, int);
116 int listen(int, int);
117 int recv(int s, void *buf, int len, int flags);
118 int recvfrom(int, char *, int, int, void *, int *);
119 int sendto(int, const char *, int, int, void *, int);
120 int select(int, fd_set *, fd_set *, fd_set *, struct timeval *);
121 int shutdown(int, int);
122 int getpeername(int, struct sockaddr *, int *);
123 int getsockopt(int, int, int, void *, int *);
124 int send(int s, const void *msg, int len, int flags);
125 struct strbuf;
126 int getmsg(int fd, struct strbuf *ctlptr, struct strbuf *dataptr, int *flags);
127
128 char *inet_ntoa(struct in_addr in);
129 unsigned long inet_addr(const char *cp);
130 int gethostname(char *, int);
131 struct hostent *gethostbyname(const char *);
132 int dn_expand(const u_char *msg,
133               const u_char *eomorig,
134               const u_char *comp_dn,
135               char *exp_dn,
136               int length);
137 int res_search(const char *dname,
138                int class,
139                int type,
140                u_char *answer,
141                int anslen);
142
143 int yp_get_default_domain (char **outdomain);
144 int innetgr(const char *netgroup, const char *machine,
145             const char *user, const char *domain);
146
147 char *getwd(char *pathname);
148
149 void bzero(char *b, int length);
150 int strcasecmp(const char *, const char *);
151 void swab(const char *, char *, int);
152 int atoi(const char *str);
153 char *mktemp(char *);
154 void srandom(int seed);
155 int random(void);
156
157 int rcmd(char **, unsigned short, char *, char *, char *, int *);
158 int rresvport(int *);
159 int openlog(const char *ident, int logopt, int facility);
160 int syslog(int priority, const char *message, ...);
161 int ttyslot(void);
162
163 char *getpass(const char *);
164
165 char *getusershell(void);
166 void setpwent();
167 void endpwent();
168
169 #include <stdio.h>
170 int fclose(FILE *);
171
172 #endif /* SunOS4 */
173
174 #if SunOS == 5
175
176 #include <sys/types.h>
177 #include <sys/resource.h>
178
179 char *getusershell(void);
180 char *strtok_r(char *, const char *, char **);
181 int getpriority (int which, id_t who);
182 int setpriority (int which, id_t who, int prio);
183 int getdtablesize (void);
184 char *getusershell(void);
185 void setusershell(void);
186 void endusershell(void);
187
188 #if defined(__GNUC__)
189
190 int syscall(int, ...);
191 int gethostname(char *, int);
192
193 struct timeval;
194 int gettimeofday(struct timeval *tp, void *);
195
196 #endif
197 #endif
198
199 #if defined(__osf__) /* OSF/1 */
200
201 #if 0
202 /* To get type fd_set */
203 #include <sys/types.h>
204 #include <sys/time.h>
205
206 int select(int, fd_set *, fd_set *, fd_set *, struct timeval *);
207 int fsync(int fildes);
208 int gethostname(char *address, int address_len);
209 int setreuid(int ruid, int euid);
210 int ioctl(int d, unsigned long request, void * arg);
211 #endif
212 int flock(int fildes, int operation);
213 int syscall(int, ...);
214
215 unsigned short htons(unsigned short hostshort);
216 unsigned int   htonl(unsigned int hostint);
217 unsigned short ntohs(unsigned short netshort);
218 unsigned int   ntohl(unsigned int netint);
219
220 char *mktemp(char *template);
221 char *getusershell(void);
222
223 int rcmd(char **, unsigned short, char *, char *, char *, int *);
224 int rresvport (int *port);
225
226 #endif /* OSF/1 */
227
228 #if defined(__sgi)
229 #include <sys/types.h>
230
231 char *ptsname(int fd);
232 struct spwd *getspuid(uid_t);
233 #endif /* IRIX */
234
235 #if defined(__GNUC__) && defined(_AIX) /* AIX */
236
237 struct timeval;
238 struct timezone;
239 int gettimeofday (struct timeval *Tp, void *Tzp);
240
241 #endif /* AIX */
242
243 #if defined(__GNUC__) && defined(__hpux) /* HP-UX */
244
245 int syscall(int, ...);
246
247 int vhangup(void);
248
249 char *ptsname(int fildes);
250
251 void utmpname(const char *file);
252
253 int innetgr(const char *netgroup, const char *machine,
254             const char *user, const char *domain);
255
256 int dn_comp(char *exp_dn, char *comp_dn, int length,
257             char **dnptrs, char **lastdnptr);
258
259 int res_query(char *dname, int class, int type,
260               unsigned char *answer, int anslen);
261
262 int dn_expand(char *msg, char *eomorig, char *comp_dn,
263               char *exp_dn, int length);
264
265 int res_search(char *dname, int class, int type,
266                unsigned char *answer, int anslen);
267
268 #endif /* HP-UX */
269
270 #if defined(WIN32)      /* Visual C++ 4.0 (Windows95/NT) */
271
272 int open(const char *, int, ...);
273 int close(int);
274 int     read(int, void *, unsigned int);
275 int write(int, const void *, unsigned int);
276
277 #endif /* WIN32 */