linux_xanmod: 5.11.14 -> 5.11.15
[NixPkgs.git] / pkgs / tools / networking / vtun / default.nix
blob4d79fdc9bc58973dd03ae30d0cf1eae622c4bde1
1 { lib, stdenv, fetchurl, fetchpatch, openssl, lzo, zlib, bison, flex }:
3 stdenv.mkDerivation rec {
4   name = "vtun-3.0.4";
6   src = fetchurl {
7     url = "mirror://sourceforge/vtun/${name}.tar.gz";
8     sha256 = "1fcqzn2bdjw31j1hvv6lg99v2phhszm29kp2xambxzp32mmxzy5b";
9   };
11   patches = [
12     (fetchpatch { url = "http://sources.debian.net/data/main/v/vtun/3.0.3-2.2/debian/patches/08-gcc5-inline.patch";
13                  sha256 = "18sys97v2hx6vac5zp3ld7sa6kz4izv3g9dnkm0lflbaxhym2vs1";
14                 })
15   ];
17   postPatch = ''
18     sed -i -e 's/-m 755//' -e 's/-o root -g 0//' Makefile.in
19     sed -i '/strip/d' Makefile.in
20   '';
21   buildInputs = [ lzo openssl zlib bison flex ];
23   configureFlags = [
24     "--with-lzo-headers=${lzo}/include/lzo"
25     "--with-ssl-headers=${openssl.dev}/include/openssl"
26     "--with-blowfish-headers=${openssl.dev}/include/openssl"
27   ];
29   meta = with lib; {
30       description = "Virtual Tunnels over TCP/IP with traffic shaping, compression and encryption";
31       homepage = "http://vtun.sourceforge.net/";
32       license = licenses.gpl2;
33       platforms = platforms.linux;
34       maintainers = with maintainers; [ pSub ];
35   };