mullvad-vpn: use makeWrapper instead of env hack
This commit is contained in:
parent
e8d0231396
commit
76c35ec839
@ -2,6 +2,7 @@
|
||||
, alsa-lib, atk, cairo, cups, dbus, expat, fontconfig, freetype
|
||||
, gdk-pixbuf, glib, gnome2, pango, nspr, nss, gtk3, mesa
|
||||
, xorg, autoPatchelfHook, systemd, libnotify, libappindicator
|
||||
, makeWrapper
|
||||
}:
|
||||
|
||||
let deps = [
|
||||
@ -53,6 +54,7 @@ stdenv.mkDerivation rec {
|
||||
nativeBuildInputs = [
|
||||
autoPatchelfHook
|
||||
dpkg
|
||||
makeWrapper
|
||||
];
|
||||
|
||||
buildInputs = deps;
|
||||
@ -73,12 +75,14 @@ stdenv.mkDerivation rec {
|
||||
mv usr/bin/* $out/bin
|
||||
mv opt/Mullvad\ VPN/* $out/share/mullvad
|
||||
|
||||
sed -i 's|"\/opt\/Mullvad.*VPN|env MULLVAD_DISABLE_UPDATE_NOTIFICATION=1 "'$out'/bin|g' $out/share/applications/mullvad-vpn.desktop
|
||||
|
||||
ln -s $out/share/mullvad/mullvad-{gui,vpn} $out/bin/
|
||||
ln -s $out/share/mullvad/resources/mullvad-daemon $out/bin/mullvad-daemon
|
||||
ln -sf $out/share/mullvad/resources/mullvad-problem-report $out/bin/mullvad-problem-report
|
||||
|
||||
wrapProgram $out/bin/mullvad-vpn --set MULLVAD_DISABLE_UPDATE_NOTIFICATION 1
|
||||
|
||||
sed -i "s|Exec.*$|Exec=$out/bin/mullvad-vpn $U|" $out/share/applications/mullvad-vpn.desktop
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user