This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: ../../gcc/java/class.c:1882: `JCR_SECTION_NAME' undeclared in emit_register_classes


> The following bootstrap error occurs with mainline under hppa1.1-hp-hpux10.20:
> 
> stage1/xgcc -Bstage1/ -B/usr/local/hppa1.1-hp-hpux10.20/bin/ -c  -DIN_GCC    -g -O2 -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes   -DHAVE_CONFIG_H    -I. -Ijava -I../../gcc -I../../gcc/java -I../../gcc/config -I../../gcc/../include ../../gcc/java/class.c -o java/class.o
> ../../gcc/java/class.c: In function `emit_register_classes':
> ../../gcc/java/class.c:1882: `JCR_SECTION_NAME' undeclared (first use in this function)
> ../../gcc/java/class.c:1882: (Each undeclared identifier is reported only once
> ../../gcc/java/class.c:1882: for each function it appears in.)
> make[2]: *** [java/class.o] Error 1

This patch fixes the problem.  Compile checked on hppa1.1-hp-hpux10.20 and
bootstrap and regression tested on i686-pc-linux-gnu.

OK for main?

Dave
-- 
J. David Anglin                                  dave.anglin@nrc.ca
National Research Council of Canada              (613) 990-0752 (FAX: 952-6605)

2001-08-09  John David Anglin  <dave@hiauly1.hia.nrc.ca>

	* defaults.h (JCR_SECTION_NAME): Don't conditionalize definition.

--- defaults.h.orig	Thu Aug  9 12:49:01 2001
+++ defaults.h	Thu Aug  9 12:54:45 2001
@@ -217,14 +217,12 @@
 #endif
 #endif
 
-/* If we have named section and we support weak symbols, then use the
-   .jcr section for recording java classes which need to be registered
-   at program start-up time.  */
-#if defined (TARGET_ASM_NAMED_SECTION) && SUPPORTS_WEAK
+/* Provide default .jcr section name for recording java classes which need
+   to be registered at program start-up.  This is only used if we support
+   named sections and weak symbols.  */
 #ifndef JCR_SECTION_NAME
 #define JCR_SECTION_NAME ".jcr"
 #endif
-#endif
 
 /* If we have no definition for UNIQUE_SECTION, but do have the 
    ability to generate arbitrary sections, construct something


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]