From: curts@compgen.com (Curt Smith)
Subject: Re: Wrappers for shared library functions?
Date: 1997/03/06 [thread overview]
Message-ID: <5fme1j$mhc$1@metro.atlanta.com> (raw)
In-Reply-To: 331EB4EA.2A0@netcomuk.co.uk
john hall (jhall@netcomuk.co.uk) wrote:
: I (john hall) wrote:
: >
: > I would be very grateful for any advice on how to create "wrappers" for
: > one or two functions in large shared libraries,
:
: As a consequence, although the renamed shared library file (e.g.
: libRenamedReal.so) is found by ld when creating the "dummy" libReal.so,
: the dependencies of the dummy library (revealed through odump -Dl)
: include the name "libReal.so" instead of "libRenamedReal.so".
Sure enough... I just did:
cp /usr/shlib/libm.so /tmp
vi /tmp/libm.so
And there's libc.so in a list of other (guess) dependancies. Given that
the start point of the "l" in libc.so must be left in place, and there's
strings immediately following, your ownly choice of hacking libm.so or
libxxx.so for that mater is to make the dependancy on libc.so to be
libC.so. Where you just change the characters of the dependant library.
Therefore do:
- Make your wrapper library named: libm.so (or what ever you're wrapping)
- Make the real library named: libM.so
- Edit libM.so to make the dependancies
on libm.so to be libM.so.
Good luck.
Curt Smith
curts@compgen.com
next prev parent reply other threads:[~1997-03-06 5:00 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
1997-03-05 5:00 Wrappers for shared library functions? john hall
1997-03-06 5:00 ` john hall
1997-03-06 5:00 ` Curt Smith [this message]
1997-03-11 5:00 ` Craig Neth USG
1997-03-13 5:00 ` john hall
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox