network/openconnect: Fix vpnc-script's test for /sbin/netconfig

Date: Mon, 8 Sep 2014 23:14:19 +0100
From: higuita <higuita@GMX.net>
To: rworkman@slackbuilds.org
Subject: openconnect slackbuild

I used your openconnect slackbuild to install it on my machine and
found a annoying problem.

The vpnc-script installed by openconnect script tried to
reconfigure slackware network configs files (rc.inet1.conf, hosts,
resolv.conf and others) because it is testing the existence of
/sbin/netconfig and use it... the problem is that is trying to
use it as the SuSE netconfig and is totally weird to get the
slackware netconfig vpn connection. Any user that don't cancel it
might mess up his network config without knowning

The solution is the attached patch, that bypass that test
on slackware machines. I will submit this also to the openconnect
so they can merge it too... but until that, please change the
slackbuild to apply this. If you like, i can send a patch for the
slackbuild too

Also, version on the slackbuild is 5.01 and openconnect
is already in version 6.00 and it works fine here... so no problem
in update it also.

--

Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
This commit is contained in:
Robby Workman 2014-12-07 00:58:11 -06:00 committed by Willy Sudiarto Raharjo
parent b699c6d90f
commit 06993904f6
2 changed files with 2 additions and 2 deletions

View file

@ -24,7 +24,7 @@
PRGNAM=openconnect
VERSION=${VERSION:-5.03}
BUILD=${BUILD:-1}
BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then

View file

@ -124,7 +124,7 @@ if [ -r /etc/openwrt_release ] && [ -n "$OPENWRT_INTERFACE" ]; then
elif [ -x /sbin/resolvconf ]; then # Optional tool on Debian, Ubuntu, Gentoo
MODIFYRESOLVCONF=modify_resolvconf_manager
RESTORERESOLVCONF=restore_resolvconf_manager
elif [ -x /sbin/netconfig ]; then # tool on Suse after 11.1
elif [ -x /sbin/netconfig-suse ] && [ ! -f /etc/slackware-version ]; then # tool on Suse after 11.1
MODIFYRESOLVCONF=modify_resolvconf_suse_netconfig
RESTORERESOLVCONF=restore_resolvconf_suse_netconfig
elif [ -x /sbin/modify_resolvconf ]; then # Mandatory tool on Suse earlier than 11.1