2017-02-28 16:47:21 +00:00
|
|
|
{ stdenv, fetchurl, pkgconfig, vpnc, openssl ? null, gnutls ? null, gmp, libxml2, stoken, zlib } :
|
2015-06-11 18:52:00 +01:00
|
|
|
|
2017-09-25 14:40:41 +01:00
|
|
|
assert (openssl != null) == (gnutls == null);
|
2013-05-31 19:19:56 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2017-01-28 21:05:37 +00:00
|
|
|
name = "openconnect-7.08";
|
2013-05-31 19:19:56 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
urls = [
|
|
|
|
"ftp://ftp.infradead.org/pub/openconnect/${name}.tar.gz"
|
|
|
|
];
|
2017-01-28 21:05:37 +00:00
|
|
|
sha256 = "00wacb79l2c45f94gxs63b9z25wlciarasvjrb8jb8566wgyqi0w";
|
2013-05-31 19:19:56 +01:00
|
|
|
};
|
|
|
|
|
2017-09-25 14:40:41 +01:00
|
|
|
outputs = [ "out" "dev" ];
|
|
|
|
|
2013-05-31 19:19:56 +01:00
|
|
|
preConfigure = ''
|
|
|
|
export PKG_CONFIG=${pkgconfig}/bin/pkg-config
|
2015-10-05 12:23:01 +01:00
|
|
|
export LIBXML2_CFLAGS="-I ${libxml2.dev}/include/libxml2"
|
|
|
|
export LIBXML2_LIBS="-L${libxml2.out}/lib -lxml2"
|
2013-05-31 19:19:56 +01:00
|
|
|
'';
|
|
|
|
|
|
|
|
configureFlags = [
|
|
|
|
"--with-vpnc-script=${vpnc}/etc/vpnc/vpnc-script"
|
|
|
|
"--disable-nls"
|
2013-06-08 11:26:23 +01:00
|
|
|
"--without-openssl-version-check"
|
2013-05-31 19:19:56 +01:00
|
|
|
];
|
|
|
|
|
2017-09-05 22:25:26 +01:00
|
|
|
nativeBuildInputs = [ pkgconfig ];
|
2017-02-28 16:47:21 +00:00
|
|
|
propagatedBuildInputs = [ vpnc openssl gnutls gmp libxml2 stoken zlib ];
|
2016-08-02 17:06:29 +01:00
|
|
|
|
|
|
|
meta = {
|
2017-01-28 21:05:37 +00:00
|
|
|
description = "VPN Client for Cisco's AnyConnect SSL VPN";
|
|
|
|
homepage = http://www.infradead.org/openconnect/;
|
|
|
|
license = stdenv.lib.licenses.lgpl21;
|
|
|
|
maintainers = with stdenv.lib.maintainers; [ pradeepchhetri ];
|
2016-08-02 17:06:29 +01:00
|
|
|
platforms = stdenv.lib.platforms.linux;
|
|
|
|
};
|
2013-05-31 19:19:56 +01:00
|
|
|
}
|