]> git.pld-linux.org Git - packages/ocaml-zip.git/blob - ocaml-zip.spec
- typo
[packages/ocaml-zip.git] / ocaml-zip.spec
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:        Zlib binding for OCaml
11 Summary(pl.UTF-8):      Wiązania Zlib dla OCamla
12 Name:           ocaml-zip
13 Version:        1.11
14 %define gitver  rel111
15 Release:        1
16 License:        LGPL v2.1 with OCaml linking exception
17 Group:          Libraries
18 #Source0Download: https://github.com/xavierleroy/camlzip/tags
19 Source0:        https://github.com/xavierleroy/camlzip/archive/%{gitver}.tar.gz?/camlzip-%{gitver}.tar.gz
20 # Source0-md5:  ee7a2ecf4801226003ba2cd1b1f11d4d
21 URL:            https://xavierleroy.org/software.html
22 BuildRequires:  ocaml >= 1:4.07
23 BuildRequires:  ocaml-findlib
24 BuildRequires:  zlib-devel >= 1.1.3
25 %requires_eq    ocaml-runtime
26 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27
28 %description
29 This Objective Caml library provides easy access to compressed files
30 in ZIP and GZIP format, as well as to Java JAR files. It provides
31 functions for reading from and writing to compressed files in these
32 formats.
33
34 This package contains files needed to run bytecode executables using
35 this library.
36
37 %description -l pl.UTF-8
38 Biblioteka ta pozwala na dostęp do plików w formacie ZIP i GZIP jak
39 również dla plików JAR Javy z poziomy OCamla. Udostępnia ona funkcje
40 do czytania i pisania do plików w tych formatach.
41
42 Pakiet ten zawiera binaria potrzebne do uruchamiania programów
43 używających tej biblioteki.
44
45 %package devel
46 Summary:        Zlib binding for OCaml - development part
47 Summary(pl.UTF-8):      Wiązania Zlib dla OCamla - część programistyczna
48 Group:          Development/Libraries
49 Requires:       %{name} = %{version}-%{release}
50 %requires_eq    ocaml
51
52 %description devel
53 This Objective Caml library provides easy access to compressed files
54 in ZIP and GZIP format, as well as to Java JAR files. It provides
55 functions for reading from and writing to compressed files in these
56 formats.
57
58 This package contains files needed to develop OCaml programs using
59 this library.
60
61 %description devel -l pl.UTF-8
62 Biblioteka ta pozwala na dostęp do plików w formacie ZIP i GZIP jak
63 również dla plików JAR Javy z poziomy OCamla. Udostępnia ona funkcje
64 do czytania i pisania do plików w tych formatach.
65
66 Pakiet ten zawiera pliki niezbędne do tworzenia programów używających
67 tej biblioteki.
68
69 %prep
70 %setup -q -n camlzip-%{gitver}
71
72 %build
73 %{__cc} %{rpmcflags} %{rpmcppflags} -fPIC -c zlibstubs.c
74
75 %{__make} allbyt %{?with_ocaml_opt:allopt}
76
77 %install
78 rm -rf $RPM_BUILD_ROOT
79 install -d $RPM_BUILD_ROOT%{_libdir}/ocaml/stublibs
80
81 %{__make} install \
82         OCAMLFIND_DESTDIR=$RPM_BUILD_ROOT%{_libdir}/ocaml
83
84 # useless in rpm
85 %{__rm} $RPM_BUILD_ROOT%{_libdir}/ocaml/stublibs/*.so.owner
86
87 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
88 cp -pr test/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
89
90 %clean
91 rm -rf $RPM_BUILD_ROOT
92
93 %files
94 %defattr(644,root,root,755)
95 %doc Changes LICENSE README.md
96 %attr(755,root,root) %{_libdir}/ocaml/stublibs/dllcamlzip.so
97 %if %{with ocaml_opt}
98 %{_libdir}/ocaml/zip/*.cmxs
99 %endif
100
101 %files devel
102 %defattr(644,root,root,755)
103 %dir %{_libdir}/ocaml/camlzip
104 %{_libdir}/ocaml/camlzip/META
105 %dir %{_libdir}/ocaml/zip
106 %{_libdir}/ocaml/zip/META
107 %{_libdir}/ocaml/zip/*.cma
108 %{_libdir}/ocaml/zip/*.cmi
109 %{_libdir}/ocaml/zip/*.cmt
110 %{_libdir}/ocaml/zip/*.cmti
111 %{_libdir}/ocaml/zip/*.mli
112 %{_libdir}/ocaml/zip/libcamlzip.a
113 %if %{with ocaml_opt}
114 %{_libdir}/ocaml/zip/*.cmx
115 %{_libdir}/ocaml/zip/*.cmxa
116 %{_libdir}/ocaml/zip/zip.a
117 %endif
118 %{_examplesdir}/%{name}-%{version}
This page took 0.152265 seconds and 3 git commands to generate.