2021-12-28 10:18:23 +01:00
|
|
|
#
|
2021-12-28 11:39:05 +01:00
|
|
|
# spec file for package yt-dlp
|
2021-12-28 10:18:23 +01:00
|
|
|
#
|
2024-03-11 00:38:18 +01:00
|
|
|
# Copyright (c) 2024 SUSE LLC
|
2021-12-28 10:18:23 +01:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
2023-10-25 06:46:46 +02:00
|
|
|
%define skip_python2 1
|
|
|
|
%define skip_python36 1
|
|
|
|
%define skip_python37 1
|
2023-10-25 07:17:16 +02:00
|
|
|
%{?sle15_python_module_pythons}
|
2021-12-28 11:39:05 +01:00
|
|
|
Name: yt-dlp
|
2024-12-12 13:55:16 +01:00
|
|
|
Version: 2024.12.06
|
2021-12-28 10:18:23 +01:00
|
|
|
Release: 0
|
2021-12-28 16:36:33 +01:00
|
|
|
Summary: Enhanced fork of youtube-dl, a video site downloader for offline watching
|
2021-12-28 10:18:23 +01:00
|
|
|
License: CC-BY-SA-3.0 AND SUSE-Public-Domain
|
|
|
|
Group: Productivity/Networking/Web/Utilities
|
|
|
|
URL: https://github.com/yt-dlp/yt-dlp
|
2023-01-06 22:52:12 +01:00
|
|
|
Source: https://github.com/yt-dlp/yt-dlp/releases/download/%version/yt-dlp.tar.gz
|
2024-09-29 21:27:29 +02:00
|
|
|
Source9: yt-dlp-rpmlintrc
|
2024-03-11 00:38:18 +01:00
|
|
|
BuildRequires: %{python_module hatchling}
|
|
|
|
BuildRequires: %{python_module pip}
|
2023-10-25 06:46:46 +02:00
|
|
|
BuildRequires: fdupes
|
2021-12-28 10:18:23 +01:00
|
|
|
BuildRequires: make >= 4
|
2023-10-25 06:05:29 +02:00
|
|
|
BuildRequires: python-rpm-macros
|
2021-12-28 10:18:23 +01:00
|
|
|
BuildRequires: zip
|
|
|
|
BuildArch: noarch
|
2024-08-14 10:56:08 +02:00
|
|
|
Obsoletes: yt-dlp-bash-completion < %version-%release
|
|
|
|
Provides: yt-dlp-bash-completion = %version-%release
|
|
|
|
Obsoletes: yt-dlp-fish-completion < %version-%release
|
|
|
|
Provides: yt-dlp-fish-completion = %version-%release
|
|
|
|
Obsoletes: yt-dlp-zsh-completion < %version-%release
|
|
|
|
Provides: yt-dlp-zsh-completion = %version-%release
|
2023-11-05 11:23:36 +01:00
|
|
|
# %%primary_python not available in Leap yet
|
|
|
|
Requires: %(echo %{python_module yt-dlp} | perl -pe 's{.* }{}g')
|
2023-10-27 09:49:33 +02:00
|
|
|
%define python_subpackage_only 1
|
2023-10-23 00:39:07 +02:00
|
|
|
%python_subpackages
|
2021-12-28 10:18:23 +01:00
|
|
|
|
2021-12-28 11:39:05 +01:00
|
|
|
%description
|
2021-12-28 10:18:23 +01:00
|
|
|
yt-dlp is a command-line program to retrieve videos from
|
|
|
|
YouTube.com and other video sites for later watching.
|
|
|
|
|
2024-08-13 20:42:15 +02:00
|
|
|
%package -n yt-dlp-youtube-dl
|
|
|
|
Summary: Compat symlinks for youtube-dl
|
|
|
|
Requires: yt-dlp
|
|
|
|
Provides: youtube-dl
|
|
|
|
Conflicts: youtube-dl
|
2021-12-28 10:18:23 +01:00
|
|
|
|
2024-08-13 20:42:15 +02:00
|
|
|
%description -n yt-dlp-youtube-dl
|
|
|
|
This package installs "youtube-dl" as a symlink to yt-dlp.
|
2021-12-28 10:18:23 +01:00
|
|
|
|
2023-10-23 00:39:07 +02:00
|
|
|
%package -n python-yt-dlp
|
|
|
|
Summary: yt-dlp Python library
|
|
|
|
Group: Development/Languages/Python
|
2023-10-27 09:49:33 +02:00
|
|
|
Requires: ffmpeg
|
|
|
|
Suggests: python-Brotli
|
|
|
|
Suggests: python-certifi
|
|
|
|
Suggests: python-mutagen
|
|
|
|
Suggests: python-pycryptodomex
|
|
|
|
Suggests: python-websockets
|
2023-10-23 00:39:07 +02:00
|
|
|
|
|
|
|
%description -n python-yt-dlp
|
|
|
|
The direct Python interface into yt-dlp.
|
|
|
|
|
2021-12-28 10:18:23 +01:00
|
|
|
%prep
|
2021-12-28 11:39:05 +01:00
|
|
|
%autosetup -p1 -n %name
|
2021-12-28 10:18:23 +01:00
|
|
|
|
|
|
|
%build
|
|
|
|
rm -f youtube-dl yt-dlp
|
2023-10-25 06:05:29 +02:00
|
|
|
#
|
|
|
|
# A self-decompressing yt-dlp is built only when python_build is not
|
|
|
|
# exercised; else yt-dlp is a loader.
|
|
|
|
#
|
2024-03-11 00:38:18 +01:00
|
|
|
%pyproject_wheel
|
2023-10-25 06:05:29 +02:00
|
|
|
%make_build yt-dlp
|
2021-12-28 10:18:23 +01:00
|
|
|
|
|
|
|
%install
|
|
|
|
b="%buildroot"
|
2024-03-11 00:38:18 +01:00
|
|
|
%pyproject_install
|
2024-08-13 20:42:15 +02:00
|
|
|
ln -s yt-dlp "$b/%_bindir/youtube-dl"
|
2023-10-23 00:39:07 +02:00
|
|
|
rm -Rf "$b/%_datadir/doc"
|
2024-09-29 21:27:29 +02:00
|
|
|
# if you leave everything as-is, rpmlint complains about
|
|
|
|
# python312-yt-dlp.noarch: W: files-duplicate
|
|
|
|
# /usr/lib/python3.12/site-packages/yt_dlp/utils/__pycache__/progress.cpython-312.pyc
|
|
|
|
# /usr/lib/python3.12/site-packages/yt_dlp/utils/__pycache__/progress.cpython-312.opt-1.pyc
|
|
|
|
# if you add fdupes, rpmlint complains about
|
|
|
|
# python312-yt-dlp.noarch: E: python-bytecode-inconsistent-mtime
|
|
|
|
# /usr/lib/python3.12/site-packages/yt_dlp/extractor/__pycache__/screencastomatic.cpython-312.pyc
|
|
|
|
# 2024-09-29T18:11:02
|
|
|
|
# /usr/lib/python3.12/site-packages/yt_dlp/extractor/screencastomatic.py
|
|
|
|
# 2024-09-29T18:11:01
|
2021-12-28 10:18:23 +01:00
|
|
|
|
2023-10-23 00:39:07 +02:00
|
|
|
%files -n yt-dlp
|
2021-12-28 10:18:23 +01:00
|
|
|
%license LICENSE
|
|
|
|
%doc README.md
|
2021-12-28 16:26:47 +01:00
|
|
|
%_bindir/%name
|
|
|
|
%_mandir/man1/%name.1%ext_man
|
2021-12-28 10:18:23 +01:00
|
|
|
%_datadir/bash-completion/
|
|
|
|
%_datadir/fish/
|
|
|
|
%_datadir/zsh/
|
|
|
|
|
2024-08-13 20:42:15 +02:00
|
|
|
%files -n yt-dlp-youtube-dl
|
|
|
|
%_bindir/youtube-dl
|
|
|
|
|
2023-10-27 09:49:33 +02:00
|
|
|
%files %{python_files yt-dlp}
|
2023-10-23 00:39:07 +02:00
|
|
|
%python_sitelib/y*
|
|
|
|
|
2021-12-28 10:18:23 +01:00
|
|
|
%changelog
|