2012-02-10 17:29:53 -05:00
|
|
|
# Makefile.am for libevent
|
|
|
|
# Copyright 2000-2007 Niels Provos
|
|
|
|
# Copyright 2007-2012 Niels Provos and Nick Mathewson
|
|
|
|
#
|
|
|
|
# See LICENSE for copying information.
|
|
|
|
|
2017-01-15 12:31:27 +03:00
|
|
|
# 'foreign' means that we're not enforcing GNU package rules strictly.
|
|
|
|
# '1.9' means that we need automake 1.9 or later (and we do).
|
|
|
|
AUTOMAKE_OPTIONS = foreign 1.9 subdir-objects
|
|
|
|
|
2009-01-22 02:47:35 +00:00
|
|
|
ACLOCAL_AMFLAGS = -I m4
|
2002-04-09 17:02:38 +00:00
|
|
|
|
2010-06-19 18:23:16 -04:00
|
|
|
# This is the "Release" of the Libevent ABI. It takes precedence over
|
|
|
|
# the VERSION_INFO, so that two versions of Libevent with the same
|
|
|
|
# "Release" are never binary-compatible.
|
|
|
|
#
|
|
|
|
# This number incremented once for the 2.0 release candidate, and
|
2010-12-15 14:29:50 -05:00
|
|
|
# will increment for each series until we revise our interfaces enough
|
|
|
|
# that we can seriously expect ABI compatibility between series.
|
2010-06-19 18:23:16 -04:00
|
|
|
#
|
2010-12-16 12:59:22 -05:00
|
|
|
RELEASE = -release 2.1
|
2010-06-19 18:23:16 -04:00
|
|
|
|
2007-11-04 02:21:31 +00:00
|
|
|
# This is the version info for the libevent binary API. It has three
|
|
|
|
# numbers:
|
|
|
|
# Current -- the number of the binary API that we're implementing
|
|
|
|
# Revision -- which iteration of the implementation of the binary
|
|
|
|
# API are we supplying?
|
|
|
|
# Age -- How many previous binary API versions do we also
|
|
|
|
# support?
|
|
|
|
#
|
2010-06-19 18:23:16 -04:00
|
|
|
# To increment a VERSION_INFO (current:revision:age):
|
|
|
|
# If the ABI didn't change:
|
|
|
|
# Return (current:revision+1:age)
|
|
|
|
# If the ABI changed, but it's backward-compatible:
|
|
|
|
# Return (current+1:0:age+1)
|
|
|
|
# If the ABI changed and it isn't backward-compatible:
|
|
|
|
# Return (current+1:0:0)
|
2007-11-04 02:21:31 +00:00
|
|
|
#
|
2010-10-26 10:38:30 -04:00
|
|
|
# Once an RC is out, DO NOT MAKE ANY ABI-BREAKING CHANGES IN THAT SERIES
|
|
|
|
# UNLESS YOU REALLY REALLY HAVE TO.
|
2017-01-22 16:38:01 +03:00
|
|
|
VERSION_INFO = 6:1:0
|
2010-06-19 18:23:16 -04:00
|
|
|
|
|
|
|
# History: RELEASE VERSION_INFO
|
|
|
|
# 2.0.1-alpha -- 2.0 1:0:0
|
|
|
|
# 2.0.2-alpha -- 2:0:0
|
|
|
|
# 2.0.3-alpha -- 2:0:0 (should have incremented; didn't.)
|
|
|
|
# 2.0.4-alpha -- 3:0:0
|
|
|
|
# 2.0.5-beta -- 4:0:0
|
2010-09-09 14:59:27 -04:00
|
|
|
# 2.0.6-rc -- 2.0 2:0:0
|
2010-10-14 18:36:07 -04:00
|
|
|
# 2.0.7-rc -- 2.0 3:0:1
|
|
|
|
# 2.0.8-rc -- 2.0 4:0:2
|
2010-11-23 11:17:06 -05:00
|
|
|
# 2.0.9-rc -- 2.0 5:0:0 (ABI changed slightly)
|
2010-12-15 14:29:50 -05:00
|
|
|
# 2.0.10-stable-- 2.0 5:1:0 (No ABI change)
|
2011-06-03 17:08:14 -04:00
|
|
|
# 2.0.11-stable-- 2.0 6:0:1 (ABI changed, backward-compatible)
|
|
|
|
# 2.0.12-stable-- 2.0 6:1:1 (No ABI change)
|
2011-07-18 18:19:25 -04:00
|
|
|
# 2.0.13-stable-- 2.0 6:2:1 (No ABI change)
|
2011-08-30 22:28:02 -04:00
|
|
|
# 2.0.14-stable-- 2.0 6:3:1 (No ABI change)
|
2011-11-18 15:27:06 -05:00
|
|
|
# 2.0.15-stable-- 2.0 6:3:1 (Forgot to update :( )
|
|
|
|
# 2.0.16-stable-- 2.0 6:4:1 (No ABI change)
|
2012-02-10 16:49:05 -05:00
|
|
|
# 2.0.17-stable-- 2.0 6:5:1 (No ABI change)
|
2012-11-18 10:53:52 -05:00
|
|
|
# 2.0.18-stable-- 2.0 6:6:1 (No ABI change)
|
|
|
|
# 2.0.19-stable-- 2.0 6:7:1 (No ABI change)
|
|
|
|
# 2.0.20-stable-- 2.0 6:8:1 (No ABI change)
|
|
|
|
# 2.0.21-stable-- 2.0 6:9:1 (No ABI change)
|
2010-10-26 10:38:30 -04:00
|
|
|
#
|
|
|
|
# For Libevent 2.1:
|
2010-06-19 18:23:16 -04:00
|
|
|
# 2.1.1-alpha -- 2.1 1:0:0
|
2013-04-30 12:02:49 -04:00
|
|
|
# 2.1.2-alpha -- 2.1 1:0:0 (should have been 2:0:1)
|
|
|
|
# 2.1.3-alpha -- 2.1 3:0:0 (ABI changed slightly)
|
2014-03-16 12:09:24 -04:00
|
|
|
# 2.1.4-alpha -- 2.1 4:0:0 (ABI changed slightly)
|
2015-01-05 09:16:12 -05:00
|
|
|
# 2.1.5-beta -- 2.1 5:0:0 (ABI changed slightly)
|
2016-07-13 17:40:48 +03:00
|
|
|
# 2.1.6-beta -- 2.1 6:0:0 (ABI changed slightly)
|
2016-11-02 00:31:31 +03:00
|
|
|
# 2.1.7-beta -- 2.1 6:1:0 (ABI changed slightly)
|
2010-10-26 10:38:30 -04:00
|
|
|
|
2010-06-19 18:23:16 -04:00
|
|
|
# ABI version history for this package effectively restarts every time
|
|
|
|
# we change RELEASE. Version 1.4.x had RELEASE of 1.4.
|
2009-04-17 17:22:32 +00:00
|
|
|
#
|
2010-06-19 18:23:16 -04:00
|
|
|
# Ideally, we would not be using RELEASE at all; instead we could just
|
|
|
|
# use the VERSION_INFO field to label our backward-incompatible ABI
|
|
|
|
# changes, and those would be few and far between. Unfortunately,
|
|
|
|
# Libevent still exposes far too many volatile structures in its
|
|
|
|
# headers, so we pretty much have to assume that most development
|
|
|
|
# series will break ABI compatibility. For now, it's simplest just to
|
|
|
|
# keep incrementing the RELEASE between series and resetting VERSION_INFO.
|
2009-04-17 17:22:32 +00:00
|
|
|
#
|
2010-06-19 18:23:16 -04:00
|
|
|
# Eventually, when we get to the point where the structures in the
|
|
|
|
# headers are all non-changing (or not there at all!), we can shift to
|
|
|
|
# a more normal worldview where backward-incompatible ABI changes are
|
|
|
|
# nice and rare. For the next couple of years, though, 'struct event'
|
|
|
|
# is user-visible, and so we can pretty much guarantee that release
|
|
|
|
# series won't be binary-compatible.
|
2007-11-04 02:21:31 +00:00
|
|
|
|
2011-06-21 10:05:28 -04:00
|
|
|
if INSTALL_LIBEVENT
|
2010-03-22 13:27:47 -04:00
|
|
|
dist_bin_SCRIPTS = event_rpcgen.py
|
2011-06-21 10:05:28 -04:00
|
|
|
endif
|
2005-08-22 01:34:34 +00:00
|
|
|
|
2009-04-17 00:24:58 +00:00
|
|
|
pkgconfigdir=$(libdir)/pkgconfig
|
2016-04-20 07:31:25 +02:00
|
|
|
LIBEVENT_PKGCONFIG=libevent.pc libevent_core.pc libevent_extra.pc
|
2009-04-17 00:24:58 +00:00
|
|
|
|
2012-09-03 08:37:25 +02:00
|
|
|
# These sources are conditionally added by configure.ac or conditionally
|
2010-03-12 14:16:30 -05:00
|
|
|
# included from other files.
|
2010-03-12 13:22:47 -05:00
|
|
|
PLATFORM_DEPENDENT_SRC = \
|
2012-04-20 12:14:20 -04:00
|
|
|
arc4random.c \
|
|
|
|
epoll_sub.c
|
2010-03-12 13:22:47 -05:00
|
|
|
|
2009-01-13 19:20:14 +00:00
|
|
|
EXTRA_DIST = \
|
2012-04-20 12:14:20 -04:00
|
|
|
ChangeLog-1.4 \
|
|
|
|
ChangeLog-2.0 \
|
|
|
|
Doxyfile \
|
2010-01-19 13:55:53 -05:00
|
|
|
LICENSE \
|
2012-04-20 12:14:20 -04:00
|
|
|
Makefile.nmake test/Makefile.nmake \
|
2010-03-12 14:16:30 -05:00
|
|
|
autogen.sh \
|
2011-06-21 10:05:28 -04:00
|
|
|
event_rpcgen.py \
|
2010-03-01 22:06:12 -05:00
|
|
|
libevent.pc.in \
|
2012-04-27 09:32:51 -04:00
|
|
|
make-event-config.sed \
|
2009-04-17 06:56:23 +00:00
|
|
|
whatsnew-2.0.txt \
|
2012-03-22 18:11:01 -04:00
|
|
|
whatsnew-2.1.txt \
|
2010-03-12 13:22:47 -05:00
|
|
|
$(PLATFORM_DEPENDENT_SRC)
|
2002-04-09 17:02:38 +00:00
|
|
|
|
2011-02-13 02:05:04 -05:00
|
|
|
LIBEVENT_LIBS_LA = libevent.la libevent_core.la libevent_extra.la
|
2009-01-21 07:51:25 +00:00
|
|
|
if PTHREADS
|
2011-02-13 02:05:04 -05:00
|
|
|
LIBEVENT_LIBS_LA += libevent_pthreads.la
|
|
|
|
LIBEVENT_PKGCONFIG += libevent_pthreads.pc
|
2009-01-21 07:51:25 +00:00
|
|
|
endif
|
2009-07-28 04:03:57 +00:00
|
|
|
if OPENSSL
|
2011-02-13 02:05:04 -05:00
|
|
|
LIBEVENT_LIBS_LA += libevent_openssl.la
|
|
|
|
LIBEVENT_PKGCONFIG += libevent_openssl.pc
|
|
|
|
endif
|
|
|
|
|
|
|
|
if INSTALL_LIBEVENT
|
|
|
|
lib_LTLIBRARIES = $(LIBEVENT_LIBS_LA)
|
|
|
|
pkgconfig_DATA = $(LIBEVENT_PKGCONFIG)
|
|
|
|
else
|
|
|
|
noinst_LTLIBRARIES = $(LIBEVENT_LIBS_LA)
|
2009-07-28 04:03:57 +00:00
|
|
|
endif
|
2002-04-09 17:02:38 +00:00
|
|
|
|
2012-08-28 15:58:18 -04:00
|
|
|
EXTRA_SOURCE=
|
|
|
|
noinst_HEADERS=
|
|
|
|
noinst_PROGRAMS=
|
|
|
|
EXTRA_PROGRAMS=
|
|
|
|
CLEANFILES=
|
2013-02-08 22:10:05 -05:00
|
|
|
DISTCLEANFILES=
|
2012-08-28 15:58:18 -04:00
|
|
|
BUILT_SOURCES =
|
2012-08-28 16:01:14 -04:00
|
|
|
include include/include.am
|
|
|
|
include sample/include.am
|
|
|
|
include test/include.am
|
2007-12-06 19:35:55 +00:00
|
|
|
|
2006-09-27 03:07:38 +00:00
|
|
|
if BUILD_WIN32
|
|
|
|
|
2011-05-25 10:54:06 +02:00
|
|
|
SYS_LIBS = -lws2_32 -lshell32 -ladvapi32
|
2016-08-07 22:19:39 +03:00
|
|
|
SYS_SRC = win32select.c buffer_iocp.c event_iocp.c \
|
2009-05-05 16:52:37 +00:00
|
|
|
bufferevent_async.c
|
2014-01-21 19:19:30 +01:00
|
|
|
SYS_INCLUDES = -IWIN32-Code -IWIN32-Code/nmake
|
2006-09-27 03:07:38 +00:00
|
|
|
|
2016-08-07 22:19:39 +03:00
|
|
|
if THREADS
|
|
|
|
SYS_SRC += evthread_win32.c
|
|
|
|
endif
|
|
|
|
|
2006-09-27 03:07:38 +00:00
|
|
|
else
|
|
|
|
|
|
|
|
SYS_LIBS =
|
|
|
|
SYS_SRC =
|
|
|
|
SYS_INCLUDES =
|
|
|
|
|
|
|
|
endif
|
|
|
|
|
2013-03-31 14:05:26 -04:00
|
|
|
if STRLCPY_IMPL
|
|
|
|
SYS_SRC += strlcpy.c
|
|
|
|
endif
|
2010-03-12 14:16:30 -05:00
|
|
|
if SELECT_BACKEND
|
|
|
|
SYS_SRC += select.c
|
|
|
|
endif
|
|
|
|
if POLL_BACKEND
|
|
|
|
SYS_SRC += poll.c
|
|
|
|
endif
|
|
|
|
if DEVPOLL_BACKEND
|
|
|
|
SYS_SRC += devpoll.c
|
|
|
|
endif
|
|
|
|
if KQUEUE_BACKEND
|
|
|
|
SYS_SRC += kqueue.c
|
|
|
|
endif
|
|
|
|
if EPOLL_BACKEND
|
|
|
|
SYS_SRC += epoll.c
|
|
|
|
endif
|
|
|
|
if EVPORT_BACKEND
|
|
|
|
SYS_SRC += evport.c
|
|
|
|
endif
|
|
|
|
if SIGNAL_SUPPORT
|
|
|
|
SYS_SRC += signal.c
|
|
|
|
endif
|
|
|
|
|
2012-08-28 15:58:18 -04:00
|
|
|
BUILT_SOURCES += include/event2/event-config.h
|
2012-04-27 09:32:51 -04:00
|
|
|
|
|
|
|
include/event2/event-config.h: config.h make-event-config.sed
|
2012-08-28 16:07:56 -04:00
|
|
|
$(AM_V_GEN)test -d include/event2 || $(MKDIR_P) include/event2
|
|
|
|
$(AM_V_at)$(SED) -f $(srcdir)/make-event-config.sed < config.h > $@T
|
|
|
|
$(AM_V_at)mv -f $@T $@
|
2007-11-07 06:01:57 +00:00
|
|
|
|
2012-04-20 12:14:20 -04:00
|
|
|
CORE_SRC = \
|
|
|
|
buffer.c \
|
|
|
|
bufferevent.c \
|
|
|
|
bufferevent_filter.c \
|
|
|
|
bufferevent_pair.c \
|
|
|
|
bufferevent_ratelim.c \
|
|
|
|
bufferevent_sock.c \
|
|
|
|
event.c \
|
|
|
|
evmap.c \
|
|
|
|
evthread.c \
|
|
|
|
evutil.c \
|
|
|
|
evutil_rand.c \
|
2012-04-20 12:19:03 -04:00
|
|
|
evutil_time.c \
|
2012-04-20 12:14:20 -04:00
|
|
|
listener.c \
|
|
|
|
log.c \
|
|
|
|
$(SYS_SRC)
|
|
|
|
|
2012-08-28 15:58:18 -04:00
|
|
|
EXTRAS_SRC = \
|
2012-04-20 12:14:20 -04:00
|
|
|
evdns.c \
|
|
|
|
event_tagging.c \
|
|
|
|
evrpc.c \
|
|
|
|
http.c
|
2009-01-13 19:19:50 +00:00
|
|
|
|
2011-06-01 13:48:02 -04:00
|
|
|
if BUILD_WITH_NO_UNDEFINED
|
2010-05-06 14:37:23 -04:00
|
|
|
NO_UNDEFINED = -no-undefined
|
2010-05-06 14:37:23 -04:00
|
|
|
MAYBE_CORE = libevent_core.la
|
2010-05-06 14:37:23 -04:00
|
|
|
else
|
|
|
|
NO_UNDEFINED =
|
2010-06-23 01:15:15 +02:00
|
|
|
MAYBE_CORE =
|
2010-05-06 14:37:23 -04:00
|
|
|
endif
|
|
|
|
|
2010-06-19 18:22:48 -04:00
|
|
|
GENERIC_LDFLAGS = -version-info $(VERSION_INFO) $(RELEASE) $(NO_UNDEFINED)
|
|
|
|
|
2012-08-28 15:58:18 -04:00
|
|
|
libevent_la_SOURCES = $(CORE_SRC) $(EXTRAS_SRC)
|
2006-09-27 03:07:38 +00:00
|
|
|
libevent_la_LIBADD = @LTLIBOBJS@ $(SYS_LIBS)
|
2010-06-19 18:22:48 -04:00
|
|
|
libevent_la_LDFLAGS = $(GENERIC_LDFLAGS)
|
2002-04-09 17:02:38 +00:00
|
|
|
|
2007-11-03 23:45:38 +00:00
|
|
|
libevent_core_la_SOURCES = $(CORE_SRC)
|
|
|
|
libevent_core_la_LIBADD = @LTLIBOBJS@ $(SYS_LIBS)
|
2010-06-19 18:22:48 -04:00
|
|
|
libevent_core_la_LDFLAGS = $(GENERIC_LDFLAGS)
|
2007-11-03 23:45:38 +00:00
|
|
|
|
2009-01-21 07:51:25 +00:00
|
|
|
if PTHREADS
|
|
|
|
libevent_pthreads_la_SOURCES = evthread_pthread.c
|
2011-06-01 13:48:02 -04:00
|
|
|
libevent_pthreads_la_LIBADD = $(MAYBE_CORE)
|
2010-06-19 18:22:48 -04:00
|
|
|
libevent_pthreads_la_LDFLAGS = $(GENERIC_LDFLAGS)
|
2009-01-21 07:51:25 +00:00
|
|
|
endif
|
|
|
|
|
2012-08-28 15:58:18 -04:00
|
|
|
libevent_extra_la_SOURCES = $(EXTRAS_SRC)
|
2010-05-06 14:37:23 -04:00
|
|
|
libevent_extra_la_LIBADD = $(MAYBE_CORE) $(SYS_LIBS)
|
2010-06-19 18:22:48 -04:00
|
|
|
libevent_extra_la_LDFLAGS = $(GENERIC_LDFLAGS)
|
2007-11-03 23:45:38 +00:00
|
|
|
|
2009-07-28 04:03:57 +00:00
|
|
|
if OPENSSL
|
|
|
|
libevent_openssl_la_SOURCES = bufferevent_openssl.c
|
2011-05-05 15:49:38 +02:00
|
|
|
libevent_openssl_la_LIBADD = $(MAYBE_CORE) $(OPENSSL_LIBS)
|
2010-06-19 18:22:48 -04:00
|
|
|
libevent_openssl_la_LDFLAGS = $(GENERIC_LDFLAGS)
|
2011-08-30 09:38:18 -07:00
|
|
|
libevent_openssl_la_CPPFLAGS = $(AM_CPPFLAGS) $(OPENSSL_INCS)
|
2009-07-28 04:03:57 +00:00
|
|
|
endif
|
|
|
|
|
2012-08-28 15:58:18 -04:00
|
|
|
noinst_HEADERS += \
|
2014-01-21 19:19:30 +01:00
|
|
|
WIN32-Code/nmake/evconfig-private.h \
|
|
|
|
WIN32-Code/nmake/event2/event-config.h \
|
2012-04-20 12:14:20 -04:00
|
|
|
WIN32-Code/tree.h \
|
|
|
|
bufferevent-internal.h \
|
|
|
|
changelist-internal.h \
|
|
|
|
compat/sys/queue.h \
|
|
|
|
defer-internal.h \
|
2014-01-21 15:47:44 -05:00
|
|
|
epolltable-internal.h \
|
2012-04-20 12:14:20 -04:00
|
|
|
evbuffer-internal.h \
|
|
|
|
evconfig-private.h \
|
|
|
|
event-internal.h \
|
|
|
|
evmap-internal.h \
|
|
|
|
evrpc-internal.h \
|
|
|
|
evsignal-internal.h \
|
|
|
|
evthread-internal.h \
|
|
|
|
ht-internal.h \
|
|
|
|
http-internal.h \
|
|
|
|
iocp-internal.h \
|
|
|
|
ipv6-internal.h \
|
|
|
|
kqueue-internal.h \
|
|
|
|
log-internal.h \
|
|
|
|
minheap-internal.h \
|
|
|
|
mm-internal.h \
|
|
|
|
ratelim-internal.h \
|
|
|
|
ratelim-internal.h \
|
|
|
|
strlcpy-internal.h \
|
2012-04-20 12:27:12 -04:00
|
|
|
time-internal.h \
|
2012-04-20 12:14:20 -04:00
|
|
|
util-internal.h
|
2009-01-13 19:20:14 +00:00
|
|
|
|
2012-02-13 12:19:08 -05:00
|
|
|
EVENT1_HDRS = \
|
2012-04-20 12:14:20 -04:00
|
|
|
include/evdns.h \
|
2012-02-13 12:19:08 -05:00
|
|
|
include/event.h \
|
|
|
|
include/evhttp.h \
|
|
|
|
include/evrpc.h \
|
|
|
|
include/evutil.h
|
2009-05-15 01:38:23 +00:00
|
|
|
|
2011-03-03 12:57:17 -05:00
|
|
|
if INSTALL_LIBEVENT
|
|
|
|
include_HEADERS = $(EVENT1_HDRS)
|
|
|
|
else
|
|
|
|
noinst_HEADERS += $(EVENT1_HDRS)
|
|
|
|
endif
|
|
|
|
|
|
|
|
AM_CPPFLAGS = -I$(srcdir)/compat -I$(srcdir)/include -I./include $(SYS_INCLUDES)
|
2002-04-09 19:09:32 +00:00
|
|
|
|
2010-03-12 13:09:28 -05:00
|
|
|
verify: check
|
2004-12-01 19:59:00 +00:00
|
|
|
|
2007-09-18 15:16:23 +00:00
|
|
|
doxygen: FORCE
|
2007-09-18 15:12:09 +00:00
|
|
|
doxygen $(srcdir)/Doxyfile
|
2007-09-18 15:16:23 +00:00
|
|
|
FORCE:
|
2007-09-18 15:12:09 +00:00
|
|
|
|
2016-04-20 07:31:25 +02:00
|
|
|
DISTCLEANFILES += *~ libevent.pc libevent_core.pc libevent_extra.pc ./include/event2/event-config.h
|
2010-07-07 16:45:03 -04:00
|
|
|
|