ldso: don't strip leading path from ROM name

This patch removes ldso's builtin policy of removing any path elements
prepending the ROM module name. Instead, the ROM name is used as is.
This clears the way to access different ROM modules that share the same
name but are stored at different directories behind an fs_rom (e.g.,
/bin/bash vs. /usr/local/bin/bash).

Issue #3500
This commit is contained in:
Norman Feske 2019-09-23 14:34:27 +02:00 committed by Christian Helmuth
parent a17c5e30b7
commit 697d496093

View File

@ -104,7 +104,7 @@ class Linker::Elf_object : public Object, private Fifo<Elf_object>::Element
bool _init_elf_file(Env &env, Allocator &md_alloc, char const *path)
{
_elf_file.construct(env, md_alloc, Linker::file(path), true);
_elf_file.construct(env, md_alloc, path, true);
Object::init(Linker::file(path), *_elf_file);
return true;
}