]> git.pld-linux.org Git - packages/R.git/blob - R.spec
d76df9077245ad84613e15269d505c0a98d2dfa6
[packages/R.git] / R.spec
1 #
2 # Conditional build
3 %bcond_without  tcl             # disable tcl support
4 %bcond_without  tests           # do not run "make check"
5 #
6 # TODO:
7 # - WTF is empty -recommended package with P/O which belong to -base ???
8 # - script for rpm to autoprovides/autorequires R internals
9 #
10 %define KernSmooth_version      2.22r19
11 %define VR_version              7.2r30
12 %define boot_version            1.2r27
13 %define cluster_version         1.11.4
14 %define foreign_version         0.8r18
15 %define lattice_version         0.14r16
16 %define mgcv_version            1.3r22
17 %define nlme_version            3.1r78
18 %define rpart_version           3.1r33
19 %define survival_version        2.30
20
21 %include        /usr/lib/rpm/macros.perl
22 Summary:        A language for data analysis and graphics
23 Summary(pl.UTF-8):      Język do analizy danych oraz grafiki
24 Name:           R
25 Version:        2.6.1
26 Release:        2
27 License:        Mixed (distributable), mostly GPL
28 Group:          Development/Languages
29 # CRAN master site: ftp://cran.r-project.org/pub/R/src/
30 Source0:        ftp://stat.ethz.ch/R-CRAN/src/base/R-2/%{name}-%{version}.tar.gz
31 # Source0-md5:  19c35a69e1afa73f5f70f91ff9939233
32 Source1:        %{name}.desktop
33 URL:            http://www.r-project.org/
34 BuildRequires:  autoconf
35 BuildRequires:  automake
36 BuildRequires:  blas-devel
37 BuildRequires:  bzip2-devel
38 BuildRequires:  gcc-c++
39 BuildRequires:  gcc-fortran
40 BuildRequires:  gettext-devel
41 BuildRequires:  lapack-devel >= 3.1.1-4
42 BuildRequires:  libjpeg-devel >= 6b
43 BuildRequires:  libpng-devel >= 1.0.5
44 BuildRequires:  libstdc++-devel
45 BuildRequires:  libtool
46 BuildRequires:  libxml2-devel >= 2.6.26
47 BuildRequires:  pcre-devel
48 BuildRequires:  perl-base >= 1:5.6
49 BuildRequires:  readline-devel
50 BuildRequires:  rpm-perlprov
51 %{?with_tcl:BuildRequires:      tcl-devel}
52 BuildRequires:  tetex-dvips
53 BuildRequires:  tetex-latex
54 BuildRequires:  tetex-pdftex
55 %{?with_tcl:BuildRequires:      tk-devel}
56 BuildRequires:  xorg-lib-libX11-devel
57 BuildRequires:  xorg-lib-libXmu-devel
58 BuildRequires:  xorg-lib-libXt-devel
59 BuildRequires:  zip
60 BuildRequires:  zlib-devel >= 1.1.3
61 #Requires:      lpr
62 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
63
64 %description
65 A system for statistical computation and graphics. R consists of a
66 language plus a run-time environment with graphics, a debugger, access
67 to certain system functions, and the ability to run programs stored in
68 script files.
69
70 The design of R has been heavily influenced by two existing languages:
71 Becker, Chambers & Wilks' S and Sussman's Scheme. Whereas the
72 resulting language is very similar in appearance to S, the underlying
73 implementation and semantics are derived from Scheme.
74
75 %description -l pl.UTF-8
76 System do obliczeń statystycznych i grafiki. R składa się z języka
77 oraz środowiska uruchomieniowego z grafiką, debuggerem, dostępem do
78 niektórych funkcji systemowych oraz możliwością uruchamiania programów
79 zapisanych w skryptach.
80
81 Język R był zainspirowany dwoma istniejącymi językami: S (Beckera,
82 Chambersa i Wilksa) oraz Scheme (Sussmana). R jest podobny do S, ale
83 implementacja i semantyka wywodzi się ze Scheme.
84
85 %package base
86 Summary:        The R base distribution
87 Summary(pl.UTF-8):      Podstawowa dystrybucja R
88 License:        GPL v2 / LGPL
89 Group:          Development/Languages
90 Requires(post): perl-base
91 Requires(post): textutils
92 Provides:       R-cran-base
93 Provides:       R-cran-datasets
94 Provides:       R-cran-grDevices
95 Provides:       R-cran-graphics
96 Provides:       R-cran-grid
97 Provides:       R-cran-methods
98 Provides:       R-cran-splines
99 Provides:       R-cran-stats
100 Provides:       R-cran-stats4
101 Provides:       R-cran-tcltk
102 Provides:       R-cran-tools
103 Provides:       R-cran-utils
104
105 %description base
106 R is a language and run-time environment for carrying out interactive
107 statistical data analysis. It is not entirely dissimilar to the S
108 language developed at AT&T Bell Laboratories (and now Lucent
109 Technologies). Indeed, S users will find the environment quite
110 familiar and a good deal of S software will run without change under
111 R.
112
113 %description base -l pl.UTF-8
114 R jest językiem i środowiskiem uruchomieniowym do interaktywnej
115 analizy danych statystycznych. R nie jest całkowicie zgodny z językiem
116 S opracowanym w AT&T Bell Laboratiories (a teraz Lucent Technologies),
117 mimo to użytkownicy S zauważą zbliżone środowisko, a duża część
118 oprogramowania w S będzie działała bez zmian w R.
119
120 %package recommended
121 Summary:        Recommended contributed packages for the R language
122 Summary(pl.UTF-8):      Zalecane dodatkowe pakiety do języka R
123 License:        GPL, free or free for non-commercial use
124 Group:          Development/Languages
125 URL:            http://www.ci.tuwien.ac.at/R/
126 Requires(post,postun):  R-base = %{version}-%{release}
127 Requires(post,postun):  perl-base
128 Requires(post,postun):  textutils
129 Requires:       R-base = %{version}-%{release}
130 Provides:       R-cran-KernSmooth = %{KernSmooth_version}
131 Provides:       R-cran-MASS = %{VR_version}
132 Provides:       R-cran-VR = %{VR_version}
133 Provides:       R-cran-boot = %{boot_version}
134 Provides:       R-cran-class = %{VR_version}
135 Provides:       R-cran-cluster = %{cluster_version}
136 Provides:       R-cran-foreign = %{foreign_version}
137 Provides:       R-cran-lattice = %{lattice_version}
138 Provides:       R-cran-mgcv = %{mgcv_version}
139 Provides:       R-cran-nlme = %{nlme_version}
140 Provides:       R-cran-nnet = %{VR_version}
141 Provides:       R-cran-rpart = %{rpart_version}
142 Provides:       R-cran-spatial = %{VR_version}
143 Provides:       R-cran-survival = %{survival_version}
144 Obsoletes:      R-contrib
145 Obsoletes:      R-cran-KernSmooth
146 Obsoletes:      R-cran-MASS
147 Obsoletes:      R-cran-VR
148 Obsoletes:      R-cran-boot
149 Obsoletes:      R-cran-class
150 Obsoletes:      R-cran-cluster
151 Obsoletes:      R-cran-foreign
152 Obsoletes:      R-cran-lattice
153 Obsoletes:      R-cran-mgcv
154 Obsoletes:      R-cran-nlme
155 Obsoletes:      R-cran-nnet
156 Obsoletes:      R-cran-rpart
157 Obsoletes:      R-cran-spatial
158 Obsoletes:      R-cran-survival
159
160 %description recommended
161 Packages which extend the capabilities of the R base distribution and
162 are distributed on the Comprehensive R Archive Network (CRAN).
163
164 %description recommended -l pl.UTF-8
165 Pakiety rozszerzające możliwości podstawowej dystrybucji języka R,
166 dystrubuowane w archiwum CRAN (Comprehensive R Archive Network).
167
168 %prep
169 %setup -q
170
171 %build
172 %configure \
173         --enable-R-shlib \
174         --enable-linux-lfs \
175         --with-system-zlib \
176         --with-system-bzlib \
177         --with-system-pcre \
178         --with-libpng \
179         --with-jpeglib \
180         --with-blas \
181         --with-lapack \
182         --with-readline \
183         --with%{!?with_tcl:out}-tcltk \
184         --with-recommended-packages
185
186 %{__make}
187 %if %{with tests}
188 %{__make} check
189 %endif
190 %{__make} docs help html info
191
192 %install
193 rm -rf $RPM_BUILD_ROOT
194 install -d $RPM_BUILD_ROOT{%{_bindir},%{_mandir}/man1,%{_libdir}/R,%{_includedir},%{_desktopdir}}
195 install -d $RPM_BUILD_ROOT%{perl_vendorlib}/{R,Text}
196
197 %{__make} install \
198         DESTDIR=$RPM_BUILD_ROOT
199
200 install %{SOURCE1} $RPM_BUILD_ROOT%{_desktopdir}
201
202 find $RPM_BUILD_ROOT%{_libdir}/R -name 'Makefile*' -exec rm -f {} \;
203 mv $RPM_BUILD_ROOT%{_libdir}/R/lib/libR*.so $RPM_BUILD_ROOT%{_libdir}
204 mv $RPM_BUILD_ROOT%{_libdir}/%{name}/include $RPM_BUILD_ROOT%{_includedir}/R
205 ln -sf %{_includedir}/R $RPM_BUILD_ROOT%{_libdir}/R/include
206 rm $RPM_BUILD_ROOT%{_bindir}/%{name}
207 sed -i -e "s#$RPM_BUILD_ROOT##g" $RPM_BUILD_ROOT%{_libdir}/%{name}/bin/%{name}
208 ln -sf %{_libdir}/%{name}/bin/%{name} $RPM_BUILD_ROOT%{_bindir}/%{name}
209
210 (cd $RPM_BUILD_ROOT%{_libdir}/%{name}/share/perl/R/
211 for f in * ; do
212   ln -s %{_libdir}/%{name}/share/perl/R/$f $RPM_BUILD_ROOT%{perl_vendorlib}/R/
213 done)
214 (cd $RPM_BUILD_ROOT%{_libdir}/%{name}/share/perl/Text
215 for f in * ; do
216   ln -s %{_libdir}/%{name}/share/perl/Text/$f $RPM_BUILD_ROOT%{perl_vendorlib}/Text/
217 done)
218
219 rm -r $RPM_BUILD_ROOT%{perl_vendorlib}/{Text,R}
220 rm -r $RPM_BUILD_ROOT%{_libdir}/R/share/perl/{File,Text}
221 mv    $RPM_BUILD_ROOT%{_libdir}/R/share/perl/R $RPM_BUILD_ROOT%{perl_vendorlib}
222
223 %clean
224 rm -rf $RPM_BUILD_ROOT
225
226 %post
227 (cd %{_libdir}/R/library; umask 022; cat */CONTENTS > ../doc/html/search/index.txt
228  R_HOME=%{_libdir}/R ../bin/Rcmd perl ../share/perl/build-help.pl --index)
229 /sbin/ldconfig
230
231 %postun -p /sbin/ldconfig
232
233 %files base
234 %defattr(644,root,root,755)
235 %doc NEWS README doc/{AUTHORS,COPYRIGHTS,FAQ,RESOURCES,THANKS}
236
237 %{_mandir}/man1/R.1*
238 %{_mandir}/man1/Rscript*
239 %attr(755,root,root) %{_bindir}/R
240 %attr(755,root,root) %{_bindir}/Rscript
241 %dir %{_libdir}/R
242 %attr(755,root,root) %{_libdir}/R/bin
243 %attr(755,root,root) %{_libdir}/libR*.so
244 %{_libdir}/R/etc
245 %{_libdir}/R/include
246 %{_includedir}/R
247 %{_libdir}/R/share
248 %{_libdir}/R/COPYING
249 %{_libdir}/R/NEWS
250 %{_libdir}/R/SVN-REVISION
251 %dir %{_libdir}/R/library
252 %{_libdir}/%{name}/library/R.css
253 # %{_libdir}/R/doc %except %{_libdir}/R/doc/html/{packages.html,search/index.txt}
254 %dir %{_libdir}/R/doc
255 %{_libdir}/R/doc/[KRm]*
256 %dir %{_libdir}/R/doc/html
257 %{_libdir}/R/doc/html/*.css
258 %{_libdir}/R/doc/html/[Ra-lr-u]*.html
259 %{_libdir}/R/doc/html/packages-head*.html
260 %{_libdir}/R/doc/html/*.jpg
261 %dir %{_libdir}/R/doc/html/search
262 %{_libdir}/R/doc/html/search/[A-Z]*
263 %ghost %{_libdir}/R/doc/html/search/index.txt
264 %ghost %{_libdir}/R/doc/html/packages.html
265 %{_desktopdir}/*.desktop
266
267 %{perl_vendorlib}/R
268
269 %attr(755,root,root) %{_libdir}/%{name}/modules
270
271 %{_libdir}/%{name}/library/KernSmooth
272 %{_libdir}/%{name}/library/MASS
273 %{_libdir}/%{name}/library/base
274 %{_libdir}/%{name}/library/boot
275 %{_libdir}/%{name}/library/class
276 %{_libdir}/%{name}/library/cluster
277 %{_libdir}/%{name}/library/codetools
278 %{_libdir}/%{name}/library/datasets
279 %{_libdir}/%{name}/library/foreign
280 %{_libdir}/%{name}/library/grDevices
281 %{_libdir}/%{name}/library/graphics
282 %{_libdir}/%{name}/library/grid
283 %{_libdir}/%{name}/library/lattice
284 %{_libdir}/%{name}/library/methods
285 %{_libdir}/%{name}/library/mgcv
286 %{_libdir}/%{name}/library/nlme
287 %{_libdir}/%{name}/library/nnet
288 %{_libdir}/%{name}/library/rcompgen
289 %{_libdir}/%{name}/library/rpart
290 %{_libdir}/%{name}/library/spatial
291 %{_libdir}/%{name}/library/survival
292 %{_libdir}/%{name}/library/splines
293 %{_libdir}/%{name}/library/stats
294 %{_libdir}/%{name}/library/stats4
295 %{_libdir}/%{name}/library/tcltk
296 %{_libdir}/%{name}/library/tools
297 %{_libdir}/%{name}/library/utils
298
299 %{_pkgconfigdir}/*.pc
300
301 %files recommended
302 %defattr(644,root,root,755)
This page took 0.392044 seconds and 3 git commands to generate.