|
From: | Michael Matz |
Subject: | Re: [Tinycc-devel] Do not load all referenced libraries, when linking a library |
Date: | Tue, 10 Oct 2023 17:37:46 +0200 (CEST) |
User-agent: | Alpine 2.21 (LSU 202 2017-01-01) |
Hello, On Tue, 10 Oct 2023, Herman ten Brugge via Tinycc-devel wrote:
On 10/5/23 22:55, Detlef Riekenberg wrote:After the comments from grischka and Michael, i prepared a different patch to fix the build break of netbsd-curses and also updated the patch to current mob. `make test` works A testapp with netbsd-curses works, but i am away for the next 2 weeks. Since we have a release canditate, i decided to not push my patch to mob.I think this is not correct.If I read the elf documentation correctly a shared lib does not have to follow DT_NEEDED.See attached patch.
Only runtime loaders are required to follow DT_NEEDED. link editors aren't. There's no distinction between emitting a shared lib or an executable. (And for OUTPUT_MEMORY, which might be said to make tcc behave like a runtime loader, it's actually dlopen which does the necessary DT_NEEDED following).
Ciao, Michael.
[Prev in Thread] | Current Thread | [Next in Thread] |