summaryrefslogtreecommitdiff
path: root/cad/spice/patches/patch-ac
blob: fdb65657d1330b853e3227b93aefb92115ad1e99 (plain)
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
$NetBSD: patch-ac,v 1.6 2006/10/09 20:04:38 mlelstv Exp $

--- src/include/misc.h.orig	1993-04-25 23:37:48.000000000 +0200
+++ src/include/misc.h
@@ -5,6 +5,8 @@ Copyright 1990 Regents of the University
 #ifndef MISC_H
 #define MISC_H
 
+#include <stdlib.h>
+
 #define BSIZE_SP      512
 
 #ifdef HAS_EXIT1
@@ -81,23 +83,12 @@ extern void srandom();
 #    define srandom	srand
 #  endif
 
-extern char *calloc();
-extern char *malloc();
-extern char *realloc();
-extern char *getenv();
-extern int errno;
+#if !(defined(__FreeBSD__) || defined(__NetBSD__) || defined(__DragonFly__) || defined(__OpenBSD__))
 extern char *sys_errlist[];
-extern char *getenv();
+#endif
 extern char *getwd();
-extern int rand();
-extern int srand();
-extern int atoi();
 extern int kill();
 extern int getpid();
-extern int qsort();
-#  ifdef notdef
-extern void exit();
-#  endif
 
 #  ifdef HAS_GETCWD
 extern char *getcwd( );
@@ -109,12 +100,14 @@ extern void clearerr();
 #    endif /* clearerr */
 #  endif /* HAS_CLEARERR */
 
+#if !(defined(__FreeBSD__) || defined(__NetBSD__) || defined(__DragonFly__) || defined(__OpenBSD__))
 #  ifndef bzero
 extern int bzero();
 #  endif
 #  ifndef bcopy
 extern void bcopy();
 #  endif
+#endif /* defined(__FreeBSD__) || defined(__NetBSD__) */
 
 #  ifndef index
 #    ifdef HAS_INDEX
@@ -144,6 +137,7 @@ extern char *strrchr();
 extern void perror();
 #endif
 
+#if !(defined(__FreeBSD__) || defined(__NetBSD__) || defined(__DragonFly__) || defined(__OpenBSD__))
 #ifdef HAS_TIME_
 #  ifdef HAS_BSDTIME
 extern char *timezone();
@@ -151,10 +145,13 @@ extern char *timezone();
 extern char *asctime();
 extern struct tm *localtime();
 #endif
+#endif
 
 #ifndef HAS_MEMAVL
 #  ifdef HAS_RLIMIT_
+#if !(defined(__FreeBSD__) || defined(__NetBSD__) || defined(__DragonFly__) || defined(__OpenBSD__))
 extern char *sbrk();
+#endif
 #  endif
 #endif