]>
Commit | Line | Data |
---|---|---|
198b2d1a | 1 | # TODO: |
198b2d1a JR |
2 | # - include ext/ in docs |
3 | # - replace ri with fastri | |
97b7914a | 4 | # - patch ri to search multiple indexes (one per package), so RPMs can install ri docs |
0b1956f4 | 5 | # - fix inconsistencies with versioned vs not-versioned dirs (see dirname hacks in configure) |
44802bd7 | 6 | # - custom-rubygems-location.patch |
198b2d1a | 7 | # |
2acc5f17 | 8 | # Conditional build: |
bc991d5a | 9 | %bcond_without doc # skip (time-consuming) docs generating; intended for speed up test builds |
bc991d5a | 10 | %bcond_without tk # skip building package with Tk bindings |
05f75f09 | 11 | %bcond_without batteries # Don't include rubygems, json, rake, minitest |
9c41e51a | 12 | %bcond_without default_ruby # use this Ruby as default system Ruby |
92ff5331 | 13 | %bcond_with bootstrap # build bootstrap version |
fa311386 | 14 | |
45f22c60 ER |
15 | %define rel 0.1 |
16 | %define ruby_version 2.0 | |
17 | %define ver_suffix 20 | |
18 | %define basever 2.0.0 | |
19 | %define patchlevel 353 | |
9c41e51a ER |
20 | |
21 | %define ruby_suffix %{!?with_default_ruby:%{ver_suffix}} | |
ee1a9db5 | 22 | %define doc_version 1_9_3 |
45f22c60 ER |
23 | |
24 | %define bigdecimal_ver 1.2.0 | |
25 | %define io_console_ver 0.4.2 | |
d8228776 | 26 | %define irb_ver 0.9.6 |
45f22c60 ER |
27 | %define json_ver 1.7.7 |
28 | %define minitest_ver 4.3.2 | |
29 | %define psych_ver 2.0.0 | |
30 | %define rake_ver 0.9.6 | |
31 | %define rdoc_ver 4.0.0 | |
32 | %define rubygems_ver 2.0.14 | |
33 | %define test_unit_ver 2.0.0.0 | |
34 | ||
9c41e51a | 35 | %define oname ruby |
6e2f9b3c | 36 | Summary: Ruby - interpreted scripting language |
3c3949cf ER |
37 | Summary(ja.UTF-8): オブジェクト指向言語Rubyインタプリタ |
38 | Summary(pl.UTF-8): Ruby - interpretowany język skryptowy | |
39 | Summary(pt_BR.UTF-8): Linguagem de script orientada a objeto | |
40 | Summary(zh_CN.UTF-8): ruby - 一种快速高效的面向对象脚本编程语言 | |
9c41e51a | 41 | Name: ruby%{ruby_suffix} |
6cd63ddf | 42 | Version: %{basever}.%{patchlevel} |
116a558f | 43 | Release: %{rel} |
01204e8f | 44 | Epoch: 1 |
267654e7 ER |
45 | # Public Domain for example for: include/ruby/st.h, strftime.c, ... |
46 | License: (Ruby or BSD) and Public Domain | |
6eb17ef6 | 47 | Group: Development/Languages |
45f22c60 ER |
48 | Source0: ftp://ftp.ruby-lang.org/pub/ruby/2.0/%{oname}-%{basever}-p%{patchlevel}.tar.bz2 |
49 | # Source0-md5: 20eb8f067d20f6b76b7e16cce2a85a55 | |
9c41e51a | 50 | Source1: http://www.ruby-doc.org/download/%{oname}-doc-bundle.tar.gz |
775b0723 | 51 | # Source1-md5: ad1af0043be98ba1a4f6d0185df63876 |
9c41e51a | 52 | Source2: http://www.ruby-doc.org/downloads/%{oname}_%{doc_version}_stdlib_rdocs.tgz |
775b0723 | 53 | # Source2-md5: ec622612428672c432b6f65dd31a84b5 |
9c41e51a | 54 | Source3: http://www.ruby-doc.org/downloads/%{oname}_%{doc_version}_core_rdocs.tgz |
775b0723 | 55 | # Source3-md5: 1892aadde51d36106c513bced2193dff |
9c41e51a | 56 | Source100: ftp://ftp.ruby-lang.org/pub/ruby/1.8/%{oname}-1.8.7-p330.tar.gz |
92ff5331 | 57 | # Source100-md5: 50a49edb787211598d08e756e733e42e |
af4f9d38 | 58 | Source4: rdoc.1 |
af4f9d38 | 59 | Source5: testrb.1 |
9c41e51a ER |
60 | Patch0: %{oname}-lib64.patch |
61 | Patch1: %{oname}-ffs.patch | |
360c41c0 | 62 | Patch2: fix-bison-invocation.patch |
d78ec589 | 63 | # http://redmine.ruby-lang.org/issues/5231 |
45f22c60 | 64 | #Patch3: disable-versioned-paths.patch |
d78ec589 | 65 | # TODO: Should be submitted upstream? |
45f22c60 | 66 | #Patch4: arch-specific-dir.patch |
d78ec589 | 67 | # http://redmine.ruby-lang.org/issues/5281 |
45f22c60 | 68 | #Patch5: site-and-vendor-arch-flags.patch |
b5465d0c ER |
69 | # Make mkmf verbose by default |
70 | Patch6: mkmf-verbose.patch | |
87688b10 | 71 | Patch7: strip-ccache.patch |
45f22c60 ER |
72 | Patch8: duplicated-paths.patch |
73 | Patch9: DESTDIR.patch | |
74 | Patch10: empty-ruby-version.patch | |
75 | Patch11: rubygems-2.0.0-binary-extensions.patch | |
76 | Patch12: custom-rubygems-location.patch | |
7c36cd5d | 77 | URL: http://www.ruby-lang.org/ |
19b741fe | 78 | BuildRequires: autoconf >= 2.60 |
53c95475 | 79 | BuildRequires: automake |
f2e66748 | 80 | BuildRequires: bison >= 1.875 |
f0eb2dd9 | 81 | BuildRequires: db-devel |
e9f2c6fe | 82 | BuildRequires: gdbm-devel >= 1.8.3 |
9ae7df75 | 83 | BuildRequires: libffi-devel |
1968db6d | 84 | BuildRequires: ncurses-devel |
f33fb184 | 85 | BuildRequires: openssl-devel |
74c8af09 | 86 | BuildRequires: pkgconfig |
933aeb0e | 87 | BuildRequires: readline-devel >= 4.2 |
d25d71f0 | 88 | BuildRequires: rpm-build >= 5.4.10-49 |
c60d9276 ER |
89 | # boostrap needs ruby binary, erb module |
90 | %{!?with_bootstrap:BuildRequires: ruby-modules} | |
0edf5e88 | 91 | %{!?with_bootstrap:BuildRequires: ruby} |
7911cce0 | 92 | BuildRequires: sed >= 4.0 |
92ff5331 | 93 | BuildRequires: yaml-devel |
15ecb21e | 94 | %if %{with tk} |
e14a2f74 | 95 | BuildRequires: tk-devel |
15ecb21e | 96 | %endif |
f0eb2dd9 | 97 | Requires(post,postun): /sbin/ldconfig |
31058abe | 98 | Provides: ruby(ver) = %{ruby_version} |
ee1edb11 | 99 | Obsoletes: ruby-REXML <= 2.4.0-2 |
bb5582fa | 100 | Obsoletes: ruby-doc < 1.8.4 |
ee1edb11 | 101 | Obsoletes: ruby-fastthread <= 0.6.3 |
a2963aa1 JR |
102 | Conflicts: ruby-activesupport < 2.3.11-2 |
103 | Conflicts: ruby-activesupport2 < 2.3.11-2 | |
584b8bcb | 104 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
4ab119cd | 105 | |
2db0575e | 106 | %define ruby_ridir %{_datadir}/ri/%{ruby_version}/system |
45f22c60 ER |
107 | #%define gem_dir %{_datadir}/gems |
108 | #%define gem_dir %{_datadir}/%{oname}/gems/%{ruby_version} | |
109 | %define gem_dir %{_datadir}/%{oname}/%{ruby_version}/gems | |
d78ec589 ER |
110 | |
111 | # The RubyGems library has to stay out of Ruby directory three, since the | |
112 | # RubyGems should be share by all Ruby implementations. | |
5c3d5a0e | 113 | %define rubygems_dir %{_datadir}/rubygems |
d78ec589 | 114 | |
9c41e51a | 115 | %define ruby_archdir %{_libdir}/%{oname}/%{ruby_version} |
45f22c60 | 116 | %define ruby_libarchdir %{_libdir}/%{oname}/%{ruby_version} |
9c41e51a | 117 | %define ruby_libdir %{_datadir}/%{oname}/%{ruby_version} |
d78ec589 ER |
118 | |
119 | # This is the local lib/arch and should not be used for packaging. | |
5c3d5a0e | 120 | %define sitedir site_ruby |
9c41e51a ER |
121 | %define ruby_sitedir %{_prefix}/local/share/%{oname}/%{sitedir} |
122 | %define ruby_sitearchdir %{_prefix}/local/%{_lib}/%{oname}/%{sitedir}/%{ruby_version} | |
123 | %define ruby_sitelibdir %{_prefix}/local/share/%{oname}/%{sitedir}/%{ruby_version} | |
d78ec589 ER |
124 | |
125 | # This is the general location for libs/archs compatible with all | |
126 | # or most of the Ruby versions available in the PLD repositories. | |
5c3d5a0e | 127 | %define vendordir vendor_ruby |
9c41e51a ER |
128 | %define ruby_vendordir %{_datadir}/%{oname}/%{vendordir} |
129 | %define ruby_vendorarchdir %{_libdir}/%{oname}/%{vendordir}/%{ruby_version} | |
130 | %define ruby_vendorlibdir %{_datadir}/%{oname}/%{vendordir}/%{ruby_version} | |
d78ec589 ER |
131 | |
132 | # TODO: drop legacy loadpaths after all ruby modules rebuilt in Th | |
9c41e51a ER |
133 | %define legacy_libdir %{_libdir}/%{oname}/%{ruby_version} |
134 | %define legacy_archdir %{_libdir}/%{oname}/%{ruby_version}/%{_target_cpu}-linux | |
135 | %define legacy_sitedir %{_libdir}/%{oname}/%{sitedir} | |
136 | %define legacy_sitelibdir %{_libdir}/%{oname}/%{sitedir}/%{ruby_version} | |
137 | %define legacy_sitearchdir %{_libdir}/%{oname}/%{sitedir}/%{ruby_version}/%{_target_cpu}-linux | |
138 | %define legacy_vendordir %{_libdir}/%{oname}/%{vendordir} | |
139 | %define legacy_vendorlibdir %{_libdir}/%{oname}/%{vendordir}/%{ruby_version} | |
140 | %define legacy_vendorarchdir %{_libdir}/%{oname}/%{vendordir}/%{ruby_version}/%{_target_cpu}-linux | |
5c3d5a0e ER |
141 | |
142 | %define legacy_siteloadpath %{legacy_sitelibdir}\\0%{legacy_sitearchdir}\\0%{legacy_sitedir} | |
b02dabe9 | 143 | %define legacy_vendorloadpath %{legacy_vendorarchdir} |
5c3d5a0e ER |
144 | %define legacy_loadpath %{legacy_archdir} |
145 | %define legacy_loadpaths %{legacy_siteloadpath}\\0%{legacy_vendorloadpath}\\0%{legacy_loadpath} | |
d78ec589 | 146 | |
8ea447c1 | 147 | # bleh, some nasty (gcc or ruby) bug still not fixed |
cc2dcaa2 | 148 | # (SEGV or "unexpected break" on miniruby run during build) |
8ea447c1 JB |
149 | %define specflags_ia64 -O0 |
150 | ||
88546731 | 151 | # ruby needs frame pointers for correct exception handling |
b66203d6 | 152 | %define specflags_ia32 -fno-omit-frame-pointer |
88546731 | 153 | |
4ab119cd | 154 | %description |
155 | Ruby is the interpreted scripting language for quick and easy | |
156 | object-oriented programming. It has many features to process text | |
157 | files and to do system management tasks (as in Perl). It is simple, | |
158 | straight-forward, extensible, and portable. | |
159 | ||
9fd96af7 | 160 | This package contains only shared library and ruby interpreter. To get |
161 | full-functional ruby environment install ruby-modules package. | |
162 | ||
a0a47c48 JR |
163 | %description -l ja.UTF-8 |
164 | Rubyはシンプルかつ強力なオブジェクト指向スクリプト言語です.Rubyは最初 | |
165 | から純粋なオブジェクト指向言語として設計されていますから,オブジェクト | |
15467dc7 | 166 | 指向プログラミングを手軽に行う事が出来ます.もちろん通常の手続き型のプ ログラミングも可能です. |
7c36cd5d | 167 | |
a0a47c48 JR |
168 | %description -l pl.UTF-8 |
169 | Ruby to interpretowany język skryptowy, w sam raz dla łatwego i | |
170 | szybkiego pisania zorientowanych obiektowo programów. Ma wiele funkcji | |
171 | ułatwiających przetwarzanie plików tekstowych i wykonywanie prac | |
172 | związanych z zarządzaniem systemu (podobnie jak Perl). Jest prosty, | |
173 | rozszerzalny i przenośny. | |
6e2f9b3c | 174 | |
a0a47c48 JR |
175 | Ten pakiet zawiera tylko bibliotekę dzieloną i interpreter ruby. |
176 | Zainstaluj pakiet ruby-modules, jeżeli potrzebujesz w pełni | |
177 | funkcjonalnego środowiska ruby. | |
9fd96af7 | 178 | |
a0a47c48 JR |
179 | %description -l pt_BR.UTF-8 |
180 | Ruby é uma linguagem de script interpretada de programação orientada a | |
181 | objeto. Possui diversas características para processamento de texto. É | |
182 | simples, extensível e direta. | |
7c36cd5d | 183 | |
9fd96af7 | 184 | %package modules |
185 | Summary: Ruby standard modules and utilities | |
3c3949cf | 186 | Summary(pl.UTF-8): Standardowe moduły i narzędzia dla języka Ruby |
9fd96af7 | 187 | Group: Development/Languages |
188 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
b688e9a5 | 189 | Suggests: ruby-rubygems |
ee1edb11 ER |
190 | Provides: ruby-bigdecimal = %{bigdecimal_ver} |
191 | Provides: ruby-io-console = %{io_console_ver} | |
05f75f09 ER |
192 | # ruby-modules deprecated, rpm5 generates ruby(abi) itself |
193 | Provides: ruby-modules(ver) = %{ruby_version} | |
194 | %if %{with batteries} | |
ee1edb11 | 195 | Provides: ruby-minitest = %{minitest_ver} |
ee1edb11 | 196 | Obsoletes: ruby-minitest <= 1.5.0 |
05f75f09 | 197 | %endif |
9fd96af7 | 198 | |
199 | %description modules | |
200 | Ruby standard modules and utilities: | |
201 | - erb - Tiny eRuby | |
7911cce0 | 202 | - testrb - automatic runner for Test::Unit of Ruby |
9fd96af7 | 203 | |
a0a47c48 JR |
204 | %description modules -l pl.UTF-8 |
205 | Standardowe moduły i narzędzia Ruby: | |
206 | - erb - mały eRuby | |
7911cce0 | 207 | - testrb - automatyczny runner dla Ruby Test::Unit |
9fd96af7 | 208 | |
265d0efe | 209 | %package tk |
210 | Summary: Ruby/Tk bindings | |
3c3949cf | 211 | Summary(pl.UTF-8): Wiązania Ruby/Tk |
e65aac33 | 212 | Group: Development/Languages |
69b51dc9 | 213 | Requires: %{name}-modules = %{epoch}:%{version}-%{release} |
265d0efe | 214 | |
215 | %description tk | |
45f22c60 | 216 | This package contains Ruby/Tk bindings. |
e65aac33 | 217 | |
a0a47c48 JR |
218 | %description tk -l pl.UTF-8 |
219 | Ten pakiet zawiera wiązania Ruby/Tk. | |
265d0efe | 220 | |
e14a2f74 | 221 | %package devel |
e14a2f74 | 222 | Summary: Ruby development libraries |
3c3949cf | 223 | Summary(pl.UTF-8): Biblioteki programistyczne interpretera języka Ruby |
9434194f | 224 | Group: Development/Languages |
9fd96af7 | 225 | Requires: %{name}-modules = %{epoch}:%{version}-%{release} |
92f362b7 ER |
226 | Requires: gcc |
227 | Requires: glibc-devel | |
b5465d0c | 228 | Requires: pkgconfig |
e14a2f74 | 229 | |
230 | %description devel | |
9434194f JB |
231 | Ruby development libraries. |
232 | ||
a0a47c48 JR |
233 | %description devel -l pl.UTF-8 |
234 | Biblioteki programistyczne interpretera języka Ruby. | |
e14a2f74 | 235 | |
87b9c30a | 236 | %package static |
237 | Summary: Ruby static libraries | |
3c3949cf | 238 | Summary(pl.UTF-8): Biblioteki statyczne Ruby |
87b9c30a | 239 | Group: Development/Languages |
f89d855e | 240 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} |
87b9c30a | 241 | |
242 | %description static | |
243 | Ruby static libraries. | |
244 | ||
a0a47c48 | 245 | %description static -l pl.UTF-8 |
87b9c30a | 246 | Biblioteki statyczne Ruby. |
247 | ||
754b419a | 248 | %package doc |
9fd96af7 | 249 | Summary: Ruby HTML documentation |
3c3949cf | 250 | Summary(pl.UTF-8): Dokumentacja HTML do Ruby |
9fd96af7 | 251 | Group: Documentation |
00595cdb ER |
252 | %if "%{_rpmversion}" >= "5" |
253 | BuildArch: noarch | |
254 | %endif | |
9fd96af7 | 255 | |
256 | %description doc | |
257 | Ruby HTML documentation: FAQ, guide, core and standard library. | |
258 | ||
a0a47c48 | 259 | %description doc -l pl.UTF-8 |
d99a4382 | 260 | Dokumentacja HTML do Ruby: FAQ, przewodnik, dokumentacja dla core i |
261 | stdlib. | |
69b51dc9 | 262 | |
9fd96af7 | 263 | %package doc-ri |
264 | Summary: Ruby ri documentation | |
3c3949cf | 265 | Summary(pl.UTF-8): Dokumentacja Ruby w formacie ri |
9fd96af7 | 266 | Group: Documentation |
69b51dc9 | 267 | Requires: %{name}-modules = %{epoch}:%{version}-%{release} |
00595cdb ER |
268 | %if "%{_rpmversion}" >= "5" |
269 | BuildArch: noarch | |
270 | %endif | |
9fd96af7 | 271 | |
272 | %description doc-ri | |
273 | Ruby ri documentation. | |
274 | ||
a0a47c48 | 275 | %description doc-ri -l pl.UTF-8 |
9fd96af7 | 276 | Dokumentacja Ruby w formacie ri. |
277 | ||
278 | %package examples | |
279 | Summary: Ruby examples | |
3c3949cf | 280 | Summary(pl.UTF-8): Przykłady dla języka Ruby |
9fd96af7 | 281 | Group: Development/Languages |
00595cdb ER |
282 | %if "%{_rpmversion}" >= "5" |
283 | BuildArch: noarch | |
284 | %endif | |
9fd96af7 | 285 | |
286 | %description examples | |
287 | Ruby examples. | |
288 | ||
a0a47c48 JR |
289 | %description examples -l pl.UTF-8 |
290 | Przykłady programów w języku Ruby. | |
9fd96af7 | 291 | |
d8228776 | 292 | # IMPORTANT: keep irb, rdoc, rubygems, rake, json as last packages as we reset epoch/version/release |
116a558f ER |
293 | # and %{version},%{release} macros may not be used directly as they take last |
294 | # subpackage value not main package one what you intend to use | |
63b8d212 | 295 | |
d8228776 ER |
296 | %package irb |
297 | Summary: The Interactive Ruby | |
298 | Version: %{irb_ver} | |
299 | Group: Development/Languages | |
300 | Release: %{basever}.%{patchlevel}.%{rel} | |
301 | Epoch: 0 | |
302 | Requires: %{name}-modules = 1:%{basever}.%{patchlevel}-%{rel} | |
303 | Provides: irb = %{version}-%{release} | |
304 | Provides: ruby(irb) = %{version}-%{release} | |
305 | %if "%{_rpmversion}" >= "5" | |
306 | BuildArch: noarch | |
307 | %endif | |
308 | ||
309 | %description irb | |
310 | The irb is acronym for Interactive Ruby. It evaluates ruby expression | |
311 | from the terminal. | |
312 | ||
2db0575e ER |
313 | %package rdoc |
314 | Summary: A tool to generate HTML and command-line documentation for Ruby projects | |
3349e6ba | 315 | Summary(pl.UTF-8): Narzędzie do generowania dokumentacji HTML i linii poleceń dla projektów w Rubym |
2db0575e | 316 | Version: %{rdoc_ver} |
45f22c60 | 317 | Release: %{basever}.%{patchlevel}.%{rel} |
2db0575e ER |
318 | Epoch: 0 |
319 | License: GPL v2 and Ruby and MIT | |
320 | Group: Development/Libraries | |
116a558f | 321 | Requires: %{name}-modules = 1:%{basever}.%{patchlevel}-%{rel} |
ee1edb11 | 322 | Obsoletes: rdoc <= 0.9.0 |
00595cdb ER |
323 | %if "%{_rpmversion}" >= "5" |
324 | BuildArch: noarch | |
325 | %endif | |
2db0575e ER |
326 | |
327 | %description rdoc | |
328 | RDoc produces HTML and command-line documentation for Ruby projects. | |
329 | RDoc includes the 'rdoc' and 'ri' tools for generating and displaying | |
330 | online documentation. | |
331 | ||
3349e6ba JB |
332 | %description rdoc -l pl.UTF-8 |
333 | RDoc tworzy dokumentację HTML i linii poleceń dla projektów w języku | |
334 | Ruby. RDoc zawiera narzędzia 'rdoc' i 'ri' do generowania i | |
335 | wyświetlania dokumentacji online. | |
336 | ||
44802bd7 | 337 | %package rubygems |
3349e6ba JB |
338 | Summary: RubyGems - the Ruby standard for packaging Ruby libraries |
339 | Summary(pl.UTF-8): RubyGems - standard Ruby'ego pakietowania bibliotek | |
941981c7 | 340 | Version: %{rubygems_ver} |
de9418ad | 341 | Release: %{basever}.%{patchlevel}.%{rel} |
bd4c2526 | 342 | Epoch: 0 |
941981c7 ER |
343 | License: Ruby or MIT |
344 | Group: Development/Libraries | |
116a558f | 345 | Requires: %{name}-modules = 1:%{basever}.%{patchlevel}-%{rel} |
941981c7 | 346 | Requires: %{name}-rdoc >= %{rdoc_ver} |
92f362b7 | 347 | Suggests: %{name}-devel |
44802bd7 ER |
348 | Provides: rubygems = %{rubygems_ver} |
349 | %if "%{_rpmversion}" >= "5" | |
350 | BuildArch: noarch | |
351 | %endif | |
352 | ||
353 | %description rubygems | |
354 | RubyGems is the Ruby standard for publishing and managing third party | |
355 | libraries. | |
356 | ||
3349e6ba JB |
357 | %description rubygems -l pl.UTF-8 |
358 | RubyGems to standardowe narzędzie języka Ruby do publikowania i | |
359 | zarządzania zewnętrznymi bibliotekami. | |
360 | ||
63b8d212 ER |
361 | %package rake |
362 | Summary: Rake is a Make-like program implemented in Ruby | |
363 | Summary(pl.UTF-8): Program typu Make dla języka Ruby | |
364 | Version: %{rake_ver} | |
365 | Release: %{basever}.%{patchlevel}.%{rel} | |
366 | Epoch: 0 | |
367 | License: MIT | |
368 | Group: Development/Languages | |
369 | Provides: rake = %{rake_ver} | |
2531db89 | 370 | Conflicts: ruby-modules < 1:1.9.3.429-2 |
63b8d212 ER |
371 | %if "%{_rpmversion}" >= "5" |
372 | BuildArch: noarch | |
373 | %endif | |
374 | ||
375 | %description rake | |
376 | Rake is a simple Ruby build program with capabilities similar to make. | |
377 | ||
378 | It has the following features: | |
379 | - Rakefiles (rake's version of Makefiles) are completely defined in | |
380 | standard Ruby syntax. No XML files to edit. No quirky Makefile syntax | |
381 | to worry about (is that a tab or a space?) | |
382 | - Users can specify tasks with prerequisites. | |
383 | - Rake supports rule patterns to synthesize implicit tasks. | |
384 | - Rake is lightweight. It can be distributed with other projects as a | |
385 | single file. Projects that depend upon rake do not require that rake | |
386 | be installed on target systems. | |
387 | ||
388 | %description rake -l pl.UTF-8 | |
389 | Rake to prosty program do budowania w języku Ruby o możliwościach | |
390 | podobnych do make. | |
391 | ||
392 | Ma następujące cechy: | |
393 | - Pliki Rakefile (rake'owa odmiana plików Makefile) są definiowane | |
394 | całkowicie w standardowej składni języka Ruby. Nie trzeba modyfikować | |
395 | plików XML. Nie trzeba martwić się kaprysami składni Makefile (czy to | |
396 | tabulacja czy spacja?). | |
397 | - Użytkownicy mogą określać zadania z ich zależnościami. | |
398 | - Rake obsługuje wzorce reguł do tworzenia z nich wynikowych zadań. | |
399 | - Rake jest lekki. Może być rozpowszechniany z innymi projektami jako | |
400 | pojedynczy plik. Projekty używające rake'a nie wymagają go | |
401 | zainstalowanego na systemach docelowych. | |
402 | ||
7e87bcc1 ER |
403 | %package json |
404 | Summary: JSON library for Ruby | |
405 | Summary(pl.UTF-8): Biblioteka JSON dla języka Ruby | |
406 | Version: %{json_ver} | |
407 | Release: %{basever}.%{patchlevel}.%{rel} | |
408 | Epoch: 0 | |
409 | License: MIT | |
410 | Group: Development/Languages | |
411 | Obsoletes: ruby-json-rubyforge | |
2531db89 | 412 | Conflicts: ruby-modules < 1:1.9.3.429-3 |
7e87bcc1 ER |
413 | |
414 | %description json | |
415 | This is a JSON implementation as a Ruby extension in C. | |
416 | ||
417 | %description json -l pl.UTF-8 | |
418 | Biblioteka JSON dla języka Ruby. | |
419 | ||
4ab119cd | 420 | %prep |
360c41c0 | 421 | %if %{with bootstrap} |
9c41e51a | 422 | %setup -q -n %{oname}-%{basever}-p%{patchlevel} -a1 -a2 -a3 -a100 |
360c41c0 | 423 | %else |
9c41e51a | 424 | %setup -q -n %{oname}-%{basever}-p%{patchlevel} -a1 -a2 -a3 |
360c41c0 | 425 | %endif |
933aeb0e | 426 | %patch0 -p1 |
a310037a | 427 | %patch1 -p1 |
360c41c0 | 428 | %patch2 -p1 |
45f22c60 ER |
429 | #%patch3 -p1 |
430 | #%patch4 -p1 | |
431 | #%patch5 -p1 | |
87688b10 ER |
432 | %patch6 -p1 |
433 | %patch7 -p1 | |
45f22c60 ER |
434 | %patch8 -p1 |
435 | %patch9 -p1 | |
436 | %patch10 -p1 | |
437 | %patch11 -p1 | |
438 | %patch12 -p1 | |
360c41c0 JR |
439 | |
440 | # must be regenerated with new bison | |
441 | %{__rm} parse.{c,h} | |
4ab119cd | 442 | |
b2f04116 JR |
443 | find '(' -name '*~' -o -name '*.orig' ')' -print0 | xargs -0 -r -l512 rm -f |
444 | ||
445 | find -type f '(' -name '*.rb' -o -name '*.cgi' -o -name '*.test' \ | |
446 | -o -name 'ruby.1' -o -name '*.html' -o -name '*.tcl' ')' \ | |
bb5582fa | 447 | | xargs %{__sed} -i 's,/usr/local/bin/,%{_bindir}/,' |
e7754311 | 448 | |
4ab119cd | 449 | %build |
de9418ad ER |
450 | rubygems_ver=$(awk '/VERSION =/ && $1 == "VERSION" {print $3}' lib/rubygems.rb | xargs) |
451 | if [ $rubygems_ver != %{rubygems_ver} ]; then | |
452 | echo "Set %%define rubygems_ver to $rubygems_ver and re-run." | |
453 | exit 1 | |
454 | fi | |
45f22c60 ER |
455 | rdoc_ver=$(awk '/VERSION =/ && $1 == "VERSION" {print $3}' lib/rdoc.rb | xargs) |
456 | if [ $rdoc_ver != %{rdoc_ver} ]; then | |
457 | echo "Set %%define rdoc_ver to $rdoc_ver and re-run." | |
458 | exit 1 | |
459 | fi | |
de9418ad | 460 | |
8ea447c1 | 461 | cp -f /usr/share/automake/config.sub . |
a5f9b7ff | 462 | |
92ff5331 | 463 | # build ruby-1.8.7 first |
464 | %if %{with bootstrap} | |
9c41e51a | 465 | cd %{oname}-1.8.7-p330 |
92ff5331 | 466 | %configure |
467 | %{__make} | |
468 | cd .. | |
469 | %endif | |
470 | ||
8ea447c1 | 471 | %{__autoconf} |
ecde9c47 | 472 | %configure \ |
9c41e51a ER |
473 | %{?with_bootstrap:--with-baseruby=%{oname}-1.8.7-p330/miniruby} \ |
474 | --program-suffix=%{ruby_suffix} \ | |
45f22c60 ER |
475 | --with-rubygemsdir=%{rubygems_dir} \ |
476 | --with-rubylibprefix=%{ruby_libdir} \ | |
477 | --with-rubyarchprefix=%{ruby_archdir} \ | |
478 | --with-sitedir=%{ruby_sitelibdir} \ | |
44d1acb8 | 479 | --with-sitearchdir=%{ruby_sitearchdir} \ |
45f22c60 | 480 | --with-vendordir=%{ruby_vendorlibdir} \ |
44d1acb8 | 481 | --with-vendorarchdir=%{ruby_vendorarchdir} \ |
45f22c60 ER |
482 | --with-rubyhdrdir=%{_includedir}/%{oname}-%{ruby_version} \ |
483 | --with-rubyarchhdrdir=%{_includedir}/%{oname}-%{ruby_version} \ | |
484 | --with-sitearchhdrdir='$(sitehdrdir)/$(arch)' \ | |
485 | --with-vendorarchhdrdir='$(vendorhdrdir)/$(arch)' \ | |
31058abe | 486 | --with-search-path="%{legacy_loadpaths}" \ |
3a4dd1f6 | 487 | --enable-shared \ |
374c5b6e | 488 | --enable-pthread \ |
45f22c60 | 489 | --enable-multiarch \ |
4e930057 | 490 | --disable-rubygems \ |
96c2e1a4 | 491 | --disable-install-doc \ |
45f22c60 | 492 | --with-ruby-version='' |
4ab119cd | 493 | |
dbf8f91d | 494 | %{__make} -j1 main \ |
2690877c | 495 | COPY="cp -p" Q= \ |
9c41e51a | 496 | %{?with_bootstrap:BASERUBY="%{oname}-1.8.7-p330/miniruby -I./ruby-1.8.7-p330/lib"} |
aa58dbf5 | 497 | |
d0f5536d | 498 | %if %{with doc} |
98757242 | 499 | %{__make} -j1 rdoc |
d0f5536d | 500 | %endif |
53830491 | 501 | |
4ab119cd | 502 | %install |
503 | rm -rf $RPM_BUILD_ROOT | |
45f22c60 ER |
504 | install -d $RPM_BUILD_ROOT%{_examplesdir}/%{oname}-%{basever}.%{patchlevel} \ |
505 | ||
506 | #install -d $RPM_BUILD_ROOT{%{ruby_rdocdir},%{_examplesdir}/%{oname}-%{version}} \ | |
507 | # $RPM_BUILD_ROOT{%{ruby_vendorarchdir},%{ruby_ridir}} \ | |
508 | # $RPM_BUILD_ROOT%{ruby_vendorlibdir}/net \ | |
509 | # $RPM_BUILD_ROOT%{ruby_vendordir}/data \ | |
510 | ||
511 | # $RPM_BUILD_ROOT{%{legacy_archdir}/racc,%{legacy_sitelibdir},%{legacy_sitearchdir},%{legacy_vendorarchdir},%{legacy_libdir}/tasks} \ | |
1968db6d | 512 | |
96c2e1a4 | 513 | %{__make} install %{?with_doc:install-doc} \ |
ecde9c47 | 514 | DESTDIR=$RPM_BUILD_ROOT |
d041de24 | 515 | |
45f22c60 | 516 | cp -Rf sample/* $RPM_BUILD_ROOT%{_examplesdir}/%{oname}-%{basever}.%{patchlevel} |
9c41e51a ER |
517 | cp -p %{SOURCE4} $RPM_BUILD_ROOT%{_mandir}/man1/rdoc%{ruby_suffix}.1 |
518 | cp -p %{SOURCE5} $RPM_BUILD_ROOT%{_mandir}/man1/testrb%{ruby_suffix}.1 | |
18e966a7 | 519 | |
5c3d5a0e | 520 | %{__rm} -rf $RPM_BUILD_ROOT%{_docdir}/%{name}/html |
698147c7 | 521 | |
9c41e51a | 522 | ln -sf %{gem_dir}/gems/rake-%{rake_ver}/bin/rake $RPM_BUILD_ROOT%{_bindir}/rake%{ruby_suffix} |
63b8d212 | 523 | |
15467dc7 | 524 | %if %{without batteries} |
b2f04116 | 525 | # packaged separately |
05f75f09 | 526 | %{__rm} -r $RPM_BUILD_ROOT%{ruby_libdir}/{rubygems,rake,json,minitest} |
0b1956f4 | 527 | %{__rm} -r $RPM_BUILD_ROOT%{ruby_archdir}/json |
7179288b | 528 | %{__rm} -r $RPM_BUILD_ROOT%{gem_dir}/gems/rake-* |
0b1956f4 | 529 | %{__rm} $RPM_BUILD_ROOT%{ruby_libdir}/{rake,rubygems,json}.rb |
92ff5331 | 530 | %{__rm} $RPM_BUILD_ROOT%{_bindir}/{gem,rake} |
531 | %{__rm} $RPM_BUILD_ROOT%{_mandir}/man1/rake* | |
45f22c60 | 532 | %{__rm} $RPM_BUILD_ROOT%{gem_dir}/specifications/default/{json,minitest,rake}-*.gemspec |
7179288b | 533 | %{?with_doc:%{__rm} -r $RPM_BUILD_ROOT%{_datadir}/ri/%{ruby_version}/system/JSON} |
15467dc7 | 534 | %endif |
1968db6d | 535 | |
44802bd7 | 536 | %if %{with doc} |
d78ec589 | 537 | # too much .ri |
45f22c60 ER |
538 | #%{__rm} $RPM_BUILD_ROOT%{ruby_ridir}/cache.ri |
539 | #%{__rm} $RPM_BUILD_ROOT%{ruby_ridir}/created.rid | |
15467dc7 | 540 | %endif |
1968db6d | 541 | |
4ab119cd | 542 | %clean |
543 | rm -rf $RPM_BUILD_ROOT | |
544 | ||
d041de24 JR |
545 | %post -p /sbin/ldconfig |
546 | %postun -p /sbin/ldconfig | |
4ab119cd | 547 | |
548 | %files | |
549 | %defattr(644,root,root,755) | |
45f22c60 ER |
550 | %doc NEWS LEGAL README README.EXT ChangeLog |
551 | #ToDo | |
9c41e51a | 552 | %attr(755,root,root) %{_bindir}/ruby%{ruby_suffix} |
529ff870 | 553 | %attr(755,root,root) %{_libdir}/libruby.so.*.*.* |
45f22c60 | 554 | %attr(755,root,root) %ghost %{_libdir}/libruby.so.%{ruby_version} |
9c41e51a | 555 | %{_mandir}/man1/ruby%{ruby_suffix}.1* |
05f75f09 | 556 | |
9c41e51a ER |
557 | %dir %{_libdir}/%{oname} |
558 | %dir %{_libdir}/%{oname}/%{vendordir} | |
559 | %dir %{_datadir}/%{oname} | |
0b1956f4 | 560 | |
be8e7b24 | 561 | %dir %{ruby_libdir} |
5c3d5a0e | 562 | %dir %{ruby_archdir} |
4ffa9197 | 563 | %dir %{ruby_vendordir} |
45f22c60 | 564 | #%dir %{ruby_vendordir}/data |
be8e7b24 | 565 | %dir %{ruby_vendorlibdir} |
be8e7b24 | 566 | %dir %{ruby_vendorarchdir} |
31058abe | 567 | |
45f22c60 ER |
568 | #%dir %{_datadir}/ri |
569 | #%dir %{_datadir}/ri/%{ruby_version} | |
570 | #%dir %{ruby_ridir} | |
571 | # | |
572 | #%dir %{ruby_rdocdir} | |
9fd96af7 | 573 | |
f1a7abab | 574 | # common dirs for ruby vendor modules |
45f22c60 | 575 | #%dir %{ruby_vendorlibdir}/net |
f1a7abab | 576 | |
de8152d8 | 577 | # legacy dirs. when everything rebuilt in Th not using these dirs. drop them |
45f22c60 | 578 | %if 0 |
de8152d8 ER |
579 | %dir %{legacy_archdir} |
580 | %dir %{legacy_sitedir} | |
581 | %dir %{legacy_sitelibdir} | |
582 | %dir %{legacy_sitearchdir} | |
583 | %dir %{legacy_vendorarchdir} | |
293a48c2 | 584 | %dir %{legacy_libdir}/tasks |
7c3b0919 | 585 | %dir %{legacy_archdir}/racc |
45f22c60 | 586 | %endif |
de8152d8 | 587 | |
9fd96af7 | 588 | %files devel |
589 | %defattr(644,root,root,755) | |
529ff870 | 590 | %attr(755,root,root) %{_libdir}/libruby.so |
9c41e51a | 591 | %{_includedir}/%{oname}-%{ruby_version} |
31058abe | 592 | %{_pkgconfigdir}/ruby-%{ruby_version}.pc |
b5465d0c | 593 | %{ruby_libdir}/mkmf.rb |
9fd96af7 | 594 | |
595 | %files static | |
596 | %defattr(644,root,root,755) | |
529ff870 | 597 | %{_libdir}/libruby-static.a |
9fd96af7 | 598 | |
15ecb21e | 599 | %if %{with tk} |
9fd96af7 | 600 | %files tk |
601 | %defattr(644,root,root,755) | |
0b1956f4 ER |
602 | %{ruby_libdir}/tcltk.rb |
603 | %{ruby_libdir}/tk*.rb | |
604 | %{ruby_libdir}/tk | |
605 | %{ruby_libdir}/tkextlib | |
606 | %attr(755,root,root) %{ruby_archdir}/t*.so | |
15ecb21e | 607 | %endif |
9fd96af7 | 608 | |
d8228776 ER |
609 | %files irb |
610 | %defattr(644,root,root,755) | |
9c41e51a | 611 | %attr(755,root,root) %{_bindir}/irb%{ruby_suffix} |
d8228776 ER |
612 | %{ruby_libdir}/irb.rb |
613 | %{ruby_libdir}/irb | |
9c41e51a | 614 | %{_mandir}/man1/irb%{ruby_suffix}.1* |
d8228776 | 615 | |
2db0575e | 616 | %files rdoc |
9fd96af7 | 617 | %defattr(644,root,root,755) |
9c41e51a ER |
618 | %attr(755,root,root) %{_bindir}/rdoc%{ruby_suffix} |
619 | %attr(755,root,root) %{_bindir}/ri%{ruby_suffix} | |
620 | %{_mandir}/man1/rdoc%{ruby_suffix}.1* | |
2db0575e ER |
621 | %{ruby_libdir}/rdoc |
622 | %dir %{gem_dir}/gems/rdoc-%{rdoc_ver} | |
623 | %dir %{gem_dir}/gems/rdoc-%{rdoc_ver}/bin | |
624 | %attr(755,root,root) %{gem_dir}/gems/rdoc-%{rdoc_ver}/bin/rdoc | |
45f22c60 | 625 | %{gem_dir}/specifications/default/rdoc-%{rdoc_ver}.gemspec |
2db0575e ER |
626 | %attr(755,root,root) %{gem_dir}/gems/rdoc-%{rdoc_ver}/bin/ri |
627 | ||
44802bd7 ER |
628 | %if %{with batteries} |
629 | %files rubygems | |
941981c7 | 630 | %defattr(644,root,root,755) |
9c41e51a | 631 | %attr(755,root,root) %{_bindir}/gem%{ruby_suffix} |
45f22c60 ER |
632 | %{rubygems_dir}/rubygems |
633 | %{rubygems_dir}/rubygems.rb | |
634 | %{rubygems_dir}/ubygems.rb | |
635 | %{rubygems_dir}/rbconfig | |
63b8d212 ER |
636 | |
637 | %files rake | |
638 | %defattr(644,root,root,755) | |
9c41e51a ER |
639 | %attr(755,root,root) %{_bindir}/rake%{ruby_suffix} |
640 | %{_mandir}/man1/rake%{ruby_suffix}.1* | |
63b8d212 ER |
641 | %{ruby_libdir}/rake |
642 | %dir %{gem_dir}/gems/rake-%{rake_ver} | |
643 | %dir %{gem_dir}/gems/rake-%{rake_ver}/bin | |
644 | %attr(755,root,root) %{gem_dir}/gems/rake-%{rake_ver}/bin/rake | |
45f22c60 | 645 | %{gem_dir}/specifications/default/rake-%{rake_ver}.gemspec |
7e87bcc1 ER |
646 | |
647 | %files json | |
648 | %defattr(644,root,root,755) | |
649 | %{ruby_libdir}/json | |
650 | %dir %{ruby_archdir}/json | |
651 | %dir %{ruby_archdir}/json/ext | |
652 | %attr(755,root,root) %{ruby_archdir}/json/ext/*.so | |
45f22c60 | 653 | %{gem_dir}/specifications/default/json-%{json_ver}.gemspec |
44802bd7 ER |
654 | %endif |
655 | ||
9fd96af7 | 656 | %files modules |
657 | %defattr(644,root,root,755) | |
9c41e51a ER |
658 | %attr(755,root,root) %{_bindir}/erb%{ruby_suffix} |
659 | %attr(755,root,root) %{_bindir}/testrb%{ruby_suffix} | |
0b1956f4 ER |
660 | %{ruby_libdir}/bigdecimal |
661 | %{ruby_libdir}/cgi | |
662 | %{ruby_libdir}/date | |
663 | %{ruby_libdir}/digest | |
664 | %{ruby_libdir}/dl | |
665 | %{ruby_libdir}/drb | |
666 | %{ruby_libdir}/fiddle | |
667 | %{ruby_libdir}/io | |
0b1956f4 | 668 | %{ruby_libdir}/matrix |
0b1956f4 ER |
669 | %{ruby_libdir}/net |
670 | %{ruby_libdir}/openssl | |
671 | %{ruby_libdir}/optparse | |
0b1956f4 ER |
672 | %{ruby_libdir}/psych |
673 | %{ruby_libdir}/racc | |
674 | %{ruby_libdir}/rbconfig | |
0b1956f4 ER |
675 | %{ruby_libdir}/rexml |
676 | %{ruby_libdir}/rinda | |
677 | %{ruby_libdir}/ripper | |
678 | %{ruby_libdir}/rss | |
679 | %{ruby_libdir}/shell | |
45f22c60 ER |
680 | #%{ruby_libdir}/syck |
681 | %{ruby_libdir}/syslog | |
0b1956f4 ER |
682 | %{ruby_libdir}/test |
683 | %{ruby_libdir}/uri | |
684 | %{ruby_libdir}/webrick | |
685 | %{ruby_libdir}/xmlrpc | |
686 | %{ruby_libdir}/yaml | |
687 | %{ruby_libdir}/[A-Za-s]*.rb | |
688 | %{ruby_libdir}/tempfile.rb | |
689 | %{ruby_libdir}/thread.rb | |
690 | %{ruby_libdir}/thwait.rb | |
691 | %{ruby_libdir}/time.rb | |
692 | %{ruby_libdir}/timeout.rb | |
693 | %{ruby_libdir}/tmpdir.rb | |
694 | %{ruby_libdir}/tracer.rb | |
695 | %{ruby_libdir}/tsort.rb | |
696 | %{ruby_libdir}/[u-z]*.rb | |
7179288b | 697 | %if %{with batteries} |
45f22c60 ER |
698 | #%exclude %{ruby_libdir}/rubygems.rb |
699 | #%exclude %{ruby_libdir}/ubygems.rb | |
7179288b | 700 | %endif |
d8228776 | 701 | %exclude %{ruby_libdir}/irb.rb |
b5465d0c | 702 | %exclude %{ruby_libdir}/mkmf.rb |
0b1956f4 ER |
703 | %attr(755,root,root) %{ruby_archdir}/[a-s]*.so |
704 | %attr(755,root,root) %{ruby_archdir}/[u-z]*.so | |
705 | %dir %{ruby_archdir}/digest | |
706 | %attr(755,root,root) %{ruby_archdir}/digest/*.so | |
707 | %dir %{ruby_archdir}/dl | |
708 | %attr(755,root,root) %{ruby_archdir}/dl/callback.so | |
709 | %dir %{ruby_archdir}/enc | |
710 | %attr(755,root,root) %{ruby_archdir}/enc/*.so | |
711 | %dir %{ruby_archdir}/enc/trans | |
712 | %attr(755,root,root) %{ruby_archdir}/enc/trans/*.so | |
713 | %dir %{ruby_archdir}/io | |
714 | %attr(755,root,root) %{ruby_archdir}/io/*.so | |
0b1956f4 ER |
715 | %dir %{ruby_archdir}/mathn |
716 | %attr(755,root,root) %{ruby_archdir}/mathn/*.so | |
717 | %dir %{ruby_archdir}/racc | |
718 | %attr(755,root,root) %{ruby_archdir}/racc/*.so | |
719 | %{ruby_archdir}/rbconfig.rb | |
31058abe | 720 | |
45f22c60 ER |
721 | %{gem_dir}/specifications/default/bigdecimal-%{bigdecimal_ver}.gemspec |
722 | %{gem_dir}/specifications/default/io-console-%{io_console_ver}.gemspec | |
ee1edb11 | 723 | |
05f75f09 | 724 | %if %{with batteries} |
05f75f09 ER |
725 | # minitest |
726 | %{ruby_libdir}/minitest | |
45f22c60 | 727 | %{gem_dir}/specifications/default/minitest-%{minitest_ver}.gemspec |
05f75f09 ER |
728 | %endif |
729 | ||
45f22c60 ER |
730 | %{gem_dir}/specifications/default/psych-%{psych_ver}.gemspec |
731 | ||
732 | # test-unit | |
733 | %{gem_dir}/specifications/default/test-unit-%{test_unit_ver}.gemspec | |
734 | %dir %{gem_dir}/gems/test-unit-%{test_unit_ver} | |
735 | %dir %{gem_dir}/gems/test-unit-%{test_unit_ver}/bin | |
736 | %attr(755,root,root) %{gem_dir}/gems/test-unit-%{test_unit_ver}/bin/testrb | |
737 | ||
31058abe | 738 | # parents of gem_dir |
45f22c60 | 739 | #%dir %{_datadir}/%{oname}/gems |
9c41e51a | 740 | #%dir %{_datadir}/%{oname}/gems/%{ruby_version} |
45f22c60 ER |
741 | #%dir %{_datadir}/%{oname}/gems/%{ruby_version}/gems |
742 | ||
743 | %dir %{_datadir}/%{oname}/%{ruby_version}/gems/gems | |
31058abe | 744 | |
d78ec589 | 745 | %dir %{gem_dir} |
d78ec589 | 746 | %dir %{gem_dir}/specifications |
45f22c60 | 747 | %dir %{gem_dir}/specifications/default |
9c41e51a ER |
748 | %{_mandir}/man1/erb%{ruby_suffix}.1* |
749 | %{_mandir}/man1/ri%{ruby_suffix}.1* | |
750 | %{_mandir}/man1/testrb%{ruby_suffix}.1* | |
15467dc7 | 751 | |
9fd96af7 | 752 | %files doc |
9434194f | 753 | %defattr(644,root,root,755) |
b2f04116 | 754 | %doc ruby-doc-bundle/* |
af4f9d38 JR |
755 | %{?with_doc:%doc ruby_%{doc_version}_stdlib} |
756 | %{?with_doc:%doc ruby_%{doc_version}_core} | |
87b9c30a | 757 | |
d0f5536d | 758 | %if %{with doc} |
9fd96af7 | 759 | %files doc-ri |
e40bfe06 | 760 | %defattr(644,root,root,755) |
2db0575e | 761 | %{ruby_ridir}/* |
d0f5536d | 762 | %endif |
265d0efe | 763 | |
9fd96af7 | 764 | %files examples |
616a12d8 | 765 | %defattr(644,root,root,755) |
45f22c60 | 766 | %{_examplesdir}/%{oname}-* |