musescore: make it find ffmpeg automatically (video export)

Fixes #529852.
This commit is contained in:
Doron Behar
2026-06-09 13:32:22 +03:00
parent 241d6617e4
commit ea541685e8
+10
View File
@@ -13,6 +13,7 @@
# buildInputs
alsa-lib,
alsa-plugins,
ffmpeg,
flac,
freetype,
kdePackages,
@@ -181,6 +182,15 @@ stdenv.mkDerivation (finalAttrs: {
kdePackages'.qtwayland
];
# Put the default, `$prefix/lib` directory to look for ffmpeg shared objects,
# Nixpkgs' provided ffmpeg, for both MacOS & Linux. Note that upstream uses
# the /usr/lib/x86_64-linux-gnu location for any Linux (e.g aarch64 too).
preConfigure = ''
substituteInPlace src/framework/media/internal/ffmpegutils.cpp \
--replace-fail "/usr/lib/x86_64-linux-gnu" "${lib.getLib ffmpeg}/lib" \
--replace-fail "/opt/homebrew/lib" "${lib.getLib ffmpeg}/lib" \
'';
strictDeps = true;
__structuredAttrs = true;