networkmanager-fortisslvpn: clean up
* format with nixpkgs-fmt * reorder the expression * move pname into the main attrset * use pkg-config instead of pkgconfig alias
This commit is contained in:
parent
a421af29e4
commit
dc318b393f
|
@ -1,10 +1,23 @@
|
||||||
{ stdenv, fetchurl, substituteAll, openfortivpn, intltool, pkgconfig, file, gtk3,
|
{ stdenv
|
||||||
networkmanager, ppp, libsecret, withGnome ? true, gnome3, fetchpatch, libnma }:
|
, fetchurl
|
||||||
|
, substituteAll
|
||||||
|
, openfortivpn
|
||||||
|
, intltool
|
||||||
|
, pkg-config
|
||||||
|
, file
|
||||||
|
, gtk3
|
||||||
|
, networkmanager
|
||||||
|
, ppp
|
||||||
|
, libsecret
|
||||||
|
, withGnome ? true
|
||||||
|
, gnome3
|
||||||
|
, fetchpatch
|
||||||
|
, libnma
|
||||||
|
}:
|
||||||
|
|
||||||
let
|
stdenv.mkDerivation rec {
|
||||||
pname = "NetworkManager-fortisslvpn";
|
pname = "NetworkManager-fortisslvpn";
|
||||||
version = "1.2.10";
|
version = "1.2.10";
|
||||||
in stdenv.mkDerivation {
|
|
||||||
name = "${pname}${if withGnome then "-gnome" else ""}-${version}";
|
name = "${pname}${if withGnome then "-gnome" else ""}-${version}";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
|
@ -17,6 +30,7 @@ in stdenv.mkDerivation {
|
||||||
src = ./fix-paths.patch;
|
src = ./fix-paths.patch;
|
||||||
inherit openfortivpn;
|
inherit openfortivpn;
|
||||||
})
|
})
|
||||||
|
|
||||||
# Don't use etc/dbus-1/system.d
|
# Don't use etc/dbus-1/system.d
|
||||||
(fetchpatch {
|
(fetchpatch {
|
||||||
url = "https://gitlab.gnome.org/GNOME/NetworkManager-fortisslvpn/merge_requests/11.patch";
|
url = "https://gitlab.gnome.org/GNOME/NetworkManager-fortisslvpn/merge_requests/11.patch";
|
||||||
|
@ -24,10 +38,21 @@ in stdenv.mkDerivation {
|
||||||
})
|
})
|
||||||
];
|
];
|
||||||
|
|
||||||
buildInputs = [ openfortivpn networkmanager ppp ]
|
nativeBuildInputs = [
|
||||||
++ stdenv.lib.optionals withGnome [ gtk3 libsecret libnma ];
|
intltool
|
||||||
|
pkg-config
|
||||||
|
file
|
||||||
|
];
|
||||||
|
|
||||||
nativeBuildInputs = [ intltool pkgconfig file ];
|
buildInputs = [
|
||||||
|
openfortivpn
|
||||||
|
networkmanager
|
||||||
|
ppp
|
||||||
|
] ++ stdenv.lib.optionals withGnome [
|
||||||
|
gtk3
|
||||||
|
libsecret
|
||||||
|
libnma
|
||||||
|
];
|
||||||
|
|
||||||
configureFlags = [
|
configureFlags = [
|
||||||
"--without-libnm-glib"
|
"--without-libnm-glib"
|
||||||
|
@ -36,9 +61,11 @@ in stdenv.mkDerivation {
|
||||||
"--enable-absolute-paths"
|
"--enable-absolute-paths"
|
||||||
];
|
];
|
||||||
|
|
||||||
# the installer only create an empty directory in localstatedir, so
|
installFlags = [
|
||||||
# we can drop it
|
# the installer only creates an empty directory in localstatedir, so
|
||||||
installFlags = [ "localstatedir=." ];
|
# we can drop it
|
||||||
|
"localstatedir=."
|
||||||
|
];
|
||||||
|
|
||||||
passthru = {
|
passthru = {
|
||||||
updateScript = gnome3.updateScript {
|
updateScript = gnome3.updateScript {
|
||||||
|
@ -48,9 +75,8 @@ in stdenv.mkDerivation {
|
||||||
};
|
};
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
description = "NetworkManager's FortiSSL plugin";
|
description = "NetworkManager’s FortiSSL plugin";
|
||||||
inherit (networkmanager.meta) maintainers platforms;
|
inherit (networkmanager.meta) maintainers platforms;
|
||||||
license = licenses.gpl2;
|
license = licenses.gpl2;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user