diff options
author | Jirka Hladky <jhladky@redhat.com> | 2020-05-11 17:03:44 +0200 |
---|---|---|
committer | Jirka Hladky <jhladky@redhat.com> | 2020-05-11 17:03:44 +0200 |
commit | 2a8748073db844d8de57823613642d59e99a875c (patch) | |
tree | 5faeacf8050832e72a8f03746ceb71e31f67ffd5 | |
parent | Merge pull request #26 from nbraud/haveged.service/security (diff) | |
download | haveged-2a8748073db844d8de57823613642d59e99a875c.tar.xz haveged-2a8748073db844d8de57823613642d59e99a875c.zip |
Updated fedora spec file
-rw-r--r-- | contrib/build/fedora.spec | 126 |
1 files changed, 94 insertions, 32 deletions
diff --git a/contrib/build/fedora.spec b/contrib/build/fedora.spec index c2a2e6e..678ca9e 100644 --- a/contrib/build/fedora.spec +++ b/contrib/build/fedora.spec @@ -1,26 +1,17 @@ Summary: A Linux entropy source using the HAVEGE algorithm Name: haveged -Version: 1.9 -Release: 0%{?dist} +Version: 1.9.8 +Release: 1%{?dist} License: GPLv3+ -BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) -Group: System Environment/Daemons -URL: http://www.irisa.fr/caps/projects/hipsor/ -Source0: http://www.issihosts.com/haveged/%{name}-%{version}.tar.gz -Source1: haveged.service +URL: https://github.com/jirka-h/haveged +Source0: https://github.com/jirka-h/%{name}/archive/v%{version}/%{name}-%{version}.tar.gz Requires(post): systemd Requires(preun): systemd Requires(postun): systemd -# SystemV -> SystemD conversion -# This is actually needed for the %%triggerun script but Requires(triggerun) -# is not valid. We can use %%post because this particular %%triggerun script -# should fire just after this package is installed. -Requires(post): systemd-sysv -# SystemV -> SystemD conversion - - -BuildRequires: automake gdb coreutils glibc-common +BuildRequires: gcc +BuildRequires: automake coreutils glibc-common systemd-units +Enhances: apache2 gpg2 openssl openvpn php5 smtp_daemon systemd %description A Linux entropy source using the HAVEGE algorithm @@ -41,7 +32,6 @@ attempt to select appropriate values from internal tables. %package devel Summary: Headers and shared development libraries for HAVEGE algorithm -Group: Development/Libraries Requires: %{name} = %{version}-%{release} %description devel @@ -68,39 +58,56 @@ make install DESTDIR=%{buildroot} INSTALL="install -p" chmod 0644 COPYING README ChangeLog AUTHORS #Install systemd service file -rm -rf %{buildroot}/etc/init.d -pushd $RPM_BUILD_ROOT -mkdir -p .%{_unitdir} -install -p -m644 %{SOURCE1} .%{_unitdir}/haveged.service -popd +install -Dpm 0644 init.d/service.fedora %{buildroot}%{_unitdir}/%{name}.service # We don't ship .la files. rm -rf %{buildroot}%{_libdir}/libhavege.*a -%clean -rm -rf %{buildroot} +mkdir -p %{buildroot}%{_defaultdocdir}/%{name} +cp -p COPYING README ChangeLog AUTHORS contrib/build/havege_sample.c %{buildroot}%{_defaultdocdir}/%{name} %post -/sbin/ldconfig +/sbin/ldconfig +%if 0%{?systemd_post:1} %systemd_post haveged.service +%else +if [ $1 = 1 ]; then + # Initial installation + /bin/systemctl daemon-reload >/dev/null 2>&1 || : +fi +%endif %preun +%if 0%{?systemd_preun:1} %systemd_preun haveged.service +%else +if [ $1 = 0 ]; then + # Package removal, not upgrade + /bin/systemctl --no-reload disable haveged.service >/dev/null 2>&1 || : + /bin/systemctl stop haveged.service >/dev/null 2>&1 || : +fi +%endif %postun -/sbin/ldconfig +%if 0%{?systemd_postun_with_restart:1} %systemd_postun_with_restart haveged.service +%else +/bin/systemctl daemon-reload >/dev/null 2>&1 || : +if [ $1 -ge 1 ]; then + # Package upgrade, not uninstall + /bin/systemctl try-restart haveged.service >/dev/null 2>&1 || : +fi +%endif +/sbin/ldconfig %files -%defattr(-, root, root, -) %{_mandir}/man8/haveged.8* %{_sbindir}/haveged %{_unitdir}/haveged.service %{_libdir}/*so.* -%doc COPYING README ChangeLog AUTHORS +%{_defaultdocdir}/* %files devel -%defattr(-, root, root, -) %{_mandir}/man3/libhavege.3* %dir %{_includedir}/%{name} %{_includedir}/%{name}/havege.h @@ -109,9 +116,64 @@ rm -rf %{buildroot} %changelog -* Sun Jan 13 2013 Jirka Hladky <hladky.jiri@gmail.com> - 1.7h-0 -- Couple of minor updates -* Sat Jan 12 2013 Jirka Hladky <hladky.jiri@gmail.com> - 1.7g-0 +* Mon Sep 30 2019 Jirka Hladky <hladky.jiri@gmail.com> - 1.9.8-1 + - Update to 1.9.8 + +* Mon Aug 26 2019 Jirka Hladky <hladky.jiri@gmail.com> - 1.9.6-1 + - Update to 1.9.6 + +* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.1-12 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild + +* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.1-11 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild + +* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.1-10 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild + +* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.1-9 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild + +* Wed Aug 02 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.1-8 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild + +* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.1-7 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild + +* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.1-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild + +* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.1-5 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild + +* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.9.1-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild + +* Sat Aug 16 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.9.1-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild + +* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.9.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild + +* Thu Feb 13 2014 Jirka Hladky <hladky.jiri@gmail.com> - 1.9.1-1 +- Update to 1.9.1 + +* Sat Jan 04 2014 Jirka Hladky <hladky.jiri@gmail.com> - 1.8-1 +- Unversioned docdir change, more info on + https://fedoraproject.org/wiki/Changes/UnversionedDocdirs + +* Fri Jan 03 2014 Jirka Hladky <hladky.jiri@gmail.com> - 1.8-0 +- Updated to the version 1.8 +- Improvement to systemd service file +- Fixed exit status + +* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.7-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild + +* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.7-1 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + +* Sat Jan 19 2013 Jirka Hladky <hladky.jiri@gmail.com> - 1.7-0 - Updated to the version 1.7 - Version 1.7 brings developement libraries - Added devel package |