* configure.in (mips-sony-bsd*): Fix typo in AC_DEFINE.
[deliverable/binutils-gdb.git] / bfd / sysdep.h
1 /* sysdep.h -- handle host dependencies for the BFD library
2 Copyright 1995 Free Software Foundation, Inc.
3 Written by Cygnus Support.
4
5 This file is part of BFD, the Binary File Descriptor library.
6
7 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2 of the License, or
10 (at your option) any later version.
11
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
20
21 #ifndef BFD_SYSDEP_H
22 #define BFD_SYSDEP_H
23
24 #include "ansidecl.h"
25
26 #include "config.h"
27
28 #ifdef HAVE_STDDEF_H
29 #include <stddef.h>
30 #endif
31
32 #include <stdio.h>
33 #include <sys/types.h>
34 #include <sys/stat.h>
35
36 #include <errno.h>
37 #ifndef errno
38 extern int errno;
39 #endif
40
41 #ifdef HAVE_STRING_H
42 #include <string.h>
43 #else
44 #ifdef HAVE_STRINGS_H
45 #include <strings.h>
46 #else
47 extern char *strchr ();
48 extern char *strrchr ();
49 extern char *strstr ();
50 #endif
51 #endif
52
53 #ifdef HAVE_STDLIB_H
54 #include <stdlib.h>
55 #endif
56
57 #if TIME_WITH_SYS_TIME
58 #include <sys/time.h>
59 #include <time.h>
60 #else
61 #if HAVE_SYS_TIME_H
62 #include <sys/time.h>
63 #else
64 #include <time.h>
65 #endif
66 #endif
67
68 #ifdef HAVE_UNISTD_H
69 #include <unistd.h>
70 #endif
71
72 #ifdef USE_BINARY_FOPEN
73 #include "fopen-bin.h"
74 #else
75 #include "fopen-same.h"
76 #endif
77
78 #ifdef HAVE_FCNTL_H
79 #include <fcntl.h>
80 #else
81 #ifdef HAVE_SYS_FILE_H
82 #include <sys/file.h>
83 #endif
84 #endif
85
86 #ifndef O_RDONLY
87 #define O_RDONLY 0
88 #endif
89 #ifndef O_WRONLY
90 #define O_WRONLY 1
91 #endif
92 #ifndef O_RDWR
93 #define O_RDWR 2
94 #endif
95 #ifndef O_ACCMODE
96 #define O_ACCMODE (O_RDONLY | O_WRONLY | O_RDWR)
97 #endif
98
99 #ifndef SEEK_SET
100 #define SEEK_SET 0
101 #endif
102 #ifndef SEEK_CUR
103 #define SEEK_CUR 1
104 #endif
105
106 #ifdef NEED_DECLARATION_MALLOC
107 extern PTR malloc ();
108 #endif
109
110 #ifdef NEED_DECLARATION_FREE
111 extern void free ();
112 #endif
113
114 #endif /* ! defined (BFD_SYSDEP_H) */
This page took 0.050494 seconds and 5 git commands to generate.