Skip to content

Instantly share code, notes, and snippets.

View pxia's full-sized avatar

Peter Xia pxia

  • Google
  • Sunnyvale, CA
View GitHub Profile
@pxia
pxia / mpv.md
Created November 7, 2018 03:06 — forked from stolendata/mpv.md

The time-consuming part is not building MPV itself, but the long list of dependencies requiring a rebuild in order to fully satisfy the deployment target version. Setting MACOSX_DEPLOYMENT_TARGET in the immediate environment doesn't always propagate, resulting in target mix-ups and build failures for some dependencies. The only working solution I've found is to enforce within the formulas themselves. The following script adjusts the bulk of this:

#!/bin/sh
path='/path/to/homebrew/Library/Taps/homebrew/homebrew-core/Formula'
for dep in pkg-config makedepend autoconf automake openssl [email protected] libpng jpeg libtiff youtube-dl little-cms2 gettext libffi pcre libtool freetype fontconfig cairo pixman graphite2 icu4c harfbuzz glib libogg libvorbis flac libsamplerate libsndfile rubberband theora nasm readline sqlite gdbm xz python@2 python gobject-introspection docutils fribidi texi2html libass ffmpeg mujs mpv
do

sed -i.bu $'s/def install/def install\\n ENV["MACOSX_DEPLOYMENT_TARGET"] = "10.

@pxia
pxia / mpv.conf
Last active November 13, 2018 23:34
mpv.conf
# vim: syntax=config
#
# mpv configuration file
#
# Configuration files are read system-wide from /usr/local/etc/mpv.conf
# and per-user from ~/.config/mpv/mpv.conf, where per-user settings override
# system-wide settings, all of which are overridden by the command line.
#
# Configuration file settings and the command line options use the same
# underlying mechanisms. Most options can be put into the configuration file