On Mon, Nov 26, 2012 at 7:19 PM, Joey Ye <joey...@arm.com> wrote: > Ping^2 > >> -----Original Message----- >> From: Joey Ye >> Sent: Tuesday, November 20, 2012 10:09 >> To: gcc-patches@gcc.gnu.org >> Cc: Joey Ye >> Subject: RE: [PATCH, libgcc] Make possible to disable JCR in crtstuff.c >> >> Ping, as Joseph Prostko is saying that this patch shall solve the same >> problem he's facing. >> >> > -----Original Message----- >> > From: Joey Ye [mailto:joey...@arm.com] >> > Sent: Friday, September 21, 2012 15:42 >> > To: gcc-patches@gcc.gnu.org >> > Subject: [PATCH, libgcc] Make possible to disable JCR in crtstuff.c >> > >> > Current crtstuff.c checks if JCR_SECTION_NAME is defined to decide >> > whether >> > do work for JCR. However, defaults.h always defines JCR_SECTION_NAME: >> > >> > #ifndef JCR_SECTION_NAME >> > #define JCR_SECTION_NAME ".jcr" >> > #endif >> > >> > So it is impossible to disable JCR related code in crtbegin.o, which >> > can >> > save some bytes for every applications that doesn't need java. >> > >> > This patch revise the check of JCR_SECTION_NAME to >> > TARGET_USE_JCR_SECTION. >> > By defining latter to zero disable JCR in crtstuff. This change >> doesn't >> > impact logic of any target given following defines in defaults.h: >> > >> > #ifndef TARGET_USE_JCR_SECTION >> > #ifdef JCR_SECTION_NAME >> > #define TARGET_USE_JCR_SECTION 1 >> > #else >> > #define TARGET_USE_JCR_SECTION 0 >> > #endif >> > #endif >> > >> > Again, this patch doesn't impact libgcc on any target, unless >> > TARGET_USE_JCR_SECTION is explicitly defined to 0 with make >> > CFLAGS_FOR_TARGET=-DTARGET_USE_JCR_SECTION=0. AIX defines >> > TARGET_USE_JCR_SECTION to 0, but it has no crtbegin/end stuff. So also >> > no impact. >> > >> > OK to trunk? >> > >> > 2012-09-21 Joey Ye <joey...@arm.com> >> > >> > * crtstuff.c: Check TARGET_USE_JCR_SECTION. >> >
Since we have --enable-languages=.., can't we disable JCR_SECTION section if java isn't enabled? -- H.J.