2 # Copyright (C) 2010-2013 Jo-Philipp Wich <jow@openwrt.org>
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
11 PKG_VERSION
:=2014-06-11
12 PKG_RELEASE
=$(PKG_SOURCE_VERSION
)
15 PKG_SOURCE_URL
:=git
://nbd.name
/uhttpd2.git
16 PKG_SOURCE_SUBDIR
:=$(PKG_NAME
)-$(PKG_VERSION
)
17 PKG_SOURCE_VERSION
:=dabd7dea6445aaa0e5b8d9add1872fa7393b3a85
18 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
)-$(PKG_SOURCE_VERSION
).
tar.gz
19 PKG_MAINTAINER
:=Felix Fietkau
<nbd@openwrt.org
>
21 PKG_BUILD_DEPENDS
= ustream-ssl
23 include $(INCLUDE_DIR
)/package.mk
24 include $(INCLUDE_DIR
)/cmake.mk
26 define Package
/uhttpd
/default
29 SUBMENU
:=Web Servers
/Proxies
30 TITLE
:=uHTTPd
- tiny
, single threaded HTTP server
34 $(Package
/uhttpd
/default
)
38 define Package
/uhttpd
/description
39 uHTTPd is a tiny single threaded HTTP server with TLS
, CGI and Lua
40 support. It is intended
as a drop-in replacement for the Busybox
44 define Package
/uhttpd
/config
45 config PACKAGE_uhttpd_debug
46 bool
"Build with debug messages"
51 define Package
/uhttpd-mod-tls
52 $(Package
/uhttpd
/default
)
55 +PACKAGE_uhttpd-mod-tls_polarssl
:libustream-polarssl \
56 +PACKAGE_uhttpd-mod-tls_cyassl
:libustream-cyassl \
57 +PACKAGE_uhttpd-mod-tls_openssl
:libustream-openssl
60 define Package
/uhttpd-mod-tls
/description
61 The TLS plugin adds HTTPS support to uHTTPd.
64 define Package
/uhttpd-mod-tls
/config
66 depends on PACKAGE_uhttpd-mod-tls
68 default PACKAGE_uhttpd-mod-tls_polarssl
70 config PACKAGE_uhttpd-mod-tls_polarssl
73 config PACKAGE_uhttpd-mod-tls_cyassl
76 config PACKAGE_uhttpd-mod-tls_openssl
81 define Package
/uhttpd-mod-lua
82 $(Package
/uhttpd
/default
)
84 DEPENDS
:=uhttpd
+liblua
87 define Package
/uhttpd-mod-lua
/description
88 The Lua plugin adds a CGI-like Lua runtime interface to uHTTPd.
92 define Package
/uhttpd-mod-ubus
93 $(Package
/uhttpd
/default
)
95 DEPENDS
:=uhttpd
+libubus
+libblobmsg-json
98 define Package
/uhttpd-mod-ubus
/description
99 The ubus plugin adds a HTTP
/JSON RPC proxy for ubus and publishes the
100 session.
* namespace and procedures.
103 define Package
/uhttpd
/conffiles
109 TARGET_LDFLAGS
+= -lcrypt
111 CMAKE_OPTIONS
= -DTLS_SUPPORT
=on
113 define Package
/uhttpd
/install
114 $(INSTALL_DIR
) $(1)/etc
/init.d
115 $(INSTALL_BIN
) .
/files
/uhttpd.init
$(1)/etc
/init.d
/uhttpd
116 $(INSTALL_DIR
) $(1)/etc
/config
117 $(INSTALL_CONF
) .
/files
/uhttpd.config
$(1)/etc
/config
/uhttpd
118 $(INSTALL_DIR
) $(1)/usr
/sbin
119 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/uhttpd
$(1)/usr
/sbin
/uhttpd
122 define Package
/uhttpd-mod-tls
/install
126 define Package
/uhttpd-mod-lua
/install
127 $(INSTALL_DIR
) $(1)/usr
/lib
128 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/uhttpd_lua.so
$(1)/usr
/lib
/
131 define Package
/uhttpd-mod-ubus
/install
132 $(INSTALL_DIR
) $(1)/usr
/lib
$(1)/etc
/uci-defaults
133 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/uhttpd_ubus.so
$(1)/usr
/lib
/
134 $(INSTALL_DATA
) .
/files
/ubus.default
$(1)/etc
/uci-defaults
/00_uhttpd_ubus
138 $(eval
$(call BuildPackage
,uhttpd
))
139 $(eval
$(call BuildPackage
,uhttpd-mod-tls
))
140 $(eval
$(call BuildPackage
,uhttpd-mod-lua
))
141 $(eval
$(call BuildPackage
,uhttpd-mod-ubus
))