Fresh pull from upstream (stable) package feed
[librecmc/package-feed.git] / lang / lua-copas / Makefile
1 #
2 # Copyright (C) 2009-2013 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:=lua-copas
11 PKG_VERSION:=2.0.0
12 PKG_RELEASE:=1
13 PKG_MAINTAINER:=Dirk Chang <dirk@kooiot.com>
14 PKG_LICENSE:=MIT
15
16 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
17 PKG_SOURCE_URL:=https://github.com/keplerproject/copas.git
18 PKG_SOURCE_PROTO:=git
19 PKG_SOURCE_VERSION:=f39a80add9f7c010ac979297652bbaaea0360a27
20 PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
21
22 PKG_INSTALL:=1
23
24 include $(INCLUDE_DIR)/package.mk
25
26 define Package/lua-copas
27   SUBMENU:=Lua
28   SECTION:=lang
29   CATEGORY:=Languages
30   TITLE:=Lua-Copas
31   URL:=https://github.com/keplerproject/copas
32   DEPENDS:=+lua
33 endef
34
35 define Package/lua-copas/description
36   Copas is a dispatcher based on coroutines that can be used by TCP/IP servers.
37 endef
38
39 define Build/Configure
40 endef
41
42 define Build/Compile
43         $(MAKE) -C $(PKG_BUILD_DIR) \
44                 T="$(BUILD_VARIANT)" \
45                 PREFIX="$(PKG_INSTALL_DIR)/usr" \
46                 install
47 endef
48
49 # add make variable overrides here
50 MAKE_FLAGS +=
51
52 define Package/lua-copas/install
53         $(INSTALL_DIR) $(1)/usr/lib/lua
54         $(INSTALL_DIR) $(1)/usr/lib/lua/copas
55         $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/copas.lua $(1)/usr/lib/lua
56         $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/copas/ftp.lua $(1)/usr/lib/lua/copas
57         $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/copas/smtp.lua $(1)/usr/lib/lua/copas
58         $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/copas/http.lua $(1)/usr/lib/lua/copas
59         $(INSTALL_DATA) $(PKG_BUILD_DIR)/src/copas/limit.lua $(1)/usr/lib/lua/copas
60 endef
61
62 $(eval $(call BuildPackage,lua-copas))