gcc/libgcc/config
Frederic Konrad 4099d6501e Tigthen libc_internal and crtstuff for VxWorks shared objects
This change tightens and documents the use of libc_internal, then
strengthens the VxWorks crtstuff objects for the support of shared
libraries. In particular:

- Define __dso_handle, which libstdc++.so requires,

- Provide _init and _fini functions to run through the init/fini arrays
  for shared libs in configurations which HAVE_INITFINI_ARRAY_SUPPORT.

The init/fini functions are provided by libc_internal.a for static links
but with slightly different names and we don't want to risk dragging other
libc_internal contents in the closure accidentally so make sure we don't
link with it.

As for the !vxworks crtstuff, the new shared libs specific bits are
conditioned by a CRTSTUFFS_O macro, for which we provide new Makefile
fragment.

The bits to actually use the fragment and the shared objects will
be added by a forthcoming change, as part of a more general configury
update for shared libs.

The change also adds guards the eh table registration code
in vxcrtstuff so the objects can be used for either init/fini
or eh tables independently.

2021-12-07  Fred Konrad  <konrad@adacore.com>
	    Olivier Hainque  <hainque@adacore.com>

gcc/
	* config/vxworks.h (VXWORKS_BASE_LIBS_RTP): Guard -lc_internal
	on !shared+!non-static and document.
	(VXWORKS_LIB_SPEC): Remove the bits intended to drag the
	init/fini functions from libc_internal in the shared lib case.
	(VX_CRTBEGIN_SPEC/VX_CRTEND_SPEC): Use vxcrtstuff objects also in
	configurations with shared lib and INITFINI_ARRAY support.

libgcc/
	* config/t-vxcrtstuffS: New Makefile fragment.
	* config/vxcrtstuff.c: Provide __dso_handle. Provide _init/_fini
	functions for INITFINI_ARRAY support in shared libs and guard
	the definition of eh table registration functions on conditions
	indicating they are needed.
2021-12-13 18:03:03 +00:00
..
aarch64 libgcc: Add missing runtime exception notices 2021-08-31 10:56:34 +01:00
alpha Update copyright years. 2021-01-04 10:26:59 +01:00
arc Update copyright years. 2021-01-04 10:26:59 +01:00
arm arm: add erratum mitigation to __gnu_cmse_nonsecure_call [PR102035] 2021-08-24 11:45:13 +01:00
avr Update copyright years. 2021-01-04 10:26:59 +01:00
bfin Update copyright years. 2021-01-04 10:26:59 +01:00
bpf GCC port for eBPF 2019-09-09 12:13:23 +02:00
c6x Update copyright years. 2021-01-04 10:26:59 +01:00
cr16 Update copyright years. 2021-01-04 10:26:59 +01:00
cris Update copyright years. 2021-01-04 10:26:59 +01:00
csky Update copyright years. 2021-01-04 10:26:59 +01:00
epiphany Update copyright years. 2021-01-04 10:26:59 +01:00
fr30 Update copyright years. 2021-01-04 10:26:59 +01:00
frv libgcc: Add missing runtime exception notices 2021-08-31 10:56:34 +01:00
ft32 Update copyright years. 2021-01-04 10:26:59 +01:00
gcn amdgcn: Enable support for TImode for AMD GCN 2021-06-29 08:19:56 -07:00
h8300 Update copyright years. 2021-01-04 10:26:59 +01:00
i386 libgcc, Darwin: Build a libgcc_s.1 for backwards compatibility. 2021-12-08 19:53:28 +00:00
ia64 Update copyright years. 2021-01-04 10:26:59 +01:00
iq2000 Update copyright years. 2021-01-04 10:26:59 +01:00
libbid Update copyright years. 2021-01-04 10:26:59 +01:00
lm32 Update copyright years. 2021-01-04 10:26:59 +01:00
m32c Update copyright years. 2021-01-04 10:26:59 +01:00
m32r Remove m32r{,le}-*-linux* support from GCC 2021-09-13 15:16:56 +00:00
m68k Update copyright years. 2021-01-04 10:26:59 +01:00
mcore Update copyright years. 2021-01-04 10:26:59 +01:00
microblaze Update copyright years. 2021-01-04 10:26:59 +01:00
mips Update copyright years. 2021-01-04 10:26:59 +01:00
mmix Update copyright years. 2021-01-04 10:26:59 +01:00
moxie Update copyright years. 2021-01-04 10:26:59 +01:00
msp430 Update copyright years. 2021-01-04 10:26:59 +01:00
nds32 Update copyright years. 2021-01-04 10:26:59 +01:00
nios2 Update copyright years. 2021-01-04 10:26:59 +01:00
nvptx Update copyright years. 2021-01-04 10:26:59 +01:00
or1k or1k: Update FPU to specify detect tininess before rounding 2021-10-23 05:57:16 +09:00
pa Fix typo in t-dimode 2021-11-27 21:47:47 +00:00
pdp11
pru libgcc: pru: Place mpyll into its own section 2021-05-13 23:11:01 +03:00
riscv RISC-V: jal cannot refer to a default visibility symbol for shared object. 2021-12-06 10:55:01 +08:00
rl78 Update copyright years. 2021-01-04 10:26:59 +01:00
rs6000 Replace t-ppccomm by t-vxworks in libgcc/config/rs6000 2021-12-10 13:17:22 +00:00
rx Update copyright years. 2021-01-04 10:26:59 +01:00
s390 libgcc: use .init_stack for constructors if available 2021-10-07 20:24:43 -07:00
score Update copyright years. 2021-01-04 10:26:59 +01:00
sh Update copyright years. 2021-01-04 10:26:59 +01:00
sol2 Update copyright years. 2021-01-04 10:26:59 +01:00
sparc Update copyright years. 2021-01-04 10:26:59 +01:00
stormy16 Update copyright years. 2021-01-04 10:26:59 +01:00
tilegx
tilepro Update copyright years. 2021-01-04 10:26:59 +01:00
v850 Update copyright years. 2021-01-04 10:26:59 +01:00
vax Update copyright years. 2021-01-04 10:26:59 +01:00
visium Update copyright years. 2021-01-04 10:26:59 +01:00
vms Update copyright years. 2021-01-04 10:26:59 +01:00
xtensa Update copyright years. 2021-01-04 10:26:59 +01:00
darwin-64.c Update copyright years. 2021-01-04 10:26:59 +01:00
darwin-crt-tm.c Update copyright years. 2021-01-04 10:26:59 +01:00
darwin-crt3.c Update copyright years. 2021-01-04 10:26:59 +01:00
darwin-unwind.ver libgcc, Darwin: Build a libgcc_s.1 for backwards compatibility. 2021-12-08 19:53:28 +00:00
darwin10-unwind-find-enc-func.c Darwin, crts: Fix a build warning. 2021-11-05 20:48:05 +00:00
gthr-lynx.h Update copyright years. 2021-01-04 10:26:59 +01:00
gthr-rtems.h Update copyright years. 2021-01-04 10:26:59 +01:00
gthr-vxworks-cond.c Update copyright years. 2021-01-04 10:26:59 +01:00
gthr-vxworks-thread.c Update copyright years. 2021-01-04 10:26:59 +01:00
gthr-vxworks-tls.c Update copyright years. 2021-01-04 10:26:59 +01:00
gthr-vxworks.c Update copyright years. 2021-01-04 10:26:59 +01:00
gthr-vxworks.h Update copyright years. 2021-01-04 10:26:59 +01:00
hardfp.c Update copyright years. 2021-01-04 10:26:59 +01:00
libgcc-glibc.ver Update copyright years. 2021-01-04 10:26:59 +01:00
libgcc-libsystem.ver Darwin: Rework handling for unwinder code in libgcc_s and specs [PR80556]. 2021-11-19 19:58:11 +00:00
no-sfp-machine.h
no-unwind.h
t-crtfm
t-crtstuff-pic
t-darwin libgcc, Darwin: Update darwin10 unwinder shim dependencies. 2021-12-10 23:15:15 +00:00
t-darwin-ehs libgcc, Darwin: Build a libgcc_s.1 for backwards compatibility. 2021-12-08 19:53:28 +00:00
t-dfprules
t-eh-dw2-dip
t-fdpbit
t-fixedpoint-gnu-prefix
t-fpbit
t-freebsd-thread
t-gnu-prefix
t-gthr-noweak musl: Don't use gthr weak refs in libgcc PR91737 2019-11-18 12:08:18 +00:00
t-gthr-vxworks Improve the thread support for VxWorks 2019-11-14 15:58:31 +00:00
t-gthr-vxworksae Update the libgcc support for VxWorks AE/653 2019-11-14 16:00:55 +00:00
t-hardfp Update copyright years. 2021-01-04 10:26:59 +01:00
t-hardfp-sfdf Update copyright years. 2021-01-04 10:26:59 +01:00
t-libgcc-pic
t-libunwind
t-libunwind-elf Update copyright years. 2021-01-04 10:26:59 +01:00
t-linux
t-openbsd-thread
t-rtems
t-slibgcc libgcc: Honor LDFLAGS_FOR_TARGET when linking libgcc_s 2021-08-05 17:32:06 +02:00
t-slibgcc-darwin libgcc, Darwin: Build a libgcc_s.1 for backwards compatibility. 2021-12-08 19:53:28 +00:00
t-slibgcc-elf-ver
t-slibgcc-fuchsia libgcc: Honor LDFLAGS_FOR_TARGET when linking libgcc_s 2021-08-05 17:32:06 +02:00
t-slibgcc-gld
t-slibgcc-gld-nover
t-slibgcc-hpux
t-slibgcc-libgcc Update copyright years. 2021-01-04 10:26:59 +01:00
t-slibgcc-nolc-override
t-slibgcc-sld
t-slibgcc-vms libgcc: Honor LDFLAGS_FOR_TARGET when linking libgcc_s 2021-08-05 17:32:06 +02:00
t-softfp Update copyright years. 2021-01-04 10:26:59 +01:00
t-softfp-compat
t-softfp-excl
t-softfp-sfdf
t-softfp-sfdftf
t-softfp-tf
t-stack
t-tls
t-vxcrtstuff Fix the vxworks crtstuff handling of kernel/rtp variations 2020-10-16 15:33:35 +00:00
t-vxcrtstuffS Tigthen libc_internal and crtstuff for VxWorks shared objects 2021-12-13 18:03:03 +00:00
t-vxworks Preserve cpu specific CRTSTUFF_T_CFLAGS on powerpc-vxworks7 2021-12-13 17:59:54 +00:00
t-vxworksae Update the libgcc support for VxWorks AE/653 2019-11-14 16:00:55 +00:00
unwind-dw2-fde-darwin.c Update copyright years. 2021-01-04 10:26:59 +01:00
vxcrtstuff.c Tigthen libc_internal and crtstuff for VxWorks shared objects 2021-12-13 18:03:03 +00:00