1 |
commit: a9f434f613b2c031adcc77b569baf05db6ef02af |
2 |
Author: Pacho Ramos <pacho <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sat Oct 20 14:47:11 2018 +0000 |
4 |
Commit: Pacho Ramos <pacho <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Oct 20 16:35:30 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a9f434f6 |
7 |
|
8 |
media-tv/mythtv: Bump to 29.1 |
9 |
|
10 |
Thanks-to: Preston Crow |
11 |
Thanks-to: Tom Dexter |
12 |
Closes: https://bugs.gentoo.org/645850 |
13 |
Closes: https://bugs.gentoo.org/649044 |
14 |
Closes: https://bugs.gentoo.org/658534 |
15 |
Closes: https://bugs.gentoo.org/665182 |
16 |
Signed-off-by: Pacho Ramos <pacho <AT> gentoo.org> |
17 |
Package-Manager: Portage-2.3.51, Repoman-2.3.11 |
18 |
|
19 |
media-tv/mythtv/Manifest | 1 + |
20 |
media-tv/mythtv/mythtv-29.1.ebuild | 369 +++++++++++++++++++++++++++++++++++++ |
21 |
2 files changed, 370 insertions(+) |
22 |
|
23 |
diff --git a/media-tv/mythtv/Manifest b/media-tv/mythtv/Manifest |
24 |
index 27c08fa4e7e..ea26a778e4d 100644 |
25 |
--- a/media-tv/mythtv/Manifest |
26 |
+++ b/media-tv/mythtv/Manifest |
27 |
@@ -1 +1,2 @@ |
28 |
DIST mythtv-0.28.1.tar.gz 104477892 BLAKE2B bdecfc5723ec3495ab6e49c72caaa5c2dc62c75a11ce7524d3fd5cb8daec82b53b415591b6198eab00322bbbcaff2de7d4f1b7a165d449007f4c3742a69d304b SHA512 67a81858cd19b90f519113b234119ecc248366d8545c862d887755f256cddf04d9ca16a7bf67f63e06f7628730e7dbde2a2099ca8aaeb9061b2e55a5a0b7d5e7 |
29 |
+DIST mythtv-29.1.tar.gz 105656634 BLAKE2B 8b9dfc6b1e1178bfd1b35e8d499afe570edeb1f07cefa64fc91c2ed74f8155f5ca00cee49a024848f715c0bb782fc22f3c4d04fd8eac8562d108e105d3a41421 SHA512 c80d84c40c019d093d44487fb4cd07d9ce3174781ff8f24a4709fd10294cb8f6186b3e480dad3a09f7a496835fa0cffcc9eca114f807794b693ffcd57acd4e39 |
30 |
|
31 |
diff --git a/media-tv/mythtv/mythtv-29.1.ebuild b/media-tv/mythtv/mythtv-29.1.ebuild |
32 |
new file mode 100644 |
33 |
index 00000000000..ac2b67ef92b |
34 |
--- /dev/null |
35 |
+++ b/media-tv/mythtv/mythtv-29.1.ebuild |
36 |
@@ -0,0 +1,369 @@ |
37 |
+# Copyright 1999-2018 Gentoo Authors |
38 |
+# Distributed under the terms of the GNU General Public License v2 |
39 |
+ |
40 |
+EAPI=6 |
41 |
+PYTHON_COMPAT=( python2_7 ) |
42 |
+ |
43 |
+# git diff --relative=mythtv v0.27.6.. > ~/mythtv-0.27.6/patches/mythtv.patch |
44 |
+BACKPORTS="d8a2db77f5731cf32c6d31127452391c6cf7f91f" |
45 |
+MY_P=${P%_p*} |
46 |
+MY_PV=${PV%_p*} |
47 |
+ |
48 |
+inherit flag-o-matic python-single-r1 qmake-utils user readme.gentoo-r1 systemd vcs-snapshot |
49 |
+ |
50 |
+MYTHTV_BRANCH="fixes/29" |
51 |
+ |
52 |
+DESCRIPTION="Homebrew PVR project" |
53 |
+HOMEPAGE="https://www.mythtv.org" |
54 |
+SRC_URI="https://github.com/MythTV/mythtv/archive/${BACKPORTS}.tar.gz -> ${PF}.tar.gz" |
55 |
+ |
56 |
+LICENSE="GPL-2" |
57 |
+KEYWORDS="~amd64 ~x86" |
58 |
+SLOT="0/${PV}" |
59 |
+ |
60 |
+IUSE_INPUT_DEVICES="input_devices_joystick" |
61 |
+IUSE="alsa altivec autostart bluray cec crystalhd debug dvb dvd egl fftw +hls \ |
62 |
+ ieee1394 jack lcd libass lirc mythlogserver perl pulseaudio python systemd +theora \ |
63 |
+ vaapi vdpau +vorbis +wrapper +xml xmltv +xvid zeroconf ${IUSE_INPUT_DEVICES}" |
64 |
+REQUIRED_USE="${PYTHON_REQUIRED_USE} |
65 |
+ bluray? ( xml ) |
66 |
+ theora? ( vorbis ) |
67 |
+" |
68 |
+ |
69 |
+COMMON=" |
70 |
+ dev-libs/glib:2 |
71 |
+ dev-qt/qtcore:5 |
72 |
+ dev-qt/qtdbus:5 |
73 |
+ dev-qt/qtgui:5 |
74 |
+ dev-qt/qtnetwork:5 |
75 |
+ dev-qt/qtscript:5 |
76 |
+ dev-qt/qtsql:5[mysql] |
77 |
+ dev-qt/qtopengl:5 |
78 |
+ dev-qt/qtwebkit:5 |
79 |
+ dev-qt/qtwidgets:5 |
80 |
+ dev-qt/qtxml:5 |
81 |
+ media-gfx/exiv2:= |
82 |
+ media-libs/freetype:2 |
83 |
+ media-libs/taglib |
84 |
+ >=media-sound/lame-3.93.1 |
85 |
+ sys-libs/zlib |
86 |
+ virtual/mysql |
87 |
+ virtual/opengl |
88 |
+ x11-libs/libX11 |
89 |
+ x11-libs/libXext |
90 |
+ x11-libs/libXinerama |
91 |
+ x11-libs/libXv |
92 |
+ x11-libs/libXrandr |
93 |
+ x11-libs/libXxf86vm |
94 |
+ x11-misc/wmctrl |
95 |
+ alsa? ( >=media-libs/alsa-lib-1.0.24 ) |
96 |
+ bluray? ( |
97 |
+ dev-libs/libcdio:= |
98 |
+ media-libs/libbluray:= |
99 |
+ sys-fs/udisks:2 |
100 |
+ ) |
101 |
+ cec? ( dev-libs/libcec ) |
102 |
+ dvb? ( |
103 |
+ virtual/linuxtv-dvb-headers |
104 |
+ ) |
105 |
+ dvd? ( |
106 |
+ dev-libs/libcdio:= |
107 |
+ sys-fs/udisks:2 |
108 |
+ ) |
109 |
+ egl? ( media-libs/mesa[egl] ) |
110 |
+ fftw? ( sci-libs/fftw:3.0= ) |
111 |
+ hls? ( |
112 |
+ <media-libs/libvpx-1.7.0:= |
113 |
+ >=media-libs/x264-0.0.20111220:= |
114 |
+ ) |
115 |
+ ieee1394? ( |
116 |
+ >=media-libs/libiec61883-1.0.0 |
117 |
+ >=sys-libs/libavc1394-0.5.3 |
118 |
+ >=sys-libs/libraw1394-1.2.0 |
119 |
+ ) |
120 |
+ jack? ( media-sound/jack-audio-connection-kit ) |
121 |
+ lcd? ( app-misc/lcdproc ) |
122 |
+ libass? ( >=media-libs/libass-0.9.11:= ) |
123 |
+ lirc? ( app-misc/lirc ) |
124 |
+ perl? ( |
125 |
+ >=dev-perl/libwww-perl-5 |
126 |
+ dev-perl/DBD-mysql |
127 |
+ dev-perl/HTTP-Message |
128 |
+ dev-perl/IO-Socket-INET6 |
129 |
+ dev-perl/LWP-Protocol-https |
130 |
+ dev-perl/Net-UPnP |
131 |
+ ) |
132 |
+ pulseaudio? ( media-sound/pulseaudio ) |
133 |
+ python? ( |
134 |
+ ${PYTHON_DEPS} |
135 |
+ dev-python/lxml |
136 |
+ dev-python/mysql-python |
137 |
+ dev-python/urlgrabber |
138 |
+ dev-python/future |
139 |
+ dev-python/requests-cache |
140 |
+ ) |
141 |
+ systemd? ( sys-apps/systemd:= ) |
142 |
+ theora? ( media-libs/libtheora media-libs/libogg ) |
143 |
+ vaapi? ( x11-libs/libva:=[opengl] ) |
144 |
+ vdpau? ( x11-libs/libvdpau ) |
145 |
+ vorbis? ( >=media-libs/libvorbis-1.0 media-libs/libogg ) |
146 |
+ xml? ( >=dev-libs/libxml2-2.6.0 ) |
147 |
+ xvid? ( >=media-libs/xvid-1.1.0 ) |
148 |
+ zeroconf? ( |
149 |
+ dev-libs/openssl:0= |
150 |
+ net-dns/avahi[mdnsresponder-compat] |
151 |
+ ) |
152 |
+" |
153 |
+RDEPEND="${COMMON} |
154 |
+ !media-tv/mythtv-bindings |
155 |
+ !x11-themes/mythtv-themes |
156 |
+ media-fonts/corefonts |
157 |
+ media-fonts/dejavu |
158 |
+ media-fonts/liberation-fonts |
159 |
+ x11-apps/xinit |
160 |
+ autostart? ( |
161 |
+ net-dialup/mingetty |
162 |
+ x11-apps/xset |
163 |
+ x11-wm/evilwm |
164 |
+ ) |
165 |
+ dvd? ( media-libs/libdvdcss ) |
166 |
+ xmltv? ( >=media-tv/xmltv-0.5.43 ) |
167 |
+" |
168 |
+DEPEND="${COMMON} |
169 |
+ dev-lang/yasm |
170 |
+ virtual/pkgconfig |
171 |
+ x11-base/xorg-proto |
172 |
+" |
173 |
+ |
174 |
+S="${WORKDIR}/${PF}/mythtv" |
175 |
+ |
176 |
+DISABLE_AUTOFORMATTING="yes" |
177 |
+DOC_CONTENTS=" |
178 |
+To have this machine operate as recording host for MythTV, |
179 |
+mythbackend must be running. Run the following: |
180 |
+rc-update add mythbackend default |
181 |
+ |
182 |
+Your recordings folder must be owned 'mythtv'. e.g. |
183 |
+chown -R mythtv /var/lib/mythtv |
184 |
+ |
185 |
+Want mythfrontend to start automatically? |
186 |
+Set USE=autostart. Details can be found at: |
187 |
+https://dev.gentoo.org/~cardoe/mythtv/autostart.html |
188 |
+ |
189 |
+Note that the systemd unit now restarts by default and logs |
190 |
+to journald via the console at the notice verbosity. |
191 |
+" |
192 |
+ |
193 |
+MYTHTV_GROUPS="video,audio,tty,uucp" |
194 |
+ |
195 |
+pkg_setup() { |
196 |
+ python-single-r1_pkg_setup |
197 |
+ enewuser mythtv -1 /bin/bash /home/mythtv ${MYTHTV_GROUPS} |
198 |
+ usermod -a -G ${MYTHTV_GROUPS} mythtv |
199 |
+} |
200 |
+ |
201 |
+src_prepare() { |
202 |
+ default |
203 |
+ |
204 |
+ # Perl bits need to go into vender_perl and not site_perl |
205 |
+ sed -e "s:pure_install:pure_install INSTALLDIRS=vendor:" \ |
206 |
+ -i "${S}"/bindings/perl/Makefile |
207 |
+ |
208 |
+ # Fix up the version info since we are using the fixes/${PV} branch |
209 |
+ echo "SOURCE_VERSION=\"v${MY_PV}\"" > "${S}"/VERSION |
210 |
+ echo "BRANCH=\"${MYTHTV_BRANCH}\"" >> "${S}"/VERSION |
211 |
+ echo "SOURCE_VERSION=\"${BACKPORTS}\"" > "${S}"/EXPORTED_VERSION |
212 |
+ echo "BRANCH=\"${MYTHTV_BRANCH}\"" >> "${S}"/EXPORTED_VERSION |
213 |
+ |
214 |
+ echo "setting.extra -= -ldconfig" >> "${S}"/programs/mythfrontend/mythfrontend.pro |
215 |
+} |
216 |
+ |
217 |
+src_configure() { |
218 |
+ local myconf= |
219 |
+ |
220 |
+ # Setup paths |
221 |
+ myconf="${myconf} --prefix=${EPREFIX}/usr" |
222 |
+ myconf="${myconf} --libdir=${EPREFIX}/usr/$(get_libdir)" |
223 |
+ myconf="${myconf} --libdir-name=$(get_libdir)" |
224 |
+ myconf="${myconf} --mandir=${EPREFIX}/usr/share/man" |
225 |
+ |
226 |
+ # Audio |
227 |
+ myconf="${myconf} $(use_enable alsa audio-alsa)" |
228 |
+ myconf="${myconf} $(use_enable jack audio-jack)" |
229 |
+ use pulseaudio || myconf="${myconf} --disable-audio-pulseoutput" |
230 |
+ |
231 |
+ use altivec || myconf="${myconf} --disable-altivec" |
232 |
+ myconf="${myconf} $(use_enable dvb)" |
233 |
+ myconf="${myconf} $(use_enable ieee1394 firewire)" |
234 |
+ myconf="${myconf} $(use_enable lirc)" |
235 |
+ myconf="${myconf} $(use_enable xvid libxvid)" |
236 |
+ myconf="${myconf} --dvb-path=/usr/include" |
237 |
+ myconf="${myconf} --enable-xrandr" |
238 |
+ myconf="${myconf} --enable-xv" |
239 |
+ myconf="${myconf} --enable-x11" |
240 |
+ myconf="${myconf} --enable-nonfree" |
241 |
+ use cec || myconf="${myconf} --disable-libcec" |
242 |
+ use zeroconf || myconf="${myconf} --disable-libdns-sd" |
243 |
+ myconf="${myconf} $(use_enable theora libtheora)" |
244 |
+ myconf="${myconf} $(use_enable vorbis libvorbis)" |
245 |
+ |
246 |
+ if use hls; then |
247 |
+ myconf="${myconf} --enable-libx264" |
248 |
+ myconf="${myconf} --enable-libvpx" |
249 |
+ fi |
250 |
+ |
251 |
+ myconf="${myconf} $(use_enable libass)" |
252 |
+ |
253 |
+ if use perl && use python; then |
254 |
+ myconf="${myconf} --with-bindings=perl,python" |
255 |
+ elif use perl; then |
256 |
+ myconf="${myconf} --without-bindings=python" |
257 |
+ myconf="${myconf} --with-bindings=perl" |
258 |
+ elif use python; then |
259 |
+ myconf="${myconf} --without-bindings=perl" |
260 |
+ myconf="${myconf} --with-bindings=python" |
261 |
+ else |
262 |
+ myconf="${myconf} --without-bindings=perl,python" |
263 |
+ fi |
264 |
+ |
265 |
+ use python && myconf="${myconf} --python=${EPYTHON}" |
266 |
+ |
267 |
+ if use debug; then |
268 |
+ myconf="${myconf} --compile-type=debug" |
269 |
+ else |
270 |
+ myconf="${myconf} --compile-type=release" |
271 |
+ #myconf="${myconf} --enable-debug" does nothing per sphery |
272 |
+ myconf="${myconf} --disable-stripping" # FIXME: does not disable for all files, only for some |
273 |
+ fi |
274 |
+ |
275 |
+ # Video |
276 |
+ myconf="${myconf} $(use_enable vdpau)" |
277 |
+ myconf="${myconf} $(use_enable vaapi)" |
278 |
+ myconf="${myconf} $(use_enable crystalhd)" |
279 |
+ |
280 |
+ # Input |
281 |
+ use input_devices_joystick || myconf="${myconf} --disable-joystick-menu" |
282 |
+ |
283 |
+ # Clean up DSO load times and other compiler bits |
284 |
+ myconf="${myconf} --enable-symbol-visibility" |
285 |
+ myconf="${myconf} --enable-pic" |
286 |
+ |
287 |
+ # CPU settings |
288 |
+ for i in $(get-flag march) $(get-flag mcpu) $(get-flag mtune) ; do |
289 |
+ [ "${i}" = "native" ] && i="host" |
290 |
+ myconf="${myconf} --cpu=${i}" |
291 |
+ break |
292 |
+ done |
293 |
+ |
294 |
+ if tc-is-cross-compiler ; then |
295 |
+ myconf="${myconf} --enable-cross-compile --arch=$(tc-arch-kernel)" |
296 |
+ myconf="${myconf} --cross-prefix=${CHOST}-" |
297 |
+ fi |
298 |
+ |
299 |
+ # Build boosters |
300 |
+ has distcc ${FEATURES} || myconf="${myconf} --disable-distcc" |
301 |
+ has ccache ${FEATURES} || myconf="${myconf} --disable-ccache" |
302 |
+ |
303 |
+ myconf="${myconf} $(use_enable systemd systemd_notify)" |
304 |
+ myconf="${myconf} $(use_enable systemd systemd_journal)" |
305 |
+ use systemd || myconf="${myconf} $(use_enable mythlogserver)" |
306 |
+ |
307 |
+ chmod +x ./external/FFmpeg/version.sh |
308 |
+ |
309 |
+ einfo "Running ./configure ${myconf}" |
310 |
+ ./configure \ |
311 |
+ --cc="$(tc-getCC)" \ |
312 |
+ --cxx="$(tc-getCXX)" \ |
313 |
+ --ar="$(tc-getAR)" \ |
314 |
+ --extra-cflags="${CFLAGS}" \ |
315 |
+ --extra-cxxflags="${CXXFLAGS}" \ |
316 |
+ --extra-ldflags="${LDFLAGS}" \ |
317 |
+ --qmake=$(qt5_get_bindir)/qmake \ |
318 |
+ ${myconf} || die "configure died" |
319 |
+} |
320 |
+ |
321 |
+src_install() { |
322 |
+ emake STRIP="true" INSTALL_ROOT="${D}" install |
323 |
+ dodoc AUTHORS UPGRADING README |
324 |
+ readme.gentoo_create_doc |
325 |
+ |
326 |
+ insinto /usr/share/mythtv/database |
327 |
+ doins database/* |
328 |
+ |
329 |
+ newinitd "${FILESDIR}"/mythbackend.init-r2 mythbackend |
330 |
+ newconfd "${FILESDIR}"/mythbackend.conf-r1 mythbackend |
331 |
+ systemd_newunit "${FILESDIR}"/mythbackend.service-28 mythbackend.service |
332 |
+ |
333 |
+ dodoc keys.txt |
334 |
+ |
335 |
+ keepdir /etc/mythtv |
336 |
+ chown -R mythtv "${ED}"/etc/mythtv |
337 |
+ keepdir /var/log/mythtv |
338 |
+ chown -R mythtv "${ED}"/var/log/mythtv |
339 |
+ dodir /var/log/mythtv/old |
340 |
+ |
341 |
+ insinto /etc/logrotate.d |
342 |
+ newins "${FILESDIR}"/mythtv.logrotate.d-r4 mythtv |
343 |
+ |
344 |
+ insinto /usr/share/mythtv/contrib |
345 |
+ # Ensure we don't install scripts needing the perl bindings (bug #516968) |
346 |
+ use perl || find contrib/ -name '*.pl' -exec rm -f {} \; |
347 |
+ # Ensure we don't install scripts needing the python bindings (bug #516968) |
348 |
+ use python || find contrib/ -name '*.py' -exec rm -f {} \; |
349 |
+ doins -r contrib/* |
350 |
+ |
351 |
+ # Install our mythfrontend wrapper which is similar to Mythbuntu's |
352 |
+ if use wrapper; then |
353 |
+ mv "${ED}/usr/bin/mythfrontend" "${ED}/usr/bin/mythfrontend.real" |
354 |
+ newbin "${FILESDIR}"/mythfrontend.wrapper mythfrontend |
355 |
+ newconfd "${FILESDIR}"/mythfrontend.conf mythfrontend |
356 |
+ fi |
357 |
+ |
358 |
+ if use autostart; then |
359 |
+ dodir /etc/env.d/ |
360 |
+ echo 'CONFIG_PROTECT="/home/mythtv/"' > "${ED}"/etc/env.d/95mythtv |
361 |
+ |
362 |
+ insinto /home/mythtv |
363 |
+ newins "${FILESDIR}"/bash_profile .bash_profile |
364 |
+ newins "${FILESDIR}"/xinitrc-r1 .xinitrc |
365 |
+ fi |
366 |
+ |
367 |
+ # Make Python files executable |
368 |
+ find "${ED}/usr/share/mythtv" -type f -name '*.py' | while read file; do |
369 |
+ if [[ ! "${file##*/}" = "__init__.py" ]]; then |
370 |
+ chmod a+x "${file}" |
371 |
+ fi |
372 |
+ done |
373 |
+ |
374 |
+ # Ensure that Python scripts are executed by Python 2 |
375 |
+ python_fix_shebang "${ED}/usr/share/mythtv" |
376 |
+ |
377 |
+ # Make shell & perl scripts executable |
378 |
+ find "${ED}" -type f -name '*.sh' -o -type f -name '*.pl' | \ |
379 |
+ while read file; do |
380 |
+ chmod a+x "${file}" |
381 |
+ done |
382 |
+ |
383 |
+ # Remove empty dir |
384 |
+ rmdir "${ED}"/var/log/mythtv/old |
385 |
+} |
386 |
+ |
387 |
+pkg_preinst() { |
388 |
+ export CONFIG_PROTECT="${CONFIG_PROTECT} ${EROOT}/home/mythtv/" |
389 |
+} |
390 |
+ |
391 |
+pkg_postinst() { |
392 |
+ readme.gentoo_print_elog |
393 |
+} |
394 |
+ |
395 |
+pkg_info() { |
396 |
+ if [[ -f "${EROOT}"/usr/bin/mythfrontend ]]; then |
397 |
+ "${EROOT}"/usr/bin/mythfrontend --version |
398 |
+ fi |
399 |
+} |
400 |
+ |
401 |
+pkg_config() { |
402 |
+ echo "Creating mythtv MySQL user and mythconverg database if it does not" |
403 |
+ echo "already exist. You will be prompted for your MySQL root password." |
404 |
+ "${EROOT}"/usr/bin/mysql -u root -p < "${EROOT}"/usr/share/mythtv/database/mc.sql |
405 |
+} |