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