diff --git a/www/yt-dlp/Makefile b/www/yt-dlp/Makefile index a27bd05f3715..6593ed147ac6 100644 --- a/www/yt-dlp/Makefile +++ b/www/yt-dlp/Makefile @@ -1,45 +1,44 @@ PORTNAME= yt-dlp -DISTVERSION= 2022.04.08 -PORTREVISION= 1 +DISTVERSION= 2022.05.18 CATEGORIES= www MAINTAINER= yuri@FreeBSD.org COMMENT= Command-line program for downloading videos from various platforms LICENSE= UNLICENSE LICENSE_FILE= ${WRKSRC}/LICENSE PY_DEPENDS= ${PYTHON_PKGNAMEPREFIX}brotli>0:archivers/py-brotli@${PY_FLAVOR} \ ${PYTHON_PKGNAMEPREFIX}certifi>0:security/py-certifi@${PY_FLAVOR} \ ${PYTHON_PKGNAMEPREFIX}mutagen>0:audio/py-mutagen@${PY_FLAVOR} \ ${PYTHON_PKGNAMEPREFIX}pycryptodomex>0:security/py-pycryptodomex@${PY_FLAVOR} \ ${PYTHON_PKGNAMEPREFIX}sqlite3>0:databases/py-sqlite3@${PY_FLAVOR} \ ${PYTHON_PKGNAMEPREFIX}websockets>0:devel/py-websockets@${PY_FLAVOR} BUILD_DEPENDS= ${PY_DEPENDS} RUN_DEPENDS= ${PY_DEPENDS} USES= gmake python:3.7+ shebangfix SHEBANG_GLOB= devscripts/*.py USE_GITHUB= yes MAKE_ARGS= PYTHON=${PYTHON_CMD} NO_ARCH= yes OPTIONS_DEFINE= FFMPEG RTMPDUMP SYMLINK OPTIONS_DEFAULT= FFMPEG RTMPDUMP SYMLINK OPTIONS_SUB= yes FFMPEG_RUN_DEPENDS= ffprobe:multimedia/ffmpeg RTMPDUMP_DESC= Use rtmpdump to download rtmp video streams RTMPDUMP_RUN_DEPENDS= rtmpdump:multimedia/rtmpdump SYMLINK_DESC= Install youtube-dl symbolic link for executable SYMLINK_CONFLICTS= youtube_dl post-install-SYMLINK-on: @${RLN} ${STAGEDIR}${PREFIX}/bin/yt-dlp ${STAGEDIR}${PREFIX}/bin/youtube-dl .include diff --git a/www/yt-dlp/distinfo b/www/yt-dlp/distinfo index 33215a014b55..49b3c3de5ee8 100644 --- a/www/yt-dlp/distinfo +++ b/www/yt-dlp/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1649428848 -SHA256 (yt-dlp-yt-dlp-2022.04.08_GH0.tar.gz) = 0e427a4df804787e1543a0ca42436564f0122d7a38b8712089ebd31cce39c224 -SIZE (yt-dlp-yt-dlp-2022.04.08_GH0.tar.gz) = 2037140 +TIMESTAMP = 1652847318 +SHA256 (yt-dlp-yt-dlp-2022.05.18_GH0.tar.gz) = 6bb20a8afd5d4449fbb1bc7032854eb285defc1e46337df0942852e2d26d18f5 +SIZE (yt-dlp-yt-dlp-2022.05.18_GH0.tar.gz) = 2034054 diff --git a/www/yt-dlp/files/patch-Makefile b/www/yt-dlp/files/patch-Makefile index 1baed35e2811..6040544260bd 100644 --- a/www/yt-dlp/files/patch-Makefile +++ b/www/yt-dlp/files/patch-Makefile @@ -1,108 +1,100 @@ ---- Makefile.orig 2022-01-21 11:57:11 UTC +--- Makefile.orig 2022-05-18 03:37:32 UTC +++ Makefile @@ -1,15 +1,15 @@ -all: lazy-extractors yt-dlp doc pypi-files -clean: clean-test clean-dist +#all: lazy-extractors yt-dlp doc pypi-files +all: lazy-extractors yt-dlp clean-all: clean clean-cache completions: completion-bash completion-fish completion-zsh -doc: README.md CONTRIBUTING.md issuetemplates supportedsites +#doc: README.md CONTRIBUTING.md issuetemplates supportedsites ot: offlinetest tar: yt-dlp.tar.gz # 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: AUTHORS 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 -@@ -37,17 +37,23 @@ SHAREDIR ?= $(PREFIX)/share +@@ -39,16 +39,17 @@ SHAREDIR ?= $(PREFIX)/share PYTHON ?= /usr/bin/env python3 # set SYSCONFDIR to /etc if PREFIX=/usr or PREFIX=/usr/local -SYSCONFDIR = $(shell if [ $(PREFIX) = /usr -o $(PREFIX) = /usr/local ]; then echo /etc; else echo $(PREFIX)/etc; fi) +#SYSCONFDIR = $(shell if [ $(PREFIX) = /usr -o $(PREFIX) = /usr/local ]; then echo /etc; else echo $(PREFIX)/etc; fi) +SYSCONFDIR = $(PREFIX)/etc # set markdown input format to "markdown-smart" for pandoc version 2 and to "markdown" for pandoc prior to version 2 - MARKDOWN = $(shell if [ `pandoc -v | head -n1 | cut -d" " -f2 | head -c1` = "2" ]; then echo markdown-smart; else echo markdown; fi) + MARKDOWN = $(shell if [ "$(pandoc -v | head -n1 | cut -d" " -f2 | head -c1)" = "2" ]; then echo markdown-smart; else echo markdown; fi) -install: lazy-extractors yt-dlp yt-dlp.1 completions +install: lazy-extractors yt-dlp completions - install -Dm755 yt-dlp $(DESTDIR)$(BINDIR)/yt-dlp -- install -Dm644 yt-dlp.1 $(DESTDIR)$(MANDIR)/man1/yt-dlp.1 -- install -Dm644 completions/bash/yt-dlp $(DESTDIR)$(SHAREDIR)/bash-completion/completions/yt-dlp -+# install -Dm644 yt-dlp.1 $(DESTDIR)$(MANDIR)/man1/yt-dlp.1 -+# install -Dm644 completions/bash/yt-dlp $(DESTDIR)$(SHAREDIR)/bash-completion/completions/yt-dlp -+ mkdir -p $(DESTDIR)$(SYSCONFDIR)/bash_completion.d -+ install -Dm644 completions/bash/yt-dlp $(DESTDIR)$(SYSCONFDIR)/bash_completion.d/yt-dlp -+ mkdir -p $(DESTDIR)$(SHAREDIR)/zsh/site-functions - install -Dm644 completions/zsh/_yt-dlp $(DESTDIR)$(SHAREDIR)/zsh/site-functions/_yt-dlp -- install -Dm644 completions/fish/yt-dlp.fish $(DESTDIR)$(SHAREDIR)/fish/vendor_completions.d/yt-dlp.fish -+# install -Dm644 completions/fish/yt-dlp.fish $(DESTDIR)$(SHAREDIR)/fish/vendor_completions.d/yt-dlp.fish -+ mkdir -p $(DESTDIR)$(SYSCONFDIR)/fish/completions -+ install -Dm644 completions/fish/yt-dlp.fish $(DESTDIR)$(SYSCONFDIR)/fish/completions/yt-dlp.fish - - codetest: - flake8 . -@@ -67,37 +73,38 @@ yt-dlp: yt_dlp/*.py yt_dlp/*/*.py + mkdir -p $(DESTDIR)$(BINDIR) + install -m755 yt-dlp $(DESTDIR)$(BINDIR)/yt-dlp + mkdir -p $(DESTDIR)$(MANDIR)/man1 +- install -m644 yt-dlp.1 $(DESTDIR)$(MANDIR)/man1/yt-dlp.1 ++ #install -m644 yt-dlp.1 $(DESTDIR)$(MANDIR)/man1/yt-dlp.1 + mkdir -p $(DESTDIR)$(SHAREDIR)/bash-completion/completions + install -m644 completions/bash/yt-dlp $(DESTDIR)$(SHAREDIR)/bash-completion/completions/yt-dlp + mkdir -p $(DESTDIR)$(SHAREDIR)/zsh/site-functions +@@ -84,37 +85,38 @@ yt-dlp: yt_dlp/*.py yt_dlp/*/*.py done - touch -t 200001010101 zip/yt_dlp/*.py zip/yt_dlp/*/*.py + touch -t 200001010101 zip/yt_dlp/*.py zip/yt_dlp/*/*.py zip/yt_dlp/*/*/*.py mv zip/yt_dlp/__main__.py zip/ -- cd zip ; zip -q ../yt-dlp yt_dlp/*.py yt_dlp/*/*.py __main__.py -+# cd zip ; zip -q ../yt-dlp yt_dlp/*.py yt_dlp/*/*.py __main__.py +- cd zip ; zip -q ../yt-dlp yt_dlp/*.py yt_dlp/*/*.py yt_dlp/*/*/*.py __main__.py ++ #cd zip ; zip -q ../yt-dlp yt_dlp/*.py yt_dlp/*/*.py yt_dlp/*/*/*.py __main__.py + cd zip ; bsdtar -a -cf ../yt-dlp.zip yt_dlp/*.py yt_dlp/*/*.py __main__.py rm -rf zip echo '#!$(PYTHON)' > yt-dlp cat yt-dlp.zip >> yt-dlp rm yt-dlp.zip chmod a+x yt-dlp -README.md: yt_dlp/*.py yt_dlp/*/*.py - COLUMNS=80 $(PYTHON) yt_dlp/__main__.py --help | $(PYTHON) devscripts/make_readme.py +#README.md: yt_dlp/*.py yt_dlp/*/*.py +# COLUMNS=80 $(PYTHON) yt_dlp/__main__.py --help | $(PYTHON) devscripts/make_readme.py -CONTRIBUTING.md: README.md - $(PYTHON) devscripts/make_contributing.py README.md CONTRIBUTING.md +#CONTRIBUTING.md: README.md +# $(PYTHON) devscripts/make_contributing.py README.md CONTRIBUTING.md -issuetemplates: devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/1_broken_site.yml .github/ISSUE_TEMPLATE_tmpl/2_site_support_request.yml .github/ISSUE_TEMPLATE_tmpl/3_site_feature_request.yml .github/ISSUE_TEMPLATE_tmpl/4_bug_report.yml .github/ISSUE_TEMPLATE_tmpl/5_feature_request.yml yt_dlp/version.py - $(PYTHON) devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/1_broken_site.yml .github/ISSUE_TEMPLATE/1_broken_site.yml - $(PYTHON) devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/2_site_support_request.yml .github/ISSUE_TEMPLATE/2_site_support_request.yml - $(PYTHON) devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/3_site_feature_request.yml .github/ISSUE_TEMPLATE/3_site_feature_request.yml - $(PYTHON) devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/4_bug_report.yml .github/ISSUE_TEMPLATE/4_bug_report.yml - $(PYTHON) devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/5_feature_request.yml .github/ISSUE_TEMPLATE/5_feature_request.yml - $(PYTHON) devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/6_question.yml .github/ISSUE_TEMPLATE/6_question.yml +#issuetemplates: devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/1_broken_site.yml .github/ISSUE_TEMPLATE_tmpl/2_site_support_request.yml .github/ISSUE_TEMPLATE_tmpl/3_site_feature_request.yml .github/ISSUE_TEMPLATE_tmpl/4_bug_report.yml .github/ISSUE_TEMPLATE_tmpl/5_feature_request.yml yt_dlp/version.py +# $(PYTHON) devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/1_broken_site.yml .github/ISSUE_TEMPLATE/1_broken_site.yml +# $(PYTHON) devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/2_site_support_request.yml .github/ISSUE_TEMPLATE/2_site_support_request.yml +# $(PYTHON) devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/3_site_feature_request.yml .github/ISSUE_TEMPLATE/3_site_feature_request.yml +# $(PYTHON) devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/4_bug_report.yml .github/ISSUE_TEMPLATE/4_bug_report.yml +# $(PYTHON) devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/5_feature_request.yml .github/ISSUE_TEMPLATE/5_feature_request.yml +# $(PYTHON) devscripts/make_issue_template.py .github/ISSUE_TEMPLATE_tmpl/6_question.yml .github/ISSUE_TEMPLATE/6_question.yml supportedsites: $(PYTHON) devscripts/make_supportedsites.py supportedsites.md -README.txt: README.md - pandoc -f $(MARKDOWN) -t plain README.md -o README.txt +#README.txt: README.md +# pandoc -f $(MARKDOWN) -t plain README.md -o README.txt -yt-dlp.1: README.md - $(PYTHON) devscripts/prepare_manpage.py yt-dlp.1.temp.md - pandoc -s -f $(MARKDOWN) -t man yt-dlp.1.temp.md -o yt-dlp.1 - rm -f yt-dlp.1.temp.md +#yt-dlp.1: README.md +# $(PYTHON) devscripts/prepare_manpage.py yt-dlp.1.temp.md +# pandoc -s -f $(MARKDOWN) -t man yt-dlp.1.temp.md -o yt-dlp.1 +# rm -f yt-dlp.1.temp.md completions/bash/yt-dlp: yt_dlp/*.py yt_dlp/*/*.py devscripts/bash-completion.in mkdir -p completions/bash diff --git a/www/yt-dlp/files/patch-yt__dlp_cookies.py b/www/yt-dlp/files/patch-yt__dlp_cookies.py index b9562230e38b..e298f7b0c119 100644 --- a/www/yt-dlp/files/patch-yt__dlp_cookies.py +++ b/www/yt-dlp/files/patch-yt__dlp_cookies.py @@ -1,11 +1,11 @@ ---- yt_dlp/cookies.py.orig 2022-05-14 11:34:22.365323000 -0400 -+++ yt_dlp/cookies.py 2022-05-14 11:34:52.544340000 -0400 -@@ -140,7 +140,7 @@ +--- yt_dlp/cookies.py.orig 2022-05-18 03:37:32 UTC ++++ yt_dlp/cookies.py +@@ -156,7 +156,7 @@ def _extract_firefox_cookies(profile, logger): def _firefox_browser_dir(): - if sys.platform in ('linux', 'linux2'): + if sys.platform in ('linux', 'linux2','freebsd13','freebsd14'): return os.path.expanduser('~/.mozilla/firefox') elif sys.platform == 'win32': - return os.path.expandvars(r'%APPDATA%\Mozilla\Firefox\Profiles') + return os.path.expandvars(R'%APPDATA%\Mozilla\Firefox\Profiles') diff --git a/www/yt-dlp/files/patch-yt__dlp_options.py b/www/yt-dlp/files/patch-yt__dlp_options.py index 00a8b6fe81f6..7adce2d76943 100644 --- a/www/yt-dlp/files/patch-yt__dlp_options.py +++ b/www/yt-dlp/files/patch-yt__dlp_options.py @@ -1,13 +1,13 @@ --- yt_dlp/options.py.orig 2021-10-22 20:47:18 UTC +++ yt_dlp/options.py @@ -203,10 +203,6 @@ def parseOpts(overrideArguments=None): action='version', help='Print program version and exit') 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='Update this program to latest version') - general.add_option( '-i', '--ignore-errors', action='store_true', dest='ignoreerrors', help='Ignore download and postprocessing errors. The download will be considered successfull even if the postprocessing fails') diff --git a/www/yt-dlp/pkg-plist b/www/yt-dlp/pkg-plist index 8401d1199c9d..5e7fcfe4e75d 100644 --- a/www/yt-dlp/pkg-plist +++ b/www/yt-dlp/pkg-plist @@ -1,5 +1,5 @@ %%SYMLINK%%bin/youtube-dl bin/yt-dlp -etc/bash_completion.d/yt-dlp -etc/fish/completions/yt-dlp.fish +share/bash-completion/completions/yt-dlp +share/fish/vendor_completions.d/yt-dlp.fish share/zsh/site-functions/_yt-dlp