From 51ab110c5c551641d545818b1bbff4cb044e2e53 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bartosz=20=C5=9Awi=C4=85tek?= Date: Wed, 22 Feb 2012 00:58:52 +0100 Subject: [PATCH] - build MPMs as loadable modules --- apache.spec | 36 ++++++++---------------------------- 1 file changed, 8 insertions(+), 28 deletions(-) diff --git a/apache.spec b/apache.spec index 66cf677..8f232f8 100644 --- a/apache.spec +++ b/apache.spec @@ -1818,12 +1818,10 @@ touch ssl_expr_scan.c cd ../.. CPPFLAGS="-DMAX_SERVER_LIMIT=200000 -DBIG_SECURITY_HOLE=1" -for mpm in prefork worker %{?with_event:event} %{?with_itk:itk}; do -install -d "buildmpm-${mpm}"; cd "buildmpm-${mpm}" -../%configure \ +%configure \ --enable-layout=TLD \ --disable-v4-mapped \ - $( [ "${mpm}" = "prefork" -o "${mpm}" = "worker" -o "${mpm}" = "event" ] && echo "--enable-exception-hook" ) \ + --enable-exception-hook \ --enable-modules=all \ --enable-mods-shared=all \ --enable-auth-anon \ @@ -1878,13 +1876,11 @@ install -d "buildmpm-${mpm}"; cd "buildmpm-${mpm}" --enable-speling \ --enable-rewrite \ --enable-so \ - --with-program-name=httpd.${mpm} \ - --with-mpm=${mpm} \ -%ifarch %{ix86} -%ifnarch i386 i486 - $( [ "${mpm}" = "leader" ] && echo "--enable-nonportable-atomics=yes" ) \ -%endif -%endif + --with-program-name=httpd \ + --with-mpm=prefork \ + --with-mpm=worker \ + --with-mpm=event \ + --enable-mpms-shared \ --with-suexec-bin=%{_sbindir}/suexec \ --with-suexec-caller=http \ --with-suexec-docroot=%{_datadir} \ @@ -1897,18 +1893,7 @@ install -d "buildmpm-${mpm}"; cd "buildmpm-${mpm}" --with-pcre %{__make} -./httpd.${mpm} -l | grep -v "${mpm}" > modules-inside -cd .. - -done - -for mpm in worker %{?with_event:event} %{?with_itk:itk}; do - if ! cmp -s buildmpm-prefork/modules-inside buildmpm-${mpm}/modules-inside; then - echo "List of compiled modules is different between prefork-MPM and ${mpm}-MPM!" - echo "Build failed." - exit 1 - fi -done +./httpd -l > modules-inside %install rm -rf $RPM_BUILD_ROOT @@ -1922,11 +1907,6 @@ install -d $RPM_BUILD_ROOT/etc/{logrotate.d,rc.d/init.d,sysconfig} \ %{__make} -C buildmpm-prefork install \ DESTDIR=$RPM_BUILD_ROOT -# install other mpm-s -for mpm in worker %{?with_event:event} %{?with_itk:itk}; do - install buildmpm-${mpm}/httpd.${mpm} $RPM_BUILD_ROOT%{_sbindir}/httpd.${mpm} -done - ln -s httpd.prefork $RPM_BUILD_ROOT%{_sbindir}/httpd ln -s %{_libexecdir} $RPM_BUILD_ROOT%{_sysconfdir}/modules ln -s %{_localstatedir}/run/httpd $RPM_BUILD_ROOT%{_sysconfdir}/run -- 2.44.0