3 # - fix build flags - some files are compiled with -O3 and without rpm*flags
4 # - fix linking argument order
5 # - add and/or fix users/groups permissions
6 # - split to subpackages?
9 %bcond_with afpclient # AFP support via libafpclient
10 %bcond_without airplay # AirPlay support
11 %bcond_with airtunes # AirTunes support
12 %bcond_without dvdcss # DVDCSS support
13 %bcond_without fishbmc # FishBMC visualisation
14 %bcond_without gl # OpenGL rendering
15 %bcond_without goom # GOOM visualisation
16 %bcond_with gtest # configure Google Test Framework
17 %bcond_with hal # build with HAL
18 %bcond_without joystick # SDL joystick support
19 %bcond_without libcap # libcap support
20 %bcond_with libcec # libcec support
21 %bcond_with libusb # libusb support
22 %bcond_with mdnsembedded # mDNSEmbedded support
23 %bcond_with nfs # NFS support via libnfs
24 %bcond_with openmax # OpenMax decoding, requires OpenGLES
25 %bcond_without projectm # ProjectM visualisation
26 %bcond_without pulse # PulseAudio support
27 %bcond_without rsxs # really slick X screensavers
28 %bcond_without rtmp # RTMP support via librtmp
29 %bcond_without sdl # SDL
30 %bcond_without spectrum # Spectrum visualisation
31 %bcond_without texturepacker # texturepacker support
32 %bcond_without udev # udev support
33 %bcond_without vaapi # VAAPI decoding
34 %bcond_without vdpau # VDPAU decoding
35 %bcond_with vtbdecoder # VTBDecoder decoding (VTB Decoder not supported on this platform)
36 %bcond_without waveform # Waveform visualisation
37 %bcond_without x11 # x11 'Linux Only'
38 %bcond_without xrandr # XRandR support
40 %define codename Helix
41 Summary: Kodi is a free and open source media-player and entertainment hub
45 License: GPL v2+ and GPL v3+
46 Group: Applications/Multimedia
47 Source0: http://mirrors.kodi.tv/releases/source/%{version}-%{codename}.tar.gz
48 # Source0-md5: 9717c539789789b8aeaf1dcfdb9f2c69
49 Patch0: jpeglib-boolean.patch
51 BuildRequires: Mesa-libGLU-devel
52 BuildRequires: OpenGL-devel
53 BuildRequires: SDL2-devel
54 BuildRequires: SDL_image-devel
55 BuildRequires: SDL_mixer-devel
56 BuildRequires: alsa-lib-devel
57 BuildRequires: autoconf
58 BuildRequires: automake
59 BuildRequires: avahi-devel
60 BuildRequires: bluez-libs-devel >= 4.99
61 BuildRequires: boost-devel
62 BuildRequires: bzip2-devel
64 BuildRequires: curl-devel
65 BuildRequires: dbus-devel
66 BuildRequires: doxygen
67 BuildRequires: ffmpeg-devel
68 BuildRequires: flac-devel
69 BuildRequires: fontconfig-devel
70 BuildRequires: freetype-devel
71 BuildRequires: fribidi-devel
73 BuildRequires: gettext-autopoint
74 BuildRequires: gettext-tools
75 BuildRequires: glew-devel
77 %{?with_hal:BuildRequires: hal-devel}
78 BuildRequires: jasper-devel
80 BuildRequires: libass-devel
81 BuildRequires: libbluray-devel >= 0.2.1
82 BuildRequires: libcap-devel
83 BuildRequires: libcdio-devel
84 %{?with_libcec:BuildRequires: libcec-devel}
85 %ifarch i686 pentium4 athlon %{x8664}
86 BuildRequires: libcrystalhd-devel
88 BuildRequires: libgcrypt-devel
89 BuildRequires: libjpeg-devel
90 BuildRequires: libltdl-devel
91 BuildRequires: libmad-devel
92 BuildRequires: libmicrohttpd-devel
93 BuildRequires: libmodplug-devel
94 BuildRequires: libmpeg2-devel
95 BuildRequires: libogg-devel
96 BuildRequires: libplist-devel
97 BuildRequires: libpng-devel
98 BuildRequires: librtmp-devel
99 BuildRequires: libsamplerate-devel
100 BuildRequires: libsmbclient-devel
101 BuildRequires: libssh-devel
102 BuildRequires: libtiff-devel
103 BuildRequires: libtool
104 BuildRequires: libva-devel
105 BuildRequires: libva-glx-devel
106 BuildRequires: libvdpau-devel
107 BuildRequires: libvorbis-devel
108 BuildRequires: libxslt-devel
109 BuildRequires: lzo-devel
110 BuildRequires: mysql-devel
114 BuildRequires: openssl-devel
115 BuildRequires: pcre-cxx-devel
116 BuildRequires: pkgconfig
117 BuildRequires: pulseaudio-devel
118 BuildRequires: python-devel >= 2.4
119 BuildRequires: rpm-pythonprov
120 BuildRequires: rpmbuild(macros) >= 1.566
122 BuildRequires: sed >= 4.0
123 BuildRequires: sqlite3-devel
125 BuildRequires: taglib-devel >= 1.8
126 BuildRequires: tinyxml-devel
127 BuildRequires: udev-devel
129 BuildRequires: xorg-lib-libX11-devel
130 BuildRequires: xorg-lib-libXext-devel
131 BuildRequires: xorg-lib-libXinerama-devel
132 BuildRequires: xorg-lib-libXmu-devel
133 BuildRequires: xorg-lib-libXrandr-devel
134 BuildRequires: xorg-lib-libXt-devel
135 BuildRequires: xorg-lib-libXtst-devel
136 BuildRequires: yajl-devel
139 BuildRequires: zlib-devel
140 #https://github.com/sahlberg/libnfs
141 #BuildRequires: libnfs-devel
142 #http://sites.google.com/site/alexthepuffin/home
143 #BuildRequires: afpfs-ng-devel
144 #http://mirrors.xbmc.org/build-deps/darwin-libs/libshairport-1.2.0.20310_lib.tar.gz
145 #https://github.com/albertz/shairport
146 #BuildRequires: libshairport
147 Requires: /usr/bin/glxinfo
148 Requires: SDL >= 1.2.14-5
149 Requires: lsb-release
150 Requires: xorg-app-xdpyinfo
151 # dlopened libraries:
152 # grep 'DLL_PATH_.*lib.*\.so' xbmc/DllPaths_generated.h | grep -v special://
157 Requires: libmpeg2-libs
161 Obsoletes: xbmc < 14.0
162 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
165 Kodi Entertainment Center (formerly XBMC) is a free and open-source
166 media player software developed by the XBMC Foundation, a non-profit
167 technology consortium. Kodi is available for multiple operating
168 systems and hardware platforms, with a software 10-foot user interface
169 for use with televisions and remote controls. It allows users to play
170 and view most videos, music, such as podcasts from the internet, and
171 all common digital media files from local and network storage media.
174 %setup -q -n xbmc-%{version}-%{codename}
180 --disable-silent-rules \
183 %{__enable_disable afpclient} \
184 %{__enable_disable airplay} \
185 %{__enable_disable airtunes} \
186 %{__enable_disable dvdcss} \
187 %{__enable_disable fishbmc} \
188 %{__enable_disable gl} \
189 %{__enable_disable goom} \
190 %{__enable_disable gtest} \
191 %{__enable_disable gtexturepacker} \
192 %{__enable_disable hal} \
193 %{__enable_disable joystick} \
194 %{__enable_disable libcap} \
195 %{__enable_disable libcec} \
196 %{__enable_disable libusb} \
197 %{__enable_disable mdnsembedded} \
198 %{__enable_disable nfs} \
199 %{__enable_disable openmax} \
200 %{__enable_disable projectm} \
201 %{__enable_disable pulse} \
202 %{__enable_disable rsxs} \
203 %{__enable_disable rtmp} \
204 %{__enable_disable sdl} \
205 %{__enable_disable spectrum} \
206 %{__enable_disable udev} \
207 %{__enable_disable vaapi} \
208 %{__enable_disable vdpau} \
209 %{__enable_disable vtbdecoder} \
210 %{__enable_disable waveform} \
211 %{__enable_disable x11} \
212 %{__enable_disable xrandr} \
218 rm -rf $RPM_BUILD_ROOT
220 DESTDIR=$RPM_BUILD_ROOT
222 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}
224 # no -devel package yet
225 %{__rm} -r $RPM_BUILD_ROOT%{_includedir}/kodi
226 %{__rm} -r $RPM_BUILD_ROOT%{_includedir}/xbmc
229 rm -rf $RPM_BUILD_ROOT
232 %defattr(644,root,root,755)
233 %doc README.md docs/README.linux
234 %attr(755,root,root) %{_bindir}/kodi
235 %attr(755,root,root) %{_bindir}/kodi-standalone
237 %attr(755,root,root) %{_libdir}/%{name}
238 %{_desktopdir}/kodi.desktop
239 %{_iconsdir}/hicolor/*/apps/%{name}.png
240 %{_datadir}/xsessions/kodi.desktop
242 # legacy xbmc compatibility links
243 %attr(755,root,root) %{_bindir}/xbmc
244 %attr(755,root,root) %{_bindir}/xbmc-standalone
247 %{_datadir}/xsessions/xbmc.desktop