mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-26 15:41:40 +00:00
networkmanager-l2tp: 1.2.8 → 1.2.10
This commit is contained in:
parent
7f175f2ad7
commit
3fa8a478e3
|
@ -1,35 +1,31 @@
|
|||
{ stdenv, fetchFromGitHub, autoreconfHook, libtool, intltool, pkgconfig
|
||||
{ stdenv, substituteAll, fetchFromGitHub, autoreconfHook, libtool, intltool, pkgconfig
|
||||
, networkmanager, ppp, xl2tpd, strongswan, libsecret
|
||||
, withGnome ? true, gnome3, networkmanagerapplet }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "${pname}${if withGnome then "-gnome" else ""}-${version}";
|
||||
pname = "NetworkManager-l2tp";
|
||||
version = "1.2.8";
|
||||
name = "${pname}${if withGnome then "-gnome" else ""}-${version}";
|
||||
pname = "NetworkManager-l2tp";
|
||||
version = "1.2.10";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "nm-l2tp";
|
||||
repo = "network-manager-l2tp";
|
||||
rev = "${version}";
|
||||
sha256 = "110157dpamgr7r5kb8aidi0a2ap9z2m52bff94fb4nhxacz69yv8";
|
||||
owner = "nm-l2tp";
|
||||
repo = "network-manager-l2tp";
|
||||
rev = "${version}";
|
||||
sha256 = "1vm004nj2n5abpywr7ji6r28scf7xs45zw4rqrm8jn7mysf96h0x";
|
||||
};
|
||||
|
||||
buildInputs = [ networkmanager ppp libsecret ]
|
||||
++ stdenv.lib.optionals withGnome [ gnome3.gtk gnome3.libgnome-keyring networkmanagerapplet ];
|
||||
patches = [
|
||||
(substituteAll {
|
||||
src = ./fix-paths.patch;
|
||||
inherit strongswan xl2tpd;
|
||||
})
|
||||
];
|
||||
|
||||
buildInputs = [ networkmanager ppp ]
|
||||
++ stdenv.lib.optionals withGnome [ gnome3.gtk libsecret networkmanagerapplet ];
|
||||
|
||||
nativeBuildInputs = [ autoreconfHook libtool intltool pkgconfig ];
|
||||
|
||||
postPatch = ''
|
||||
sed -i -e 's%"\(/usr/sbin\|/usr/pkg/sbin\|/usr/local/sbin\)/[^"]*",%%g' ./src/nm-l2tp-service.c
|
||||
|
||||
substituteInPlace ./Makefile.am \
|
||||
--replace '$(sysconfdir)/dbus-1/system.d' "$out/etc/dbus-1/system.d"
|
||||
|
||||
substituteInPlace ./src/nm-l2tp-service.c \
|
||||
--replace /sbin/ipsec ${strongswan}/bin/ipsec \
|
||||
--replace /sbin/xl2tpd ${xl2tpd}/bin/xl2tpd
|
||||
'';
|
||||
|
||||
preConfigure = ''
|
||||
intltoolize -f
|
||||
'';
|
||||
|
|
20
pkgs/tools/networking/network-manager/l2tp/fix-paths.patch
Normal file
20
pkgs/tools/networking/network-manager/l2tp/fix-paths.patch
Normal file
|
@ -0,0 +1,20 @@
|
|||
--- a/src/nm-l2tp-service.c
|
||||
+++ b/src/nm-l2tp-service.c
|
||||
@@ -480,7 +480,7 @@
|
||||
{
|
||||
static const char *ipsec_binary_paths[] =
|
||||
{
|
||||
- "/sbin/ipsec",
|
||||
+ "@strongswan@/bin/ipsec",
|
||||
"/usr/sbin/ipsec",
|
||||
"/usr/local/sbin/ipsec",
|
||||
"/sbin/strongswan",
|
||||
@@ -505,7 +505,7 @@
|
||||
{
|
||||
static const char *l2tp_binary_paths[] =
|
||||
{
|
||||
- "/sbin/xl2tpd",
|
||||
+ "@xl2tpd@/bin/xl2tpd",
|
||||
"/usr/sbin/xl2tpd",
|
||||
"/usr/local/sbin/xl2tpd",
|
||||
NULL
|
Loading…
Reference in a new issue