3a44ff7
%define contentdir %{_datadir}/httpd
3a44ff7
%define docroot /var/www
cvsdist 3cbd43b
%define suexec_caller apache
3a44ff7
%define mmn 20120211
d546d00
%define mmnisa %{mmn}-%{__isa_name}-%{__isa_bits}
805286c
%define vstring Fedora
cvsdist f8e1fe3
cvsdist 3cbd43b
Summary: Apache HTTP Server
cvsdist 3cbd43b
Name: httpd
3a44ff7
Version: 2.4.1
3a44ff7
Release: 1%{?dist}
cvsdist 3cbd43b
URL: http://httpd.apache.org/
f93baaa
Source0: http://www.apache.org/dist/httpd/httpd-%{version}.tar.bz2
cvsdist 3cbd43b
Source1: index.html
cvsdist 3cbd43b
Source3: httpd.logrotate
cvsdist e9bfb00
Source5: httpd.sysconf
Jan Kaluza 2673a43
Source6: httpd-ssl-pass-dialog
3a44ff7
Source7: httpd.tmpfiles
3a44ff7
Source8: httpd.service
cvsdist 3cbd43b
Source10: httpd.conf
3a44ff7
Source11: 00-base.conf
3a44ff7
Source12: 00-mpm.conf
3a44ff7
Source13: 00-lua.conf
3a44ff7
Source14: 01-cgi.conf
3a44ff7
Source15: 00-dav.conf
3a44ff7
Source16: 00-proxy.conf
3a44ff7
Source17: 00-ssl.conf
3a44ff7
Source18: 00-ldap.conf
3a44ff7
Source19: userdir.conf
3a44ff7
Source20: ssl.conf
3a44ff7
Source21: welcome.conf
3a44ff7
Source22: manual.conf
cvsdist f8e1fe3
# Documentation
cvsdist f8e1fe3
Source33: README.confd
cvsdist 3cbd43b
# build/scripts patches
3a44ff7
Patch1: httpd-2.4.1-apctl.patch
3a44ff7
Patch2: httpd-2.4.1-apxs.patch
3a44ff7
Patch3: httpd-2.4.1-deplibs.patch
3a44ff7
Patch5: httpd-2.4.1-layout.patch
3a44ff7
Patch6: httpd-2.4.1-apr14.patch
cvsdist 6356941
# Features/functional changes
96e0b33
Patch20: httpd-2.0.48-release.patch
3a44ff7
Patch23: httpd-2.4.1-export.patch
3a44ff7
Patch24: httpd-2.4.1-corelimit.patch
3a44ff7
Patch25: httpd-2.4.1-selinux.patch
3a44ff7
Patch26: httpd-2.4.1-suenable.patch
073d591
License: ASL 2.0
cvsdist 3cbd43b
Group: System Environment/Daemons
47c8208
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
c187a27
BuildRequires: autoconf, perl, pkgconfig, findutils, xmlto
3a44ff7
BuildRequires: zlib-devel, libselinux-devel, lua-devel
6401925
BuildRequires: apr-devel >= 1.2.0, apr-util-devel >= 1.2.0, pcre-devel >= 5.0
ce009f9
Requires: /etc/mime.types, system-logos >= 7.92.1-1
06872c8
Obsoletes: httpd-suexec
cvsdist 3cbd43b
Provides: webserver
935b958
Provides: mod_dav = %{version}-%{release}, httpd-suexec = %{version}-%{release}
d546d00
Provides: httpd-mmn = %{mmn}, httpd-mmn = %{mmnisa}
ce009f9
Requires: httpd-tools = %{version}-%{release}, apr-util-ldap
ce009f9
Requires(pre): /usr/sbin/useradd
ce009f9
Requires(preun): systemd-units
ce009f9
Requires(postun): systemd-units
ce009f9
Requires(post): systemd-units
cvsdist 3cbd43b
cvsdist 3cbd43b
%description
0f8eb18
The Apache HTTP Server is a powerful, efficient, and extensible
0f8eb18
web server.
cvsdist 3cbd43b
cvsdist 3cbd43b
%package devel
cvsdist 3cbd43b
Group: Development/Libraries
8499915
Summary: Development interfaces for the Apache HTTP server
cvsdist 6356941
Obsoletes: secureweb-devel, apache-devel, stronghold-apache-devel
c1d7519
Requires: apr-devel, apr-util-devel, pkgconfig
9f7341d
Requires: httpd = %{version}-%{release}
cvsdist 3cbd43b
cvsdist 3cbd43b
%description devel
cvsdist 3cbd43b
The httpd-devel package contains the APXS binary and other files
7c0f3e4
that you need to build Dynamic Shared Objects (DSOs) for the
7c0f3e4
Apache HTTP Server.
cvsdist 3cbd43b
cvsdist 3cbd43b
If you are installing the Apache HTTP server and you want to be
cvsdist 3cbd43b
able to compile or develop additional modules for Apache, you need
cvsdist 3cbd43b
to install this package.
cvsdist 3cbd43b
cvsdist 3cbd43b
%package manual
cvsdist 3cbd43b
Group: Documentation
935b958
Summary: Documentation for the Apache HTTP server
9f7341d
Requires: httpd = %{version}-%{release}
cvsdist 3cbd43b
Obsoletes: secureweb-manual, apache-manual
39b4bd2
BuildArch: noarch
cvsdist 3cbd43b
cvsdist 3cbd43b
%description manual
cvsdist 3cbd43b
The httpd-manual package contains the complete manual and
cvsdist 3cbd43b
reference guide for the Apache HTTP server. The information can
9f9ccbc
also be found at http://httpd.apache.org/docs/2.2/.
cvsdist 3cbd43b
8499915
%package tools
8499915
Group: System Environment/Daemons
8499915
Summary: Tools for use with the Apache HTTP Server
8499915
8499915
%description tools
8499915
The httpd-tools package contains tools which can be used with 
8499915
the Apache HTTP Server.
8499915
cvsdist 3cbd43b
%package -n mod_ssl
cvsdist 3cbd43b
Group: System Environment/Daemons
8499915
Summary: SSL/TLS module for the Apache HTTP Server
jbj b35049d
Epoch: 1
c187a27
BuildRequires: openssl-devel
3383664
Requires(post): openssl, /bin/cat
9c0ce39
Requires(pre): httpd
d546d00
Requires: httpd = 0:%{version}-%{release}, httpd-mmn = %{mmnisa}
cvsdist 6356941
Obsoletes: stronghold-mod_ssl
cvsdist 3cbd43b
cvsdist 3cbd43b
%description -n mod_ssl
cvsdist 3cbd43b
The mod_ssl module provides strong cryptography for the Apache Web
cvsdist 3cbd43b
server via the Secure Sockets Layer (SSL) and Transport Layer
cvsdist 3cbd43b
Security (TLS) protocols.
cvsdist 3cbd43b
cvsdist 3cbd43b
%prep
cvsdist 3cbd43b
%setup -q
cvsdist d4ea4ed
%patch1 -p1 -b .apctl
cvsdist 739d054
%patch2 -p1 -b .apxs
96e0b33
%patch3 -p1 -b .deplibs
96e0b33
%patch5 -p1 -b .layout
3a44ff7
%patch6 -p1 -b .apr14
96e0b33
96e0b33
%patch23 -p1 -b .export
96e0b33
%patch24 -p1 -b .corelimit
96e0b33
%patch25 -p1 -b .selinux
6a32927
%patch26 -p1 -b .suenable
cvsdist 3cbd43b
cvsdist 6356941
# Patch in vendor/release string
96e0b33
sed "s/@RELEASE@/%{vstring}/" < %{PATCH20} | patch -p1
cvsdist 2d6a2e5
cvsdist f8e1fe3
# Safety check: prevent build if defined MMN does not equal upstream MMN.
cvsdist 3ebc88d
vmmn=`echo MODULE_MAGIC_NUMBER_MAJOR | cpp -include include/ap_mmn.h | sed -n '/^2/p'`
cvsdist f8e1fe3
if test "x${vmmn}" != "x%{mmn}"; then
d546d00
   : Error: Upstream MMN is now ${vmmn}, packaged MMN is %{mmn}
cvsdist f8e1fe3
   : Update the mmn macro and rebuild.
cvsdist f8e1fe3
   exit 1
cvsdist f8e1fe3
fi
cvsdist f8e1fe3
d546d00
: Building with MMN %{mmn}, MMN-ISA %{mmnisa} and vendor string '%{vstring}'
cvsdist 3ebc88d
cvsdist 739d054
%build
cvsdist 436bfeb
# forcibly prevent use of bundled apr, apr-util, pcre
cvsdist 436bfeb
rm -rf srclib/{apr,apr-util,pcre}
cvsdist 436bfeb
cvsdist 3cbd43b
# regenerate configure scripts
cvsdist 436bfeb
autoheader && autoconf || exit 1
cvsdist 3cbd43b
cvsdist f8e1fe3
# Before configure; fix location of build dir in generated apxs
cvsdist f8e1fe3
%{__perl} -pi -e "s:\@exp_installbuilddir\@:%{_libdir}/httpd/build:g" \
cvsdist f8e1fe3
	support/apxs.in
cvsdist f8e1fe3
e359920
export CFLAGS=$RPM_OPT_FLAGS
e359920
export LDFLAGS="-Wl,-z,relro,-z,now"
cvsdist f8e1fe3
e91269e
# Hard-code path to links to avoid unnecessary builddep
e91269e
export LYNX_PATH=/usr/bin/links
e91269e
bd3365e
# Build the daemon
3a44ff7
./configure \
cvsdist 3cbd43b
 	--prefix=%{_sysconfdir}/httpd \
cvsdist 3cbd43b
 	--exec-prefix=%{_prefix} \
cvsdist 3cbd43b
 	--bindir=%{_bindir} \
cvsdist 3cbd43b
 	--sbindir=%{_sbindir} \
cvsdist 3cbd43b
 	--mandir=%{_mandir} \
cvsdist f8e1fe3
	--libdir=%{_libdir} \
cvsdist 3cbd43b
	--sysconfdir=%{_sysconfdir}/httpd/conf \
cvsdist 3cbd43b
	--includedir=%{_includedir}/httpd \
cvsdist 3cbd43b
	--libexecdir=%{_libdir}/httpd/modules \
cvsdist 3cbd43b
	--datadir=%{contentdir} \
3a44ff7
        --enable-layout=Fedora \
cvsdist d48e904
        --with-installbuilddir=%{_libdir}/httpd/build \
3a44ff7
        --enable-mpms-shared=all \
cvsdist d48e904
        --with-apr=%{_prefix} --with-apr-util=%{_prefix} \
cvsdist 3cbd43b
	--enable-suexec --with-suexec \
cvsdist 3cbd43b
	--with-suexec-caller=%{suexec_caller} \
3a44ff7
	--with-suexec-docroot=%{docroot} \
cvsdist 3cbd43b
	--with-suexec-logfile=%{_localstatedir}/log/httpd/suexec.log \
cvsdist 3cbd43b
	--with-suexec-bin=%{_sbindir}/suexec \
cvsdist d48e904
	--with-suexec-uidmin=500 --with-suexec-gidmin=100 \
96e0b33
        --enable-pie \
96e0b33
        --with-pcre \
96e0b33
        --enable-mods-shared=all \
c187a27
	--enable-ssl --with-ssl --disable-distcache \
96e0b33
	--enable-proxy \
8a37bd4
        --enable-cache \
8a37bd4
        --enable-disk-cache \
96e0b33
        --enable-ldap --enable-authnz-ldap \
3a44ff7
        --enable-cgid --enable-cgi \
abfe86f
        --enable-authn-anon --enable-authn-alias \
3a44ff7
        --disable-imagemap  \
3a44ff7
        --disable-proxy-html \
3a44ff7
        --disable-xml2enc \
3a44ff7
        --disable-session
3a44ff7
	$*
3a44ff7
make %{?_smp_mflags}
c187a27
cvsdist 3cbd43b
%install
cvsdist 3cbd43b
rm -rf $RPM_BUILD_ROOT
cvsdist 3cbd43b
cvsdist 3cbd43b
make DESTDIR=$RPM_BUILD_ROOT install
cvsdist 3cbd43b
3a44ff7
# Install systemd service files
bd3365e
mkdir -p $RPM_BUILD_ROOT/lib/systemd/system
3a44ff7
install -p -m 644 $RPM_SOURCE_DIR/httpd.service \
bd3365e
        $RPM_BUILD_ROOT/lib/systemd/system/httpd.service
bd3365e
cvsdist 3cbd43b
# install conf file/directory
3a44ff7
mkdir $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d \
3a44ff7
      $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.modules.d
cvsdist 3cbd43b
install -m 644 $RPM_SOURCE_DIR/README.confd \
cvsdist f8aafff
    $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d/README
3a44ff7
for f in 00-base.conf 00-mpm.conf 00-lua.conf 01-cgi.conf 00-dav.conf \
3a44ff7
         00-proxy.conf 00-ssl.conf 00-ldap.conf; do
3a44ff7
  install -m 644 -p $RPM_SOURCE_DIR/$f \
3a44ff7
        $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.modules.d/$f
3a44ff7
done
3a44ff7
3a44ff7
for f in welcome.conf manual.conf ssl.conf userdir.conf; do
78b00cd
  install -m 644 -p $RPM_SOURCE_DIR/$f \
78b00cd
        $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d/$f
cvsdist f8aafff
done
cvsdist 3cbd43b
cvsdist 3cbd43b
rm $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf/*.conf
12462ec
install -m 644 -p $RPM_SOURCE_DIR/httpd.conf \
cvsdist 3cbd43b
   $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf/httpd.conf
cvsdist 3cbd43b
cvsdist e9bfb00
mkdir $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig
78b00cd
install -m 644 -p $RPM_SOURCE_DIR/httpd.sysconf \
cvsdist e9bfb00
   $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/httpd
cvsdist e9bfb00
da4346b
# tmpfiles.d configuration
da4346b
mkdir $RPM_BUILD_ROOT%{_sysconfdir}/tmpfiles.d 
da4346b
install -m 644 -p $RPM_SOURCE_DIR/httpd.tmpfiles \
da4346b
   $RPM_BUILD_ROOT%{_sysconfdir}/tmpfiles.d/httpd.conf
da4346b
cvsdist 3cbd43b
# for holding mod_dav lock database
cvsdist 3cbd43b
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/lib/dav
cvsdist 3cbd43b
cvsdist f13b38c
# create a prototype session cache
cvsdist f13b38c
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/cache/mod_ssl
cvsdist f13b38c
touch $RPM_BUILD_ROOT%{_localstatedir}/cache/mod_ssl/scache.{dir,pag,sem}
cvsdist f13b38c
cvsdist d48e904
# create cache root
cvsdist d48e904
mkdir $RPM_BUILD_ROOT%{_localstatedir}/cache/mod_proxy
cvsdist d48e904
cvsdist 6af796e
# Make the MMN accessible to module packages
d546d00
echo %{mmnisa} > $RPM_BUILD_ROOT%{_includedir}/httpd/.mmn
594bef6
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/rpm
3a44ff7
cat > $RPM_BUILD_ROOT%{_sysconfdir}/rpm/macros.httpd <
3a44ff7
%%_httpd_mmn %{mmnisa}
3a44ff7
%%_httpd_apxs %{_bindir}/apxs
3a44ff7
EOF
cvsdist 6af796e
3a44ff7
# Handle contentdir
3a44ff7
mkdir $RPM_BUILD_ROOT%{contentdir}/noindex
12462ec
install -m 644 -p $RPM_SOURCE_DIR/index.html \
3a44ff7
        $RPM_BUILD_ROOT%{contentdir}/noindex/index.html
3a44ff7
rm -rf %{contentdir}/htdocs
cvsdist d48e904
cvsdist d48e904
# remove manual sources
cvsdist d48e904
find $RPM_BUILD_ROOT%{contentdir}/manual \( \
cvsdist d48e904
    -name \*.xml -o -name \*.xml.* -o -name \*.ent -o -name \*.xsl -o -name \*.dtd \
cvsdist d48e904
    \) -print0 | xargs -0 rm -f
cvsdist 3cbd43b
2724cce
# Strip the manual down just to English and replace the typemaps with flat files:
2724cce
set +x
2724cce
for f in `find $RPM_BUILD_ROOT%{contentdir}/manual -name \*.html -type f`; do
2724cce
   if test -f ${f}.en; then
2724cce
      cp ${f}.en ${f}
2724cce
      rm ${f}.*
2724cce
   fi
2724cce
done
2724cce
set -x
2724cce
3a44ff7
# Clean Document Root
3a44ff7
rm -v $RPM_BUILD_ROOT%{docroot}/html/*.html \
3a44ff7
      $RPM_BUILD_ROOT%{docroot}/cgi-bin/*
3a44ff7
78b00cd
# Symlink for the powered-by-$DISTRO image:
78b00cd
ln -s ../../..%{_datadir}/pixmaps/poweredby.png \
78b00cd
        $RPM_BUILD_ROOT%{contentdir}/icons/poweredby.png
cvsdist 3cbd43b
cvsdist 3cbd43b
# symlinks for /etc/httpd
cvsdist 3cbd43b
ln -s ../..%{_localstatedir}/log/httpd $RPM_BUILD_ROOT/etc/httpd/logs
f47f283
ln -s ../..%{_localstatedir}/run/httpd $RPM_BUILD_ROOT/etc/httpd/run
cvsdist 3cbd43b
ln -s ../..%{_libdir}/httpd/modules $RPM_BUILD_ROOT/etc/httpd/modules
cvsdist 3cbd43b
Jan Kaluza 2673a43
# install http-ssl-pass-dialog
Jan Kaluza 2673a43
mkdir -p $RPM_BUILD_ROOT/%{_libexecdir}
Jan Kaluza 2673a43
install -m755 $RPM_SOURCE_DIR/httpd-ssl-pass-dialog \
Jan Kaluza 2673a43
	$RPM_BUILD_ROOT/%{_libexecdir}/httpd-ssl-pass-dialog
Jan Kaluza 2673a43
cvsdist 3cbd43b
# install log rotation stuff
cvsdist 3cbd43b
mkdir -p $RPM_BUILD_ROOT/etc/logrotate.d
78b00cd
install -m 644 -p $RPM_SOURCE_DIR/httpd.logrotate \
cvsdist 3cbd43b
	$RPM_BUILD_ROOT/etc/logrotate.d/httpd
cvsdist 3cbd43b
cvsdist 3cbd43b
# fix man page paths
cvsdist 3cbd43b
sed -e "s|/usr/local/apache2/conf/httpd.conf|/etc/httpd/conf/httpd.conf|" \
cvsdist 3cbd43b
    -e "s|/usr/local/apache2/conf/mime.types|/etc/mime.types|" \
cvsdist 3cbd43b
    -e "s|/usr/local/apache2/conf/magic|/etc/httpd/conf/magic|" \
cvsdist 3cbd43b
    -e "s|/usr/local/apache2/logs/error_log|/var/log/httpd/error_log|" \
cvsdist 3cbd43b
    -e "s|/usr/local/apache2/logs/access_log|/var/log/httpd/access_log|" \
110f0ad
    -e "s|/usr/local/apache2/logs/httpd.pid|/var/run/httpd/httpd.pid|" \
cvsdist 3cbd43b
    -e "s|/usr/local/apache2|/etc/httpd|" < docs/man/httpd.8 \
cvsdist 3cbd43b
  > $RPM_BUILD_ROOT%{_mandir}/man8/httpd.8
cvsdist 3cbd43b
48593e5
# Make ap_config_layout.h libdir-agnostic
48593e5
sed -i '/.*DEFAULT_..._LIBEXECDIR/d;/DEFAULT_..._INSTALLBUILDDIR/d' \
48593e5
    $RPM_BUILD_ROOT%{_includedir}/httpd/ap_config_layout.h
48593e5
e91269e
# Fix path to instdso in special.mk
e91269e
sed -i '/instdso/s,top_srcdir,top_builddir,' \
e91269e
    $RPM_BUILD_ROOT%{_libdir}/httpd/build/special.mk
e91269e
cvsdist f8e1fe3
# Remove unpackaged files
cvsdist d48e904
rm -f $RPM_BUILD_ROOT%{_libdir}/*.exp \
cvsdist f8e1fe3
      $RPM_BUILD_ROOT/etc/httpd/conf/mime.types \
cvsdist f8e1fe3
      $RPM_BUILD_ROOT%{_libdir}/httpd/modules/*.exp \
cvsdist 2d6a2e5
      $RPM_BUILD_ROOT%{_libdir}/httpd/build/config.nice \
cvsdist f8e1fe3
      $RPM_BUILD_ROOT%{_bindir}/ap?-config \
cvsdist f8e1fe3
      $RPM_BUILD_ROOT%{_sbindir}/{checkgid,dbmmanage,envvars*} \
cvsdist f8e1fe3
      $RPM_BUILD_ROOT%{contentdir}/htdocs/* \
cvsdist 6356941
      $RPM_BUILD_ROOT%{_mandir}/man1/dbmmanage.* \
cvsdist 6356941
      $RPM_BUILD_ROOT%{contentdir}/cgi-bin/*
cvsdist f8e1fe3
96e0b33
rm -rf $RPM_BUILD_ROOT/etc/httpd/conf/{original,extra}
96e0b33
cvsdist 6356941
# Make suexec a+rw so it can be stripped.  %%files lists real permissions
cvsdist 6356941
chmod 755 $RPM_BUILD_ROOT%{_sbindir}/suexec
cvsdist 6356941
cvsdist 3cbd43b
%pre
cvsdist 3cbd43b
# Add the "apache" user
cvsdist 3cbd43b
/usr/sbin/useradd -c "Apache" -u 48 \
cvsdist 3cbd43b
	-s /sbin/nologin -r -d %{contentdir} apache 2> /dev/null || :
cvsdist 3cbd43b
cvsdist 3cbd43b
%post
cvsdist 3cbd43b
# Register the httpd service
ce009f9
if [ $1 -eq 1 ] ; then 
ce009f9
    # Initial installation 
ce009f9
    /bin/systemctl daemon-reload >/dev/null 2>&1 || :
ce009f9
fi
cvsdist 3cbd43b
cvsdist 3cbd43b
%preun
ce009f9
if [ $1 -eq 0 ] ; then
ce009f9
    # Package removal, not upgrade
ce009f9
    /bin/systemctl --no-reload disable %{all_services} > /dev/null 2>&1 || :
ce009f9
    /bin/systemctl stop %{all_services} > /dev/null 2>&1 || :
cvsdist 3cbd43b
fi
cvsdist 3cbd43b
ce009f9
%postun
ce009f9
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
ce009f9
ce009f9
# Trigger for conversion from SysV, per guidelines at:
ce009f9
# https://fedoraproject.org/wiki/Packaging:ScriptletSnippets#Systemd
ce009f9
%triggerun -- httpd < 2.2.21-5
ce009f9
# Save the current service runlevel info
ce009f9
# User must manually run systemd-sysv-convert --apply httpd
ce009f9
# to migrate them to systemd targets
ce009f9
/usr/bin/systemd-sysv-convert --save httpd.service >/dev/null 2>&1 ||:
ce009f9
ce009f9
# Run these because the SysV package being removed won't do them
ce009f9
/sbin/chkconfig --del httpd >/dev/null 2>&1 || :
ce009f9
b2a4380
%posttrans
3a44ff7
/bin/systemctl try-restart httpd.service >/dev/null 2>&1 || :
b2a4380
670541e
%define sslcert %{_sysconfdir}/pki/tls/certs/localhost.crt
670541e
%define sslkey %{_sysconfdir}/pki/tls/private/localhost.key
06872c8
cvsdist 3cbd43b
%post -n mod_ssl
cvsdist 3cbd43b
umask 077
cvsdist 3cbd43b
ce009f9
if [ -f %{sslkey} -o -f %{sslcert} ]; then
ce009f9
   exit 0
cvsdist 3cbd43b
fi
cvsdist 3cbd43b
ce009f9
%{_bindir}/openssl genrsa -rand /proc/apm:/proc/cpuinfo:/proc/dma:/proc/filesystems:/proc/interrupts:/proc/ioports:/proc/pci:/proc/rtc:/proc/uptime 1024 > %{sslkey} 2> /dev/null
ce009f9
cvsdist 3cbd43b
FQDN=`hostname`
cvsdist 3cbd43b
if [ "x${FQDN}" = "x" ]; then
cvsdist 3cbd43b
   FQDN=localhost.localdomain
cvsdist 3cbd43b
fi
cvsdist 3cbd43b
670541e
cat << EOF | %{_bindir}/openssl req -new -key %{sslkey} \
c187a27
         -x509 -days 365 -set_serial $RANDOM -extensions v3_req \
670541e
         -out %{sslcert} 2>/dev/null
cvsdist 3cbd43b
--
cvsdist 3cbd43b
SomeState
cvsdist 3cbd43b
SomeCity
cvsdist 3cbd43b
SomeOrganization
cvsdist 3cbd43b
SomeOrganizationalUnit
cvsdist 3cbd43b
${FQDN}
cvsdist 3cbd43b
root@${FQDN}
cvsdist 3cbd43b
EOF
cvsdist 3cbd43b
cvsdist d48e904
%check
cvsdist d48e904
# Check the built modules are all PIC
cvsdist d48e904
if readelf -d $RPM_BUILD_ROOT%{_libdir}/httpd/modules/*.so | grep TEXTREL; then
cvsdist d48e904
   : modules contain non-relocatable code
cvsdist d48e904
   exit 1
cvsdist d48e904
fi
cvsdist d48e904
cvsdist 3cbd43b
%clean
cvsdist 3cbd43b
rm -rf $RPM_BUILD_ROOT
cvsdist 3cbd43b
cvsdist 3cbd43b
%files
cvsdist 3cbd43b
%defattr(-,root,root)
cvsdist 3cbd43b
cvsdist d01424a
%doc ABOUT_APACHE README CHANGES LICENSE VERSIONING NOTICE
cvsdist 3cbd43b
cvsdist 3cbd43b
%dir %{_sysconfdir}/httpd
cvsdist 3cbd43b
%{_sysconfdir}/httpd/modules
cvsdist 3cbd43b
%{_sysconfdir}/httpd/logs
cvsdist 3cbd43b
%{_sysconfdir}/httpd/run
cvsdist 3cbd43b
%dir %{_sysconfdir}/httpd/conf
a980810
%config(noreplace) %{_sysconfdir}/httpd/conf/httpd.conf
cvsdist 3cbd43b
%config(noreplace) %{_sysconfdir}/httpd/conf/magic
cvsdist 3cbd43b
cvsdist d48e904
%config(noreplace) %{_sysconfdir}/logrotate.d/httpd
cvsdist 3cbd43b
cvsdist 3cbd43b
%dir %{_sysconfdir}/httpd/conf.d
cvsdist 3cbd43b
%{_sysconfdir}/httpd/conf.d/README
3a44ff7
%config(noreplace) %{_sysconfdir}/httpd/conf.d/welcome.conf
3a44ff7
%config(noreplace) %{_sysconfdir}/httpd/conf.d/userdir.conf
3a44ff7
3a44ff7
%dir %{_sysconfdir}/httpd/conf.modules.d
3a44ff7
%config(noreplace) %{_sysconfdir}/httpd/conf.modules.d/*.conf
3a44ff7
%exclude %{_sysconfdir}/httpd/conf.modules.d/00-ssl.conf
cvsdist 3cbd43b
cvsdist e9bfb00
%config(noreplace) %{_sysconfdir}/sysconfig/httpd
da4346b
%config %{_sysconfdir}/tmpfiles.d/httpd.conf
cvsdist e9bfb00
96e0b33
%{_sbindir}/ht*
3a44ff7
%{_sbindir}/fcgistarter
cvsdist 3cbd43b
%{_sbindir}/apachectl
cvsdist 3cbd43b
%{_sbindir}/rotatelogs
Jan Kaluza a1caf8d
# cap_dac_override needed to write to /var/log/httpd
Jan Kaluza a1caf8d
%caps(cap_setuid,cap_setgid,cap_dac_override+pe) %attr(510,root,%{suexec_caller}) %{_sbindir}/suexec
cvsdist 3cbd43b
cvsdist 3cbd43b
%dir %{_libdir}/httpd
cvsdist 3cbd43b
%dir %{_libdir}/httpd/modules
cvsdist 6356941
%{_libdir}/httpd/modules/mod*.so
cvsdist 6356941
%exclude %{_libdir}/httpd/modules/mod_ssl.so
cvsdist 3cbd43b
cvsdist 3cbd43b
%dir %{contentdir}
cvsdist 3cbd43b
%dir %{contentdir}/icons
cvsdist d5ddf48
%dir %{contentdir}/error
cvsdist d5ddf48
%dir %{contentdir}/error/include
3a44ff7
%dir %{contentdir}/noindex
cvsdist 3cbd43b
%{contentdir}/icons/*
cvsdist d5ddf48
%{contentdir}/error/README
3a44ff7
%{contentdir}/error/*.var
3a44ff7
%{contentdir}/error/include/*.html
3a44ff7
%{contentdir}/noindex/index.html
3a44ff7
3a44ff7
%dir %{docroot}/cgi-bin
3a44ff7
%dir %{docroot}/html
cvsdist 3cbd43b
ba94879
%attr(0710,root,apache) %dir %{_localstatedir}/run/httpd
cvsdist 3cbd43b
%attr(0700,root,root) %dir %{_localstatedir}/log/httpd
cvsdist 3cbd43b
%attr(0700,apache,apache) %dir %{_localstatedir}/lib/dav
cvsdist d48e904
%attr(0700,apache,apache) %dir %{_localstatedir}/cache/mod_proxy
cvsdist 3cbd43b
8499915
%{_mandir}/man8/*
cvsdist 3cbd43b
bd3365e
/lib/systemd/system/*.service
bd3365e
8499915
%files tools
8499915
%defattr(-,root,root)
8499915
%{_bindir}/*
8499915
%{_mandir}/man1/*
3383664
%doc LICENSE NOTICE
3a44ff7
%exclude %{_bindir}/apxs
8499915
cvsdist 3cbd43b
%files manual
cvsdist 3cbd43b
%defattr(-,root,root)
cvsdist 3cbd43b
%{contentdir}/manual
3a44ff7
%config(noreplace) %{_sysconfdir}/httpd/conf.d/manual.conf
cvsdist 3cbd43b
cvsdist 3cbd43b
%files -n mod_ssl
cvsdist 3cbd43b
%defattr(-,root,root)
cvsdist 3cbd43b
%{_libdir}/httpd/modules/mod_ssl.so
3a44ff7
%config(noreplace) %{_sysconfdir}/httpd/conf.modules.d/00-ssl.conf
cvsdist 3cbd43b
%config(noreplace) %{_sysconfdir}/httpd/conf.d/ssl.conf
cvsdist f13b38c
%attr(0700,apache,root) %dir %{_localstatedir}/cache/mod_ssl
cvsdist f13b38c
%attr(0600,apache,root) %ghost %{_localstatedir}/cache/mod_ssl/scache.dir
cvsdist f13b38c
%attr(0600,apache,root) %ghost %{_localstatedir}/cache/mod_ssl/scache.pag
cvsdist f13b38c
%attr(0600,apache,root) %ghost %{_localstatedir}/cache/mod_ssl/scache.sem
Jan Kaluza 2673a43
%{_libexecdir}/httpd-ssl-pass-dialog
cvsdist 3cbd43b
cvsdist 3cbd43b
%files devel
cvsdist 3cbd43b
%defattr(-,root,root)
cvsdist 3cbd43b
%{_includedir}/httpd
3a44ff7
%{_bindir}/apxs
61679dd
%{_mandir}/man1/apxs.1*
cvsdist 3cbd43b
%dir %{_libdir}/httpd/build
cvsdist 3cbd43b
%{_libdir}/httpd/build/*.mk
96e0b33
%{_libdir}/httpd/build/*.sh
594bef6
%{_sysconfdir}/rpm/macros.httpd
cvsdist 3cbd43b
cvsdist 3cbd43b
%changelog
3a44ff7
* Tue Mar  6 2012 Joe Orton <jorton@redhat.com> - 2.4.1-1
3a44ff7
- update to 2.4.1
3a44ff7
- adopt upstream default httpd.conf (almost verbatim)
3a44ff7
- split all LoadModules to conf.modules.d/*.conf
3a44ff7
- include conf.d/*.conf at end of httpd.conf
3a44ff7
- trim %%changelog
3a44ff7
15553f5
* Mon Feb 13 2012 Joe Orton <jorton@redhat.com> - 2.2.22-2
15553f5
- fix build against PCRE 8.30
15553f5
8e77f79
* Mon Feb 13 2012 Joe Orton <jorton@redhat.com> - 2.2.22-1
8e77f79
- update to 2.2.22
8e77f79
056bf1c
* Fri Feb 10 2012 Petr Pisar <ppisar@redhat.com> - 2.2.21-8
056bf1c
- Rebuild against PCRE 8.30
056bf1c
Jan Kaluza a942213
* Mon Jan 23 2012 Jan Kaluza <jkaluza@redhat.com> - 2.2.21-7
Jan Kaluza a942213
- fix #783629 - start httpd after named
Jan Kaluza a942213
ce009f9
* Mon Jan 16 2012 Joe Orton <jorton@redhat.com> - 2.2.21-6
ce009f9
- complete conversion to systemd, drop init script (#770311)
ce009f9
- fix comments in /etc/sysconfig/httpd (#771024)
ce009f9
- enable PrivateTmp in service file (#781440)
ce009f9
- set LANG=C in /etc/sysconfig/httpd
ce009f9
ba7fac9
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.2.21-5
ba7fac9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
ba7fac9
Jan Kaluza 5f89498
* Tue Dec 06 2011 Jan Kaluza <jkaluza@redhat.com> - 2.2.21-4
Jan Kaluza 5f89498
- fix #751591 - start httpd after remote-fs
Jan Kaluza 5f89498
Jan Kaluza 7d4330a
* Mon Oct 24 2011 Jan Kaluza <jkaluza@redhat.com> - 2.2.21-3
Jan Kaluza 7d4330a
- allow change state of BalancerMember in mod_proxy_balancer web interface
Jan Kaluza 7d4330a
594bef6
* Thu Sep 22 2011 Ville Skyttä <ville.skytta@iki.fi> - 2.2.21-2
594bef6
- Make mmn available as %%{_httpd_mmn}.
fee4dde
- Add .svgz to AddEncoding x-gzip example in httpd.conf.
594bef6
f93baaa
* Tue Sep 13 2011 Joe Orton <jorton@redhat.com> - 2.2.21-1
f93baaa
- update to 2.2.21
f93baaa
e6f446d
* Mon Sep  5 2011 Joe Orton <jorton@redhat.com> - 2.2.20-1
e6f446d
- update to 2.2.20
fc68d49
- fix MPM stub man page generation
e6f446d
Jan Kaluza 2673a43
* Wed Aug 10 2011 Jan Kaluza <jkaluza@redhat.com> - 2.2.19-5
Jan Kaluza 2673a43
- fix #707917 - add httpd-ssl-pass-dialog to ask for SSL password using systemd
Jan Kaluza 2673a43
badeb4a
* Fri Jul 22 2011 Iain Arnell <iarnell@gmail.com> 1:2.2.19-4
badeb4a
- rebuild while rpm-4.9.1 is untagged to remove trailing slash in provided
badeb4a
  directory names
badeb4a
Jan Kaluza a1caf8d
* Wed Jul 20 2011 Jan Kaluza <jkaluza@redhat.com> - 2.2.19-3
Jan Kaluza a1caf8d
- fix #716621 - suexec now works without setuid bit
Jan Kaluza a1caf8d
Jan Kaluza 39b84c6
* Thu Jul 14 2011 Jan Kaluza <jkaluza@redhat.com> - 2.2.19-2
Jan Kaluza 39b84c6
- fix #689091 - backported patch from 2.3 branch to support IPv6 in logresolve
Jan Kaluza 39b84c6
5ac19f6
* Fri Jul  1 2011 Joe Orton <jorton@redhat.com> - 2.2.19-1
5ac19f6
- update to 2.2.19
5ac19f6
- enable dbd, authn_dbd in default config
5ac19f6
df147d5
* Thu Apr 14 2011 Joe Orton <jorton@redhat.com> - 2.2.17-13
df147d5
- fix path expansion in service files
df147d5
bd3365e
* Tue Apr 12 2011 Joe Orton <jorton@redhat.com> - 2.2.17-12
bd3365e
- add systemd service files (#684175, thanks to Jóhann B. Guðmundsson)
bd3365e
718c836
* Wed Mar 23 2011 Joe Orton <jorton@redhat.com> - 2.2.17-11
718c836
- minor updates to httpd.conf
718c836
- drop old patches
718c836
f334064
* Wed Mar  2 2011 Joe Orton <jorton@redhat.com> - 2.2.17-10
f334064
- rebuild
f334064
1c70e18
* Wed Feb 23 2011 Joe Orton <jorton@redhat.com> - 2.2.17-9
d546d00
- use arch-specific mmn
d546d00
f6428e0
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.2.17-8
f6428e0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
f6428e0
c187a27
* Mon Jan 31 2011 Joe Orton <jorton@redhat.com> - 2.2.17-7
c187a27
- generate dummy mod_ssl cert with CA:FALSE constraint (#667841)
c187a27
- add man page stubs for httpd.event, httpd.worker
c187a27
- drop distcache support
c187a27
- add STOP_TIMEOUT support to init script
c187a27
0e9583d
* Sat Jan  8 2011 Joe Orton <jorton@redhat.com> - 2.2.17-6
0e9583d
- update default SSLCipherSuite per upstream trunk
0e9583d
9bdb50e
* Wed Jan  5 2011 Joe Orton <jorton@redhat.com> - 2.2.17-5
9bdb50e
- fix requires (#667397)
9bdb50e
ba94879
* Wed Jan  5 2011 Joe Orton <jorton@redhat.com> - 2.2.17-4
ba94879
- de-ghost /var/run/httpd
ba94879
da4346b
* Tue Jan  4 2011 Joe Orton <jorton@redhat.com> - 2.2.17-3
da4346b
- add tmpfiles.d configuration, ghost /var/run/httpd (#656600)
da4346b
38e4a75
* Sat Nov 20 2010 Joe Orton <jorton@redhat.com> - 2.2.17-2
38e4a75
- drop setuid bit, use capabilities for suexec binary
38e4a75
ec012a6
* Wed Oct 27 2010 Joe Orton <jorton@redhat.com> - 2.2.17-1
ec012a6
- update to 2.2.17
ec012a6
e359920
* Fri Sep 10 2010 Joe Orton <jorton@redhat.com> - 2.2.16-2
e359920
- link everything using -z relro and -z now
e359920
57af27d
* Mon Jul 26 2010 Joe Orton <jorton@redhat.com> - 2.2.16-1
57af27d
- update to 2.2.16
57af27d
3383664
* Fri Jul  9 2010 Joe Orton <jorton@redhat.com> - 2.2.15-3
3383664
- default config tweaks:
3383664
 * harden httpd.conf w.r.t. .htaccess restriction (#591293)
3383664
 * load mod_substitute, mod_version by default
3383664
 * drop proxy_ajp.conf, load mod_proxy_ajp in httpd.conf
3383664
 * add commented list of shipped-but-unloaded modules
3383664
 * bump up worker defaults a little
3383664
 * drop KeepAliveTimeout to 5 secs per upstream
3383664
- fix LSB compliance in init script (#522074)
3383664
- bundle NOTICE in -tools
3383664
- use init script in logrotate postrotate to pick up PIDFILE
3383664
- drop some old Obsoletes/Conflicts
3383664
0cb0f7f
* Sun Apr 04 2010 Robert Scheck <robert@fedoraproject.org> - 2.2.15-1
0cb0f7f
- update to 2.2.15 (#572404, #579311)
0cb0f7f