nix: check share/applications in share package

This allows share directories without share/applications/ to build correctly.

Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
2025-03-29 19:28:20 +09:00
parent ff3cfbb437
commit 72c59f9229

View File

@@ -201,9 +201,11 @@ in
${copy "${pkg}/share/icons"} ${copy "${pkg}/share/icons"}
${copy "${pkg}/share/man"} ${copy "${pkg}/share/man"}
if test -d "$out/share/applications"; then
substituteInPlace $out/share/applications/* \ substituteInPlace $out/share/applications/* \
--replace-warn '${pkg}/bin/' "" \ --replace-warn '${pkg}/bin/' "" \
--replace-warn '${pkg}/libexec/' "" --replace-warn '${pkg}/libexec/' ""
fi
'' ''
) )
++ acc ++ acc