nixpkgs/pkgs/applications/office/libreoffice/wrapper.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

20 lines
484 B
Nix
Raw Normal View History

{ libreoffice, runCommand, dbus, bash }:
let
jdk = libreoffice.jdk;
in
2019-09-09 01:38:31 +02:00
(runCommand libreoffice.name {
inherit dbus libreoffice jdk bash;
} ''
mkdir -p "$out/bin"
ln -s "${libreoffice}/share" "$out/share"
substituteAll "${./wrapper.sh}" "$out/bin/soffice"
chmod a+x "$out/bin/soffice"
for i in $(ls "${libreoffice}/bin/"); do
test "$i" = "soffice" || ln -s soffice "$out/bin/$(basename "$i")"
done
'') // {
inherit libreoffice dbus;
meta = libreoffice.meta;
}