# --- T2-COPYRIGHT-NOTE-BEGIN --- # T2 SDE: package/*/apache/apache.conf # Copyright (C) 2004 - 2023 The T2 SDE Project # Copyright (C) 1998 - 2004 ROCK Linux Project # # This Copyright note is generated by scripts/Create-CopyPatch, # more information can be found in the files COPYING and README. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2. # --- T2-COPYRIGHT-NOTE-END --- if [ $prefix_auto = 1 ]; then if [ "$SDECFG_PKG_APACHE_PREFIX" ]; then prefix="$SDECFG_PKG_APACHE_PREFIX" else prefix="opt/apache" fi set_confopt fi [ "$sysconfdir" == "/etc" ] && sysconfdir=/etc/apache [ "$datadir" == "/var/lib" ] && datadir=/var/lib/apache if atstage "cross"; then hook_add preconf 5 "echo 'ap_cv_void_ptr_lt_long=no' >> config.cache" var_append makeopt ' ' 'LIBTOOL=$root/usr/bin/libtool' fi # APR is mandatory, so no additional test needed. pkgprefix -t apr var_append extraconfopt " " "--with-apr=$root/$(pkgprefix apr)" pkgprefix -t apr-util var_append extraconfopt " " "--with-apr-util=$root/$(pkgprefix apr-util)" pkginstalled nghttp2 && var_append extraconfopt " " "--enable-http2" pkginstalled pcre && var_append extraconfopt " " "--with-pcre=$root/$(pkgprefix pcre)" if [ $pkg = "apache" ]; then datadir="$localstatedir/lib" # or maybe www would be nicer than lib ?!? ... if [ "$SDECFG_PKG_APACHE_SUEXEC" == "1" ]; then if [ "${SDECFG_PKG_APACHE_DOCROOT:0:1}" == "/" ]; then docroot="$SDECFG_PKG_APACHE_DOCROOT" else docroot="$localstatedir/$SDECFG_PKG_APACHE_DOCROOT" fi var_append extraconfopt ' ' \ "--with-suexec-docroot=${docroot#$root}" # var_append extraconfopt ' ' \ # "--with-suexec-userdir=$SDECFG_PKG_APACHE_USERDIR" var_append extraconfopt ' ' "--with-suexec-caller=http \ --enable-suexec" hook_add postmake 5 "mv -vf $sbindir/suexec $bindir/" fi var_append extraconfopt ' ' "--enable-cgi" [ "$SDECFG_PKG_APACHE_MOD_SO" == 1 ] && var_append extraconfopt " " "--enable-so" [ "$SDECFG_PKG_APACHE_MOD_AUTH_ANON" == 1 ] && var_append extraconfopt " " "--enable-mod-auth-anon" [ "$SDECFG_PKG_APACHE_MOD_AUTH_DBM" == 1 ] && var_append extraconfopt " " "--enable-mod-auth-dbm" [ "$SDECFG_PKG_APACHE_MOD_AUTH_DIGEST" == 1 ] && var_append extraconfopt " " "--enable-auth-digest" if [ "$SDECFG_PKG_APACHE_MOD_AUTH_LDAP" == 1 ]; then pkgprefix -t openldap var_append extraconfopt " " "--with-ldap" var_append extraconfopt " " "--enable-ldap" var_append extraconfopt " " "--enable-auth-ldap" var_append CFLAGS ' ' "-I$(pkgprefix includedir openldap)" var_append CPPFLAGS ' ' "-I$(pkgprefix includedir openldap)" var_append LDFLAGS ' ' "-L$(pkgprefix libdir openldap)" export CPPFLAGS CFLAGS LDFLAGS fi var_append extraconfopt " " "--enable-ssl" [ "$SDECFG_PKG_APACHE_MOD_DAV" == 1 ] && var_append extraconfopt " " "--enable-dav" [ "$SDECFG_PKG_APACHE_MOD_PROXY" == 1 ] && var_append extraconfopt " " "--enable-proxy" [ "$SDECFG_PKG_APACHE_MOD_REWRITE" == 1 ] && var_append extraconfopt " " "--enable-rewrite" [ "$SDECFG_PKG_APACHE_MOD_CACHE" == 1 ] && var_append extraconfopt " " "--enable-cache" [ "$SDECFG_PKG_APACHE_MOD_DISK_CACHE" == 1 ] && var_append extraconfopt " " "--enable-disk-cache" [ "$SDECFG_PKG_APACHE_MOD_DEFLATE" == 1 ] && var_append extraconfopt " " "--enable-deflate" [ "$SDECFG_PKG_APACHE_MOD_INFO" == 1 ] && var_append extraconfopt " " "--enable-info" [ "$SDECFG_PKG_APACHE_MOD_SPELLING" == 1 ] && var_append extraconfopt " " "--enable-spelling" fi if [ "$SDECFG_PKG_APACHE_BDB" ]; then pkgprefix -t bdb var_append extraconfopt " " \ "--with-berkeley-db=$(pkgprefix includedir bdb)" fi [[ $libdir = *lib64 ]] && hook_add premake 3 "sed -i 's/usr\/lib$/usr\/lib64/' build/config_vars.mk"