Skip to content

Update L4Re compilers - #344

Open
jkloetzke wants to merge 5 commits into
BobBuildTool:masterfrom
jkloetzke:update-l4re
Open

jkloetzke wants to merge 5 commits into
BobBuildTool:masterfrom
jkloetzke:update-l4re

Conversation

@jkloetzke

Copy link
Copy Markdown
Member

No description provided.

The MIPS L4Re toolchains need binutils to know the mips*-*-l4re*
targets.

Signed-off-by: Jan Klötzke <jan.kloetzke@kernkonzept.com>
Current L4Re uses musl instead of uClibc as its libc. The sysroot has no
l4-arch header directory anymore and the dynamic linker is
/rom/libc.so.1. The L4Re linker scripts reject .ctors/.dtors sections,
so gcc must always use .init_array. Configure cannot detect this when
building the bootstrap compiler without target headers.

The gcc L4Re patch also gains RISC-V and MIPS support.

Signed-off-by: Jan Klötzke <jan.kloetzke@kernkonzept.com>
L4Re supports these architectures and needs toolchains for them.

The L4Re toolchains are tested in their own project so that they are
not built by default with the Linux tests.

Signed-off-by: Jan Klötzke <jan.kloetzke@kernkonzept.com>
The L4Re loader passes AT_PHDR only for binaries with a PT_PHDR segment,
which static executables lack. Their TLS segment was thus never set up,
breaking any TLS access through __tls_get_addr. Additionally, the
minimum TLS alignment evaluated to 1, which yields an unaligned DTV and
crashes static programs on MIPS32.

Signed-off-by: Jan Klötzke <jan.kloetzke@kernkonzept.com>
Build small C and C++ programs with the L4Re cross toolchains and run
them in an L4Re image on QEMU to verify the toolchains on the target.

Signed-off-by: Jan Klötzke <jan.kloetzke@kernkonzept.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant