Error while compiling krb 1.5

Henry B. Hotz hotz at jpl.nasa.gov
Tue Jul 11 02:09:46 EDT 2006


On Jul 10, 2006, at 4:43 PM, Theodore Tso wrote:

> On Mon, Jul 10, 2006 at 04:22:35PM -0700, Henry B. Hotz wrote:
>> As someone noted, you can use libdl to access symbols in a statically
>> linked program.
>
> Err, no, you can't.  dlopen() is only supported on dynamically linked
> programs.  (This is true as far as I can tell for both Solaris and
> Linux, although for Solaris 10 Sun has effectively eliminated static
> linking by not providing libc.a anymore.)
>
> 							- Ted

I haven't *tried* this, so maybe I'm missing something, but:

 From dlopen(3DL) on Sol 9:

>      If the value of pathname is 0, dlopen() provides a handle on
>      a set of global symbol objects. These objects consist of the
>      original program image file, any dependencies loaded at pro-
>      gram startup, and any objects loaded using dlopen() with the
>      RTLD_GLOBAL flag.

Can't you just do this to get access to global symbols that are  
already there?  The only relevant restriction I see in the man page  
is that you can't get to dl objects that have been closed.

There are also options for dlsym() that look like they would do the  
same thing without a special open.
------------------------------------------------------------------------ 
----
The opinions expressed in this message are mine,
not those of Caltech, JPL, NASA, or the US Government.
Henry.B.Hotz at jpl.nasa.gov, or hbhotz at oxy.edu





More information about the krbdev mailing list