Blame SPECS/mod_revocator.spec

e7e179
%{!?_httpd_apxs:       %{expand: %%global _httpd_apxs       %%{_sbindir}/apxs}}
e7e179
%{!?_httpd_confdir:    %{expand: %%global _httpd_confdir    %%{_sysconfdir}/httpd/conf.d}}
e7e179
# /etc/httpd/conf.d with httpd < 2.4 and defined as /etc/httpd/conf.modules.d with httpd >= 2.4
e7e179
%{!?_httpd_modconfdir: %{expand: %%global _httpd_modconfdir %%{_sysconfdir}/httpd/conf.d}}
e7e179
e7e179
Name: mod_revocator
e7e179
Version: 1.0.3
e7e179
Release: 21%{?dist}
e7e179
Summary: CRL retrieval module for the Apache HTTP server
e7e179
Group: System Environment/Daemons
e7e179
License: ASL 2.0
e7e179
URL: https://fedorahosted.org/mod_revocator/
e7e179
Source: http://directory.fedoraproject.org/sources/%{name}-%{version}.tar.gz
e7e179
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
e7e179
BuildRequires: nspr-devel >= 4.6, nss-devel >= 3.11.9
e7e179
BuildRequires: nss-pkcs11-devel >= 3.11
e7e179
BuildRequires: nss-pkcs11-devel-static
e7e179
BuildRequires: httpd-devel >= 0:2.0.52, apr-devel, apr-util-devel
e7e179
BuildRequires: pkgconfig, autoconf, automake, libtool
e7e179
BuildRequires: openldap-devel >= 2.2.29
e7e179
Requires: mod_nss >= 1.0.8
e7e179
Patch1: mod_revocator-libpath.patch
e7e179
Patch2: mod_revocator-kill.patch
e7e179
Patch3: mod_revocator-segfault-fix.patch
e7e179
Patch4: mod_revocator-32-bit-semaphore-fix.patch
e7e179
Patch5: mod_revocator-array-size.patch
e7e179
Patch6: mod_revocator-waitpid.patch
e7e179
Patch7: mod_revocator-man.patch
e7e179
# Clean up semaphore on shutdown
e7e179
Patch8: mod_revocator-clean-semaphore.patch
e7e179
e7e179
%description
e7e179
The mod_revocator module retrieves and installs remote
e7e179
Certificate Revocate Lists (CRLs) into an Apache web server. 
e7e179
e7e179
%prep
e7e179
%setup -q
e7e179
%patch1 -p1
e7e179
%patch2 -p1
e7e179
%patch3 -p1
e7e179
%patch4 -p1
e7e179
%patch5 -p1
e7e179
%patch6 -p1
e7e179
%patch7 -p1
e7e179
%patch8 -p1
e7e179
e7e179
%build
e7e179
autoreconf -fvi
e7e179
e7e179
# Needed for ppc64, automake can't be run here
e7e179
for file in %{_datadir}/automake-*/config.{guess,sub}
e7e179
do
e7e179
    cp -f $file .
e7e179
done
e7e179
e7e179
CFLAGS="$RPM_OPT_FLAGS"
e7e179
export CFLAGS
e7e179
e7e179
NSPR_INCLUDE_DIR=`/usr/bin/pkg-config --variable=includedir nspr`
e7e179
NSPR_LIB_DIR=`/usr/bin/pkg-config --variable=libdir nspr`
e7e179
e7e179
NSS_INCLUDE_DIR=`/usr/bin/pkg-config --variable=includedir nss`
e7e179
NSS_LIB_DIR=`/usr/bin/pkg-config --variable=libdir nss`
e7e179
e7e179
NSS_BIN=`/usr/bin/pkg-config --variable=exec_prefix nss`
e7e179
e7e179
%configure \
e7e179
    --with-nss-lib=$NSS_LIB_DIR \
e7e179
    --with-nss-inc=$NSS_INCLUDE_DIR \
e7e179
    --with-nspr-lib=$NSPR_LIB_DIR \
e7e179
    --with-nspr-inc=$NSPR_INCLUDE_DIR \
e7e179
    --with-apr-config --enable-openldap \
e7e179
    --with-apxs=%{_httpd_apxs}
e7e179
e7e179
make %{?_smp_flags} all
e7e179
e7e179
%install
e7e179
# The install target of the Makefile isn't used because that uses apxs
e7e179
# which tries to enable the module in the build host httpd instead of in
e7e179
# the build root.
e7e179
rm -rf $RPM_BUILD_ROOT
e7e179
e7e179
mkdir -p $RPM_BUILD_ROOT%{_httpd_confdir} $RPM_BUILD_ROOT%{_httpd_modconfdir} \
e7e179
       $RPM_BUILD_ROOT%{_libdir}/httpd/modules $RPM_BUILD_ROOT%{_bindir}      \
e7e179
       $RPM_BUILD_ROOT%{_libexecdir} $RPM_BUILD_ROOT%{_sbindir}               \
e7e179
       $RPM_BUILD_ROOT%{_mandir}/man8
e7e179
e7e179
%if "%{_httpd_modconfdir}" != "%{_httpd_confdir}"
e7e179
# httpd >= 2.4.x
e7e179
sed -n /^LoadModule/p revocator.conf > 11-revocator.conf
e7e179
sed -i /^LoadModule/d revocator.conf
e7e179
install -m 644 11-revocator.conf $RPM_BUILD_ROOT%{_httpd_modconfdir}/11-revocator.conf
e7e179
%endif
e7e179
install -m 644 revocator.conf $RPM_BUILD_ROOT%{_httpd_confdir}/revocator.conf
e7e179
install -m 755 .libs/libmodrev.so $RPM_BUILD_ROOT%{_libdir}/httpd/modules/mod_rev.so
e7e179
install -m 644 ldapget.8 $RPM_BUILD_ROOT%{_mandir}/man8/
e7e179
install -m 644 crlhelper.8 $RPM_BUILD_ROOT%{_mandir}/man8/
e7e179
# Ugh, manually create the ldconfig symbolic links
e7e179
version=`grep -v '^\#' ./libtool-version`
e7e179
current=`echo $version | cut -d: -f1`
e7e179
revision=`echo $version | cut -d: -f2`
e7e179
age=`echo $version | cut -d: -f3`
e7e179
install -m  755 .libs/librevocation.so.$current.$revision.$age $RPM_BUILD_ROOT%{_libdir}/
e7e179
# install missing symlink (was giving no-ldconfig-symlink rpmlint errors)
e7e179
ldconfig -n $RPM_BUILD_ROOT%{_libdir}
e7e179
(cd $RPM_BUILD_ROOT%{_libdir} && ln -s librevocation.so.$current.$revision.$age librevocation.so.0)
e7e179
(cd $RPM_BUILD_ROOT%{_libdir} && ln -s librevocation.so.$current.$revision.$age  librevocation.so)
e7e179
install -m 755 ldapget $RPM_BUILD_ROOT%{_sbindir}/
e7e179
install -m 755 crlhelper $RPM_BUILD_ROOT%{_libexecdir}/
e7e179
# Provide compatibility links to prevent disruption of customized deployments.
e7e179
#
e7e179
#     NOTE:  These links may be deprecated in a future release
e7e179
#            of 'mod_revocator'.
e7e179
#
e7e179
ln -s %{_sbindir}/ldapget $RPM_BUILD_ROOT%{_bindir}/ldapget
e7e179
ln -s %{_libexecdir}/crlhelper $RPM_BUILD_ROOT%{_bindir}/crlhelper
e7e179
e7e179
%clean
e7e179
rm -rf $RPM_BUILD_ROOT
e7e179
e7e179
%post -p /sbin/ldconfig
e7e179
e7e179
%postun -p /sbin/ldconfig
e7e179
e7e179
%files
e7e179
%defattr(-,root,root,-)
e7e179
%doc README LICENSE docs/mod_revocator.html
e7e179
%{_mandir}/man8/*
e7e179
%config(noreplace) %{_httpd_confdir}/*.conf
e7e179
%if "%{_httpd_modconfdir}" != "%{_httpd_confdir}"
e7e179
%config(noreplace) %{_httpd_modconfdir}/*.conf
e7e179
%endif
e7e179
%{_libdir}/httpd/modules/mod_rev.so
e7e179
# rpmlint will complain that librevocation.so is a shared library but this
e7e179
# must be ignored because this file is loaded directly by name by the Apache
e7e179
# module.
e7e179
%{_libdir}/librevocation.*so*
e7e179
%{_sbindir}/ldapget
e7e179
%{_libexecdir}/crlhelper
e7e179
%{_bindir}/ldapget
e7e179
%{_bindir}/crlhelper
e7e179
e7e179
%changelog
e7e179
* Tue Aug  9 2016 Rob Crittenden <rcritten@redhat.com> - 1.0.3-21
e7e179
- Respin to fix segfault in cleanup call. (#1326840)
e7e179
e7e179
* Mon Aug  8 2016 Rob Crittenden <rcritten@redhat.com> - 1.0.3-20
e7e179
- Clean up semaphore in crlhelper on shutdown (#1326840)
e7e179
- Update URL to https://fedorahosted.org/mod_revocator/
e7e179
e7e179
* Fri Jan 24 2014 Daniel Mach <dmach@redhat.com> - 1.0.3-19
e7e179
- Mass rebuild 2014-01-24
e7e179
e7e179
* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 1.0.3-18
e7e179
- Mass rebuild 2013-12-27
e7e179
e7e179
* Tue Jul  9 2013 Matthew Harmsen <mharmsen@redhat.com> - 1.0.3-17
e7e179
- Add the following explanation to the 'Brewtap results' textbox in rpmdiff:
e7e179
  The '/etc/httpd/conf.d/revocator.conf' file does not require a man page
e7e179
  because its parameters are sufficiently documented within the
e7e179
  configuration file itself.
e7e179
  The '/etc/httpd/conf.modules.d/11-revocator.conf' file does not require
e7e179
  a man page because the file merely contains the line
e7e179
  'LoadModule rev_module modules/mod_rev.so' to support httpd
e7e179
  loading of Dynamic Shared Objects ('/etc/httpd/conf/httpd.conf').
e7e179
e7e179
* Wed Jul  3 2013 Matthew Harmsen <mharmsen@redhat.com> - 1.0.3-16
e7e179
- Bugzilla Bug #948875 - Man page scan results for mod_revocator
e7e179
- Moved 'ldapget' from %%bindir to %%sbindir (provided compatibility link)
e7e179
- Moved 'crlhelper' from %%bindir to %%libexecdir (provided compatibility link)
e7e179
e7e179
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.3-15
e7e179
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
e7e179
e7e179
* Mon Oct  8 2012 Matthew Harmsen <mharmsen@redhat.com> - 1.0.3-14
e7e179
- Bugzilla Bug #861999 - mod_revocator exec CLR URIs fail to load: unable to
e7e179
  load Revocation module, NSS error -8187 - stephen.capstick64@gmail.com
e7e179
  (mod_revocator-waitpid.patch)
e7e179
e7e179
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.3-13
e7e179
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
e7e179
e7e179
* Mon Apr 23 2012 Joe Orton <jorton@redhat.com> - 1.0.3-12
e7e179
- use 11- prefix for config file w/2.4
e7e179
e7e179
* Wed Apr 18 2012 Joe Orton <jorton@redhat.com> - 1.0.3-11
e7e179
- fix deps, packaging for 2.4 (#803074)
e7e179
e7e179
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.3-10
e7e179
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
e7e179
e7e179
* Thu Oct 27 2011 Matthew Harmsen <mharmsen@redhat.com> - 1.0.3-9
e7e179
- Bugzilla Bug #716874 - httpd (32 bit) failed to start if mod_revocator
e7e179
  (32 bit) is installed on ppc64
e7e179
e7e179
* Fri Oct 21 2011 Matthew Harmsen <mharmsen@redhat.com> - 1.0.3-7
e7e179
- Bugzilla Bug #716355 - mod_revocator does not shut down httpd server if
e7e179
  expired CRL is fetched
e7e179
- Bugzilla Bug #716361 - mod_revocator does not bring down httpd server if
e7e179
  CRLUpdate fails
e7e179
e7e179
* Tue Oct 11 2011 Matthew Harmsen <mharmsen@redhat.com> - 1.0.3-6
e7e179
- Bugzilla Bug #737556 - CRLS are not downloaded when mod_revocator module
e7e179
  is loaded successfully. And no error was thrown in httpd error_log -
e7e179
  mharmsen
e7e179
- Add 'autoreconf -fvi' to build section - mharmsen
e7e179
- Fix shutting down Apache if CRLUpdateCritical is on and a CRL
e7e179
  is not available at startup (#654378) - rcritten@redhat.com
e7e179
- Updated mod_revocator-kill patch. The ownership of the semaphore used to
e7e179
  control access to crlhelper was not always changed to the Apache user
e7e179
  (#648546) - rcritten@redhat.com
e7e179
- Actually apply the patch (#648546) - rcritten@redhat.com
e7e179
- Fix killing the web server if updatecritical is set (#648546) -
e7e179
  rcritten@redhat.com
e7e179
e7e179
* Mon Mar  7 2011 Rob Crittenden <rcritten@redhat.com> - 1.0.3-4
e7e179
- Use correct package name, nss-pkcs11-devel-static (#640293)
e7e179
e7e179
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.3-3
e7e179
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
e7e179
e7e179
* Tue Oct  5 2010 Rob Crittenden <rcritten@redhat.com> - 1.0.3-2
e7e179
- Add BuildRequires: nss-pkcs11-static (#640293)
e7e179
e7e179
* Wed Apr 14 2010 Rob Crittenden <rcritten@redhat.com> - 1.0.3-1
e7e179
- Update to upstream 1.0.3
e7e179
e7e179
* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.2-8
e7e179
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
e7e179
e7e179
* Wed Mar 04 2009 Robert Scheck <robert@fedoraproject.org> - 1.0.2-7
e7e179
- Solve the ppc64-redhat-linux-gnu configure target error
e7e179
e7e179
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.2-6
e7e179
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
e7e179
e7e179
* Mon Aug 11 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 1.0.2-5
e7e179
- fix license tag
e7e179
e7e179
* Mon Feb 25 2008 Rob Crittenden <rcritten@redhat.com> 1.0.2-4
e7e179
- The nss package changed the location of the NSS shared libraries to /lib from
e7e179
  /usr/lib. Static libraries remained in /usr/lib. They then updated their
e7e179
  devel package to put symlinks back from /lib to /usr. Respin to pick that up.
e7e179
  BZ 434395.
e7e179
e7e179
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 1.0.2-3
e7e179
- Autorebuild for GCC 4.3
e7e179
e7e179
* Wed Dec  5 2007 Rob Crittenden <rcritten@redhat.com> 1.0.2-2
e7e179
- Respin to pick up new openldap
e7e179
e7e179
* Mon Oct 16 2006 Rob Crittenden <rcritten@redhat.com> 1.0.2-1
e7e179
- Initial build