Streamlink in Android using Termux with Python #5913
Replies: 2 comments 11 replies
-
My issue here is this almost works for me but it doesn't. It's noted in the original thread, but the solutions doesn't work. Simply, streamlink doesn't detect VLC installed and doesn't open the stream because that:
This can be issues with Termux or VLC, but the first thing I tested is you can launch VLC through Termux executing Noted that i tested all three options noted in the guide above with the same output, including the last one that seems to be created to fix this exact issue (but it doesn't create the stream to open inside VLC, so i can't be used). My specs!
Thanks! |
Beta Was this translation helpful? Give feedback.
-
OHHH... i see... Tested with the config file like this:
And it opened VLC right away. I updated the main guide too with all this info. However, i saw something, maybe VLC is opening but it happened to me twice that it closes within in a seconds. Maybe Many many thanks @bastimeyer for put me in the right path! |
Beta Was this translation helpful? Give feedback.
-
Description
Hello!
First of all, I know that using Streamlink in Android is something unsupported but because it seems possible to make it work maybe is worth it to have a discussion here about it. Also, if you search about this the main result you found it is this reddit thread and maybe here has more life as it seems outdated or with lack of testing.
Basically, following the guide in that thread, you need to install:
Then setup Termux:
Update repositories:
pkg update
Install required packages:
pkg install clang libxslt libxml2 python
Install and build streamlink (It takes a while):
pip install streamlink
Install an editor to edit ~/.config/streamlink/config, for example:
pkg install nano
or
pkg install joe
Create a new script file (called slink for example) with this content (Thanks to @urgoz0 and @bastimeyer) and save it:
Move slink to termux user apps, and make it executable (thanks @urgoz0)
mv slink $PREFIX/bin/slink
chmod +x $PREFIX/bin/slink
Execute slink like you do with streamlink:
slink www.youtube.com/NASA/live best
(NASA live stream, for example)When closing VLC, you need to close termux manually with its notification.
Old basic testing configuration. Has the issue of not opening VLC automatically, and closing streamlink automatically seconds after opening
Open to edit ~/.config/streamlink/config:
mkdir -p ~/.config/streamlink/
cd ~/.config/streamlink/
joe config
(change joe for your desired editor like nano)Edit the content in config. There are several options:
http://127.0.0.1:4567
. Maybe can be used too to play it through the local network, but i didn't test it (NEEDS TO BE UPDATED with Streamlink >6.0 arguments format, but still works with >6.0):streamlink www.youtube.com/NASA/live best
(NASA live stream, for example)Deprecated config posted in the original thread https://www.reddit.com/r/Streamlink/comments/cfno18/guide_streamlink_on_android_termux_vlc/. Supposedly working in Streamlink version <6.0
These don't work anymore because Streamlink 6.0 changed the `--player` option to a path only argument, and added a `--player-args` argument. More info: Streamlink 6.0 Changelog: https://streamlink.github.io/changelog.html#streamlink-6-0-0-2023-07-20), Streamlink 6.0 Migration Guide: https://streamlink.github.io/migrations.html#player-path-only-player-cli-argument (Thanks bastimeyer).
This is the guide that seems that at some point worked for some people, and now almost works, but at least for me it doesn't. I will post a response with my case below, but maybe for someone else doesn't have these issues and it can be edit with solutions found later.
Beta Was this translation helpful? Give feedback.
All reactions