]> git.pld-linux.org Git - packages/OpenColorIO.git/blob - OpenColorIO.spec
- (try to) help cmake to find jdk when lib64 is used
[packages/OpenColorIO.git] / OpenColorIO.spec
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_without  java    # JNI glue
9 %bcond_without  docs    # 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:        1.0.6
19 Release:        1
20 License:        BSD
21 Group:          Libraries
22 Source0:        https://github.com/imageworks/OpenColorIO/tarball/v%{version}#/%{name}-%{version}.tar.gz
23 # Source0-md5:  7bd5521d8671be9f9f92339b32497908
24 Patch0:         %{name}-system-libs.patch
25 Patch1:         %{name}-java.patch
26 URL:            http://opencolorio.org/
27 # g++ with tr1 support or...
28 #BuildRequires: boost-devel >= 1.34
29 BuildRequires:  cmake >= 2.8
30 %{?with_java:BuildRequires:     jdk}
31 BuildRequires:  libstdc++-devel
32 BuildRequires:  pkgconfig
33 BuildRequires:  python-devel
34 %{?with_docs:BuildRequires:     sphinx-pdg >= 1.1}
35 BuildRequires:  tinyxml-devel >= 2.6.1
36 BuildRequires:  yaml-cpp-devel >= 0.2.6
37 %if %{with opengl}
38 BuildRequires:  OpenGL-devel
39 BuildRequires:  OpenGL-glut-devel
40 BuildRequires:  glew-devel >= 1.5.1
41 %endif
42 %if %{with oiio}
43 BuildRequires:  OpenImageIO-devel
44 BuildRequires:  lcms2-devel >= 2.1
45 %endif
46 Requires:       tinyxml >= 2.6.1
47 Requires:       yaml-cpp >= 0.2.6
48 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
49
50 %description
51 OpenColorIO (OCIO) is a complete color management solution geared
52 towards motion picture production with an emphasis on visual effects
53 and computer animation. OCIO provides a straightforward and consistent
54 user experience across all supporting applications while allowing for
55 sophisticated back-end configuration options suitable for high-end
56 production usage. OCIO is compatible with the Academy Color Encoding
57 Specification (ACES) and is LUT-format agnostic, supporting many
58 popular formats.
59
60 %description -l pl.UTF-8
61 OpenColorIO (OCIO) to kompletne rozwiązanie zarządzania kolorami
62 przeznaczone do tworzenia obrazów ruchomych, w szczególności efektów
63 wizualnych i animacji komputerowej. OCIO zapewnia proste i spójne
64 elementy we wszystkich współpracujących aplikacjach, pozwalając na
65 wyszukane opcje konfiguracyjne backendu, nadające się do zastosowań
66 produkcyjnych wysokiej jakości. OCIO jest zgodne ze specyfikacją ACES
67 (Academy Color Encoding Specification) i jest niezależne od formatu
68 LUT dzięki obsłudze wielu popularnych formatów.
69
70 %package convert
71 Summary:        OpenColorIO convert tool
72 Summary(pl.UTF-8):      Narzędzie OpenColorIO do konwersji
73 Group:          Applications/Graphics
74 Requires:       %{name} = %{version}-%{release}
75
76 %description convert
77 OpenColorIO convert tool.
78
79 %description convert -l pl.UTF-8
80 Narzędzie OpenColorIO do konwersji.
81
82 %package display
83 Summary:        OpenColorIO viewer based on OpenGL
84 Summary(pl.UTF-8):      Przeglądarka OpenColorIO oparta na OpenGL-u
85 Group:          X11/Applications/Graphics
86 Requires:       %{name} = %{version}-%{release}
87
88 %description display
89 OpenColorIO viewer based on OpenGL.
90
91 %description display -l pl.UTF-8
92 Przeglądarka OpenColorIO oparta na OpenGL-u.
93
94 %package devel
95 Summary:        Header files for OpenColorIO library
96 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki OpenColorIO
97 Group:          Development/Libraries
98 Requires:       %{name} = %{version}-%{release}
99 Requires:       libstdc++-devel
100
101 %description devel
102 Header files for OpenColorIO library.
103
104 %description devel -l pl.UTF-8
105 Pliki nagłówkowe biblioteki OpenColorIO.
106
107 %package static
108 Summary:        Static OpenColorIO library
109 Summary(pl.UTF-8):      Statyczna biblioteka OpenColorIO
110 Group:          Development/Libraries
111 Requires:       %{name}-devel = %{version}-%{release}
112
113 %description static
114 Static OpenColorIO library.
115
116 %description static -l pl.UTF-8
117 Statyczna biblioteka OpenColorIO.
118
119 %package -n java-OpenColorIO
120 Summary:        Java binding for OpenColorIO library
121 Summary(pl.UTF-8):      Wiązanie Javy do biblioteki OpenColorIO
122 Group:          Libraries/Java
123 Requires:       %{name} = %{version}-%{release}
124
125 %description -n java-OpenColorIO
126 Java binding for OpenColorIO library.
127
128 %description -n java-OpenColorIO -l pl.UTF-8
129 Wiązanie Javy do biblioteki OpenColorIO.
130
131 %package -n python-OpenColorIO
132 Summary:        Python binding for OpenColorIO library
133 Summary(pl.UTF-8):      Wiązanie Pythona do biblioteki OpenColorIO
134 Group:          Libraries/Python
135 Requires:       %{name} = %{version}-%{release}
136
137 %description -n python-OpenColorIO
138 Python binding for OpenColorIO library.
139
140 %description -n python-OpenColorIO -l pl.UTF-8
141 Wiązanie Pythona do biblioteki OpenColorIO.
142
143 %package -n python-OpenColorIO-devel
144 Summary:        Header file for PyOpenColorIO API
145 Summary(pl.UTF-8):      Plik nagłówkowy API PyOpenColorIO
146 Group:          Development/Libraries
147 Requires:       %{name}-devel = %{version}-%{release}
148 Requires:       python-OpenColorIO = %{version}-%{release}
149
150 %description -n python-OpenColorIO-devel
151 Header file for PyOpenColorIO API.
152
153 %description -n python-OpenColorIO-devel -l pl.UTF-8
154 Plik nagłówkowy API PyOpenColorIO.
155
156 %prep
157 %setup -q -n imageworks-OpenColorIO-a16d9ac
158 %patch0 -p1
159 %patch1 -p1
160
161 %build
162 %{?with_java:export JAVA_HOME=%{_jvmlibdir}/java}
163
164 install -d build
165 cd build
166 %cmake .. \
167         -DOCIO_BUILD_DOCS=ON \
168 %if %{with java}
169         -DOCIO_BUILD_JNIGLUE=ON \
170         -DOCIO_STATIC_JNIGLUE=OFF \
171 %endif
172         %{!?with_sse2:-DOCIO_USE_SSE=OFF} \
173         -DPYTHON_INCLUDE_LIB_PREFIX=ON
174
175 %{__make}
176
177 %install
178 rm -rf $RPM_BUILD_ROOT
179
180 %{__make} -C build install \
181         DESTDIR=$RPM_BUILD_ROOT
182
183 # we use PYTHON_INCLUDE_LIB_PREFIX=ON so library is useful as C++ API
184 # but allow it to be loaded without lib prefix
185 ln -sf $(basename $RPM_BUILD_ROOT%{_libdir}/libPyOpenColorIO.so.*.*.*) $RPM_BUILD_ROOT%{_libdir}/PyOpenColorIO.so
186
187 # not needed when installing to /usr
188 %{__rm} $RPM_BUILD_ROOT%{_datadir}/ocio/setup_ocio.sh
189 # packaged as %doc
190 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/OpenColorIO
191
192 %clean
193 rm -rf $RPM_BUILD_ROOT
194
195 %post   -p /sbin/ldconfig
196 %postun -p /sbin/ldconfig
197
198 %post   -n java-OpenColorIO -p /sbin/ldconfig
199 %postun -n java-OpenColorIO -p /sbin/ldconfig
200
201 %post   -n python-OpenColorIO -p /sbin/ldconfig
202 %postun -n python-OpenColorIO -p /sbin/ldconfig
203
204 %files
205 %defattr(644,root,root,755)
206 %doc ChangeLog LICENSE README
207 %attr(755,root,root) %{_bindir}/ociobakelut
208 %attr(755,root,root) %{_bindir}/ociocheck
209 %attr(755,root,root) %{_libdir}/libOpenColorIO.so.*.*.*
210 %attr(755,root,root) %ghost %{_libdir}/libOpenColorIO.so.1
211
212 %if %{with oiio}
213 %files convert
214 %defattr(644,root,root,755)
215 %attr(755,root,root) %{_bindir}/ocioconvert
216 %endif
217
218 %if %{with oiio} && %{with opengl}
219 %files display
220 %defattr(644,root,root,755)
221 %attr(755,root,root) %{_bindir}/ociodisplay
222 %endif
223
224 %files devel
225 %defattr(644,root,root,755)
226 %doc build/docs/build-html/*
227 %attr(755,root,root) %{_libdir}/libOpenColorIO.so
228 %{_includedir}/OpenColorIO
229 %{_pkgconfigdir}/OpenColorIO.pc
230
231 %files static
232 %defattr(644,root,root,755)
233 %{_libdir}/libOpenColorIO.a
234
235 %if %{with java}
236 %files -n java-OpenColorIO
237 %defattr(644,root,root,755)
238 %attr(755,root,root) %{_libdir}/libOpenColorIO-JNI.so.*.*.*
239 %attr(755,root,root) %ghost %{_libdir}/libOpenColorIO-JNI.so.1
240 %attr(755,root,root) %{_libdir}/libOpenColorIO-JNI.so
241 %dir %{_datadir}/ocio
242 %{_datadir}/ocio/OpenColorIO-1.0.6.jar
243 %endif
244
245 %files -n python-OpenColorIO
246 %defattr(644,root,root,755)
247 %attr(755,root,root) %{_libdir}/libPyOpenColorIO.so.*.*.*
248 %attr(755,root,root) %ghost %{_libdir}/libPyOpenColorIO.so.1
249 %attr(755,root,root) %{_libdir}/PyOpenColorIO.so
250
251 %files -n python-OpenColorIO-devel
252 %defattr(644,root,root,755)
253 %attr(755,root,root) %{_libdir}/libPyOpenColorIO.so
254 %{_includedir}/PyOpenColorIO
This page took 0.075368 seconds and 4 git commands to generate.