Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MacOS MPV DLL/Dylib #171

Open
willwrong opened this issue Jul 19, 2021 · 4 comments
Open

MacOS MPV DLL/Dylib #171

willwrong opened this issue Jul 19, 2021 · 4 comments

Comments

@willwrong
Copy link

Hi there,

I'm having trouble finding the library file for MPV on MacOS -- I've come across three .dylib files (mpvlib-1.dylib, and a couple others), but none work when placed in the file path of the Python program.

Any ideas where I should look?

Thanks,

Will

@neinseg
Copy link

neinseg commented Jul 28, 2021

I'm not an OS X user, but have a look at this comment. Note that you need not just libmpv, but also about three dozen other libraries such as libav.

@olivierfriard
Copy link

Hi,

for finding the required libraries I have had to change the @rpath in @loader_path in libmpv.1.dylib (and other libs) and put my python script in the same directory than all the libraries (from the IINA project).

The tool is install_name_tool and the commands are:

install_name_tool -change @rpath/libjpeg.9.dylib @loader_path/libjpeg.9.dylib libmpv.1.dylib
install_name_tool -change @rpath/liblua.5.1.dylib @loader_path/liblua.5.1.dylib libmpv.1.dylib
install_name_tool -change @rpath/librubberband.2.dylib @loader_path/librubberband.2.dylib libmpv.1.dylib
install_name_tool -change @rpath/libavdevice.58.dylib @loader_path/libavdevice.58.dylib libmpv.1.dylib
install_name_tool -change @rpath/libarchive.13.dylib @loader_path/libarchive.13.dylib libmpv.1.dylib
install_name_tool -change @rpath/libass.9.dylib @loader_path/libass.9.dylib libmpv.1.dylib
install_name_tool -change @rpath/libuchardet.0.dylib @loader_path/libuchardet.0.dylib libmpv.1.dylib
install_name_tool -change @rpath/libbluray.2.dylib @loader_path/libbluray.2.dylib libmpv.1.dylib
install_name_tool -change @rpath/liblcms2.2.dylib @loader_path/liblcms2.2.dylib libmpv.1.dylib
install_name_tool -change @rpath/libavcodec.58.dylib @loader_path/libavcodec.58.dylib libmpv.1.dylib
install_name_tool -change @rpath/libavutil.56.dylib @loader_path/libavutil.56.dylib libmpv.1.dylib
install_name_tool -change @rpath/libavformat.58.dylib @loader_path/libavformat.58.dylib libmpv.1.dylib
install_name_tool -change @rpath/libswscale.5.dylib @loader_path/libswscale.5.dylib libmpv.1.dylib
install_name_tool -change @rpath/libavfilter.7.dylib @loader_path/libavfilter.7.dylib libmpv.1.dylib
install_name_tool -change @rpath/libswresample.3.dylib @loader_path/libswresample.3.dylib libmpv.1.dylib

install_name_tool -change @rpath/libpostproc.55.dylib @loader_path/libpostproc.55.dylib libavdevice.58.dylib
install_name_tool -change @rpath/libavresample.4.dylib @loader_path/libavresample.4.dylib libavdevice.58.dylib
install_name_tool -change @rpath/libtesseract.4.dylib @loader_path/libtesseract.4.dylib libavdevice.58.dylib
install_name_tool -change @rpath/libfontconfig.1.dylib @loader_path/libfontconfig.1.dylib libavdevice.58.dylib
install_name_tool -change @rpath/libfreetype.6.dylib @loader_path/libfreetype.6.dylib libavdevice.58.dylib
install_name_tool -change @rpath/librtmp.1.dylib @loader_path/librtmp.1.dylib libavdevice.58.dylib
install_name_tool -change @rpath/libssl.1.1.dylib @loader_path/libssl.1.1.dylib libavdevice.58.dylib
install_name_tool -change @rpath/libcrypto.1.1.dylib @loader_path/libcrypto.1.1.dylib libavdevice.58.dylib
install_name_tool -change @rpath/libdav1d.4.dylib @loader_path/libdav1d.4.dylib libavdevice.58.dylib
install_name_tool -change @rpath/libspeex.1.dylib @loader_path/libspeex.1.dylib libavdevice.58.dylib

install_name_tool -change @rpath/libpng16.16.dylib @loader_path/libpng16.16.dylib libfreetype.6.dylib

install_name_tool -change @rpath/liblept.5.dylib @loader_path/liblept.5.dylib libtesseract.4.dylib

install_name_tool -change @rpath/libtiff.5.dylib @loader_path/libtiff.5.dylib liblept.5.dylib
install_name_tool -change @rpath/libwebpmux.3.dylib @loader_path/libwebpmux.3.dylib liblept.5.dylib
install_name_tool -change @rpath/libwebp.7.dylib @loader_path/libwebp.7.dylib liblept.5.dylib
install_name_tool -change @rpath/libopenjp2.7.dylib @loader_path/libopenjp2.7.dylib liblept.5.dylib

install_name_tool -change @rpath/libharfbuzz.0.dylib @loader_path/libharfbuzz.0.dylib libass.9.dylib

@gavspav
Copy link

gavspav commented Jun 22, 2023

Hmm, didn't work for me.

@j77h
Copy link

j77h commented Jul 9, 2023

didn't work for me.

Try brew install --force-bottle mpv

7 months ago installing mpv required full Xcode installation, but recently
I upgraded mpv and I'm pretty sure it was re-installed from a bottle (binary).
If that was so, you wouldn't need Xcode to install it now.

(Xcode is a 7 GB download and won't install if you have <~20+ GB free space.
Brew always wants xcode CommandLineTools present, but it's a lot smaller.)

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

No branches or pull requests

5 participants