mirror of
https://github.com/apache/nuttx.git
synced 2026-08-29 05:10:44 +00:00
An FDPIC module is compiled by the stock arm-none-eabi GCC, which emits correct FDPIC objects for both C and C++, but it cannot be assembled or linked by that toolchain: its as rejects the FDPIC relocations, and its ld carries the armelf emulation alone. Linking FDPIC objects with the stock ld does not fail, which is the awkward part. It produces an object marked "UNIX - System V" instead of "ARM FDPIC" and turns every import into an R_ARM_JUMP_SLOT where the ABI wants an R_ARM_FUNCDESC_VALUE. A jump slot is one word and a descriptor is two, a code address and the GOT that goes with it, so the module links cleanly and then calls out of itself with the caller's data base still in the PIC register. No distribution packages the arm-uclinuxfdpiceabi target, so the image builds it, the way the Renesas stage already builds its own binutils. Only binutils is needed, no GCC and no C library, so the stage takes about a minute and the install is 20 MB stripped. The tarball comes from sourceware.org, the binutils project's own host, because ftp.gnu.org is not reliably reachable from every builder. curl runs with --fail so that a bad fetch says so, rather than piping an error page into tar and failing as "File format not recognized". Signed-off-by: Marco Casaroli <marco.casaroli@gmail.com> |
||
|---|---|---|
| .. | ||
| Dockerfile | ||