> -----Original Message----- > From: H.J. Lu [mailto:hjl.to...@gmail.com] > Sent: Tuesday, December 18, 2012 12:10 > To: Joseph Prostko > Cc: Joey Ye; gcc-patches@gcc.gnu.org > Subject: Re: [PATCH, libgcc] Make possible to disable JCR in crtstuff.c > > On Mon, Dec 17, 2012 at 5:23 PM, Joseph Prostko <joe.pros...@gmail.com> > wrote: > > On Mon, Dec 17, 2012 at 2:28 PM, H.J. Lu <hjl.to...@gmail.com> wrote: > >> On Mon, Dec 17, 2012 at 1:50 AM, Joey Ye <joey...@arm.com> wrote: > > > >>> * libgcc/Makefile.in: Include TARGET_USE_JCR_SECTION in CFLAGS. > >>> * libgcc/configure.ac (use_jcr_section): New variable. > >>> * libgcc/configure: Regenerated. > >>> * libgcc/crtstuff.c: Check TARGET_USE_JCR_SECTION. > >> > >> > >> I would use JAVA_IS_ENABLED instead of TARGET_USE_JCR_SECTION. > >> But it is only my personal preference. > > > > I believe Joey did that to be consistent with the > > TARGET_USE_JCR_SECTION macro used in gcc/defaults.h that can be turned > > on or off for targets that specify it . If JAVA_IS_ENABLED is used > > instead, should TARGET_USE_JCR_SECTION be deprecated? > > > > TARGET_USE_JCR_SECTION determines whether to use the JCR section > to register Java classes. We don't need to do anything for Java if Java > isn't enabled. The change can be as simple as > > #ifndef JAVA_IS_ENABLED > #undef JCR_SECTION_NAME > #endif > > in crtstuff.c. Can you give it a try? Tried and it simply worked. But undef JCR_SECTION_NAME here is very hacking.
> > > -- > H.J.