]> git.pld-linux.org Git - packages/ocaml.git/blob - ocaml.spec
f70bbb008145b274e54ef6f5d1e6b953dccf8b00
[packages/ocaml.git] / ocaml.spec
1 Summary:        The Objective Caml compiler and programming environment
2 Summary(pl):    Kompilator Objektowego Caml oraz ¶rodowisko programistyczne
3 Name:           ocaml
4 Version:        2.02
5 Release:        1
6 URL:            http://pauillac.inria.fr/caml/
7 Vendor:         Group of implementors <caml-light@inria.fr>
8 Source0:        ftp://ftp.inria.fr/lang/caml-light/%{name}-%{version}.tar.gz
9 Source1:        ftp://ftp.inria.fr/lang/caml-light/%{name}-%{version}-refman.html.tar.gz
10 Patch0:         ocaml-ext_prof.patch
11 Patch1:         ocaml-opt.patch
12 Copyright:      Distributable
13 Group:          Development/Languages
14 BuildRoot:      /tmp/%{name}-%{version}-root
15
16 %description
17 Objective Caml is a high-level, strongly-typed, functional and
18 object-oriented programming language from the ML family of languages.
19
20 This package comprises two batch compilers (a fast bytecode compiler
21 and an optimizing native-code compiler), an interactive toplevel system,
22 Lex&Yacc tools, a replay debugger, and a comprehensive library.
23
24 %description -l pl
25 Objektowy Caml jest funkcjonalnym, objektowo zorientowanym jêzykiem
26 wysokiego poziomuz rodziny jêzyków ML.
27
28 Ten pakiet zawiera dwa kompilatory (szybki kompilator bytecode
29 oraz zoptymalizowany natywny kompilator), interaktywny g³ówny system,
30 narzêdzia Lex&Yacc, odpluskwiacz i biblioteki.
31
32 %package emacs
33 Group:          Development/Tools
34 Summary:        Emacs mode for OCaml
35 Summary(pl):    Tryb Emacsa dla OCaml
36 Requires:       %{name} = %{version}
37 # xemacs doesn't have Provide emacs ?
38 #BuildRequires: emacs
39
40 %description emacs
41 Emacs mode files for Objective Caml language
42
43 %description -l pl emacs
44 Pliki trybu Emacsa dla jêzyka Objektowego Caml
45
46
47 %prep
48 %setup -q -T -b 0
49 %setup -q -T -D -a 1
50 %patch0 -p0
51 %patch1 -p1
52
53 %build
54 ./configure \
55         -cc "cc $RPM_OPT_FLAGS" \
56         -bindir %{_bindir} \
57         -libdir %{_libdir}/%{name} \
58         -mandir %{_mandir}/man1 \
59         -host %{_host_alias} \
60         -with-pthread
61
62 make world bootstrap opt ocamlc.opt ocamlopt.opt
63
64 %install
65 umask 022
66 rm -rf $RPM_BUILD_ROOT
67 echo    BINDIR=$RPM_BUILD_ROOT%{_bindir} >> config/Makefile
68 echo    LIBDIR=$RPM_BUILD_ROOT%{_libdir}/%{name} >> config/Makefile
69 echo    MANDIR=$RPM_BUILD_ROOT%{_mandir}/man1 >> config/Makefile
70 make    install 
71 make -C emacs install \
72         EMACS="`if [ -x %{_bindir}/emacs ]; then echo emacs; \
73                 else echo xemacs; fi`" \
74         EMACSDIR="$RPM_BUILD_ROOT%{_libdir}/emacs/site-lisp"
75 cp -p {parsing/{location,longident,parsetree},typing/typecore}.{cm,ml}i \
76         $RPM_BUILD_ROOT%{_libdir}/%{name}
77                         
78 gzip -9nf LICENSE Changes README $RPM_BUILD_ROOT%{_mandir}/man*/*
79
80 cd $RPM_BUILD_ROOT%{_bindir}
81 mv -f ocamlc            $RPM_BUILD_ROOT%{_bindir}/ocamlc.byte
82 mv -f ocamlc.opt        $RPM_BUILD_ROOT%{_bindir}/ocamlc
83 mv -f ocamlopt          $RPM_BUILD_ROOT%{_bindir}/ocamlopt.byte
84 mv -f ocamlopt.opt      $RPM_BUILD_ROOT%{_bindir}/ocamlopt
85 rm -f                   $RPM_BUILD_ROOT%{_libdir}/%{_name}/*.ml
86
87 strip                   $RPM_BUILD_ROOT%{_bindir}/* || :
88 %clean
89 rm -rf $RPM_BUILD_ROOT
90
91 %files
92 %defattr(644,root,root,755)
93 %doc htmlman *.gz
94 %attr(755, root, root) %{_bindir}/*
95 %{_libdir}/%{name}
96 %{_mandir}/man*/*
97
98 %files emacs
99 %defattr(644,root,root,755)
100 %{_libdir}/emacs/site-lisp/*.el
This page took 0.122435 seconds and 3 git commands to generate.