[packages] libevent: update to v1.4.13 (#6468)
[openwrt/svn-archive/archive.git] / libs / libevent / Makefile
1 #
2 # Copyright (C) 2006-2010 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=libevent
11 PKG_VERSION:=1.4.13
12 PKG_RELEASE:=1
13
14 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)-stable
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-stable.tar.gz
16 PKG_SOURCE_URL:=http://www.monkey.org/~provos/
17 PKG_MD5SUM:=0b3ea18c634072d12b3c1ee734263664
18
19 PKG_INSTALL:=1
20
21 include $(INCLUDE_DIR)/package.mk
22
23 define Package/libevent
24 SECTION:=libs
25 CATEGORY:=Libraries
26 TITLE:=Event notification library
27 URL:=http://www.monkey.org/~provos/libevent/
28 endef
29
30 define Package/libevent/description
31 The libevent API provides a mechanism to execute a callback function
32 when a specific event occurs on a file descriptor or after a timeout
33 has been reached. Furthermore, libevent also support callbacks due
34 to signals or regular timeouts.
35
36 libevent is meant to replace the event loop found in event driven
37 network servers. An application just needs to call event_dispatch()
38 and then add or remove events dynamically without having to change
39 the event loop.
40 endef
41
42 TARGET_CFLAGS += $(FPIC)
43
44 Hooks/InstallDev/Post += libtool_fixup_libdir
45
46 CONFIGURE_ARGS += \
47 --enable-shared \
48 --enable-static \
49
50 MAKE_FLAGS += \
51 CFLAGS="$(TARGET_CFLAGS)" \
52
53 define Build/InstallDev
54 $(INSTALL_DIR) $(1)/usr/include
55 $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/
56 $(INSTALL_DIR) $(1)/usr/lib
57 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libevent.{la,a,so} $(1)/usr/lib/
58 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libevent-1.4.so* $(1)/usr/lib/
59 endef
60
61 define Package/libevent/install
62 $(INSTALL_DIR) $(1)/usr/lib
63 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libevent-1.4.so.* $(1)/usr/lib/
64 endef
65
66 $(eval $(call BuildPackage,libevent))