<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
   "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
  <!ENTITY % general-entities SYSTEM "../../general.ent">
  %general-entities;

  <!ENTITY libevent-download-http "&sourceforge-repo;/levent/libevent-&libevent-version;-stable.tar.gz">
  <!ENTITY libevent-download-ftp  " ">
  <!ENTITY libevent-md5sum        "c4c56f986aa985677ca1db89630a2e11">
  <!ENTITY libevent-size          "835 KB">
  <!ENTITY libevent-buildsize     "19 MB (additional 1 MB for the tests and 6 MB for the API documentation)">
  <!ENTITY libevent-time          "0.3 SBU (additional 1.3 SBU for the tests)">
]>

<sect1 id="libevent" xreflabel="libevent-&libevent-version;">
  <?dbhtml filename="libevent.html"?>

  <sect1info>
    <othername>$LastChangedBy: bdubbs $</othername>
    <date>$Date: 2015-02-23 00:16:54 -0500 (Mon, 23 Feb 2015) $</date>
  </sect1info>

  <title>libevent-&libevent-version;</title>

  <indexterm zone="libevent">
    <primary sortas="a-libevent">libevent</primary>
  </indexterm>

  <sect2 role="package">
    <title>Introduction to libevent</title>

    <para>
      <application>libevent</application> is an asynchronous event notification
      software library. The <application>libevent</application> API provides a
      mechanism to execute a callback function when a specific event occurs on
      a file descriptor or after a timeout has been reached. Furthermore,
      <application>libevent</application> also supports callbacks due to
      signals or regular timeouts.
    </para>

    &lfs77_checked;

    <bridgehead renderas="sect3">Package Information</bridgehead>
    <itemizedlist spacing="compact">
      <listitem>
        <para>
          Download (HTTP): <ulink url="&libevent-download-http;"/>
        </para>
      </listitem>
      <listitem>
        <para>
          Download (FTP): <ulink url="&libevent-download-ftp;"/>
        </para>
      </listitem>
      <listitem>
        <para>
          Download MD5 sum: &libevent-md5sum;
        </para>
      </listitem>
      <listitem>
        <para>
          Download size: &libevent-size;
        </para>
      </listitem>
      <listitem>
        <para>
          Estimated disk space required: &libevent-buildsize;
        </para>
      </listitem>
      <listitem>
        <para>
          Estimated build time: &libevent-time;
        </para>
      </listitem>
    </itemizedlist>

    <bridgehead renderas="sect3">libevent Dependencies</bridgehead>

    <bridgehead renderas="sect4">Recommended</bridgehead>
    <para role="recommended">
      <xref linkend="openssl"/>
    </para>

    <bridgehead renderas="sect4">Optional</bridgehead>
    <para role="optional">
      <xref linkend="doxygen"/> (for API documentation)
    </para>

    <para condition="html" role="usernotes">
      User Notes: <ulink url="&blfs-wiki;/libevent"/>
    </para>
  </sect2>

  <sect2 role="installation">
    <title>Installation of libevent</title>

    <para>
      Install <application>libevent</application> by running the following
      commands:
    </para>

<screen><userinput>./configure --prefix=/usr --disable-static &amp;&amp;
make</userinput></screen>

    <para>
      If you have <xref linkend="doxygen"/> installed and wish to build API
      documentation, issue <command>doxygen Doxyfile</command>.
    </para>

    <para>
      To test the results, issue: <command>make verify</command>.
    </para>

    <para>
      Now, as the <systemitem class="username">root</systemitem> user:
    </para>

<screen role="root"><userinput>make install</userinput></screen>

    <para>
      If you built the API documentation, install it by issuing the following
      commands as the <systemitem class="username">root</systemitem> user:
    </para>

<screen role="root"><userinput>install -v -m755 -d /usr/share/doc/libevent-&libevent-version;/api &amp;&amp;
cp      -v -R       doxygen/html/* \
                    /usr/share/doc/libevent-&libevent-version;/api</userinput></screen>
  </sect2>

  <sect2 role="commands">
    <title>Command Explanations</title>

    <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
      href="../../xincludes/static-libraries.xml"/>

  </sect2>

  <sect2 role="content">
    <title>Contents</title>

    <segmentedlist>
      <segtitle>Installed Program</segtitle>
      <segtitle>Installed Libraries</segtitle>
      <segtitle>Installed Directory</segtitle>

      <seglistitem>
        <seg>
          event_rpcgen.py
        </seg>
        <seg>
          libevent_core.so,
          libevent_extra.so,
          libevent_openssl.so,
          libevent_pthreads.so and
          libevent.so
        </seg>
        <seg>
         /usr/include/event2 and
         /usr/share/doc/libevent-&libevent-version;
        </seg>
      </seglistitem>
    </segmentedlist>

    <!-- Who knows what these things do?
    <variablelist>
      <bridgehead renderas="sect3">Short Descriptions</bridgehead>
      <?dbfo list-presentation="list"?>
      <?dbhtml list-presentation="table"?>

      <varlistentry id="event_rpcgen.py">
        <term><command>event_rpcgen.py</command></term>
        <listitem>
          <para>
            does this .....
          </para>
          <indexterm zone="libevent event_rpcgen.py">
            <primary sortas="b-event_rpcgen.py">event_rpcgen.py</primary>
          </indexterm>
        </listitem>
      </varlistentry>

      <varlistentry id="libevent_core">
        <term><filename class="libraryfile">libevent_core.so</filename></term>
        <listitem>
          <para>
            contains functions that .....
          </para>
          <indexterm zone="libevent libevent_core">
            <primary sortas="c-libevent_core">libevent_core.so</primary>
          </indexterm>
        </listitem>
      </varlistentry>
    </variablelist>

      <varlistentry id="libevent_extra">
        <term><filename class="libraryfile">libevent_extra.so</filename></term>
        <listitem>
          <para>
            contains functions that .....
          </para>
          <indexterm zone="libevent libevent_extra">
            <primary sortas="c-libevent_extra">libevent_extra.so</primary>
          </indexterm>
        </listitem>
      </varlistentry>
    </variablelist>

      <varlistentry id="libevent_openssl">
        <term><filename class="libraryfile">libevent_openssl.so</filename></term>
        <listitem>
          <para>
            contains functions that .....
          </para>
          <indexterm zone="libevent libevent_openssl">
            <primary sortas="c-libevent_openssl">libevent_openssl.so</primary>
          </indexterm>
        </listitem>
      </varlistentry>
    </variablelist>

      <varlistentry id="libevent_pthreads">
        <term><filename class="libraryfile">libevent_pthreads.so</filename></term>
        <listitem>
          <para>
            contains functions that .....
          </para>
          <indexterm zone="libevent libevent_pthreads">
            <primary sortas="c-libevent_pthreads">libevent_pthreads.so</primary>
          </indexterm>
        </listitem>
      </varlistentry>
    </variablelist>

      <varlistentry id="libevent-lib">
        <term><filename class="libraryfile">libevent.so</filename></term>
        <listitem>
          <para>
            contains functions that .....
          </para>
          <indexterm zone="libevent libevent-lib">
            <primary sortas="c-libevent">libevent.so</primary>
          </indexterm>
        </listitem>
      </varlistentry>

    </variablelist> -->

  </sect2>

</sect1>
