From: Olivier Hainque Date: Thu, 15 Oct 2020 17:39:05 +0000 (+0000) Subject: Fix the vxworks crtstuff handling of kernel/rtp variations X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=2d23fd23bbb84a6ea87cb8c77699261d6ae8100e;p=gcc.git Fix the vxworks crtstuff handling of kernel/rtp variations The ports that support RTPs achieve the kernel/rtp compilation and link distinction through the multilib mechanism. This patch just removes the bogus explicit extraneous materialization of this distinction in the common VxWorks configuration files and leaves the rtp specialization all to the multilib machinery. 2020-10-15 Olivier Hainque libgcc/ * config/t-vxcrtstuff: Remove the -kernel/-rtp specialization. gcc/ * config/vxworks.h (VX_CRTBEGIN_SPEC): Likewise. --- diff --git a/gcc/config/vxworks.h b/gcc/config/vxworks.h index d3c417e7f5a..5b1538085e9 100644 --- a/gcc/config/vxworks.h +++ b/gcc/config/vxworks.h @@ -158,8 +158,7 @@ along with GCC; see the file COPYING3. If not see /* Setup the crtstuff begin/end we might need for dwarf EH registration. */ #if !defined(CONFIG_SJLJ_EXCEPTIONS) && DWARF2_UNWIND_INFO -#define VX_CRTBEGIN_SPEC \ - "%{!mrtp:vx_crtbegin-kernel.o%s} %{mrtp:vx_crtbegin-rtp.o%s}" +#define VX_CRTBEGIN_SPEC "vx_crtbegin.o%s" #define VX_CRTEND_SPEC "-l:vx_crtend.o" #else #define VX_CRTBEGIN_SPEC "" diff --git a/libgcc/config/t-vxcrtstuff b/libgcc/config/t-vxcrtstuff index 96b728525e0..ef64951c903 100644 --- a/libgcc/config/t-vxcrtstuff +++ b/libgcc/config/t-vxcrtstuff @@ -1,12 +1,12 @@ -# crtbegin/crtend for VxWorks (DKM or RTP) +# crtbegin/crtend for VxWorks -vx_crtbegin-kernel.o: $(srcdir)/config/vxcrtstuff.c +vx_crtbegin.o: $(srcdir)/config/vxcrtstuff.c $(crt_compile) $(CRTSTUFF_T_CFLAGS) -DCRT_BEGIN -c $< -vx_crtbegin-rtp.o: $(srcdir)/config/vxcrtstuff.c - $(crt_compile) $(CRTSTUFF_T_CFLAGS) -DCRT_BEGIN -c $< -mrtp - vx_crtend.o: $(srcdir)/config/vxcrtstuff.c $(crt_compile) $(CRTSTUFF_T_CFLAGS) -DCRT_END -c $< -EXTRA_PARTS += vx_crtbegin-kernel.o vx_crtbegin-rtp.o vx_crtend.o +# We do pretty different things for kernel vs rtp modes, all +# controlled thanks to __RTP__ and (optional) multilibs. + +EXTRA_PARTS += vx_crtbegin.o vx_crtend.o