/[packages]/cauldron/xbmc/current/SPECS/xbmc.spec
ViewVC logotype

Contents of /cauldron/xbmc/current/SPECS/xbmc.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 219397 - (show annotations) (download)
Mon Mar 5 22:40:27 2012 UTC (12 years, 1 month ago) by anssi
File size: 14266 byte(s)
- enable Pulse-Eight CEC adapter support via libcec
- use "tarball" for git revision, tarball name is too long
- update .spec comments

1
2 %define name xbmc
3 %define branch_release Eden
4 %define extra_feature pvr
5 %define version 11.0
6 %define snap 0
7 %define pre rc2
8 %define rel 2
9
10 %if %snap
11 %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 Summary: XBMC Media Center - media player and home entertainment system
19 Name: %{name}
20 Version: %{version}
21 %if %snap
22 Release: %mkrel 0.git%snap%branchr.%rel
23 Source: %{name}-%branch_release-%snap.tar.xz
24 %else
25 %if %pre
26 Release: %mkrel 0.%pre%branchr.%rel
27 Source: %{name}-%{version}-%{branch_release}_%{pre}.tar.gz
28 %else
29 Release: %mkrel 1.%branch.%rel
30 Source: %{name}-%{version}.tar.gz
31 %endif
32 %endif
33 URL: http://xbmc.org/
34
35 # bring snapshot up-to-date with pvr branch
36 # https://github.com/opdenkamp/xbmc
37 # git diff 4246dffa9896d0c66dc79a97c2d3c8a3d4c4a183..opdenkamp/Eden-pvr
38 # rediffed with already-applied hunks removed
39 Patch0: xbmc-Eden-pvr-rc1.1.patch
40
41 # Disable updates of the default skin. Our one is the PVR version, while the
42 # one in the XBMC.org addon repository would be the vanilla one (Confluence
43 # is currently not in the addon repository, though, as of 2012-03).
44 Patch201: xbmc-disable-confluence-update.patch
45
46 # fix build with libpng 1.5
47 # https://github.com/xbmc/xbmc/pull/601
48 # patch of Zenkibou @ 2012-01-14
49 Patch210: xbmc-libpng-1.5.patch
50
51 # Make the MythTV PVR client buildable (submitted upstream):
52 Patch211: 0001-fixed-undefined-symbols-in-MythTV-PVR-client.patch
53
54 # nosefart audio plugin and RSXS-0.9 based screensavers are GPLv2 only
55 # several eventclients are GPLv3+ (in subpackages)
56 # libhdhomerun is LGPLv3+ with an exception (always ok to link against it)
57 # the rest is GPLv2+
58 # both GPLv2+ and GPLv2 are mentioned because plugins are not part of core
59 # xbmc and therefore e.g. /usr/bin/xbmc is GPLv2+ with LGPLv3+ part
60 # as allowed by a license exception
61 License: GPLv2+ and GPLv2 and (LGPLv3+ with exceptions)
62 Group: Video
63 BuildRoot: %{_tmppath}/%{name}-root
64 BuildRequires: boost-devel
65 BuildRequires: ffmpeg-devel
66 BuildRequires: libmpeg2dec-devel
67 BuildRequires: libogg-devel
68 BuildRequires: libwavpack-devel
69 BuildRequires: python-devel
70 BuildRequires: glew-devel
71 BuildRequires: mesagl-devel
72 BuildRequires: mesaglu-devel
73 BuildRequires: libmad-devel
74 BuildRequires: libjpeg-devel
75 BuildRequires: libsamplerate-devel
76 BuildRequires: libvorbis-devel
77 BuildRequires: bzip2-devel
78 BuildRequires: mysql-devel
79 BuildRequires: liblzo2-devel
80 BuildRequires: zlib-devel
81 BuildRequires: openssl-devel
82 BuildRequires: fontconfig-devel
83 BuildRequires: fribidi-devel
84 BuildRequires: sqlite3-devel
85 BuildRequires: libpng-devel
86 BuildRequires: libpcre-devel
87 BuildRequires: libcdio-devel
88 BuildRequires: libmms-devel
89 BuildRequires: freetype2-devel
90 BuildRequires: libflac-devel
91 BuildRequires: libsmbclient-devel
92 BuildRequires: SDL_mixer-devel
93 BuildRequires: libjasper-devel
94 BuildRequires: libtiff-devel
95 BuildRequires: SDL_image-devel
96 BuildRequires: libalsa-devel
97 BuildRequires: enca-devel
98 BuildRequires: libxt-devel
99 BuildRequires: libxtst-devel
100 BuildRequires: libxmu-devel
101 BuildRequires: libxinerama-devel
102 BuildRequires: libcurl-devel
103 BuildRequires: dbus-devel
104 BuildRequires: hal-devel
105 BuildRequires: SDL-devel
106 BuildRequires: pulseaudio-devel
107 BuildRequires: avahi-common-devel
108 BuildRequires: avahi-client-devel
109 BuildRequires: libxrandr-devel
110 BuildRequires: vdpau-devel
111 BuildRequires: cwiid-devel
112 BuildRequires: libice-devel
113 BuildRequires: libx11-devel
114 BuildRequires: crystalhd-devel
115 BuildRequires: libmicrohttpd-devel
116 BuildRequires: libmodplug-devel
117 BuildRequires: ssh-devel
118 BuildRequires: libva-devel
119 BuildRequires: gettext-devel
120 BuildRequires: expat-devel
121 BuildRequires: libass-devel
122 BuildRequires: rtmp-devel
123 BuildRequires: bluray-devel
124 BuildRequires: bluez-devel
125 BuildRequires: udev-devel
126 BuildRequires: yajl-devel
127 BuildRequires: nfs-devel
128 BuildRequires: afpclient-devel
129 BuildRequires: libplist-devel
130 BuildRequires: shairport-devel
131 BuildRequires: cec-devel
132 BuildRequires: cmake
133 BuildRequires: gperf
134 BuildRequires: zip
135 %ifarch %ix86
136 BuildRequires: nasm
137 %endif
138 Requires: lsb-release
139 # dlopened (existence check required by rpm5 as it doesn't use stderr):
140 %define dlopenreq() %([ -e %{_libdir}/lib%{1}.so ] && rpm -qf --qf '%%{name}' $(readlink -f %{_libdir}/lib%{1}.so) 2>/dev/null || echo %{name})
141 Requires: %dlopenreq curl
142 Requires: %dlopenreq FLAC
143 Requires: %dlopenreq mad
144 Requires: %dlopenreq ogg
145 Requires: %dlopenreq vorbis
146 Requires: %dlopenreq vorbisenc
147 Requires: %dlopenreq vorbisfile
148 Requires: %dlopenreq modplug
149 Requires: %dlopenreq rtmp
150 Requires: %dlopenreq mpeg2
151 Requires: %dlopenreq ass
152 Requires: %dlopenreq bluray
153 Requires: %dlopenreq nfs
154 Requires: %dlopenreq afpclient
155 Requires: %dlopenreq plist
156 Requires: %dlopenreq shairport
157 Requires: %dlopenreq cec
158 # not nearly as common as the above, so just suggest instead for now:
159 Suggests: %dlopenreq crystalhd
160 # TODO: FEH.py is useless nowadays, drop it here and upstream.
161 # for FEH.py, to check current configuration is ok for xbmc:
162 Requires: xdpyinfo
163 Requires: glxinfo
164 # for FEH.py to allow it to give an error message (should be available already
165 # on most systems):
166 Requires: pygtk2
167 # for xbmc python scripts:
168 Requires: python-imaging
169 # Packages not shipped in core:
170 Suggests: %{_lib}lame0
171 Suggests: %{_lib}dvdcss2
172
173 # Packages have been merged
174 Obsoletes: xbmc-core < 9.11-1.svn29468
175 Obsoletes: xbmc-skin-confluence < 9.11-1.svn29468
176 Obsoletes: xbmc-skin-pm3-hd < 9.11-1.svn29468
177 Obsoletes: xbmc-nosefart < 9.11-1.svn29468
178 Obsoletes: xbmc-screensavers-default < 9.11-1.svn29468
179 Obsoletes: xbmc-script-examples < 9.11-1.svn27796
180 Obsoletes: xbmc-web-pm3 < 9.11-1.svn27796
181
182 %description
183 XBMC is an award-winning free and open source software media player
184 and entertainment hub for digital media.
185
186 While XBMC functions very well as a standard media player application
187 for your computer, it has been designed to be the perfect companion
188 for your HTPC. Supporting an almost endless range of remote controls,
189 and combined with its beautiful interface and powerful skinning
190 engine, XBMC feels very natural to use from the couch and is the
191 ideal solution for your home theater.
192
193 This is the stable version of XBMC from the %branch_release release branch,
194 with PVR support added from opdenkamp %branch_release-pvr branch. Support for
195 RAR files is not included due to license issues.
196
197 %package eventclients-common
198 Summary: Common files for XBMC eventclients
199 Group: Video
200 License: GPLv2+
201 %py_requires
202
203 %description eventclients-common
204 XBMC is an award-winning free and open source software media player
205 and entertainment hub for digital media.
206
207 This package contains common files for eventclients.
208
209 %package eventclients-devel
210 Summary: Development files for XBMC eventclients
211 Group: Development/C
212 License: GPLv2+
213
214 %description eventclients-devel
215 XBMC is an award-winning free and open source software media player
216 and entertainment hub for digital media.
217
218 This package contains files needed to build eventclients.
219
220 %package eventclient-wiiremote
221 Summary: Wii Remote eventclient for XBMC
222 Group: Video
223 License: GPLv3+
224 Requires: %{name}-eventclients-common = %{version}-%{release}
225
226 %description eventclient-wiiremote
227 XBMC is an award-winning free and open source software media player
228 and entertainment hub for digital media.
229
230 This package contains the Wii Remote eventclient.
231
232 %package eventclient-j2me
233 Summary: J2ME eventclient for XBMC
234 Group: Video
235 License: GPLv2+
236 Requires: python-pybluez
237 Requires: %{name}-eventclients-common = %{version}-%{release}
238
239 %description eventclient-j2me
240 XBMC is an award-winning free and open source software media player
241 and entertainment hub for digital media.
242
243 This package contains the J2ME eventclient, providing a bluetooth
244 server that can communicate with a mobile tool supporting J2ME.
245
246 %package eventclient-ps3
247 Summary: PS3 eventclients for XBMC
248 Group: Video
249 License: GPLv2+
250 Requires: python-pybluez
251 Requires: %{name}-eventclients-common = %{version}-%{release}
252 # requires via zeroconf.py, only used by xbmc-ps3d:
253 Requires: python-gobject avahi-python python-dbus
254 # TODO merge all these?, and TODO zeroconf.py to a correct package? :)
255 Obsoletes: eventclient-ps3remote < 9.11-1.svn31936
256
257 %description eventclient-ps3
258 XBMC is an award-winning free and open source software media player
259 and entertainment hub for digital media.
260
261 This package contains the PS3 remote and sixaxis eventclients.
262
263 %package eventclient-xbmc-send
264 Summary: PS3 eventclient for XBMC
265 Group: Video
266 License: GPLv2+
267 Requires: %{name}-eventclients-common = %{version}-%{release}
268
269 %description eventclient-xbmc-send
270 XBMC is an award-winning free and open source software media player
271 and entertainment hub for digital media.
272
273 This package contains the xbmc-send eventclient.
274
275 %prep
276 %if %snap
277 %setup -q -n %name-%branch_release-%snap
278 %else
279 %if %pre
280 %setup -q -n %{name}-%{version}-%{branch_release}_%{pre}
281 %else
282 %setup -q
283 %endif
284 %endif
285 %apply_patches
286 # otherwise backups end up in binary rpms
287 find -type f \( -name '*.00??' -o -name '*.00??~' \) -print -delete
288
289 # remove prebuilt libraries
290 find -type f \( -iname '*.so' -o -iname '*.dll' -o -iname '*.exe' \) -delete
291
292 # GPLv2 only
293 rm -r lib/cmyth/Win32/include/mysql
294 # BSD 4-clause
295 rm -r xbmc/cores/DllLoader/exports/emu_socket
296
297 # win32 only
298 rm -rf system/players/dvdplayer/etc/fonts
299
300 %build
301 %if %snap
302 export GIT_REV=%snap
303 %else
304 export GIT_REV="tarball"
305 %endif
306 ./bootstrap
307
308 # due to xbmc modules that use symbols from xbmc binary
309 # and are not using libtool
310 %define _disable_ld_no_undefined 1
311
312 # Workaround configure using git to override GIT_REV (TODO: fix it properly)
313 export ac_cv_prog_HAVE_GIT="no"
314
315 %configure2_5x \
316 --disable-debug \
317 --disable-ccache \
318 --enable-external-libraries \
319 --disable-non-free \
320 --disable-dvdcss \
321 --enable-goom \
322 --with-lirc-device=/var/run/lirc/lircd
323
324 # non-free = unrar
325 # dvdcss is handled via dlopen when disabled
326
327 %make
328 %make -C tools/EventClients wiimote
329
330 %install
331 rm -rf %{buildroot}
332 %makeinstall_std
333 %makeinstall_std -C tools/EventClients
334
335 # unused
336 rm %{buildroot}%{_datadir}/xsessions/XBMC.desktop
337 # our version of the above:
338 install -d -m755 %{buildroot}%{_sysconfdir}/X11/wmsession.d
339 cat > %{buildroot}%{_sysconfdir}/X11/wmsession.d/15XBMC <<EOF
340 NAME=XBMC
341 ICON=xbmc.png
342 DESC=XBMC Media Center
343 EXEC=%{_bindir}/xbmc-standalone
344 SCRIPT:
345 exec %{_bindir}/xbmc-standalone
346 EOF
347
348 # unused files, TODO fix this upstream:
349 find %{buildroot}%{_datadir}/xbmc/addons/skin.*/media -name '*.png' -delete
350
351 ( # for IFS and +x
352 # Check for issues in ELF binaries
353 undefined=
354 fhserr=
355 echo Silencing output of undefined symbol and FHS conformance checks
356 set +x
357 IFS=$'\n'
358 for file in $(find %{buildroot} -type f); do
359 type="$(file "$file")"
360 echo "$type" | grep -q "ELF" || continue
361
362 # Check that a binary file is not in datadir:
363 echo "$file" | grep -q "%{_datadir}" && fhserr="${fhserr}$file\n"
364
365 # check for undefined symbols in XBMC modules
366 echo "$type" | grep -q "shared object" || continue
367 for symbol in $(LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{buildroot}%{_libdir} ldd -r "$file" 2>&1 | grep undefined | awk '{ print $3 }'); do
368 # undefined symbols may also be provided by XBMC:
369 nm -f posix -D --no-demangle --defined-only %{buildroot}%{_libdir}/xbmc/xbmc.bin | grep -q "^$symbol " && continue
370 # The symbol was not provided by XBMC.
371 # Check if it is available through its dependencies:
372 for filename in $(objdump -p %{buildroot}%{_libdir}/xbmc/xbmc.bin | grep NEEDED | awk '{ print $2 }'); do
373 depfile="/%{_lib}/$filename"
374 [ -e "$depfile" ] || depfile="%{_libdir}/$filename"
375 nm -f posix -D --no-demangle --defined-only $depfile | grep -q "^$symbol " && continue 2
376 done
377 # Euphoria references rsxs PNG class, but it is never used at runtime,
378 # so it results in no errors due to RTLD_LAZY being used by xbmc module loader.
379 case $file:$symbol in */Euphoria.xbs:_ZN3PNG*) continue; esac
380 # the symbol was not found
381 undefined="${undefined}$file: $symbol\n"
382 done
383 done
384 ok=1
385 [ -n "$undefined" ] && echo -e "$undefined" && echo "Undefined symbols!" && ok=
386 [ -n "$fhserr" ] && echo -e "$fhserr" && echo "Binaries in datadir!" && ok=
387 [ -n "$ok" ]
388 )
389
390 %clean
391 rm -rf %{buildroot}
392
393 %files
394 %defattr(-,root,root)
395 %doc %{_docdir}/xbmc
396 %{_sysconfdir}/X11/wmsession.d/15XBMC
397 %{_bindir}/xbmc
398 %{_bindir}/xbmc-standalone
399 %dir %{_libdir}/xbmc
400 %dir %{_libdir}/xbmc/addons
401 %dir %{_libdir}/xbmc/system
402 %dir %{_libdir}/xbmc/system/players
403 %dir %{_libdir}/xbmc/system/players/dvdplayer
404 %dir %{_libdir}/xbmc/system/players/paplayer
405 %{_libdir}/xbmc/xbmc.bin
406 %{_libdir}/xbmc/xbmc-xrandr
407 %dir %{_libdir}/xbmc/addons/*
408 %{_libdir}/xbmc/addons/*/*.so
409 %{_libdir}/xbmc/addons/*/*.pvr
410 %{_libdir}/xbmc/addons/*/*.vis
411 %{_libdir}/xbmc/addons/*/*.xbs
412 %{_libdir}/xbmc/system/ImageLib-*-linux.so
413 %{_libdir}/xbmc/system/hdhomerun-*-linux.so
414 %{_libdir}/xbmc/system/libcmyth-*-linux.so
415 %{_libdir}/xbmc/system/libcpluff-*-linux.so
416 %{_libdir}/xbmc/system/libexif-*-linux.so
417 %{_libdir}/xbmc/system/libid3tag-*-linux.so
418 %{_libdir}/xbmc/system/players/dvdplayer/libdvdnav-*-linux.so
419 %{_libdir}/xbmc/system/players/paplayer/adpcm-*-linux.so
420 %{_libdir}/xbmc/system/players/paplayer/libsidplay2-*-linux.so
421 %{_libdir}/xbmc/system/players/paplayer/nosefart-*-linux.so
422 %{_libdir}/xbmc/system/players/paplayer/stsoundlibrary-*-linux.so
423 %{_libdir}/xbmc/system/players/paplayer/timidity-*-linux.so
424 %{_libdir}/xbmc/system/players/paplayer/vgmstream-*-linux.so
425 %ifarch %ix86
426 %{_libdir}/xbmc/system/players/paplayer/SNESAPU-*-linux.so
427 %endif
428 %dir %{_datadir}/xbmc
429 %{_datadir}/xbmc/addons
430 %{_datadir}/xbmc/FEH.py
431 %{_datadir}/xbmc/language
432 %{_datadir}/xbmc/media
433 %{_datadir}/xbmc/sounds
434 %{_datadir}/xbmc/system
435 %{_datadir}/xbmc/userdata
436 %{_datadir}/applications/xbmc.desktop
437 %{_iconsdir}/hicolor/*/apps/xbmc.png
438
439 %files eventclients-common
440 %defattr(-,root,root)
441 %python_sitelib/xbmc
442 %dir %{_datadir}/pixmaps/xbmc
443 %{_datadir}/pixmaps/xbmc/*.png
444
445 %files eventclients-devel
446 %defattr(-,root,root)
447 %dir %{_includedir}/xbmc
448 %{_includedir}/xbmc/xbmcclient.h
449
450 %files eventclient-j2me
451 %defattr(-,root,root)
452 %{_bindir}/xbmc-j2meremote
453
454 %files eventclient-ps3
455 %defattr(-,root,root)
456 %{_bindir}/xbmc-ps3d
457 %{_bindir}/xbmc-ps3remote
458
459 %files eventclient-xbmc-send
460 %defattr(-,root,root)
461 %{_bindir}/xbmc-send
462
463 %files eventclient-wiiremote
464 %defattr(-,root,root)
465 %{_bindir}/xbmc-wiiremote
466
467

  ViewVC Help
Powered by ViewVC 1.1.30