evolutionWithPlugins: wrap with evolution schema

See https://github.com/NixOS/nixpkgs/issues/140853#issuecomment-1416247760
This commit is contained in:
Guillaume Girol 2023-02-03 12:00:00 +00:00
parent 4d7c2644db
commit 7dc8f2ab9f

View File

@ -7,10 +7,16 @@ symlinkJoin {
nativeBuildInputs = [ makeWrapper ];
postBuild = ''
declare -a schemas;
for plugin in ${toString plugins}; do
for schema in $plugin/share/gsettings-schemas/*; do
schemas+=($schema);
done
done
for i in $out/bin/* $out/libexec/**; do
if [ ! -d $i ]; then
echo wrapping $i
wrapProgram $i --set EDS_EXTRA_PREFIXES "${lib.concatStringsSep ":" plugins}"
wrapProgram $i --set EDS_EXTRA_PREFIXES "${lib.concatStringsSep ":" plugins}" --prefix XDG_DATA_DIRS : "''${schemas[@]}"
fi
done