old-www/HOWTO/C++-dlopen/index.html

392 lines
4.8 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML
><HEAD
><TITLE
>C++ dlopen mini HOWTO</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.7"><LINK
REL="NEXT"
TITLE="Introduction"
HREF="intro.html"></HEAD
><BODY
CLASS="article"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><DIV
CLASS="ARTICLE"
><DIV
CLASS="TITLEPAGE"
><H1
CLASS="title"
><A
NAME="AEN2"
></A
>C++ dlopen mini HOWTO</H1
><H3
CLASS="author"
><A
NAME="AEN4"
>Aaron Isotton</A
></H3
><DIV
CLASS="affiliation"
><DIV
CLASS="address"
><P
CLASS="address"
><TT
CLASS="email"
>&#60;<A
HREF="mailto:aaron@isotton.com"
>aaron@isotton.com</A
>&#62;</TT
></P
></DIV
></DIV
><P
CLASS="pubdate"
>2006-03-16<BR></P
><DIV
CLASS="revhistory"
><TABLE
WIDTH="100%"
BORDER="0"
><TR
><TH
ALIGN="LEFT"
VALIGN="TOP"
COLSPAN="3"
><B
>Revision History</B
></TH
></TR
><TR
><TD
ALIGN="LEFT"
>Revision 1.10</TD
><TD
ALIGN="LEFT"
>2006-03-16</TD
><TD
ALIGN="LEFT"
>Revised by: AI</TD
></TR
><TR
><TD
ALIGN="LEFT"
COLSPAN="3"
>Changed the license from the GFDL to the GPL. Fixed usage
of dlerror; thanks to Carmelo Piccione. Using a virtual destructor
in the example; thanks to Joerg Knobloch. Added Source Code
section. Minor fixes.</TD
></TR
><TR
><TD
ALIGN="LEFT"
>Revision 1.03</TD
><TD
ALIGN="LEFT"
>2003-08-12</TD
><TD
ALIGN="LEFT"
>Revised by: AI</TD
></TR
><TR
><TD
ALIGN="LEFT"
COLSPAN="3"
>Added reference to the GLib Dynamic Module
Loader. Thanks to G. V. Sriraam for the pointer.</TD
></TR
><TR
><TD
ALIGN="LEFT"
>Revision 1.02</TD
><TD
ALIGN="LEFT"
>2002-12-08</TD
><TD
ALIGN="LEFT"
>Revised by: AI</TD
></TR
><TR
><TD
ALIGN="LEFT"
COLSPAN="3"
>Added FAQ. Minor changes</TD
></TR
><TR
><TD
ALIGN="LEFT"
>Revision 1.01</TD
><TD
ALIGN="LEFT"
>2002-06-30</TD
><TD
ALIGN="LEFT"
>Revised by: AI</TD
></TR
><TR
><TD
ALIGN="LEFT"
COLSPAN="3"
>Updated virtual destructor explanation. Minor changes.</TD
></TR
><TR
><TD
ALIGN="LEFT"
>Revision 1.00</TD
><TD
ALIGN="LEFT"
>2002-06-19</TD
><TD
ALIGN="LEFT"
>Revised by: AI</TD
></TR
><TR
><TD
ALIGN="LEFT"
COLSPAN="3"
>Moved copyright and license section to the
beginning. Added terms section. Minor changes.</TD
></TR
><TR
><TD
ALIGN="LEFT"
>Revision 0.97</TD
><TD
ALIGN="LEFT"
>2002-06-19</TD
><TD
ALIGN="LEFT"
>Revised by: JYG</TD
></TR
><TR
><TD
ALIGN="LEFT"
COLSPAN="3"
>Entered minor grammar and sentence level changes.</TD
></TR
><TR
><TD
ALIGN="LEFT"
>Revision 0.96</TD
><TD
ALIGN="LEFT"
>2002-06-12</TD
><TD
ALIGN="LEFT"
>Revised by: AI</TD
></TR
><TR
><TD
ALIGN="LEFT"
COLSPAN="3"
>Added bibliography. Corrected explanation of extern
functions and variables.</TD
></TR
><TR
><TD
ALIGN="LEFT"
>Revision 0.95</TD
><TD
ALIGN="LEFT"
>2002-06-11</TD
><TD
ALIGN="LEFT"
>Revised by: AI</TD
></TR
><TR
><TD
ALIGN="LEFT"
COLSPAN="3"
>Minor improvements.</TD
></TR
></TABLE
></DIV
><DIV
><DIV
CLASS="abstract"
><A
NAME="AEN52"
></A
><P
></P
><P
>How to dynamically load C++ functions and classes using
the <TT
CLASS="function"
>dlopen</TT
> API.</P
><P
></P
></DIV
></DIV
><HR></DIV
><DIV
CLASS="TOC"
><DL
><DT
><B
>Table of Contents</B
></DT
><DT
>1. <A
HREF="intro.html"
>Introduction</A
></DT
><DD
><DL
><DT
>1.1. <A
HREF="intro.html#copyright"
>Copyright and License</A
></DT
><DT
>1.2. <A
HREF="intro.html#disclaimer"
>Disclaimer</A
></DT
><DT
>1.3. <A
HREF="intro.html#credits"
>Credits / Contributors</A
></DT
><DT
>1.4. <A
HREF="intro.html#feedback"
>Feedback</A
></DT
><DT
>1.5. <A
HREF="intro.html#AEN91"
>Terms Used in this Document</A
></DT
></DL
></DD
><DT
>2. <A
HREF="theproblem.html"
>The Problem</A
></DT
><DD
><DL
><DT
>2.1. <A
HREF="theproblem.html#mangling"
>Name Mangling</A
></DT
><DT
>2.2. <A
HREF="theproblem.html#AEN137"
>Classes</A
></DT
></DL
></DD
><DT
>3. <A
HREF="thesolution.html"
>The Solution</A
></DT
><DD
><DL
><DT
>3.1. <A
HREF="thesolution.html#externC"
><TT
CLASS="literal"
>extern "C"</TT
></A
></DT
><DT
>3.2. <A
HREF="thesolution.html#loadingfunctions"
>Loading Functions</A
></DT
><DT
>3.3. <A
HREF="thesolution.html#loadingclasses"
>Loading Classes</A
></DT
></DL
></DD
><DT
>4. <A
HREF="source.html"
>Source Code</A
></DT
><DT
>5. <A
HREF="faq.html"
>Frequently Asked Questions</A
></DT
><DT
>6. <A
HREF="seealso.html"
>See Also</A
></DT
><DT
><A
HREF="b304.html"
>Bibliography</A
></DT
></DL
></DIV
></DIV
><DIV
CLASS="NAVFOOTER"
><HR
ALIGN="LEFT"
WIDTH="100%"><TABLE
SUMMARY="Footer navigation table"
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
>&nbsp;</TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
>&nbsp;</TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><A
HREF="intro.html"
ACCESSKEY="N"
>Next</A
></TD
></TR
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
>&nbsp;</TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
>&nbsp;</TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
>Introduction</TD
></TR
></TABLE
></DIV
></BODY
></HTML
>