summaryrefslogtreecommitdiff
path: root/yt-dlp/debian/patches
diff options
context:
space:
mode:
authorB. Stack <bgstack15@gmail.com>2021-12-09 15:32:47 -0500
committerB. Stack <bgstack15@gmail.com>2021-12-09 15:32:47 -0500
commit328f444bc77d4323d5eceb93e6d84185322445ba (patch)
treef3e77aacbba7434d363beec3f166e52436d2190d /yt-dlp/debian/patches
parentMerge branch 'irfanview-bump' into 'master' (diff)
downloadstackrpms-yt-dlp-bump.tar.gz
stackrpms-yt-dlp-bump.tar.bz2
stackrpms-yt-dlp-bump.zip
add yt-dlpyt-dlp-bump
Diffstat (limited to 'yt-dlp/debian/patches')
-rw-r--r--yt-dlp/debian/patches/0001-Don-t-install-support-files-via-setup.py.patch25
-rw-r--r--yt-dlp/debian/patches/0002-Disable-upstream-s-autoupdate-mechanism.patch69
-rw-r--r--yt-dlp/debian/patches/0003-Remove-use-of-git.patch19
-rw-r--r--yt-dlp/debian/patches/0004-Skip-directories-and-style-checks-for-flake8.patch24
-rw-r--r--yt-dlp/debian/patches/0005-Makefile-Don-t-run-flake8-when-running-offlinetest.patch25
-rw-r--r--yt-dlp/debian/patches/series5
6 files changed, 167 insertions, 0 deletions
diff --git a/yt-dlp/debian/patches/0001-Don-t-install-support-files-via-setup.py.patch b/yt-dlp/debian/patches/0001-Don-t-install-support-files-via-setup.py.patch
new file mode 100644
index 0000000..4cac87a
--- /dev/null
+++ b/yt-dlp/debian/patches/0001-Don-t-install-support-files-via-setup.py.patch
@@ -0,0 +1,25 @@
+From: Carlos Maddela <e7appew@gmail.com>
+Date: Tue, 1 Mar 2016 02:31:47 +1100
+Subject: Don't install support files via setup.py
+
+Description: Don't install support files via setup.py
+ for better control over where they should be installed.
+Author: Carlos Maddela <e7appew@gmail.com>
+Origin: vendor
+Forwarded: not-needed
+Last-Update: 2016-06-27
+---
+ setup.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/setup.py 2021-10-10 01:09:36.951650937 -0400
++++ b/setup.py 2021-10-10 01:09:36.939651038 -0400
+@@ -59,7 +59,7 @@
+ ('share/bash-completion/completions', ['completions/bash/yt-dlp']),
+ ('share/zsh/site-functions', ['completions/zsh/_yt-dlp']),
+ ('share/fish/vendor_completions.d', ['completions/fish/yt-dlp.fish']),
+- ('share/doc/yt_dlp', ['README.txt']),
++ ('share/doc/yt-dlp', ['README.txt']),
+ ('share/man/man1', ['yt-dlp.1'])
+ ]
+ root = os.path.dirname(os.path.abspath(__file__))
diff --git a/yt-dlp/debian/patches/0002-Disable-upstream-s-autoupdate-mechanism.patch b/yt-dlp/debian/patches/0002-Disable-upstream-s-autoupdate-mechanism.patch
new file mode 100644
index 0000000..968b171
--- /dev/null
+++ b/yt-dlp/debian/patches/0002-Disable-upstream-s-autoupdate-mechanism.patch
@@ -0,0 +1,69 @@
+From: Nicolas Braud-Santoni <nicolas@braud-santoni.eu>
+Date: Fri, 16 Mar 2018 14:17:40 -0300
+Subject: Disable upstream's autoupdate mechanism
+MIME-Version: 1.0
+Content-Type: text/plain; charset="utf-8"
+Content-Transfer-Encoding: 8bit
+
+Description: Remove autoupdate mechanism
+Bug-Debian: https://bugs.debian.org/890119
+Forwarded: not-needed
+Author: Nicolas Braud-Santoni <nicolas@braud-santoni.eu>
+Reviewed-by: Rogério Theodoro de Brito <rbrito@gmail.com>
+Last-Update: 2021-02-13
+---
+ README.md | 3 ---
+ yt_dlp/__init__.py | 11 ++++++-----
+ yt_dlp/options.py | 2 +-
+ 3 files changed, 7 insertions(+), 9 deletions(-)
+
+--- a/README.md 2021-12-01 15:12:20.651056853 -0500
++++ b/README.md 2021-12-01 15:12:20.631057057 -0500
+@@ -289,9 +289,6 @@
+ ## General Options:
+ -h, --help Print this help text and exit
+ --version Print program version and exit
+- -U, --update Update this program to latest version. Make
+- sure that you have sufficient permissions
+- (run with sudo if needed)
+ -i, --ignore-errors Ignore download and postprocessing errors.
+ The download will be considered successful
+ even if the postprocessing fails
+--- a/yt_dlp/__init__.py 2021-12-01 15:12:20.651056853 -0500
++++ b/yt_dlp/__init__.py 2021-12-01 15:12:20.631057057 -0500
+@@ -42,7 +42,6 @@
+ std_headers,
+ write_string,
+ )
+-from .update import run_update
+ from .downloader import (
+ FileDownloader,
+ )
+@@ -791,10 +790,12 @@
+ # Update version
+ if opts.update_self:
+ # If updater returns True, exit. Required for windows
+- if run_update(ydl):
+- if actual_use:
+- sys.exit('ERROR: The program must exit for the update to complete')
+- sys.exit()
++ parser.error(
++ "yt-dlp's self-update mechanism is disabled on Debian.\n"
++ "Please update yt-dlp using apt(8).\n"
++ "See https://packages.debian.org/sid/yt-dlp for the "
++ "latest packaged version.\n"
++ )
+
+ # Maybe do nothing
+ if not actual_use:
+--- a/yt_dlp/options.py 2021-12-01 15:12:20.651056853 -0500
++++ b/yt_dlp/options.py 2021-12-01 15:12:20.635057016 -0500
+@@ -205,7 +205,7 @@
+ general.add_option(
+ '-U', '--update',
+ action='store_true', dest='update_self',
+- help='Update this program to latest version. Make sure that you have sufficient permissions (run with sudo if needed)')
++ help=optparse.SUPPRESS_HELP)
+ general.add_option(
+ '-i', '--ignore-errors',
+ action='store_true', dest='ignoreerrors',
diff --git a/yt-dlp/debian/patches/0003-Remove-use-of-git.patch b/yt-dlp/debian/patches/0003-Remove-use-of-git.patch
new file mode 100644
index 0000000..24b6636
--- /dev/null
+++ b/yt-dlp/debian/patches/0003-Remove-use-of-git.patch
@@ -0,0 +1,19 @@
+Description: Remove use of git during build
+Author: Unit 193 <unit193@debian.org>
+Forwarded: not-needed
+
+---
+ Makefile | 10 ++--------
+ 1 file changed, 2 insertions(+), 8 deletions(-)
+
+--- a/Makefile 2021-09-25 12:27:50.468876774 -0400
++++ b/Makefile 2021-09-25 12:27:50.456876891 -0400
+@@ -8,7 +8,7 @@
+ # Keep this list in sync with MANIFEST.in
+ # intended use: when building a source distribution,
+ # make pypi-files && python setup.py sdist
+-pypi-files: AUTHORS Changelog.md LICENSE README.md README.txt supportedsites completions yt-dlp.1 devscripts/* test/*
++pypi-files: Changelog.md LICENSE README.md README.txt supportedsites completions yt-dlp.1 devscripts/* test/*
+
+ .PHONY: all clean install test tar pypi-files completions ot offlinetest codetest supportedsites
+
diff --git a/yt-dlp/debian/patches/0004-Skip-directories-and-style-checks-for-flake8.patch b/yt-dlp/debian/patches/0004-Skip-directories-and-style-checks-for-flake8.patch
new file mode 100644
index 0000000..a51bd78
--- /dev/null
+++ b/yt-dlp/debian/patches/0004-Skip-directories-and-style-checks-for-flake8.patch
@@ -0,0 +1,24 @@
+From: =?utf-8?q?Rog=C3=A9rio_Theodoro_de_Brito?= <rbrito@gmail.com>
+Date: Sun, 22 Nov 2020 20:05:27 -0300
+Subject: Skip directories and style checks for flake8
+
+Forwarded: no
+Last-Update: 2020-04-10
+---
+ Makefile | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+--- a/Makefile 2021-12-01 15:12:30.374957372 -0500
++++ b/Makefile 2021-12-01 15:12:30.362957495 -0500
+@@ -49,7 +49,10 @@
+ install -Dm644 completions/fish/yt-dlp.fish $(DESTDIR)$(SHAREDIR)/fish/vendor_completions.d/yt-dlp.fish
+
+ codetest:
+- flake8 .
++ flake8 \
++ --exclude=.svn,CVS,.bzr,.hg,.git,__pycache__,.tox,.eggs,*.egg,.pc,.pybuild \
++ --ignore=E121,E123,E126,E226,E24,E704,E402,E501,E731,E741,W503,W504,N802,N803,N806,N816,F401,F821,E302,E305,N801,N815,E265,N813,F403,F405 \
++ .
+
+ test:
+ $(PYTHON) -m pytest
diff --git a/yt-dlp/debian/patches/0005-Makefile-Don-t-run-flake8-when-running-offlinetest.patch b/yt-dlp/debian/patches/0005-Makefile-Don-t-run-flake8-when-running-offlinetest.patch
new file mode 100644
index 0000000..07fbc02
--- /dev/null
+++ b/yt-dlp/debian/patches/0005-Makefile-Don-t-run-flake8-when-running-offlinetest.patch
@@ -0,0 +1,25 @@
+From: =?utf-8?q?Rog=C3=A9rio_Brito?= <rbrito@gmail.com>
+Date: Sun, 22 Nov 2020 20:06:55 -0300
+Subject: Makefile: Don't run flake8 when running offlinetest.
+
+Unfortunately, due to the dynamic nature of python, we most certainly would
+like to run flake8 when testing the package. Alas, flake8 sometimes
+generates style-only warning or "errors" that break the build, in a similar
+fashion to what -Werror does to GCC or other compilers.
+
+Therefore, I'm disabling this.
+---
+ Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/Makefile 2021-12-01 15:12:36.202897749 -0500
++++ b/Makefile 2021-12-01 15:12:36.190897872 -0500
+@@ -58,7 +58,7 @@
+ $(PYTHON) -m pytest
+ $(MAKE) codetest
+
+-offlinetest: codetest
++offlinetest:
+ $(PYTHON) -m pytest -k "not download"
+
+ yt-dlp: yt_dlp/*.py yt_dlp/*/*.py
diff --git a/yt-dlp/debian/patches/series b/yt-dlp/debian/patches/series
new file mode 100644
index 0000000..9369aad
--- /dev/null
+++ b/yt-dlp/debian/patches/series
@@ -0,0 +1,5 @@
+0001-Don-t-install-support-files-via-setup.py.patch
+0002-Disable-upstream-s-autoupdate-mechanism.patch
+0003-Remove-use-of-git.patch
+0004-Skip-directories-and-style-checks-for-flake8.patch
+0005-Makefile-Don-t-run-flake8-when-running-offlinetest.patch
bgstack15