Sophie

Sophie

distrib > Fedora > 16 > x86_64 > by-pkgid > fb5804936515ec870d0dadd1967167a0 > files > 6

boa-0.94.14-0.16.rc21.fc15.src.rpm

%define rcver rc21
%define webroot /var/www/boa

Summary: Single-tasking HTTP server
Name: boa
Version: 0.94.14
Release: 0.16%{?rcver:.%{rcver}}%{?dist}
License: GPLv2+
Group: System Environment/Daemons
URL: http://www.boa.org/
Source0: http://www.boa.org/boa-%{version}%{?rcver}.tar.bz2
Source1: boa.init
Source2: boa.sysconfig
Source10: index.html
Source11: boa_logo_pasi2.png
Patch0: boa-0.94.14rc21-config.patch
Patch1: boa-0.94.14rc21-cgi.c.patch
Patch2: boa-0.94.14rc21-escape-errorlog.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
Requires: system-logos >= 7.92.1
Requires(pre): /usr/sbin/useradd
Requires(post): /sbin/chkconfig
Requires(preun): /sbin/service, /sbin/chkconfig
Requires(postun): /sbin/service
Requires: gzip
Requires: /etc/mime.types
BuildRequires: tetex, texinfo
Provides: webserver

%description
Boa is a single-tasking HTTP server. That means that unlike traditional web
servers, it does not fork for each incoming connection, nor does it fork many
copies of itself to handle multiple connections. It internally multiplexes
all of the ongoing HTTP connections, and forks only for CGI programs (which
must be separate processes), automatic directory generation, and automatic
file gunzipping.
The primary design goals of Boa are speed and security. Security, in the sense
of "can't be subverted by a malicious user," not "fine grained access control
and encrypted communications". Boa is not intended as a feature-packed server.

Available rpmbuild rebuild options :
--with : debug access poll
--without : gunzip sendfile


%prep
%setup -q -n %{name}-%{version}%{?rcver}
%patch0 -p1 -b .config
%patch1 -p1 -b .cgi.c
%patch2 -p1 -b .escape-errorlog


%build
%configure \
    %{!?_with_debug:      --disable-debug} \
    %{?_with_access:      --enable-access-control} \
    %{?_with_poll:        --with-poll} \
    %{?_without_gunzip:   --disable-gunzip} \
    %{?_without_sendfile: --disable-sendfile}
%{__make} %{?_smp_mflags}
%{__make} -C docs boa.html boa.txt


%install
%{__rm} -rf %{buildroot}
# Manual install is still mandatory
%{__install} -p -m 0755 -D src/boa \
    %{buildroot}%{_sbindir}/boa
%{__install} -p -m 0755 -D src/boa_indexer \
    %{buildroot}%{_libexecdir}/boa/boa_indexer
%{__install} -p -m 0644 -D docs/boa.8 \
    %{buildroot}%{_mandir}/man8/boa.8
%{__install} -p -m 0644 -D examples/boa.conf \
    %{buildroot}%{_sysconfdir}/boa/boa.conf
%{__install} -p -m 0644 -D contrib/rpm/boa.logrotate \
    %{buildroot}%{_sysconfdir}/logrotate.d/boa
%{__install} -p -m 0755 -D %{SOURCE1} \
    %{buildroot}%{_sysconfdir}/rc.d/init.d/boa
%{__install} -p -m 0644 -D %{SOURCE2} \
    %{buildroot}%{_sysconfdir}/sysconfig/boa

%{__mkdir_p} %{buildroot}/%{webroot}/{cgi-bin,html}
%{__mkdir_p} %{buildroot}/%{_var}/log/boa

# Install the default index.html file
%{__install} -p -m 0644 %{SOURCE10} %{SOURCE11} \
    %{buildroot}%{webroot}/html/

# Symlink for the powered-by-$DISTRO image
%{__ln_s} %{_datadir}/pixmaps/poweredby.png \
    %{buildroot}%{webroot}/html/poweredby.png

# Avoid automatic picking up of perl dependency
%{__chmod} -x examples/*.{cgi,pl}


%clean
%{__rm} -rf %{buildroot}


%pre
/usr/sbin/useradd -s /sbin/nologin -M -r -d %{webroot} \
    -c "boa web server" boa &>/dev/null || :

%post
if [ $1 -eq 1 ]; then
    /sbin/chkconfig --add boa
fi

%preun
if [ $1 -eq 0 ]; then
    /sbin/service boa stop &>/dev/null || :
    /sbin/chkconfig --del boa
fi

%postun
if [ $1 -ge 1 ]; then
    /sbin/service boa condrestart &>/dev/null || :
fi


%files
%defattr(-,root,root,-)
%doc COPYING CREDITS README
%doc docs/*.{html,png,txt} examples/
%dir %{_sysconfdir}/boa/
%config(noreplace) %{_sysconfdir}/boa/boa.conf
%config(noreplace) %{_sysconfdir}/logrotate.d/boa
%config(noreplace) %{_sysconfdir}/sysconfig/boa
%{_sysconfdir}/rc.d/init.d/boa
%dir %{_libexecdir}/boa/
%{_libexecdir}/boa/boa_indexer
%{_sbindir}/boa
%{webroot}/
%dir %{_var}/log/boa/
%{_mandir}/man8/*


%changelog
* Mon Feb 07 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.94.14-0.16.rc21
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild

* Wed Apr 28 2010 Matthias Saou <http://freshrpms.net/> 0.94.14-0.15.rc21
- Include escape-errorlog patch from Debian to fix CVE-2009-4496 (#583162).

* Tue Nov 24 2009 Matthias Saou <http://freshrpms.net/> 0.94.14-0.14.rc21
- Fix last minute init script breakage from the lat changes (#527582).

* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.94.14-0.13.rc21
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild

* Sun Apr 12 2009 Matthias Saou <http://freshrpms.net/> 0.94.14-0.12.rc21
- Update init script to the new style.
- Move boa_indexer to libexec, as it makes more sense there.
- Fix cgi-bin location in the config patch.

* Mon Feb 23 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org>
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild

* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org>
- Autorebuild for GCC 4.3

* Mon Oct 22 2007 Matthias Saou <http://freshrpms.net/> 0.94.14-0.9.rc21
- Remove trademarked Fedora image and symlink to the one from system-logos.
- Switch webroot back from /srv to /var.
- Update default index.html to UTF-8.

* Wed Aug 22 2007 Matthias Saou <http://freshrpms.net/> 0.94.14-0.8.rc21
- Rebuild for new BuildID feature.

* Mon Aug  6 2007 Matthias Saou <http://freshrpms.net/> 0.94.14-0.7.rc21
- Include cgi.c patch to fix env. variable dump (#250950, Jose Pedro Oliveira).
- Update license field.

* Tue Jun 19 2007 Matthias Saou <http://freshrpms.net/> 0.94.14-0.6.rc21
- Switch to using .bz2 sources.
- Add missing scriplet requirements.
- Switch webroot to /srv/www/boa.
- Change user creation to create its own "boa" group instead of "www".
- Update config patch to match updates.
- Create empty default cgi-bin directory.
- Fix sysconfig file mode (755 -> 644).

* Mon Aug 28 2006 Matthias Saou <http://freshrpms.net/> 0.94.14-0.5.rc21
- FC6 rebuild, remove gzip build requirement (it's a default).

* Mon Mar  6 2006 Matthias Saou <http://freshrpms.net/> 0.94.14-0.4.rc21
- FC5 rebuild.

* Wed Feb  8 2006 Matthias Saou <http://freshrpms.net/> 0.94.14-0.3.rc21
- Rebuild for new gcc/glibc.

* Wed Nov 16 2005 Matthias Saou <http://freshrpms.net/> 0.94.14-0.2.rc21
- Make example cgi scripts -x to avoid perl dependency side-effect (#173335).

* Sat Apr 16 2005 Seth Vidal <skvidal at phy.duke.edu> 0.94.14-0.1.rc21
- tar.gz not tar.bz2

* Thu Apr 14 2005 Matthias Saou <http://freshrpms.net/> 0.94.14-0.1.rc21
- Update to 0.94.14rc21.
- Change release tag "order" to comply with guidelines (extra info at the end).
- Change _initrddir (which I still see as plain wrong) to /etc/rc.d/init.d.
- Replace freshrpms logo with fedora one.
- Change flashy green from the default index.html to plain white.
- Minor spec file cosmetic changes.

* Fri Apr  7 2005 Michael Schwendt <mschwendt[AT]users.sf.net> 0.94.14-0.rc17.3
- rebuilt

* Mon Feb 14 2005 Ville Skyttä <ville.skytta at iki.fi> - 0.94.14-0.rc17.2
- Build only installed docs, avoids build failure with boa.dvi.
- Drop .fr release suffix.

* Wed Oct 22 2003 Matthias Saou <matthias.saou@est.une.marmotte.net>
- Initial package.