source: branches/backfire/package/uhttpd/Makefile @ 21763

Last change on this file since 21763 was 21763, checked in by jow, 6 years ago

[backfire] merge r21492, r21556 and r21762

File size: 2.1 KB
Line 
1#
2# Copyright (C) 2010 Jo-Philipp Wich <xm@subsignal.org>
3#
4# This is free software, licensed under the GNU General Public License v2.
5# See /LICENSE for more information.
6#
7
8include $(TOPDIR)/rules.mk
9
10PKG_NAME:=uhttpd
11PKG_RELEASE:=11
12
13PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)
14
15include $(INCLUDE_DIR)/package.mk
16
17define Package/uhttpd/default
18  SECTION:=net
19  CATEGORY:=Network
20  TITLE:=uHTTPd - tiny, single threaded HTTP server
21endef
22
23define Package/uhttpd
24  $(Package/uhttpd/default)
25  MENU:=1
26endef
27
28define Package/uhttpd/description
29 uHTTPd is a tiny single threaded HTTP server with TLS, CGI and Lua
30 support. It is intended as a drop-in replacement for the Busybox
31 HTTP daemon.
32endef
33
34
35define Package/uhttpd-mod-tls
36  $(Package/uhttpd/default)
37  TITLE+= (TLS plugin)
38  DEPENDS:=uhttpd +libcyassl
39endef
40
41define Package/uhttpd-mod-tls/description
42 The TLS plugin adds HTTPS support to uHTTPd.
43endef
44
45
46define Package/uhttpd-mod-lua
47  $(Package/uhttpd/default)
48  TITLE+= (Lua plugin)
49  DEPENDS:=uhttpd +liblua
50endef
51
52define Package/uhttpd-mod-lua/description
53 The Lua plugin adds a CGI-like Lua runtime interface to uHTTPd.
54endef
55
56
57# hack to use CyASSL headers
58TARGET_CFLAGS += -I$(firstword $(wildcard $(BUILD_DIR)/cyassl-*/include))
59TARGET_LDFLAGS += -lm
60MAKE_VARS += FPIC="$(FPIC)"
61
62define Build/Prepare
63        mkdir -p $(PKG_BUILD_DIR)
64        $(CP) ./src/* $(PKG_BUILD_DIR)/
65endef
66
67define Package/uhttpd/conffiles
68/etc/config/uhttpd
69endef
70
71define Package/uhttpd/install
72        $(INSTALL_DIR) $(1)/etc/init.d
73        $(INSTALL_BIN) ./files/uhttpd.init $(1)/etc/init.d/uhttpd
74        $(INSTALL_DIR) $(1)/etc/config
75        $(INSTALL_CONF) ./files/uhttpd.config $(1)/etc/config/uhttpd
76        $(INSTALL_DIR) $(1)/usr/sbin
77        $(INSTALL_BIN) $(PKG_BUILD_DIR)/uhttpd $(1)/usr/sbin/uhttpd
78endef
79
80define Package/uhttpd-mod-tls/install
81        $(INSTALL_DIR) $(1)/usr/lib
82        $(INSTALL_BIN) $(PKG_BUILD_DIR)/uhttpd_tls.so $(1)/usr/lib/
83endef
84
85define Package/uhttpd-mod-lua/install
86        $(INSTALL_DIR) $(1)/usr/lib
87        $(INSTALL_BIN) $(PKG_BUILD_DIR)/uhttpd_lua.so $(1)/usr/lib/
88endef
89
90
91$(eval $(call BuildPackage,uhttpd))
92$(eval $(call BuildPackage,uhttpd-mod-tls))
93$(eval $(call BuildPackage,uhttpd-mod-lua))
Note: See TracBrowser for help on using the repository browser.