Blame SPECS/memcached.spec

dc8233
%define username   memcached
dc8233
%define groupname  memcached
dc8233
%bcond_without sasl
dc8233
%bcond_with seccomp
dc8233
%bcond_with tests
dc8233
dc8233
Name:           memcached
dc8233
Version:        1.5.9
dc8233
Release:        2%{?dist}
dc8233
Epoch:          0
dc8233
Summary:        High Performance, Distributed Memory Object Cache
dc8233
dc8233
Group:          System Environment/Daemons
dc8233
License:        BSD
dc8233
URL:            https://www.memcached.org/
dc8233
Source0:        https://www.memcached.org/files/%{name}-%{version}.tar.gz
dc8233
Source1:        memcached.sysconfig
dc8233
dc8233
Patch1:         memcached-unit.patch
dc8233
Patch2:         memcached-vaend.patch
dc8233
Patch3:         memcached-lrutest.patch
dc8233
dc8233
BuildRequires:  gcc libevent-devel systemd
dc8233
BuildRequires:  perl-generators
dc8233
BuildRequires:  perl(Test::More), perl(Test::Harness)
dc8233
%{?with_sasl:BuildRequires: cyrus-sasl-devel}
dc8233
%{?with_seccomp:BuildRequires: libseccomp-devel}
dc8233
dc8233
Requires(pre):  shadow-utils
dc8233
%{?systemd_requires}
dc8233
dc8233
%description
dc8233
memcached is a high-performance, distributed memory object caching
dc8233
system, generic in nature, but intended for use in speeding up dynamic
dc8233
web applications by alleviating database load.
dc8233
dc8233
%package devel
dc8233
Summary: Files needed for development using memcached protocol
dc8233
Group: Development/Libraries
dc8233
Requires: %{name} = %{epoch}:%{version}-%{release}
dc8233
dc8233
%description devel
dc8233
Install memcached-devel if you are developing C/C++ applications that require
dc8233
access to the memcached binary include files.
dc8233
dc8233
%prep
dc8233
%setup -q
dc8233
%patch1 -p1 -b .unit
dc8233
%patch2 -p1 -b .vaend
dc8233
%patch3 -p1 -b .lrutest
dc8233
dc8233
%build
dc8233
# compile with full RELRO
dc8233
export CFLAGS="%{optflags} -pie -fpie"
dc8233
export LDFLAGS="-Wl,-z,relro,-z,now"
dc8233
dc8233
%configure \
dc8233
  %{?with_sasl: --enable-sasl} \
dc8233
  %{?with_seccomp: --enable-seccomp}
dc8233
dc8233
make %{?_smp_mflags}
dc8233
dc8233
%check
dc8233
# tests are disabled by default as they are unreliable on build systems
dc8233
%{!?with_tests: exit 0}
dc8233
dc8233
# whitespace tests fail locally on fedpkg systems now that they use git
dc8233
rm -f t/whitespace.t
dc8233
dc8233
# Parts of the test suite only succeed as non-root.
dc8233
if [ `id -u` -ne 0 ]; then
dc8233
  # remove failing test that doesn't work in
dc8233
  # build systems
dc8233
  rm -f t/daemonize.t t/watcher.t t/expirations.t
dc8233
fi
dc8233
make test
dc8233
dc8233
%install
dc8233
make install DESTDIR=%{buildroot} INSTALL="%{__install} -p"
dc8233
# remove memcached-debug
dc8233
rm -f %{buildroot}/%{_bindir}/memcached-debug
dc8233
dc8233
# Perl script for monitoring memcached
dc8233
install -Dp -m0755 scripts/memcached-tool %{buildroot}%{_bindir}/memcached-tool
dc8233
install -Dp -m0644 scripts/memcached-tool.1 \
dc8233
        %{buildroot}%{_mandir}/man1/memcached-tool.1
dc8233
dc8233
# Unit file
dc8233
install -Dp -m0644 scripts/memcached.service \
dc8233
        %{buildroot}%{_unitdir}/memcached.service
dc8233
dc8233
# Default configs
dc8233
install -Dp -m0644 %{SOURCE1} %{buildroot}/%{_sysconfdir}/sysconfig/%{name}
dc8233
dc8233
dc8233
%pre
dc8233
getent group %{groupname} >/dev/null || groupadd -r %{groupname}
dc8233
getent passwd %{username} >/dev/null || \
dc8233
useradd -r -g %{groupname} -d /run/memcached \
dc8233
    -s /sbin/nologin -c "Memcached daemon" %{username}
dc8233
exit 0
dc8233
dc8233
dc8233
%post
dc8233
%systemd_post memcached.service
dc8233
dc8233
dc8233
%preun
dc8233
%systemd_preun memcached.service
dc8233
dc8233
dc8233
%postun
dc8233
%systemd_postun_with_restart memcached.service
dc8233
dc8233
dc8233
%files
dc8233
%doc AUTHORS ChangeLog COPYING NEWS README.md doc/CONTRIBUTORS doc/*.txt
dc8233
%config(noreplace) %{_sysconfdir}/sysconfig/%{name}
dc8233
%{_bindir}/memcached-tool
dc8233
%{_bindir}/memcached
dc8233
%{_mandir}/man1/memcached-tool.1*
dc8233
%{_mandir}/man1/memcached.1*
dc8233
%{_unitdir}/memcached.service
dc8233
dc8233
dc8233
%files devel
dc8233
%{_includedir}/memcached/*
dc8233
dc8233
%changelog
dc8233
* Fri Feb 08 2019 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.9-2
dc8233
- fix lru-maintainer test (#1671666)
dc8233
dc8233
* Wed Aug 08 2018 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.9-1
dc8233
- update to 1.5.9 (#1613690)
dc8233
dc8233
* Wed Aug 01 2018 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.7-3
dc8233
- disable tests in check stage by default (#1610006)
dc8233
dc8233
* Tue Jul 24 2018 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.7-2
dc8233
- add missing va_end() call (#1602616)
dc8233
- enable tests in check stage again
dc8233
dc8233
* Thu Mar 29 2018 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.7-1
dc8233
- update to 1.5.7
dc8233
- use https URLs in spec
dc8233
dc8233
* Thu Mar 01 2018 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.6-1
dc8233
- update to 1.5.6 (UDP port disabled by default)
dc8233
- add gcc to build requirements
dc8233
dc8233
* Thu Feb 15 2018 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.5-2
dc8233
- rebuild for new libevent
dc8233
dc8233
* Tue Feb 13 2018 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.5-1
dc8233
- update to 1.5.5
dc8233
dc8233
* Thu Feb 08 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0:1.5.4-3
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
dc8233
dc8233
* Tue Jan 30 2018 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.4-2
dc8233
- fix building with new gcc
dc8233
- use macro for systemd scriptlet dependencies
dc8233
dc8233
* Thu Jan 04 2018 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.4-1
dc8233
- update to 1.5.4
dc8233
dc8233
* Mon Nov 06 2017 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.3-1
dc8233
- update to 1.5.3
dc8233
- add build condition for seccomp support
dc8233
dc8233
* Mon Oct 02 2017 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.2-1
dc8233
- update to 1.5.2
dc8233
dc8233
* Fri Aug 25 2017 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.1-1
dc8233
- update to 1.5.1
dc8233
dc8233
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0:1.5.0-3
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
dc8233
dc8233
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0:1.5.0-2
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
dc8233
dc8233
* Mon Jul 24 2017 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.5.0-1
dc8233
- update to 1.5.0
dc8233
dc8233
* Tue Jul 11 2017 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.39-1
dc8233
- update to 1.4.39 (CVE-2017-9951)
dc8233
dc8233
* Tue Jun 27 2017 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.38-1
dc8233
- update to 1.4.38
dc8233
dc8233
* Fri Jun 09 2017 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.37-1
dc8233
- update to 1.4.37
dc8233
dc8233
* Wed Mar 22 2017 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.36-1
dc8233
- update to 1.4.36
dc8233
dc8233
* Mon Feb 27 2017 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.35-1
dc8233
- update to 1.4.35
dc8233
dc8233
* Wed Feb 15 2017 Joe Orton <jorton@redhat.com> - 0:1.4.34-3
dc8233
- fix gcc 7 format-truncation error (#1423934)
dc8233
dc8233
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0:1.4.34-2
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
dc8233
dc8233
* Mon Jan 16 2017 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.34-1
dc8233
- update to 1.4.34
dc8233
dc8233
* Tue Nov 01 2016 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.33-1
dc8233
- update to 1.4.33 (CVE-2016-8704, CVE-2016-8705, CVE-2016-8706)
dc8233
dc8233
* Thu Oct 13 2016 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.32-1
dc8233
- update to 1.4.32
dc8233
dc8233
* Wed Sep 07 2016 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.31-1
dc8233
- update to 1.4.31
dc8233
- disable testing for now
dc8233
dc8233
* Fri Aug 12 2016 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.30-1
dc8233
- update to 1.4.30
dc8233
dc8233
* Thu Jul 14 2016 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.29-1
dc8233
- update to 1.4.29
dc8233
dc8233
* Tue Jul 12 2016 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.28-1
dc8233
- update to 1.4.28
dc8233
- listen only on loopback interface by default (#1182542)
dc8233
- use upstream unit file (#1350939)
dc8233
- remove obsolete macros and scriptlet
dc8233
dc8233
* Tue Jun 21 2016 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.26-1
dc8233
- update to 1.4.26
dc8233
dc8233
* Tue Feb 23 2016 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.25-1
dc8233
- update to 1.4.25
dc8233
- enable SASL support (#815050)
dc8233
- remove obsolete macros
dc8233
dc8233
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0:1.4.17-5
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
dc8233
dc8233
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.4.17-4
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
dc8233
dc8233
* Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.4.17-3
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
dc8233
dc8233
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.4.17-2
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
dc8233
dc8233
* Wed Jan 15 2014 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.17-1
dc8233
- update to 1.4.17
dc8233
- fix building with -Werror=format-security in CFLAGS
dc8233
dc8233
* Wed Aug 07 2013 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.15-7
dc8233
- buildrequire systemd-units (#992221)
dc8233
- update memcached man page
dc8233
- add memcached-tool man page
dc8233
dc8233
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.4.15-6
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
dc8233
dc8233
* Wed Jul 17 2013 Petr Pisar <ppisar@redhat.com> - 0:1.4.15-5
dc8233
- Perl 5.18 rebuild
dc8233
dc8233
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.4.15-4
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
dc8233
dc8233
* Thu Dec 20 2012 Miroslav Lichvar <mlichvar@redhat.com> - 0:1.4.15-3
dc8233
- compile with full RELRO
dc8233
dc8233
* Tue Nov 20 2012 Joe Orton <jorton@redhat.com> - 0:1.4.15-2
dc8233
- BR perl(Test::Harness)
dc8233
dc8233
* Tue Nov 20 2012 Joe Orton <jorton@redhat.com> - 0:1.4.15-1
dc8233
- update to 1.4.15 (#782395)
dc8233
- switch to simple systemd service (#878198)
dc8233
- use systemd scriptlet macros (Václav Pavlín, #850204)
dc8233
dc8233
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.4.13-3
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
dc8233
dc8233
* Fri May 04 2012 Jon Ciesla <limburgher@gmail.com> - 0:1.4.13-2
dc8233
- Migrate to systemd, 783112.
dc8233
dc8233
* Tue Feb  7 2012 Paul Lindner <lindner@mirth.inuus.com> - 0:1.4.13-1
dc8233
- Upgrade to memcached 1.4.13
dc8233
- http://code.google.com/p/memcached/wiki/ReleaseNotes1413
dc8233
- http://code.google.com/p/memcached/wiki/ReleaseNotes1412
dc8233
- http://code.google.com/p/memcached/wiki/ReleaseNotes1411
dc8233
dc8233
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.4.10-2
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
dc8233
dc8233
* Wed Nov  9 2011 Paul Lindner <lindner@mirth.inuus.com> - 0:1.4.10-1
dc8233
- Upgrade to memcached 1.4.10 (http://code.google.com/p/memcached/wiki/ReleaseNotes1410)
dc8233
dc8233
* Tue Aug 16 2011 Paul Lindner <lindner@inuus.com> - 0:1.4.7-1
dc8233
- Upgrade to memcached 1.4.7 (http://code.google.com/p/memcached/wiki/ReleaseNotes147)
dc8233
- Fix some rpmlint errors/warnings.
dc8233
dc8233
* Tue Aug  2 2011 Paul Lindner <lindner@inuus.com> - 0:1.4.6-1
dc8233
- Upgrade to memcached-1.4.6
dc8233
dc8233
* Wed Feb 16 2011 Joe Orton <jorton@redhat.com> - 0:1.4.5-7
dc8233
- fix build
dc8233
dc8233
* Mon Feb 14 2011 Paul Lindner <lindner@inuus.com> - 0:1.4.5-6
dc8233
- Rebuild for updated libevent
dc8233
dc8233
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.4.5-5
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
dc8233
dc8233
* Sun Nov 28 2010 Paul Lindner <lindner@inuus.com> - 0:1.4.5-4
dc8233
- Add code to deal with /var/run/memcached on tmpfs
dc8233
dc8233
* Wed Sep  8 2010 Paul Lindner <lindner@inuus.com> - 0:1.4.5-3
dc8233
- Apply patch from memcached issue #60, solves Bugzilla 631051
dc8233
dc8233
* Wed May 26 2010 Joe Orton <jorton@redhat.com> - 0:1.4.5-2
dc8233
- LSB compliance fixes for init script
dc8233
- don't run the test suite as root
dc8233
- ensure a constant timestamp on the sysconfig file
dc8233
dc8233
* Sun Apr  4 2010 Paul Lindner <lindner@inuus.com> - 0:1.4.5-1
dc8233
- Upgrade to upstream memcached-1.4.5 (http://code.google.com/p/memcached/wiki/ReleaseNotes145)
dc8233
dc8233
* Wed Jan 20 2010 Paul Lindner <lindner@inuus.com> - 0:1.4.4-2
dc8233
- Remove SELinux policies fixes Bugzilla 557073
dc8233
dc8233
* Sat Nov 28 2009 Paul Lindner <lindner@inuus.com> - 0:1.4.4-1
dc8233
- Upgraded to upstream memcached-1.4.4 (http://code.google.com/p/memcached/wiki/ReleaseNotes144)
dc8233
- Add explicit Epoch to fix issue with broken devel dependencies (resolves 542001)
dc8233
dc8233
* Thu Nov 12 2009 Paul Lindner <lindner@inuus.com> - 1.4.3-1
dc8233
- Add explicit require on memcached for memcached-devel (resolves 537046)
dc8233
- enable-threads option no longer needed
dc8233
- Update web site address
dc8233
dc8233
* Wed Nov 11 2009 Paul Lindner <lindner@inuus.com> - 1.4.3-1
dc8233
- Upgrade to memcached-1.4.3
dc8233
dc8233
* Mon Oct 12 2009 Paul Lindner <lindner@inuus.com> - 1.4.2-1
dc8233
- Upgrade to memcached-1.4.2
dc8233
- Addresses CVE-2009-2415
dc8233
dc8233
* Sat Aug 29 2009 Paul Lindner <lindner@inuus.com> - 1.4.1-1
dc8233
- Upgrade to 1.4.1
dc8233
- http://code.google.com/p/memcached/wiki/ReleaseNotes141
dc8233
dc8233
* Wed Apr 29 2009 Paul Lindner <lindner@inuus.com> - 1.2.8-1
dc8233
- Upgrade to memcached-1.2.8
dc8233
- Addresses CVE-2009-1255
dc8233
dc8233
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.6-2
dc8233
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
dc8233
dc8233
* Tue Jul 29 2008 Paul Lindner <lindner@inuus.com> - 1.2.6-1
dc8233
- Upgrade to memcached-1.2.6
dc8233
dc8233
* Tue Mar  4 2008 Paul Lindner <lindner@inuus.com> - 1.2.5-1
dc8233
- Upgrade to memcached-1.2.5
dc8233
dc8233
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 1.2.4-4
dc8233
- Autorebuild for GCC 4.3
dc8233
dc8233
* Sun Jan 27 2008 Paul Lindner <lindner@inuus.com> - 1.2.4-3
dc8233
- Adjust libevent dependencies
dc8233
dc8233
* Sat Dec 22 2007 Paul Lindner <lindner@inuus.com> - 1.2.4-2
dc8233
- Upgrade to memcached-1.2.4
dc8233
dc8233
* Fri Sep 07 2007 Konstantin Ryabitsev <icon@fedoraproject.org> - 1.2.3-8
dc8233
- Add selinux policies
dc8233
- Create our own system user
dc8233
dc8233
* Mon Aug  6 2007 Paul Lindner <lindner@inuus.com> - 1.2.3-7
dc8233
- Fix problem with -P and -d flag combo on x86_64
dc8233
- Fix init script for FC-6
dc8233
dc8233
* Fri Jul 13 2007 Paul Lindner <lindner@inuus.com> - 1.2.3-4
dc8233
- Remove test that fails in fedora build system on ppc64
dc8233
dc8233
* Sat Jul  7 2007 root <lindner@inuus.com> - 1.2.3-2
dc8233
- Upgrade to 1.2.3 upstream
dc8233
- Adjust make install to preserve man page timestamp
dc8233
- Conform with LSB init scripts standards, add force-reload
dc8233
dc8233
* Wed Jul  4 2007 Paul Lindner <lindner@inuus.com> - 1.2.2-5
dc8233
- Use /var/run/memcached/ directory to hold PID file
dc8233
dc8233
* Sat May 12 2007 Paul Lindner <lindner@inuus.com> - 1.2.2-4
dc8233
- Remove tabs from spec file, rpmlint reports no more errors
dc8233
dc8233
* Thu May 10 2007 Paul Lindner <lindner@inuus.com> - 1.2.2-3
dc8233
- Enable build-time regression tests
dc8233
- add dependency on initscripts
dc8233
- remove memcached-debug (not needed in dist)
dc8233
- above suggestions from Bernard Johnson
dc8233
dc8233
* Mon May  7 2007 Paul Lindner <lindner@inuus.com> - 1.2.2-2
dc8233
- Tidyness improvements suggested by Ruben Kerkhof in bugzilla #238994
dc8233
dc8233
* Fri May  4 2007 Paul Lindner <lindner@inuus.com> - 1.2.2-1
dc8233
- Initial spec file created via rpmdev-newspec