]>
Commit | Line | Data |
---|---|---|
20734182 JB |
1 | # Conditional build: |
2 | %bcond_without static_libs # don't build static libraries | |
3 | %bcond_without tbb # Threading Building Blocks | |
4 | # | |
644b99fc JR |
5 | |
6 | %ifarch i486 | |
7 | %undefine with_tbb | |
8 | %endif | |
9 | ||
20734182 JB |
10 | Summary: Library for reading and writing images |
11 | Summary(pl.UTF-8): Biblioteka do odczytu i zapisu obrazów | |
12 | Name: OpenImageIO | |
907ca7e3 | 13 | Version: 1.0.7 |
644b99fc | 14 | Release: 2 |
20734182 JB |
15 | License: BSD |
16 | Group: Libraries | |
17 | Source0: https://github.com/OpenImageIO/oiio/tarball/Release-%{version}#/%{name}-%{version}.tar.gz | |
5fbc5d86 | 18 | # Source0-md5: e939f97db2b0cac813c9e166f2353fe6 |
40b0de7c | 19 | Patch0: %{name}-link.patch |
8a5e279e | 20 | Patch2: %{name}-hdf.patch |
fc6d7d67 | 21 | Patch3: %{name}-system-squish.patch |
d46df4d1 | 22 | Patch4: %{name}-system-ptex.patch |
b238f81f JB |
23 | Patch5: %{name}-system-dpx.patch |
24 | Patch6: %{name}-system-libcineon.patch | |
20734182 | 25 | URL: https://sites.google.com/site/openimageio/home |
8a5e279e | 26 | BuildRequires: Field3D-devel |
20734182 JB |
27 | BuildRequires: OpenEXR-devel >= 1.6.1 |
28 | BuildRequires: OpenGL-devel | |
29 | BuildRequires: QtCore-devel | |
30 | BuildRequires: QtGui-devel | |
31 | BuildRequires: QtOpenGL-devel | |
32 | # filesystem, regex, system, thread | |
33 | BuildRequires: boost-devel >= 1.35 | |
34 | BuildRequires: boost-python-devel >= 1.35 | |
35 | BuildRequires: cmake >= 2.6 | |
b238f81f | 36 | BuildRequires: dpx-devel |
20734182 | 37 | BuildRequires: glew-devel >= 1.5.1 |
8a5e279e | 38 | BuildRequires: hdf5-devel |
20734182 JB |
39 | BuildRequires: ilmbase-devel >= 1.0.1 |
40 | BuildRequires: jasper-devel | |
e83a6d4b | 41 | BuildRequires: libcineon-devel |
20734182 JB |
42 | BuildRequires: libjpeg-devel |
43 | BuildRequires: libpng-devel | |
44 | BuildRequires: libtiff-devel | |
cf6fcddf | 45 | BuildRequires: libwebp-devel |
d46df4d1 | 46 | BuildRequires: ptex-devel >= 2 |
20734182 | 47 | BuildRequires: python-devel >= 1:2.6 |
fc6d7d67 | 48 | BuildRequires: squish-devel >= 1.10 |
20734182 | 49 | %{?with_tbb:BuildRequires: tbb-devel} |
5bef7fef | 50 | BuildRequires: txt2man |
20734182 JB |
51 | BuildRequires: zlib-devel |
52 | Requires: ilmbase >= 1.0.1 | |
53 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
54 | ||
55 | %description | |
56 | OpenImageIO is a library for reading and writing images, and a bunch | |
57 | of related classes, utilities, and applications. It has extremely | |
58 | simple but powerful ImageInput and ImageOutput APIs for reading and | |
59 | writing 2D images that is format agnostic; specific formats are | |
60 | implemented by DLL/DSO plugins. | |
61 | ||
62 | Currently there are format plugins for: TIFF, JPEG/JFIF, OpenEXR, PNG, | |
63 | HDR/RGBE, Targa, JPEG-2000, DPX, Cineon, FITS, BMP, ICO, RMan Zfile, | |
64 | Softimage PIC, DDS, SGI, PNM/PPM/PGM/PBM, Field3d, WebP. | |
65 | ||
66 | %description -l pl.UTF-8 | |
67 | OpenImageIO to biblioteka do odczytu i zapisu obrazów oraz wiele | |
68 | powiązanych klas, narzędzi i aplikacji. Ma bardzo proste, ale mające | |
69 | wiele możliwości API ImageInput i ImageOutput służące do odczytu i | |
70 | zapisu obrazów 2D, które jest niezależne od formatu; konkretne formaty | |
71 | są implementowane przez wtyczki DLL/DSO. | |
72 | ||
73 | Obecnie istnieją wtyczki obsługujące formaty: TIFF, JPEG/JFIF, | |
74 | OpenEXR, PNG, HDR/RGBE, Targa, JPEG-2000, DPX, Cineon, FITS, BMP, ICO, | |
75 | RMan Zfile, Softimage PIC, DDS, SGI, PNM/PPM/PGM/PBM, Field3d, WebP. | |
76 | ||
77 | %package devel | |
78 | Summary: Header files for OpenImageIO library | |
79 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki OpenImageIO | |
80 | Group: Development/Libraries | |
81 | Requires: %{name} = %{version}-%{release} | |
82 | ||
83 | %description devel | |
84 | Header files for OpenImageIO library. | |
85 | ||
86 | %description devel -l pl.UTF-8 | |
87 | Pliki nagłówkowe biblioteki OpenImageIO. | |
88 | ||
52005a92 JR |
89 | %package plugin-cineon |
90 | Summary: Cineon plugin for OpenImageIO library | |
91 | Summary(pl.UTF-8): Wtyczka Cineon dla biblioteki OpenImageIO | |
92 | Group: Libraries | |
93 | Requires: %{name} = %{version}-%{release} | |
94 | ||
95 | %description plugin-cineon | |
96 | OpenImageIO plugin to read Cineon files. | |
97 | ||
98 | %description plugin-cineon -l pl.UTF-8 | |
99 | Wtyczka biblioteki OpenImageIO czytająca pliki Cineon. | |
100 | ||
fc6d7d67 JB |
101 | %package plugin-dds |
102 | Summary: DDS plugin for OpenImageIO library | |
103 | Summary(pl.UTF-8): Wtyczka DDS dla biblioteki OpenImageIO | |
104 | Group: Libraries | |
105 | Requires: %{name} = %{version}-%{release} | |
106 | Requires: squish >= 1.10 | |
107 | ||
108 | %description plugin-dds | |
d46df4d1 | 109 | OpenImageIO plugin to read DDS files. |
fc6d7d67 JB |
110 | |
111 | %description plugin-dds -l pl.UTF-8 | |
d46df4d1 | 112 | Wtyczka biblioteki OpenImageIO czytająca pliki DDS. |
fc6d7d67 | 113 | |
b238f81f JB |
114 | %package plugin-dpx |
115 | Summary: DPX plugin for OpenImageIO library | |
116 | Summary(pl.UTF-8): Wtyczka DPX dla biblioteki OpenImageIO | |
117 | Group: Libraries | |
118 | Requires: %{name} = %{version}-%{release} | |
119 | ||
120 | %description plugin-dpx | |
121 | OpenImageIO plugin to read and write DPX files. | |
122 | ||
123 | %description plugin-dpx -l pl.UTF-8 | |
124 | Wtyczka biblioteki OpenImageIO czytająca i zapisująca pliki DPX. | |
125 | ||
8a5e279e JB |
126 | %package plugin-field3d |
127 | Summary: Field3D plugin for OpenImageIO library | |
128 | Summary(pl.UTF-8): Wtyczka Field3D dla biblioteki OpenImageIO | |
129 | Group: Libraries | |
130 | Requires: %{name} = %{version}-%{release} | |
131 | ||
132 | %description plugin-field3d | |
d46df4d1 | 133 | OpenImageIO plugin to read Field3D files. |
8a5e279e JB |
134 | |
135 | %description plugin-field3d -l pl.UTF-8 | |
d46df4d1 | 136 | Wtyczka biblioteki OpenImageIO czytająca pliki Field3D. |
8a5e279e | 137 | |
20734182 JB |
138 | %package plugin-ico |
139 | Summary: ICO plugin for OpenImageIO library | |
140 | Summary(pl.UTF-8): Wtyczka ICO dla biblioteki OpenImageIO | |
141 | Group: Libraries | |
142 | Requires: %{name} = %{version}-%{release} | |
143 | ||
144 | %description plugin-ico | |
145 | OpenImageIO plugin to read and write ICO files. | |
146 | ||
147 | %description plugin-ico -l pl.UTF-8 | |
148 | Wtyczka biblioteki OpenImageIO czytająca i zapisująca pliki ICO. | |
149 | ||
150 | %package plugin-jpeg | |
151 | Summary: JPEG plugin for OpenImageIO library | |
152 | Summary(pl.UTF-8): Wtyczka JPEG dla biblioteki OpenImageIO | |
153 | Group: Libraries | |
154 | Requires: %{name} = %{version}-%{release} | |
155 | ||
156 | %description plugin-jpeg | |
157 | OpenImageIO plugin to read and write JPEG files (with TIFF/EXIF | |
158 | information). | |
159 | ||
160 | %description plugin-jpeg -l pl.UTF-8 | |
161 | Wtyczka biblioteki OpenImageIO czytająca i zapisująca pliki JPEG | |
162 | (wraz z informacjami TIFF/EXIF). | |
163 | ||
164 | %package plugin-jpeg2000 | |
165 | Summary: JPEG2000 plugin for OpenImageIO library | |
166 | Summary(pl.UTF-8): Wtyczka JPEG2000 dla biblioteki OpenImageIO | |
167 | Group: Libraries | |
168 | Requires: %{name} = %{version}-%{release} | |
169 | ||
170 | %description plugin-jpeg2000 | |
171 | OpenImageIO plugin to read and write JPEG2000 files. | |
172 | ||
173 | %description plugin-jpeg2000 -l pl.UTF-8 | |
174 | Wtyczka biblioteki OpenImageIO czytająca i zapisująca pliki JPEG2000. | |
175 | ||
176 | %package plugin-openexr | |
177 | Summary: OpenEXR plugin for OpenImageIO library | |
178 | Summary(pl.UTF-8): Wtyczka OpenEXR dla biblioteki OpenImageIO | |
179 | Group: Libraries | |
180 | Requires: %{name} = %{version}-%{release} | |
181 | Requires: OpenEXR >= 1.6.1 | |
182 | ||
183 | %description plugin-openexr | |
184 | OpenImageIO plugin to read and write OpenEXR files. | |
185 | ||
186 | %description plugin-openexr -l pl.UTF-8 | |
187 | Wtyczka biblioteki OpenImageIO czytająca i zapisująca pliki OpenEXR. | |
188 | ||
189 | %package plugin-png | |
190 | Summary: PNG plugin for OpenImageIO library | |
191 | Summary(pl.UTF-8): Wtyczka PNG dla biblioteki OpenImageIO | |
192 | Group: Libraries | |
193 | Requires: %{name} = %{version}-%{release} | |
194 | ||
195 | %description plugin-png | |
196 | OpenImageIO plugin to read and write PNG files. | |
197 | ||
198 | %description plugin-png -l pl.UTF-8 | |
199 | Wtyczka biblioteki OpenImageIO czytająca i zapisująca pliki PNG. | |
200 | ||
52005a92 JR |
201 | %package plugin-psd |
202 | Summary: PSD plugin for OpenImageIO library | |
203 | Summary(pl.UTF-8): Wtyczka PSD dla biblioteki OpenImageIO | |
204 | Group: Libraries | |
205 | Requires: %{name} = %{version}-%{release} | |
206 | ||
207 | %description plugin-psd | |
208 | OpenImageIO plugin to read and write PSD files. | |
209 | ||
210 | %description plugin-psd -l pl.UTF-8 | |
211 | Wtyczka biblioteki OpenImageIO czytająca i zapisująca pliki PSD. | |
212 | ||
d46df4d1 JB |
213 | %package plugin-ptex |
214 | Summary: Ptex plugin for OpenImageIO library | |
215 | Summary(pl.UTF-8): Wtyczka Ptex dla biblioteki OpenImageIO | |
216 | Group: Libraries | |
217 | Requires: %{name} = %{version}-%{release} | |
218 | Requires: ptex >= 2 | |
219 | ||
220 | %description plugin-ptex | |
221 | OpenImageIO plugin to read Ptex files. | |
222 | ||
223 | %description plugin-ptex -l pl.UTF-8 | |
224 | Wtyczka biblioteki OpenImageIO czytająca pliki Ptex. | |
225 | ||
cf6fcddf JR |
226 | %package plugin-webp |
227 | Summary: WebP plugin for OpenImageIO library | |
228 | Summary(pl.UTF-8): Wtyczka WebP dla biblioteki OpenImageIO | |
229 | Group: Libraries | |
230 | Requires: %{name} = %{version}-%{release} | |
231 | ||
232 | %description plugin-webp | |
233 | OpenImageIO plugin to read and write WebP files. | |
234 | ||
235 | %description plugin-webp -l pl.UTF-8 | |
236 | Wtyczka biblioteki OpenImageIO czytająca i zapisująca pliki WebP. | |
237 | ||
20734182 JB |
238 | %package plugin-tiff |
239 | Summary: TIFF plugin for OpenImageIO library | |
240 | Summary(pl.UTF-8): Wtyczka TIFF dla biblioteki OpenImageIO | |
241 | Group: Libraries | |
242 | Requires: %{name} = %{version}-%{release} | |
243 | ||
244 | %description plugin-tiff | |
245 | OpenImageIO plugin to read and write TIFF files. | |
246 | ||
247 | %description plugin-tiff -l pl.UTF-8 | |
248 | Wtyczka biblioteki OpenImageIO czytająca i zapisująca pliki TIFF. | |
249 | ||
250 | %package apidocs | |
251 | Summary: Programmer documentation for OpenImageIO library | |
252 | Summary(pl.UTF-8): Dokumentacja programisty do biblioteki OpenImageIO | |
253 | Group: Documentation | |
254 | ||
255 | %description apidocs | |
256 | Programmer documentation for OpenImageIO library. | |
257 | ||
258 | %description apidocs -l pl.UTF-8 | |
259 | Dokumentacja programisty do biblioteki OpenImageIO. | |
260 | ||
261 | %package iv | |
262 | Summary: Qt/OpenImageIO-based Image Viewer | |
263 | Summary(pl.UTF-8): Przeglądarka obrazków (IV) oparta o Qt i OpenImageIO | |
264 | Group: X11/Applications/Graphics | |
265 | Requires: %{name} = %{version}-%{release} | |
266 | Requires: glew >= 1.5.1 | |
267 | ||
268 | %description iv | |
269 | IV is an image viewer based on ImageIO plugins; therefore it can read | |
270 | images of any format for which an appropriate plugin may be found. | |
271 | ||
272 | %description iv -l pl.UTF-8 | |
273 | IV to przeglądarka obrazków oparta na wtyczkach ImageIO; dzięki temu | |
274 | jest w stanie odczytać obrazy w dowolnym formacie, dla którego | |
275 | istnieje właściwa wtyczka. | |
276 | ||
277 | %package -n python-OpenImageIO | |
278 | Summary: Python binding for OpenImageIO library | |
279 | Summary(pl.UTF-8): Wiązanie Pythona do biblioteki OpenImageIO | |
280 | Group: Libraries/Python | |
281 | Requires: %{name} = %{version}-%{release} | |
282 | ||
283 | %description -n python-OpenImageIO | |
284 | Python binding for OpenImageIO library. | |
285 | ||
286 | %description -n python-OpenImageIO -l pl.UTF-8 | |
287 | Wiązanie Pythona do biblioteki OpenImageIO. | |
288 | ||
289 | %prep | |
9fcb7f94 | 290 | %setup -q -n OpenImageIO-oiio-e9fa4c7 |
40b0de7c | 291 | %patch0 -p1 |
8a5e279e | 292 | %patch2 -p1 |
fc6d7d67 | 293 | %patch3 -p1 |
d46df4d1 | 294 | %patch4 -p1 |
b238f81f JB |
295 | %patch5 -p1 |
296 | %patch6 -p1 | |
fc6d7d67 | 297 | |
d46df4d1 | 298 | %{__rm} -r src/dds.imageio/squish src/ptex.imageio/ptex |
20734182 JB |
299 | |
300 | %build | |
301 | install -d build | |
302 | cd build | |
303 | %cmake ../src \ | |
304 | -DEMBEDPLUGINS=OFF \ | |
52005a92 JR |
305 | -DPYLIB_INSTALL_DIR=%{py_sitedir} \ |
306 | -DINCLUDE_INSTALL_DIR=%{_includedir}/%{name} \ | |
20734182 | 307 | -DPYTHON_VERSION=%{py_ver} \ |
20734182 | 308 | %{!?with_tbb:-DUSE_TBB=OFF} \ |
20734182 JB |
309 | |
310 | %{__make} | |
311 | ||
312 | %install | |
313 | rm -rf $RPM_BUILD_ROOT | |
314 | ||
315 | %{__make} -C build install \ | |
316 | DESTDIR=$RPM_BUILD_ROOT | |
317 | ||
318 | # name clash with iv | |
40b0de7c | 319 | %{__mv} -f $RPM_BUILD_ROOT%{_bindir}/{iv,oiiv} |
5bef7fef | 320 | %{__mv} -f $RPM_BUILD_ROOT%{_mandir}/man1/{iv,oiiv}.1 |
20734182 | 321 | |
52005a92 JR |
322 | # installed as %doc |
323 | %{__rm} -r $RPM_BUILD_ROOT%{_datadir}/doc/openimageio | |
324 | ||
20734182 JB |
325 | %clean |
326 | rm -rf $RPM_BUILD_ROOT | |
327 | ||
328 | %post -p /sbin/ldconfig | |
329 | %postun -p /sbin/ldconfig | |
330 | ||
331 | %files | |
332 | %defattr(644,root,root,755) | |
333 | %doc CHANGES CREDITS LICENSE README | |
334 | %attr(755,root,root) %{_bindir}/iconvert | |
335 | %attr(755,root,root) %{_bindir}/idiff | |
336 | %attr(755,root,root) %{_bindir}/igrep | |
337 | %attr(755,root,root) %{_bindir}/iinfo | |
338 | %attr(755,root,root) %{_bindir}/iprocess | |
339 | %attr(755,root,root) %{_bindir}/maketx | |
52005a92 | 340 | %attr(755,root,root) %{_bindir}/oiiotool |
20734182 | 341 | %attr(755,root,root) %{_libdir}/libOpenImageIO.so.*.*.* |
40b0de7c | 342 | %attr(755,root,root) %ghost %{_libdir}/libOpenImageIO.so.1.0 |
20734182 | 343 | %attr(755,root,root) %{_libdir}/bmp.imageio.so |
20734182 JB |
344 | %attr(755,root,root) %{_libdir}/fits.imageio.so |
345 | %attr(755,root,root) %{_libdir}/hdr.imageio.so | |
52005a92 | 346 | %attr(755,root,root) %{_libdir}/iff.imageio.so |
20734182 | 347 | %attr(755,root,root) %{_libdir}/pnm.imageio.so |
52005a92 | 348 | %attr(755,root,root) %{_libdir}/rla.imageio.so |
20734182 JB |
349 | %attr(755,root,root) %{_libdir}/sgi.imageio.so |
350 | %attr(755,root,root) %{_libdir}/socket.imageio.so | |
351 | %attr(755,root,root) %{_libdir}/softimage.imageio.so | |
352 | %attr(755,root,root) %{_libdir}/targa.imageio.so | |
353 | %attr(755,root,root) %{_libdir}/zfile.imageio.so | |
5bef7fef JR |
354 | %{_mandir}/man1/iconvert.1* |
355 | %{_mandir}/man1/idiff.1* | |
356 | %{_mandir}/man1/igrep.1* | |
357 | %{_mandir}/man1/iinfo.1* | |
358 | %{_mandir}/man1/iprocess.1* | |
359 | %{_mandir}/man1/maketx.1* | |
360 | %{_mandir}/man1/oiiotool.1* | |
20734182 JB |
361 | |
362 | %files devel | |
363 | %defattr(644,root,root,755) | |
364 | %attr(755,root,root) %{_libdir}/libOpenImageIO.so | |
365 | %{_includedir}/OpenImageIO | |
366 | ||
52005a92 JR |
367 | %files plugin-cineon |
368 | %defattr(644,root,root,755) | |
369 | %attr(755,root,root) %{_libdir}/cineon.imageio.so | |
370 | ||
fc6d7d67 JB |
371 | %files plugin-dds |
372 | %defattr(644,root,root,755) | |
373 | %attr(755,root,root) %{_libdir}/dds.imageio.so | |
374 | ||
b238f81f JB |
375 | %files plugin-dpx |
376 | %defattr(644,root,root,755) | |
377 | %attr(755,root,root) %{_libdir}/dpx.imageio.so | |
378 | ||
8a5e279e JB |
379 | %files plugin-field3d |
380 | %defattr(644,root,root,755) | |
381 | %attr(755,root,root) %{_libdir}/field3d.imageio.so | |
382 | ||
20734182 JB |
383 | %files plugin-ico |
384 | %defattr(644,root,root,755) | |
385 | %attr(755,root,root) %{_libdir}/ico.imageio.so | |
386 | ||
387 | %files plugin-jpeg | |
388 | %defattr(644,root,root,755) | |
389 | %attr(755,root,root) %{_libdir}/jpeg.imageio.so | |
390 | ||
391 | %files plugin-jpeg2000 | |
392 | %defattr(644,root,root,755) | |
393 | %attr(755,root,root) %{_libdir}/jpeg2000.imageio.so | |
394 | ||
395 | %files plugin-openexr | |
396 | %defattr(644,root,root,755) | |
397 | %attr(755,root,root) %{_libdir}/openexr.imageio.so | |
398 | ||
399 | %files plugin-png | |
400 | %defattr(644,root,root,755) | |
401 | %attr(755,root,root) %{_libdir}/png.imageio.so | |
402 | ||
52005a92 JR |
403 | %files plugin-psd |
404 | %defattr(644,root,root,755) | |
405 | %attr(755,root,root) %{_libdir}/psd.imageio.so | |
406 | ||
d46df4d1 JB |
407 | %files plugin-ptex |
408 | %defattr(644,root,root,755) | |
409 | %attr(755,root,root) %{_libdir}/ptex.imageio.so | |
410 | ||
20734182 JB |
411 | %files plugin-tiff |
412 | %defattr(644,root,root,755) | |
413 | %attr(755,root,root) %{_libdir}/tiff.imageio.so | |
414 | ||
cf6fcddf JR |
415 | %files plugin-webp |
416 | %defattr(644,root,root,755) | |
417 | %attr(755,root,root) %{_libdir}/webp.imageio.so | |
418 | ||
20734182 JB |
419 | %files apidocs |
420 | %defattr(644,root,root,755) | |
421 | %doc src/doc/openimageio.pdf | |
422 | ||
423 | %files iv | |
424 | %defattr(644,root,root,755) | |
425 | %attr(755,root,root) %{_bindir}/oiiv | |
5bef7fef | 426 | %{_mandir}/man1/oiiv.1* |
20734182 JB |
427 | |
428 | %files -n python-OpenImageIO | |
429 | %defattr(644,root,root,755) | |
430 | %attr(755,root,root) %{py_sitedir}/OpenImageIO.so |