1 /* sysdep.h -- handle host dependencies for binutils
2 Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
3 2001, 2002, 2003, 2005, 2006, 2007 Free Software Foundation, Inc.
5 This file is part of GNU Binutils.
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 3 of the License, or
10 (at your option) any later version.
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.
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., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */
27 #include <sys/types.h>
33 #ifdef USE_BINARY_FOPEN
34 #include "fopen-bin.h"
36 #include "fopen-same.h"
41 #define O_BINARY _O_BINARY
62 extern char *strchr ();
63 extern char *strrchr ();
74 #ifdef HAVE_SYS_FILE_H
80 extern char *stpcpy (char *, const char *);
84 extern char *strstr ();
94 extern char *getenv ();
97 #if !HAVE_DECL_ENVIRON
98 extern char **environ
;
101 #if !HAVE_DECL_FPRINTF
102 extern int fprintf (FILE *, const char *, ...);
105 #if !HAVE_DECL_SNPRINTF
106 extern int snprintf(char *, size_t, const char *, ...);
109 #if !HAVE_DECL_VSNPRINTF
110 extern int vsnprintf(char *, size_t, const char *, va_list);
131 #if defined(__GNUC__) && !defined(C_ALLOCA)
133 # define alloca __builtin_alloca
135 # if defined(HAVE_ALLOCA_H) && !defined(C_ALLOCA)
138 # ifndef alloca /* predefined by HP cc +Olibcalls */
139 # if !defined (__STDC__) && !defined (__hpux)
143 # endif /* __STDC__, __hpux */
145 # endif /* HAVE_ALLOCA_H */
150 /* The Solaris version of locale.h always includes libintl.h. If we have
151 been configured with --disable-nls then ENABLE_NLS will not be defined
152 and the dummy definitions of bindtextdomain (et al) below will conflict
153 with the defintions in libintl.h. So we define these values to prevent
154 the bogus inclusion of libintl.h. */
156 # define _LIBGETTEXT_H
162 # include <libintl.h>
163 # define _(String) gettext (String)
165 # define N_(String) gettext_noop (String)
167 # define N_(String) (String)
170 # define gettext(Msgid) (Msgid)
171 # define dgettext(Domainname, Msgid) (Msgid)
172 # define dcgettext(Domainname, Msgid, Category) (Msgid)
173 # define textdomain(Domainname) while (0) /* nothing */
174 # define bindtextdomain(Domainname, Dirname) while (0) /* nothing */
175 # define _(String) (String)
176 # define N_(String) (String)
179 /* Used by ar.c and objcopy.c. */
182 #endif /* _BIN_SYSDEP_H */