]>
Commit | Line | Data |
---|---|---|
e7f6dce0 JB |
1 | # |
2 | # Conditional build: | |
9fdf14c7 | 3 | %bcond_without qt5 # do not build Qt5 version |
a0b16f30 | 4 | %bcond_without zeitgeist # enable zeitgeist (via libqzeitgeist) supoort |
a065ff0f | 5 | |
e7f6dce0 JB |
6 | %define qt4_ver 4.8.1 |
7 | %define qt5_ver 5.3.1 | |
2c13f770 | 8 | |
85decc24 JB |
9 | Summary: Phonon: multimedia API for Qt4/KDE4 |
10 | Summary(pl.UTF-8): Phonon - biblioteka multimedialna dla Qt4/KDE4 | |
87d58a79 | 11 | Name: phonon |
22a89b10 | 12 | Version: 4.8.3 |
27b5d31e | 13 | Release: 6 |
85decc24 | 14 | License: LGPL v2.1 or LGPL v3 |
87d58a79 | 15 | Group: X11/Libraries |
22a89b10 AM |
16 | Source0: ftp://ftp.kde.org/pub/kde/stable/phonon/%{version}/src/%{name}-%{version}.tar.xz |
17 | # Source0-md5: 88bb9867261803eed61ff53a7c026338 | |
2067b452 | 18 | Patch0: %{name}-pkg.patch |
0c3f61e3 | 19 | Patch1: x32.patch |
174bb316 | 20 | URL: http://phonon.kde.org/ |
a065ff0f | 21 | %if %{with qt5} |
4976fa0a | 22 | BuildRequires: Qt5Core-devel >= %{qt5_ver} |
e7f6dce0 JB |
23 | BuildRequires: Qt5DBus-devel >= %{qt5_ver} |
24 | BuildRequires: Qt5Declarative-devel >= %{qt5_ver} | |
25 | BuildRequires: Qt5Designer-devel >= %{qt5_ver} | |
26 | BuildRequires: Qt5Gui-devel >= %{qt5_ver} | |
27 | BuildRequires: Qt5OpenGL-devel >= %{qt5_ver} | |
28 | BuildRequires: Qt5Qml-devel >= %{qt5_ver} | |
29 | BuildRequires: Qt5Widgets-devel >= %{qt5_ver} | |
30 | BuildRequires: qt5-build >= %{qt5_ver} | |
31 | BuildRequires: qt5-qmake >= %{qt5_ver} | |
a065ff0f | 32 | %endif |
e7f6dce0 JB |
33 | BuildRequires: QtCore-devel >= %{qt4_ver} |
34 | BuildRequires: QtDBus-devel >= %{qt4_ver} | |
35 | BuildRequires: QtDeclarative-devel >= %{qt4_ver} | |
36 | BuildRequires: QtGui-devel >= %{qt4_ver} | |
37 | BuildRequires: QtNetwork-devel >= %{qt4_ver} | |
38 | BuildRequires: QtOpenGL-devel >= %{qt4_ver} | |
39 | BuildRequires: QtSql-devel >= %{qt4_ver} | |
40 | BuildRequires: QtTest-devel >= %{qt4_ver} | |
9fb1cf8e | 41 | BuildRequires: cmake >= 2.8.0 |
ac805375 | 42 | BuildRequires: glib2-devel >= 2.0 |
9fdf14c7 | 43 | %{?with_zeitgeist:BuildRequires: libqzeitgeist-devel >= 0.8} |
54fe0ccc | 44 | BuildRequires: pkgconfig |
63d78ae0 | 45 | BuildRequires: pulseaudio-devel >= 0.9.21 |
e7f6dce0 JB |
46 | BuildRequires: qt4-build >= %{qt4_ver} |
47 | BuildRequires: qt4-qmake >= %{qt4_ver} | |
85decc24 | 48 | BuildRequires: rpmbuild(macros) >= 1.603 |
e7f6dce0 JB |
49 | Requires: QtCore >= %{qt4_ver} |
50 | Requires: QtDBus >= %{qt4_ver} | |
51 | Requires: QtGui >= %{qt4_ver} | |
52 | Requires: QtOpenGL >= %{qt4_ver} | |
8da7cae4 | 53 | Requires: kde-common-dirs >= 0.5 |
9fdf14c7 | 54 | %{?with_zeitgeist:Requires: libqzeitgeist >= 0.8} |
90cdc944 | 55 | Requires: qt4-phonon-backend |
87d58a79 | 56 | Provides: qt4-phonon |
926de682 | 57 | Obsoletes: qt4-phonon |
87d58a79 | 58 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
59 | ||
60 | %description | |
90fd11ae ER |
61 | Phonon is the multimedia API for Qt4/KDE4. |
62 | ||
bbcd3cdf ER |
63 | Phonon was originally created to allow KDE 4 to be independent of any |
64 | single multimedia framework such as GStreamer or Xine and to provide a | |
65 | stable API for KDE4's lifetime. It was done to fix problems of | |
66 | frameworks becoming unmaintained, API instability, and to create a | |
67 | simple multimedia API. | |
87d58a79 | 68 | |
69 | %description -l pl.UTF-8 | |
85decc24 JB |
70 | Phonon to biblioteka multimedialna dla Qt4/KDE4. |
71 | ||
72 | Pierwotnie powstała, aby pozwolić na niezależność KDE 4 od konkretnego | |
73 | środowiska multimedialnego, takiego jak GStreamer czy Xine, oraz | |
74 | zapewnić stabilne API na cały czas życia KDE4. Została stworzona w | |
75 | celu wyeliminowania problemów z porzucaniem bibliotek i | |
76 | niestabilnością ich API, a także w celu stworzenia prostego API | |
77 | multimedialnego. | |
87d58a79 | 78 | |
79 | %package devel | |
5095f7de | 80 | Summary: Header files for Phonon library |
926de682 | 81 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki Phonon |
5095f7de | 82 | Group: X11/Development/Libraries |
bbcd3cdf | 83 | Requires: %{name} = %{version}-%{release} |
e7f6dce0 JB |
84 | Requires: QtCore-devel >= %{qt4_ver} |
85 | Requires: QtDBus-devel >= %{qt4_ver} | |
86 | Requires: QtGui-devel >= %{qt4_ver} | |
87d58a79 | 87 | Provides: qt4-phonon-devel |
88 | Obsoletes: qt4-phonon-devel | |
89 | ||
90 | %description devel | |
96eb3964 | 91 | Header files for Phonon library. |
87d58a79 | 92 | |
93 | %description devel -l pl.UTF-8 | |
926de682 | 94 | Pliki nagłówkowe biblioteki Phonon. |
87d58a79 | 95 | |
e7f6dce0 JB |
96 | %package -n QtDeclarative-plugin-phonon |
97 | Summary: Phonon plugin for Qt4 QtDeclarative library | |
98 | Summary(pl.UTF-8): Wtyczka Phonon dla biblioteki Qt4 QtDeclarative | |
99 | Group: X11/Libraries | |
100 | Requires: %{name} = %{version}-%{release} | |
101 | Requires: QtDeclarative >= %{qt4_ver} | |
102 | ||
103 | %description -n QtDeclarative-plugin-phonon | |
104 | Phonon plugin for Qt4 QtDeclarative library. | |
105 | ||
106 | %description -n QtDeclarative-plugin-phonon -l pl.UTF-8 | |
107 | Wtyczka Phonon dla biblioteki Qt4 QtDeclarative. | |
108 | ||
a065ff0f WF |
109 | %package qt5 |
110 | Summary: Phonon: multimedia API for Qt5/KDE5 | |
111 | Summary(pl.UTF-8): Phonon - biblioteka multimedialna dla Qt5/KDE5 | |
112 | Group: X11/Libraries | |
e7f6dce0 JB |
113 | Requires: Qt5Core >= %{qt5_ver} |
114 | Requires: Qt5DBus >= %{qt5_ver} | |
115 | Requires: Qt5Gui >= %{qt5_ver} | |
116 | Requires: Qt5OpenGL >= %{qt5_ver} | |
117 | Requires: Qt5Widgets >= %{qt5_ver} | |
a065ff0f WF |
118 | Provides: qt5-phonon |
119 | Obsoletes: qt5-phonon | |
120 | ||
121 | %description qt5 | |
122 | Phonon is the multimedia API for Qt5/KDE5. | |
123 | ||
124 | Phonon was originally created to allow KDE 5 to be independent of any | |
125 | single multimedia framework such as GStreamer or Xine and to provide a | |
126 | stable API for KDE5's lifetime. It was done to fix problems of | |
127 | frameworks becoming unmaintained, API instability, and to create a | |
128 | simple multimedia API. | |
129 | ||
130 | %description qt5 -l pl.UTF-8 | |
131 | Phonon to biblioteka multimedialna dla Qt5/KDE5. | |
132 | ||
133 | Pierwotnie powstała, aby pozwolić na niezależność KDE 5 od konkretnego | |
134 | środowiska multimedialnego, takiego jak GStreamer czy Xine, oraz | |
135 | zapewnić stabilne API na cały czas życia KDE5. Została stworzona w | |
136 | celu wyeliminowania problemów z porzucaniem bibliotek i | |
137 | niestabilnością ich API, a także w celu stworzenia prostego API | |
138 | multimedialnego. | |
139 | ||
140 | %package qt5-devel | |
141 | Summary: Header files for Phonon library | |
142 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki Phonon | |
143 | Group: X11/Development/Libraries | |
144 | Requires: %{name}-qt5 = %{version}-%{release} | |
e7f6dce0 JB |
145 | Requires: Qt5Core-devel >= %{qt5_ver} |
146 | Requires: Qt5DBus-devel >= %{qt5_ver} | |
147 | Requires: Qt5Gui-devel >= %{qt5_ver} | |
a065ff0f WF |
148 | Provides: qt5-phonon-devel |
149 | Obsoletes: qt5-phonon-devel | |
150 | ||
151 | %description qt5-devel | |
152 | Header files for Phonon library. | |
153 | ||
154 | %description qt5-devel -l pl.UTF-8 | |
155 | Pliki nagłówkowe biblioteki Phonon. | |
156 | ||
e7f6dce0 JB |
157 | %package -n Qt5Declarative-plugin-phonon |
158 | Summary: Phonon plugin for Qt5 QtDeclarative library | |
159 | Summary(pl.UTF-8): Wtyczka Phonon dla biblioteki Qt5 QtDeclarative | |
160 | Group: X11/Libraries | |
161 | Requires: %{name} = %{version}-%{release} | |
162 | Requires: Qt5Declarative >= %{qt5_ver} | |
163 | ||
164 | %description -n Qt5Declarative-plugin-phonon | |
165 | Phonon plugin for Qt5 QtDeclarative library. | |
166 | ||
167 | %description -n Qt5Declarative-plugin-phonon -l pl.UTF-8 | |
168 | Wtyczka Phonon dla biblioteki Qt5 QtDeclarative. | |
169 | ||
170 | %package -n Qt5Designer-plugin-phonon | |
171 | Summary: Phonon plugin for Qt5 QtDesigner | |
172 | Summary(pl.UTF-8): Wtyczka Phonon dla Qt5 QtDesignera | |
173 | Group: X11/Libraries | |
174 | Requires: %{name} = %{version}-%{release} | |
175 | Requires: Qt5Designer >= %{qt5_ver} | |
176 | ||
177 | %description -n Qt5Designer-plugin-phonon | |
178 | Phonon plugin for Qt5 QtDesigner. | |
179 | ||
180 | %description -n Qt5Designer-plugin-phonon -l pl.UTF-8 | |
181 | Wtyczka Phonon dla Qt5 QtDesignera. | |
182 | ||
87d58a79 | 183 | %prep |
72fa65d1 | 184 | %setup -q |
2067b452 | 185 | %patch0 -p1 |
4c2c985a | 186 | %patch1 -p1 |
87d58a79 | 187 | |
188 | %build | |
189 | install -d build | |
190 | cd build | |
ac805375 JB |
191 | # disable designer plugin - currently packaged in QtDesigner package |
192 | %cmake .. \ | |
e7f6dce0 | 193 | -DPHONON_BUILD_DECLARATIVE_PLUGIN=ON \ |
ac805375 | 194 | -DPHONON_BUILD_DESIGNER_PLUGIN=OFF |
a065ff0f | 195 | %{__make} |
87d58a79 | 196 | |
a065ff0f WF |
197 | cd .. |
198 | %if %{with qt5} | |
199 | install -d build5 | |
200 | cd build5 | |
201 | %cmake .. \ | |
e7f6dce0 JB |
202 | -DPHONON_BUILD_DECLARATIVE_PLUGIN=ON \ |
203 | -DPHONON_BUILD_DESIGNER_PLUGIN=ON \ | |
a065ff0f WF |
204 | -DPHONON_BUILD_PHONON4QT5=ON \ |
205 | -DPHONON_INSTALL_QT_EXTENSIONS_INTO_SYSTEM_QT=ON | |
87d58a79 | 206 | %{__make} |
a065ff0f | 207 | %endif |
87d58a79 | 208 | |
209 | %install | |
210 | rm -rf $RPM_BUILD_ROOT | |
211 | ||
212 | %{__make} -C build install \ | |
213 | DESTDIR=$RPM_BUILD_ROOT | |
214 | ||
90fd11ae | 215 | install -d $RPM_BUILD_ROOT%{_includedir}/qt4 |
e144db61 | 216 | install -d $RPM_BUILD_ROOT%{_libdir}/kde4/plugins/phonon_backend |
5d50300b | 217 | install -d $RPM_BUILD_ROOT%{_datadir}/kde4/services/phononbackends |
90fd11ae ER |
218 | ln -s ../phonon $RPM_BUILD_ROOT%{_includedir}/qt4/phonon |
219 | ln -s ../KDE/Phonon $RPM_BUILD_ROOT%{_includedir}/phonon/Phonon | |
22eeef83 | 220 | |
a065ff0f WF |
221 | %if %{with qt5} |
222 | %{__make} -C build5 install \ | |
223 | DESTDIR=$RPM_BUILD_ROOT | |
1e88fd38 JB |
224 | |
225 | install -d $RPM_BUILD_ROOT%{_libdir}/qt5/plugins/phonon4qt5_backend | |
a065ff0f WF |
226 | %endif |
227 | ||
87d58a79 | 228 | %clean |
229 | rm -rf $RPM_BUILD_ROOT | |
230 | ||
231 | %post -p /sbin/ldconfig | |
232 | %postun -p /sbin/ldconfig | |
233 | ||
e7f6dce0 JB |
234 | %post qt5 -p /sbin/ldconfig |
235 | %postun qt5 -p /sbin/ldconfig | |
a065ff0f | 236 | |
87d58a79 | 237 | %files |
238 | %defattr(644,root,root,755) | |
239 | %attr(755,root,root) %{_libdir}/libphonon.so.*.*.* | |
bbcd3cdf | 240 | %attr(755,root,root) %ghost %{_libdir}/libphonon.so.4 |
87d58a79 | 241 | %attr(755,root,root) %{_libdir}/libphononexperimental.so.*.*.* |
bbcd3cdf | 242 | %attr(755,root,root) %ghost %{_libdir}/libphononexperimental.so.4 |
87d58a79 | 243 | %{_datadir}/dbus-1/interfaces/org.kde.Phonon.AudioOutput.xml |
e144db61 | 244 | %dir %{_libdir}/kde4/plugins/phonon_backend |
5d50300b | 245 | %dir %{_datadir}/kde4/services/phononbackends |
2f158ee4 | 246 | |
87d58a79 | 247 | %files devel |
248 | %defattr(644,root,root,755) | |
85decc24 JB |
249 | %attr(755,root,root) %{_libdir}/libphonon.so |
250 | %attr(755,root,root) %{_libdir}/libphononexperimental.so | |
87d58a79 | 251 | %{_includedir}/phonon |
79b366d8 | 252 | %dir %{_includedir}/KDE |
87d58a79 | 253 | %{_includedir}/KDE/Phonon |
22eeef83 | 254 | %{_includedir}/qt4/phonon |
87d58a79 | 255 | %{_pkgconfigdir}/phonon.pc |
ac805375 | 256 | %{_libdir}/cmake/phonon |
03bc6914 | 257 | %dir %{_datadir}/phonon |
61643aa7 | 258 | %{_datadir}/phonon/buildsystem |
e09d576b | 259 | %{_datadir}/qt4/mkspecs/modules/qt_phonon.pri |
a065ff0f | 260 | |
e7f6dce0 JB |
261 | %files -n QtDeclarative-plugin-phonon |
262 | %defattr(644,root,root,755) | |
263 | %dir %{_libdir}/qt4/imports/Phonon | |
264 | %attr(755,root,root) %{_libdir}/qt4/imports/Phonon/libphononqmlplugin.so | |
265 | %{_libdir}/qt4/imports/Phonon/VideoPlayer.qml | |
266 | %{_libdir}/qt4/imports/Phonon/qmldir | |
267 | ||
a065ff0f WF |
268 | %if %{with qt5} |
269 | %files qt5 | |
270 | %defattr(644,root,root,755) | |
271 | %attr(755,root,root) %ghost %{_libdir}/libphonon4qt5.so.4 | |
846b6e56 | 272 | %attr(755,root,root) %{_libdir}/libphonon4qt5.so.*.*.* |
a065ff0f | 273 | %attr(755,root,root) %ghost %{_libdir}/libphonon4qt5experimental.so.4 |
846b6e56 | 274 | %attr(755,root,root) %{_libdir}/libphonon4qt5experimental.so.*.*.* |
1e88fd38 | 275 | %dir %{_libdir}/qt5/plugins/phonon4qt5_backend |
a065ff0f WF |
276 | %{_datadir}/dbus-1/interfaces/org.kde.Phonon4Qt5.AudioOutput.xml |
277 | %{_datadir}/phonon4qt5 | |
278 | ||
279 | %files qt5-devel | |
280 | %defattr(644,root,root,755) | |
a065ff0f WF |
281 | %attr(755,root,root) %{_libdir}/libphonon4qt5.so |
282 | %attr(755,root,root) %{_libdir}/libphonon4qt5experimental.so | |
e7f6dce0 | 283 | %{_includedir}/phonon4qt5 |
a065ff0f | 284 | %{_pkgconfigdir}/phonon4qt5.pc |
e7f6dce0 | 285 | %{_libdir}/cmake/phonon4qt5 |
a065ff0f | 286 | %{_libdir}/qt5/mkspecs/modules/qt_phonon4qt5.pri |
e7f6dce0 JB |
287 | |
288 | %files -n Qt5Declarative-plugin-phonon | |
289 | %defattr(644,root,root,755) | |
54a9adc2 | 290 | %dir %{_libdir}/qt5/imports/Phonon |
e7f6dce0 JB |
291 | %attr(755,root,root) %{_libdir}/qt5/imports/Phonon/libphononqmlplugin.so |
292 | %{_libdir}/qt5/imports/Phonon/VideoPlayer.qml | |
293 | %{_libdir}/qt5/imports/Phonon/qmldir | |
294 | ||
295 | %files -n Qt5Designer-plugin-phonon | |
296 | %defattr(644,root,root,755) | |
297 | %attr(755,root,root) %{_libdir}/qt5/plugins/designer/libphononwidgets.so | |
a065ff0f | 298 | %endif |