@@ -3,7 +3,7 @@
33, freefont_ttf, freetype, libass, libpthreadstubs
44, lua, luasocket, libuchardet, libiconv ? null, darwin
55
6−, x11Support ? true,
6+, x11Support ? stdenv.isLinux,
77 libGLU_combined ? null,
88 libX11 ? null,
99 libXext ? null,
@@ -98,7 +98,8 @@ in stdenv.mkDerivation rec {
9898 patchShebangs ./TOOLS/
9999 '';
100100
101− NIX_LDFLAGS = optionalString x11Support "-lX11 -lXext";
101+ NIX_LDFLAGS = optionalString x11Support "-lX11 -lXext "
102+ + optionalString stdenv.isDarwin "-framework CoreFoundation";
102103
103104 configureFlags = [
104105 "--enable-libmpv-shared"
@@ -155,7 +156,7 @@ in stdenv.mkDerivation rec {
155156 ++ optionals x11Support [ libX11 libXext libGLU_combined libXxf86vm libXrandr ]
156157 ++ optionals waylandSupport [ wayland wayland-protocols libxkbcommon ]
157158 ++ optionals stdenv.isDarwin (with darwin.apple_sdk.frameworks; [
158− libiconv Cocoa CoreAudio
159+ CoreFoundation libiconv Cocoa CoreAudio
159160 ]);
160161
161162 enableParallelBuilding = true;