diff options
author | V3n3RiX <venerix@koprulu.sector> | 2021-12-22 14:08:05 +0000 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2021-12-22 14:08:05 +0000 |
commit | 93a93e9a3b53c1a73142a305ea1f8136846942ee (patch) | |
tree | b9791a06ab3284e27b568412c59316c66240c682 /media-video/vidify | |
parent | 2771f79232c273bc2a57d23bf335dd81ccf6af28 (diff) |
gentoo resync : 22.12.2021
Diffstat (limited to 'media-video/vidify')
-rw-r--r-- | media-video/vidify/Manifest | 4 | ||||
-rw-r--r-- | media-video/vidify/files/vidify-2.2.6-python310.patch | 16 | ||||
-rw-r--r-- | media-video/vidify/files/vidify-2.2.6-yt-dlp.patch | 122 | ||||
-rw-r--r-- | media-video/vidify/vidify-2.2.6-r2.ebuild (renamed from media-video/vidify/vidify-2.2.6.ebuild) | 12 |
4 files changed, 150 insertions, 4 deletions
diff --git a/media-video/vidify/Manifest b/media-video/vidify/Manifest index 8b1ba7975e05..5adbc042437d 100644 --- a/media-video/vidify/Manifest +++ b/media-video/vidify/Manifest @@ -1,3 +1,5 @@ +AUX vidify-2.2.6-python310.patch 743 BLAKE2B 143ae6532398038da83cf08fc95f25338cabd35f02213336b3e7e54944c2a49b1fd831a7d8ded957305b2b2a292f5bcfc64fb290888029c4859ce8f002db9809 SHA512 63b24e30e1159455411cf1aeaa8c2d2d88db6fa7c08536fb8cf95401c2f23ad68d2d67efdc8fc92d9decb3e2541154fb083a44aba1ba15f526333ff46a3bdf8a +AUX vidify-2.2.6-yt-dlp.patch 4669 BLAKE2B 04f1c80702a495f732e617c5a1ad51a70dcaed82e9650c4ab21844d2aadeb58893889c575ed141fd9e8b8e2353f24b234217b1b9fad83d1b1d2b9e5f87e90474 SHA512 4ff0ca2d2c9999dae5b90abdd9554f8808b30b263a74f099d21c1de001736d1040e53e2ab55607fe6b0807ac4fbffb81cf10935f1419055a9ac136188ef90d84 DIST vidify-2.2.6.tar.gz 2906511 BLAKE2B 3df48ca57e102f664852e2fc2abeb3d19427673e1fec5144a8c0afda112a0f3b281b18db43b4326244266d6e9dfbcb2443319ddad3f864098a61bd1e3c966307 SHA512 15487ee9dcbe647b2b287bd2eb3c09962b557320313a9a3885fb3c0d6af945909531111d5297c1a5fb5b451af5df6fd968b3953bbf79af113980ed368a5674b5 -EBUILD vidify-2.2.6.ebuild 2304 BLAKE2B 791c43c4bf1bdd168ceafcc26e3b7646f7a23b87ec5eb61447d81475fae292da5e31b720abd175a90379deed515b5195d36dcd08cb2cc0cef0959c2d656d1021 SHA512 d26e4992414d5dd366b60cc0a79a47e7d0ced8658bacd4e1f76dc122cc64a5fa9a04e459969183ce74d76da6c73dc92cd269a6c427bbb757bd0cd7bb96e4967a +EBUILD vidify-2.2.6-r2.ebuild 2462 BLAKE2B 7579bb1bbcc9504468b147874a324ac3c366ca68c672b9b4f22173a85c80b0f98e73175ec7cdf2d31c6a21c1481ecd72a6e49738d7ec7f7bf0c3a77a772c025a SHA512 b934e7e5f27b22466fd117caad3ed51a85c16d33f814d93f803f494da4d7206c1e04d165087ce6add7bbf335de1a9a07c519bb3a04c413c911fa4ed8d995f746 MISC metadata.xml 792 BLAKE2B b06fd7f4c01b146b8dc6f45f4451ae592f59a7c917be4a315f4500e8a374670262614e500b7498d731e08ffd471b9da5983b22e79e538f67de914f4d43a7300e SHA512 5192430ceb4221ba5a97bd87d1c149d28dbf3613f3fff337b6fabb2b4452302ddd941765e20a3fc2975d74c5207fab728d59bbb7a80fb758ea74a0b391bea04e diff --git a/media-video/vidify/files/vidify-2.2.6-python310.patch b/media-video/vidify/files/vidify-2.2.6-python310.patch new file mode 100644 index 000000000000..4b78ea559333 --- /dev/null +++ b/media-video/vidify/files/vidify-2.2.6-python310.patch @@ -0,0 +1,16 @@ +diff --git a/vidify/player/vlc.py b/vidify/player/vlc.py +index a7c9ec0..cb50f89 100644 +--- a/vidify/player/vlc.py ++++ b/vidify/player/vlc.py +@@ -75,9 +75,9 @@ class VLCPlayer(PlayerBase): + def start_video(self, media: str, is_playing: bool = True) -> None: + logging.info("Starting new video") + if CURRENT_PLATFORM in (Platform.LINUX, Platform.BSD): +- self._player.set_xwindow(self.winId()) ++ self._player.set_xwindow(int(self.winId())) + elif CURRENT_PLATFORM == Platform.WINDOWS: +- self._player.set_hwnd(self.winId()) ++ self._player.set_hwnd(int(self.winId())) + elif CURRENT_PLATFORM == Platform.MACOS: + self._player.set_nsobject(int(self.winId())) + diff --git a/media-video/vidify/files/vidify-2.2.6-yt-dlp.patch b/media-video/vidify/files/vidify-2.2.6-yt-dlp.patch new file mode 100644 index 000000000000..6ce0f836d5fd --- /dev/null +++ b/media-video/vidify/files/vidify-2.2.6-yt-dlp.patch @@ -0,0 +1,122 @@ +diff --git a/README.md b/README.md +index c4ea164..51e65e6 100644 +--- a/README.md ++++ b/README.md +@@ -79,7 +79,7 @@ Audiosync is only available on Linux for now. It's strongly recommended to use M + * FFTW: `libfftw3` on Debian-based distros. + * ffmpeg: `ffmpeg` on most repositories. It must be available on your path. + * pulseaudio: `pulseaudio`, pre-installed on most repos. +-* youtube-dl: this is installed by default with Vidify, but make sure it's available on your path. ++* yt-dlp: this is installed by default with Vidify, but make sure it's available on your path. + + It's also available as [`vidify-audiosync`](https://aur.archlinux.org/packages/vidify-audiosync) on the AUR, and it comes pre-installed in the binaries. + +diff --git a/dev/build_requires.txt b/dev/build_requires.txt +index ed682fd..a8bbc30 100644 +--- a/dev/build_requires.txt ++++ b/dev/build_requires.txt +@@ -14,5 +14,5 @@ QtPy + SwSpotify>=1.1.1; platform_system == "Windows" or platform_system == "Darwin" + tekore < 2.0 + vidify-audiosync == 0.2.* +-youtube-dl ++yt-dlp + zeroconf +diff --git a/dev/snapcraft.yaml b/dev/snapcraft.yaml +index a5446de..00d2aae 100644 +--- a/dev/snapcraft.yaml ++++ b/dev/snapcraft.yaml +@@ -22,7 +22,7 @@ parts: + - python3-pyqt5 + - python3-appdirs + - python3-pydbus +- - youtube-dl ++ - yt-dlp + # Mpv is used by default because it's lighter and works better + # with the audiosync feature. + - libmpv-dev +diff --git a/setup.py b/setup.py +index 3fdb656..9b1c093 100644 +--- a/setup.py ++++ b/setup.py +@@ -19,7 +19,7 @@ install_deps = [ + # Base package + 'QtPy', + 'lyricwikia', +- 'youtube-dl', ++ 'yt-dlp', + 'appdirs', + 'qdarkstyle', + 'dataclasses; python_version<"3.7"', +diff --git a/vidify/player/mpv.py b/vidify/player/mpv.py +index 4b92571..68bd1a5 100644 +--- a/vidify/player/mpv.py ++++ b/vidify/player/mpv.py +@@ -30,7 +30,7 @@ locale.setlocale(locale.LC_NUMERIC, 'C') + + class MpvPlayer(PlayerBase): + # The audio is always muted, which is needed because not all the +- # youtube-dl videos are silent. The keep-open flag stops mpv from closing ++ # yt-dlp videos are silent. The keep-open flag stops mpv from closing + # after the video is over. + DEFAULT_FLAGS = ['mute'] + DEFAULT_ARGS = { +diff --git a/vidify/player/vlc.py b/vidify/player/vlc.py +index 6a0bec7..a7c9ec0 100644 +--- a/vidify/player/vlc.py ++++ b/vidify/player/vlc.py +@@ -31,7 +31,7 @@ class VLCPlayer(PlayerBase): + else: + vlc_args += " --quiet" + # The audio is always muted, which is needed because not all the +- # youtube-dl videos are silent. ++ # yt-dlp videos are silent. + # Needed for the audiosync feature: set the Group of Pictures size to + # one, so that seeking is more precise. + vlc_args += " --no-audio --sout-x264-min-keyint 1" +diff --git a/vidify/youtube.py b/vidify/youtube.py +index 1b23bfb..b959f34 100644 +--- a/vidify/youtube.py ++++ b/vidify/youtube.py +@@ -1,5 +1,5 @@ + """ +-This module uses youtube-dl to obtain the actual URL of a YouTube link. ++This module uses yt-dlp to obtain the actual URL of a YouTube link. + That way, the video can be played directly with a video player like VLC + or mpv. + """ +@@ -7,7 +7,7 @@ or mpv. + import logging + from typing import Optional + +-from youtube_dl import YoutubeDL ++from yt_dlp import YoutubeDL + from qtpy.QtCore import QObject, Signal + + +@@ -63,7 +63,7 @@ class YouTubeDLWorker(QObject): + + def get_url(self) -> None: + """ +- Getting the youtube direct link with youtube-dl, intended to be used ++ Getting the youtube direct link with yt-dlp, intended to be used + with a QThread. It's guaranteed that either a success signal or a + fail signal will be emitted. + """ +@@ -74,13 +74,13 @@ class YouTubeDLWorker(QObject): + except Exception as e: + # Any kind of error has to be caught, so that it doesn't only + # send the error signal when the download wasn't successful +- # (a DownloadError from youtube_dl). +- logging.info("YouTube-dl wasn't able to obtain the video: %s", ++ # (a DownloadError from yt_dlp). ++ logging.info("yt-dlp wasn't able to obtain the video: %s", + str(e)) + self.fail.emit() + else: + if len(data['entries']) == 0: +- logging.info("YouTube-dl returned no entries") ++ logging.info("yt-dlp returned no entries") + self.fail.emit() + else: + self.success.emit(data) diff --git a/media-video/vidify/vidify-2.2.6.ebuild b/media-video/vidify/vidify-2.2.6-r2.ebuild index 94b2caead30c..fe640744473d 100644 --- a/media-video/vidify/vidify-2.2.6.ebuild +++ b/media-video/vidify/vidify-2.2.6-r2.ebuild @@ -1,9 +1,9 @@ # Copyright 1999-2021 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=7 +EAPI=8 -PYTHON_COMPAT=( python3_{7..10} ) +PYTHON_COMPAT=( python3_{8..10} ) inherit xdg distutils-r1 optfeature virtualx @@ -23,7 +23,7 @@ RDEPEND=" dev-python/appdirs[${PYTHON_USEDEP}] dev-python/QtPy[gui,webengine,${PYTHON_USEDEP}] net-misc/lyricwikia[${PYTHON_USEDEP}] - net-misc/youtube-dl[${PYTHON_USEDEP}] + net-misc/yt-dlp[${PYTHON_USEDEP}] dbus? ( dev-python/pydbus[${PYTHON_USEDEP}] ) !dbus? ( dev-python/tekore[${PYTHON_USEDEP}] ) mpv? ( dev-python/python-mpv[${PYTHON_USEDEP}] ) @@ -31,6 +31,12 @@ RDEPEND=" zeroconf? ( dev-python/zeroconf[${PYTHON_USEDEP}] ) " +# use yt-dlp instead of youtube-dl, otherwise download is too slow for playback +PATCHES=( + "${FILESDIR}/${P}-yt-dlp.patch" + "${FILESDIR}/${P}-python310.patch" +) + distutils_enable_tests unittest python_prepare_all() { |