3 %bcond_without tex # TeX documentation
5 # note: latest perl Math::Pari (2.030518) doesn't know of pari >= 2.12
6 # 2.13.1 with updated Math-Pari diff patch + Math-Pari 2.030518 with update patch:
7 # Failed 19/243 test programs. 176/1476 subtests failed.
8 # compared to 2.11.4 with Math-Pari 2.11-diff-all patch:
9 # Failed 20/229 test programs. 173/1477 subtests failed.
10 %define pari_version 2.13.1
11 %define gp2c_version 0.0.12
12 # because of previous 2.x versions with 8 minor digits, keep trailing zeros in package Version
13 %define math_pari_version 2.03051800
14 %define math_pari_fversion 2.030518
15 Summary: Number Theory-oriented Computer Algebra System
16 Summary(pl.UTF-8): Komputerowy system obliczeń algebraicznych zorientowany na metody teorii liczb
18 Version: %{pari_version}
21 Group: Applications/Math
22 Source0: http://pari.math.u-bordeaux.fr/pub/pari/unix/pari-%{pari_version}.tar.gz
23 # Source0-md5: 826064cf75af268be8a482ade6e27501
24 Source1: http://pari.math.u-bordeaux.fr/pub/pari/packages/galdata.tgz
25 # Source1-md5: f9f61b2930757a785b568e5d307a7d75
26 Source2: http://pari.math.u-bordeaux.fr/pub/pari/GP2C/gp2c-%{gp2c_version}.tar.gz
27 # Source2-md5: ab29c383985d1b7d339189ecff31d40a
28 Source3: http://www.cpan.org/modules/by-module/Math/Math-Pari-%{math_pari_fversion}.zip
29 # Source3-md5: f0d1d9f803c92abff0d6349869a82699
30 Source4: %{name}.desktop
32 Patch0: %{name}-target_arch.patch
33 Patch2: %{name}-arch.patch
34 Patch3: perl-Math-Pari-crash-workaround.patch
35 Patch4: perl-Math-Pari-noproccpuinfo.patch
36 Patch5: %{name}-noproccpuinfo.patch
37 Patch6: gmp-version.patch
38 Patch7: Math-Pari-escape-left-braces-in-regex.patch
39 Patch8: perl-Math-Pari-update.patch
40 # based on Math-Pari-%{math_pari_fversion}/patches/diff-2.11.0-all
41 Patch10: pari-Math-Pari-diff.patch
42 URL: http://pari.math.u-bordeaux.fr/
43 BuildRequires: autoconf
45 BuildRequires: gmp-devel
46 BuildRequires: perl-devel >= 1:5.8.0
47 BuildRequires: readline-devel >= 4.2
48 BuildRequires: rpm-perlprov >= 3.0.3-16
49 BuildRequires: rpmbuild(macros) >= 1.745
51 BuildRequires: texlive
52 BuildRequires: texlive-amstex
53 BuildRequires: texlive-csplain
54 BuildRequires: texlive-dvips
55 BuildRequires: texlive-fonts-cm
56 BuildRequires: texlive-format-pdflatex
57 BuildRequires: texlive-plain
58 BuildRequires: texlive-pdftex
59 BuildRequires: texlive-tex-babel
60 BuildRequires: texlive-tex-ruhyphen
62 BuildRequires: xorg-lib-libX11-devel
63 BuildRequires: xorg-util-imake
64 Requires: pari = %{pari_version}-%{release}
66 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
69 PARI/GP is a package which is aimed at efficient computations in
70 number theory, but also contains a large number of other useful
71 functions. It is somewhat related to a Computer Algebra System, but is
72 not really one since it treats symbolic expressions as mathematical
73 entities such as matrices, polynomials, series, etc..., and not as
74 expressions per se. However it is often much faster than other CAS,
75 and contains a large number of specific functions not found elsewhere,
76 essentially for use in number theory.
78 %description -l pl.UTF-8
79 System PARI/GP jest przeznaczony do wydajnych obliczeń z zakresu
80 teorii liczb, ale zawiera również inne przydatne funkcje. Jest nieco
81 spokrewniony z Komputerowymi Systemami Algebraicznymi, ale nie
82 identyczny, ponieważ traktuje wyrażenia symboliczne jako obiekty
83 matematyczne (macierze, wielomiany, szeregi itp.) a nie jako wyrażenia
84 same w sobie. Jest jednak często znacznie szybszy od innych KSA-ów a
85 ponadto zawiera wiele innych funkcji nie spotykanych gdzie indziej, a
86 przydatnych zwłaszcza w teorii liczb.
89 Summary: Shared PARI library (required by the parigp package)
90 Summary(pl.UTF-8): Biblioteka współdzielona PARI (wymagana przez pakiet parigp)
94 Shared PARI library. You need it to run PARI/GP.
96 %description -n pari -l pl.UTF-8
97 Biblioteka współdzielona PARI. Potrzebujesz jej do uruchomienia
100 %package -n pari-devel
101 Summary: Include files for PARI shared library
102 Summary(pl.UTF-8): Pliki nagłówkowe do biblioteki współdzielonej PARI
103 Group: Development/Libraries
104 Requires: pari = %{pari_version}-%{release}
106 %description -n pari-devel
107 Include files for shared PARI library. You need them to use PARI
108 routines in you own programs.
110 %description -n pari-devel -l pl.UTF-8
111 Pliki nagłówkowe biblioteki współdzielonej PARI. Będziesz ich
112 potrzebował, jeżeli będziesz chciał wykorzystywać procedury PARI w
115 %package -n pari-static
116 Summary: Static PARI library
117 Summary(pl.UTF-8): Statyczna biblioteka PARI
118 Group: Development/Libraries
119 Requires: pari-devel = %{pari_version}-%{release}
121 %description -n pari-static
122 Static PARI library. You need it to statically link your programs with
125 %description -n pari-static -l pl.UTF-8
126 Biblioteka statyczna PARI. Potrzebujesz jej do konsolidowania
127 statycznego swoich programów korzystających z biblioteki PARI.
130 Summary: Example PARI/GP scripts
131 Summary(pl.UTF-8): Przykładowe skrypty pisane w języku PARI/GP
132 Group: Applications/Math
133 Requires: %{name} = %{pari_version}-%{release}
136 Example PARI/GP scripts. You can write such programs on your own.
138 %description demos -l pl.UTF-8
139 Przykładowe skrypty pisane w języku PARI/GP. Sam możesz takie napisać.
142 Summary: Galois data resolvents for PARI/GP
143 Summary(pl.UTF-8): Reprezentacje danych Galois fla PARI/GP
144 Group: Applications/Math
145 Requires: %{name} = %{pari_version}-%{release}
148 Galois data resolvents for PARI/GP.
150 %description galdata -l pl.UTF-8
151 Reprezentacje danych Galois do PARI/GP.
154 Summary: PARI/GP to C translator
155 Summary(pl.UTF-8): Konwerter skryptów PARI/GP do języka C
156 Version: %{gp2c_version}
158 Group: Development/Tools
159 Requires: pari-devel = %{pari_version}-%{release}
160 Requires: %{name} = %{pari_version}-%{release}
163 PARI/GP to C translator. Use it to compile your own C programs which
164 use pari library, without necessarily being a C programmer. Note: use
165 gp2c-run to run your programs inside the PARI/GP environment.
167 %description gp2c -l pl.UTF-8
168 Konwerter skryptów PARI/GP do języka C. Można nim tworzyć własne
169 programy w C korzystające z biblioteki pari. Znajomość języka C nie
170 jest wymagana. Uwaga: do uruchamiania programów w środowisku PARI/GP
171 należy używać gp2c-run.
173 %package -n perl-Math-Pari
174 Summary: Math-Pari perl module
175 Summary(pl.UTF-8): Moduł perla Math-Pari
176 Version: %{math_pari_version}
177 Group: Development/Languages/Perl
179 %description -n perl-Math-Pari
180 The Perl interface to the PARI part of GP/PARI.
182 %description -n perl-Math-Pari -l pl.UTF-8
183 Interfejs Perla do biblioteki PARI.
186 %setup -q -n pari-%{pari_version} -a 2 -a 3
192 cd Math-Pari-%{math_pari_fversion}
201 --target=%{_target_cpu} \
202 --prefix=%{_prefix} \
203 --libdir=%{_libdir} \
204 --sysdatadir=%{_libdir}/parigp \
205 --datadir=%{_datadir}/parigp \
206 --share-prefix=%{_datadir} \
207 --with-readline-lib=%{_libdir} \
208 --with-ncurses-lib=%{_libdir} \
209 --with-gmp-lib=%{_libdir}
211 %{__make} -C Olinux-%{_target_cpu} all \
213 CFLAGS="%{rpmcflags} -fno-strict-aliasing -fomit-frame-pointer -fPIC"
217 %{?with_tex:%{__make} -j1 -C doc docpdf}
219 ln -s Olinux-%{_target_cpu} Olinux-x86_64
222 ln -s Olinux-%{_target_cpu} Olinux-ix86
224 %ifarch sparc sparc64
225 # allow building sparc package on sparc64
226 ln -s Olinux-sparc Olinux-sparc64
230 cd gp2c-%{gp2c_version}
235 --datadir=%{_datadir}/parigp
238 %{?with_tex:%{__make} -j1 -C doc docall}
243 cd Math-Pari-%{math_pari_fversion}
244 cp -f ../Olinux-%{_target_cpu}/paricfg.h libPARI/paricfg.h
245 echo '#define DL_DFLT_NAME NULL' >>libPARI/paricfg.h
247 %{__perl} Makefile.PL \
251 OPTIMIZE="%{rpmcflags} -I$(pwd)/../Olinux-%{_target_cpu}"
256 rm -rf $RPM_BUILD_ROOT
257 install -d $RPM_BUILD_ROOT{%{_datadir}/parigp/galdata,%{_examplesdir}/parigp} \
258 $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir}}
260 # parigp, pari & pari-devel
262 DESTDIR=$RPM_BUILD_ROOT
264 install src/tags $RPM_BUILD_ROOT%{_datadir}/parigp/misc
265 install %{SOURCE4} $RPM_BUILD_ROOT%{_desktopdir}
266 install %{SOURCE5} $RPM_BUILD_ROOT%{_pixmapsdir}
269 install Olinux-%{_target_cpu}/libpari.a $RPM_BUILD_ROOT%{_libdir}/libpari.a
272 install examples/* $RPM_BUILD_ROOT%{_examplesdir}/parigp
275 tar zxvf %{SOURCE1} -C $RPM_BUILD_ROOT%{_datadir}/parigp/galdata
278 %{__make} install -C gp2c-%{gp2c_version} \
279 DESTDIR=$RPM_BUILD_ROOT
282 %{__make} install -C Math-Pari-%{math_pari_fversion} \
283 DESTDIR=$RPM_BUILD_ROOT
285 %{__rm} $RPM_BUILD_ROOT%{_mandir}/man1/pari.1
286 echo ".so gp.1" > $RPM_BUILD_ROOT%{_mandir}/man1/pari.1
288 %{__rm} -r $RPM_BUILD_ROOT%{_datadir}/parigp/{examples,doc}
289 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/gp2c
290 %{__rm} $RPM_BUILD_ROOT%{perl_vendorarch}/Math/libPARI*.pod
293 rm -rf $RPM_BUILD_ROOT
295 %post -n pari -p /sbin/ldconfig
296 %postun -n pari -p /sbin/ldconfig
299 %defattr(644,root,root,755)
300 %doc AUTHORS CHANGES* COMPAT NEW README examples/Inputrc %{?with_tex:doc/*.pdf}
301 %attr(755,root,root) %{_bindir}/gp-2.13
302 %attr(755,root,root) %{_bindir}/gp
303 %attr(755,root,root) %{_bindir}/gphelp
304 %attr(755,root,root) %{_bindir}/tex2mail
305 %dir %{_datadir}/parigp
306 %{_datadir}/parigp/PARI
307 %{_datadir}/parigp/misc
308 %{_datadir}/parigp/pari.desc
309 %{_mandir}/man1/gp.1*
310 %{_mandir}/man1/gp-*.1*
311 %{_mandir}/man1/gphelp.1*
312 %{_mandir}/man1/pari.1*
313 %{_mandir}/man1/tex2mail.1*
314 %{_desktopdir}/parigp.desktop
315 %{_pixmapsdir}/parigp.png
318 %defattr(644,root,root,755)
319 %attr(755,root,root) %{_libdir}/libpari-gmp.so.*.*.*
320 %attr(755,root,root) %ghost %{_libdir}/libpari-gmp.so.7
324 %defattr(644,root,root,755)
325 %attr(755,root,root) %{_libdir}/libpari.so
328 %files -n pari-static
329 %defattr(644,root,root,755)
333 %defattr(644,root,root,755)
334 %doc examples/EXPLAIN
335 %{_examplesdir}/parigp
338 %defattr(644,root,root,755)
339 %{_datadir}/parigp/galdata
342 %defattr(644,root,root,755)
343 %attr(755,root,root) %{_bindir}/gp2c*
344 %doc gp2c-%{gp2c_version}/{AUTHORS,ChangeLog,NEWS,README,BUGS,doc/*.{html,png}}
345 %{?with_tex:%doc gp2c-%{gp2c_version}/doc/gp2c.pdf}
346 %{_datadir}/parigp/gp2c
347 %{_mandir}/man1/gp2c*.1*
349 %files -n perl-Math-Pari
350 %defattr(644,root,root,755)
351 %doc Math-Pari-%{math_pari_fversion}/{Changes,README,TODO}
352 %{perl_vendorarch}/Math/Pari.pm
353 %{perl_vendorarch}/Math/PariInit.pm
354 %dir %{perl_vendorarch}/auto/Math/Pari
355 %attr(755,root,root) %{perl_vendorarch}/auto/Math/Pari/Pari.so
356 %{_mandir}/man3/Math::Pari.3pm*
357 %{_mandir}/man3/Math::PariInit.3pm*
358 %{_mandir}/man3/Math::libPARI.3pm*
359 %{_mandir}/man3/Math::libPARI.dumb.3pm*