From b8acc93ce32132c1fa9d99a4e53774732871d47b Mon Sep 17 00:00:00 2001 From: David Woodhouse Date: Mon, 18 Jun 2012 12:00:41 +0100 Subject: [PATCH] Reinstate package, update to 2.4 --- .gitignore | 1 + dead.package | 1 - nettle.spec | 136 +++++++++++++++++++++++++++++++++++++++++++++++++++ sources | 1 + 4 files changed, 138 insertions(+), 1 deletion(-) delete mode 100644 dead.package create mode 100644 nettle.spec create mode 100644 sources diff --git a/.gitignore b/.gitignore index 5dea932..e01de03 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ nettle-1.15.tar.gz +/nettle-2.4.tar.gz diff --git a/dead.package b/dead.package deleted file mode 100644 index 7dcad86..0000000 --- a/dead.package +++ /dev/null @@ -1 +0,0 @@ -This package was retired due to no active owner on 2010-08-27 diff --git a/nettle.spec b/nettle.spec new file mode 100644 index 0000000..8e1b2e8 --- /dev/null +++ b/nettle.spec @@ -0,0 +1,136 @@ +Name: nettle +Version: 2.4 +Release: 1%{?dist} +Summary: A low-level cryptographic library + +Group: Development/Libraries +License: LGPLv2+ +URL: http://www.lysator.liu.se/~nisse/nettle/ +Source0: http://www.lysator.liu.se/~nisse/archive/%{name}-%{version}.tar.gz +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) + +BuildRequires: gmp-devel +BuildRequires: m4 + +Requires(post): /sbin/install-info +Requires(preun): /sbin/install-info + + +%package devel +Summary: Development headers for a low-level cryptographic library +Group: Development/Libraries +Requires: %{name} = %{version}-%{release} + +%description +Nettle is a cryptographic library that is designed to fit easily in more +or less any context: In crypto toolkits for object-oriented languages +(C++, Python, Pike, ...), in applications like LSH or GNUPG, or even in +kernel space. + +%description devel +Nettle is a cryptographic library that is designed to fit easily in more +or less any context: In crypto toolkits for object-oriented languages +(C++, Python, Pike, ...), in applications like LSH or GNUPG, or even in +kernel space. This package contains kernel headers. + + +%prep +%setup -q +# Disable -ggdb3 which makes debugedit unhappy +sed s/ggdb3/g/ -i configure +# Welcome to the 21st century. Thankfully the legacy charset crap is fixed in 2.5 +# Patch was sent for the FSF address on 2012-06-18. +for a in NEWS README ChangeLog nettle.texinfo *.[ch] tools/*.[ch] descore.README ; do + /usr/bin/iconv -f iso8859-1 -t utf-8 $a | + sed -e 's/59 Temple Place.* Suite 330/51 Franklin Street, Fifth Floor/' \ + -e 's/MA.*02111-1307/MA 02111-1301/' > $a.conf && mv -f $a.conf $a +done +sed -i s/ISO-8859-1/UTF-8/ -i nettle.texinfo + +%build +%configure --enable-shared +make %{?_smp_mflags} + + +%install +rm -rf $RPM_BUILD_ROOT +make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p" +make install-shared DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p" +mkdir -p $RPM_BUILD_ROOT%{_infodir} +install -p -m 644 nettle.info $RPM_BUILD_ROOT%{_infodir}/ +rm -f $RPM_BUILD_ROOT%{_libdir}/*.a +rm -f $RPM_BUILD_ROOT%{_infodir}/dir +chmod 0755 $RPM_BUILD_ROOT%{_libdir}/libnettle.so.4.3 +chmod 0755 $RPM_BUILD_ROOT%{_libdir}/libhogweed.so.2.1 +%check +make check + +%clean +rm -rf $RPM_BUILD_ROOT + + +%files +%defattr(-,root,root,-) +%doc AUTHORS ChangeLog COPYING.LIB NEWS README TODO +%{_infodir}/nettle.info.gz +%{_bindir}/nettle-lfib-stream +%{_bindir}/pkcs1-conv +%{_bindir}/sexp-conv +%{_bindir}/nettle-hash +%{_libdir}/libnettle.so.4 +%{_libdir}/libnettle.so.4.3 +%{_libdir}/libhogweed.so.2 +%{_libdir}/libhogweed.so.2.1 + + +%files devel +%defattr(-,root,root,-) +%doc descore.README nettle.html nettle.pdf COPYING.LIB +%{_includedir}/nettle +%{_libdir}/libnettle.so +%{_libdir}/libhogweed.so +%{_libdir}/pkgconfig/hogweed.pc +%{_libdir}/pkgconfig/nettle.pc + +%post +/sbin/install-info %{_infodir}/%{name}.info %{_infodir}/dir || : +/sbin/ldconfig + +%preun +if [ $1 = 0 ]; then + /sbin/install-info --delete %{_infodir}/%{name}.info.gz %{_infodir}/dir || : +fi + +%postun -p /sbin/ldconfig + + + +%changelog +* Mon Jun 18 2012 David Woodhouse - 2.4-1 +- Revive package (GnuTLS needs it), disable static, update to current release 2.4 + +* Sat Jul 25 2009 Fedora Release Engineering - 1.15-7 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild + +* Wed Feb 25 2009 Fedora Release Engineering - 1.15-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild + +* Thu Apr 10 2008 Ian Weller 1.15-5 +- Moved static lib to -static + +* Mon Mar 24 2008 Ian Weller 1.15-4 +- Added libraries and ldconfig + +* Mon Feb 18 2008 Ian Weller 1.15-3 +- Added provides -static to -devel + +* Sun Feb 17 2008 Ian Weller 1.15-2 +- Removed redundant requires +- Removed redundant documentation between packages +- Fixed license tag +- Fixed -devel description +- Added the static library back to -devel +- Added make clean + +* Fri Feb 08 2008 Ian Weller 1.15-1 +- First package build. diff --git a/sources b/sources new file mode 100644 index 0000000..06aacef --- /dev/null +++ b/sources @@ -0,0 +1 @@ +450be8c4886d46c09f49f568ad6fa013 nettle-2.4.tar.gz