]>
Commit | Line | Data |
---|---|---|
261d3977 JB |
1 | # |
2 | # Conditional build: | |
90a34fd6 | 3 | %bcond_without ixion # ixion-based spreadsheet model support |
cbb865a5 | 4 | %bcond_without python # Python 3 binding |
6f6f60d3 | 5 | %bcond_without apidocs # Sphinx documentation |
261d3977 JB |
6 | %bcond_without static_libs # static library |
7 | # | |
81a745c4 | 8 | Summary: Standalone file import filter library for spreadsheet documents |
261d3977 | 9 | Summary(pl.UTF-8): Biblioteka samodzielnego filtra importującego pliki dla arkuszy kalkulacyjnych |
81a745c4 | 10 | Name: liborcus |
6f6f60d3 | 11 | Version: 0.14.1 |
ee30d402 | 12 | Release: 3 |
d4854844 | 13 | License: MPL v2.0 |
81a745c4 | 14 | Group: Libraries |
6f6f60d3 | 15 | #Source0Download: https://gitlab.com/orcus/orcus/raw/master/README.md |
8d927631 | 16 | Source0: http://kohei.us/files/orcus/src/%{name}-%{version}.tar.xz |
6f6f60d3 | 17 | # Source0-md5: d3f56b0eb115a081ee3e1d244f0a8a78 |
d4854844 | 18 | Patch0: %{name}-flags.patch |
8d927631 | 19 | URL: https://gitlab.com/orcus/orcus |
90a34fd6 JB |
20 | BuildRequires: autoconf >= 2.65 |
21 | BuildRequires: automake >= 1:1.11 | |
806b8082 | 22 | BuildRequires: boost-devel >= 1.36 |
b5b5a620 | 23 | %{?with_ixion:BuildRequires: ixion-devel >= 0.14.0} |
cbb865a5 | 24 | BuildRequires: libstdc++-devel >= 6:4.7 |
90a34fd6 | 25 | BuildRequires: libtool >= 2:1.5 |
b5b5a620 | 26 | BuildRequires: mdds-devel >= 1.4.0 |
261d3977 | 27 | BuildRequires: pkgconfig >= 1:0.20 |
cbb865a5 | 28 | %{?with_python:BuildRequires: python3-devel >= 1:3.2} |
8d927631 JB |
29 | BuildRequires: tar >= 1:1.22 |
30 | BuildRequires: xz | |
81a745c4 | 31 | BuildRequires: zlib-devel |
6f6f60d3 JB |
32 | %if %{with apidocs} |
33 | BuildRequires: doxygen | |
34 | BuildRequires: python3-breathe | |
35 | BuildRequires: python3-sphinx_bootstrap_theme | |
36 | BuildRequires: sphinx-pdg-3 | |
37 | %endif | |
81a745c4 AM |
38 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
39 | ||
40 | %description | |
261d3977 | 41 | liborcus is a standalone file import filter library for spreadsheet |
81a745c4 AM |
42 | documents. Currently under development are ODS, XLSX and CSV import |
43 | filters. | |
44 | ||
261d3977 JB |
45 | %description -l pl.UTF-8 |
46 | liborcus to biblioteka samodzielnego filtra importującego pliki dla | |
47 | arkuszy kalkulacyjnych. Obecnie rozwijane są filtry importujące | |
48 | dokumenty ODS, XLSX i CSV. | |
49 | ||
81a745c4 | 50 | %package devel |
261d3977 JB |
51 | Summary: Header files for liborcus |
52 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki liborcus | |
81a745c4 AM |
53 | Group: Development/Libraries |
54 | Requires: %{name} = %{version}-%{release} | |
806b8082 | 55 | Requires: boost-devel >= 1.36 |
cbb865a5 | 56 | Requires: libstdc++-devel >= 6:4.7 |
81a745c4 AM |
57 | |
58 | %description devel | |
261d3977 JB |
59 | This package contains the header files for developing applications |
60 | that use liborcus. | |
61 | ||
62 | %description devel -l pl.UTF-8 | |
63 | Ten pakiet zawiera pliki nagłówkowe do tworzenia aplikacji | |
64 | wykorzystujących bibliotekę liborcus. | |
65 | ||
66 | %package static | |
67 | Summary: Static liborcus library | |
68 | Summary(pl.UTF-8): Statyczna biblioteka liborcus | |
69 | Group: Development/Libraries | |
70 | Requires: %{name}-devel = %{version}-%{release} | |
71 | ||
72 | %description static | |
73 | Static liborcus library. | |
74 | ||
75 | %description static -l pl.UTF-8 | |
76 | Statyczna biblioteka liborcus. | |
81a745c4 | 77 | |
90a34fd6 JB |
78 | %package spreadsheet |
79 | Summary: liborcus spreadsheet model library | |
80 | Summary(pl.UTF-8): Biblioteka liborcus spreadsheet model | |
81 | Group: Libraries | |
82 | Requires: %{name} = %{version}-%{release} | |
b5b5a620 | 83 | Requires: ixion >= 0.14.0 |
90a34fd6 JB |
84 | |
85 | %description spreadsheet | |
86 | liborcus spreadsheet model library. | |
87 | ||
88 | %description spreadsheet -l pl.UTF-8 | |
89 | Biblioteka liborcus spreadsheet model (modelu arkuszy kalkulacyjnych). | |
90 | ||
91 | %package spreadsheet-devel | |
92 | Summary: Development files for liborcus spreadsheet model library | |
93 | Summary(pl.UTF-8): Pliki programistyczne biblioteki liborcus spreadsheet model | |
94 | Group: Development/Libraries | |
95 | Requires: %{name}-devel = %{version}-%{release} | |
96 | Requires: %{name}-spreadsheet = %{version}-%{release} | |
b5b5a620 | 97 | Requires: ixion-devel >= 0.14.0 |
90a34fd6 JB |
98 | |
99 | %description spreadsheet-devel | |
100 | Development files for liborcus spreadsheet model library. | |
101 | ||
102 | %description spreadsheet-devel -l pl.UTF-8 | |
103 | Pliki programistyczne biblioteki liborcus spreadsheet model. | |
104 | ||
105 | %package spreadsheet-static | |
106 | Summary: Static liborcus spreadsheet model library | |
107 | Summary(pl.UTF-8): Biblioteka statyczna liborcus spreadsheet model | |
108 | Group: Development/Libraries | |
109 | Requires: %{name}-spreadsheet-devel = %{version}-%{release} | |
110 | ||
111 | %description spreadsheet-static | |
112 | Static liborcus spreadsheet model library. | |
113 | ||
114 | %description spreadsheet-static -l pl.UTF-8 | |
115 | Biblioteka statyczna liborcus spreadsheet model. | |
116 | ||
6f6f60d3 JB |
117 | %package apidocs |
118 | Summary: API documentation for orcus libraries | |
119 | Summary(pl.UTF-8): Dokumentacja API bibliotek orcus | |
120 | Group: Documentation | |
121 | ||
122 | %description apidocs | |
123 | API documentation for orcus libraries. | |
124 | ||
125 | %description apidocs -l pl.UTF-8 | |
126 | Dokumentacja API bibliotek orcus. | |
127 | ||
cbb865a5 JB |
128 | %package -n python3-orcus |
129 | Summary: Python 3 binding for liborcus library | |
130 | Summary(pl.UTF-8): Wiązanie Pythona 3 do biblioteki liborcus | |
131 | Group: Libraries/Python | |
132 | Requires: %{name} = %{version}-%{release} | |
133 | Requires: python3-libs >= 1:3.2 | |
134 | ||
135 | %description -n python3-orcus | |
136 | Python 3 binding for liborcus library. | |
137 | ||
138 | %description -n python3-orcus -l pl.UTF-8 | |
139 | Wiązanie Pythona 3 do biblioteki liborcus. | |
140 | ||
81a745c4 | 141 | %prep |
6cb5819d | 142 | %setup -q |
d4854844 | 143 | %patch0 -p1 |
81a745c4 AM |
144 | |
145 | %build | |
90a34fd6 JB |
146 | %{__libtoolize} |
147 | %{__aclocal} -I m4 | |
148 | %{__autoconf} | |
149 | %{__autoheader} | |
150 | %{__automake} | |
81a745c4 | 151 | %configure \ |
d4854844 | 152 | am_cv_python_pyexecdir=%{py3_sitedir} \ |
e84b8743 | 153 | am_cv_python_pythondir=%{py3_sitescriptdir} \ |
81a745c4 | 154 | --disable-debug \ |
cbb865a5 | 155 | %{!?with_python:--disable-python} \ |
261d3977 JB |
156 | --disable-silent-rules \ |
157 | %{!?with_ixion:--disable-spreadsheet-model} \ | |
158 | %{!?with_static_libs:--disable-static} \ | |
81a745c4 | 159 | --disable-werror \ |
8d927631 JB |
160 | --with-pic |
161 | ||
81a745c4 AM |
162 | %{__make} |
163 | ||
6f6f60d3 JB |
164 | %if %{with apidocs} |
165 | cd doc | |
166 | doxygen doxygen.conf | |
167 | sphinx-build-3 -b html . _build | |
168 | %endif | |
81a745c4 AM |
169 | |
170 | %install | |
171 | rm -rf $RPM_BUILD_ROOT | |
172 | ||
173 | %{__make} install \ | |
174 | DESTDIR=$RPM_BUILD_ROOT | |
175 | ||
261d3977 JB |
176 | # obsoleted by pkg-config |
177 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/liborcus-*.la | |
178 | ||
cbb865a5 JB |
179 | %if %{with python} |
180 | %{__rm} $RPM_BUILD_ROOT%{py3_sitedir}/*.la | |
181 | %if %{with static_libs} | |
182 | %{__rm} $RPM_BUILD_ROOT%{py3_sitedir}/*.a | |
183 | %endif | |
184 | %endif | |
185 | ||
81a745c4 AM |
186 | %clean |
187 | rm -rf $RPM_BUILD_ROOT | |
188 | ||
261d3977 JB |
189 | %post -p /sbin/ldconfig |
190 | %postun -p /sbin/ldconfig | |
81a745c4 | 191 | |
90a34fd6 JB |
192 | %post spreadsheet -p /sbin/ldconfig |
193 | %postun spreadsheet -p /sbin/ldconfig | |
194 | ||
81a745c4 AM |
195 | %files |
196 | %defattr(644,root,root,755) | |
d4854844 | 197 | %doc AUTHORS CHANGELOG ChangeLog LICENSE README.md |
8d927631 | 198 | %attr(755,root,root) %{_bindir}/orcus-css-dump |
806b8082 | 199 | %attr(755,root,root) %{_bindir}/orcus-detect |
cbb865a5 | 200 | %attr(755,root,root) %{_bindir}/orcus-json |
6cb5819d | 201 | %attr(755,root,root) %{_bindir}/orcus-mso-encryption |
81a745c4 | 202 | %attr(755,root,root) %{_bindir}/orcus-xml-dump |
cbb865a5 | 203 | %attr(755,root,root) %{_bindir}/orcus-yaml |
6cb5819d | 204 | %attr(755,root,root) %{_bindir}/orcus-zip-dump |
b5b5a620 AG |
205 | %attr(755,root,root) %{_libdir}/liborcus-0.14.so.*.*.* |
206 | %attr(755,root,root) %ghost %{_libdir}/liborcus-0.14.so.0 | |
207 | %attr(755,root,root) %{_libdir}/liborcus-mso-0.14.so.*.*.* | |
208 | %attr(755,root,root) %ghost %{_libdir}/liborcus-mso-0.14.so.0 | |
209 | %attr(755,root,root) %{_libdir}/liborcus-parser-0.14.so.*.*.* | |
210 | %attr(755,root,root) %ghost %{_libdir}/liborcus-parser-0.14.so.0 | |
81a745c4 AM |
211 | |
212 | %files devel | |
213 | %defattr(644,root,root,755) | |
b5b5a620 AG |
214 | %attr(755,root,root) %{_libdir}/liborcus-0.14.so |
215 | %attr(755,root,root) %{_libdir}/liborcus-mso-0.14.so | |
216 | %attr(755,root,root) %{_libdir}/liborcus-parser-0.14.so | |
217 | %{_includedir}/liborcus-0.14 | |
218 | %{_pkgconfigdir}/liborcus-0.14.pc | |
261d3977 JB |
219 | |
220 | %if %{with static_libs} | |
221 | %files static | |
222 | %defattr(644,root,root,755) | |
b5b5a620 AG |
223 | %{_libdir}/liborcus-0.14.a |
224 | %{_libdir}/liborcus-mso-0.14.a | |
225 | %{_libdir}/liborcus-parser-0.14.a | |
90a34fd6 JB |
226 | %endif |
227 | ||
228 | %if %{with ixion} | |
229 | %files spreadsheet | |
230 | %defattr(644,root,root,755) | |
231 | %attr(755,root,root) %{_bindir}/orcus-csv | |
232 | %attr(755,root,root) %{_bindir}/orcus-gnumeric | |
73b4d81c | 233 | %attr(755,root,root) %{_bindir}/orcus-styles-ods |
90a34fd6 | 234 | %attr(755,root,root) %{_bindir}/orcus-ods |
806b8082 | 235 | %attr(755,root,root) %{_bindir}/orcus-xls-xml |
90a34fd6 JB |
236 | %attr(755,root,root) %{_bindir}/orcus-xlsx |
237 | %attr(755,root,root) %{_bindir}/orcus-xml | |
b5b5a620 AG |
238 | %attr(755,root,root) %{_libdir}/liborcus-spreadsheet-model-0.14.so.*.*.* |
239 | %attr(755,root,root) %ghost %{_libdir}/liborcus-spreadsheet-model-0.14.so.0 | |
90a34fd6 JB |
240 | |
241 | %files spreadsheet-devel | |
242 | %defattr(644,root,root,755) | |
b5b5a620 AG |
243 | %attr(755,root,root) %{_libdir}/liborcus-spreadsheet-model-0.14.so |
244 | %{_pkgconfigdir}/liborcus-spreadsheet-model-0.14.pc | |
90a34fd6 JB |
245 | |
246 | %files spreadsheet-static | |
247 | %defattr(644,root,root,755) | |
b5b5a620 | 248 | %{_libdir}/liborcus-spreadsheet-model-0.14.a |
cbb865a5 JB |
249 | %endif |
250 | ||
6f6f60d3 JB |
251 | %if %{with apidocs} |
252 | %files apidocs | |
253 | %defattr(644,root,root,755) | |
254 | %doc doc/_build/{_static,cpp,overview,python,*.html,*.js} | |
255 | %endif | |
256 | ||
cbb865a5 JB |
257 | %if %{with python} |
258 | %files -n python3-orcus | |
259 | %defattr(644,root,root,755) | |
260 | %attr(755,root,root) %{py3_sitedir}/_orcus.so | |
261 | %attr(755,root,root) %{py3_sitedir}/_orcus_json.so | |
e84b8743 | 262 | %{py3_sitescriptdir}/orcus |
90a34fd6 | 263 | %endif |