|
@@ -0,0 +1,67 @@
|
|
1
|
+#
|
|
2
|
+# Copyright (C) 2006-2014 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.14b
|
|
12
|
+PKG_RELEASE:=2
|
|
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:=https://github.com/downloads/libevent/libevent/
|
|
17
|
+PKG_MD5SUM:=a00e037e4d3f9e4fe9893e8a2d27918c
|
|
18
|
+PKG_MAINTAINER:=Steven Barth <cyrus@openwrt.org>
|
|
19
|
+
|
|
20
|
+PKG_FIXUP:=autoreconf
|
|
21
|
+PKG_INSTALL:=1
|
|
22
|
+PKG_BUILD_PARALLEL:=1
|
|
23
|
+
|
|
24
|
+include $(INCLUDE_DIR)/package.mk
|
|
25
|
+
|
|
26
|
+define Package/libevent
|
|
27
|
+ SECTION:=libs
|
|
28
|
+ CATEGORY:=Libraries
|
|
29
|
+ TITLE:=Event notification library
|
|
30
|
+ DEPENDS:=+librt
|
|
31
|
+ URL:=http://www.libevent.org
|
|
32
|
+endef
|
|
33
|
+
|
|
34
|
+define Package/libevent/description
|
|
35
|
+ The libevent API provides a mechanism to execute a callback function
|
|
36
|
+ when a specific event occurs on a file descriptor or after a timeout
|
|
37
|
+ has been reached. Furthermore, libevent also support callbacks due
|
|
38
|
+ to signals or regular timeouts.
|
|
39
|
+
|
|
40
|
+ libevent is meant to replace the event loop found in event driven
|
|
41
|
+ network servers. An application just needs to call event_dispatch()
|
|
42
|
+ and then add or remove events dynamically without having to change
|
|
43
|
+ the event loop.
|
|
44
|
+endef
|
|
45
|
+
|
|
46
|
+TARGET_CFLAGS += $(FPIC)
|
|
47
|
+
|
|
48
|
+CONFIGURE_ARGS += \
|
|
49
|
+ --enable-shared \
|
|
50
|
+ --enable-static \
|
|
51
|
+
|
|
52
|
+MAKE_FLAGS += \
|
|
53
|
+ CFLAGS="$(TARGET_CFLAGS)" \
|
|
54
|
+
|
|
55
|
+define Build/InstallDev
|
|
56
|
+ $(INSTALL_DIR) $(1)/usr/include/libevent
|
|
57
|
+ $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/libevent/
|
|
58
|
+ $(INSTALL_DIR) $(1)/usr/lib/libevent
|
|
59
|
+ $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.{a,so} $(1)/usr/lib/libevent/
|
|
60
|
+endef
|
|
61
|
+
|
|
62
|
+define Package/libevent/install
|
|
63
|
+ $(INSTALL_DIR) $(1)/usr/lib
|
|
64
|
+ $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so.* $(1)/usr/lib/
|
|
65
|
+endef
|
|
66
|
+
|
|
67
|
+$(eval $(call BuildPackage,libevent))
|