#ifndef _DLFCN_H
#define _DLFCN_H 1
#include
#define __need_size_t
#include
#include
#ifdef __USE_GNU
# define RTLD_NEXT ((void *) -1l)
# define RTLD_DEFAULT ((void *) 0)
typedef long int Lmid_t;
# define LM_ID_BASE 0
# define LM_ID_NEWLM -1
#endif
__BEGIN_DECLS
extern void *dlopen (__const char *__file, int __mode) __THROW;
extern int dlclose (void *__handle) __THROW __nonnull ((1));
extern void *dlsym (void *__restrict __handle,
__const char *__restrict __name) __THROW __nonnull ((2));
#ifdef __USE_GNU
extern void *dlmopen (Lmid_t __nsid, __const char *__file, int __mode) __THROW;
extern void *dlvsym (void *__restrict __handle,
__const char *__restrict __name,
__const char *__restrict __version)
__THROW __nonnull ((2, 3));
#endif
extern char *dlerror (void) __THROW;
#ifdef __USE_GNU
typedef struct
{
__const char *dli_fname;
void *dli_fbase;
__const char *dli_sname;
void *dli_saddr;
} Dl_info;
extern int dladdr (__const void *__address, Dl_info *__info)
__THROW __nonnull ((2));
extern int dladdr1 (__const void *__address, Dl_info *__info,
void **__extra_info, int __flags) __THROW __nonnull ((2));
the EXTRA_INFO argument is not used. */
enum
{
RTLD_DL_SYMENT = 1,
RTLD_DL_LINKMAP = 2
};
extern int dlinfo (void *__restrict __handle,
int __request, void *__restrict __arg)
__THROW __nonnull ((1, 3));
enum
{
RTLD_DI_LMID = 1,
RTLD_DI_LINKMAP = 2,
RTLD_DI_SERINFO = 4,
RTLD_DI_SERINFOSIZE = 5,
RTLD_DI_ORIGIN = 6,
RTLD_DI_CONFIGADDR = 3
};
typedef struct
{
char *dls_name;
unsigned int dls_flags;
} Dl_serpath;
typedef struct
{
size_t dls_size;
unsigned int dls_cnt;
Dl_serpath dls_serpath[1];
} Dl_serinfo;
#endif
__END_DECLS
#endif
|