]>
Commit | Line | Data |
---|---|---|
1 | # TODO (proprietary?): | |
2 | # - truelight http://www.filmlight.ltd.uk/products/truelight/overview_tl.php | |
3 | # - nuke: http://docs.thefoundry.co.uk/products/nuke/ | |
4 | # | |
5 | # Conditional build: | |
6 | %bcond_without oiio # OpenImageIO-dependent apps (ocioconvert,ociodisplay) | |
7 | %bcond_without opengl # OpenGL-dependent app (ociodisplay) | |
8 | %bcond_with java # JNI glue | |
9 | %bcond_with doc # documentation | |
10 | %bcond_with sse2 # use SSE2 instructions | |
11 | # | |
12 | %ifarch %{x8664} pentrium4 | |
13 | %define with_sse2 1 | |
14 | %endif | |
15 | Summary: Complete color management solution | |
16 | Summary(pl.UTF-8): Kompletny pakiet do zarządzania kolorami | |
17 | Name: OpenColorIO | |
18 | Version: 2.1.1 | |
19 | Release: 2 | |
20 | License: BSD | |
21 | Group: Libraries | |
22 | #Source0Download: https://github.com/imageworks/OpenColorIO/releases | |
23 | Source0: https://github.com/imageworks/OpenColorIO/archive/v%{version}/%{name}-%{version}.tar.gz | |
24 | # Source0-md5: 604f562e073f23d88ce89ed4f7f709ba | |
25 | URL: http://opencolorio.org/ | |
26 | BuildRequires: Imath-devel >= 3.1.2 | |
27 | BuildRequires: cmake >= 2.8 | |
28 | %{?with_java:BuildRequires: jdk} | |
29 | BuildRequires: libstdc++-devel >= 6:4.7 | |
30 | BuildRequires: pkgconfig | |
31 | BuildRequires: pystring-devel | |
32 | BuildRequires: python3-devel | |
33 | BuildRequires: python3-pybind11 >= 2.6.1 | |
34 | %if %{with doc} | |
35 | BuildRequires: python3-recommonmark | |
36 | BuildRequires: python3-testresources | |
37 | BuildRequires: sphinx-pdg >= 1.1 | |
38 | %endif | |
39 | BuildRequires: tinyxml-devel >= 2.6.1 | |
40 | BuildRequires: yaml-cpp-devel >= 0.3.0 | |
41 | %if %{with opengl} | |
42 | BuildRequires: OpenGL-devel | |
43 | BuildRequires: OpenGL-glut-devel | |
44 | BuildRequires: glew-devel >= 1.5.1 | |
45 | %endif | |
46 | %if %{with oiio} | |
47 | BuildRequires: OpenImageIO-devel | |
48 | BuildRequires: lcms2-devel >= 2.1 | |
49 | %endif | |
50 | BuildRequires: rpmbuild(macros) >= 1.742 | |
51 | Requires: tinyxml >= 2.6.1 | |
52 | Requires: yaml-cpp >= 0.3.0 | |
53 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
54 | ||
55 | %description | |
56 | OpenColorIO (OCIO) is a complete color management solution geared | |
57 | towards motion picture production with an emphasis on visual effects | |
58 | and computer animation. OCIO provides a straightforward and consistent | |
59 | user experience across all supporting applications while allowing for | |
60 | sophisticated back-end configuration options suitable for high-end | |
61 | production usage. OCIO is compatible with the Academy Color Encoding | |
62 | Specification (ACES) and is LUT-format agnostic, supporting many | |
63 | popular formats. | |
64 | ||
65 | %description -l pl.UTF-8 | |
66 | OpenColorIO (OCIO) to kompletne rozwiązanie zarządzania kolorami | |
67 | przeznaczone do tworzenia obrazów ruchomych, w szczególności efektów | |
68 | wizualnych i animacji komputerowej. OCIO zapewnia proste i spójne | |
69 | elementy we wszystkich współpracujących aplikacjach, pozwalając na | |
70 | wyszukane opcje konfiguracyjne backendu, nadające się do zastosowań | |
71 | produkcyjnych wysokiej jakości. OCIO jest zgodne ze specyfikacją ACES | |
72 | (Academy Color Encoding Specification) i jest niezależne od formatu | |
73 | LUT dzięki obsłudze wielu popularnych formatów. | |
74 | ||
75 | %package convert | |
76 | Summary: OpenColorIO convert tool | |
77 | Summary(pl.UTF-8): Narzędzie OpenColorIO do konwersji | |
78 | Group: Applications/Graphics | |
79 | Requires: %{name} = %{version}-%{release} | |
80 | Requires: lcms2 >= 2.1 | |
81 | ||
82 | %description convert | |
83 | OpenColorIO convert tool. | |
84 | ||
85 | %description convert -l pl.UTF-8 | |
86 | Narzędzie OpenColorIO do konwersji. | |
87 | ||
88 | %package display | |
89 | Summary: OpenColorIO viewer based on OpenGL | |
90 | Summary(pl.UTF-8): Przeglądarka OpenColorIO oparta na OpenGL-u | |
91 | Group: X11/Applications/Graphics | |
92 | Requires: %{name} = %{version}-%{release} | |
93 | ||
94 | %description display | |
95 | OpenColorIO viewer based on OpenGL. | |
96 | ||
97 | %description display -l pl.UTF-8 | |
98 | Przeglądarka OpenColorIO oparta na OpenGL-u. | |
99 | ||
100 | %package devel | |
101 | Summary: Header files for OpenColorIO library | |
102 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki OpenColorIO | |
103 | Group: Development/Libraries | |
104 | Requires: %{name} = %{version}-%{release} | |
105 | Requires: libstdc++-devel | |
106 | ||
107 | %description devel | |
108 | Header files for OpenColorIO library. | |
109 | ||
110 | %description devel -l pl.UTF-8 | |
111 | Pliki nagłówkowe biblioteki OpenColorIO. | |
112 | ||
113 | %package -n java-OpenColorIO | |
114 | Summary: Java binding for OpenColorIO library | |
115 | Summary(pl.UTF-8): Wiązanie Javy do biblioteki OpenColorIO | |
116 | Group: Libraries/Java | |
117 | Requires: %{name} = %{version}-%{release} | |
118 | ||
119 | %description -n java-OpenColorIO | |
120 | Java binding for OpenColorIO library. | |
121 | ||
122 | %description -n java-OpenColorIO -l pl.UTF-8 | |
123 | Wiązanie Javy do biblioteki OpenColorIO. | |
124 | ||
125 | %package -n python3-OpenColorIO | |
126 | Summary: Python binding for OpenColorIO library | |
127 | Summary(pl.UTF-8): Wiązanie Pythona do biblioteki OpenColorIO | |
128 | Group: Libraries/Python | |
129 | Requires: %{name} = %{version}-%{release} | |
130 | ||
131 | %description -n python3-OpenColorIO | |
132 | Python binding for OpenColorIO library. | |
133 | ||
134 | %description -n python3-OpenColorIO -l pl.UTF-8 | |
135 | Wiązanie Pythona do biblioteki OpenColorIO. | |
136 | ||
137 | %prep | |
138 | %setup -q | |
139 | ||
140 | %build | |
141 | # required for cmake to find JNI headers/libs when lib64 is in use | |
142 | %{?with_java:export JAVA_HOME=%{_jvmlibdir}/java} | |
143 | ||
144 | install -d build | |
145 | cd build | |
146 | %cmake .. \ | |
147 | -DCMAKE_CONFIGURATION_TYPES=PLD \ | |
148 | -DCMAKE_CXX_STANDARD=14 \ | |
149 | %cmake_on_off doc OCIO_BUILD_DOCS \ | |
150 | %cmake_on_off java OCIO_BUILD_JAVA \ | |
151 | %{!?with_oiio:-DDISABLE_OIIO=ON} \ | |
152 | %{!?with_sse2:-DOCIO_USE_SSE=OFF} \ | |
153 | -DUSE_EXTERNAL_LCMS=ON \ | |
154 | -DUSE_EXTERNAL_TINYXML=ON \ | |
155 | -DUSE_EXTERNAL_YAML=ON | |
156 | ||
157 | %{__make} | |
158 | ||
159 | %install | |
160 | rm -rf $RPM_BUILD_ROOT | |
161 | ||
162 | %{__make} -C build install \ | |
163 | DESTDIR=$RPM_BUILD_ROOT | |
164 | ||
165 | # not needed when installing to /usr | |
166 | %{__rm} $RPM_BUILD_ROOT%{_datadir}/ocio/setup_ocio.sh | |
167 | ||
168 | %clean | |
169 | rm -rf $RPM_BUILD_ROOT | |
170 | ||
171 | %post -p /sbin/ldconfig | |
172 | %postun -p /sbin/ldconfig | |
173 | ||
174 | %post -n java-OpenColorIO -p /sbin/ldconfig | |
175 | %postun -n java-OpenColorIO -p /sbin/ldconfig | |
176 | ||
177 | %post -n python3-OpenColorIO -p /sbin/ldconfig | |
178 | %postun -n python3-OpenColorIO -p /sbin/ldconfig | |
179 | ||
180 | %files | |
181 | %defattr(644,root,root,755) | |
182 | %doc CHANGELOG.md LICENSE README.md | |
183 | %attr(755,root,root) %{_bindir}/ociobakelut | |
184 | %attr(755,root,root) %{_bindir}/ociocheck | |
185 | %attr(755,root,root) %{_bindir}/ociochecklut | |
186 | %attr(755,root,root) %{_bindir}/ociomakeclf | |
187 | %attr(755,root,root) %{_bindir}/ociowrite | |
188 | %attr(755,root,root) %{_libdir}/libOpenColorIO.so.*.*.* | |
189 | %attr(755,root,root) %ghost %{_libdir}/libOpenColorIO.so.2.1 | |
190 | ||
191 | %if %{with oiio} | |
192 | %files convert | |
193 | %defattr(644,root,root,755) | |
194 | %attr(755,root,root) %{_bindir}/ocioconvert | |
195 | %attr(755,root,root) %{_bindir}/ociolutimage | |
196 | %attr(755,root,root) %{_bindir}/ocioperf | |
197 | %endif | |
198 | ||
199 | %if %{with oiio} && %{with opengl} | |
200 | %files display | |
201 | %defattr(644,root,root,755) | |
202 | %attr(755,root,root) %{_bindir}/ociodisplay | |
203 | %endif | |
204 | ||
205 | %files devel | |
206 | %defattr(644,root,root,755) | |
207 | %{?with_doc:%doc build/docs/build-html/*} | |
208 | %attr(755,root,root) %{_libdir}/libOpenColorIO.so | |
209 | %{_libdir}/libOpenColorIOoglapphelpers.a | |
210 | %{?with_oiio:%{_libdir}/libOpenColorIOoiiohelpers.a} | |
211 | %{_includedir}/OpenColorIO | |
212 | %{_pkgconfigdir}/OpenColorIO.pc | |
213 | %{_libdir}/cmake/OpenColorIO | |
214 | ||
215 | %if %{with java} | |
216 | %files -n java-OpenColorIO | |
217 | %defattr(644,root,root,755) | |
218 | %attr(755,root,root) %{_libdir}/libOpenColorIO-JNI.so.*.*.* | |
219 | %attr(755,root,root) %ghost %{_libdir}/libOpenColorIO-JNI.so.1 | |
220 | %attr(755,root,root) %{_libdir}/libOpenColorIO-JNI.so | |
221 | %dir %{_datadir}/ocio | |
222 | %{_datadir}/ocio/OpenColorIO-%{version}.jar | |
223 | %endif | |
224 | ||
225 | %files -n python3-OpenColorIO | |
226 | %defattr(644,root,root,755) | |
227 | %attr(755,root,root) %{py3_sitedir}/PyOpenColorIO.so |