2023-05-02 02:08:24 +03:00
|
|
|
distributable:
|
|
|
|
url: https://dlcdn.apache.org/httpd/httpd-2.4.57.tar.gz
|
|
|
|
strip-components: 1
|
|
|
|
|
|
|
|
versions:
|
|
|
|
url: https://dlcdn.apache.org/httpd/
|
|
|
|
match: /httpd-\d+\.\d+\.\d+.tar.gz/
|
|
|
|
strip:
|
|
|
|
- /^httpd-/
|
|
|
|
- /\.tar\.gz$/
|
|
|
|
|
|
|
|
dependencies:
|
|
|
|
apache.org/apr: '>=1.3.0'
|
|
|
|
apache.org/apr-util: '>=1.3.0'
|
|
|
|
github.com/google/brotli: '*'
|
|
|
|
nghttp2.org: '*'
|
|
|
|
openssl.org: '*'
|
|
|
|
pcre.org/v2: '*'
|
|
|
|
gnome.org/libxml2: '*'
|
|
|
|
zlib.net: '*'
|
2023-05-06 21:12:36 +03:00
|
|
|
libexpat.github.io: '*'
|
|
|
|
|
|
|
|
runtime:
|
|
|
|
env:
|
|
|
|
HTTPD_ROOT: '{{prefix}}'
|
|
|
|
APACHE_CONFDIR: '{{prefix}}/conf'
|
2023-05-02 02:08:24 +03:00
|
|
|
|
|
|
|
build:
|
|
|
|
dependencies:
|
|
|
|
tea.xyz/gx/cc: c99
|
|
|
|
tea.xyz/gx/make: '*'
|
|
|
|
gnu.org/libtool: '*'
|
|
|
|
gnu.org/autoconf: '*'
|
|
|
|
script: |
|
|
|
|
./configure $ARGS
|
|
|
|
make
|
|
|
|
make install
|
2023-05-06 21:12:36 +03:00
|
|
|
|
|
|
|
HTTPD_CONF=$(tea httpd -V 2>/dev/null | grep SERVER_CONFIG_FILE | sed 's/.*"\(.*\)"/\1/')
|
|
|
|
port=8080
|
|
|
|
while lsof -i:$port >/dev/null 2>&1; do
|
|
|
|
((port++))
|
|
|
|
done
|
|
|
|
if [ "$port" -ne 8080 ]; then
|
|
|
|
sed -i '' "s/Listen 8080/Listen $port/" {{prefix}}/$HTTPD_CONF
|
|
|
|
fi
|
|
|
|
sed -i.bak 's/#ServerName www.example.com:8080/ServerName localhost:'"$port"'/g' {{prefix}}/$HTTPD_CONF
|
|
|
|
|
|
|
|
cd "{{prefix}}/bin"
|
|
|
|
sed -i.bak \
|
|
|
|
-e "s_{{prefix}}_\$(cd \$(dirname \$0)/.. \&\& pwd)_g" \
|
|
|
|
-e "s/^HTTPD=\'\(.*\)\'$/HTTPD=\"\1\"/" \
|
|
|
|
apachectl envvars envvars-std
|
|
|
|
sed -i.bak \
|
|
|
|
-e 's_{{prefix}}_$(cd $(dirname $0)/.. && pwd)_g' \
|
|
|
|
-e 's/^HTTPD='\''\(.*\)'\''$/HTTPD="$(cd $(dirname $0)\/.. \&\& pwd)\/bin\/httpd"/' \
|
|
|
|
apachectl envvars envvars-std
|
|
|
|
|
|
|
|
rm apachectl.bak envvars.bak envvars-std.bak
|
|
|
|
cd ../conf
|
|
|
|
sed -i.bak \
|
|
|
|
-e 's_{{prefix}}_\${HTTPD\_ROOT}_' \
|
|
|
|
httpd.conf
|
|
|
|
rm httpd.conf.bak
|
|
|
|
|
2023-05-02 02:08:24 +03:00
|
|
|
env:
|
|
|
|
ARGS:
|
|
|
|
- --prefix="{{prefix}}"
|
2023-05-06 21:12:36 +03:00
|
|
|
- --enable-layout="Apache"
|
2023-05-02 02:08:24 +03:00
|
|
|
- --enable-mpms-shared=all
|
|
|
|
- --enable-mods-shared=all
|
|
|
|
- --enable-authnz-fcgi
|
2023-05-06 21:12:36 +03:00
|
|
|
- --enable-so
|
|
|
|
- --enable-ssl
|
2023-05-02 02:08:24 +03:00
|
|
|
- --enable-cgi
|
|
|
|
- --enable-pie
|
|
|
|
- --enable-suexec
|
|
|
|
- --with-suexec-caller=_www
|
2023-05-06 21:12:36 +03:00
|
|
|
- --with-suexec-bin={{prefix}}/suexec
|
2023-05-02 02:08:24 +03:00
|
|
|
- --with-port=8080
|
|
|
|
- --with-sslport=8443
|
|
|
|
- --with-apr={{deps.apache.org/apr.prefix}}
|
|
|
|
- --with-apr-util={{deps.apache.org/apr-util.prefix}}
|
|
|
|
- --with-brotli={{deps.github.com/google/brotli.prefix}}
|
|
|
|
- --with-libxml2={{deps.gnome.org/libxml2.prefix}}
|
|
|
|
- --with-mpm=prefork
|
|
|
|
- --with-nghttp2={{deps.nghttp2.org.prefix}}
|
|
|
|
- --with-ssl={{deps.openssl.org.prefix}}
|
|
|
|
- --with-pcre={{deps.pcre.org/v2.prefix}}
|
|
|
|
- --with-z={{deps.zlib.net.prefix}}
|
|
|
|
- --disable-lua
|
|
|
|
- --disable-luajit
|
|
|
|
|
|
|
|
provides:
|
|
|
|
- bin/ab
|
2023-05-06 21:12:36 +03:00
|
|
|
- bin/apachectl
|
2023-05-02 02:08:24 +03:00
|
|
|
- bin/checkgid
|
|
|
|
- bin/fcgistarter
|
|
|
|
- bin/htcacheclean
|
|
|
|
- bin/htdbm
|
|
|
|
- bin/htdigest
|
|
|
|
- bin/htpasswd
|
|
|
|
- bin/httpd
|
|
|
|
- bin/httxt2dbm
|
|
|
|
- bin/logresolve
|
|
|
|
- bin/rotatelogs
|
|
|
|
- bin/suexec
|
|
|
|
|
2023-05-06 21:12:36 +03:00
|
|
|
test:
|
|
|
|
script: |
|
|
|
|
httpd -v | grep {{version}}
|
|
|
|
apachectl -t -f "$APACHE_CONFDIR/httpd.conf"
|