gpodder: ACTUALLY fix environment variable expansion
they were incorrectly being expanded at build time by the python wrapper; use extraMakeWrapperArgs to avoid that
This commit is contained in:
@@ -17,10 +17,12 @@ in {
|
||||
# - GPODDER_WRITE_LOGS ("yes" or "no")
|
||||
# - GPODDER_EXTENSIONS
|
||||
# - GPODDER_DISABLE_EXTENSIONS ("yes" or "no")
|
||||
makeWrapperArgs = (base.makeWrapperArgs or []) ++ [
|
||||
extraMakeWrapperArgs = (base.extraMakeWrapperArgs or []) ++ [
|
||||
"--set" "GPODDER_HOME" "~/.local/share/gPodder"
|
||||
# "--run" "export GPODDER_HOME=~/.local/share/gPodder" #< unquote `~/.local/share/gPodder` to force run-time home expansion
|
||||
# place downloads in a shared media directory to ensure sandboxed apps can read them
|
||||
"--set" "GPODDER_DOWNLOAD_DIR" "~/Videos/gPodder"
|
||||
# "--run" "export GPODDER_DOWNLOAD_DIR=~/Videos/gPodder"
|
||||
];
|
||||
});
|
||||
|
||||
|
@@ -32,8 +32,10 @@ in
|
||||
postFixup = (upstream.postFixup or "") + ''
|
||||
# XXX(2025-03-21): splat the makeWrapperArgs here because upstream gpodder specifies
|
||||
# `--suffix PATH ...` all as _one_ argument, but makeShellWrapper requires it to be multiple :(
|
||||
makeWrapperArgs=(''${makeWrapperArgs[*]} "''${gappsWrapperArgs[@]}")
|
||||
# makeWrapperArgs+=("''${gappsWrapperArgs[@]}")
|
||||
# splat `extraMakeWrapperArgs` because nix passes that through as a single string instead of as a bash array.
|
||||
# be careful when changing this: we rely on `~` being expanded at the right time (i.e. by the python interpreter),
|
||||
# and never before that (e.g. the makePythonApplication c wrapper)
|
||||
makeWrapperArgs=(''${makeWrapperArgs[*]} "''${gappsWrapperArgs[@]}" ''${extraMakeWrapperArgs[@]})
|
||||
|
||||
for f in $out/bin/*; do
|
||||
wrapProgramShell "$f" "''${makeWrapperArgs[@]}"
|
||||
|
Reference in New Issue
Block a user