GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  LIBRTLD_DB (3)

NAME

librtld_db - library for run-time linker debugging

CONTENTS

Library
Synopsis
Description
Return Values
See Also
History
Authors
Caveats

LIBRARY


.Lb librtld_db

SYNOPSIS


.In rtld_db.h void
.Fo rd_delete rd_agent_t *rdap
.Fc char *
.Fo rd_errstr rd_err_e rderr
.Fc rd_err_e
.Fo rd_event_addr rd_agent_t *rdap, rd_event_e event, rd_notify_t *notify
.Fc rd_err_e
.Fo rd_event_enable rd_agent_t *rdap, int onoff
.Fc rd_err_e
.Fo rd_event_getmsg rd_agent_t *rdap, rd_event_msg_t *msg
.Fc rd_err_e
.Fo rd_init int version
.Fc typedef int
.Fo rl_iter_f const rd_loadobj_t *, void *
.Fc rd_err_e
.Fo rd_loadobj_iter rd_agent_t *rdap, rl_iter_f *cb, void *clnt_data
.Fc void
.Fo rd_log const int onoff
.Fc rd_agent_t *
.Fo rd_new struct proc_handle *php
.Fc rd_err_e
.Fo rd_objpad_enable rd_agent_t *rdap, size_t padsize
.Fc rd_err_e
.Fo rd_plt_resolution rd_agent_t *rdap, uintptr_t pc, struct proc *proc uintptr_t plt_base, rd_plt_info_t *rpi
.Fc rd_err_e
.Fo rd_reset rd_agent_t *rdap
.Fc

DESCRIPTION

The librtld_db library provides a debugging interface to the run-time linker (rtld). This library must be used along with libproc(3).

Most library functions take a rd_agent_t argument. This argument is an opaque structure containing information associated with the current status of the agent.

Before you start using librtld_db you should call rd_init with the RD_VERSION argument. This initializes the library to the correct version your program was compiled with and provides proper ABI stability.

What follows is a description of what each function.

rd_new creates a new librtld_db agent. The php argument should be the proc_handle you received from libproc(3).

rd_reset resets your previously created agent.

rd_delete deallocates the resources associated with the agent.

rd_errstr returns an error string describing the error present in rderr.

rd_event_enable enables reporting of events. This function always returns RD_OK.

rd_event_addr returns the event address corresponding to the event parameter. At the moment we only report events of type RD_NOTIFY_BPT.

rd_event_getmsg returns the message associated with the latest event. At the moment only RD_POSTINIT events are supported.

rd_loadobj_iter allows you to iterate over the program’s loaded objects. cb is a callback of type rl_iter_f.

RETURN VALUES

Most functions return an rd_err_e type error. The error codes are described in the header file for this library. You can get the error string using rd_errstr.

SEE ALSO

ld(1), ld-elf.so.1(1), ld.so(1), libproc(3), rtld(1)

HISTORY

The librtld_db library first appeared in
.Fx 9.0 and was modeled after the same library present in the Solaris operating system.

AUTHORS

The librtld_db library and this manual page were written by
.An Rui Paulo Aq rpaulo@FreeBSD.org under sponsorship from the FreeBSD Foundation.

CAVEATS

The functions rd_event_enable, rd_log, rd_objpad_enable and rd_plt_resolution are not yet implemented.
Search for    or go to Top of page |  Section 3 |  Main Index


Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.