Subject: GCC support for hppa*-*-netbsd*
To: None <port-hp700@netbsd.org>
From: Jason R Thorpe <thorpej@wasabisystems.com>
List: port-hp700
Date: 02/02/2002 16:32:28
--tThc/1wpZn/ma/RB
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

Folks...

I cooked up a hppa ELF config for NetBSD.  This should apply to
the latest anoncvs version of gcc-current from gcc.gnu.org.

Included here are some changes not directly to PA-RISC that:

	(1) Avoid some bogus format warnings (these are temporary
	    work-arounds until I have a chance to fix it properly
	    in GCC).

	(2) Implement the -CC option for the C preprocessor so
	    that lint(1) will work with current gcc 3.1 CVS
	    versions.

I can't test the configuration directly, since I don't have include
files for NetBSD/hp700.  Matt -- if you could check in what you have
so far, that would be really great, as it would make it easier for
other people to do e.g. this sort of work :-)

When I've confirmed that this compiler can build kernels and at least
static userland binaries, I'll submit it for inclusion in the master
GCC sources.

-- 
        -- Jason R. Thorpe <thorpej@wasabisystems.com>

--tThc/1wpZn/ma/RB
Content-Type: text/plain; charset=us-ascii
Content-Description: pa-netbsd-patch
Content-Disposition: attachment; filename=pa-netbsd-patch

Index: c-format.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/c-format.c,v
retrieving revision 1.16
diff -c -r1.16 c-format.c
*** c-format.c	2001/11/25 18:54:11	1.16
--- c-format.c	2002/02/03 00:08:09
***************
*** 1360,1368 ****
--- 1360,1370 ----
    if (res.number_dollar_extra_args > 0 && res.number_non_literal == 0
        && res.number_other == 0 && warn_format_extra_args)
      status_warning (status, "unused arguments in $-style format");
+ #if 0
    if (res.number_empty > 0 && res.number_non_literal == 0
        && res.number_other == 0)
      status_warning (status, "zero-length format string");
+ #endif
  
    if (res.number_wide > 0)
      status_warning (status, "format is a wide character string");
***************
*** 1475,1481 ****
--- 1477,1485 ----
  	 specially if info == NULL and add a res->number_null entry for
  	 that case, or maybe add a function pointer to be called at
  	 the end instead of hardcoding check_format_info_main.  */
+ #if 0
        status_warning (status, "null format string");
+ #endif
  
        /* Skip to first argument to check, so we can see if this format
  	 has any arguments (it shouldn't).  */
Index: config.gcc
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config.gcc,v
retrieving revision 1.157
diff -c -r1.157 config.gcc
*** config.gcc	2002/01/30 22:37:10	1.157
--- config.gcc	2002/02/03 00:08:43
***************
*** 786,791 ****
--- 789,800 ----
  		thread_file='posix'
  	fi
  	;;
+ hppa*-*-netbsd*)
+ 	target_cpu_default="MASK_PA_11"
+ 	tm_file="${tm_file} dbxelf.h elfos.h netbsd.h netbsd-elf.h \
+ 		 pa/pa-netbsd.h pa/pa32-regs.h pa/pa32-netbsd.h"
+ 	tmake_file="${tmake_file} pa/t-netbsd"
+ 	;;
  hppa*-*-openbsd*)
  	target_cpu_default="MASK_PA_11"
  	tmake_file=pa/t-bsd
Index: cppinit.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cppinit.c,v
retrieving revision 1.198
diff -c -r1.198 cppinit.c
*** cppinit.c	2002/01/29 12:09:21	1.198
--- cppinit.c	2002/02/03 00:09:05
***************
*** 487,492 ****
--- 487,493 ----
    set_lang (pfile, lang);
    CPP_OPTION (pfile, warn_import) = 1;
    CPP_OPTION (pfile, discard_comments) = 1;
+   CPP_OPTION (pfile, discard_comments_in_macro_exp) = 1;
    CPP_OPTION (pfile, show_column) = 1;
    CPP_OPTION (pfile, tabstop) = 8;
    CPP_OPTION (pfile, operator_names) = 1;
***************
*** 1163,1168 ****
--- 1164,1170 ----
    DEF_OPT("-version",                 0,      OPT__version)                   \
    DEF_OPT("A",                        no_ass, OPT_A)                          \
    DEF_OPT("C",                        0,      OPT_C)                          \
+   DEF_OPT("CC",                       0,      OPT_CC)                         \
    DEF_OPT("D",                        no_mac, OPT_D)                          \
    DEF_OPT("H",                        0,      OPT_H)                          \
    DEF_OPT("I",                        no_dir, OPT_I)                          \
***************
*** 1435,1440 ****
--- 1437,1446 ----
  
  	case OPT_C:
  	  CPP_OPTION (pfile, discard_comments) = 0;
+ 	  break;
+ 	case OPT_CC:
+ 	  CPP_OPTION (pfile, discard_comments) = 0;
+ 	  CPP_OPTION (pfile, discard_comments_in_macro_exp) = 0;
  	  break;
  	case OPT_P:
  	  CPP_OPTION (pfile, no_line_commands) = 1;
Index: cpplib.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cpplib.c,v
retrieving revision 1.289
diff -c -r1.289 cpplib.c
*** cpplib.c	2002/01/03 21:43:04	1.289
--- cpplib.c	2002/02/03 00:09:25
***************
*** 386,391 ****
--- 386,398 ----
  
    if (dir)
      {
+       /* If we are processing a `#define' directive and we have been
+ 	 requested to expand comments into macros, then re-enable
+ 	 saving of comments.  */
+       if (dir == &dtable[T_DEFINE])
+         pfile->state.save_comments =
+           ! CPP_OPTION (pfile, discard_comments_in_macro_exp);
+ 
        pfile->directive = dir;
        (*pfile->directive->handler) (pfile);
      }
Index: cpplib.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cpplib.h,v
retrieving revision 1.200
diff -c -r1.200 cpplib.h
*** cpplib.h	2002/01/29 12:09:23	1.200
--- cpplib.h	2002/02/03 00:09:33
***************
*** 252,257 ****
--- 252,261 ----
    /* Nonzero means don't copy comments into the output file.  */
    unsigned char discard_comments;
  
+   /* Nonzero means don't copy comments into the output file during
+      macro expansion.  */
+   unsigned char discard_comments_in_macro_exp;
+ 
    /* Nonzero means process the ISO trigraph sequences.  */
    unsigned char trigraphs;
  
Index: cppmacro.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cppmacro.c,v
retrieving revision 1.91
diff -c -r1.91 cppmacro.c
*** cppmacro.c	2002/01/03 21:43:05	1.91
--- cppmacro.c	2002/02/03 00:09:51
***************
*** 1036,1041 ****
--- 1036,1044 ----
  	  return &pfile->avoid_paste;
  	}
  
+       if (pfile->state.in_directive && result->type == CPP_COMMENT)
+ 	continue;
+ 
        if (result->type != CPP_NAME)
  	break;
  
Index: gcc.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/gcc.c,v
retrieving revision 1.288
diff -c -r1.288 gcc.c
*** gcc.c	2002/01/29 12:09:21	1.288
--- gcc.c	2002/02/03 00:11:01
***************
*** 675,681 ****
  
  static const char *cpp_unique_options =
  "%{C:%{!E:%eGNU C does not support -C without using -E}}\
!  %{nostdinc*} %{C} %{v} %{I*} %{P} %{$} %I\
   %{MD:-M -MF %W{!o: %b.d}%W{o*:%.d%*}}\
   %{MMD:-MM -MF %W{!o: %b.d}%W{o*:%.d%*}}\
   %{M} %{MM} %W{MF*} %{MG} %{MP} %{MQ*} %{MT*} %{M|MD|MM|MMD:%{o*:-MQ %*}}\
--- 675,682 ----
  
  static const char *cpp_unique_options =
  "%{C:%{!E:%eGNU C does not support -C without using -E}}\
!  %{CC:%{!E:%eGNU C does not support -CC without using -E}}\
!  %{nostdinc*} %{C} %{CC} %{v} %{I*} %{P} %{$} %I\
   %{MD:-M -MF %W{!o: %b.d}%W{o*:%.d%*}}\
   %{MMD:-MM -MF %W{!o: %b.d}%W{o*:%.d%*}}\
   %{M} %{MM} %W{MF*} %{MG} %{MP} %{MQ*} %{MT*} %{M|MD|MM|MMD:%{o*:-MQ %*}}\
***************
*** 921,926 ****
--- 922,928 ----
     {"--classpath", "-fclasspath=", "aj"},
     {"--CLASSPATH", "-fCLASSPATH=", "aj"},
     {"--comments", "-C", 0},
+    {"--comments-in-macros", "-CC", 0},
     {"--compile", "-c", 0},
     {"--debug", "-g", "oj"},
     {"--define-macro", "-D", "aj"},
Index: config/pa/milli32.S
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/pa/milli32.S,v
retrieving revision 1.1
diff -c -r1.1 milli32.S
*** milli32.S	2001/04/13 05:19:02	1.1
--- milli32.S	2002/02/03 00:16:01
***************
*** 64,70 ****
  	ldw	4(%r22),%r19		; load new LTP value
  	ldw	0(%r22),%r22		; load address of target
  LSYM(1)
! #ifdef LINUX
  	bv	%r0(%r22)		; branch to the real target
  #else
  	ldsid	(%sr0,%r22),%r1		; get the "space ident" selected by r22
--- 64,70 ----
  	ldw	4(%r22),%r19		; load new LTP value
  	ldw	0(%r22),%r22		; load address of target
  LSYM(1)
! #if defined(LINUX) || defined(NETBSD)
  	bv	%r0(%r22)		; branch to the real target
  #else
  	ldsid	(%sr0,%r22),%r1		; get the "space ident" selected by r22
Index: config/pa/pa-netbsd.h
===================================================================
RCS file: pa-netbsd.h
diff -N pa-netbsd.h
*** /dev/null	Tue May  5 13:32:27 1998
--- pa-netbsd.h	Sat Feb  2 16:16:04 2002
***************
*** 0 ****
--- 1,249 ----
+ /* Definitions for PA_RISC with ELF format running NetBSD.
+    Copyright 2002 Free Software Foundation, Inc.
+    Contributed by Wasabi Systems, Inc.
+ 
+    Derived from <pa/pa-linux.h>.
+ 
+ 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, 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA.  */
+ 
+ 
+ /* Provide a LINK_SPEC appropriate for a NetBSD/hppa ELF target.
+    This is a copy of LINK_SPEC from <netbsd-elf.h> tweaked for
+    the hppa target.  */
+ 
+ #undef LINK_SPEC
+ #define LINK_SPEC							\
+   "%{assert*} %{R*}							\
+    %{shared:-shared}							\
+    %{!shared:								\
+      -dc -dp								\
+      %{!nostdlib:							\
+        %{!r*:								\
+ 	 %{!e*:-e _start}}}						\
+      %{!static:								\
+        %{rdynamic:-export-dynamic}					\
+        %{!dynamic-linker:-dynamic-linker /usr/libexec/ld.elf_so}}	\
+      %{static:-static}}"
+ 
+ 
+ /* Names to predefine in the preprocessor for this target machine.  */
+ 
+ #undef CPP_PREDEFINES
+ #define CPP_PREDEFINES							\
+   "-D__NetBSD__ -D__ELF__ -D__hppa__ -Asystem=unix -Asystem=NetBSD"
+ 
+ 
+ /* Define CPP specs appropriate for NetBSD.  We deal with the GCC
+    option `-posix', as well as target CPU specs.  */
+ 
+ #undef SUBTARGET_EXTRA_SPECS
+ #define SUBTARGET_EXTRA_SPECS						\
+   { "cpp_subtarget", CPP_SUBTARGET_SPEC },
+ 
+ #define CPP_SUBTARGET_SPEC						\
+   "%{posix:-D_POSIX_SOURCE}"
+ 
+ #undef CPP_PA10_SPEC
+ #define CPP_PA10_SPEC "-D_PA_RISC1_0"
+ 
+ #undef CPP_PA11_SPEC
+ #define CPP_PA11_SPEC "-D_PA_RISC1_1"
+ 
+ #undef CPP_PA20_SPEC
+ #define CPP_PA20_SPEC "-D_PA_RISC2_0"
+ 
+ #undef CPP_SPEC
+ #define CPP_SPEC							\
+   "%{mpa-risc-1-0:%(cpp_pa10)}						\
+    %{mpa-risc-1-1:%(cpp_pa11)}						\
+    %{msnake:%(cpp_pa11)}						\
+    %{mpa-risc-2-0:%(cpp_pa20)}						\
+    %{!mpa-risc-1-0:							\
+      %{!mpa-risc-1-1:							\
+        %{!mpa-risc-2-0:							\
+ 	 %{!msnake:%(cpp_cpu_default)}}}}				\
+    %{m64bit:%(cpp_64bit)}						\
+    %{!m64bit:%(cpp_64bit_default)}					\
+    %(cpp_subtarget)"
+ 
+ /* Make this default to CPP_SPEC.  */
+ #undef CPLUSPLUS_CPP_SPEC
+ 
+ 
+ /* Use DWARF2 debugging and unwind info.  */
+ #undef PREFERRED_DEBUGGING_TYPE
+ #define PREFERRED_DEBUGGING_TYPE DWARF2_DEBUG
+ #define DWARF2_ASM_LINE_DEBUG_INFO 1
+ #define DWARF2_UNWIND_INFO 1
+ 
+ 
+ /* Sibcalls, stubs, and ELF sections don't play well.  */
+ #undef FUNCTION_OK_FOR_SIBCALL
+ #define FUNCTION_OK_FOR_SIBCALL(x) 0
+ 
+ 
+ /* Put plabels into the data section so we can relocate them.  */
+ #undef SELECT_RTX_SECTION
+ #define SELECT_RTX_SECTION(MODE,RTX,ALIGN)				\
+   if (flag_pic && function_label_operand (RTX, MODE))			\
+     data_section ();							\
+   else									\
+     readonly_data_section ();
+ 
+ 
+ /* A C expression whose value is RTL representing the location of the
+    incoming return address at the beginning of any function, before the
+    prologue.  */
+ #define INCOMING_RETURN_ADDR_RTX  (gen_rtx_REG (word_mode, 2))
+ #define DWARF_FRAME_RETURN_COLUMN (DWARF_FRAME_REGNUM (2))
+ 
+ 
+ /* Define the strings used for the special svr4 .type and .size directives.
+    These strings generally do not vary from one system running svr4 to
+    another, but if a given system (e.g. m88k running svr) needs to use
+    different pseudo-op names for these, they may be overridden in the
+    file which includes this one.  */
+ 
+ #undef STRING_ASM_OP
+ #define STRING_ASM_OP	".stringz"
+ 
+ #define TEXT_SECTION_ASM_OP "\t.text"
+ #define DATA_SECTION_ASM_OP "\t.data"
+ #define BSS_SECTION_ASM_OP "\t.section\t.bss"
+ 
+ 
+ /* Output at beginning of assembler file.  */
+ #undef ASM_FILE_START
+ #define ASM_FILE_START(FILE)						\
+   do									\
+     {									\
+       if (write_symbols != NO_DEBUG)					\
+ 	{								\
+ 	  output_file_directive (FILE, main_input_filename);		\
+ 	  fputs ("\t.version\t\"01.01\"\n", FILE);			\
+ 	}								\
+       if (TARGET_64BIT)							\
+ 	fputs("\t.LEVEL 2.0w\n", FILE);					\
+       else if (TARGET_PA_20)						\
+ 	fputs("\t.LEVEL 2.0\n", FILE);					\
+       else if (TARGET_PA_11)						\
+ 	fputs("\t.LEVEL 1.1\n", FILE);					\
+       else								\
+ 	fputs("\t.LEVEL 1.0\n", FILE);					\
+       if (profile_flag)							\
+ 	fputs ("\t.IMPORT _mcount, CODE\n", FILE);			\
+     }									\
+   while (0)
+ 
+ 
+ /* Output a definition */
+ #define ASM_OUTPUT_DEF(FILE,LABEL1,LABEL2)				\
+   do									\
+     {									\
+       fprintf ((FILE), "\t%s\t", SET_ASM_OP);				\
+       assemble_name (FILE, LABEL1);					\
+       fprintf (FILE, ",");						\
+       assemble_name (FILE, LABEL2);					\
+       fprintf (FILE, "\n");						\
+     }									\
+   while (0)
+ 
+ 
+ /* Define these to generate the ELF/SysV style of internal
+    labels all the time - i.e. to be compatible with
+    ASM_GENERATE_INTERNAL_LABEL in <elfos.h>.  Compare these with the
+    ones in pa.h and note the lack of dollar signs in these.  FIXME:
+    shouldn't we fix pa.h to use ASM_GENERATE_INTERNAL_LABEL instead? */
+ 
+ #undef ASM_OUTPUT_ADDR_VEC_ELT
+ #define ASM_OUTPUT_ADDR_VEC_ELT(FILE, VALUE)				\
+   if (TARGET_BIG_SWITCH)						\
+     fprintf (FILE, "\tstw %%r1,-16(%%r30)\n\tldil LR'.L%d,%%r1\n\tbe RR'.L%d(%%sr4,%%r1)\n\tldw -16(%%r30),%%r1\n", VALUE, VALUE);			\
+   else									\
+     fprintf (FILE, "\tb .L%d\n\tnop\n", VALUE)
+ 
+ 
+ #undef ASM_OUTPUT_ADDR_DIFF_ELT
+ #define ASM_OUTPUT_ADDR_DIFF_ELT(FILE, BODY, VALUE, REL)		\
+   if (TARGET_BIG_SWITCH)						\
+     fprintf (FILE, "\tstw %%r1,-16(%%r30)\n\tldw T'.L%d(%%r19),%%r1\n\tbv %%r0(%%r1)\n\tldw -16(%%r30),%%r1\n", VALUE);					\
+   else									\
+     fprintf (FILE, "\tb .L%d\n\tnop\n", VALUE)
+ 
+ 
+ /* This is how to output the definition of a user-level label named NAME,
+    such as the label on a static function or variable NAME.  */
+ 
+ #undef ASM_OUTPUT_LABEL
+ #define ASM_OUTPUT_LABEL(FILE, NAME)					\
+   do									\
+     {									\
+       assemble_name (FILE, NAME);					\
+       fputs (":\n", FILE);						\
+     }									\
+   while (0)
+ 
+ 
+ /* NOTE: ASM_OUTPUT_INTERNAL_LABEL() is defined for us by elfos.h, and
+    does what we want (i.e. uses colons).  It must be compatible with
+    ASM_GENERATE_INTERNAL_LABEL(), so do not define it here.  */
+ 
+ #undef ASM_GLOBALIZE_LABEL
+ #define ASM_GLOBALIZE_LABEL(FILE, NAME)					\
+   (fputs (".globl ", FILE), assemble_name (FILE, NAME), fputs ("\n", FILE))
+ 
+ 
+ /* FIXME: Hacked from the <elfos.h> one so that we avoid multiple
+    labels in a function declaration (since pa.c seems determined to do
+    it differently)  */
+ 
+ #undef ASM_DECLARE_FUNCTION_NAME
+ #define ASM_DECLARE_FUNCTION_NAME(FILE, NAME, DECL)			\
+   do									\
+     {									\
+       fprintf (FILE, "\t%s\t ", TYPE_ASM_OP);				\
+       assemble_name (FILE, NAME);					\
+       putc (',', FILE);							\
+       fprintf (FILE, TYPE_OPERAND_FMT, "function");			\
+       putc ('\n', FILE);						\
+       ASM_DECLARE_RESULT (FILE, DECL_RESULT (DECL));			\
+     }									\
+   while (0)
+ 
+ 
+ /* NetBSD always uses gas.  */
+ #undef TARGET_GAS
+ #define TARGET_GAS 1
+ 
+ 
+ /* Make gcc agree with <machine/ansi.h>.  */
+ 
+ #undef SIZE_TYPE
+ #define SIZE_TYPE "unsigned int"
+ 
+ #undef PTRDIFF_TYPE
+ #define PTRDIFF_TYPE "int"
+ 
+ #undef WCHAR_TYPE
+ #define WCHAR_TYPE "int"
+ 
+ #undef WCHAR_UNSIGNED
+ #define WCHAR_UNSIGNED 0
+ 
+ #undef WCHAR_TYPE_SIZE
+ #define WCHAR_TYPE_SIZE 32
Index: config/pa/pa32-netbsd.h
===================================================================
RCS file: pa32-netbsd.h
diff -N pa32-netbsd.h
*** /dev/null	Tue May  5 13:32:27 1998
--- pa32-netbsd.h	Sat Feb  2 16:16:04 2002
***************
*** 0 ****
--- 1,23 ----
+ /* Definitions for 32-bit PA_RISC with ELF running NetBSD.
+    Copyright (C) 2002 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, 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA.  */
+ 
+ /* Turn off various SOM crap we don't want.  */
+ #undef TARGET_ELF32
+ #define TARGET_ELF32 1
Index: config/pa/t-netbsd
===================================================================
RCS file: t-netbsd
diff -N t-netbsd
*** /dev/null	Tue May  5 13:32:27 1998
--- t-netbsd	Sat Feb  2 16:16:04 2002
***************
*** 0 ****
--- 1,15 ----
+ #Plug millicode routines into libgcc.a  We want these on both native and
+ #cross compiles.
+ 
+ LIB1ASMFUNCS =  _divI _divU _remI _remU _multiply \
+ 	_divI_15 _divI_14 _divI_12 _divI_10 _divI_9 \
+ 	_divI_7 _divI_6 _divI_5 _divI_3 \
+ 	_divU_15 _divU_14 _divU_12 _divU_10 _divU_9 \
+ 	_divU_7 _divU_6 _divU_5 _divU_3 _dyncall
+ 
+ LIB1ASMSRC = pa/milli32.S
+ 
+ # Compile libgcc2.a as PIC.
+ TARGET_LIBGCC2_CFLAGS = -fPIC -DELF=1 -DNETBSD=1
+ 
+ T_ADAFLAGS=-mdisable-indexing
Index: doc/cpp.texi
===================================================================
RCS file: /cvs/gcc/gcc/gcc/doc/cpp.texi,v
retrieving revision 1.22
diff -c -r1.22 cpp.texi
*** cpp.texi	2002/01/10 11:53:19	1.22
--- cpp.texi	2002/02/03 00:17:50
***************
*** 4244,4249 ****
--- 4244,4256 ----
  directive line have the effect of turning that line into an ordinary
  source line, since the first token on the line is no longer a @samp{#}.
  
+ @item -CC
+ Do not discard comments, including during macro expansion.  This is
+ like @option{-C}, except that comments contained within macros are
+ also passed through to the output file where the macro is expanded.
+ 
+ The @option{-CC} option is generally used to support lint comments.
+ 
  @item -gcc
  Define the macros @sc{__gnuc__}, @sc{__gnuc_minor__} and
  @sc{__gnuc_patchlevel__}.  These are defined automatically when you use
Index: doc/invoke.texi
===================================================================
RCS file: /cvs/gcc/gcc/gcc/doc/invoke.texi,v
retrieving revision 1.111
diff -c -r1.111 invoke.texi
*** invoke.texi	2002/01/27 17:44:54	1.111
--- invoke.texi	2002/02/03 00:20:15
***************
*** 3981,3986 ****
--- 3981,3991 ----
  Tell the preprocessor not to discard comments.  Used with the
  @option{-E} option.
  
+ @item -CC
+ @opindex CC
+ Like @option{-C}, but instructs the preprocessor to also include
+ comments in macro expansions.  Used with the @option{-E} option.
+ 
  @item -P
  @opindex P
  Tell the preprocessor not to generate @samp{#line} directives.
Index: f/lang-specs.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/f/lang-specs.h,v
retrieving revision 1.30
diff -c -r1.30 lang-specs.h
*** lang-specs.h	2001/11/24 21:36:56	1.30
--- lang-specs.h	2002/02/03 00:20:17
***************
*** 33,39 ****
    {".r", "@ratfor", 0},
    {"@ratfor",
     "%{C:%{!E:%eGNU C does not support -C without using -E}}\
!     ratfor %{C} %{v} %i %{E:%W{o*}} %{!E: %{!pipe:-o %g.f} |\n\
      f771 %{!pipe:%g.f} %(cc1_options) %{I*} %{!fsyntax-only:%(invoke_as)}}", 0},
    {".f",   "@f77", 0},
    {".for", "@f77", 0},
--- 33,40 ----
    {".r", "@ratfor", 0},
    {"@ratfor",
     "%{C:%{!E:%eGNU C does not support -C without using -E}}\
!     %{CC:%{!E:%eGNU C does not support -CC without using -E}}
!     ratfor %{C} %{CC} %{v} %i %{E:%W{o*}} %{!E: %{!pipe:-o %g.f} |\n\
      f771 %{!pipe:%g.f} %(cc1_options) %{I*} %{!fsyntax-only:%(invoke_as)}}", 0},
    {".f",   "@f77", 0},
    {".for", "@f77", 0},

--tThc/1wpZn/ma/RB--