* Need some advice of how to get the ld.so names in multilib situation
@ 2011-07-29 3:20 Lu, Lianhao
2011-07-29 16:57 ` Mark Hatle
0 siblings, 1 reply; 2+ messages in thread
From: Lu, Lianhao @ 2011-07-29 3:20 UTC (permalink / raw)
To: poky@yoctoproject.org
Hi guys,
Bug #1236 http://bugzilla.pokylinux.org/show_bug.cgi?id=1236
In order to get ldd work under the multilib situation, ldd and ldconfig.h need
to know all the full path names for all the dynamic loaders(ld.so) in the
current multilib configuration.
The dynamic loader's full path names would be something like:
${base_libdir}/<ld.so name>
We can get the ${base_libdir} for each variant in the multilib configuration by
setting the correct TUNE name. The problem resides in the <ld.so name>. For
i586 and x86_32, the ld.so name would be "ld-linux.so.2"; for x86_64 it would
be "ld-linux-x86-64.so.2"; but for other ABI, I see names like "ld-linux.so.3",
"ld.so.1", "ld64.so.1", etc.
So the question is how we can get the correct ld.so names in the current
multilib configuration? Hard code them in the TUNE configurations?
Best Regards,
-Lianhao
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Need some advice of how to get the ld.so names in multilib situation
2011-07-29 3:20 Need some advice of how to get the ld.so names in multilib situation Lu, Lianhao
@ 2011-07-29 16:57 ` Mark Hatle
0 siblings, 0 replies; 2+ messages in thread
From: Mark Hatle @ 2011-07-29 16:57 UTC (permalink / raw)
To: poky
On 7/28/11 10:20 PM, Lu, Lianhao wrote:
> Hi guys,
>
> Bug #1236 http://bugzilla.pokylinux.org/show_bug.cgi?id=1236
>
> In order to get ldd work under the multilib situation, ldd and ldconfig.h need
> to know all the full path names for all the dynamic loaders(ld.so) in the
> current multilib configuration.
>
> The dynamic loader's full path names would be something like:
> ${base_libdir}/<ld.so name>
>
> We can get the ${base_libdir} for each variant in the multilib configuration by
> setting the correct TUNE name. The problem resides in the <ld.so name>. For
> i586 and x86_32, the ld.so name would be "ld-linux.so.2"; for x86_64 it would
> be "ld-linux-x86-64.so.2"; but for other ABI, I see names like "ld-linux.so.3",
> "ld.so.1", "ld64.so.1", etc.
>
> So the question is how we can get the correct ld.so names in the current
> multilib configuration? Hard code them in the TUNE configurations?
We can likely create a custom ldd and ldconfig.h (assuming it's only used by
ldconfig) machine package. In this we can iterate over the multilibs configured
for the system and construct the necessary table of library paths. (This is of
course way more complicated then just saying "the paths are here for this
architecture..." but it seems to me that people want/require the flexibility to
change the library paths for their particular devices and distributions.
To iterate over it, we'll need to use python and then the base and multilib
values.. we can evaluate the ${libdir} and ${base_libdir} as necessary. For the
individual ld.so names, those will need to be encoded into the libc itself.. the
tunes don't have the knowledge for the machine ABI -> ld.so mapping.
Then the table can be constructed something like (pseudo code, not python):
def so_mapping:
if "i386" return "ld-linux.so.2"
if "x86_64" return "ld-linux-x86-64.so.2"
...
set multilib value to ""
so_name = so_mapping($TARGET_ARCH)
echo ${base_libdir}/${so_name} > list
for each multilib
set OVERRIDES with multilib
so_name = so_mapping($TARGET_ARCH)
echo ${base_libdir}/${so_name} >> list
done
--Mark
> Best Regards,
> -Lianhao
> _______________________________________________
> poky mailing list
> poky@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/poky
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-07-29 16:57 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-07-29 3:20 Need some advice of how to get the ld.so names in multilib situation Lu, Lianhao
2011-07-29 16:57 ` Mark Hatle
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.