2 # Copyright (C) 2007-2015 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
13 PKG_SOURCE_NAME
:=httpd
15 PKG_SOURCE
:=$(PKG_SOURCE_NAME
)-$(PKG_VERSION
).
tar.bz2
16 PKG_SOURCE_URL
:=@APACHE
/httpd
/
17 PKG_HASH
:=a497652ab3fc81318cdc2a203090a999150d86461acff97c1065dc910fe10f43
19 PKG_BUILD_DIR
:=$(BUILD_DIR
)/$(PKG_SOURCE_NAME
)-$(PKG_VERSION
)
21 PKG_MAINTAINER
:=Thomas Heil
<heil@terminal-consulting.de
>, \
22 Sebastian Kemper
<sebastian_ml@gmx.net
>
23 PKG_LICENSE
:=Apache-2.0
24 PKG_LICENSE_FILES
:=LICENSE
26 PKG_CPE_ID
:=cpe
:/a
:apache
:http_server
28 PKG_BUILD_DEPENDS
:=openssl
32 PKG_CONFIG_DEPENDS
:= \
33 CONFIG_PACKAGE_apache-mod-deflate \
34 CONFIG_PACKAGE_apache-mod-http2 \
35 CONFIG_PACKAGE_apache-mod-ldap \
36 CONFIG_PACKAGE_apache-mod-lua \
37 CONFIG_PACKAGE_apache-mod-md \
38 CONFIG_PACKAGE_apache-mod-proxy \
39 CONFIG_PACKAGE_apache-mod-proxy-html \
40 CONFIG_PACKAGE_apache-mod-session-crypto \
41 CONFIG_PACKAGE_apache-mod-suexec \
42 CONFIG_PACKAGE_apache-mod-webdav \
43 CONFIG_PACKAGE_apache-suexec
49 include $(INCLUDE_DIR
)/package.mk
50 # without nls.mk mod_xml2enc might not find the iconv headers
51 include $(INCLUDE_DIR
)/nls.mk
53 define Package
/apache
/Default
56 SUBMENU
:=Web Servers
/Proxies
57 TITLE
:=The Apache Web Server
58 URL
:=https
://httpd.apache.org
/
61 define Package
/apache
/Default
/description
62 The Apache HTTP Server Project is a collaborative software development
63 effort aimed at creating a robust
, commercial-grade
, featureful
, and
64 freely-available source code implementation of an HTTP
(Web
) server.
68 $(call Package
/apache
/Default
)
69 USERID
:=apache
=377:apache
=377
70 DEPENDS
:=+libapr
+libaprutil
+libpcre
73 define Package
/apache
/description
74 $(call Package
/apache
/Default
/description
)
76 This package contains the Apache web server and utility programs.
80 define Package
/apache
/conffiles
81 /etc
/apache2
/apache2.conf
82 /etc
/apache2
/extra
/httpd-autoindex.conf
83 /etc
/apache2
/extra
/httpd-dav.conf
84 /etc
/apache2
/extra
/httpd-default.conf
85 /etc
/apache2
/extra
/httpd-info.conf
86 /etc
/apache2
/extra
/httpd-languages.conf
87 /etc
/apache2
/extra
/httpd-manual.conf
88 /etc
/apache2
/extra
/httpd-mpm.conf
89 /etc
/apache2
/extra
/httpd-multilang-errordoc.conf
90 /etc
/apache2
/extra
/httpd-ssl.conf
91 /etc
/apache2
/extra
/httpd-userdir.conf
92 /etc
/apache2
/extra
/httpd-vhosts.conf
93 /etc
/apache2
/extra
/proxy-html.conf
95 /etc
/apache2
/mime.types
99 define Package
/apache-ab
100 $(call Package
/apache
/Default
)
101 TITLE
:=Apache benchmark utility
102 DEPENDS
:=apache
+libopenssl
105 define Package
/apache-ab
/description
106 $(call Package
/apache
/Default
/description
)
108 Apache server benchmarking utility.
112 define Package
/apache-error
113 $(call Package
/apache
/Default
)
114 TITLE
:=Error documents
118 define Package
/apache-error
/description
119 $(call Package
/apache
/Default
/description
)
121 Apache multi language custom error documents.
125 define Package
/apache-icons
126 $(call Package
/apache
/Default
)
127 TITLE
:=Icons from Apache
131 define Package
/apache-icons
/description
132 $(call Package
/apache
/Default
/description
)
134 This package contains the icons from Apache.
138 define Package
/apache-suexec
139 $(call Package
/apache
/Default
)
144 define Package
/apache-suexec
/description
145 $(call Package
/apache
/Default
/description
)
147 This package contains the suEXEC utility from Apache.
151 define Package
/apache-utils
152 $(call Package
/apache
/Default
)
153 TITLE
:=Apache utilities
157 define Package
/apache-utils
/description
158 $(call Package
/apache
/Default
/description
)
160 Apache utility programs for webservers.
164 define Package
/apache
/install/mod
165 $(INSTALL_DIR
) $(1)/usr
/lib
/apache2
167 $(PKG_INSTALL_DIR
)/usr
/lib
/apache2
/mod_
$(2).so \
172 --$(if
$(CONFIG_PACKAGE_apache-mod-http2
),en
,dis
)able-http2 \
173 --$(if
$(CONFIG_PACKAGE_apache-mod-lua
),en
,dis
)able-lua \
174 --$(if
$(CONFIG_PACKAGE_apache-mod-md
),en
,dis
)able-md \
175 --$(if
$(CONFIG_PACKAGE_apache-mod-proxy
),en
,dis
)able-proxy \
176 --$(if
$(CONFIG_PACKAGE_apache-mod-session-crypto
),en
,dis
)able-session-crypto \
177 --$(if
$(CONFIG_PACKAGE_apache-mod-ssl
),en
,dis
)able-ssl \
178 --datadir=/usr
/share
/apache2 \
181 --enable-authn-alias \
182 --enable-authn-anon \
187 --enable-disk-cache \
188 --enable-exception-hook \
189 --enable-file-cache \
190 --enable-layout
=OpenWrt \
192 --enable-mods-shared
=all \
193 --enable-mpms-shared
=all \
195 --libexecdir
=/usr
/lib
/apache2 \
196 --sysconfdir
=/etc
/apache2 \
197 --with-apr-util
="$(STAGING_DIR)/usr/bin/apu-1-config" \
198 --with-apr
="$(STAGING_DIR)/usr/bin/apr-1-config" \
200 --with-pcre
="$(STAGING_DIR)/usr/bin/pcre-config" \
201 --with-program-name
=apache2 \
204 ifneq ($(CONFIG_PACKAGE_apache-mod-deflate
),)
207 --with-z
="$(STAGING_DIR)/usr"
214 ifneq ($(CONFIG_PACKAGE_apache-mod-ldap
),)
216 --enable-authnz-ldap \
220 --disable-authnz-ldap \
224 ifneq ($(CONFIG_PACKAGE_apache-mod-proxy
),)
227 --enable-proxy-connect \
235 ifneq ($(CONFIG_PACKAGE_apache-mod-proxy-html
),)
237 --enable-proxy-html \
239 --with-libxml2
="$(STAGING_DIR)/usr"
242 --disable-proxy-html \
246 ifneq ($(CONFIG_PACKAGE_apache-mod-suexec
)$(CONFIG_PACKAGE_apache-suexec
),)
249 --with-suexec-bin
=/usr
/sbin
/suexec \
250 --with-suexec-caller
=apache \
251 --with-suexec-docroot
=/var
/www \
252 --with-suexec-logfile
=/var
/log
/apache2
/suexec.log \
253 --with-suexec-uidmin
=99 \
254 --with-suexec-gidmin
=99
260 ifneq ($(CONFIG_PACKAGE_apache-mod-webdav
),)
272 ap_cv_void_ptr_lt_long
=no
274 define Build
/InstallDev
275 $(INSTALL_DIR
) $(1)/usr
/bin
276 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/bin
/apxs
$(1)/usr
/bin
277 $(INSTALL_DIR
) $(1)/usr
/include/apache2
278 $(INSTALL_DATA
) $(PKG_INSTALL_DIR
)/usr
/include/apache2
/* \
279 $(1)/usr
/include/apache2
280 $(INSTALL_DIR
) $(1)/usr
/lib
/apache2
281 $(INSTALL_DIR
) $(1)/usr
/share
/apache2
/build
282 $(CP
) $(PKG_INSTALL_DIR
)/usr
/share
/apache2
/build
/* \
283 $(1)/usr
/share
/apache2
/build
284 $(SED
) 's%^prefix =.*%prefix = $(STAGING_DIR)/usr%' \
285 $(1)/usr
/share
/apache2
/build
/config_vars.mk
288 define Package
/apache
/install
289 $(INSTALL_DIR
) $(1)/etc
/apache2
/extra
290 $(INSTALL_DATA
) $(PKG_INSTALL_DIR
)/etc
/apache2
/extra
/* \
291 $(1)/etc
/apache2
/extra
292 $(SED
) '/^LoadModule session_crypto_module/s/^/#/' \
293 $(PKG_INSTALL_DIR
)/etc
/apache2
/apache2.conf
295 $(PKG_INSTALL_DIR
)/etc
/apache2
/{apache2.conf
,magic
,mime.types
} \
297 $(INSTALL_DIR
) $(1)/etc
/init.d
298 $(INSTALL_BIN
) .
/files
/apache2.init
$(1)/etc
/init.d
/apache2
299 $(INSTALL_DIR
) $(1)/usr
/lib
/apache2
300 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/lib
/apache2
/*.so \
302 rm -f
$(1)/usr
/lib
/apache2
/mod_
{*ldap
,dav
*,deflate
,http2
,lbmethod_
*,lua
,md
,proxy
*,proxy_html
,session_crypto
,ssl
,suexec
,xml2enc
}.so
303 $(INSTALL_DIR
) $(1)/usr
/share
/apache2
/{cgi-bin
,htdocs
}
304 $(INSTALL_DATA
) $(PKG_INSTALL_DIR
)/usr
/share
/apache2
/cgi-bin
/* \
305 $(1)/usr
/share
/apache2
/cgi-bin
306 $(INSTALL_DATA
) $(PKG_INSTALL_DIR
)/usr
/share
/apache2
/htdocs
/* \
307 $(1)/usr
/share
/apache2
/htdocs
308 $(INSTALL_DIR
) $(1)/usr
/{,s
}bin
310 $(PKG_INSTALL_DIR
)/usr
/bin
/{dbmmanage
,htdbm
,htdigest
,htpasswd
,httxt2dbm
,logresolve
} \
312 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/{apachectl
,apache2
} \
316 define Package
/apache-ab
/install
317 $(INSTALL_DIR
) $(1)/usr
/bin
318 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/bin
/ab
$(1)/usr
/bin
321 define Package
/apache-error
/install
322 $(INSTALL_DIR
) $(1)/usr
/share
/apache2
/error
323 $(CP
) $(PKG_INSTALL_DIR
)/usr
/share
/apache2
/error
/* \
324 $(1)/usr
/share
/apache2
/error
327 define Package
/apache-icons
/install
328 $(INSTALL_DIR
) $(1)/usr
/share
/apache2
329 $(CP
) $(PKG_INSTALL_DIR
)/usr
/share
/apache2
/icons \
330 $(1)/usr
/share
/apache2
333 define Package
/apache-suexec
/install
334 $(INSTALL_DIR
) $(1)/usr
/sbin
335 $(CP
) $(PKG_INSTALL_DIR
)/usr
/sbin
/suexec
$(1)/usr
/sbin
338 define Package
/apache-utils
/install
339 $(INSTALL_DIR
) $(1)/usr
/sbin
341 $(PKG_INSTALL_DIR
)/usr
/sbin
/{checkgid
,envvars
*,htcacheclean
,rotatelogs
} \
345 define Package
/apache
/Module
346 define Package
/apache-mod-
$(1)
347 $(call Package
/apache
/Default
)
349 DEPENDS
:=apache
$(patsubst +%,+PACKAGE_apache-mod-
$(1):%,$(4))
351 define Package
/apache-mod-
$(1)/description
352 $(subst \n,$(newline
),$(3))
354 define Package
/apache-mod-
$(1)/install
355 $(foreach m
,$(5),$(call Package
/apache
/install/mod
,$$(1),$(m
));)
357 $$(eval
$$(call BuildPackage
,apache-mod-
$(1)))
360 $(eval
$(call BuildPackage
,apache
))
361 $(eval
$(call BuildPackage
,apache-ab
))
362 $(eval
$(call BuildPackage
,apache-error
))
363 $(eval
$(call BuildPackage
,apache-icons
))
364 $(eval
$(call BuildPackage
,apache-suexec
))
365 $(eval
$(call BuildPackage
,apache-utils
))
366 $(eval
$(call Package
/apache
/Module
,deflate
,Deflate
,Deflate support for the Apache HTTP server.
,+zlib
,deflate
))
367 $(eval
$(call Package
/apache
/Module
,http2
,HTTP2
,HTTP
/2 transport layer for the Apache HTTP Server.
,+libnghttp2
+libopenssl
,http2
))
368 $(eval
$(call Package
/apache
/Module
,ldap
,LDAP
,LDAP authentication
/authorization module for the Apache HTTP Server.
,+libaprutil-ldap
,authnz_ldap ldap
))
369 $(eval
$(call Package
/apache
/Module
,lua
,Lua
,Lua support for the Apache HTTP server.
,+liblua
,lua
))
370 $(eval
$(call Package
/apache
/Module
,md
,Managed Domain handling
,Managed Domain handling.
,+libcurl
+jansson
+libopenssl
,md
))
371 $(eval
$(call Package
/apache
/Module
,proxy
,Proxy
,Proxy modules for the Apache HTTP Server.
,,proxy proxy_ajp proxy_balancer proxy_connect proxy_express proxy_fcgi proxy_fdpass proxy_ftp proxy_hcheck proxy_http proxy_scgi proxy_uwsgi proxy_wstunnel lbmethod_byrequests lbmethod_heartbeat lbmethod_bytraffic lbmethod_bybusyness
))
372 $(eval
$(call Package
/apache
/Module
,proxy-html
,Proxy HTML
,HTML and XML content filters for the Apache HTTP Server.
,+apache-mod-proxy
+libxml2
,proxy_html xml2enc
))
373 $(eval
$(call Package
/apache
/Module
,session-crypto
,Session crypto
,Session encryption support for the Apache HTTP Server.
,+libaprutil-crypto-openssl
,session_crypto
))
374 $(eval
$(call Package
/apache
/Module
,ssl
,SSL
/TLS
,SSL
/TLS module for the Apache HTTP Server.
,+libopenssl
,ssl
))
375 $(eval
$(call Package
/apache
/Module
,suexec
,suEXEC
,suEXEC module for the Apache HTTP Server.
,+apache-suexec
,suexec
))
376 $(eval
$(call Package
/apache
/Module
,webdav
,WebDAV
,WebDAV support for the Apache HTTP Server.
,,dav dav_fs dav_lock
))