diff options
author | Jerome Lambourg <lambourg@adacore.com> | 2019-11-14 15:53:23 +0000 |
---|---|---|
committer | Olivier Hainque <hainque@gcc.gnu.org> | 2019-11-14 15:53:23 +0000 |
commit | 78e49fb1bc69592389a09ce5544b40fef634e893 (patch) | |
tree | 6a4a42db11d921d3246820bf1f2cdc529af89bc2 /gcc/config/vxworks.h | |
parent | ebcdba9c9f71e548e7506ecc8cb13139614b392e (diff) | |
download | gcc-78e49fb1bc69592389a09ce5544b40fef634e893.zip gcc-78e49fb1bc69592389a09ce5544b40fef634e893.tar.gz gcc-78e49fb1bc69592389a09ce5544b40fef634e893.tar.bz2 |
Introduce vxworks specific crtstuff support
2019-11-06 Jerome Lambourg <lambourg@adacore.com>
Olivier Hainque <hainque@adacore.com>
libgcc/
* config/vxcrtstuff.c: New file.
* config/t-vxcrtstuff: New Makefile fragment.
* config.host: Append t-vxcrtstuff to the tmake_file list
on all VxWorks ports using dwarf for table based EH.
gcc/
* config/vx-common.h (USE_TM_CLONE_REGISTRY): Remove
definition, pointless with a VxWorks specific version
of crtstuff.
(DWARF2_UNWIND_INFO): Conditionalize on !ARM_UNWIND_INFO.
* config/vxworks.h (VX_CRTBEGIN_SPEC, VX_CRTEND_SPEC):
New local macros, controlling the addition of vxworks specific
crtstuff objects depending on the EH mechanism and kind of
module being linked.
(VXWORKS_STARTFILE_SPEC, VXWORKS_ENDFILE_SPEC): Use them.
Co-Authored-By: Olivier Hainque <hainque@adacore.com>
From-SVN: r278248
Diffstat (limited to 'gcc/config/vxworks.h')
-rw-r--r-- | gcc/config/vxworks.h | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/gcc/config/vxworks.h b/gcc/config/vxworks.h index 8c93a30..d7083b3 100644 --- a/gcc/config/vxworks.h +++ b/gcc/config/vxworks.h @@ -143,9 +143,23 @@ along with GCC; see the file COPYING3. If not see #undef VXWORKS_LIBGCC_SPEC #define VXWORKS_LIBGCC_SPEC "-lgcc" +/* 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_CRTEND_SPEC "-l:vx_crtend.o" +#else +#define VX_CRTBEGIN_SPEC "" +#define VX_CRTEND_SPEC "" +#endif + #undef VXWORKS_STARTFILE_SPEC -#define VXWORKS_STARTFILE_SPEC "%{mrtp:%{!shared:-l:crt0.o}}" -#define VXWORKS_ENDFILE_SPEC "" +#define VXWORKS_STARTFILE_SPEC \ + VX_CRTBEGIN_SPEC " %{mrtp:%{!shared:-l:crt0.o}}" + +#undef VXWORKS_ENDFILE_SPEC +#define VXWORKS_ENDFILE_SPEC VX_CRTEND_SPEC #undef VXWORKS_CC1_SPEC #if TARGET_VXWORKS7 |