mirror of git://gcc.gnu.org/git/gcc.git
choose-temp.c: Don't check IN_GCC anymore.
* choose-temp.c: Don't check IN_GCC anymore. * floatformat.c (floatformat_from_double): Use `const', not `CONST'. * memchr.c (memchr): Likewise. * memcpy.c (memcpy): Likewise. * memmove.c (memmove): Likewise. * mkstemp.c: Don't check IN_GCC anymore. * pexecute.c: Likewise. * splay-tree.c: Likewise. * strchr.c (strchr): Use `const', not `CONST'. * strrchr.c (strrchr): Likewise. * strtol.c (strtol): Likewise. * strtoul.c (strtoul): Likewise. From-SVN: r24307
This commit is contained in:
parent
625c729b51
commit
11a0bb74cd
|
@ -1,3 +1,21 @@
|
||||||
|
Mon Dec 14 09:55:50 1998 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
|
||||||
|
|
||||||
|
* choose-temp.c: Don't check IN_GCC anymore.
|
||||||
|
|
||||||
|
* floatformat.c (floatformat_from_double): Use `const', not `CONST'.
|
||||||
|
* memchr.c (memchr): Likewise.
|
||||||
|
* memcpy.c (memcpy): Likewise.
|
||||||
|
* memmove.c (memmove): Likewise.
|
||||||
|
|
||||||
|
* mkstemp.c: Don't check IN_GCC anymore.
|
||||||
|
* pexecute.c: Likewise.
|
||||||
|
* splay-tree.c: Likewise.
|
||||||
|
|
||||||
|
* strchr.c (strchr): Use `const', not `CONST'.
|
||||||
|
* strrchr.c (strrchr): Likewise.
|
||||||
|
* strtol.c (strtol): Likewise.
|
||||||
|
* strtoul.c (strtoul): Likewise.
|
||||||
|
|
||||||
Fri Dec 4 13:51:04 1998 David Taylor <taylor@texas.cygnus.com>
|
Fri Dec 4 13:51:04 1998 David Taylor <taylor@texas.cygnus.com>
|
||||||
Elena Zannoni <ezannoni@cygnus.com>
|
Elena Zannoni <ezannoni@cygnus.com>
|
||||||
Stan Shebs <shebs@cygnus.com>
|
Stan Shebs <shebs@cygnus.com>
|
||||||
|
|
|
@ -22,22 +22,16 @@ Boston, MA 02111-1307, USA. */
|
||||||
/* This file lives in at least two places: libiberty and gcc.
|
/* This file lives in at least two places: libiberty and gcc.
|
||||||
Don't change one without the other. */
|
Don't change one without the other. */
|
||||||
|
|
||||||
#if defined (IN_GCC) || defined (HAVE_CONFIG_H)
|
#ifdef HAVE_CONFIG_H
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef IN_GCC
|
#include <stdio.h> /* May get P_tmpdir. */
|
||||||
#include "system.h"
|
|
||||||
#else
|
|
||||||
|
|
||||||
/* If we are in gcc, system.h has handled everything. When not in
|
|
||||||
gcc, if we have a config.h we assume that HAVE_SYS_FILE_H tells us
|
|
||||||
whether to include sys/file.h. However, libiberty does not have a
|
|
||||||
config.h, and instead arranges to define NO_SYS_FILE_H on the
|
|
||||||
command line when there is no sys/file.h. */
|
|
||||||
|
|
||||||
#if defined (HAVE_CONFIG_H) ? defined (HAVE_SYS_FILE_H) : ! defined (NO_SYS_FILE_H)
|
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
#ifdef HAVE_UNISTD_H
|
||||||
|
#include <unistd.h>
|
||||||
|
#endif
|
||||||
|
#ifdef HAVE_SYS_FILE_H
|
||||||
#include <sys/file.h> /* May get R_OK, etc. on some systems. */
|
#include <sys/file.h> /* May get R_OK, etc. on some systems. */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -47,13 +41,10 @@ Boston, MA 02111-1307, USA. */
|
||||||
#define X_OK 1
|
#define X_OK 1
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include <stdio.h> /* May get P_tmpdir. */
|
|
||||||
#endif /* IN_GCC */
|
|
||||||
|
|
||||||
#include "libiberty.h"
|
#include "libiberty.h"
|
||||||
#ifdef IN_GCC
|
|
||||||
extern int mkstemps ();
|
extern int mkstemps ();
|
||||||
#else
|
|
||||||
|
#ifndef IN_GCC
|
||||||
#if defined (__MSDOS__) || defined (_WIN32)
|
#if defined (__MSDOS__) || defined (_WIN32)
|
||||||
#define DIR_SEPARATOR '\\'
|
#define DIR_SEPARATOR '\\'
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -279,7 +279,7 @@ put_field (data, order, total_len, start, len, stuff_to_put)
|
||||||
|
|
||||||
void
|
void
|
||||||
floatformat_from_double (fmt, from, to)
|
floatformat_from_double (fmt, from, to)
|
||||||
CONST struct floatformat *fmt;
|
const struct floatformat *fmt;
|
||||||
double *from;
|
double *from;
|
||||||
char *to;
|
char *to;
|
||||||
{
|
{
|
||||||
|
|
|
@ -44,11 +44,11 @@ QUICKREF
|
||||||
|
|
||||||
PTR
|
PTR
|
||||||
memchr (src_void, c, length)
|
memchr (src_void, c, length)
|
||||||
register CONST PTR src_void;
|
register const PTR src_void;
|
||||||
int c;
|
int c;
|
||||||
size_t length;
|
size_t length;
|
||||||
{
|
{
|
||||||
CONST unsigned char *src = (CONST unsigned char *)src_void;
|
const unsigned char *src = (const unsigned char *)src_void;
|
||||||
|
|
||||||
while (--length >= 0)
|
while (--length >= 0)
|
||||||
{
|
{
|
||||||
|
|
|
@ -21,7 +21,7 @@ DESCRIPTION
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
PTR
|
PTR
|
||||||
DEFUN(memcpy, (out, in, length), PTR out AND CONST PTR in AND size_t length)
|
DEFUN(memcpy, (out, in, length), PTR out AND const PTR in AND size_t length)
|
||||||
{
|
{
|
||||||
bcopy(in, out, length);
|
bcopy(in, out, length);
|
||||||
return out;
|
return out;
|
||||||
|
|
|
@ -10,7 +10,7 @@
|
||||||
PTR
|
PTR
|
||||||
memmove (s1, s2, n)
|
memmove (s1, s2, n)
|
||||||
PTR s1;
|
PTR s1;
|
||||||
CONST PTR s2;
|
const PTR s2;
|
||||||
size_t n;
|
size_t n;
|
||||||
{
|
{
|
||||||
bcopy (s2, s1, n);
|
bcopy (s2, s1, n);
|
||||||
|
|
|
@ -20,7 +20,6 @@
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef IN_GCC
|
|
||||||
#ifdef HAVE_STDLIB_H
|
#ifdef HAVE_STDLIB_H
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#endif
|
#endif
|
||||||
|
@ -37,9 +36,6 @@
|
||||||
#include <sys/time.h>
|
#include <sys/time.h>
|
||||||
#endif
|
#endif
|
||||||
#include "ansidecl.h"
|
#include "ansidecl.h"
|
||||||
#else
|
|
||||||
#include "system.h"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* We need to provide a type for gcc_uint64_t. */
|
/* We need to provide a type for gcc_uint64_t. */
|
||||||
#ifdef __GNUC__
|
#ifdef __GNUC__
|
||||||
|
|
|
@ -26,9 +26,7 @@ Boston, MA 02111-1307, USA. */
|
||||||
#ifdef HAVE_CONFIG_H
|
#ifdef HAVE_CONFIG_H
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
#endif
|
#endif
|
||||||
#ifdef IN_GCC
|
|
||||||
#include "system.h"
|
|
||||||
#else
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#ifdef HAVE_UNISTD_H
|
#ifdef HAVE_UNISTD_H
|
||||||
|
@ -38,7 +36,6 @@ Boston, MA 02111-1307, USA. */
|
||||||
#ifdef HAVE_SYS_WAIT_H
|
#ifdef HAVE_SYS_WAIT_H
|
||||||
#include <sys/wait.h>
|
#include <sys/wait.h>
|
||||||
#endif
|
#endif
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef vfork /* Autoconf may define this to fork for us. */
|
#ifdef vfork /* Autoconf may define this to fork for us. */
|
||||||
# define VFORK_STRING "fork"
|
# define VFORK_STRING "fork"
|
||||||
|
@ -609,9 +606,6 @@ pfinish ()
|
||||||
|
|
||||||
extern int execv ();
|
extern int execv ();
|
||||||
extern int execvp ();
|
extern int execvp ();
|
||||||
#ifdef IN_GCC
|
|
||||||
extern char * my_strerror PROTO ((int));
|
|
||||||
#endif
|
|
||||||
|
|
||||||
int
|
int
|
||||||
pexecute (program, argv, this_pname, temp_base, errmsg_fmt, errmsg_arg, flags)
|
pexecute (program, argv, this_pname, temp_base, errmsg_fmt, errmsg_arg, flags)
|
||||||
|
@ -703,11 +697,7 @@ pexecute (program, argv, this_pname, temp_base, errmsg_fmt, errmsg_arg, flags)
|
||||||
/* Note: Calling fprintf and exit here doesn't seem right for vfork. */
|
/* Note: Calling fprintf and exit here doesn't seem right for vfork. */
|
||||||
fprintf (stderr, "%s: ", this_pname);
|
fprintf (stderr, "%s: ", this_pname);
|
||||||
fprintf (stderr, install_error_msg, program);
|
fprintf (stderr, install_error_msg, program);
|
||||||
#ifdef IN_GCC
|
|
||||||
fprintf (stderr, ": %s\n", my_strerror (errno));
|
|
||||||
#else
|
|
||||||
fprintf (stderr, ": %s\n", xstrerror (errno));
|
fprintf (stderr, ": %s\n", xstrerror (errno));
|
||||||
#endif
|
|
||||||
exit (-1);
|
exit (-1);
|
||||||
/* NOTREACHED */
|
/* NOTREACHED */
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
Lewis, Harry R. and Denenberg, Larry. Data Structures and Their
|
Lewis, Harry R. and Denenberg, Larry. Data Structures and Their
|
||||||
Algorithms. Harper-Collins, Inc. 1991. */
|
Algorithms. Harper-Collins, Inc. 1991. */
|
||||||
|
|
||||||
#if defined (IN_GCC) || defined (HAVE_CONFIG_H)
|
#ifdef HAVE_CONFIG_H
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -21,7 +21,7 @@ BUGS
|
||||||
|
|
||||||
char *
|
char *
|
||||||
strchr (s, c)
|
strchr (s, c)
|
||||||
register CONST char *s;
|
register const char *s;
|
||||||
int c;
|
int c;
|
||||||
{
|
{
|
||||||
do {
|
do {
|
||||||
|
|
|
@ -21,7 +21,7 @@ BUGS
|
||||||
|
|
||||||
char *
|
char *
|
||||||
strrchr (s, c)
|
strrchr (s, c)
|
||||||
register CONST char *s;
|
register const char *s;
|
||||||
int c;
|
int c;
|
||||||
{
|
{
|
||||||
char *rtnval = 0;
|
char *rtnval = 0;
|
||||||
|
|
|
@ -63,11 +63,11 @@
|
||||||
*/
|
*/
|
||||||
long
|
long
|
||||||
strtol(nptr, endptr, base)
|
strtol(nptr, endptr, base)
|
||||||
CONST char *nptr;
|
const char *nptr;
|
||||||
char **endptr;
|
char **endptr;
|
||||||
register int base;
|
register int base;
|
||||||
{
|
{
|
||||||
register CONST char *s = nptr;
|
register const char *s = nptr;
|
||||||
register unsigned long acc;
|
register unsigned long acc;
|
||||||
register int c;
|
register int c;
|
||||||
register unsigned long cutoff;
|
register unsigned long cutoff;
|
||||||
|
|
|
@ -51,11 +51,11 @@
|
||||||
*/
|
*/
|
||||||
unsigned long
|
unsigned long
|
||||||
strtoul(nptr, endptr, base)
|
strtoul(nptr, endptr, base)
|
||||||
CONST char *nptr;
|
const char *nptr;
|
||||||
char **endptr;
|
char **endptr;
|
||||||
register int base;
|
register int base;
|
||||||
{
|
{
|
||||||
register CONST char *s = nptr;
|
register const char *s = nptr;
|
||||||
register unsigned long acc;
|
register unsigned long acc;
|
||||||
register int c;
|
register int c;
|
||||||
register unsigned long cutoff;
|
register unsigned long cutoff;
|
||||||
|
|
Loading…
Reference in New Issue