mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-28 09:53:10 +00:00
vpnc: patch to not set a default route when a netmask is given
also, fix the name attribute in the nix expression
This commit is contained in:
parent
092a5eea28
commit
167383c7bf
@ -1,7 +1,7 @@
|
|||||||
{ stdenv, fetchsvn, nettools, libgcrypt, openssl, openresolv, perl, gawk, makeWrapper }:
|
{ stdenv, fetchsvn, nettools, libgcrypt, openssl, openresolv, perl, gawk, makeWrapper }:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
name = "vpnc-rev550";
|
name = "vpnc-0.5.3-post-r550";
|
||||||
src = fetchsvn {
|
src = fetchsvn {
|
||||||
url = "http://svn.unix-ag.uni-kl.de/vpnc";
|
url = "http://svn.unix-ag.uni-kl.de/vpnc";
|
||||||
rev = "550";
|
rev = "550";
|
||||||
@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
|
|||||||
rm -r $sourceRoot/{trunk,branches,tags}
|
rm -r $sourceRoot/{trunk,branches,tags}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
patches = [ ./makefile.patch ];
|
patches = [ ./makefile.patch ./no_default_route_when_netmask.patch ];
|
||||||
|
|
||||||
# The `etc/vpnc/vpnc-script' script relies on `which' and on
|
# The `etc/vpnc/vpnc-script' script relies on `which' and on
|
||||||
# `ifconfig' as found in net-tools (not GNU Inetutils).
|
# `ifconfig' as found in net-tools (not GNU Inetutils).
|
||||||
|
@ -0,0 +1,12 @@
|
|||||||
|
diff -uNr a/vpnc-script b/vpnc-script
|
||||||
|
--- a/vpnc-script 2015-09-06 13:19:11.408661526 +0200
|
||||||
|
+++ b/vpnc-script 2015-09-06 14:47:40.260871556 +0200
|
||||||
|
@@ -647,7 +647,7 @@
|
||||||
|
echo "$i" | grep : >/dev/null || \
|
||||||
|
set_network_route "$i" "255.255.255.255" "32"
|
||||||
|
done
|
||||||
|
- elif [ -n "$INTERNAL_IP4_ADDRESS" ]; then
|
||||||
|
+ elif [ -n "$INTERNAL_IP4_ADDRESS" -a -z "$INTERNAL_IP4_NETMASK" ]; then
|
||||||
|
set_default_route
|
||||||
|
fi
|
||||||
|
if [ -n "$CISCO_IPV6_SPLIT_INC" ]; then
|
Loading…
Reference in New Issue
Block a user