tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

ld.elf_so compatibility for ancient ELF binaries (pre-2.0)

Hello all,
there is a compatiblity hack in ld.elf_so for early ELF binaries that I
would like to restructure and restrict to those architectures that
actually need it. Short version is that crt0.o would contain dlopen(3)
and friends and implement them by calling a pointer stored in the handle
passed to _start from the dynamic linker. The handle is not used for any
other purpose than checking some magic values and those function

The change that dropped this code from crt0.o can be found in

Determining which architectures need this hack is a bit tricky. From the
subdirectory list of
there was some form of ld.elf_so support for alpha, i386, m68k, mips,
powerpc, sparc and vax. m68k and vax can be dropped from the list, they
only contained some stub startup code. That leaves alpha, i386, mips,
powerpc and sparc.

The list of platforms where ELF was enabled by default can be found in
Note that this also includes sparc64. This makes no sense as the dynamic
linker had no support for it at the time. Do we care about binaries
build in a system before ELF was fully working?

Otherwise I would strictly reduce the compatibility hack to the above
mentioned five architectures. The difference is 132-256 Bytes in .data
and a couple of relocations.


Home | Main Index | Thread Index | Old Index