]>
Commit | Line | Data |
---|---|---|
3105856a JB |
1 | # |
2 | # Conditional build: | |
b552f088 JB |
3 | %bcond_without emacs # without emacs subpackage |
4 | %bcond_without x # without X11 support | |
5 | %bcond_without tk # without Tcl/Tk support | |
ed19172f | 6 | # |
f4710e3c | 7 | # --without x11 implies --without tk |
1b2eae14 | 8 | %{!?with_x:%undefine with_tk} |
4797676b | 9 | |
6e71517f | 10 | %define p4ver 3.06 |
9de25172 | 11 | %define sver 3.12 |
db184753 | 12 | |
65fbc6c7 | 13 | Summary: The Objective Caml compiler and programming environment |
6e95eae7 | 14 | Summary(pl.UTF-8): Kompilator OCamla (Objective Caml) oraz środowisko programistyczne |
65fbc6c7 | 15 | Name: ocaml |
356fa1c2 | 16 | Version: 3.12.1 |
0d424b76 | 17 | Release: 21 |
4694cc06 | 18 | Epoch: 1 |
a13fc47d | 19 | License: distributable |
65fbc6c7 | 20 | Group: Development/Languages |
7845a5c9 | 21 | Source0: http://caml.inria.fr/distrib/%{name}-%{sver}/%{name}-%{version}.tar.bz2 |
356fa1c2 | 22 | # Source0-md5: 227a3daaedb150bf5037a3db01f5bf42 |
307e1de8 | 23 | Source1: http://caml.inria.fr/distrib/%{name}-%{sver}/%{name}-%{sver}-refman.html.tar.gz |
9de25172 | 24 | # Source1-md5: 93cd91f525441eb7e94cc49b9b64bab0 |
307e1de8 | 25 | Source2: http://caml.inria.fr/distrib/%{name}-%{sver}/%{name}-%{sver}-refman.ps.gz |
9de25172 JB |
26 | # Source2-md5: a9c17db6ffd400c5ea00c6d51cbf56bf |
27 | Source3: http://caml.inria.fr/distrib/%{name}-%{sver}/%{name}-%{sver}-refman.info.tar.gz | |
28 | # Source3-md5: 8cf24c4f69c6f9c9f9cc1edb9b18f6cb | |
0328da41 | 29 | # following 4 URLs are dead, some version now available at http://pauillac.inria.fr/camlp4/ |
9de25172 JB |
30 | Source4: ftp://ftp.inria.fr/INRIA/Projects/cristal/camlp4/camlp4-%{p4ver}-manual.html.tar.gz |
31 | # Source4-md5: 21370bae4e7f6435b38aeb21db7ce8bb | |
32 | Source5: ftp://ftp.inria.fr/INRIA/Projects/cristal/camlp4/camlp4-%{p4ver}-manual.dvi.gz | |
33 | # Source5-md5: 035915d1a530aa7ec9b194d9a7d258eb | |
34 | Source6: ftp://ftp.inria.fr/INRIA/Projects/cristal/camlp4/camlp4-%{p4ver}-tutorial.html.tar.gz | |
35 | # Source6-md5: 96d8eb4ca5abd58c9a280ba59f73b192 | |
36 | Source7: ftp://ftp.inria.fr/INRIA/Projects/cristal/camlp4/camlp4-%{p4ver}-tutorial.dvi.gz | |
37 | # Source7-md5: fcd87c235109364242a0c9ccf176dff8 | |
38 | Source8: http://www.ocaml.info/ocaml_sources/pure-fun-1.0.6.tar.bz2 | |
39 | # Source8-md5: 94eac3fa1ac51b8ada344b04839cb43c | |
40 | Source9: http://www.ocaml.info/ocaml_sources/ds-contrib.tar.gz | |
41 | # Source9-md5: 77fa1da7375dea1393cc0b6cd802d7e1 | |
42946d4f | 42 | Patch0: %{name}-db3.patch |
9de25172 JB |
43 | Patch1: %{name}-CFLAGS.patch |
44 | Patch2: %{name}-as_needed.patch | |
45 | Patch3: %{name}-gas.patch | |
0d424b76 | 46 | Patch4: %{name}-tcl86.patch |
8b0de54e | 47 | URL: http://caml.inria.fr/ |
3a1adca1 | 48 | BuildRequires: db-devel >= 4.1 |
6e71517f | 49 | %{?with_tk:BuildRequires: tk-devel} |
3232e3f5 | 50 | %{?with_x:BuildRequires: xorg-lib-libX11-devel} |
f4710e3c | 51 | %if %{with emacs} |
69735a4b | 52 | BuildRequires: sed >= 4.0 |
3889f6d2 JR |
53 | BuildRequires: emacs |
54 | BuildRequires: emacs-common | |
f4710e3c | 55 | %endif |
4e386054 | 56 | Requires: %{name}-runtime = %{epoch}:%{version}-%{release} |
5a1e52bf PG |
57 | Provides: ocaml-ocamldoc |
58 | Obsoletes: ocaml-ocamldoc | |
151fbae6 | 59 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
65fbc6c7 | 60 | |
0053154a PS |
61 | %define specflags -fno-strict-aliasing |
62 | ||
65fbc6c7 AM |
63 | %description |
64 | Objective Caml is a high-level, strongly-typed, functional and | |
65 | object-oriented programming language from the ML family of languages. | |
66 | ||
67 | This package comprises two batch compilers (a fast bytecode compiler | |
5ca6b9fb MP |
68 | and an optimizing native-code compiler), an interactive toplevel |
69 | system, Lex&Yacc tools, a replay debugger, and a comprehensive | |
70 | library. | |
65fbc6c7 | 71 | |
3f556f71 JR |
72 | %description -l pl.UTF-8 |
73 | OCaml (Objective Caml) jest funkcyjnym, obiektowo zorientowanym językiem | |
74 | wysokiego poziomu z silnym typowaniem. Należy do rodziny języków ML. | |
65fbc6c7 | 75 | |
8151bf1e | 76 | Ten pakiet zawiera dwa kompilatory (szybki kompilator do bajtkodu |
3f556f71 JR |
77 | oraz optymalizujący kompilator do kodu natywnego), interaktywne środowisko |
78 | pracy, narzędzia do tworzenia analizatorów leksykalnych oraz składniowych | |
8151bf1e | 79 | (ocamllex, ocamlyacc), odpluskwiacz (ocamldebug) i biblioteki. |
65fbc6c7 | 80 | |
79502218 JB |
81 | %package runtime |
82 | Summary: Runtime system for OCaml | |
6e95eae7 | 83 | Summary(pl.UTF-8): Środowisko uruchomieniowe dla OCamla |
79502218 JB |
84 | Group: Libraries |
85 | ||
86 | %description runtime | |
87 | This package contains binaries needed to run bytecode OCaml programs: | |
88 | ocamlrun bytecode interpreter, and basic dynamic link libraries. | |
89 | ||
3f556f71 JR |
90 | %description runtime -l pl.UTF-8 |
91 | Pakiet ten zawiera binaria potrzebne do uruchamiania programów w | |
79502218 JB |
92 | OCamlu skompilowanych do bajtkodu: interpreter bajtkodu (ocamlrun) oraz |
93 | podstawowe biblioteki linkowane dynamicznie. | |
94 | ||
95 | %package lib-source | |
96 | Summary: Sources of OCaml standard library | |
6e95eae7 | 97 | Summary(pl.UTF-8): Źródła biblioteki standardowej OCamla |
79502218 JB |
98 | Group: Development/Languages |
99 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
100 | ||
101 | %description lib-source | |
102 | This sources come helpful during debugging of user programs with ocamldebug. | |
103 | ||
3f556f71 JR |
104 | %description lib-source -l pl.UTF-8 |
105 | Źródła te są przydatne przy odpluskwianiu programów użytkownika | |
106 | z użyciem ocamldebug. | |
79502218 | 107 | |
69735a4b | 108 | %package doc-html |
109 | Summary: HTML documentation for OCaml | |
6e95eae7 | 110 | Summary(pl.UTF-8): Dokumentacja dla OCamla w formacie HTML |
69735a4b | 111 | Group: Development/Tools |
112 | ||
113 | %description doc-html | |
114 | HTML documentation for OCaml. | |
115 | ||
3f556f71 | 116 | %description doc-html -l pl.UTF-8 |
69735a4b | 117 | Dokumentacja dla OCamla w formacie HTML. |
118 | ||
13b509d1 | 119 | %package doc-ps |
4797676b | 120 | Summary: PostScript documentation for OCaml |
6e95eae7 | 121 | Summary(pl.UTF-8): Dokumentacja dla OCamla w formacie PostScript |
4797676b | 122 | Group: Development/Tools |
4797676b | 123 | |
13b509d1 | 124 | %description doc-ps |
69735a4b | 125 | PostScript documentation for OCaml. |
4797676b | 126 | |
3f556f71 | 127 | %description doc-ps -l pl.UTF-8 |
69735a4b | 128 | Dokumentacja dla OCamla w formacie PostScript. |
129 | ||
130 | %package doc-info | |
131 | Summary: Info documentation for OCaml | |
6e95eae7 | 132 | Summary(pl.UTF-8): Dokumentacja info dla OCamla |
69735a4b | 133 | Group: Development/Tools |
134 | ||
135 | %description doc-info | |
136 | Info documentation for OCaml. | |
137 | ||
3f556f71 | 138 | %description doc-info -l pl.UTF-8 |
69735a4b | 139 | Dokumentacja info dla OCamla. |
4797676b | 140 | |
65fbc6c7 | 141 | %package emacs |
c4a5fbda | 142 | Summary: Emacs mode for OCaml |
6e95eae7 | 143 | Summary(pl.UTF-8): Tryb OCamla dla Emacsa |
65fbc6c7 | 144 | Group: Development/Tools |
4694cc06 | 145 | Requires: %{name} = %{epoch}:%{version}-%{release} |
65fbc6c7 AM |
146 | |
147 | %description emacs | |
981ff793 | 148 | Emacs mode files for Objective Caml language. |
65fbc6c7 | 149 | |
3f556f71 | 150 | %description emacs -l pl.UTF-8 |
8151bf1e | 151 | Pliki trybu OCamla dla Emacsa. |
56260732 | 152 | |
79502218 JB |
153 | %package labltk |
154 | Summary: Runtime for LablTk library | |
6e95eae7 | 155 | Summary(pl.UTF-8): Środowisko uruchomieniowe dla biblioteki LablTk |
981ff793 | 156 | Group: Libraries |
79502218 | 157 | Requires: %{name} = %{epoch}:%{version}-%{release} |
981ff793 | 158 | |
79502218 JB |
159 | %description labltk |
160 | LablTk gives OCaml program access to Tcl/Tk GUI widgets. This package | |
161 | contains files needed to run bytecode OCaml programs using LablTk. | |
981ff793 | 162 | |
3f556f71 JR |
163 | %description labltk -l pl.UTF-8 |
164 | Biblioteka LablTk daje programom napisanym w OCamlu dostęp do widgetów | |
165 | Tcl/Tk. Pakiet ten zawiera binaria potrzebne do uruchamiania programów | |
166 | używających LablTk. | |
981ff793 MM |
167 | |
168 | %package labltk-devel | |
8151bf1e | 169 | Summary: LablTk library for OCaml |
6e95eae7 | 170 | Summary(pl.UTF-8): Biblioteka LablTk dla OCamla |
56260732 | 171 | Group: Development/Libraries |
4694cc06 | 172 | Requires: %{name}-labltk = %{epoch}:%{version}-%{release} |
981ff793 MM |
173 | |
174 | %description labltk-devel | |
175 | LablTk gives OCaml program access to Tcl/Tk GUI widgets. This package | |
176 | contains files needed to develop OCaml programs using LablTk. | |
177 | ||
3f556f71 JR |
178 | %description labltk-devel -l pl.UTF-8 |
179 | Biblioteka LablTk daje programom napisanym w OCamlu dostęp do widgetów | |
180 | Tcl/Tk. Pakiet ten zawiera pliki niezbędne do tworzenia programów | |
181 | używających LablTk. | |
981ff793 | 182 | |
79502218 JB |
183 | %package x11graphics |
184 | Summary: X11 graphic output for OCaml | |
6e95eae7 | 185 | Summary(pl.UTF-8): Dostęp do X11 dla OCamla |
79502218 | 186 | Group: Development/Libraries |
4694cc06 | 187 | Requires: %{name} = %{epoch}:%{version}-%{release} |
56260732 | 188 | |
79502218 JB |
189 | %description x11graphics |
190 | x11graphics module gives OCaml program access to drawing in X11 | |
191 | windows. This package contains files needed to run bytecode OCaml | |
192 | programs using x11graphics. | |
56260732 | 193 | |
3f556f71 JR |
194 | %description x11graphics -l pl.UTF-8 |
195 | Moduł x11graphics daje programom napisanym w OCamlu możliwość | |
79502218 | 196 | korzystania z interfejsu graficznego X11. Pakiet ten zawiera binaria |
3f556f71 | 197 | potrzebne do uruchamiania programów używających x11graphics. |
981ff793 MM |
198 | |
199 | %package x11graphics-devel | |
200 | Summary: X11 graphic output for OCaml | |
6e95eae7 | 201 | Summary(pl.UTF-8): Dostęp do X11 dla OCamla |
981ff793 | 202 | Group: Development/Libraries |
4694cc06 | 203 | Requires: %{name}-x11graphics = %{epoch}:%{version}-%{release} |
981ff793 MM |
204 | |
205 | %description x11graphics-devel | |
206 | x11graphics module gives OCaml program access to drawing in X11 | |
207 | windows. This package contains files needed to develop OCaml programs | |
208 | using x11graphics. | |
209 | ||
3f556f71 JR |
210 | %description x11graphics-devel -l pl.UTF-8 |
211 | Moduł x11graphics daje programom napisanym w OCamlu możliwość | |
8151bf1e | 212 | korzystania z interfejsu graficznego X11. Pakiet ten zawiera pliki |
3f556f71 | 213 | niezbędne do tworzenia programów używających x11graphics. |
56260732 | 214 | |
56260732 MM |
215 | %package camlp4 |
216 | Summary: Objective Caml Preprocessor | |
6e95eae7 | 217 | Summary(pl.UTF-8): Preprocesor OCamla |
56260732 | 218 | Group: Development/Languages |
4694cc06 | 219 | Requires: %{name} = %{epoch}:%{version}-%{release} |
220 | Provides: camlp4 = %{epoch}:%{version}-%{release} | |
56260732 MM |
221 | Obsoletes: camlp4 |
222 | ||
223 | %description camlp4 | |
224 | Camlp4 is a Pre-Processor-Pretty-Printer for Objective Caml. It offers | |
225 | tools for syntax (grammars) and the ability to modify the concrete | |
226 | syntax of the language (quotations, syntax extensions). | |
227 | ||
228 | Camlp4 can parse normal Ocaml concrete syntax or any other | |
229 | user-definable syntax. As an example, an alternative syntax is | |
230 | provided, named revised, because it tries to fix some small problems | |
231 | of the normal syntax. | |
232 | ||
233 | Camlp4 can pretty print the normal Ocaml concrete syntax or the | |
234 | revised one. It is therefore always possible to have a version of your | |
8151bf1e | 235 | sources compilable by the Objective Caml compiler without |
56260732 MM |
236 | preprocessing. |
237 | ||
3f556f71 JR |
238 | %description camlp4 -l pl.UTF-8 |
239 | Camlp4 jest preprocesorem OCamla. Oferuje narzędzia do manipulowania | |
240 | składnią (gramatyki) oraz możliwość modyfikowania oryginalnej składni | |
241 | języka (cytowania, rozszerzenia). | |
56260732 | 242 | |
3f556f71 JR |
243 | Camlp4 może sparsować oryginalną składnię Ocamla lub dowolną inną |
244 | definiowalną przez użytkownika. Jako przykład podana jest alternatywna | |
245 | składnia (revised syntax), która próbuje poprawić drobne problemy | |
246 | występujące w składni oryginalnej. | |
56260732 | 247 | |
3f556f71 JR |
248 | Camlp4 umie ładnie formatować źródła zarówno w oryginalnej jak i |
249 | poprawionej składni OCamla. Potrafi także tłumaczyć programy z jednej | |
250 | składni na drugą. | |
65fbc6c7 | 251 | |
69735a4b | 252 | %package camlp4-doc-html |
253 | Summary: Objective Caml Preprocessor - HTML documentation | |
6e95eae7 | 254 | Summary(pl.UTF-8): Preprocesor OCamla - dokumentacja HTML |
69735a4b | 255 | Group: Development/Languages |
256 | ||
257 | %description camlp4-doc-html | |
258 | Objective Caml Preprocessor - HTML documentation. | |
259 | ||
3f556f71 | 260 | %description camlp4-doc-html -l pl.UTF-8 |
69735a4b | 261 | Preprocesor OCamla - dokumentacja HTML. |
262 | ||
6dfc0e1a | 263 | %package compiler-objects |
981ff793 | 264 | Summary: Compiled parts of OCaml compiler |
6e95eae7 | 265 | Summary(pl.UTF-8): Skompilowane części kompilatora OCamla |
981ff793 | 266 | Group: Development/Languages |
4694cc06 | 267 | Requires: %{name} = %{epoch}:%{version}-%{release} |
68076664 | 268 | Obsoletes: ocaml-devel |
6adc6dd7 | 269 | Provides: ocaml-devel |
981ff793 | 270 | |
6dfc0e1a | 271 | %description compiler-objects |
981ff793 MM |
272 | This package contains *.cmi and *.cmo files being parts of OCaml |
273 | compiler. They are needed to compile some programs. | |
274 | ||
3f556f71 JR |
275 | %description compiler-objects -l pl.UTF-8 |
276 | Pakiet ten zawiera pliki *.cmi oraz *.cmo będące częściami kompilatora | |
277 | OCamla. Są one wymagane do kompilacji niektórych programów. | |
981ff793 | 278 | |
13b509d1 MM |
279 | %package ocamldoc-devel |
280 | Summary: Files needed to develop programs using ocamldoc | |
6e95eae7 | 281 | Summary(pl.UTF-8): Pliki potrzebne do tworzenia programów używających ocamldoc |
13b509d1 | 282 | Group: Development/Languages |
4694cc06 | 283 | Requires: %{name} = %{epoch}:%{version}-%{release} |
13b509d1 MM |
284 | |
285 | %description ocamldoc-devel | |
286 | You need this package if you are going to write ocamldoc front end or | |
287 | something like that. | |
288 | ||
3f556f71 JR |
289 | %description ocamldoc-devel -l pl.UTF-8 |
290 | Będziesz potrzebować tego pakietu, jeśli zamierzasz pisać front end | |
291 | dla ocamldoc lub coś podobnego. | |
13b509d1 | 292 | |
53fbd845 MM |
293 | # maybe we'll want to add some more stuff here? |
294 | %package examples | |
295 | Summary: Example source code for OCaml | |
6e95eae7 | 296 | Summary(pl.UTF-8): Przykładowe kody źródłowe w OCamlu |
53fbd845 | 297 | Group: Development/Languages |
4694cc06 | 298 | Requires: %{name} = %{epoch}:%{version}-%{release} |
53fbd845 MM |
299 | |
300 | %description examples | |
63004413 | 301 | This packages contains sources for Okasaki's Purely Functional |
53fbd845 MM |
302 | Datastructures in OCaml, along with some contributions. |
303 | ||
3f556f71 JR |
304 | %description examples -l pl.UTF-8 |
305 | Pakiet ten zawiera źródła Czysto Funkcyjnych Struktur Danych | |
8151bf1e | 306 | autorstwa Okasaki'ego, napisane w OCamlu, wraz z dodatkami. |
53fbd845 | 307 | |
65fbc6c7 | 308 | %prep |
9de25172 | 309 | %setup -q -a1 -a3 -a4 -a6 |
19e77905 | 310 | mkdir examples |
9de25172 JB |
311 | tar xjf %{SOURCE8} -C examples |
312 | tar xzf %{SOURCE9} -C examples | |
56260732 | 313 | # order mess with docs somewhat |
69735a4b | 314 | mkdir -p docs/html |
56260732 | 315 | mv htmlman docs/html/ocaml |
fa4b2219 | 316 | cp %{SOURCE2} docs/ocaml.ps.gz |
db184753 | 317 | mv camlp4-%{p4ver}-manual.html docs/html/camlp4 |
9de25172 | 318 | cp %{SOURCE5} docs/camlp4.ps.gz |
db184753 | 319 | mv camlp4-%{p4ver}-tutorial.html docs/html/camlp4-tutorial |
9de25172 | 320 | cp %{SOURCE7} docs/camlp4-tutorial.ps.gz |
56260732 | 321 | %patch0 -p1 |
4c1e0f62 | 322 | %patch1 -p1 |
56260732 | 323 | %patch2 -p1 |
3a1adca1 | 324 | %patch3 -p1 |
0d424b76 | 325 | %patch4 -p1 |
69735a4b | 326 | |
327 | %build | |
ed19172f | 328 | cp -f /usr/share/automake/config.sub config/gnu |
65fbc6c7 | 329 | ./configure \ |
69735a4b | 330 | -cc "%{__cc}" \ |
65fbc6c7 AM |
331 | -bindir %{_bindir} \ |
332 | -libdir %{_libdir}/%{name} \ | |
333 | -mandir %{_mandir}/man1 \ | |
530dec71 | 334 | -host %{_host} \ |
f4710e3c | 335 | %{!?with_tk:-no-tk} \ |
2e6ceb74 | 336 | -with-pthread \ |
0053154a | 337 | -x11lib %{_libdir} |
65fbc6c7 | 338 | |
0d424b76 AM |
339 | %{__make} -j1 world bootstrap opt.opt CFLAGS="%{rpmcflags} -Wall -DUSE_INTERP_RESULT" |
340 | %{__make} -C tools objinfo CFLAGS="%{rpmcflags} -Wall -DUSE_INTERP_RESULT" -j1 | |
65fbc6c7 | 341 | |
e1542d3b JB |
342 | # broken build system |
343 | sed -e 's,LIBDIR,%{_libdir},' camlp4/man/camlp4.1.tpl > camlp4/man/camlp4.1 | |
344 | ||
65fbc6c7 | 345 | %install |
5ca6b9fb | 346 | rm -rf $RPM_BUILD_ROOT |
69735a4b | 347 | install -d $RPM_BUILD_ROOT{%{_includedir},%{_infodir},%{_examplesdir}/%{name}-{labltk-,}%{version}} |
7ff0f82f | 348 | install -d $RPM_BUILD_ROOT%{_libdir}/%{name}/site-lib |
e42e1457 | 349 | |
7ae05805 | 350 | %{__make} install \ |
13b509d1 MM |
351 | BINDIR=$RPM_BUILD_ROOT%{_bindir} \ |
352 | LIBDIR=$RPM_BUILD_ROOT%{_libdir}/%{name} \ | |
353 | MANDIR=$RPM_BUILD_ROOT%{_mandir} | |
354 | ||
355 | cat > $RPM_BUILD_ROOT%{_libdir}/%{name}/ld.conf <<EOF | |
356 | %{_libdir}/%{name}/stublibs | |
357 | %{_libdir}/%{name} | |
358 | EOF | |
4797676b | 359 | |
f4710e3c | 360 | %if %{with emacs} |
3889f6d2 JR |
361 | %{__make} -C emacs install \ |
362 | DESTDIR=$RPM_BUILD_ROOT \ | |
363 | EMACSDIR="$RPM_BUILD_ROOT%{_datadir}/emacs/site-lisp" \ | |
364 | EMACS="emacs" | |
56260732 MM |
365 | %endif |
366 | ||
981ff793 | 367 | # symlink .opt versions of compilers (if present) |
13b509d1 MM |
368 | # warning: don't do that with camlp4 (can't load extensions then) |
369 | for f in ocamlc ocamlopt ocamldoc ocamllex; do | |
067af37d MM |
370 | if test -f $RPM_BUILD_ROOT%{_bindir}/$f.opt; then |
371 | mv -f $RPM_BUILD_ROOT%{_bindir}/$f \ | |
372 | $RPM_BUILD_ROOT%{_bindir}/$f.byte | |
373 | ln -sf %{_bindir}/$f.opt $RPM_BUILD_ROOT%{_bindir}/$f | |
374 | fi | |
1511bcd5 | 375 | done |
65fbc6c7 | 376 | |
981ff793 | 377 | # move includes to the proper place |
ba35c88b | 378 | mv -f $RPM_BUILD_ROOT%{_libdir}/%{name}/caml $RPM_BUILD_ROOT%{_includedir}/caml |
981ff793 | 379 | # but leave compatibility symlink |
379cf672 | 380 | ln -s ../../include/caml $RPM_BUILD_ROOT%{_libdir}/%{name}/caml |
981ff793 | 381 | |
360c386d MM |
382 | # compiled sources of compiler, needed by some programs |
383 | for f in {asm,byte}comp parsing typing utils ; do | |
384 | install -d $RPM_BUILD_ROOT%{_libdir}/%{name}/compiler/$f | |
385 | cp $f/*.{cmi,cmo,cmx,o} $RPM_BUILD_ROOT%{_libdir}/%{name}/compiler/$f | |
386 | done | |
981ff793 MM |
387 | |
388 | # this isn't installed by default, but is useful | |
389 | install tools/objinfo $RPM_BUILD_ROOT%{_bindir}/ocamlobjinfo | |
53fbd845 | 390 | cp -r examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} |
13b509d1 | 391 | cp -r otherlibs/labltk/examples* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-labltk-%{version} |
56260732 MM |
392 | ln -sf %{_libdir}/%{name}/{scrape,add}labels $RPM_BUILD_ROOT%{_bindir} |
393 | ||
13b509d1 | 394 | # shutup checkfiles |
9de25172 JB |
395 | %{__rm} -r $RPM_BUILD_ROOT%{_mandir}/man3 |
396 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/%{name}/labltk/{labltktop,pp} | |
13b509d1 | 397 | |
69735a4b | 398 | # install info pages |
399 | cp -f infoman/*.gz $RPM_BUILD_ROOT%{_infodir} | |
400 | ||
e1542d3b JB |
401 | # broken build system |
402 | install camlp4/man/camlp4.1 $RPM_BUILD_ROOT%{_mandir}/man1 | |
403 | for f in camlp4o.1 camlp4r.1 mkcamlp4.1 camlp4o.opt.1 camlp4r.opt.1 ; do | |
404 | echo '.so camlp4.1' >$RPM_BUILD_ROOT%{_mandir}/man1/$f | |
405 | done | |
406 | ||
65fbc6c7 AM |
407 | %clean |
408 | rm -rf $RPM_BUILD_ROOT | |
409 | ||
9de25172 | 410 | %post doc-info -p /sbin/postshell |
4a452533 | 411 | -/usr/sbin/fix-info-dir -c %{_infodir} |
69735a4b | 412 | |
9de25172 | 413 | %postun doc-info -p /sbin/postshell |
4a452533 | 414 | -/usr/sbin/fix-info-dir -c %{_infodir} |
69735a4b | 415 | |
65fbc6c7 AM |
416 | %files |
417 | %defattr(644,root,root,755) | |
f1920819 | 418 | %doc LICENSE Changes README Upgrading |
9de25172 | 419 | %attr(755,root,root) %{_bindir}/addlabels |
13b509d1 | 420 | %attr(755,root,root) %{_bindir}/ocaml* |
9de25172 | 421 | %attr(755,root,root) %{_bindir}/scrapelabels |
dd90c8d9 | 422 | %{?with_tk:%exclude %{_bindir}/ocamlbrowser} |
13b509d1 | 423 | %exclude %{_bindir}/ocamlrun |
ba35c88b | 424 | %{_includedir}/caml |
530dec71 | 425 | %{_libdir}/%{name}/caml |
530dec71 | 426 | %{_libdir}/%{name}/threads |
4c1e0f62 MM |
427 | %dir %{_libdir}/%{name}/vmthreads |
428 | %dir %{_libdir}/%{name}/vmthreads/*.cm* | |
429 | %dir %{_libdir}/%{name}/vmthreads/*.a | |
13b509d1 MM |
430 | %{_libdir}/%{name}/*.a |
431 | %{_libdir}/%{name}/*.o | |
432 | %{_libdir}/%{name}/*.cm* | |
433 | %exclude %{_libdir}/%{name}/*graphics* | |
dd90c8d9 | 434 | %{_libdir}/%{name}/Makefile.config |
4251bfb1 | 435 | %{_libdir}/%{name}/ld.conf |
56260732 MM |
436 | %{_libdir}/%{name}/camlheader |
437 | %{_libdir}/%{name}/camlheader_ur | |
7ff0f82f | 438 | %{_libdir}/%{name}/ocamlbuild |
13b509d1 | 439 | %dir %{_libdir}/%{name}/ocamldoc |
13b509d1 MM |
440 | %{_libdir}/%{name}/ocamldoc/*.hva |
441 | %attr(755,root,root) %{_libdir}/%{name}/expunge | |
442 | %attr(755,root,root) %{_libdir}/%{name}/extract_crc | |
9de25172 JB |
443 | %attr(755,root,root) %{_libdir}/%{name}/objinfo_helper |
444 | %{_mandir}/man1/ocaml* | |
445 | %exclude %{_mandir}/man1/ocamlrun.1* | |
13b509d1 | 446 | |
79502218 JB |
447 | %files runtime |
448 | %defattr(644,root,root,755) | |
449 | %attr(755,root,root) %{_bindir}/ocamlrun | |
450 | %dir %{_libdir}/%{name} | |
7ff0f82f | 451 | %dir %{_libdir}/%{name}/site-lib |
79502218 JB |
452 | %dir %{_libdir}/%{name}/stublibs |
453 | %attr(755,root,root) %{_libdir}/%{name}/stublibs/dll*.so | |
454 | %exclude %{_libdir}/%{name}/stublibs/dllgraphics.so | |
42946d4f | 455 | %attr(755,root,root) %{_libdir}/%{name}/libcamlrun_shared.so |
79502218 JB |
456 | %if %{with tk} |
457 | %exclude %{_libdir}/%{name}/stublibs/dlllabltk.so | |
79502218 | 458 | %endif |
9de25172 | 459 | %{_mandir}/man1/ocamlrun.1* |
79502218 | 460 | |
13b509d1 MM |
461 | %files lib-source |
462 | %defattr(644,root,root,755) | |
463 | %{_libdir}/%{name}/*.ml | |
8151bf1e | 464 | %{_libdir}/%{name}/*.mli |
4c1e0f62 | 465 | %{_libdir}/%{name}/*/*.mli |
13b509d1 | 466 | |
79502218 | 467 | %files doc-html |
763b9075 | 468 | %defattr(644,root,root,755) |
79502218 JB |
469 | %doc docs/html/ocaml/* |
470 | ||
471 | %files doc-ps | |
472 | %defattr(644,root,root,755) | |
473 | %doc docs/*.ps.gz | |
474 | ||
475 | %files doc-info | |
476 | %defattr(644,root,root,755) | |
477 | %{_infodir}/ocaml.info* | |
53fbd845 | 478 | |
13b509d1 MM |
479 | # they are poor, html is much better |
480 | #%files manpages | |
e68873d9 | 481 | #%%{_mandir}/man3/* |
65fbc6c7 | 482 | |
79502218 JB |
483 | %if %{with emacs} |
484 | %files emacs | |
56260732 | 485 | %defattr(644,root,root,755) |
79502218 JB |
486 | %{_datadir}/emacs/site-lisp/*.el* |
487 | %endif | |
56260732 | 488 | |
79502218 JB |
489 | %if %{with tk} |
490 | %files labltk | |
69735a4b | 491 | %defattr(644,root,root,755) |
79502218 | 492 | %attr(755,root,root) %{_libdir}/%{name}/stublibs/dlllabltk.so |
69735a4b | 493 | |
981ff793 | 494 | %files labltk-devel |
56260732 | 495 | %defattr(644,root,root,755) |
73a93122 | 496 | %attr(755,root,root) %{_bindir}/labltk |
497 | %attr(755,root,root) %{_bindir}/ocamlbrowser | |
56260732 MM |
498 | %dir %{_libdir}/%{name}/labltk |
499 | %{_libdir}/%{name}/labltk/*.cm* | |
500 | %{_libdir}/%{name}/labltk/*.a | |
42946d4f | 501 | %{_libdir}/%{name}/labltk/*.o |
73a93122 | 502 | %attr(755,root,root) %{_libdir}/%{name}/labltk/tkcompiler |
ba35c88b | 503 | %{_examplesdir}/%{name}-labltk-%{version} |
56260732 MM |
504 | %endif |
505 | ||
b552f088 | 506 | %if %{with x} |
79502218 JB |
507 | %files x11graphics |
508 | %defattr(644,root,root,755) | |
509 | %attr(755,root,root) %{_libdir}/%{name}/stublibs/dllgraphics.so | |
510 | ||
981ff793 | 511 | %files x11graphics-devel |
56260732 | 512 | %defattr(644,root,root,755) |
13b509d1 | 513 | %{_libdir}/%{name}/graphics*.cm* |
f442d039 | 514 | %{_libdir}/%{name}/graphics.a |
56260732 | 515 | %{_libdir}/%{name}/libgraphics.a |
56260732 MM |
516 | %endif |
517 | ||
79502218 | 518 | %files camlp4 |
65fbc6c7 | 519 | %defattr(644,root,root,755) |
e1542d3b JB |
520 | %attr(755,root,root) %{_bindir}/camlp4* |
521 | %attr(755,root,root) %{_bindir}/mkcamlp4 | |
79502218 | 522 | %{_libdir}/%{name}/camlp4 |
e1542d3b JB |
523 | %{_mandir}/man1/camlp4*.1* |
524 | %{_mandir}/man1/mkcamlp4.1* | |
4797676b | 525 | |
79502218 | 526 | %files camlp4-doc-html |
13b509d1 | 527 | %defattr(644,root,root,755) |
79502218 | 528 | %doc docs/html/camlp4* |
13b509d1 | 529 | |
79502218 | 530 | %files compiler-objects |
69735a4b | 531 | %defattr(644,root,root,755) |
79502218 | 532 | %{_libdir}/%{name}/compiler |
69735a4b | 533 | |
79502218 | 534 | %files ocamldoc-devel |
73a93122 | 535 | %defattr(644,root,root,755) |
79502218 JB |
536 | %{_libdir}/%{name}/ocamldoc/*.cm* |
537 | %{_libdir}/%{name}/ocamldoc/*.a | |
69735a4b | 538 | |
79502218 | 539 | %files examples |
69735a4b | 540 | %defattr(644,root,root,755) |
79502218 | 541 | %{_examplesdir}/%{name}-%{version} |