mirror of
https://github.com/outbackdingo/ports.git
synced 2026-03-21 06:44:30 +00:00
47 lines
1.8 KiB
Plaintext
Executable File
47 lines
1.8 KiB
Plaintext
Executable File
# description : Open-source HTTP server
|
|
# depends : apr-util libnghttp2 pcre2 libxml2 openssl
|
|
|
|
name=apache
|
|
version=2.4.57
|
|
release=1
|
|
source="https://archive.apache.org/dist/httpd/httpd-$version.tar.bz2
|
|
httpd-blfs_layout-1.patch::https://www.linuxfromscratch.org/patches/blfs/svn/httpd-$version-blfs_layout-1.patch
|
|
rc.httpd
|
|
run.httpd"
|
|
|
|
build() {
|
|
cd httpd-$version
|
|
|
|
# Forces the apxs utility to use absolute pathnames for modules, when instructed to do so
|
|
patch -Np1 -i $SRC/httpd-blfs_layout-1.patch
|
|
|
|
# Adapt the Lua module to API changes in Lua-5.4
|
|
sed -i 's/lua_resume(a, NULL, b)/lua_resume(a, NULL, b, NULL)/' modules/lua/mod_lua.h
|
|
|
|
./configure --enable-authnz-fcgi \
|
|
--enable-layout=BLFS \
|
|
--enable-mods-shared="all cgi" \
|
|
--enable-mpms-shared=all \
|
|
--enable-suexec=shared \
|
|
--with-apr=/usr/bin/apr-1-config \
|
|
--with-apr-util=/usr/bin/apu-1-config \
|
|
--with-suexec-bin=/usr/lib/httpd/suexec \
|
|
--with-suexec-caller=apache \
|
|
--with-suexec-docroot=/srv/www \
|
|
--with-suexec-logfile=/var/log/httpd/suexec.log \
|
|
--with-suexec-uidmin=100 \
|
|
--with-suexec-userdir=public_html
|
|
make
|
|
make DESTDIR=$PKG install
|
|
|
|
mv -v $PKG/usr/sbin/suexec $PKG/usr/lib/httpd/suexec
|
|
|
|
rm -fr $PKG/var/run
|
|
|
|
# runit service
|
|
install -Dm755 $SRC/run.httpd $PKG/etc/sv/httpd/run
|
|
ln -s /run/runit/supervise.httpd $PKG/etc/sv/httpd/supervise
|
|
# rc service
|
|
install -Dm755 $SRC/rc.httpd $PKG/etc/rc.d/httpd
|
|
}
|