List Info

Thread: Crazy idea for easy (lazy) dlopen replacement




Crazy idea for easy (lazy) dlopen replacement
user name
2006-12-22 15:34:35
Hi,

As we all know it would be nice if more programs would
runtime 
conditionally support some of there features, think for
example mp3 support.

The traditional way todo this is dlopen and friends, but
that is a bit 
of a pain, so I had this crazy idea why not (ab)use the
RTLD_LAZY 
feature also done by ld.so ?

If we could add a way to tell ld.so that a certain library
is optional, 
and then add a libc function call to ask if such an optional
library was 
  found, then all we need todo is make sure no symbols of
said library 
are used when it is not found, when we do not use any such
symbols, the 
RTLD_LAZY feature basicly means that we do not need the
library. Since 
many programs for for example image and sound formats usualy
have only 
one code path to filter out for a certain image / sound
format so if 
this dirty hack / feature of optional libraries could be
added then
supporting optional libs would be easy.

Regards,

Hans

p.s.

I'll be offline for 2 weeks since I will be away from work
for 2 weeks 
and I currently do not have internet access at home because
I just 
moved. SO don't expect any replies to replies from me soon.


-- 
fedora-extras-list mailing list
fedora-extras-listredhat.com
https://www.redhat.com/mailman/listinfo/fedora-extras-
list
Crazy idea for easy (lazy) dlopen replacement
user name
2006-12-22 15:34:35
Hi,

As we all know it would be nice if more programs would
runtime 
conditionally support some of there features, think for
example mp3 support.

The traditional way todo this is dlopen and friends, but
that is a bit 
of a pain, so I had this crazy idea why not (ab)use the
RTLD_LAZY 
feature also done by ld.so ?

If we could add a way to tell ld.so that a certain library
is optional, 
and then add a libc function call to ask if such an optional
library was 
  found, then all we need todo is make sure no symbols of
said library 
are used when it is not found, when we do not use any such
symbols, the 
RTLD_LAZY feature basicly means that we do not need the
library. Since 
many programs for for example image and sound formats usualy
have only 
one code path to filter out for a certain image / sound
format so if 
this dirty hack / feature of optional libraries could be
added then
supporting optional libs would be easy.

Regards,

Hans

p.s.

I'll be offline for 2 weeks since I will be away from work
for 2 weeks 
and I currently do not have internet access at home because
I just 
moved. SO don't expect any replies to replies from me soon.


-- 
fedora-extras-list mailing list
fedora-extras-listredhat.com
https://www.redhat.com/mailman/listinfo/fedora-extras-
list
[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )