]>
Commit | Line | Data |
---|---|---|
74f5a091 JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without ocaml_opt # native optimized binaries (bytecode is always built) | |
4 | ||
5 | # not yet available on x32 (ocaml 4.02.1), update when upstream will support it | |
6 | %ifnarch %{ix86} %{x8664} %{arm} aarch64 ppc sparc sparcv9 | |
7 | %undefine with_ocaml_opt | |
8 | %endif | |
9 | ||
10 | Summary: React - declarative events and signals for OCaml | |
11 | Summary(pl.UTF-8): React - deklaratywne zdarzenia i sygnały dla OCamla | |
12 | Name: ocaml-react | |
13 | Version: 1.2.1 | |
14 | Release: 1 | |
15 | License: ISC | |
16 | Group: Libraries | |
17 | Source0: https://erratique.ch/software/react/releases/react-%{version}.tbz | |
18 | # Source0-md5: ce1454438ce4e9d2931248d3abba1fcc | |
19 | URL: https://erratique.ch/software/react | |
20 | BuildRequires: ocaml >= 1:4.01.0 | |
21 | BuildRequires: ocaml-findlib-devel | |
22 | BuildRequires: ocaml-ocamlbuild | |
23 | BuildRequires: ocaml-topkg-devel >= 0.9.0 | |
24 | %requires_eq ocaml-runtime | |
25 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
26 | ||
27 | %define debug_package %{nil} | |
28 | ||
29 | %description | |
30 | React is an OCaml module for functional reactive programming (FRP). It | |
31 | provides support to program with time varying values: declarative | |
32 | events and signals. React doesn't define any primitive event or | |
33 | signal, it lets the client choose the concrete timeline. | |
34 | ||
35 | This package contains files needed to run bytecode executables using | |
36 | OCaml react library. | |
37 | ||
38 | %description -l pl.UTF-8 | |
39 | React to moduł OCamla do funkcyjnego programowania reaktywnego (FRP). | |
40 | Wspiera programowanie z wartościami zmiennymi w czasie: deklaratywnymi | |
41 | zdarzeniami i sygnałami. React nie definiuje żadnego podstawowego | |
42 | zdarzenia czy sygnału, pozwala klientowi wybrać konkretną oś czasu. | |
43 | ||
44 | Pakiet ten zawiera binaria potrzebne do uruchamiania programów | |
45 | używających biblioteki OCamla react. | |
46 | ||
47 | %package devel | |
48 | Summary: React - declarative events and signals for OCaml - development part | |
d7e30f84 | 49 | Summary(pl.UTF-8): React - deklaratywne zdarzenia i sygnały dla OCamla - część programistyczna |
74f5a091 JB |
50 | Group: Development/Libraries |
51 | Requires: %{name} = %{version}-%{release} | |
52 | %requires_eq ocaml | |
53 | ||
54 | %description devel | |
55 | This package contains files needed to develop OCaml programs using | |
56 | react library. | |
57 | ||
58 | %description devel -l pl.UTF-8 | |
59 | Pakiet ten zawiera pliki niezbędne do tworzenia programów w OCamlu | |
60 | używających biblioteki react. | |
61 | ||
62 | %prep | |
63 | %setup -q -n react-%{version} | |
64 | ||
65 | %build | |
66 | ocaml pkg/pkg.ml build | |
67 | ||
68 | %install | |
69 | rm -rf $RPM_BUILD_ROOT | |
70 | install -d $RPM_BUILD_ROOT%{_libdir}/ocaml/react | |
71 | ||
72 | cp -p _build/pkg/META _build/opam $RPM_BUILD_ROOT%{_libdir}/ocaml/react | |
73 | cp -p _build/src/*.{cma,cmi,cmt,cmti,mli} $RPM_BUILD_ROOT%{_libdir}/ocaml/react | |
74 | %if %{with ocaml_opt} | |
75 | cp -p _build/src/*.{a,cmxs,cmx,cmxa} $RPM_BUILD_ROOT%{_libdir}/ocaml/react | |
76 | %endif | |
77 | ||
78 | %clean | |
79 | rm -rf $RPM_BUILD_ROOT | |
80 | ||
81 | %files | |
82 | %defattr(644,root,root,755) | |
83 | %doc CHANGES.md LICENSE.md README.md TODO.md | |
84 | %dir %{_libdir}/ocaml/react | |
85 | %{_libdir}/ocaml/react/META | |
86 | %{_libdir}/ocaml/react/*.cma | |
87 | %if %{with ocaml_opt} | |
88 | %attr(755,root,root) %{_libdir}/ocaml/react/*.cmxs | |
89 | %endif | |
90 | ||
91 | %files devel | |
92 | %defattr(644,root,root,755) | |
93 | %{_libdir}/ocaml/react/*.cmi | |
94 | %{_libdir}/ocaml/react/*.cmt | |
95 | %{_libdir}/ocaml/react/*.cmti | |
96 | %{_libdir}/ocaml/react/*.mli | |
97 | %if %{with ocaml_opt} | |
98 | %{_libdir}/ocaml/react/*.a | |
99 | %{_libdir}/ocaml/react/*.cmx | |
100 | %{_libdir}/ocaml/react/*.cmxa | |
101 | %endif | |
102 | %{_libdir}/ocaml/react/opam |