Sophie

Sophie

distrib > Mandriva > 2010.1 > i586 > by-pkgid > 62ad35541a3d3512013c274f98016288 > files > 3

zn_poly-0.9-7mdv2010.0.src.rpm

%define name		zn_poly
%define version		0.9
%define devstatic	%mklibname -d -s %{name}

Name:		%{name}
Group:		Sciences/Mathematics
License:	GPLv2 or GPLv3
Summary:	Polynomial arithmetic in Z/nZ[x]
Version:	%{version}
Release:	%mkrel 7
Source:		http://cims.nyu.edu/~harvey/zn_poly/releases/%{name}-%{version}.tar.gz
URL:		http://cims.nyu.edu/~harvey/zn_poly/
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-buildroot

BuildRequires:	gmp-devel
BuildRequires:	ntl-devel

Patch0:		zn_poly-0.9.patch

%description
zn_poly is a C library for polynomial arithmetic in Z/nZ[x],
where n is any modulus that fits into an unsigned long. 

%package	-n %{devstatic}
Group:		Development/C
Summary:	Polynomial arithmetic in Z/nZ[x]
Provides:	zn_poly-static-devel = %{version}-%{release}

%description	-n %{devstatic}
zn_poly is a C library for polynomial arithmetic in Z/nZ[x],
where n is any modulus that fits into an unsigned long. 

%prep
%setup -q

%patch0	-p1

%build
# this script actually just calls makemakefile.py, and it doesn't like
# options it doesn't know about.
sed -i	-e 's|^ntl_include_dir.*|ntl_include_dir = options.ntl_prefix + "/NTL/include"|'	\
	-e 's|" % prefix|" % ("%{buildroot}" + prefix)|'	\
	-e 's|/lib"|/%{_lib}"|'					\
	makemakefile.py
/bin/sh ./configure --prefix=%{_prefix} --cflags="%{optflags} -fPIC"

make

%install
make install

%clean
rm -rf %{buildroot}

%files		-n %{devstatic}
%defattr(-,root,root)
%{_includedir}/*
%{_libdir}/*
%doc doc/REFERENCES


%changelog
* Mon Mar 30 2009 Paulo Andrade <pcpa@mandriva.com.br> 0.9-2mdv2009.1
+ Revision: 362763
- Initial import of zn_poly version 0.9
  Polynomial arithmetic in Z/nZ[x]
  http://cims.nyu.edu/~harvey/zn_poly/
- zn_poly