[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

1.1 BFD library interfaces

One way to look at the BFD library is to divide it into four parts by type of interface.

The first interface is the set of generic functions which programs using the BFD library will call. These generic function normally translate directly or indirectly into calls to routines which are specific to a particular object file format. Many of these generic functions are actually defined as macros in `bfd.h'. These functions comprise the official BFD interface.

The second interface is the set of functions which appear in the target vectors. This is the bulk of the code in BFD. A target vector is a set of function pointers specific to a particular object file format. The target vector is used to implement the generic BFD functions. These functions are always called through the target vector, and are never called directly. The target vector is described in detail in 3. BFD target vector. The set of functions which appear in a particular target vector is often referred to as a BFD backend.

The third interface is a set of oddball functions which are typically specific to a particular object file format, are not generic functions, and are called from outside of the BFD library. These are used as hooks by the linker and the assembler when a particular object file format requires some action which the BFD generic interface does not provide. These functions are typically declared in `bfd.h', but in many cases they are only provided when BFD is configured with support for a particular object file format. These functions live in a grey area, and are not really part of the official BFD interface.

The fourth interface is the set of BFD support functions which are called by the other BFD functions. These manage issues like memory allocation, error handling, file access, hash tables, swapping, and the like. These functions are never called from outside of the BFD library.


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

This document was generated by system on December, 2 2004 using texi2html