Add LIST_ delaration to event_struct.h to supplment TAILQ_

Generally, LIST_ can be a little faster than TAILQ_ for most
operations.  We only need to use TAILQ_ when we care about traversing
lists from tail-to-head, or we need to be able to add items to the end
of the list.
Use LIST rather than TAILQ for evmap_io and evmap_signal

These structures used TAILQ for the lists of events waiting on a
single fd or signal.  But order doesn't matter for these lists; only
the order of the active events lists actually matters.
Use LIST rather than TAILQ for evbuffer callbacks

There's no reason to traverse these out-of-order, and we never defined
the order that you'd get your callbacks on an evbuffer if you happened
to add more than one.
Use LIST rather than TAILQ for bufferevent_rate_limit_group members

Once again, there's no reason to keep these lists in the order we were
keeping them in.  Every time we needed to traverse them for any important
purpose, we started at a random point anyway.
support adding buffers to other buffers non-destructively
prevent nested multicast references, reworked locking
When a signal callback is activated to run multiple times, allow event_base_loopbreak to work even before they all have run.

Found by Abilio Marques.
Build with large-file support on platforms where it matters

Some hosts require you to define certain options to get a large off_t
instead of a small one, to get useful ftell and fseek calls instead of
ones that can only support 2GB files, and so on.  This patch makes
Libevent support those platforms by:

   * Defining the right options when we build, and
   * Changing our API so that it does not depend on the platform's
     definition of off_t.

Based on discusion with Michael Herf
Use _SOURCES, not _sources, in sample/Makefile.am

Found by Adrian Chadd
Merge remote-tracking branch 'origin/patches-2.0'
Merge branch '20_loopbreak_in_signal' into patches-2.0
Merge remote-tracking branch 'origin/patches-2.0'
Make evbuffer callbacks get the right n_added value after evbuffer_add

Patch from Alex.
Merge remote-tracking branch 'origin/patches-2.0'
Prefer mmap to sendfile unless a DRAINS_TO_FD flag is set. Allows add_file to work with SSL.

The sendfile() implementation for evbuffer_add_file is potentially more
efficient, but it has a problem: you can only use it to send bytes over
a socket using sendfile().  If you are writing bytes via SSL_send() or
via a filter, or if you need to be able to inspect your buffer, it
doesn't work.

As an easy fix, this patch disables the sendfile-based implementation of
evbuffer_add_file on an evbuffer unless the user sets a new
EVBUFFER_FLAG_DRAINS_TO_FD flag on that evbuffer, indicating that the
evbuffer will not be inspected, but only written out via
evbuffer_write(), evbuffer_write_atmost(), or drained with stuff like
evbuffer_drain() or evbuffer_add_buffer().  This flag is off by
default, except for evbuffers used for output on bufferevent_socket.

In the future, it could be interesting to make a best-effort file
segment implementation that tries to send via sendfile, but mmaps on
demand.  That's too much complexity for a stable release series, though.
Fixed compiler warnings for unchecked read/write calls.
Make write-checking fixes use tt_fail_perror
Fix some "value never used" warnings with gcc 4.6.1
Merge remote-tracking branch 'origin/patches-2.0'
Allow evconnlistener to be created in disabled state.