]> git.pld-linux.org Git - packages/parigp.git/blame - parigp.spec
- rebuild with readline 7.0
[packages/parigp.git] / parigp.spec
CommitLineData
56f71478 1#
90c38ece 2# Conditional build:
3%bcond_without tex # don't build tex documentation
56f71478 4#
1d785e6a 5%include /usr/lib/rpm/macros.perl
c1170d84
MK
6%define pari_version 2.5.5
7%define gp2c_version 0.0.8
bc327ffe 8%define math_pari_version 2.01080605
dd89a8b7 9Summary: Number Theory-oriented Computer Algebra System
434b919b 10Summary(pl.UTF-8): Komputerowy system obliczeń algebraicznych zorientowany na metody teorii liczb
dd89a8b7 11Name: parigp
c8d4b162 12Version: %{pari_version}
5c44a449 13Release: 9
466800ee 14License: GPL
dd89a8b7 15Group: Applications/Math
bfae4dfe 16Source0: ftp://megrez.math.u-bordeaux.fr/pub/pari/unix/pari-%{pari_version}.tar.gz
c1170d84 17# Source0-md5: fbd6402f8d3d3213b0633ab9ef4a63d0
2fe27273
JR
18Source1: ftp://megrez.math.u-bordeaux.fr/pub/pari/packages/galdata.tgz
19# Source1-md5: f9f61b2930757a785b568e5d307a7d75
446a2143 20Source2: ftp://megrez.math.u-bordeaux.fr/pub/pari/GP2C/gp2c-%{gp2c_version}.tar.gz
c1170d84 21# Source2-md5: b29599e06aea3b0a7d370de3d955fdb2
6087df7e 22Source3: http://www.cpan.org/modules/by-module/Math/Math-Pari-%{math_pari_version}.tar.gz
bc327ffe 23# Source3-md5: ccb3da2bdce184a5df3f52cfa8b43a85
1d785e6a 24Source4: %{name}.desktop
95882164 25Source5: %{name}.png
24b72da1
JR
26Patch0: %{name}-target_arch.patch
27Patch1: %{name}-termcap.patch
28Patch2: %{name}-arch.patch
c1170d84
MK
29Patch3: perl-Math-Pari-crash-workaround.patch
30Patch4: perl-Math-Pari-update.patch
5b9ede90 31Patch5: %{name}-noproccpuinfo.patch
e6713c66 32Patch6: gmp-version.patch
3c0d90f0 33URL: http://pari.math.u-bordeaux.fr/
c8d4b162 34BuildRequires: autoconf
bc327ffe 35BuildRequires: ctags
e6713c66 36BuildRequires: gmp-devel
56f71478 37BuildRequires: perl-devel >= 1:5.8.0
e07df94b 38BuildRequires: readline-devel >= 4.2
c8d4b162 39BuildRequires: rpm-perlprov >= 3.0.3-16
90c38ece 40%if %{with tex}
88d21d33
JR
41BuildRequires: texlive
42BuildRequires: texlive-amstex
43BuildRequires: texlive-csplain
44BuildRequires: texlive-dvips
45BuildRequires: texlive-fonts-cm
65cd5e24 46BuildRequires: texlive-format-pdflatex
88d21d33
JR
47BuildRequires: texlive-plain
48BuildRequires: texlive-pdftex
49BuildRequires: texlive-tex-babel
50BuildRequires: texlive-tex-ruhyphen
90c38ece 51%endif
101d00e8 52BuildRequires: xorg-lib-libX11-devel
24b72da1 53BuildRequires: xorg-util-imake
56f71478 54Requires: pari = %{pari_version}-%{release}
9a83e110 55Requires: xdvi
f3b4af7f 56BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
dd89a8b7 57
dd89a8b7 58%description
c4d271de 59PARI/GP is a package which is aimed at efficient computations in
f3b4af7f 60number theory, but also contains a large number of other useful
61functions. It is somewhat related to a Computer Algebra System, but is
62not really one since it treats symbolic expressions as mathematical
63entities such as matrices, polynomials, series, etc..., and not as
64expressions per se. However it is often much faster than other CAS,
65and contains a large number of specific functions not found elsewhere,
66essentially for use in number theory.
dd89a8b7 67
6f6f7023
JR
68%description -l pl.UTF-8
69System PARI/GP jest przeznaczony do wydajnych obliczeń z zakresu
70teorii liczb, ale zawiera również inne przydatne funkcje. Jest nieco
f3b4af7f 71spokrewniony z Komputerowymi Systemami Algebraicznymi, ale nie
6f6f7023
JR
72identyczny, ponieważ traktuje wyrażenia symboliczne jako obiekty
73matematyczne (macierze, wielomiany, szeregi itp.) a nie jako wyrażenia
74same w sobie. Jest jednak często znacznie szybszy od innych KSA-ów a
f3b4af7f 75ponadto zawiera wiele innych funkcji nie spotykanych gdzie indziej, a
6f6f7023 76przydatnych zwłaszcza w teorii liczb.
dd89a8b7
RW
77
78%package -n pari
79Summary: Shared PARI library (required by the parigp package)
434b919b 80Summary(pl.UTF-8): Biblioteka współdzielona PARI (wymagana przez pakiet parigp)
f3b4af7f 81Group: Libraries
dd89a8b7
RW
82
83%description -n pari
c4d271de 84Shared PARI library. You need it to run PARI/GP.
dd89a8b7 85
6f6f7023
JR
86%description -n pari -l pl.UTF-8
87Biblioteka współdzielona PARI. Potrzebujesz jej do uruchomienia
434a9a07 88PARI/GP.
dd89a8b7
RW
89
90%package -n pari-devel
91Summary: Include files for PARI shared library
434b919b 92Summary(pl.UTF-8): Pliki nagłówkowe do biblioteki współdzielonej PARI
f3b4af7f 93Group: Development/Libraries
56f71478 94Requires: pari = %{pari_version}-%{release}
dd89a8b7
RW
95
96%description -n pari-devel
f3b4af7f 97Include files for shared PARI library. You need them to use PARI
98routines in you own programs.
dd89a8b7 99
6f6f7023
JR
100%description -n pari-devel -l pl.UTF-8
101Pliki nagłówkowe biblioteki współdzielonej PARI. Będziesz ich
102potrzebował, jeżeli będziesz chciał wykorzystywać procedury PARI w
f3b4af7f 103swoich programach.
dd89a8b7 104
86e1d1c3
RW
105%package -n pari-static
106Summary: Static PARI library
434b919b 107Summary(pl.UTF-8): Statyczna biblioteka PARI
86e1d1c3 108Group: Development/Libraries
56f71478 109Requires: pari-devel = %{pari_version}-%{release}
dd89a8b7 110
86e1d1c3 111%description -n pari-static
434a9a07 112Static PARI library. You need it to statically link your programs with
113PARI.
dd89a8b7 114
6f6f7023 115%description -n pari-static -l pl.UTF-8
434a9a07 116Biblioteka statyczna PARI. Potrzebujesz jej do konsolidowania
6f6f7023 117statycznego swoich programów korzystających z biblioteki PARI.
dd89a8b7
RW
118
119%package demos
c4d271de 120Summary: Example PARI/GP scripts
434b919b 121Summary(pl.UTF-8): Przykładowe skrypty pisane w języku PARI/GP
f3b4af7f 122Group: Applications/Math
56f71478 123Requires: %{name} = %{pari_version}-%{release}
dd89a8b7
RW
124
125%description demos
c4d271de 126Example PARI/GP scripts. You can write such programs on your own.
dd89a8b7 127
6f6f7023
JR
128%description demos -l pl.UTF-8
129Przykładowe skrypty pisane w języku PARI/GP. Sam możesz takie napisać.
dd89a8b7
RW
130
131%package galdata
c4d271de 132Summary: Galois data resolvents for PARI/GP
434b919b 133Summary(pl.UTF-8): Reprezentacje danych Galois fla PARI/GP
f3b4af7f 134Group: Applications/Math
56f71478 135Requires: %{name} = %{pari_version}-%{release}
dd89a8b7
RW
136
137%description galdata
c4d271de 138Galois data resolvents for PARI/GP.
dd89a8b7 139
6f6f7023 140%description galdata -l pl.UTF-8
c4d271de 141Reprezentacje danych Galois do PARI/GP.
dd89a8b7 142
446a2143 143%package gp2c
be3def7b 144Summary: PARI/GP to C translator
434b919b 145Summary(pl.UTF-8): Konwerter skryptów PARI/GP do języka C
0741c06b 146Version: %{gp2c_version}
b628e85a 147Epoch: 1
446a2143 148Group: Development/Tools
56f71478
JB
149Requires: pari-devel = %{pari_version}-%{release}
150Requires: %{name} = %{pari_version}-%{release}
446a2143
RW
151
152%description gp2c
434a9a07 153PARI/GP to C translator. Use it to compile your own C programs which
36af16a6
JB
154use pari library, without necessarily being a C programmer. Note: use
155gp2c-run to run your programs inside the PARI/GP environment.
446a2143 156
6f6f7023
JR
157%description gp2c -l pl.UTF-8
158Konwerter skryptów PARI/GP do języka C. Można nim tworzyć własne
159programy w C korzystające z biblioteki pari. Znajomość języka C nie
160jest wymagana. Uwaga: do uruchamiania programów w środowisku PARI/GP
161należy używać gp2c-run.
446a2143 162
1d785e6a 163%package -n perl-Math-Pari
164Summary: Math-Pari perl module
434b919b 165Summary(pl.UTF-8): Moduł perla Math-Pari
c8d4b162 166Version: %{math_pari_version}
1d785e6a 167Group: Development/Languages/Perl
1d785e6a 168
169%description -n perl-Math-Pari
36af16a6 170The Perl interface to the PARI part of GP/PARI.
1d785e6a 171
6f6f7023 172%description -n perl-Math-Pari -l pl.UTF-8
36af16a6 173Interfejs Perla do biblioteki PARI.
1d785e6a 174
dd89a8b7 175%prep
c8d4b162 176%setup -q -n pari-%{pari_version} -a 2 -a 3
24b72da1
JR
177%patch0 -p1
178%patch1 -p1
21e9bc09 179%patch2 -p1
eaf472d3 180%patch3 -p1
24b72da1 181%patch4 -p1
5b9ede90 182%patch5 -p1
e6713c66 183%patch6 -p1
dd89a8b7
RW
184
185%build
446a2143 186# pari & parigp
e07df94b 187./Configure \
24b72da1 188 --target=%{_target_cpu} \
e07df94b 189 --prefix=%{_prefix} \
6f23328b 190 --libdir=%{_libdir} \
24b72da1
JR
191 --sysdatadir=%{_libdir}/parigp \
192 --datadir=%{_datadir}/parigp \
e6713c66
JR
193 --share-prefix=%{_datadir} \
194 --with-readline-lib=%{_libdir} \
195 --with-ncurses-lib=%{_libdir} \
196 --with-gmp-lib=%{_libdir}
197
dd89a8b7 198
24b72da1 199%{__make} -C Olinux-%{_target_cpu} all \
bc327ffe 200 CC="%{__cc}" \
24b72da1 201 CFLAGS="%{rpmcflags} -fno-strict-aliasing -fomit-frame-pointer -fPIC"
cfe6cbf8 202
bc327ffe
JB
203%{__make} ctags
204
df89f095 205%{?with_tex:%{__make} -j1 -C doc docpdf}
e6713c66
JR
206%ifarch x32
207ln -s Olinux-%{_target_cpu} Olinux-x86_64
208%endif
eaf472d3 209%ifarch %{ix86}
210ln -s Olinux-%{_target_cpu} Olinux-ix86
211%endif
d73dc01e
JB
212%ifarch sparc sparc64
213# allow building sparc package on sparc64
214ln -s Olinux-sparc Olinux-sparc64
215%endif
dd89a8b7 216
446a2143
RW
217# gp2c
218cd gp2c-%{gp2c_version}
24b72da1 219
e647ea60 220ln -sf .. pari
66b05270 221%{__autoconf}
446a2143
RW
222%configure \
223 --datadir=%{_datadir}/parigp
24b72da1 224
446a2143 225%{__make}
be033589 226%{?with_tex:%{__make} -j1 -C doc docall}
24b72da1 227
1d785e6a 228cd ..
229
230# math-pari
c8d4b162 231cd Math-Pari-%{math_pari_version}
bc327ffe
JB
232cp -f ../Olinux-%{_target_cpu}/paricfg.h libPARI/paricfg.h
233echo '#define DL_DFLT_NAME NULL' >>libPARI/paricfg.h
24b72da1 234
c6321049 235%{__perl} Makefile.PL \
236 INSTALLDIRS=vendor
24b72da1 237
56f71478 238%{__make} \
bc327ffe 239 OPTIMIZE="%{rpmcflags} -I$(pwd)/../Olinux-%{_target_cpu}"
24b72da1 240
471f6a05 241# %{__make} test
28a3c1d0 242
dd89a8b7
RW
243%install
244rm -rf $RPM_BUILD_ROOT
56f71478
JB
245install -d $RPM_BUILD_ROOT{%{_datadir}/parigp/galdata,%{_examplesdir}/parigp} \
246 $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir}}
dd89a8b7
RW
247
248# parigp, pari & pari-devel
c6321049 249%{__make} install \
250 DESTDIR=$RPM_BUILD_ROOT
56f71478 251
a1fc7ab1 252install src/tags $RPM_BUILD_ROOT%{_datadir}/parigp/misc
56f71478 253install %{SOURCE4} $RPM_BUILD_ROOT%{_desktopdir}
8f98520d 254install %{SOURCE5} $RPM_BUILD_ROOT%{_pixmapsdir}
dd89a8b7 255
86e1d1c3 256# pari-static
a1fc7ab1 257install Olinux-%{_target_cpu}/libpari.a $RPM_BUILD_ROOT%{_libdir}/libpari.a
dd89a8b7
RW
258
259# parigp-demos
a1fc7ab1 260install examples/* $RPM_BUILD_ROOT%{_examplesdir}/parigp
dd89a8b7
RW
261
262# galdata
56f71478 263tar zxvf %{SOURCE1} -C $RPM_BUILD_ROOT%{_datadir}/parigp/galdata
dd89a8b7 264
446a2143 265# gp2c
cfe6cbf8 266%{__make} install -C gp2c-%{gp2c_version} \
446a2143 267 DESTDIR=$RPM_BUILD_ROOT
446a2143 268
1d785e6a 269# math-pari
cfe6cbf8 270%{__make} install -C Math-Pari-%{math_pari_version} \
1d785e6a 271 DESTDIR=$RPM_BUILD_ROOT
1d785e6a 272
bc327ffe 273%{__rm} $RPM_BUILD_ROOT%{_mandir}/man1/pari.1
cce86261
JB
274echo ".so gp.1" > $RPM_BUILD_ROOT%{_mandir}/man1/pari.1
275
bc327ffe
JB
276%{__rm} -r $RPM_BUILD_ROOT%{_datadir}/parigp/{examples,doc}
277%{__rm} $RPM_BUILD_ROOT%{perl_vendorarch}/Math/libPARI*.pod
24b72da1 278
dd89a8b7
RW
279%clean
280rm -rf $RPM_BUILD_ROOT
281
7fc9b10b
JB
282%post -n pari -p /sbin/ldconfig
283%postun -n pari -p /sbin/ldconfig
284
dd89a8b7
RW
285%files
286%defattr(644,root,root,755)
bc327ffe
JB
287%doc AUTHORS CHANGES* COMPAT MACHINES NEW README examples/Inputrc %{?with_tex:doc/*.pdf}
288%attr(755,root,root) %{_bindir}/gp-2.5
dd89a8b7
RW
289%attr(755,root,root) %{_bindir}/gp
290%attr(755,root,root) %{_bindir}/gphelp
291%attr(755,root,root) %{_bindir}/tex2mail
dd89a8b7 292%dir %{_datadir}/parigp
bc327ffe 293%{_datadir}/parigp/PARI
846279c1 294%{_datadir}/parigp/misc
24b72da1 295%{_datadir}/parigp/pari.desc
cfe6cbf8 296%{_mandir}/man1/[!g]*.1*
ed10f0d4 297%{_mandir}/man1/gp.1*
24b72da1 298%{_mandir}/man1/gp-*.1*
ed10f0d4 299%{_mandir}/man1/gphelp.1*
bc327ffe
JB
300%{_desktopdir}/parigp.desktop
301%{_pixmapsdir}/parigp.png
dd89a8b7
RW
302
303%files -n pari
f3b4af7f 304%defattr(644,root,root,755)
bc327ffe
JB
305%attr(755,root,root) %{_libdir}/libpari-gmp.so.*.*.*
306%ghost %attr(755,root,root) %{_libdir}/libpari-gmp.so.3
307%{_libdir}/parigp
dd89a8b7
RW
308
309%files -n pari-devel
f3b4af7f 310%defattr(644,root,root,755)
24b72da1 311%attr(755,root,root) %{_libdir}/libpari.so
cfe6cbf8 312%{_includedir}/pari
dd89a8b7 313
86e1d1c3 314%files -n pari-static
dd89a8b7 315%defattr(644,root,root,755)
24b72da1 316%{_libdir}/libpari.a
dd89a8b7
RW
317
318%files demos
f3b4af7f 319%defattr(644,root,root,755)
c8d4b162 320%doc examples/EXPLAIN
846279c1 321%{_examplesdir}/parigp
dd89a8b7
RW
322
323%files galdata
f3b4af7f 324%defattr(644,root,root,755)
cfa61620 325%{_datadir}/parigp/galdata
76dd33b2 326
446a2143
RW
327%files gp2c
328%defattr(644,root,root,755)
4a006b16 329%attr(755,root,root) %{_bindir}/gp2c*
24b72da1
JR
330%doc gp2c-%{gp2c_version}/{AUTHORS,ChangeLog,NEWS,README,BUGS,doc/*.{html,png}}
331%{?with_tex:%doc gp2c-%{gp2c_version}/doc/gp2c.pdf}
846279c1 332%{_datadir}/parigp/gp2c
ed10f0d4 333%{_mandir}/man1/gp2c*.1*
1d785e6a 334
335%files -n perl-Math-Pari
336%defattr(644,root,root,755)
c8d4b162 337%doc Math-Pari-%{math_pari_version}/{Changes,README,TODO}
bc327ffe
JB
338%{perl_vendorarch}/Math/Pari.pm
339%{perl_vendorarch}/Math/PariInit.pm
c6321049 340%dir %{perl_vendorarch}/auto/Math/Pari
c6321049 341%attr(755,root,root) %{perl_vendorarch}/auto/Math/Pari/Pari.so
bc327ffe
JB
342%{_mandir}/man3/Math::Pari.3pm*
343%{_mandir}/man3/Math::PariInit.3pm*
344%{_mandir}/man3/Math::libPARI.3pm*
345%{_mandir}/man3/Math::libPARI.dumb.3pm*
This page took 2.17348 seconds and 4 git commands to generate.