This is the mail archive of the gcc-help@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]
Other format: [Raw text]

Re: Bare metal ARM Cross compiler for arm-none-eabi target without libunwind?


> /usr/local/gcc/arm-elf-tools-4.7.0/lib/gcc/arm-none-eabi/4.7.0/thumb//libgcc.a(unwind-arm.o): In function `get_eit_entry':

I did a patch in libgcc "Makefile.in" that is very similar to Martin's:

This works:

# Build LIB2_DIVMOD_FUNCS.
+ ifeq ($(enable_libgcc_libunwind_exceptions),yes)
+ LIB2_DIVMOD_CFLAGS := -fexceptions -fnon-call-exceptions
+ else
+ LIB2_DIVMOD_CFLAGS := -fno-exceptions -fno-non-call-exceptions
+ endif
lib2-divmod-o = $(patsubst %,%$(objext),$(LIB2_DIVMOD_FUNCS))
$(lib2-divmod-o): %$(objext): $(srcdir)/libgcc2.c
	$(gcc_compile) -DL$* -c $< \
-	  -fexceptions -fnon-call-exceptions $(vis_hide)
+	  $(LIB2_DIVMOD_CFLAGS) $(vis_hide)
libgcc-objects += $(lib2-divmod-o)

ifeq ($(enable_shared),yes)
lib2-divmod-s-o = $(patsubst %,%_s$(objext),$(LIB2_DIVMOD_FUNCS))
$(lib2-divmod-s-o): %_s$(objext): $(srcdir)/libgcc2.c
	$(gcc_s_compile) -DL$* -c $< \
-	  -fexceptions -fnon-call-exceptions
+	   $(LIB2_DIVMOD_CFLAGS)
libgcc-s-objects += $(lib2-divmod-s-o)
endif


It seems to work fine, now I guess some work has to be done to add argument to configure-command line to be truly accepted.
I invented the new argument option 'enable_libgcc_libunwind_exceptions' to not mix-up with the old 'without-libunwind-exceptions'.
(Though I have some problems trying to add new arguments to configure, it does not seem to work fully yet...)

Thanks and Best Regards/Fredrik


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