gstreamer: Fix wrapper quoting

The bug was that the inner double quotes in "\$("…")" are not actually
inner like they would be in "$("…")".  We could write "\$(\"…\")", but
using single quotes on the outside makes everything simpler.

Fixes #63751.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
This commit is contained in:
Anders Kaseorg 2020-06-04 13:51:27 -07:00 committed by Frederik Rietdijk
parent 1b6e357424
commit c8d064eec1

View file

@ -99,7 +99,7 @@ stdenv.mkDerivation rec {
postInstall = ''
for prog in "$dev/bin/"*; do
# We can't use --suffix here due to quoting so we craft the export command by hand
wrapProgram "$prog" --run "export GST_PLUGIN_SYSTEM_PATH=\$GST_PLUGIN_SYSTEM_PATH"$\{GST_PLUGIN_SYSTEM_PATH:+:\}"\$(unset _tmp; for profile in \$NIX_PROFILES; do _tmp="\$profile/lib/gstreamer-1.0''$\{_tmp:+:\}\$_tmp"; done; printf "\$_tmp")"
wrapProgram "$prog" --run 'export GST_PLUGIN_SYSTEM_PATH=$GST_PLUGIN_SYSTEM_PATH''${GST_PLUGIN_SYSTEM_PATH:+:}$(unset _tmp; for profile in $NIX_PROFILES; do _tmp="$profile/lib/gstreamer-1.0''${_tmp:+:}$_tmp"; done; printf '%s' "$_tmp")'
done
'';