]>
Commit | Line | Data |
---|---|---|
aa6db6e7 | 1 | # TODO |
bc34ab39 | 2 | # - bconds: altivec joystick lcd |
58422b0a | 3 | # - lcd? (app-misc/lcdproc) |
bc34ab39 | 4 | # - icons for desktop entries |
58422b0a | 5 | # - alpha, sparc, ppc arches? |
8afae0cb ER |
6 | # |
7 | # Specfile for MythTV | |
8 | # | |
9 | # MythTV now uses a fairly intelligent cpu-detection script, so if you are | |
10 | # building an rpm by hand on the machine it will be used on, I encourage you | |
11 | # to use "--with cpu_autodetect" to let mythtv decide for you. | |
12 | # | |
ed630fed | 13 | # Conditional build: |
af73c10e | 14 | %bcond_with cpu_autodetect # enable CPU autodetection at compile time (sets "-march", "-mcpu" compile flags really) |
cb059bf8 ER |
15 | %bcond_without lirc # lirc support |
16 | %bcond_without alsa # alsa support | |
9dc1d1be | 17 | %bcond_without oss # oss support |
cb059bf8 ER |
18 | %bcond_without arts # arts support |
19 | %bcond_without jack # jack audio connection kit | |
cb059bf8 | 20 | %bcond_without opengl # opengl vsync |
1e5a2ed2 | 21 | %bcond_with dvb # DVB support # invalid option |
bc34ab39 | 22 | %bcond_without xrandr # disable X11 resolution switching |
9dc1d1be JB |
23 | %bcond_with ivtv # ivtv support (PVR-250, PVR-350) NFY |
24 | %bcond_with firewire # ieee1394 (NFY) | |
bc34ab39 | 25 | %bcond_without xvmc # do not use XvMCW |
1e5a2ed2 | 26 | %bcond_with mmx # enable mmx |
32b3b293 ER |
27 | |
28 | # enable mmx automatically on arches having it | |
29 | %ifarch %{ix86} %{x8664} | |
30 | %ifnarch i386 i486 i586 i686 | |
31 | %define with_mmx 1 | |
32 | %endif | |
33 | %endif | |
cb059bf8 | 34 | |
b2c9e730 | 35 | Summary: A personal video recorder (PVR) application |
7456895a | 36 | Summary(pl.UTF-8): Osobista aplikacja do nagrywania obrazu (PVR) |
910a00e3 | 37 | Name: mythtv |
ac180387 | 38 | Version: 0.21 |
39 | Release: 0.1 | |
910a00e3 | 40 | License: GPL v2 |
b2c9e730 | 41 | Group: Applications/Multimedia |
448e41b0 | 42 | Source0: http://www.mythtv.org/mc/%{name}-%{version}.tar.bz2 |
ac180387 | 43 | # Source0-md5: 49fc135e1cde90cd935c1229467fa37e |
eceeddea ER |
44 | Source1: mythbackend.sysconfig |
45 | Source2: mythbackend.init | |
46 | Source3: mythbackend.logrotate | |
4cd4742b | 47 | Source5: mythfrontend.desktop |
2360417b | 48 | #Patch100: %{name}-branch.diff |
c79fdf07 | 49 | Patch0: %{name}-lib64.patch |
f1992461 | 50 | Patch1: mythtv-configure.patch |
96b717a5 ER |
51 | Patch2: %{name}-mythstream.patch |
52 | Patch3: %{name}-ldconfig.patch | |
1e5a2ed2 | 53 | #Patch4: %{name}-pl.patch |
96b717a5 | 54 | Patch5: %{name}-sbinpath.patch |
ac180387 | 55 | Patch6: mythtv-dvdnav-shared.patch |
56 | Patch7: %{name}-libs.patch | |
57 | Patch8: %{name}-fixes.patch | |
b2c9e730 | 58 | URL: http://www.mythtv.org/ |
5eccad13 | 59 | #BuildRequires: DirectFB-devel |
03ba0f65 | 60 | #BuildRequires: XFree86-devel |
ed630fed JB |
61 | %{?with_alsa:BuildRequires: alsa-lib-devel} |
62 | %{?with_arts:BuildRequires: arts-devel >= 13:0.9.5} | |
c0517663 | 63 | BuildRequires: freetype-devel >= 1:2.0.0 |
cb059bf8 | 64 | %{?with_jack:BuildRequires: jack-audio-connection-kit-devel} |
c0517663 | 65 | BuildRequires: lame-libs-devel |
03ba0f65 | 66 | %{?with_xvmc:BuildRequires: xorg-lib-libXvMC-devel} |
c0517663 | 67 | %{?with_firewire:BuildRequires: libavc1394-devel} |
96b717a5 ER |
68 | %{?with_dvb:BuildRequires: libdvb-devel} |
69 | BuildRequires: libdvdnav-devel | |
c0517663 ER |
70 | %{?with_firewire:BuildRequires: libiec61883-devel} |
71 | %{?with_firewire:BuildRequires: libraw1394-devel} | |
a3ec4ed6 | 72 | BuildRequires: linux-libc-headers >= 7:2.6.10 |
f3707f19 | 73 | %{?with_lirc:BuildRequires: lirc-devel} |
ed630fed | 74 | BuildRequires: mysql-devel |
ed630fed JB |
75 | BuildRequires: qmake >= 6:3.2.1-4 |
76 | BuildRequires: qt-devel >= 6:3.2.1-4 | |
4cd4742b | 77 | BuildRequires: rpmbuild(macros) >= 1.228 |
ed630fed | 78 | BuildRequires: sed >= 4.0 |
96b717a5 ER |
79 | # for bundled libavcodec |
80 | BuildRequires: libdts-devel | |
cccbdc0c | 81 | #BuildConflicts: libmyth-devel |
97b6efdd | 82 | ExclusiveArch: %{ix86} %{x8664} ppc |
910a00e3 | 83 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
8afae0cb | 84 | |
96b717a5 ER |
85 | %define myth_api_version %(echo %{version} | cut -d. -f1,2) |
86 | ||
8afae0cb | 87 | %description |
910a00e3 ER |
88 | MythTV implements the following PVR features, and more, with a unified |
89 | graphical interface: | |
5eccad13 ER |
90 | - Basic 'live-tv' functionality. Pause/Fast Forward/Rewind "live" TV. |
91 | - Video compression using RTjpeg or MPEG-4 | |
92 | - Program listing retrieval using XMLTV | |
93 | - Themable, semi-transparent on-screen display | |
94 | - Electronic program guide | |
95 | - Scheduled recording of TV programs | |
96 | - Resolution of conflicts between scheduled recordings | |
97 | - Basic video editing | |
8afae0cb | 98 | |
17176342 JR |
99 | %description -l pl.UTF-8 |
100 | MythTV implementuje następujące możliwości PVR, a nawet więcej, wraz z | |
ed630fed | 101 | ujednoliconym interfejsem graficznym: |
17176342 JR |
102 | - podstawowa funkcjonalność "live-tv"; pauza, szybkie przewijanie, |
103 | przewijanie "żywej" telewizji | |
104 | - kompresja obrazu przy użyciu RTjpeg lub MPEG-4 | |
105 | - odczyt listy programów przy użyciu XMLTV | |
106 | - pseudoprzezroczyste wyświetlanie na obrazie (OSD) z obsługą motywów | |
ed630fed | 107 | - elektroniczny przewodnik po programie |
17176342 JR |
108 | - planowane nagrywanie programów telewizyjnych |
109 | - rozwiązywanie konfliktów między planowanymi nagraniami | |
ed630fed | 110 | - podstawowa edycja obrazu |
a7691716 | 111 | |
ed630fed JB |
112 | %package backend |
113 | Summary: Server component of mythtv (a PVR) | |
7456895a | 114 | Summary(pl.UTF-8): Część serwerowa mythtv (PVR) |
910a00e3 | 115 | Group: Applications/Multimedia |
96b717a5 ER |
116 | Requires(post,preun): /sbin/chkconfig |
117 | Requires(postun): /usr/sbin/groupdel | |
118 | Requires(postun): /usr/sbin/userdel | |
ed630fed | 119 | Requires(pre): /bin/id |
f2f4277e | 120 | Requires(pre): /usr/bin/getgid |
ed630fed JB |
121 | Requires(pre): /usr/sbin/groupadd |
122 | Requires(pre): /usr/sbin/useradd | |
96b717a5 | 123 | Requires: libmyth = %{version}-%{release} |
ed630fed | 124 | Requires: mythtv = %{version}-%{release} |
ed630fed | 125 | Provides: group(mythtv) |
96b717a5 | 126 | Provides: user(mythtv) |
8afae0cb | 127 | |
ed630fed | 128 | %description backend |
910a00e3 ER |
129 | MythTV provides a unified graphical interface for recording and |
130 | viewing television programs. Refer to the mythtv package for more | |
131 | information. | |
8afae0cb | 132 | |
ed630fed JB |
133 | This package contains only the server software, which provides video |
134 | and audio capture and encoding services. In order to be useful, it | |
135 | requires a mythtv-frontend installation, either on the same system or | |
136 | one reachable via the network. | |
137 | ||
17176342 | 138 | %description backend -l pl.UTF-8 |
ed630fed | 139 | MythTV dostarcza ujednolicony interfejs graficzny do nagrywania i |
17176342 | 140 | oglądania programów telewizyjnych. Więcej informacji w pakiecie |
ed630fed JB |
141 | mythtv. |
142 | ||
17176342 JR |
143 | Ten pakiet zawiera tylko oprogramowanie serwerowe, udostępniające |
144 | usługi przechwytywania i kodowania obrazu i dźwięku. Aby było | |
ed630fed | 145 | przydatne, wymaga instalacji mythtv-frontend - na tym samym systemie, |
17176342 | 146 | albo innym osiągalnym po sieci. |
8afae0cb ER |
147 | |
148 | %package frontend | |
ed630fed | 149 | Summary: Client component of mythtv (a PVR) |
7456895a | 150 | Summary(pl.UTF-8): Część kliencka mythtv (PVR) |
910a00e3 | 151 | Group: Applications/Multimedia |
96b717a5 | 152 | Requires: libmyth = %{version}-%{release} |
910a00e3 ER |
153 | Requires: mythtv = %{version}-%{release} |
154 | Requires: mythtv-themes = %{version}-%{release} | |
96b717a5 | 155 | Provides: mythtv-frontend-api = %{myth_api_version} |
8afae0cb ER |
156 | |
157 | %description frontend | |
910a00e3 ER |
158 | MythTV provides a unified graphical interface for recording and |
159 | viewing television programs. Refer to the mythtv package for more | |
160 | information. | |
8afae0cb ER |
161 | |
162 | This package contains only the client software, which provides a | |
910a00e3 | 163 | front-end for playback and configuration. It requires access to a |
8afae0cb ER |
164 | mythtv-backend installation, either on the same system or one |
165 | reachable via the network. | |
166 | ||
17176342 | 167 | %description frontend -l pl.UTF-8 |
ed630fed | 168 | MythTV dostarcza ujednolicony interfejs graficzny do nagrywania i |
17176342 | 169 | oglądania programów telewizyjnych. Więcej informacji w pakiecie |
ed630fed | 170 | mythtv. |
8afae0cb | 171 | |
17176342 JR |
172 | Ten pakiet zawiera tylko oprogramowanie klienckie, dostarczające |
173 | frontend do odtwarzania i konfiguracji. Wymaga dostępu do instalacji | |
174 | mythtv-backend - na tym samym systemie, albo innym osiągalnym po | |
ed630fed | 175 | sieci. |
8afae0cb ER |
176 | |
177 | %package setup | |
ed630fed | 178 | Summary: Setup the mythtv backend |
7456895a | 179 | Summary(pl.UTF-8): Konfigurator backendu mythtv |
910a00e3 | 180 | Group: Applications/Multimedia |
96b717a5 | 181 | Requires: libmyth = %{version}-%{release} |
8afae0cb ER |
182 | |
183 | %description setup | |
910a00e3 ER |
184 | MythTV provides a unified graphical interface for recording and |
185 | viewing television programs. Refer to the mythtv package for more | |
186 | information. | |
8afae0cb ER |
187 | |
188 | This package contains only the setup software for configuring the | |
189 | mythtv backend. | |
190 | ||
17176342 | 191 | %description setup -l pl.UTF-8 |
ed630fed | 192 | MythTV dostarcza ujednolicony interfejs graficzny do nagrywania i |
17176342 | 193 | oglądania programów telewizyjnych. Więcej informacji w pakiecie |
ed630fed JB |
194 | mythtv. |
195 | ||
196 | Ten pakiet zawiera tylko program do konfigurowania backendu mythtv. | |
197 | ||
198 | %package themes | |
199 | Summary: Base themes for mythtv's frontend | |
7456895a | 200 | Summary(pl.UTF-8): Podstawowe motywy dla frontendu mythtv |
bbba3c1d ER |
201 | Requires: %{name}-frontend = %{version}-%{release} |
202 | Group: Themes | |
ed630fed JB |
203 | |
204 | %description themes | |
205 | MythTV provides a unified graphical interface for recording and | |
206 | viewing television programs. Refer to the mythtv package for more | |
207 | information. | |
208 | ||
209 | This package contains only the base themes used by the frontend and | |
210 | mythtvsetup. | |
211 | ||
17176342 | 212 | %description themes -l pl.UTF-8 |
ed630fed | 213 | MythTV dostarcza ujednolicony interfejs graficzny do nagrywania i |
17176342 | 214 | oglądania programów telewizyjnych. Więcej informacji w pakiecie |
ed630fed JB |
215 | mythtv. |
216 | ||
17176342 | 217 | Ten pakiet zawiera tylko podstawowe motywy używane przez frontend oraz |
ed630fed JB |
218 | mythtvsetup. |
219 | ||
220 | %package -n libmyth | |
221 | Summary: Library providing mythtv support | |
7456895a | 222 | Summary(pl.UTF-8): Biblioteka udostępniająca obsługę mythtv |
ed630fed JB |
223 | Group: Libraries |
224 | Requires: freetype >= 1:2.0.0 | |
225 | Requires: lame | |
226 | Requires: qt >= 6:3.2.1-4 | |
227 | Requires: qt-plugin-mysql >= 6:3.2.1-4 | |
228 | ||
229 | %description -n libmyth | |
230 | Common library code for MythTV and add-on modules (development) MythTV | |
231 | provides a unified graphical interface for recording and viewing | |
232 | television programs. Refer to the mythtv package for more information. | |
233 | ||
17176342 JR |
234 | %description -n libmyth -l pl.UTF-8 |
235 | Wspólny kod biblioteki dla MythTV i dodatkowych modułów MythTV | |
236 | dostarczający ujednolicony interfejs graficzny do nagrywania i | |
237 | oglądania programów telewizyjnych. Więcej informacji w pakiecie | |
ed630fed JB |
238 | mythtv. |
239 | ||
240 | %package -n libmyth-devel | |
241 | Summary: Development files for libmyth | |
7456895a | 242 | Summary(pl.UTF-8): Pliki nagłówkowe libmyth |
ed630fed JB |
243 | Group: Development/Libraries |
244 | Requires: libmyth = %{version}-%{release} | |
ed630fed JB |
245 | |
246 | %description -n libmyth-devel | |
247 | This package contains the header files for developing add-ons for | |
248 | mythtv. | |
249 | ||
17176342 JR |
250 | %description -n libmyth-devel -l pl.UTF-8 |
251 | Ten pakiet zawiera pliki nagłówkowe do tworzenia dodatków dla mythtv. | |
ed630fed JB |
252 | |
253 | %package -n libmyth-static | |
254 | Summary: Static libmyth library | |
7456895a | 255 | Summary(pl.UTF-8): Statyczna biblioteka libmyth |
ed630fed JB |
256 | Group: Development/Libraries |
257 | Requires: libmyth-devel = %{version}-%{release} | |
258 | ||
259 | %description -n libmyth-static | |
260 | Static libmyth library. | |
261 | ||
17176342 | 262 | %description -n libmyth-static -l pl.UTF-8 |
ed630fed JB |
263 | Statyczna biblioteka libmyth. |
264 | ||
8afae0cb | 265 | %prep |
448e41b0 | 266 | %setup -q %{?_rev:-n %{name}} |
96b717a5 | 267 | %if %{_lib} != "lib" |
1e5a2ed2 | 268 | #%patch0 -p1 |
96b717a5 | 269 | %endif |
f1992461 | 270 | %patch1 -p1 |
018c2e7e | 271 | %patch2 -p1 |
0ea777bd | 272 | %patch3 -p1 |
1e5a2ed2 | 273 | #%patch4 -p1 REDIFF and submit |
96b717a5 | 274 | %patch5 -p1 |
ac180387 | 275 | %patch6 -p1 |
09985e5b | 276 | %patch7 -p1 |
2360417b | 277 | %patch8 -p1 |
8afae0cb | 278 | |
6e738c98 ER |
279 | rm -rf database/old # not supported in PLD |
280 | ||
96b717a5 ER |
281 | # lib64 fix - enable to update patch |
282 | %if %{_lib} != "lib" && 0 | |
283 | find '(' -name '*.[ch]' -o -name '*.cpp' -o -name '*.pro' ')' | \ | |
284 | xargs grep -l /lib . | xargs sed -i -e ' | |
285 | s,/''usr/lib/,/%{_libdir}/,g | |
286 | s,/''lib/mythtv,/%{_lib}/mythtv,g | |
287 | s,{PREFIX}/lib$,{PREFIX}/%{_lib},g | |
288 | ' | |
289 | exit 1 | |
290 | %endif | |
291 | ||
3c3d6f2b ER |
292 | # Assigning null to QMAKE_LIBDIR_QT will prevent makefiles contain |
293 | # -L$(QTDIR)/%{_lib} and -Wl,-rpath,$(QTDIR)/%{_lib}. And that will | |
294 | # prevent compiler finding libs from system when they should be looked | |
295 | # from current buildtree. | |
296 | # but that made it link with -lqt which doesn't exist, instead of -lqt-mt | |
297 | # so we make QMAKE wrapper which will do sed subst after calling | |
298 | # qmake. this is the wrapper. | |
299 | cat > qmake-wrapper.sh <<'EOF' | |
300 | #!/bin/sh | |
301 | getmakefile() { | |
302 | while [ $# -gt 0 ]; do | |
303 | case "$1" in | |
304 | -o) | |
305 | shift | |
306 | makefile="$1" | |
307 | return | |
308 | ;; | |
309 | esac | |
310 | shift | |
311 | done | |
312 | } | |
313 | ||
314 | qmake "$@" | |
315 | getmakefile "$@" | |
316 | if [ "$makefile" ]; then | |
317 | %{__sed} -i -e ' | |
318 | s;-Wl,-rpath,$(QTDIR)/%{_lib};; | |
319 | s;-L$(QTDIR)/%{_lib};; | |
320 | ' $makefile | |
321 | fi | |
322 | EOF | |
323 | chmod +x qmake-wrapper.sh | |
324 | ||
8afae0cb | 325 | %build |
018c2e7e ER |
326 | %if %{with cpu_autodetect} |
327 | # Make sure we have /proc mounted | |
328 | if [ ! -r /proc/cpuinfo ]; then | |
329 | echo "You need to have /proc mounted in order to build with cpu_autodetect!" | |
330 | exit 1 | |
331 | fi | |
332 | %endif | |
eceeddea | 333 | |
96b717a5 | 334 | # NB: not autoconf configure |
448e41b0 ER |
335 | # help configure::has_library() to locate libs |
336 | LD_LIBRARY_PATH=%{_libdir} \ | |
337 | CC="%{__cc}" \ | |
338 | CXX="%{__cxx}" \ | |
96b717a5 ER |
339 | ./configure \ |
340 | --prefix=%{_prefix} \ | |
341 | --libdir=%{_libdir} \ | |
342 | --mandir=%{_mandir} \ | |
1b03363f | 343 | --disable-distcc --disable-ccache \ |
8e8230a1 | 344 | --compile-type=%{?debug:debug}%{!?debug:release} \ |
86b7888f ER |
345 | --extra-cflags="%{rpmcflags} -fomit-frame-pointer" \ |
346 | --extra-cxxflags="%{rpmcxxflags} -fomit-frame-pointer" \ | |
c79fdf07 ER |
347 | %if %{with cpu_autodetect} |
348 | --enable-proc-opt \ | |
349 | %else | |
c0517663 | 350 | %ifarch %{ix86} |
58422b0a | 351 | %ifarch athlon |
d0c7b0ef | 352 | --arch=athlon \ |
58422b0a ER |
353 | %else |
354 | --cpu=i386 --tune=pentium4 \ | |
58422b0a | 355 | %endif |
c0517663 ER |
356 | %endif |
357 | %ifarch %{x8664} | |
d0c7b0ef | 358 | --arch=x86_64 \ |
c0517663 | 359 | %endif |
32b3b293 | 360 | %{?with_mmx:--enable-mmx} \ |
8afae0cb | 361 | %endif |
ac180387 | 362 | %{?with_dvb:--enable-dvb --dvb-path=%{_includedir}} \ |
eceeddea ER |
363 | --%{?with_arts:en}%{!?with_arts:dis}able-audio-arts \ |
364 | --%{?with_alsa:en}%{!?with_alsa:dis}able-audio-alsa \ | |
365 | --%{?with_oss:en}%{!?with_oss:dis}able-audio-oss \ | |
6c269db6 | 366 | --%{?with_jack:en}%{!?with_jack:dis}able-audio-jack \ |
c79fdf07 | 367 | --%{?with_opengl:en}%{!?with_opengl:dis}able-opengl-vsync \ |
eceeddea | 368 | --%{?with_lirc:en}%{!?with_lirc:dis}able-lirc \ |
cb059bf8 | 369 | --%{?with_firewire:en}%{!?with_firewire:dis}able-firewire \ |
bc34ab39 ER |
370 | --%{?with_xrandr:en}%{!?with_xrandr:dis}able-xrandr \ |
371 | --%{?with_xvmc:en}%{!?with_xvmc:dis}able-xvmc \ | |
cb059bf8 ER |
372 | --enable-xv \ |
373 | --enable-x11 \ | |
96b717a5 | 374 | |
448e41b0 ER |
375 | qmake mythtv.pro \ |
376 | QTDIR="%{_prefix}" \ | |
377 | QMAKE_LIBDIR_X11=%{?_x_libraries}%{!?_x_libraries:%{_libdir}} | |
378 | ||
3c3d6f2b | 379 | %{__make} \ |
ac180387 | 380 | QTDIR="%{_prefix}" \ |
3c3d6f2b | 381 | QMAKE=$(pwd)/qmake-wrapper.sh |
8afae0cb | 382 | |
8afae0cb ER |
383 | %install |
384 | rm -rf $RPM_BUILD_ROOT | |
2dcbef41 | 385 | install -d $RPM_BUILD_ROOT/etc/{logrotate.d,sysconfig} \ |
2aaa3ce4 | 386 | $RPM_BUILD_ROOT{/etc/rc.d/init.d,%{_desktopdir}} \ |
4cd4742b ER |
387 | $RPM_BUILD_ROOT/var/{cache,lib,log,run}/mythtv \ |
388 | $RPM_BUILD_ROOT%{_libdir}/mythtv/plugins | |
eceeddea | 389 | |
a3ec4ed6 | 390 | export QTDIR="%{_prefix}" |
eceeddea ER |
391 | %{__make} install \ |
392 | INSTALL_ROOT=$RPM_BUILD_ROOT | |
393 | ||
8afae0cb | 394 | # Install the files that we added on top of mythtv's own stuff |
4cd4742b ER |
395 | install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/mythbackend |
396 | install %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/mythbackend | |
2dcbef41 | 397 | install %{SOURCE1} $RPM_BUILD_ROOT/etc/sysconfig/mythbackend |
4cd4742b ER |
398 | |
399 | # desktop entries | |
4cd4742b | 400 | install %{SOURCE5} $RPM_BUILD_ROOT%{_desktopdir} |
8afae0cb ER |
401 | |
402 | # Install settings.pro so people can see the build options we used | |
68d88cbd ER |
403 | install -d $RPM_BUILD_ROOT%{_datadir}/mythtv/build |
404 | install config.mak settings.pro $RPM_BUILD_ROOT%{_datadir}/mythtv/build | |
8afae0cb | 405 | |
96b717a5 ER |
406 | for p in mythfrontend; do |
407 | for l in $RPM_BUILD_ROOT%{_datadir}/mythtv/i18n/${p}_*.qm; do | |
408 | echo $l | sed -e "s,^$RPM_BUILD_ROOT\(.*${p}_\(.*\).qm\),%%lang(\2) \1," | |
409 | done > $p.lang | |
410 | done | |
411 | ||
412 | # glibc language codes. attempt was made to change it on libmyth side, | |
413 | # but that was just asking for trouble due large coverage of | |
414 | # language.lower() usage. | |
415 | sed -i -e ' | |
416 | s,%%lang(en_gb),%%lang(en_GB), | |
417 | s,%%lang(zh_tw),%%lang(zh_TW), | |
418 | s,%%lang(pt_br),%%lang(pt_BR), | |
419 | ' *.lang | |
420 | ||
421 | rm -rf mythtvosd mythwelcome mythlcdserver | |
99d50505 | 422 | install -d mythtvosd mythwelcome |
96b717a5 ER |
423 | cp -a programs/mythtvosd/{README,*.xml} mythtvosd |
424 | cp -a programs/mythwelcome/README mythwelcome | |
425 | cp -a programs/mythlcdserver/README mythlcdserver | |
426 | ||
8afae0cb ER |
427 | %clean |
428 | rm -rf $RPM_BUILD_ROOT | |
429 | ||
ed630fed | 430 | %pre backend |
5eccad13 | 431 | %groupadd -g 149 %{name} |
cb059bf8 ER |
432 | %useradd -u 149 -d /var/lib/mythtv -g %{name} -c "MythTV User" %{name} |
433 | %addusertogroup %{name} video | |
434 | %addusertogroup %{name} audio | |
435 | ||
436 | %post backend | |
68d88cbd | 437 | /sbin/chkconfig --add mythbackend |
cb059bf8 ER |
438 | |
439 | %preun backend | |
440 | if [ "$1" = "0" ]; then | |
441 | %service -q mythbackend stop | |
442 | /sbin/chkconfig --del mythbackend | |
443 | fi | |
8afae0cb | 444 | |
ed630fed | 445 | %postun backend |
a3eedc29 ER |
446 | if [ "$1" = "0" ]; then |
447 | %userremove %{name} | |
448 | %groupremove %{name} | |
449 | fi | |
8afae0cb | 450 | |
ed630fed JB |
451 | %post -n libmyth -p /sbin/ldconfig |
452 | %postun -n libmyth -p /sbin/ldconfig | |
453 | ||
6e738c98 | 454 | %post setup |
cb059bf8 | 455 | if [ "$1" = 1 ]; then |
6e738c98 ER |
456 | %banner -e %{name}-setup <<EOF |
457 | To grant mysql permissions to mythtv, please run | |
458 | zcat %{_docdir}/%{name}-setup-%{version}/database/mc.sql.gz | mysql | |
459 | EOF | |
cb059bf8 | 460 | fi |
6e738c98 | 461 | |
8afae0cb | 462 | %files |
910a00e3 | 463 | %defattr(644,root,root,755) |
2b07fa66 | 464 | %doc README* UPGRADING AUTHORS FAQ |
ac180387 | 465 | #%doc docs contrib configfiles |
96b717a5 | 466 | %doc keys.txt mythtvosd mythwelcome mythlcdserver |
8afae0cb ER |
467 | |
468 | %files backend | |
910a00e3 | 469 | %defattr(644,root,root,755) |
96b717a5 ER |
470 | %attr(755,root,root) %{_sbindir}/mythbackend |
471 | %attr(755,root,root) %{_sbindir}/mythcommflag | |
910a00e3 | 472 | %attr(755,root,root) %{_bindir}/mythfilldatabase |
96b717a5 ER |
473 | %attr(755,root,root) %{_sbindir}/mythjobqueue |
474 | %attr(755,root,root) %{_sbindir}/mythlcdserver | |
475 | %attr(755,root,root) %{_bindir}/mythtranscode | |
f1992461 | 476 | %attr(755,root,root) %{_bindir}/mythreplex |
cb059bf8 ER |
477 | %attr(775,root,mythtv) %dir /var/lib/mythtv |
478 | %attr(775,root,mythtv) %dir /var/cache/mythtv | |
479 | %attr(775,root,mythtv) %dir /var/run/mythtv | |
a3eedc29 | 480 | %attr(754,root,root) /etc/rc.d/init.d/mythbackend |
96b717a5 ER |
481 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/mythbackend |
482 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/mythbackend | |
cb059bf8 | 483 | %attr(775,root,mythtv) %dir %{_localstatedir}/log/mythtv |
8afae0cb | 484 | |
96b717a5 | 485 | %files frontend -f mythfrontend.lang |
910a00e3 | 486 | %defattr(644,root,root,755) |
a3ec4ed6 | 487 | %attr(755,root,root) %{_bindir}/mythfrontend |
96b717a5 | 488 | %attr(755,root,root) %{_bindir}/mythshutdown |
910a00e3 | 489 | %attr(755,root,root) %{_bindir}/mythtv |
910a00e3 | 490 | %attr(755,root,root) %{_bindir}/mythtvosd |
96b717a5 ER |
491 | %attr(755,root,root) %{_bindir}/mythwelcome |
492 | %dir %{_datadir}/mythtv | |
bbba3c1d | 493 | %dir %{_datadir}/mythtv/themes |
96b717a5 ER |
494 | %dir %{_libdir}/mythtv |
495 | %{_datadir}/mythtv/*.xml | |
cb059bf8 ER |
496 | %dir %{_libdir}/mythtv/filters |
497 | %dir %{_libdir}/mythtv/plugins | |
498 | %attr(755,root,root) %{_libdir}/mythtv/filters/*.so | |
8afae0cb | 499 | %{_datadir}/mythtv/*.ttf |
96b717a5 | 500 | %dir %{_datadir}/mythtv/i18n |
2aaa3ce4 | 501 | %{_desktopdir}/*.desktop |
8afae0cb | 502 | |
ed630fed JB |
503 | %files setup |
504 | %defattr(644,root,root,755) | |
6e738c98 | 505 | %doc database |
b9307635 | 506 | %attr(755,root,root) %{_bindir}/mythtv-setup |
ed630fed | 507 | |
8afae0cb | 508 | %files themes |
910a00e3 | 509 | %defattr(644,root,root,755) |
bbba3c1d | 510 | %{_datadir}/mythtv/themes/* |
8afae0cb ER |
511 | |
512 | %files -n libmyth | |
910a00e3 | 513 | %defattr(644,root,root,755) |
a7691716 | 514 | %attr(755,root,root) %{_libdir}/lib*.so.*.*.* |
8afae0cb ER |
515 | |
516 | %files -n libmyth-devel | |
910a00e3 | 517 | %defattr(644,root,root,755) |
910a00e3 | 518 | %attr(755,root,root) %{_libdir}/*.so |
ed630fed | 519 | %{_includedir}/* |
68d88cbd | 520 | %{_datadir}/mythtv/build |
a7691716 ER |
521 | |
522 | %files -n libmyth-static | |
523 | %defattr(644,root,root,755) |