]> git.pld-linux.org Git - packages/mythtv.git/blob - mythtv.spec
- added to CVS, based on ATrpms src.rpm:
[packages/mythtv.git] / mythtv.spec
1 #
2 # Specfile for MythTV
3 #
4 #  MythTV now uses a fairly intelligent cpu-detection script, so if you are
5 #  building an rpm by hand on the machine it will be used on, I encourage you
6 #  to use "--with cpu_autodetect" to let mythtv decide for you.
7 #
8
9 # The name of the DVB driver package (used in a couple of places,
10 # so it's not hard-coded in the spec itself)
11 %define linuxtv_dvb_package linuxtv-dvb-1.1.1
12
13 # Set up some custom-build parameters
14 %bcond_with     lirc
15 %bcond_without alsa
16 %bcond_without oss
17 %bcond_with opengl_vsync
18 %bcond_with arts
19 %bcond_with xvmc
20 %bcond_with cpu_autodetect # enable cpu autodetection at compile time
21
22 Name:           mythtv
23 Version:        0.17
24 #define _snap 20050326
25 Release:        0.2
26 Summary:        A personal video recorder (PVR) application.
27 Group:          Applications/Multimedia
28 License:        GPL v2
29 URL:            http://www.mythtv.org/
30 Source0:        http://www.mythtv.org/mc/%{name}-%{version}.tar.bz2
31 # Source0-md5:  c996dc690d36e946396fc5cd4b715e3b
32 Source1:        mythbackend.sysconfig
33 Source2:        mythbackend.init
34 Source3:        mythbackend.logrotate
35 Source12:       http://linuxtv.org/download/dvb/%{linuxtv_dvb_package}.tar.bz2
36 Patch0:         %{name}-configure.patch
37 # Source12-md5: 6dd599f24b7abecd1e32c203eaa7fa8a
38 ExclusiveArch:  i386 i686 athlon x86_64
39 Requires(post): /sbin/ldconfig
40 Requires(postun):       /sbin/ldconfig
41 BuildRequires:  gcc-c++
42 BuildRequires:  XFree86-devel
43 BuildRequires:  freetype-devel >= 1:2.0.0
44 BuildRequires:  lame-libs-devel
45 BuildRequires:  qt-devel >= 6:3.2.1-4
46 BuildRequires:  qmake >= 6:3.2.1-4
47 BuildRequires:  mysql-devel
48 BuildRequires:  desktop-file-utils
49 %if %{with alsa}
50 BuildRequires:  alsa-lib-devel
51 %endif
52 %if %{with lirc}
53 BuildRequires:  lirc-devel
54 %endif
55 %if %{with arts}
56 BuildRequires:  arts-devel >= 13:0.9.5
57 %endif
58 %if %{with xvmc}
59 BuildRequires:  nvidia-graphics-devel
60 %endif
61 %if %{with opengl_vsync}
62 BuildRequires:  nvidia-graphics-devel
63 %endif
64 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
65
66 %description
67 MythTV implements the following PVR features, and more, with a unified
68 graphical interface:
69
70  - Basic 'live-tv' functionality. Pause/Fast Forward/Rewind "live" TV.
71  - Video compression using RTjpeg or MPEG-4
72  - Program listing retrieval using XMLTV
73  - Themable, semi-transparent on-screen display
74  - Electronic program guide
75  - Scheduled recording of TV programs
76  - Resolution of conflicts between scheduled recordings
77  - Basic video editing
78
79 %package -n libmyth
80 Summary:        Library providing mythtv support.
81 Group:          Libraries
82 Requires:       freetype >= 1:2.0.0
83 Requires:       lame
84 Requires:       qt >= 6:3.2.1-4
85 Requires:       qt-plugin-mysql >= 6:3.2.1-4
86
87 %description -n libmyth
88 Common library code for MythTV and add-on modules (development) MythTV
89 provides a unified graphical interface for recording and viewing
90 television programs. Refer to the mythtv package for more information.
91
92 %package -n libmyth-devel
93 Summary:        Development files for libmyth.
94 Group:          Development/Libraries
95 Requires:       libmyth = %{version}-%{release}
96 BuildRequires:  freetype-devel >= 1:2.0.0
97 BuildRequires:  lame-libs-devel
98 BuildRequires:  qt-devel >= 6:3.2.1-4
99 BuildRequires:  mysql-devel
100 BuildRequires:  DirectFB-devel
101 %if %{with alsa}
102 BuildRequires:  alsa-lib-devel
103 %endif
104 %if %{with lirc}
105 BuildRequires:  lirc-devel
106 %endif
107 %if %{with arts}
108 BuildRequires:  arts-devel >= 13:0.9.5
109 %endif
110
111 %description -n libmyth-devel
112 This package contains the header files and libraries for developing
113 add-ons for mythtv.
114
115 %package -n libmyth-static
116 Summary:        Static libmyth library
117 Group:          Development/Libraries
118 Requires:       lib%{name}-devel = %{version}-%{release}
119
120 %description -n libmyth-static
121 Static libmyth library.
122
123 %package themes
124 Summary:        Base themes for mythtv's frontend.
125 Group:          Applications/Multimedia
126 Obsoletes:      mythtv-theme-Titivillus
127
128 %description themes
129 MythTV provides a unified graphical interface for recording and
130 viewing television programs. Refer to the mythtv package for more
131 information.
132
133 This package contains only the base themes used by the frontend and
134 mythtvsetup.
135
136 %package frontend
137 Summary:        Client component of mythtv (a PVR).
138 Group:          Applications/Multimedia
139 Requires:       mythtv = %{version}-%{release}
140 Requires:       mythtv-themes = %{version}-%{release}
141 Provides:       mythtv-frontend-api = %(echo %{version} | cut -d. -f1,2)
142
143 %description frontend
144 MythTV provides a unified graphical interface for recording and
145 viewing television programs. Refer to the mythtv package for more
146 information.
147
148 This package contains only the client software, which provides a
149 front-end for playback and configuration. It requires access to a
150 mythtv-backend installation, either on the same system or one
151 reachable via the network.
152
153 %package backend
154 Summary:        Server component of mythtv (a PVR).
155 Group:          Applications/Multimedia
156 Conflicts:      xmltv-grabbers < 0.5.34
157 Requires:       mythtv = %{version}-%{release}
158
159 %description backend
160 MythTV provides a unified graphical interface for recording and
161 viewing television programs. Refer to the mythtv package for more
162 information.
163
164 This package contains only the server software, which provides video
165 and audio capture and encoding services. In order to be useful, it
166 requires a mythtv-frontend installation, either on the same system or
167 one reachable via the network.
168
169 %package setup
170 Summary:        Setup the mythtv backend.
171 Group:          Applications/Multimedia
172 Requires:       mythtv-backend = %{version}-%{release}
173 Requires:       mythtv-themes = %{version}-%{release}
174 Provides:       mythtvsetup
175
176 %description setup
177 MythTV provides a unified graphical interface for recording and
178 viewing television programs. Refer to the mythtv package for more
179 information.
180
181 This package contains only the setup software for configuring the
182 mythtv backend.
183
184 %prep
185 %setup -q -a 12
186 %patch0 -p1
187
188 %build
189 export QTDIR="%{_prefix}"
190 #export QMAKESPEC="linux-g++"
191
192 # Initialize the options string
193 OPTS=""
194
195
196 # Finally, actually configure
197
198 # BTW: this is not autoconf configure
199 %configure \
200     --compile-type=%{?debug:debug}%{!?debug:release} \
201     --disable-audio-jack \
202     --enable-dvb \
203     --dvb-path=%{_builddir}/%{name}-%{version}/%{linuxtv_dvb_package}/linux/include \
204 %if %{with cpu_autodetect}
205     %ifarch i386
206                 --cpu=i386 --tune=pentium4 --enable-mmx \
207     %endif
208     %ifarch i686
209         --cpu=i686 --tune=pentium4 --enable-mmx \
210     %endif
211     %ifarch athlon
212         --arch=athlon \
213     %endif
214     %ifarch x86_64
215         --arch=x86_64 \
216     %endif
217 %endif
218         --%{?with_arts:en}%{!?with_arts:dis}able-audio-arts \
219         --%{?with_alsa:en}%{!?with_alsa:dis}able-audio-alsa \
220         --%{?with_oss:en}%{!?with_oss:dis}able-audio-oss \
221         --%{?with_opengl_vsync:en}%{!?with_openvl_vsync:dis}able-opengl-vsync \
222         --%{?with_lirc:en}%{!?with_lirc:dis}able-lirc \
223         %{?with_xvmc:--enable-xvmc --enable-xvmc-vld} \
224         %{!?with_xvmc:--disable-xvmc --disable-xvmc-vld} \
225 #  --disable-joystick-menu \
226 #  --disable-firewire \
227 #  --disable-ivtv \
228 #  --enable-dvb-eit \
229
230 #sed -i -e 's:OPTFLAGS=.*:OPTFLAGS=%{rpmcflags} -Wno-switch:g' config.mak
231
232 # MythTV doesn't support parallel builds
233 qmake -o Makefile mythtv.pro \
234     QMAKE_CXX="%{__cxx}" \
235     QMAKE_LINK="%{__cxx}" \
236     QMAKE_CXXFLAGS_RELEASE="%{rpmcflags}"
237
238 %{__make} qmake
239
240 # We don't want rpm to add perl requirements to anything in contrib
241 find contrib -type f | xargs -r chmod a-x
242
243 %install
244 rm -rf $RPM_BUILD_ROOT
245 install -d $RPM_BUILD_ROOT
246
247 %{__make} install \
248         INSTALL_ROOT=$RPM_BUILD_ROOT
249
250 mv $RPM_BUILD_ROOT{/usr/local/bin,%{_bindir}}
251 mv $RPM_BUILD_ROOT{/usr/local/include,%{_includedir}}
252 mv $RPM_BUILD_ROOT{/usr/local/share,%{_datadir}}
253 mv $RPM_BUILD_ROOT{/usr/local/lib,%{_libdir}}
254
255 # Install the files that we added on top of mythtv's own stuff
256 install -pD %{SOURCE2} $RPM_BUILD_ROOT%{_initrddir}/mythbackend
257 install -pD %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/mythbackend
258 install -pD %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/mythbackend
259
260 # Desktop entries
261 #mkdir -p %{buildroot}%{_datadir}/pixmaps
262 #mkdir -p %{buildroot}%{_datadir}/applications
263 #for file in %{desktop_applications}; do
264 #  install -p %{_sourcedir}/$file.png %{buildroot}%{_datadir}/pixmaps/$file.png
265 #  desktop-file-install --vendor %{desktop_vendor} \
266 #    --dir %{buildroot}%{_datadir}/applications    \
267 #    --add-category X-Red-Hat-Extra                \
268 #    --add-category Application                    \
269 #    --add-category AudioVideo                     \
270 #    %{_sourcedir}/$file.desktop
271 #done
272
273 # Various utility directories that we want rpm to keep track of mythtv ownership
274 install -d $RPM_BUILD_ROOT/var/lib/mythtv
275 install -d $RPM_BUILD_ROOT/var/lib/cache/mythtv
276 install -d $RPM_BUILD_ROOT%{_localstatedir}/log/mythtv
277 install -d $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d
278 install -d $RPM_BUILD_ROOT%{_initrddir}
279 install -d $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig
280
281 # Create the plugins directory, so rpm can know mythtv owns it
282 install -d $RPM_BUILD_ROOT%{_libdir}/mythtv/plugins
283
284 # Install settings.pro so people can see the build options we used
285 install -pD settings.pro $RPM_BUILD_ROOT%{_datadir}/mythtv/build/settings.pro
286
287 %clean
288 rm -rf $RPM_BUILD_ROOT
289
290 # ldconfig's for packages that install %{_libdir}/*.so.*
291 # -> Don't forget Requires(post) and Requires(postun): /sbin/ldconfig
292 # ...and install-info's for ones that install %{_infodir}/*.info*
293 # -> Don't forget Requires(post) and Requires(preun): /sbin/install-info
294
295 %post   -p /sbin/ldconfig
296 %postun -p /sbin/ldconfig
297
298 %files
299 %defattr(644,root,root,755)
300 %doc README* UPGRADING AUTHORS COPYING FAQ
301 %doc database keys.txt
302 %doc docs contrib configfiles
303
304 %files backend
305 %defattr(644,root,root,755)
306 #%attr(755,root,root) %{_bindir}/mythbackend # MISSING
307 %attr(755,root,root) %{_bindir}/mythfilldatabase
308 %attr(755,root,root) %{_bindir}/mythjobqueue
309 %attr(-,mythtv,mythtv) %dir /var/lib/mythtv
310 %attr(-,mythtv,mythtv) %dir /var/lib/cache/mythtv
311 %{_initrddir}/mythbackend
312 %config %{_sysconfdir}/sysconfig/mythbackend
313 %config /etc/logrotate.d/mythbackend
314 %attr(-,mythtv,mythtv) %dir %{_localstatedir}/log/mythtv
315
316 %files setup
317 %defattr(644,root,root,755)
318 #%attr(755,root,root) %{_bindir}/mythtv-setup MISSING
319
320 %files frontend
321 %defattr(644,root,root,755)
322 %{_datadir}/mythtv/*.xml
323 #%attr(755,root,root) %{_bindir}/mythfrontend # MISSING
324 %attr(755,root,root) %{_bindir}/mythtv
325 %attr(755,root,root) %{_bindir}/mythepg
326 %attr(755,root,root) %{_bindir}/mythprogfind
327 %attr(755,root,root) %{_bindir}/mythcommflag
328 %attr(755,root,root) %{_bindir}/mythtranscode
329 %attr(755,root,root) %{_bindir}/mythtvosd
330 %{_libdir}/mythtv/filters
331 %{_libdir}/mythtv/plugins
332 %{_datadir}/mythtv/*.ttf
333 %{_datadir}/mythtv/i18n
334 #%{_datadir}/applications/*myth*.desktop
335 #%{_datadir}/pixmaps/myth*.png
336
337 %files themes
338 %defattr(644,root,root,755)
339 %{_datadir}/mythtv/themes
340
341 %files -n libmyth
342 %defattr(644,root,root,755)
343 %attr(755,root,root) %{_libdir}/lib*.so.*.*.*
344
345 %files -n libmyth-devel
346 %defattr(644,root,root,755)
347 %{_includedir}/*
348 %attr(755,root,root) %{_libdir}/*.so
349 %{_datadir}/mythtv/build/settings.pro
350
351 %files -n libmyth-static
352 %defattr(644,root,root,755)
353 %{_libdir}/lib*.a
This page took 0.093819 seconds and 3 git commands to generate.