networkmanager-openvpn: add updateScript

This commit is contained in:
Jan Tojnar 2018-03-07 06:10:37 +01:00
parent 6c4bb91fca
commit 348784f8a8
No known key found for this signature in database
GPG Key ID: 7FAB2A15F7A607A4

View File

@ -1,14 +1,14 @@
{ stdenv, fetchurl, openvpn, intltool, pkgconfig, networkmanager, libsecret
, withGnome ? true, gnome3, procps, kmod }:
stdenv.mkDerivation rec {
name = "${pname}${if withGnome then "-gnome" else ""}-${version}";
let
pname = "NetworkManager-openvpn";
major = "1.8";
version = "${major}.0";
version = "1.8.0";
in stdenv.mkDerivation rec {
name = "${pname}${if withGnome then "-gnome" else ""}-${version}";
src = fetchurl {
url = "mirror://gnome/sources/${pname}/${major}/${pname}-${version}.tar.xz";
url = "mirror://gnome/sources/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
sha256 = "1973n89g66a3jfx8r45a811fga4kadh6r1w35cb25cz1mlii2vhn";
};
@ -34,6 +34,13 @@ stdenv.mkDerivation rec {
--replace "/sbin/openvpn" "${openvpn}/bin/openvpn"
'';
passthru = {
updateScript = gnome3.updateScript {
packageName = pname;
attrPath = "networkmanager-openvpn";
};
};
meta = {
description = "NetworkManager's OpenVPN plugin";
inherit (networkmanager.meta) maintainers platforms;