platinum-md icon indicating copy to clipboard operation
platinum-md copied to clipboard

FFmpeg binary breaks if newer Homebrew libraries are installed

Open ticky opened this issue 6 years ago • 2 comments

The included FFmpeg binary emits this error on my system:

dyld: Library not loaded: /usr/local/opt/openssl/lib/libssl.1.0.0.dylib
  Referenced from: /Users/ticky/Repositories/platinum-md/resources/mac/bin/ffmpeg
  Reason: image not found

It’s looking for an old version of openssl from Homebrew which Homebrew no longer ships.

The FFmpeg binary is not suitable for redistribution. It should instead bake in one of these official static versions: https://evermeet.cx/ffmpeg/ (note: this is the linked page if you click on the macOS option on https://www.ffmpeg.org/download.html)

Alternately, building a version from source which targets audio codecs specifically would also be possible, and reduce the binary size.

I believe this would also resolve #4 and #6

ticky avatar Mar 25 '20 22:03 ticky

Thanks! This should be fixed in the next build, I've swapped to a different method using @ffmpeg-installer/ffmpeg and fluent-ffmpeg which makes things a lot nicer (and adds to the cross-platform goal). Hopefully releasing it over the next day or two.

gavinbenda avatar Mar 25 '20 22:03 gavinbenda

IMO, ideally the opaque binaries would be removed from the repository and the build system scripted to either trigger building a suitable binary from source (e.g. in the case of atracdenc; maybe adding atracdenc as a git submodule would be a good idea here), or downloading/extracting one from a known good location as @ticky suggests, and checking its hash for a known good value.

In CMake-based C/C++ projects, for example, we can use ExternalProject_Add() for automating all of this, but unfortunately I'm not knowledgeable enough about web-app build systems to suggest how to do it.

Cheers! 😃

dwhinham avatar Mar 25 '20 22:03 dwhinham