Open t56k opened 4 years ago
I've never done development for macOS, so quite frankly I don't even know what it is you're supposed to do to make jftui compile and work there. I also don't own a mac and don't plan to, so I don't have anything to use for the purpose.
I understand it should work as a very special flavor of BSD and I've been avoiding to rely on specific Linux behavior so far and stuck to POSIX. So it should be possible, in theory.
You'll definitely need to patch the sources. I think everything about default folders and env variables needs touching, to start with. But there may be subtle things I don't know about, like some macro constants being undefined. The Makefile may need work too.
Mind that I would not be open to integrating a PR for it either, unless I got some guarantees that the onus of supporting a macOS build in the future would be taken up by somebody reliable. That's not something I'm doing myself.
I've been using this on Arch for a bit. (great work @Aanok)
Decided to see if I could get it compiled on macOS.
@cd-rum I have a fork here: github::LaurentFough/jftui
libmpv
files from https://github.com/mpv-player/mpv/tree/master/libmpv
Makefie
src/main.c
- point to libmpv
src/shared.h
- point to libmpv
The [only] build errors so far:
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [build/jftui] Error 1
[1] 41395 exit 2 make
Need to spend some time tracking it down. I've only just cloned and started today, so let's see what we can get done.
This branch (https://github.com/LaurentFough/jftui/tree/macOS-M1) compiles on an M1 Mac.
@LaurentFough that's awesome! I'll have a close look during the holidays to see what it took. If it turns out to be simple enough, I might just integrate the changes here, though no promises about that. At the very least your repo's getting a link from the readme/front page :)
@Aanok Thanks.
I'm also tracking down a small bug. Seems small from what I can deduce, maybe a macOS encoding issue or some small vagary between mpv edl on linux vs macOS.
If compile a debug version(jftui_debug
): I get a loadfile
url similar to:
edl://%141%http://JELLYFIN_SERVER:PORT/videos/89aaf3eb040290345b505eb9e4f8ebcb/stream?static=true&mediasourceid=89aaf3eb040290345b505eb9e4f8ebcb;
DEBUG: loadfile edl://%141%http://JELLYFIN_SERVER:PORT/videos/89aaf3eb040290345b505eb9e4f8ebcb/stream?static=true&mediasourceid=89aaf3eb040290345b505eb9e4f8ebcb;
Name: MEDIA_FILE_NAME
Path: (null)
Type: Episode
Id: 89aaf3eb040290345b505eb9e4f8ebcb
PB ticks: 0, RT ticks: 14400849920
Children:
Name: (null)
Path: (null)
Type: Video_Source
Id: 89aaf3eb040290345b505eb9e4f8ebcb
PB ticks: 0, RT ticks: 14400849920
DEBUG: event: idle
DEBUG: event: start-file
DEBUG: event: property-change
DEBUG: event: property-change
DEBUG: event: property-change
DEBUG: event: tracks-changed
DEBUG: event: tracks-changed
(+) Video --vid=1 (*) (h264 1280x720 23.976fps)
(+) Audio --aid=1 --alang=jpn (*) (aac 2ch 48000Hz)
Which does not play. No errors, mpv reports the correct media data, etc. —
If I then just execute, (in my default shell).
$ mpv "edl://%141%http://JELLYFIN_SERVER:PORT/videos/89aaf3eb040290345b505eb9e4f8ebcb/stream?static=true&mediasourceid=89aaf3eb040290345b505eb9e4f8ebcb;"
then playback starts as expected.
Anyone got a build working on macOS?