This commit is contained in:
parent
0defb1aea2
commit
50e8112f11
@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Oct 22 17:38:19 CEST 2007 - sbrabec@suse.cz
|
||||
|
||||
- Use correct SuSEfirewall2 rule directory.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Sep 3 13:43:22 CEST 2007 - skh@suse.de
|
||||
|
||||
|
52
apache2.spec
52
apache2.spec
@ -55,7 +55,7 @@ License: The Apache Software License
|
||||
Group: Productivity/Networking/Web/Servers
|
||||
%define realver 2.2.4
|
||||
Version: 2.2.4
|
||||
Release: 61
|
||||
Release: 75
|
||||
#Source0: http://www.apache.org/dist/httpd-%{version}.tar.bz2
|
||||
Source0: http://httpd.apache.org/dev/dist/httpd-%{realver}.tar.bz2
|
||||
Source10: SUSE-NOTICE
|
||||
@ -112,10 +112,10 @@ Patch69: httpd-2.2.x.doublefree.patch
|
||||
Patch150: mod_dbd.c-issue18989-autoconnect.dif
|
||||
Patch151: apache2-mod_status-CVE-2006-5752.patch
|
||||
Patch152: apache2-mod_cache-CVE-2007-1863.patch
|
||||
URL: http://httpd.apache.org/
|
||||
Url: http://httpd.apache.org/
|
||||
Icon: Apache.xpm
|
||||
Summary: The Apache Web Server Version 2.0
|
||||
Autoreqprov: on
|
||||
AutoReqProv: on
|
||||
Provides: httpd http_daemon %{apache_mmn} suse_help_viewer
|
||||
Requires: %{pname}-MPM /etc/mime.types
|
||||
PreReq: %{name}-utils
|
||||
@ -179,6 +179,7 @@ Provides: %{pname}-MPM
|
||||
Requires: %{name} = %{version}
|
||||
%endif
|
||||
%if %prefork
|
||||
|
||||
%package prefork
|
||||
Summary: Apache 2 "prefork" MPM (Multi-Processing Module)
|
||||
Group: Productivity/Networking/Web/Servers
|
||||
@ -189,6 +190,7 @@ Provides: apache:/usr/sbin/httpd
|
||||
Requires: %{name} = %{version}
|
||||
%endif
|
||||
%if %event
|
||||
|
||||
%package event
|
||||
Summary: Apache 2 event MPM (Multi-Processing Module)
|
||||
Group: Productivity/Networking/Web/Servers
|
||||
@ -212,7 +214,6 @@ Authors:
|
||||
|
||||
%endif
|
||||
%if %prefork
|
||||
|
||||
%description prefork
|
||||
"prefork" MPM (Multi-Processing Module)
|
||||
|
||||
@ -228,7 +229,6 @@ Authors:
|
||||
|
||||
%endif
|
||||
%if %event
|
||||
|
||||
%description event
|
||||
The event MPM (multi-Processing Module) is experimental, so it may or
|
||||
may not work as expected.
|
||||
@ -335,7 +335,6 @@ cp -p %{S:16} %{S:17} .; gunzip mkcert.sh.gz
|
||||
# replace PLATFORM string that's seen in the "Server:" header
|
||||
#
|
||||
sed 's,(" PLATFORM "),(%platform_string),' server/core.c > tmp_file && mv tmp_file server/core.c
|
||||
|
||||
sed 's/public_html/%{userdir}/g' docs/conf/extra/httpd-userdir.conf.in > tmp_file && mv tmp_file docs/conf/extra/httpd-userdir.conf.in
|
||||
#
|
||||
# now configure Apache
|
||||
@ -421,8 +420,6 @@ function configure {
|
||||
--with-suexec-gidmin=96 \
|
||||
--with-suexec-safepath=%{suexec_safepath}
|
||||
}
|
||||
|
||||
|
||||
#
|
||||
# |_ o| _| | _ _ ._
|
||||
# |_)|_|||(_| |(_)(_)|_)
|
||||
@ -439,7 +436,6 @@ for mpm in %{mpms_to_build}; do
|
||||
configure
|
||||
sed "s/%{vers}-$mpm//" include/ap_config_auto.h > include/ap_config_auto.h.new
|
||||
mv include/ap_config_auto.h.new include/ap_config_auto.h
|
||||
|
||||
make CFLAGS="$RPM_OPT_FLAGS -fPIC \
|
||||
-fno-strict-aliasing \
|
||||
-Wall \
|
||||
@ -449,9 +445,7 @@ for mpm in %{mpms_to_build}; do
|
||||
-DDEFAULT_PIDLOG='\"%{runtimedir}/%{httpd}.pid\"' \
|
||||
-DDEFAULT_ERRORLOG='\"%{logfiledir}/error_log\"' " \
|
||||
%{?jobs:-j%jobs}
|
||||
|
||||
make DESTDIR=$RPM_BUILD_ROOT install
|
||||
|
||||
#rm -rf $RPM_BUILD_ROOT.$mpm.pre
|
||||
#cp -a $RPM_BUILD_ROOT/ $RPM_BUILD_ROOT.$mpm.pre
|
||||
# show pathnames in config files
|
||||
@ -476,14 +470,12 @@ for mpm in %{mpms_to_build}; do
|
||||
#cp -a $RPM_BUILD_ROOT/ $RPM_BUILD_ROOT.$mpm.post
|
||||
done
|
||||
mkdir -p $RPM_BUILD_ROOT/%{libexecdir}
|
||||
|
||||
# remove references to mpm type in config_vars
|
||||
sed -e "s^/usr/%_lib/%{pname}-%{default_mpm}^/usr/%_lib/%{pname}^" \
|
||||
-e "s/httpd$/%{httpd}-%{default_mpm}/" \
|
||||
-e "s/%{pname}-%{default_mpm}/%{pname}/" \
|
||||
< $RPM_BUILD_ROOT/%{installbuilddir}/config_vars.mk-%{default_mpm} \
|
||||
> $RPM_BUILD_ROOT/%{installbuilddir}/config_vars.mk
|
||||
|
||||
# get rid of modules that do not differ between the MPMs (since most of them are the same)
|
||||
# by putting them in /usr/lib/apache%{vers}
|
||||
ldir=$RPM_BUILD_ROOT/%{libexecdir}
|
||||
@ -500,7 +492,6 @@ for i in $(cd $ldir-%{default_mpm}; ls -1); do
|
||||
done
|
||||
fi
|
||||
done
|
||||
|
||||
# merge the three /usr/include/apache2-* directories
|
||||
# by putting them in /usr/lib/apache%{vers}
|
||||
idir=$RPM_BUILD_ROOT/%{includedir}
|
||||
@ -524,7 +515,6 @@ for i in ap_config_auto.h ap_config_layout.h; do
|
||||
fi
|
||||
done
|
||||
|
||||
|
||||
%install
|
||||
#
|
||||
# O/ o._ __|_ _.||
|
||||
@ -538,7 +528,6 @@ cat > $RPM_BUILD_ROOT/%{_libdir}/%{pname}_MMN <<-EOF
|
||||
#!/bin/sh
|
||||
echo %{apache_mmn}
|
||||
EOF
|
||||
|
||||
cp -p $RPM_BUILD_ROOT/%{sysconfdir}/%{httpd}-%{default_mpm}.conf $RPM_BUILD_ROOT/%{sysconfdir}/httpd.conf
|
||||
cp -p $RPM_BUILD_ROOT/%{sysconfdir}/httpd.conf ./httpd.conf.default
|
||||
rm $RPM_BUILD_ROOT/%{sysconfdir}/%{httpd}-*.conf
|
||||
@ -630,7 +619,6 @@ cat > $RPM_BUILD_ROOT/%{sysconfdir}/uid.conf <<-EOF
|
||||
User %httpduser
|
||||
Group %httpdgroup
|
||||
EOF
|
||||
|
||||
# remove configuration for mpms which have not been built
|
||||
mpm_confs="$(awk '/IfModule .*\.c/ {print $2}' $RPM_BUILD_ROOT/%{sysconfdir}/server-tuning.conf | cut -d. -f1 | tr '\n' ' ')"
|
||||
for mpm_conf in $mpm_confs; do
|
||||
@ -647,19 +635,16 @@ install -m 644 $RPM_SOURCE_DIR/apache2-vhost-ssl.template $RPM_BUILD_ROOT/%{sysc
|
||||
install -m 644 $RPM_SOURCE_DIR/apache2-manual.conf $RPM_BUILD_ROOT/%{sysconfdir}/conf.d/
|
||||
# for mod_auth_ldap
|
||||
install -m 644 docs/conf/charset.conv $RPM_BUILD_ROOT/%{sysconfdir}/
|
||||
|
||||
cp -p $RPM_SOURCE_DIR/robots.txt .
|
||||
cp -p $RPM_SOURCE_DIR/favicon.ico $RPM_BUILD_ROOT/%{htdocsdir}/
|
||||
cat > $RPM_BUILD_ROOT/%{htdocsdir}/robots.txt <<-EOF
|
||||
User-Agent: *
|
||||
Disallow: /
|
||||
EOF
|
||||
|
||||
#
|
||||
# use official mime.types (more complete)
|
||||
#
|
||||
ln -sf ../mime.types $RPM_BUILD_ROOT/%{sysconfdir}/mime.types
|
||||
|
||||
mv $RPM_BUILD_ROOT/%{cgidir}/printenv .
|
||||
mv $RPM_BUILD_ROOT/%{cgidir}/test-cgi .
|
||||
pushd $RPM_BUILD_ROOT/%{_mandir}
|
||||
@ -701,12 +686,10 @@ pushd $RPM_BUILD_ROOT/%{_sbindir}
|
||||
EOT_ED
|
||||
mv apxs apxs%{vers}
|
||||
popd
|
||||
|
||||
# install firewall information file
|
||||
install -d $RPM_BUILD_ROOT%{_sysconfdir}/SuSEfirewall2.d/services/
|
||||
install -m 644 %{S:49} $RPM_BUILD_ROOT%{_sysconfdir}/SuSEfirewall2.d/services/%{name}
|
||||
install -m 644 %{S:50} $RPM_BUILD_ROOT%{_sysconfdir}/SuSEfirewall2.d/services/%{name}-ssl
|
||||
|
||||
install -d $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/SuSEfirewall2.d/services/
|
||||
install -m 644 %{S:49} $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/SuSEfirewall2.d/services/%{name}
|
||||
install -m 644 %{S:50} $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/SuSEfirewall2.d/services/%{name}-ssl
|
||||
#
|
||||
# filelists
|
||||
#
|
||||
@ -724,14 +707,11 @@ find $RPM_BUILD_ROOT/%{includedir}/.. -type f -o -type l \
|
||||
find $RPM_BUILD_ROOT/%{installbuilddir} -type f \
|
||||
| sed "s#$RPM_BUILD_ROOT##" \
|
||||
>> filelist-devel
|
||||
|
||||
# remove files from the build root that we won't package
|
||||
rm -f $RPM_BUILD_ROOT/%{_libdir}/%{pname}-*/*.exp # needed only on AIX
|
||||
rm -f $RPM_BUILD_ROOT/%{_libdir}/%{pname}/*.exp # needed only on AIX
|
||||
rm -f $RPM_BUILD_ROOT/%{_sbindir}/checkgid # needed only for user installations from tarball
|
||||
rm -r $RPM_BUILD_ROOT/%{sysconfdir}/extra # it is already in the documentation directory
|
||||
|
||||
|
||||
#
|
||||
# O/ _|_ _ __|_
|
||||
# /O |_(/__> |_
|
||||
@ -773,7 +753,6 @@ done
|
||||
# auth_ldap_module needs to be loaded after ldap_module
|
||||
echo -e "/authnz_ldap\n+\n-m/ldap\nwq" | ed -s ./%{sysconfdir}/sysconfig.d/loadmodule.conf.test
|
||||
popd
|
||||
|
||||
%if %{?suse_version:1}%{!?suse_version:0}
|
||||
LD_LIBRARY_PATH=${RPM_BUILD_ROOT}%{_libdir} \
|
||||
$RPM_BUILD_ROOT/%{_sbindir}/httpd%{vers}-%{default_mpm} \
|
||||
@ -866,10 +845,8 @@ mv $RPM_BUILD_ROOT/%{sysconfdir}/original .
|
||||
%{_prefix}/share/%{pname}/find_httpd2_includes
|
||||
%{_prefix}/share/%{pname}/find_mpm
|
||||
%{_prefix}/share/%{pname}/load_configuration
|
||||
%dir /etc/SuSEfirewall2.d
|
||||
%dir /etc/SuSEfirewall2.d/services
|
||||
%config %{_sysconfdir}/SuSEfirewall2.d/services/%{name}
|
||||
%config %{_sysconfdir}/SuSEfirewall2.d/services/%{name}-ssl
|
||||
%config %{_sysconfdir}/sysconfig/SuSEfirewall2.d/services/%{name}
|
||||
%config %{_sysconfdir}/sysconfig/SuSEfirewall2.d/services/%{name}-ssl
|
||||
%if %prefork
|
||||
|
||||
%files prefork
|
||||
@ -1012,7 +989,6 @@ if [ -e $RC_CONFIG ]; then
|
||||
echo "done"
|
||||
fi
|
||||
fi
|
||||
|
||||
if test -s etc/sysconfig/%{pname} && grep -q "^LOADMODULES" etc/sysconfig/%{pname}; then
|
||||
sed "s/LOADMODULES/APACHE_MODULES/" etc/sysconfig/%{pname} >| $tmpfile \
|
||||
&& cp $tmpfile etc/sysconfig/%{pname}
|
||||
@ -1033,24 +1009,19 @@ if [ ${FIRST_ARG:-0} -gt 1 ]; then
|
||||
sed "
|
||||
# generated files were renamed from suse_* to sysconfig.d/*
|
||||
s|\(^Include /etc/apache2\)/suse_\(\(include\|loadmodule\|global\).conf\)|\1/sysconfig.d/\2|
|
||||
|
||||
# the access_log configuration is now configurable
|
||||
s|^CustomLog /var/log/apache2/access_log.*|# &|
|
||||
|
||||
# group of wwwrun has changed
|
||||
s|^Group nogroup|Group www|
|
||||
|
||||
" < ./%{sysconfdir}/httpd.conf > $tmpfile
|
||||
chmod --reference=./%{sysconfdir}/httpd.conf $tmpfile
|
||||
chown --reference=./%{sysconfdir}/httpd.conf $tmpfile
|
||||
cmp -s $tmpfile ./%{sysconfdir}/httpd.conf || cp -p $tmpfile ./%{sysconfdir}/httpd.conf
|
||||
fi
|
||||
|
||||
rm -rf $tmpdir
|
||||
/usr/share/%{pname}/apache-20-22-upgrade
|
||||
/usr/share/%{pname}/get_module_list &>/dev/null
|
||||
exit 0
|
||||
|
||||
%verifyscript
|
||||
%verify_permissions -e %{_sbindir}/suexec2
|
||||
|
||||
@ -1058,8 +1029,9 @@ exit 0
|
||||
if ! test -f /.buildenv; then
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
fi
|
||||
|
||||
%changelog
|
||||
* Mon Oct 22 2007 - sbrabec@suse.cz
|
||||
- Use correct SuSEfirewall2 rule directory.
|
||||
* Mon Sep 03 2007 - skh@suse.de
|
||||
- get_module_list: replace loadmodule.conf atomically [bnc #214863]
|
||||
* Fri Aug 31 2007 - poeml@suse.de
|
||||
|
Loading…
x
Reference in New Issue
Block a user