1 |
ennael |
78010 |
|
2 |
|
|
%define name xbmc |
3 |
anssi |
217508 |
%define branch_release Eden |
4 |
ennael |
78010 |
%define extra_feature pvr |
5 |
anssi |
217508 |
%define version 11.0 |
6 |
anssi |
93516 |
%define snap 0 |
7 |
anssi |
226110 |
%define pre 0 |
8 |
fwang |
277861 |
%define rel 4 |
9 |
ennael |
78010 |
|
10 |
anssi |
93516 |
%if %snap |
11 |
ennael |
78010 |
%define branch %branch_release.%extra_feature |
12 |
|
|
%else |
13 |
|
|
%define branch %extra_feature |
14 |
|
|
%endif |
15 |
|
|
|
16 |
|
|
%define branchr %([ "%branch" ] && echo .%branch | tr - _) |
17 |
|
|
|
18 |
anssi |
227542 |
# build with internal ffmpeg, disabled by default (--with internal_ffmpeg) |
19 |
|
|
%bcond_with internal_ffmpeg |
20 |
|
|
|
21 |
|
|
%if %with internal_ffmpeg |
22 |
|
|
# issue with 11.0 internal ffmpeg, haven't bothered with patching as it is |
23 |
|
|
# not used in the default build anyway |
24 |
|
|
%define Werror_cflags %nil |
25 |
|
|
%endif |
26 |
|
|
|
27 |
ennael |
78010 |
Summary: XBMC Media Center - media player and home entertainment system |
28 |
|
|
Name: %{name} |
29 |
|
|
Version: %{version} |
30 |
anssi |
93516 |
%if %snap |
31 |
anssi |
217508 |
Release: %mkrel 0.git%snap%branchr.%rel |
32 |
anssi |
93516 |
Source: %{name}-%branch_release-%snap.tar.xz |
33 |
ennael |
78010 |
%else |
34 |
anssi |
217508 |
%if %pre |
35 |
|
|
Release: %mkrel 0.%pre%branchr.%rel |
36 |
|
|
Source: %{name}-%{version}-%{branch_release}_%{pre}.tar.gz |
37 |
|
|
%else |
38 |
ennael |
78010 |
Release: %mkrel 1.%branch.%rel |
39 |
|
|
Source: %{name}-%{version}.tar.gz |
40 |
|
|
%endif |
41 |
anssi |
217508 |
%endif |
42 |
ennael |
78010 |
URL: http://xbmc.org/ |
43 |
|
|
|
44 |
|
|
# bring snapshot up-to-date with pvr branch |
45 |
anssi |
217508 |
# https://github.com/opdenkamp/xbmc |
46 |
anssi |
227542 |
# git diff 11.0-Eden-r2..11.0-Eden-pvr |
47 |
|
|
Patch0: xbmc-Eden-pvr-11.0.patch |
48 |
ennael |
78010 |
|
49 |
anssi |
269300 |
# Fix wiiremote eventclient build: |
50 |
|
|
Patch1: xbmc-wiiremote-missing-include.patch |
51 |
|
|
|
52 |
|
|
# Backports to fix build with FFmpeg |
53 |
|
|
Patch101: 0101-Update-ffmpeg-to-n0.10.2-f139838d6473c7b5152178f602c.patch |
54 |
|
|
Patch102: 0102-Update-patches.patch |
55 |
|
|
Patch103: 0103-Drop-neon-patch-that-doesn-t-apply-anymore.patch |
56 |
|
|
Patch104: 0104-Drop-patch-for-win32-build.patch |
57 |
|
|
Patch105: 0105-Drop-patch-for-cdxa-probe-it-causes-missdetections-o.patch |
58 |
|
|
Patch106: 0106-Drop-now-merged-or-redundant-patches.patch |
59 |
|
|
Patch107: 0107-replace-depreciated-av_open_input_stream-file-with-n.patch |
60 |
|
|
Patch108: 0108-replace-depreciated-ByteIOContext-with-AVIOContext.patch |
61 |
|
|
Patch109: 0109-replace-depreciated-AVMetadata-Tag-with-AVDictionary.patch |
62 |
|
|
Patch110: 0110-Don-t-listen-to-depreciated-return-value-of-av_read_.patch |
63 |
|
|
Patch111: 0111-Don-t-use-depreciated-avcodec_thread_init.patch |
64 |
|
|
Patch112: 0112-Replace-depreciated-av_find_stream_info-with-avforma.patch |
65 |
|
|
Patch113: 0113-Replace-more-depreciated-ffmpeg-functions.patch |
66 |
|
|
Patch114: 0114-Drop-support-for-ffmpeg-version-older-than-our-built.patch |
67 |
|
|
Patch115: 0115-Replace-deprecated-is_streamed-with-new-seekable-fla.patch |
68 |
|
|
Patch116: 0116-Remove-old-code-depending-on-deprecated-file_size.patch |
69 |
|
|
Patch117: 0117-changed-replace-old-libavfilter-integration-with-nul.patch |
70 |
|
|
Patch118: 0118-changed-replace-old-swscale-pixel-format-conversion-.patch |
71 |
|
|
Patch119: 0119-Drop-url_set_interrupt_cb-usage-which-was-removed-in.patch |
72 |
|
|
Patch120: 0120-Do-not-map-url_fdopen-as-it-is-deprecated-and-gone-i.patch |
73 |
|
|
Patch121: 0121-Replace-av_write_header-by-avformat_write_header.patch |
74 |
|
|
Patch122: 0122-Remove-av_set_parameters.patch |
75 |
|
|
Patch123: 0123-Replace-av_metadata_-get-set2-by-av_dict_-get-set.patch |
76 |
|
|
Patch124: 0124-Merge-av_close_input_-file-stream-into-avformat_clos.patch |
77 |
|
|
Patch125: 0125-Replace-init_put_byte-by-avio_alloc_context.patch |
78 |
|
|
Patch126: 0126-Replace-dump_format-by-av_dump_format.patch |
79 |
|
|
Patch127: 0127-Replace-url_-functions-by-their-avio_-counterparts.patch |
80 |
|
|
Patch128: 0128-Remove-av_alloc_put_byte-and-replace-its-occurences-.patch |
81 |
|
|
Patch129: 0129-Include-libavfilter-avcodec.h-for-av_vsrc_buffer_add.patch |
82 |
|
|
Patch130: 0130-Remove-assignment-to-stream_copy-which-is-never-read.patch |
83 |
|
|
Patch131: 0131-Do-not-set-AVFrame.age.patch |
84 |
|
|
Patch132: 0132-Use-av_opt_set-instead-of-av_set_string3-and-drop-su.patch |
85 |
|
|
Patch133: 0133-Replace-deprecated-av_get_bits_per_sample_fmt-by-av_.patch |
86 |
|
|
Patch134: 0134-Convert-to-avcodec_decode_audio4-and-drop-avcodec_de.patch |
87 |
|
|
Patch135: 0135-osx-ios-atv2-build-and-link-static-libs-for-ffmpeg-b.patch |
88 |
|
|
Patch136: 0136-changed-Only-allow-slice-based-parallel-decoding.patch |
89 |
|
|
Patch137: 0137-fixed-crash-if-audio-decoder-for-some-reason-doesn-t.patch |
90 |
|
|
Patch138: 0138-dvdplayer-previous-picture-is-invalidated-by-a-call-.patch |
91 |
|
|
Patch139: 0139-dvdplayer-Recalculate-codecname-when-we-update-based.patch |
92 |
|
|
Patch140: 0140-dvdplayer-avoid-crashing-if-ffmpeg-contains-more-tha.patch |
93 |
|
|
Patch141: 0141-Add-support-for-new-ffmpeg-10-11-api.patch |
94 |
|
|
Patch142: 0142-Bring-av_read_frame_flush-in-line-with-ffmpeg-git.patch |
95 |
|
|
Patch143: 0143-avutil-add-av_get_default_channel_layout-for-later-u.patch |
96 |
|
|
Patch144: 0144-Use-libavutil-av_get_default_channel_layout-instead-.patch |
97 |
|
|
Patch145: 0145-DllAvCodec-Remove-now-unused-private-avcodec_guess_c.patch |
98 |
|
|
|
99 |
ennael |
78010 |
# Disable updates of the default skin. Our one is the PVR version, while the |
100 |
|
|
# one in the XBMC.org addon repository would be the vanilla one (Confluence |
101 |
anssi |
217508 |
# is currently not in the addon repository, though, as of 2012-03). |
102 |
anssi |
162472 |
Patch201: xbmc-disable-confluence-update.patch |
103 |
ennael |
78010 |
|
104 |
anssi |
219397 |
# Make the MythTV PVR client buildable (submitted upstream): |
105 |
anssi |
217508 |
Patch211: 0001-fixed-undefined-symbols-in-MythTV-PVR-client.patch |
106 |
ennael |
78010 |
|
107 |
anssi |
223735 |
# Hack to workaround upgrading from our old hack... see patch header for more |
108 |
|
|
# details and an upstreaming plan. |
109 |
|
|
Patch213: 0001-hack-workaround-for-old-incompatible-PVR-addon-datab.patch |
110 |
|
|
|
111 |
ennael |
78010 |
# nosefart audio plugin and RSXS-0.9 based screensavers are GPLv2 only |
112 |
anssi |
217508 |
# several eventclients are GPLv3+ (in subpackages) |
113 |
|
|
# libhdhomerun is LGPLv3+ with an exception (always ok to link against it) |
114 |
ennael |
78010 |
# the rest is GPLv2+ |
115 |
anssi |
217508 |
# both GPLv2+ and GPLv2 are mentioned because plugins are not part of core |
116 |
anssi |
219397 |
# xbmc and therefore e.g. /usr/bin/xbmc is GPLv2+ with LGPLv3+ part |
117 |
|
|
# as allowed by a license exception |
118 |
anssi |
217508 |
License: GPLv2+ and GPLv2 and (LGPLv3+ with exceptions) |
119 |
ennael |
78010 |
Group: Video |
120 |
|
|
BuildRoot: %{_tmppath}/%{name}-root |
121 |
|
|
BuildRequires: boost-devel |
122 |
anssi |
227542 |
%if %without internal_ffmpeg |
123 |
ennael |
78010 |
BuildRequires: ffmpeg-devel |
124 |
anssi |
227542 |
%endif |
125 |
ennael |
78010 |
BuildRequires: libmpeg2dec-devel |
126 |
|
|
BuildRequires: libogg-devel |
127 |
|
|
BuildRequires: libwavpack-devel |
128 |
|
|
BuildRequires: python-devel |
129 |
|
|
BuildRequires: glew-devel |
130 |
|
|
BuildRequires: mesagl-devel |
131 |
|
|
BuildRequires: mesaglu-devel |
132 |
|
|
BuildRequires: libmad-devel |
133 |
|
|
BuildRequires: libjpeg-devel |
134 |
|
|
BuildRequires: libsamplerate-devel |
135 |
|
|
BuildRequires: libvorbis-devel |
136 |
|
|
BuildRequires: bzip2-devel |
137 |
|
|
BuildRequires: mysql-devel |
138 |
|
|
BuildRequires: liblzo2-devel |
139 |
|
|
BuildRequires: zlib-devel |
140 |
|
|
BuildRequires: openssl-devel |
141 |
|
|
BuildRequires: fontconfig-devel |
142 |
|
|
BuildRequires: fribidi-devel |
143 |
|
|
BuildRequires: sqlite3-devel |
144 |
anssi |
217508 |
BuildRequires: libpng-devel |
145 |
ennael |
78010 |
BuildRequires: libpcre-devel |
146 |
|
|
BuildRequires: libcdio-devel |
147 |
|
|
BuildRequires: libmms-devel |
148 |
|
|
BuildRequires: freetype2-devel |
149 |
|
|
BuildRequires: libflac-devel |
150 |
|
|
BuildRequires: libsmbclient-devel |
151 |
|
|
BuildRequires: SDL_mixer-devel |
152 |
|
|
BuildRequires: libjasper-devel |
153 |
|
|
BuildRequires: libtiff-devel |
154 |
|
|
BuildRequires: SDL_image-devel |
155 |
|
|
BuildRequires: libalsa-devel |
156 |
|
|
BuildRequires: enca-devel |
157 |
|
|
BuildRequires: libxt-devel |
158 |
|
|
BuildRequires: libxtst-devel |
159 |
|
|
BuildRequires: libxmu-devel |
160 |
|
|
BuildRequires: libxinerama-devel |
161 |
|
|
BuildRequires: libcurl-devel |
162 |
|
|
BuildRequires: dbus-devel |
163 |
|
|
BuildRequires: SDL-devel |
164 |
|
|
BuildRequires: pulseaudio-devel |
165 |
|
|
BuildRequires: avahi-common-devel |
166 |
|
|
BuildRequires: avahi-client-devel |
167 |
|
|
BuildRequires: libxrandr-devel |
168 |
|
|
BuildRequires: vdpau-devel |
169 |
|
|
BuildRequires: cwiid-devel |
170 |
|
|
BuildRequires: libice-devel |
171 |
|
|
BuildRequires: libx11-devel |
172 |
|
|
BuildRequires: crystalhd-devel |
173 |
|
|
BuildRequires: libmicrohttpd-devel |
174 |
|
|
BuildRequires: libmodplug-devel |
175 |
|
|
BuildRequires: ssh-devel |
176 |
|
|
BuildRequires: libva-devel |
177 |
|
|
BuildRequires: gettext-devel |
178 |
|
|
BuildRequires: expat-devel |
179 |
|
|
BuildRequires: libass-devel |
180 |
|
|
BuildRequires: rtmp-devel |
181 |
|
|
BuildRequires: bluray-devel |
182 |
|
|
BuildRequires: bluez-devel |
183 |
anssi |
217508 |
BuildRequires: udev-devel |
184 |
|
|
BuildRequires: yajl-devel |
185 |
|
|
BuildRequires: nfs-devel |
186 |
|
|
BuildRequires: afpclient-devel |
187 |
|
|
BuildRequires: libplist-devel |
188 |
|
|
BuildRequires: shairport-devel |
189 |
anssi |
219397 |
BuildRequires: cec-devel |
190 |
ennael |
78010 |
BuildRequires: cmake |
191 |
|
|
BuildRequires: gperf |
192 |
|
|
BuildRequires: zip |
193 |
|
|
%ifarch %ix86 |
194 |
|
|
BuildRequires: nasm |
195 |
|
|
%endif |
196 |
|
|
Requires: lsb-release |
197 |
|
|
# dlopened (existence check required by rpm5 as it doesn't use stderr): |
198 |
|
|
%define dlopenreq() %([ -e %{_libdir}/lib%{1}.so ] && rpm -qf --qf '%%{name}' $(readlink -f %{_libdir}/lib%{1}.so) 2>/dev/null || echo %{name}) |
199 |
|
|
Requires: %dlopenreq curl |
200 |
|
|
Requires: %dlopenreq FLAC |
201 |
|
|
Requires: %dlopenreq mad |
202 |
|
|
Requires: %dlopenreq ogg |
203 |
|
|
Requires: %dlopenreq vorbis |
204 |
|
|
Requires: %dlopenreq vorbisenc |
205 |
|
|
Requires: %dlopenreq vorbisfile |
206 |
|
|
Requires: %dlopenreq modplug |
207 |
|
|
Requires: %dlopenreq rtmp |
208 |
anssi |
217508 |
Requires: %dlopenreq mpeg2 |
209 |
|
|
Requires: %dlopenreq ass |
210 |
|
|
Requires: %dlopenreq bluray |
211 |
|
|
Requires: %dlopenreq nfs |
212 |
|
|
Requires: %dlopenreq afpclient |
213 |
|
|
Requires: %dlopenreq plist |
214 |
|
|
Requires: %dlopenreq shairport |
215 |
anssi |
219397 |
Requires: %dlopenreq cec |
216 |
ennael |
78010 |
# not nearly as common as the above, so just suggest instead for now: |
217 |
|
|
Suggests: %dlopenreq crystalhd |
218 |
anssi |
219397 |
# TODO: FEH.py is useless nowadays, drop it here and upstream. |
219 |
ennael |
78010 |
# for FEH.py, to check current configuration is ok for xbmc: |
220 |
|
|
Requires: xdpyinfo |
221 |
|
|
Requires: glxinfo |
222 |
|
|
# for FEH.py to allow it to give an error message (should be available already |
223 |
|
|
# on most systems): |
224 |
|
|
Requires: pygtk2 |
225 |
|
|
# for xbmc python scripts: |
226 |
|
|
Requires: python-imaging |
227 |
anssi |
217508 |
# Packages not shipped in core: |
228 |
ennael |
78010 |
Suggests: %{_lib}lame0 |
229 |
|
|
Suggests: %{_lib}dvdcss2 |
230 |
|
|
|
231 |
|
|
# Packages have been merged |
232 |
|
|
Obsoletes: xbmc-core < 9.11-1.svn29468 |
233 |
|
|
Obsoletes: xbmc-skin-confluence < 9.11-1.svn29468 |
234 |
|
|
Obsoletes: xbmc-skin-pm3-hd < 9.11-1.svn29468 |
235 |
|
|
Obsoletes: xbmc-nosefart < 9.11-1.svn29468 |
236 |
|
|
Obsoletes: xbmc-screensavers-default < 9.11-1.svn29468 |
237 |
|
|
Obsoletes: xbmc-script-examples < 9.11-1.svn27796 |
238 |
|
|
Obsoletes: xbmc-web-pm3 < 9.11-1.svn27796 |
239 |
|
|
|
240 |
|
|
%description |
241 |
|
|
XBMC is an award-winning free and open source software media player |
242 |
|
|
and entertainment hub for digital media. |
243 |
|
|
|
244 |
|
|
While XBMC functions very well as a standard media player application |
245 |
|
|
for your computer, it has been designed to be the perfect companion |
246 |
|
|
for your HTPC. Supporting an almost endless range of remote controls, |
247 |
|
|
and combined with its beautiful interface and powerful skinning |
248 |
|
|
engine, XBMC feels very natural to use from the couch and is the |
249 |
|
|
ideal solution for your home theater. |
250 |
|
|
|
251 |
anssi |
217508 |
This is the stable version of XBMC from the %branch_release release branch, |
252 |
|
|
with PVR support added from opdenkamp %branch_release-pvr branch. Support for |
253 |
|
|
RAR files is not included due to license issues. |
254 |
ennael |
78010 |
|
255 |
|
|
%package eventclients-common |
256 |
|
|
Summary: Common files for XBMC eventclients |
257 |
|
|
Group: Video |
258 |
anssi |
217508 |
License: GPLv2+ |
259 |
ennael |
78010 |
%py_requires |
260 |
|
|
|
261 |
|
|
%description eventclients-common |
262 |
|
|
XBMC is an award-winning free and open source software media player |
263 |
|
|
and entertainment hub for digital media. |
264 |
|
|
|
265 |
|
|
This package contains common files for eventclients. |
266 |
|
|
|
267 |
|
|
%package eventclients-devel |
268 |
|
|
Summary: Development files for XBMC eventclients |
269 |
|
|
Group: Development/C |
270 |
anssi |
217508 |
License: GPLv2+ |
271 |
ennael |
78010 |
|
272 |
|
|
%description eventclients-devel |
273 |
|
|
XBMC is an award-winning free and open source software media player |
274 |
|
|
and entertainment hub for digital media. |
275 |
|
|
|
276 |
|
|
This package contains files needed to build eventclients. |
277 |
|
|
|
278 |
|
|
%package eventclient-wiiremote |
279 |
|
|
Summary: Wii Remote eventclient for XBMC |
280 |
|
|
Group: Video |
281 |
anssi |
217508 |
License: GPLv3+ |
282 |
ennael |
78010 |
Requires: %{name}-eventclients-common = %{version}-%{release} |
283 |
|
|
|
284 |
|
|
%description eventclient-wiiremote |
285 |
|
|
XBMC is an award-winning free and open source software media player |
286 |
|
|
and entertainment hub for digital media. |
287 |
|
|
|
288 |
|
|
This package contains the Wii Remote eventclient. |
289 |
|
|
|
290 |
|
|
%package eventclient-j2me |
291 |
|
|
Summary: J2ME eventclient for XBMC |
292 |
|
|
Group: Video |
293 |
anssi |
217508 |
License: GPLv2+ |
294 |
ennael |
78010 |
Requires: python-pybluez |
295 |
|
|
Requires: %{name}-eventclients-common = %{version}-%{release} |
296 |
|
|
|
297 |
|
|
%description eventclient-j2me |
298 |
|
|
XBMC is an award-winning free and open source software media player |
299 |
|
|
and entertainment hub for digital media. |
300 |
|
|
|
301 |
|
|
This package contains the J2ME eventclient, providing a bluetooth |
302 |
|
|
server that can communicate with a mobile tool supporting J2ME. |
303 |
|
|
|
304 |
|
|
%package eventclient-ps3 |
305 |
|
|
Summary: PS3 eventclients for XBMC |
306 |
|
|
Group: Video |
307 |
anssi |
217508 |
License: GPLv2+ |
308 |
ennael |
78010 |
Requires: python-pybluez |
309 |
|
|
Requires: %{name}-eventclients-common = %{version}-%{release} |
310 |
|
|
# requires via zeroconf.py, only used by xbmc-ps3d: |
311 |
|
|
Requires: python-gobject avahi-python python-dbus |
312 |
|
|
# TODO merge all these?, and TODO zeroconf.py to a correct package? :) |
313 |
|
|
Obsoletes: eventclient-ps3remote < 9.11-1.svn31936 |
314 |
|
|
|
315 |
|
|
%description eventclient-ps3 |
316 |
|
|
XBMC is an award-winning free and open source software media player |
317 |
|
|
and entertainment hub for digital media. |
318 |
|
|
|
319 |
|
|
This package contains the PS3 remote and sixaxis eventclients. |
320 |
|
|
|
321 |
|
|
%package eventclient-xbmc-send |
322 |
|
|
Summary: PS3 eventclient for XBMC |
323 |
|
|
Group: Video |
324 |
anssi |
217508 |
License: GPLv2+ |
325 |
ennael |
78010 |
Requires: %{name}-eventclients-common = %{version}-%{release} |
326 |
|
|
|
327 |
|
|
%description eventclient-xbmc-send |
328 |
|
|
XBMC is an award-winning free and open source software media player |
329 |
|
|
and entertainment hub for digital media. |
330 |
|
|
|
331 |
|
|
This package contains the xbmc-send eventclient. |
332 |
|
|
|
333 |
|
|
%prep |
334 |
anssi |
93516 |
%if %snap |
335 |
|
|
%setup -q -n %name-%branch_release-%snap |
336 |
ennael |
78010 |
%else |
337 |
anssi |
217508 |
%if %pre |
338 |
|
|
%setup -q -n %{name}-%{version}-%{branch_release}_%{pre} |
339 |
|
|
%else |
340 |
ennael |
78010 |
%setup -q |
341 |
|
|
%endif |
342 |
anssi |
217508 |
%endif |
343 |
ennael |
78010 |
%apply_patches |
344 |
|
|
# otherwise backups end up in binary rpms |
345 |
|
|
find -type f \( -name '*.00??' -o -name '*.00??~' \) -print -delete |
346 |
|
|
|
347 |
|
|
# remove prebuilt libraries |
348 |
|
|
find -type f \( -iname '*.so' -o -iname '*.dll' -o -iname '*.exe' \) -delete |
349 |
|
|
|
350 |
|
|
# GPLv2 only |
351 |
anssi |
217508 |
rm -r lib/cmyth/Win32/include/mysql |
352 |
ennael |
78010 |
# BSD 4-clause |
353 |
|
|
rm -r xbmc/cores/DllLoader/exports/emu_socket |
354 |
|
|
|
355 |
|
|
# win32 only |
356 |
|
|
rm -rf system/players/dvdplayer/etc/fonts |
357 |
|
|
|
358 |
|
|
%build |
359 |
anssi |
93516 |
%if %snap |
360 |
|
|
export GIT_REV=%snap |
361 |
ennael |
78010 |
%else |
362 |
anssi |
219397 |
export GIT_REV="tarball" |
363 |
ennael |
78010 |
%endif |
364 |
|
|
./bootstrap |
365 |
|
|
|
366 |
|
|
# due to xbmc modules that use symbols from xbmc binary |
367 |
|
|
# and are not using libtool |
368 |
|
|
%define _disable_ld_no_undefined 1 |
369 |
|
|
|
370 |
anssi |
93516 |
# Workaround configure using git to override GIT_REV (TODO: fix it properly) |
371 |
|
|
export ac_cv_prog_HAVE_GIT="no" |
372 |
|
|
|
373 |
ennael |
78010 |
%configure2_5x \ |
374 |
|
|
--disable-debug \ |
375 |
|
|
--disable-ccache \ |
376 |
|
|
--enable-external-libraries \ |
377 |
|
|
--disable-non-free \ |
378 |
|
|
--disable-dvdcss \ |
379 |
anssi |
227542 |
--disable-hal \ |
380 |
ennael |
78010 |
--enable-goom \ |
381 |
anssi |
227542 |
--with-lirc-device=/var/run/lirc/lircd \ |
382 |
|
|
%if %with internal_ffmpeg |
383 |
|
|
--disable-external-ffmpeg |
384 |
|
|
%endif |
385 |
ennael |
78010 |
|
386 |
anssi |
217508 |
# non-free = unrar |
387 |
ennael |
78010 |
# dvdcss is handled via dlopen when disabled |
388 |
anssi |
227542 |
# hal is disabled as it is just a fallback when the replacmenets are |
389 |
|
|
# not available |
390 |
ennael |
78010 |
|
391 |
|
|
%make |
392 |
|
|
%make -C tools/EventClients wiimote |
393 |
|
|
|
394 |
|
|
%install |
395 |
|
|
rm -rf %{buildroot} |
396 |
|
|
%makeinstall_std |
397 |
|
|
%makeinstall_std -C tools/EventClients |
398 |
|
|
|
399 |
|
|
# unused |
400 |
|
|
rm %{buildroot}%{_datadir}/xsessions/XBMC.desktop |
401 |
|
|
# our version of the above: |
402 |
|
|
install -d -m755 %{buildroot}%{_sysconfdir}/X11/wmsession.d |
403 |
|
|
cat > %{buildroot}%{_sysconfdir}/X11/wmsession.d/15XBMC <<EOF |
404 |
|
|
NAME=XBMC |
405 |
|
|
ICON=xbmc.png |
406 |
|
|
DESC=XBMC Media Center |
407 |
|
|
EXEC=%{_bindir}/xbmc-standalone |
408 |
|
|
SCRIPT: |
409 |
|
|
exec %{_bindir}/xbmc-standalone |
410 |
|
|
EOF |
411 |
|
|
|
412 |
|
|
# unused files, TODO fix this upstream: |
413 |
|
|
find %{buildroot}%{_datadir}/xbmc/addons/skin.*/media -name '*.png' -delete |
414 |
|
|
|
415 |
|
|
( # for IFS and +x |
416 |
|
|
# Check for issues in ELF binaries |
417 |
|
|
undefined= |
418 |
|
|
fhserr= |
419 |
anssi |
162472 |
echo Silencing output of undefined symbol and FHS conformance checks |
420 |
ennael |
78010 |
set +x |
421 |
|
|
IFS=$'\n' |
422 |
|
|
for file in $(find %{buildroot} -type f); do |
423 |
|
|
type="$(file "$file")" |
424 |
|
|
echo "$type" | grep -q "ELF" || continue |
425 |
|
|
|
426 |
|
|
# Check that a binary file is not in datadir: |
427 |
|
|
echo "$file" | grep -q "%{_datadir}" && fhserr="${fhserr}$file\n" |
428 |
|
|
|
429 |
|
|
# check for undefined symbols in XBMC modules |
430 |
|
|
echo "$type" | grep -q "shared object" || continue |
431 |
|
|
for symbol in $(LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{buildroot}%{_libdir} ldd -r "$file" 2>&1 | grep undefined | awk '{ print $3 }'); do |
432 |
|
|
# undefined symbols may also be provided by XBMC: |
433 |
|
|
nm -f posix -D --no-demangle --defined-only %{buildroot}%{_libdir}/xbmc/xbmc.bin | grep -q "^$symbol " && continue |
434 |
|
|
# The symbol was not provided by XBMC. |
435 |
|
|
# Check if it is available through its dependencies: |
436 |
|
|
for filename in $(objdump -p %{buildroot}%{_libdir}/xbmc/xbmc.bin | grep NEEDED | awk '{ print $2 }'); do |
437 |
|
|
depfile="/%{_lib}/$filename" |
438 |
|
|
[ -e "$depfile" ] || depfile="%{_libdir}/$filename" |
439 |
|
|
nm -f posix -D --no-demangle --defined-only $depfile | grep -q "^$symbol " && continue 2 |
440 |
|
|
done |
441 |
|
|
# Euphoria references rsxs PNG class, but it is never used at runtime, |
442 |
|
|
# so it results in no errors due to RTLD_LAZY being used by xbmc module loader. |
443 |
anssi |
227542 |
case $file:$symbol in |
444 |
|
|
*/Euphoria.xbs:_ZN3PNG*) continue;; |
445 |
|
|
%if %with internal_ffmpeg |
446 |
|
|
*/dvdplayer/*.so:*) continue;; |
447 |
|
|
%endif |
448 |
|
|
esac |
449 |
ennael |
78010 |
# the symbol was not found |
450 |
|
|
undefined="${undefined}$file: $symbol\n" |
451 |
|
|
done |
452 |
|
|
done |
453 |
|
|
ok=1 |
454 |
|
|
[ -n "$undefined" ] && echo -e "$undefined" && echo "Undefined symbols!" && ok= |
455 |
|
|
[ -n "$fhserr" ] && echo -e "$fhserr" && echo "Binaries in datadir!" && ok= |
456 |
|
|
[ -n "$ok" ] |
457 |
|
|
) |
458 |
|
|
|
459 |
|
|
%clean |
460 |
|
|
rm -rf %{buildroot} |
461 |
|
|
|
462 |
|
|
%files |
463 |
|
|
%defattr(-,root,root) |
464 |
|
|
%doc %{_docdir}/xbmc |
465 |
|
|
%{_sysconfdir}/X11/wmsession.d/15XBMC |
466 |
|
|
%{_bindir}/xbmc |
467 |
|
|
%{_bindir}/xbmc-standalone |
468 |
|
|
%dir %{_libdir}/xbmc |
469 |
|
|
%dir %{_libdir}/xbmc/addons |
470 |
|
|
%dir %{_libdir}/xbmc/system |
471 |
|
|
%dir %{_libdir}/xbmc/system/players |
472 |
|
|
%dir %{_libdir}/xbmc/system/players/dvdplayer |
473 |
|
|
%dir %{_libdir}/xbmc/system/players/paplayer |
474 |
|
|
%{_libdir}/xbmc/xbmc.bin |
475 |
|
|
%{_libdir}/xbmc/xbmc-xrandr |
476 |
|
|
%dir %{_libdir}/xbmc/addons/* |
477 |
|
|
%{_libdir}/xbmc/addons/*/*.so |
478 |
|
|
%{_libdir}/xbmc/addons/*/*.pvr |
479 |
|
|
%{_libdir}/xbmc/addons/*/*.vis |
480 |
|
|
%{_libdir}/xbmc/addons/*/*.xbs |
481 |
|
|
%{_libdir}/xbmc/system/ImageLib-*-linux.so |
482 |
|
|
%{_libdir}/xbmc/system/hdhomerun-*-linux.so |
483 |
anssi |
217508 |
%{_libdir}/xbmc/system/libcmyth-*-linux.so |
484 |
ennael |
78010 |
%{_libdir}/xbmc/system/libcpluff-*-linux.so |
485 |
|
|
%{_libdir}/xbmc/system/libexif-*-linux.so |
486 |
|
|
%{_libdir}/xbmc/system/libid3tag-*-linux.so |
487 |
|
|
%{_libdir}/xbmc/system/players/dvdplayer/libdvdnav-*-linux.so |
488 |
anssi |
227542 |
%if %with internal_ffmpeg |
489 |
|
|
%{_libdir}/xbmc/system/players/dvdplayer/av*-linux.so |
490 |
|
|
%{_libdir}/xbmc/system/players/dvdplayer/postproc-*-linux.so |
491 |
|
|
%{_libdir}/xbmc/system/players/dvdplayer/swscale-*-linux.so |
492 |
|
|
%endif |
493 |
ennael |
78010 |
%{_libdir}/xbmc/system/players/paplayer/adpcm-*-linux.so |
494 |
|
|
%{_libdir}/xbmc/system/players/paplayer/libsidplay2-*-linux.so |
495 |
|
|
%{_libdir}/xbmc/system/players/paplayer/nosefart-*-linux.so |
496 |
|
|
%{_libdir}/xbmc/system/players/paplayer/stsoundlibrary-*-linux.so |
497 |
|
|
%{_libdir}/xbmc/system/players/paplayer/timidity-*-linux.so |
498 |
|
|
%{_libdir}/xbmc/system/players/paplayer/vgmstream-*-linux.so |
499 |
|
|
%ifarch %ix86 |
500 |
|
|
%{_libdir}/xbmc/system/players/paplayer/SNESAPU-*-linux.so |
501 |
|
|
%endif |
502 |
|
|
%dir %{_datadir}/xbmc |
503 |
|
|
%{_datadir}/xbmc/addons |
504 |
|
|
%{_datadir}/xbmc/FEH.py |
505 |
|
|
%{_datadir}/xbmc/language |
506 |
|
|
%{_datadir}/xbmc/media |
507 |
|
|
%{_datadir}/xbmc/sounds |
508 |
|
|
%{_datadir}/xbmc/system |
509 |
|
|
%{_datadir}/xbmc/userdata |
510 |
|
|
%{_datadir}/applications/xbmc.desktop |
511 |
|
|
%{_iconsdir}/hicolor/*/apps/xbmc.png |
512 |
|
|
|
513 |
|
|
%files eventclients-common |
514 |
|
|
%defattr(-,root,root) |
515 |
|
|
%python_sitelib/xbmc |
516 |
|
|
%dir %{_datadir}/pixmaps/xbmc |
517 |
|
|
%{_datadir}/pixmaps/xbmc/*.png |
518 |
|
|
|
519 |
|
|
%files eventclients-devel |
520 |
|
|
%defattr(-,root,root) |
521 |
|
|
%dir %{_includedir}/xbmc |
522 |
|
|
%{_includedir}/xbmc/xbmcclient.h |
523 |
|
|
|
524 |
|
|
%files eventclient-j2me |
525 |
|
|
%defattr(-,root,root) |
526 |
|
|
%{_bindir}/xbmc-j2meremote |
527 |
|
|
|
528 |
|
|
%files eventclient-ps3 |
529 |
|
|
%defattr(-,root,root) |
530 |
|
|
%{_bindir}/xbmc-ps3d |
531 |
|
|
%{_bindir}/xbmc-ps3remote |
532 |
|
|
|
533 |
|
|
%files eventclient-xbmc-send |
534 |
|
|
%defattr(-,root,root) |
535 |
|
|
%{_bindir}/xbmc-send |
536 |
|
|
|
537 |
|
|
%files eventclient-wiiremote |
538 |
|
|
%defattr(-,root,root) |
539 |
|
|
%{_bindir}/xbmc-wiiremote |
540 |
|
|
|
541 |
|
|
|