# Buildsheet autogenerated by ravenadm tool -- Do not edit.
NAMEBASE= apache
VERSION= 2.4.62
KEYWORDS= www
VARIANTS= std
SDESC[std]= Secure, efficient and extensible HTTP server
HOMEPAGE= https://httpd.apache.org/
CONTACT= nobody
DOWNLOAD_GROUPS= main
SITES[main]= APACHE_HTTPD/
DISTFILE[1]= httpd-2.4.62.tar.bz2:main
DF_INDEX= 1
SPKGS[std]= set
primary
dev
man
docs
OPTIONS_AVAILABLE= MPM_PREFORK MPM_WORKER MPM_EVENT
OPTIONS_STANDARD= MPM_PREFORK MPM_WORKER MPM_EVENT
OPTGROUP_RADIO= MPM
OPTDESCR[MPM]= Default Multi-Processing Module (MPM)
OPTGROUP[MPM]= MPM_PREFORK MPM_WORKER MPM_EVENT
OPT_ON[freebsd]= MPM_EVENT
OPT_ON[sunos]= MPM_WORKER
OPT_ON[linux]= MPM_EVENT
OPT_ON[darwin]= MPM_EVENT
OPT_ON[netbsd]= MPM_EVENT
OPT_ON[dragonfly]= MPM_EVENT
OPT_ON[midnightbsd]= MPM_EVENT
BUILD_DEPENDS= apr1:dev:std
apr-util:dev:std
libnghttp2:dev:std
gdbm:dev:std
BUILDRUN_DEPENDS= apr1:primary:std
apr-util:primary:std
libnghttp2:primary:std
gdbm:primary:std
USERS= wwwraven
GROUPS= wwwraven
USERGROUP_SPKG= primary
USES= autoreconf cpe iconv libtool ssl perl:run zlib expat
pcre bdb
GNOME_COMPONENTS= libxml2
DISTNAME= httpd-2.4.62
LICENSE= APACHE20:primary
LICENSE_TERMS= primary:{{WRKDIR}}/TERMS
LICENSE_FILE= APACHE20:{{WRKSRC}}/LICENSE
LICENSE_AWK= TERMS:"^$$"
LICENSE_SOURCE= TERMS:{{WRKSRC}}/include/httpd.h
LICENSE_SCHEME= solo
CPE_PRODUCT= http_server
CPE_VENDOR= apache
FPC_EQUIVALENT= www/apache24
MUST_CONFIGURE= gnu
CONFIGURE_ARGS= --enable-http
--enable-layout=Ravenports
--with-pcre={{LOCALBASE}}
--with-apr={{LOCALBASE}}/bin/apr-1-config
--with-apr-util={{LOCALBASE}}/bin/apu-1-config
--with-nghttp2={{LOCALBASE}}
--with-libxml2={{LOCALBASE}}
--with-ssl={{OPENSSLBASE}}
--with-z={{LOCALBASE}}
--enable-mpms-shared=all
--enable-access-compat=shared
--enable-actions=shared
--enable-alias=shared
--enable-allowmethods=shared
--enable-asis=shared
--enable-authn-anon=shared
--enable-authn-core=shared
--enable-authn-dbd=shared
--enable-authn-dbm=shared
--enable-authn-file=shared
--enable-authn-socache=shared
--enable-authz-core=shared
--enable-authz-dbd=shared
--enable-authz-dbm=shared
--enable-authnz-fcgi=shared
--enable-authz-groupfile=shared
--enable-authz-host=shared
--enable-authz-owner=shared
--enable-authz-user=shared
--enable-auth-basic=shared
--enable-auth-digest=shared
--enable-auth-form=shared
--enable-autoindex=shared
--enable-buffer=shared
--enable-cache=shared
--enable-cache-disk=shared
--enable-cache-socache=shared
--enable-cern-meta=shared
--enable-cgi=shared
--enable-cgid=shared
--enable-charset-lite=shared
--enable-data=shared
--enable-dav=shared
--enable-dav-fs=shared
--enable-dav-lock=shared
--enable-dbd=shared
--enable-deflate=shared
--enable-dialup=shared
--enable-dir=shared
--enable-dumpio=shared
--enable-env=shared
--enable-expires=shared
--enable-ext-filter=shared
--enable-file-cache=shared
--enable-filter=shared
--enable-headers=shared
--enable-heartbeat=shared
--enable-heartmonitor=shared
--enable-http2=shared
--enable-imagemap=shared
--enable-include=shared
--enable-info=shared
--enable-lbmethod-bybusyness=shared
--enable-lbmethod-byrequests=shared
--enable-lbmethod-bytraffic=shared
--enable-lbmethod-heartbeat=shared
--enable-logio=shared
--enable-log-debug=shared
--enable-log-forensic=shared
--enable-macro=shared
--enable-mime=shared
--enable-mime-magic=shared
--enable-negotiation=shared
--enable-ratelimit=shared
--enable-reflector=shared
--enable-remoteip=shared
--enable-reqtimeout=shared
--enable-request=shared
--enable-rewrite=shared
--enable-sed=shared
--enable-setenvif=shared
--enable-slotmem-plain=shared
--enable-slotmem-shm=shared
--enable-socache-dbm=shared
--enable-socache-memcache=shared
--enable-socache-shmcb=shared
--enable-speling=shared
--enable-ssl=shared
--enable-status=shared
--enable-substitute=shared
--enable-unique-id=shared
--enable-userdir=shared
--enable-usertrack=shared
--enable-version=shared
--enable-vhost-alias=shared
--enable-watchdog=shared
--enable-xml2enc=shared
--enable-session=shared
--enable-session-cookie=shared
--enable-session-crypto=shared
--enable-session-dbd=shared
--enable-proxy=shared
--enable-proxy-ajp=shared
--enable-proxy-balancer=shared
--enable-proxy-connect=shared
--enable-proxy-express=shared
--enable-proxy-fcgi=shared
--enable-proxy-http2=shared
--enable-proxy-ftp=shared
--enable-proxy-hcheck=shared
--enable-proxy-html=shared
--enable-proxy-http=shared
--enable-proxy-scgi=shared
--enable-proxy-uwsgi=shared
--enable-proxy-wstunnel=shared
--disable-authnz-ldap
--disable-brotli
--disable-ident
--disable-ldap
--disable-lua
--disable-md
--disable-socache-dc
--disable-suexec
--disable-bucketeer
--disable-case-filter
--disable-case-filter-in
--disable-echo
--disable-example-hooks
--disable-example-ipc
--disable-optional-fn-export
--disable-optional-fn-import
--disable-optional-hook-export
--disable-optional-hook-import
CONFIGURE_ENV= LOCALBASE="{{LOCALBASE}}"
CONFIG_SHELL="{{SH}}"
MAKE_ENV= EXPR_COMPAT="yes"
INSTALL_MAN="{{INSTALL_MAN}}"
RC_SUBR= apache:primary
VAR_OPSYS[freebsd]= CONFIGURE_ARGS=--enable-proxy-fdpass=shared
VAR_OPSYS[linux]= CONFIGURE_ARGS=--enable-proxy-fdpass=shared
VAR_OPSYS[dragonfly]= CONFIGURE_ARGS=--enable-proxy-fdpass=shared
VAR_OPSYS[midnightbsd]= CONFIGURE_ARGS=--enable-proxy-fdpass=shared
[MPM_WORKER].DESCRIPTION= Build multi-threaded, multi-process web server
[MPM_WORKER].CONFIGURE_ARGS_ON= --with-mpm=worker
[MPM_EVENT].DESCRIPTION= Build thread-safe polling web server
[MPM_EVENT].CONFIGURE_ARGS_ON= --with-mpm=event
[MPM_PREFORK].DESCRIPTION= Build non-threaded, pre-forking web server
[MPM_PREFORK].CONFIGURE_ARGS_ON= --with-mpm=prefork
post-install:
${FIND} ${STAGEDIR}${STD_DOCDIR} -type d -empty -delete
${FIND} ${STAGEDIR}/var -type d -empty -delete
${STRIP_CMD} ${STAGEDIR}${PREFIX}/libexec/apache/*.so
.for binary in ab htdbm htdigest htpasswd httxt2dbm logresolve
${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/${binary}
.endfor
.for binary in checkgid fcgistarter htcacheclean httpd rotatelogs
${STRIP_CMD} ${STAGEDIR}${PREFIX}/sbin/${binary}
.endfor
[FILE:403:descriptions/desc.primary]
The Apache HTTP Server is a powerful and flexible HTTP/1.1 compliant web
server. Originally designed as a replacement for the NCSA HTTP Server, it
has grown to be the most popular web server on the Internet. As a project
of the Apache Software Foundation, the developers aim to collaboratively
develop and maintain a robust, commercial-grade, standards-based server
with freely available source code.
[FILE:99:distinfo]
674188e7bf44ced82da8db522da946849e22080d73d16c93f7f4df89e25729ec 7521661 httpd-2.4.62.tar.bz2
[FILE:6800:manifests/plist.primary]
%%ONLY-DRAGONFLY%%libexec/apache/mod_proxy_fdpass.so
%%ONLY-FREEBSD%%libexec/apache/mod_proxy_fdpass.so
%%ONLY-LINUX%%libexec/apache/mod_proxy_fdpass.so
%%ONLY-MIDNIGHTBSD%%libexec/apache/mod_proxy_fdpass.so
%%ONLY-NETBSD%%libexec/apache/mod_proxy_fdpass.so
bin/
ab
apxs
dbmmanage
htdbm
htdigest
htpasswd
httxt2dbm
logresolve
etc/apache/
httpd.conf
magic
mime.types
etc/apache/extra/
httpd-autoindex.conf
httpd-dav.conf
httpd-default.conf
httpd-info.conf
httpd-languages.conf
httpd-manual.conf
httpd-mpm.conf
httpd-multilang-errordoc.conf
httpd-ssl.conf
httpd-userdir.conf
httpd-vhosts.conf
proxy-html.conf
etc/apache/original/httpd.conf
etc/apache/original/extra/
httpd-autoindex.conf
httpd-dav.conf
httpd-default.conf
httpd-info.conf
httpd-languages.conf
httpd-manual.conf
httpd-mpm.conf
httpd-multilang-errordoc.conf
httpd-ssl.conf
httpd-userdir.conf
httpd-vhosts.conf
proxy-html.conf
libexec/apache/
httpd.exp
mod_access_compat.so
mod_actions.so
mod_alias.so
mod_allowmethods.so
mod_asis.so
mod_auth_basic.so
mod_auth_digest.so
mod_auth_form.so
mod_authn_anon.so
mod_authn_core.so
mod_authn_dbd.so
mod_authn_dbm.so
mod_authn_file.so
mod_authn_socache.so
mod_authnz_fcgi.so
mod_authz_core.so
mod_authz_dbd.so
mod_authz_dbm.so
mod_authz_groupfile.so
mod_authz_host.so
mod_authz_owner.so
mod_authz_user.so
mod_autoindex.so
mod_buffer.so
mod_cache.so
mod_cache_disk.so
mod_cache_socache.so
mod_cern_meta.so
mod_cgi.so
mod_cgid.so
mod_charset_lite.so
mod_data.so
mod_dav.so
mod_dav_fs.so
mod_dav_lock.so
mod_dbd.so
mod_deflate.so
mod_dialup.so
mod_dir.so
mod_dumpio.so
mod_env.so
mod_expires.so
mod_ext_filter.so
mod_file_cache.so
mod_filter.so
mod_headers.so
mod_heartbeat.so
mod_heartmonitor.so
mod_http2.so
mod_imagemap.so
mod_include.so
mod_info.so
mod_lbmethod_bybusyness.so
mod_lbmethod_byrequests.so
mod_lbmethod_bytraffic.so
mod_lbmethod_heartbeat.so
mod_log_config.so
mod_log_debug.so
mod_log_forensic.so
mod_logio.so
mod_macro.so
mod_mime.so
mod_mime_magic.so
mod_mpm_event.so
mod_mpm_prefork.so
mod_mpm_worker.so
mod_negotiation.so
mod_proxy.so
mod_proxy_ajp.so
mod_proxy_balancer.so
mod_proxy_connect.so
mod_proxy_express.so
mod_proxy_fcgi.so
mod_proxy_ftp.so
mod_proxy_hcheck.so
mod_proxy_html.so
mod_proxy_http.so
mod_proxy_http2.so
mod_proxy_scgi.so
mod_proxy_uwsgi.so
mod_proxy_wstunnel.so
mod_ratelimit.so
mod_reflector.so
mod_remoteip.so
mod_reqtimeout.so
mod_request.so
mod_rewrite.so
mod_sed.so
mod_session.so
mod_session_cookie.so
mod_session_crypto.so
mod_session_dbd.so
mod_setenvif.so
mod_slotmem_plain.so
mod_slotmem_shm.so
mod_socache_dbm.so
mod_socache_memcache.so
mod_socache_redis.so
mod_socache_shmcb.so
mod_speling.so
mod_ssl.so
mod_status.so
mod_substitute.so
mod_unique_id.so
mod_unixd.so
mod_userdir.so
mod_usertrack.so
mod_version.so
mod_vhost_alias.so
mod_watchdog.so
mod_xml2enc.so
sbin/
apachectl
checkgid
envvars
envvars-std
fcgistarter
htcacheclean
httpd
rotatelogs
www/apache/build/
config.nice
config_vars.mk
instdso.sh
library.mk
ltlib.mk
mkdir.sh
program.mk
rules.mk
special.mk
www/apache/cgi-bin/
printenv
printenv.vbs
printenv.wsf
test-cgi
www/apache/data/index.html
www/apache/error/
HTTP_BAD_GATEWAY.html.var
HTTP_BAD_REQUEST.html.var
HTTP_FORBIDDEN.html.var
HTTP_GONE.html.var
HTTP_INTERNAL_SERVER_ERROR.html.var
HTTP_LENGTH_REQUIRED.html.var
HTTP_METHOD_NOT_ALLOWED.html.var
HTTP_NOT_FOUND.html.var
HTTP_NOT_IMPLEMENTED.html.var
HTTP_PRECONDITION_FAILED.html.var
HTTP_REQUEST_ENTITY_TOO_LARGE.html.var
HTTP_REQUEST_TIME_OUT.html.var
HTTP_REQUEST_URI_TOO_LARGE.html.var
HTTP_SERVICE_UNAVAILABLE.html.var
HTTP_UNAUTHORIZED.html.var
HTTP_UNSUPPORTED_MEDIA_TYPE.html.var
HTTP_VARIANT_ALSO_VARIES.html.var
README
contact.html.var
www/apache/error/include/
bottom.html
spacer.html
top.html
www/apache/icons/
README
README.html
a.gif
a.png
alert.black.gif
alert.black.png
alert.red.gif
alert.red.png
apache_pb.gif
apache_pb.png
apache_pb.svg
apache_pb2.gif
apache_pb2.png
back.gif
back.png
ball.gray.gif
ball.gray.png
ball.red.gif
ball.red.png
binary.gif
binary.png
binhex.gif
binhex.png
blank.gif
blank.png
bomb.gif
bomb.png
box1.gif
box1.png
box2.gif
box2.png
broken.gif
broken.png
burst.gif
burst.png
c.gif
c.png
comp.blue.gif
comp.blue.png
comp.gray.gif
comp.gray.png
compressed.gif
compressed.png
continued.gif
continued.png
dir.gif
dir.png
diskimg.gif
diskimg.png
down.gif
down.png
dvi.gif
dvi.png
f.gif
f.png
folder.gif
folder.open.gif
folder.open.png
folder.png
folder.sec.gif
folder.sec.png
forward.gif
forward.png
generic.gif
generic.png
generic.red.gif
generic.red.png
generic.sec.gif
generic.sec.png
hand.right.gif
hand.right.png
hand.up.gif
hand.up.png
icon.sheet.gif
icon.sheet.png
image1.gif
image1.png
image2.gif
image2.png
image3.gif
image3.png
index.gif
index.png
layout.gif
layout.png
left.gif
left.png
link.gif
link.png
movie.gif
movie.png
odf6odb.png
odf6odc.png
odf6odf.png
odf6odg.png
odf6odi.png
odf6odm.png
odf6odp.png
odf6ods.png
odf6odt.png
odf6otc.png
odf6otf.png
odf6otg.png
odf6oth.png
odf6oti.png
odf6otp.png
odf6ots.png
odf6ott.png
p.gif
p.png
patch.gif
patch.png
pdf.gif
pdf.png
pie0.gif
pie0.png
pie1.gif
pie1.png
pie2.gif
pie2.png
pie3.gif
pie3.png
pie4.gif
pie4.png
pie5.gif
pie5.png
pie6.gif
pie6.png
pie7.gif
pie7.png
pie8.gif
pie8.png
portal.gif
portal.png
ps.gif
ps.png
quill.gif
quill.png
right.gif
right.png
screw1.gif
screw1.png
screw2.gif
screw2.png
script.gif
script.png
sound1.gif
sound1.png
sound2.gif
sound2.png
sphere1.gif
sphere1.png
sphere2.gif
sphere2.png
svg.png
tar.gif
tar.png
tex.gif
tex.png
text.gif
text.png
transfer.gif
transfer.png
unknown.gif
unknown.png
up.gif
up.png
uu.gif
uu.png
uuencoded.gif
uuencoded.png
world1.gif
world1.png
world2.gif
world2.png
xml.png
www/apache/icons/small/
back.gif
back.png
binary.gif
binary.png
binhex.gif
binhex.png
blank.gif
blank.png
broken.gif
broken.png
burst.gif
burst.png
comp1.gif
comp1.png
comp2.gif
comp2.png
compressed.gif
compressed.png
continued.gif
continued.png
doc.gif
doc.png
folder.gif
folder.png
folder2.gif
folder2.png
forward.gif
forward.png
generic.gif
generic.png
generic2.gif
generic2.png
generic3.gif
generic3.png
image.gif
image.png
image2.gif
image2.png
index.gif
index.png
key.gif
key.png
movie.gif
movie.png
patch.gif
patch.png
ps.gif
ps.png
rainbow.gif
rainbow.png
sound.gif
sound.png
sound2.gif
sound2.png
tar.gif
tar.png
text.gif
text.png
transfer.gif
transfer.png
unknown.gif
unknown.png
uu.gif
uu.png
[FILE:906:manifests/plist.dev]
include/apache/
ap_compat.h
ap_config.h
ap_config_auto.h
ap_config_layout.h
ap_expr.h
ap_hooks.h
ap_listen.h
ap_mmn.h
ap_mpm.h
ap_provider.h
ap_regex.h
ap_regkey.h
ap_release.h
ap_slotmem.h
ap_socache.h
apache_noprobes.h
cache_common.h
heartbeat.h
http_config.h
http_connection.h
http_core.h
http_log.h
http_main.h
http_protocol.h
http_request.h
http_ssl.h
http_vhost.h
httpd.h
mod_auth.h
mod_cache.h
mod_cgi.h
mod_core.h
mod_dav.h
mod_dbd.h
mod_http2.h
mod_include.h
mod_log_config.h
mod_proxy.h
mod_request.h
mod_rewrite.h
mod_session.h
mod_so.h
mod_ssl.h
mod_ssl_openssl.h
mod_status.h
mod_unixd.h
mod_watchdog.h
mod_xml2enc.h
mpm_common.h
os.h
scoreboard.h
unixd.h
util_cfgtree.h
util_charset.h
util_cookies.h
util_ebcdic.h
util_fcgi.h
util_filter.h
util_ldap.h
util_md5.h
util_mutex.h
util_script.h
util_time.h
util_varbuf.h
util_xml.h
[FILE:196:manifests/plist.man]
share/man/man1/
ab.1
apxs.1
dbmmanage.1
htdbm.1
htdigest.1
htpasswd.1
httxt2dbm.1
logresolve.1
share/man/man8/
apachectl.8
fcgistarter.8
htcacheclean.8
httpd.8
rotatelogs.8
suexec.8
[FILE:986:patches/patch-config.layout]
--- config.layout.orig 2020-02-21 00:39:22 UTC
+++ config.layout
@@ -298,6 +298,30 @@
proxycachedir: ${datadir}/proxy
+# Ravenports Layout
+
+ prefix: /raven
+ localstatedir: /var/rav-apache
+ exec_prefix: ${prefix}
+ bindir: ${exec_prefix}/bin
+ sbindir: ${exec_prefix}/sbin
+ libdir: ${exec_prefix}/lib
+ libexecdir: ${exec_prefix}/libexec/apache
+ mandir: ${prefix}/share/man
+ sysconfdir: ${prefix}/etc/apache
+ datadir: ${prefix}/www/apache
+ installbuilddir: ${datadir}/build
+ errordir: ${datadir}/error
+ iconsdir: ${datadir}/icons
+ htdocsdir: ${datadir}/data
+ cgidir: ${datadir}/cgi-bin
+ manualdir: ${prefix}/share/doc/apache
+ includedir: ${prefix}/include/apache
+ runtimedir: ${localstatedir}/run
+ logfiledir: ${localstatedir}/log
+ proxycachedir: ${datadir}/proxy
+
+
# Debian layout
prefix:
[FILE:611:patches/patch-modules_generators_config5.m4]
--- modules/generators/config5.m4.orig 2024-06-17 08:11:10 UTC
+++ modules/generators/config5.m4
@@ -51,8 +51,7 @@ if test $cgid_needed = "yes"; then
;;
esac
AC_MSG_CHECKING([for Solaris patch $patch_id])
- showrev -p | grep "$patch_id" >/dev/null 2>&1
- if test $? -eq 1; then
+ if test 0 -eq 1; then
dnl Solaris 11 (next release) as of snv_19 doesn't have this problem.
dnl It may be possible to use /kernel/drv/tl from later releases.
AC_MSG_ERROR([Please apply either patch # 120664 (Sparc) or # 120665 (x86).
[FILE:443:patches/patch-modules_ssl_ssl__engine__init.c]
--- modules/ssl/ssl_engine_init.c.orig 2024-06-21 14:28:25 UTC
+++ modules/ssl/ssl_engine_init.c
@@ -617,7 +617,7 @@ static apr_status_t ssl_init_ctx_protoco
char *cp;
int protocol = mctx->protocol;
SSLSrvConfigRec *sc = mySrvConfig(s);
-#if OPENSSL_VERSION_NUMBER >= 0x10100000L
+#if OPENSSL_VERSION_NUMBER >= 0x10100000L && !(defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER < 0x20700000L)
int prot;
#endif
[FILE:393:patches/patch-modules_ssl_ssl__private.h]
--- modules/ssl/ssl_private.h.orig 2024-06-21 14:28:25 UTC
+++ modules/ssl/ssl_private.h
@@ -136,7 +136,7 @@
#define MODSSL_SSL_METHOD_CONST
#endif
-#if defined(LIBRESSL_VERSION_NUMBER)
+#if defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER < 0x20700000L
/* Missing from LibreSSL */
#if LIBRESSL_VERSION_NUMBER < 0x2060000f
#define SSL_CTRL_SET_MIN_PROTO_VERSION 123
[FILE:594:patches/patch-modules_ssl_ssl__util__stapling.c]
--- modules/ssl/ssl_util_stapling.c.orig 2023-11-18 11:34:12 UTC
+++ modules/ssl/ssl_util_stapling.c
@@ -107,7 +107,7 @@ static X509 *stapling_get_issuer(modssl_
for (i = 0; i < sk_X509_num(extra_certs); i++) {
issuer = sk_X509_value(extra_certs, i);
if (X509_check_issued(issuer, x) == X509_V_OK) {
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if OPENSSL_VERSION_NUMBER < 0x10100000L || (defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER < 0x2050000fL)
CRYPTO_add(&issuer->references, 1, CRYPTO_LOCK_X509);
#else
X509_up_ref(issuer);
[FILE:5912:files/apache.in]
#!/bin/sh
# PROVIDE: apache
# REQUIRE: LOGIN cleanvar sshd
# KEYWORD: shutdown
#
# Add the following lines to /etc/rc.conf to enable apache:
# apache_enable (bool): Set to "NO" by default.
# Set it to "YES" to enable apache
# apache_profiles (str): Set to "" by default.
# Define your profiles here.
# apachelimits_enable (bool):Set to "NO" by default.
# Set it to yes to run `limits $limits_args`
# just before apache starts.
# apache_flags (str): Set to "" by default.
# Extra flags passed to start command.
# apachelimits_args (str): Default to "-e -C daemon"
# Arguments of pre-start limits run.
# apache_http_accept_enable (bool): Set to "NO" by default.
# Set to yes to check for accf_http kernel
# module on start up and load if not loaded.
# apache_fib (str): Set an altered default network view for apache
# apache_configcheck_disable (bool): Set to "YES" to disable sanity check on startup
. /etc/rc.subr
name="apache"
rcvar=apache_enable
start_precmd="apache_prestart"
restart_precmd="apache_checkconfig"
reload_precmd="apache_checkconfig"
reload_cmd="apache_graceful"
graceful_cmd="apache_graceful"
gracefulstop_cmd="apache_gracefulstop"
configtest_cmd="apache_checkconfig"
command="%%PREFIX%%/sbin/httpd"
_pidprefix="/var/run/httpd"
pidfile="${_pidprefix}.pid"
required_files=%%PREFIX%%/etc/apache/httpd.conf
envvars="%%PREFIX%%/sbin/envvars"
[ -z "$apache_enable" ] && apache_enable="NO"
[ -z "$apachelimits_enable" ] && apachelimits_enable="NO"
[ -z "$apachelimits_args" ] && apachelimits_args="-e -C daemon"
[ -z "$apache_http_accept_enable" ] && apache_http_accept_enable="NO"
[ -z "$apache_configcheck_disable" ] && apache_configcheck_disable="NO"
apache_accf()
{
if checkyesno apache_http_accept_enable; then
/sbin/kldstat -qm accf_http || /sbin/kldload accf_http || return ${?}
/sbin/kldstat -qm accf_data || /sbin/kldload accf_data || return ${?}
else
apache_flags="${apache_flags} -DNOHTTPACCEPT"
fi
}
load_rc_config $name
if [ -n "$2" ]; then
profile="$2"
if [ "x${apache_profiles}" != "x" ]; then
pidfile="${_pidprefix}.${profile}.pid"
eval apache_configfile="\${apache_${profile}_configfile:-}"
if [ "x${apache_configfile}" = "x" ]; then
echo "You must define a configuration file (apache_${profile}_configfile)"
exit 1
fi
required_files="${apache_configfile}"
eval apache_enable="\${apache_${profile}_enable:-${apache_enable}}"
eval apache_flags="\${apache_${profile}_flags:-${apache_flags}}"
eval apache_http_accept_enable="\${apache_${profile}_http_accept_enable:-${apache_http_accept_enable}}"
eval apachelimits_enable="\${apachelimits_${profile}_enable:-${apachelimits_enable}}"
eval apachelimits_args="\${apachelimits_${profile}_args:-${apachelimits_args}}"
eval apache_fib="\${apache_${profile}_fib:-${apache_fib}}"
eval apache_configcheck_disable="\${apache_${profile}_configcheck_disable:-${apache_configcheck_disable}}"
eval command="\${apache_${profile}_command:-${command}}"
eval pidfile="\${apache_${profile}_pidfile:-${pidfile}}"
eval apache_envvars="\${apache_${profile}_envvars:-${envvars}}"
apache_flags="-f ${apache_configfile} -c \"PidFile ${pidfile}\" ${apache_flags}"
else
echo "$0: extra argument ignored"
fi
else
eval apache_envvars=${envvars}
if [ "x${apache_profiles}" != "x" -a "x$1" != "x" ]; then
for profile in ${apache_profiles}; do
eval _enable="\${apache_${profile}_enable}"
case "x${_enable:-${apache_enable}}" in
x|x[Nn][Oo]|x[Nn][Oo][Nn][Ee])
continue
;;
x[Yy][Ee][Ss])
;;
*)
if test -z "$_enable"; then
_var=apache_enable
else
_var=apache_"${profile}"_enable
fi
echo "Bad value" \
"'${_enable:-${apache_enable}}'" \
"for ${_var}. " \
"Profile ${profile} skipped."
continue
;;
esac
echo "===> apache profile: ${profile}"
%%PREFIX%%/etc/rc.d/apache $1 ${profile}
retcode="$?"
if [ "0${retcode}" -ne 0 ]; then
failed="${profile} (${retcode}) ${failed:-}"
else
success="${profile} ${success:-}"
fi
done
exit 0
fi
fi
if [ "${1}" != "stop" ] ; then \
apache_accf
fi
if checkyesno apache_configcheck_disable
then
unset restart_precmd
unset reload_precmd
fi
apache_requirepidfile()
{
if [ ! "0`check_pidfile ${pidfile} ${command}`" -gt 1 ]; then
echo "${name} not running? (check $pidfile)."
exit 1
fi
}
apache_checkconfig()
{
if test -f ${apache_envvars}
then
. ${apache_envvars}
fi
echo "Performing sanity check on apache configuration:"
eval ${command} ${apache_flags} -t
}
apache_graceful() {
apache_requirepidfile
if ! checkyesno apache_configcheck_disable
then
apache_checkconfig
fi
echo "Performing a graceful restart"
eval ${command} ${apache_flags} -k graceful
}
apache_gracefulstop() {
apache_requirepidfile
if ! checkyesno apache_configcheck_disable
then
apache_checkconfig
fi
echo "Performing a graceful stop"
eval ${command} ${apache_flags} -k graceful-stop
}
apache_precmd()
{
if ! checkyesno apache_configcheck_disable
then
apache_checkconfig
fi
if checkyesno apachelimits_enable
then
eval `/usr/bin/limits ${apachelimits_args}` 2>/dev/null
else
return 0
fi
}
apache_checkfib () {
if command -v check_namevarlist > /dev/null 2>&1; then
check_namevarlist fib && return 0
fi
$SYSCTL net.fibs >/dev/null 2>&1 || return 0
apache_fib=${apache_fib:-"NONE"}
if [ "x$apache_fib" != "xNONE" ]
then
command="/usr/sbin/setfib -F ${apache_fib} ${command}"
else
return 0
fi
}
apache_prestart() {
apache_checkfib
apache_precmd
}
extra_commands="reload graceful gracefulstop configtest"
run_rc_command "$1"