SUMMARY="A command-line program to download videos from various sites" DESCRIPTION="The program is usually invoked as youtube-dl followed by \ options and the video URL. Run 'youtube-dl --help' and get a summary \ of all options. Some YouTube videos are served using Adobe's proprietary RTMP protocol, which \ imposes DRM restrictions and encrypts the connection. youtube-dl is not able \ to download these videos by itself." HOMEPAGE="https://ytdl-org.github.io/youtube-dl/index.html https://github.com/ytdl-org/youtube-dl" COPYRIGHT="2006-2021 youtube-dl contributors" LICENSE="Unlicense" REVISION="5" SOURCE_URI="https://github.com/ytdl-org/youtube-dl/releases/download/$portVersion/youtube-dl-$portVersion.tar.gz" CHECKSUM_SHA256="9f3b99c8b778455165b4525f21505e86c7ff565f3ac319e19733d810194135df" SOURCE_DIR="youtube-dl" ARCHITECTURES="any" pythonVersion=3.10 pythonPackage=python${pythonVersion//.} PROVIDES=" youtube_dl = $portVersion cmd:youtube_dl = $portVersion " REQUIRES=" haiku ffmpeg6_tools cmd:python$pythonVersion " # This recipe was previously built as if it was just a regular Python package recipe, # and not as a CLI program that targets a particular Python version. REPLACES=" youtube_dl_python310 " BUILD_REQUIRES=" haiku_devel setuptools_$pythonPackage " BUILD_PREREQUIRES=" cmd:find cmd:make cmd:python$pythonVersion cmd:zip " INSTALL() { python=python$pythonVersion installLocation="$prefix"/lib/$python/vendor-packages/ export PYTHONPATH="$installLocation" mkdir -p "$installLocation" $python setup.py build install --root=/ --prefix="$prefix" # Install shell completions: install -d $dataDir/bash-completion/completions cp youtube-dl.bash-completion $dataDir/bash-completion/completions/youtube-dl install -d $dataDir/fish cp youtube-dl.fish $dataDir/fish/ install -d $dataDir/zsh/site-functions cp youtube-dl.zsh $dataDir/zsh/site-functions/_youtube-dl # Install man page and Readme: mkdir -p $docDir $manDir mv $prefix/share/man/man1 $manDir mv $prefix/share/doc/youtube_dl/README.txt $docDir # Remove left over cruft: rm -rf $prefix/etc rm -rf $prefix/share } TEST() { # Will fail because flake8 is not available make offlinetest }