Skip to content

Conversation

@AminurAlam
Copy link
Contributor

yt-dlp will soon have deno, node and bun as runtime dependencies. add two of them which are available in termux repos

previous discussion: #26680

TERMUX_PKG_SHA256=1afacd10ec55e4d18dca1f6398823f8b642b5d1c524913a065985b482b8a73c2
TERMUX_PKG_DEPENDS="libc++, libexpat, openssl, python, python-brotli, python-pip, python-pycryptodomex"
TERMUX_PKG_RECOMMENDS="ffmpeg"
TERMUX_PKG_RECOMMENDS="deno, ffmpeg"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't that be Node OR Deno?

Suggested change
TERMUX_PKG_RECOMMENDS="deno, ffmpeg"
TERMUX_PKG_RECOMMENDS="nodejs | nodejs-lts | deno, ffmpeg"

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know if that will work, but I can test whichever method this PR chooses and report what happens on my 32-bit device.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It should also be noted that the version of yt-dlp that will depend on these things is still a draft in upstream, so it's not yet possible to test the actual runtime behavior of yt-dlp when exposed to these dependencies, without also applying that branch temporarily to the package, and even then, the behavior might be unfinished and not final.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Installing the current version of this PR on my 32-bit device resulted in this printing:

Recommended packages:
  deno

but apt proceeded to not attempt to install deno or mention it at all during the rest of the installation process and no errors happened, so that is as expected, while on a 64-bit device it would automatically install deno, so I believe that just confirms that it is fine to add deno to TERMUX_PKG_RECOMMENDS. I haven't tested what happens if it is changed to nodejs | nodejs-lts | deno, but I can if this PR is changed to that.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we have architecture dependent dependencies on any packages so far.
But in theory we should be able to do a separate TERMUX_PKG_RECOMMENDS for 64 bit and 32 bit architectures if having deno in the list on architectures that it isn't available for would cause issues.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But in theory we should be able to do a separate TERMUX_PKG_RECOMMENDS for 64 bit and 32 bit architectures if having deno in the list on architectures that it isn't available for would cause issues.

I have just tested that and explained that does not appear to cause any issues.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might be "nicer" to not have it there on the 32 bit architectures regardless so it doesn't lead to any potential confusion for users.
i.e "Why can't I install wine on my device, oh it's 32 bit ARM"

So something like this below might be a good idea.

TERMUX_PKG_RECOMMENDS="nodejs | nodejs-lts | deno, ffmpeg"
if (( TERMUX_ARCH_BITS == 32 )); then
	TERMUX_PKG_RECOMMENDS="nodejs | nodejs-lts, ffmpeg"
fi

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

going with the oneliner since @robertkirkman didn't see any mentions of deno

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This way (in the current version of this PR at time of writing) works great, when I install the 32-bit build on the 32-bit device, nodejs is installed automatically, while when I install the 64-bit build on a 64-bit device, deno is installed automatically instead.

What remains is, that we don't know yet how exactly yt-dlp will actually behave when exposed to these dependencies (for example whether it will automatically attempt to actually use the nodejs dependency in the 32-bit build or not without downstream patching or explicit arguments at runtime), so maybe we just need to wait for the yt-dlp release to find out what will happen.

Copy link
Contributor Author

@AminurAlam AminurAlam Sep 29, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yup, we will have to wait and see.

currently according to this wiki change, ejs will need to be installed and deno will work automatically

for 32bit systems we will have to manually enable nodejs support, either by conditionally adding it to system config or with patches

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants