From: spath@jhunix.hcf.jhu.edu (James Spath)
Newsgroups: gnu.gcc.bug
Subject: (none)
Date: 12 Nov 92 08:50:01 GMT
Distribution: gnu
Organization: GNUs Not Usenet

Dear Sir or Madam:

  I have obtained gcc-2.3.1.tar.Z from the usual places, and have gotten
it to build on a Prime EXL7340.  I am writing to report a minor 
inconvenience in this process.  The Prime (as you probably know) runs
a flavor of the MIPS OS.  I built the GCC compiler using the
configuration option "mips-mips-sysv."  The only problem I had was with 
one file "mips-tdump.c," which caused compiler error messages of the
sort "index not defined."  The listing of config.h below contains a comment
that I used to remove the #define for index for this one source file.

 - - - - - - -

/* Configuration for GNU C-compiler for UMIPS operating system
   Copyright (C) 1989, 1990, 1991 Free Software Foundation, Inc.

This file is part of GNU CC.

GNU CC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.

GNU CC is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with GNU CC; see the file COPYING.  If not, write to
the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.  */

/*
 *  Notes for compiling gcc on umips (v3.0)
 *	- change the -g in the CFLAGS to a -g3 or take it out all together.
 *	- do not define DBX_DEBUGGING_INFO in tm.h, it doesn't exist (unless
 *	you get one from a bsd system)
 */

#define USG

#include "xm-mips.h"

#define bcopy(a,b,c)	memcpy((b),(a),(c))
#define bzero(a,b)	memset((a),0,(b))
#define bcmp(a,b,c)	memcmp((a),(b),(c))

#define rindex strrchr
/* TAKE OUT FOR mips-tdump.c #define index strchr */
#define index strchr

 - - - - - - -

  I have gotten gcc through stage 3, and am now testing it with various
C and C++ programs.  The only side effect of the above-mentioned problem
was that "cpp" got built, but not installed because "dumb make" didn't
remove it.  I moved it by hand and everything seems hunky dory.

  For reference, here is output from gcc -v 1-1.c (hello, world):

Reading specs from /usr/local/lib/gcc-lib/mips-mips-sysv/2.3.1/specs
gcc version 2.3.1
 /usr/local/lib/gcc-lib/mips-mips-sysv/2.3.1/cpp -lang-c -v -undef -D__GNUC__=2 -Dmips -Dunix -Dhost_mips -DMIPSEB -DR3000 -DSYSTYPE_SYSV -D_mips -D_unix -D_host_mips -D_MIPSEB -D_R3000 -D_SYSTYPE_SYSV -D__mips__ -D__unix__ -D__host_mips__ -D__MIPSEB__ -D__R3000__ -D__SYSTYPE_SYSV__ -D___mips__ -D___unix__ -D___host_mips__ -D___MIPSEB__ -D___R3000__ -D___SYSTYPE_SYSV__ -D__mips -D__unix -D__host_mips -D__MIPSEB -D__R3000 -D__SYSTYPE_SYSV -D___mips -D___unix -D___host_mips -D___MIPSEB -D___R3000 -D___SYSTYP


E_SYSV -D__LANGUAGE_C -D_LANGUAGE_C -DLANGUAGE_C gnu_cc/1-1.c /usr/tmp/cca26192.i
GNU CPP version 2.3.1 [AL 1.1, MM 28] RISC-OS System V Mips
 /usr/local/lib/gcc-lib/mips-mips-sysv/2.3.1/cc1 /usr/tmp/cca26192.i -quiet -dumpbase 1-1.c -version -o /usr/tmp/cca26192.s
GNU C version 2.3.1 [AL 1.1, MM 28] RISC-OS System V Mips compiled by GNU C version 2.3.1.
 as -nocpp -EB -v -o /usr/tmp/cca261921.o /usr/tmp/cca26192.s
/usr/lib/cmplrs/cc/as0 -v -G 8 -EB -g0 -O1 /usr/tmp/cca26192.s -o /tmp/ctmaa26195 -t /tmp/ctmsta26195 
as0: main 
0.04u 0.14s 0:00.8 22%
/usr/lib/cmplrs/cc/as1 -v -G 8 -p0 -EB -g0 -O1 /tmp/ctmaa26195 -o /usr/tmp/cca261921.o -t /tmp/ctmsta26195 
as1: main 
0.07u 0.14s 0:01.3 16%
 /usr/local/lib/gcc-lib/mips-mips-sysv/2.3.1/mips-tfile -v -o /usr/tmp/cca261921.o /usr/tmp/cca26192.s
mips-tfile version 2.3.1 [AL 1.1, MM 28] RISC-OS System V Mips
 /usr/local/lib/gcc-lib/mips-mips-sysv/2.3.1/ld -EB -systype /sysv/ /sysv/usr/lib/cmplrs/cc/crt1.o /usr/tmp/cca261921.o /usr/local/lib/gcc-lib/mips-mips-sysv/2.3.1/libgcc.a -lc /sysv/usr/lib/cmplrs/cc/crtn.o /usr/local/lib/gcc-lib/mips-mips-sysv/2.3.1/libgcc.a

a.out
hello, world

  I appreciate all the fine work that has come out of FSF and the Gnu
project!  Thanks!!

/jes  13:45  12-Nov-92
Newsgroups: gnu.gcc.bug