From 7615d6385ad13f28123e59b82eb9547144056f71 Mon Sep 17 00:00:00 2001 From: Alexander Ried Date: Sun, 25 Sep 2016 15:07:03 +0200 Subject: iproute2: 4.5.0 -> 4.7.0 (#18435) iproute now packages a bash-completion file which it installs to $BASH_COMPDIR. * fanpatch: adjust for new version - The patch did not apply because the code around the additions changed. - The patch uses functions that got changed [1] & [2], I adjusted the patch to use the safe version. Probably not needed but better safe than sorry. [1] format_host: http://git.kernel.org/cgit/linux/kernel/git/shemminger/iproute2.git/commit/?id=a418e451643e77fe36861e53359587ba8aa41873 [2] rt_addr_n2a: http://git.kernel.org/cgit/linux/kernel/git/shemminger/iproute2.git/commit/?id=7faf1588a755edb9c9cabbe1d3211265e9826d28 --- .../linux/iproute/1000-ubuntu-poc-fan-driver.patch | 2 +- .../linux/iproute/1001-ubuntu-poc-fan-driver-v3.patch | 4 ++-- .../linux/iproute/1002-ubuntu-poc-fan-driver-vxlan.patch | 12 ++++++------ pkgs/os-specific/linux/iproute/default.nix | 6 ++++-- 4 files changed, 13 insertions(+), 11 deletions(-) (limited to 'pkgs/os-specific/linux/iproute') diff --git a/pkgs/os-specific/linux/iproute/1000-ubuntu-poc-fan-driver.patch b/pkgs/os-specific/linux/iproute/1000-ubuntu-poc-fan-driver.patch index ca91b8160008..e0c8278d488d 100644 --- a/pkgs/os-specific/linux/iproute/1000-ubuntu-poc-fan-driver.patch +++ b/pkgs/os-specific/linux/iproute/1000-ubuntu-poc-fan-driver.patch @@ -57,7 +57,7 @@ Index: iproute2-4.1.1/ip/link_iptnl.c + + if (addr) + fprintf(f, "underlay %s ", -+ format_host(AF_INET, 4, &addr, s1, sizeof(s1))); ++ format_host_r(AF_INET, 4, &addr, s1, sizeof(s1))); + } + if (tb[IFLA_IPTUN_LINK] && rta_getattr_u32(tb[IFLA_IPTUN_LINK])) { diff --git a/pkgs/os-specific/linux/iproute/1001-ubuntu-poc-fan-driver-v3.patch b/pkgs/os-specific/linux/iproute/1001-ubuntu-poc-fan-driver-v3.patch index a940b341ea0f..634daa0de29f 100644 --- a/pkgs/os-specific/linux/iproute/1001-ubuntu-poc-fan-driver-v3.patch +++ b/pkgs/os-specific/linux/iproute/1001-ubuntu-poc-fan-driver-v3.patch @@ -111,9 +111,9 @@ Index: iproute2-4.1.1/ip/link_iptnl.c + p = RTA_PAYLOAD(i); + m = RTA_DATA(i); + fprintf(f, "%s/%d:%s/%d ", -+ rt_addr_n2a(AF_INET, p, &m->overlay, b1, INET_ADDRSTRLEN), ++ rt_addr_n2a_r(AF_INET, p, &m->overlay, b1, INET_ADDRSTRLEN), + m->overlay_prefix, -+ rt_addr_n2a(AF_INET, p, &m->underlay, b2, INET_ADDRSTRLEN), ++ rt_addr_n2a_r(AF_INET, p, &m->underlay, b2, INET_ADDRSTRLEN), + m->underlay_prefix); + } +} diff --git a/pkgs/os-specific/linux/iproute/1002-ubuntu-poc-fan-driver-vxlan.patch b/pkgs/os-specific/linux/iproute/1002-ubuntu-poc-fan-driver-vxlan.patch index 2ddc2840bdd1..070023d0b923 100644 --- a/pkgs/os-specific/linux/iproute/1002-ubuntu-poc-fan-driver-vxlan.patch +++ b/pkgs/os-specific/linux/iproute/1002-ubuntu-poc-fan-driver-vxlan.patch @@ -6,9 +6,9 @@ Index: iproute2-4.3.0/include/linux/if_link.h --- iproute2-4.3.0.orig/include/linux/if_link.h +++ iproute2-4.3.0/include/linux/if_link.h @@ -392,6 +392,7 @@ enum { - IFLA_VXLAN_GBP, - IFLA_VXLAN_REMCSUM_NOPARTIAL, IFLA_VXLAN_COLLECT_METADATA, + IFLA_VXLAN_LABEL, + IFLA_VXLAN_GPE, + IFLA_VXLAN_FAN_MAP = 33, __IFLA_VXLAN_MAX }; @@ -88,9 +88,9 @@ Index: iproute2-4.3.0/ip/iplink_vxlan.c struct nlmsghdr *n) { @@ -201,6 +243,10 @@ static int vxlan_parse_opt(struct link_u - udp6zerocsumrx = 0; - } else if (!matches(*argv, "gbp")) { gbp = 1; + } else if (!matches(*argv, "gpe")) { + gpe = 1; + } else if (!matches(*argv, "fan-map")) { + NEXT_ARG(); + if (fan_parse_map(&argc, &argv, n)) @@ -117,9 +117,9 @@ Index: iproute2-4.3.0/ip/iplink_vxlan.c + p = RTA_PAYLOAD(i); + m = RTA_DATA(i); + fprintf(f, "%s/%d:%s/%d ", -+ rt_addr_n2a(AF_INET, p, &m->overlay, b1, INET_ADDRSTRLEN), ++ rt_addr_n2a_r(AF_INET, p, &m->overlay, b1, INET_ADDRSTRLEN), + m->overlay_prefix, -+ rt_addr_n2a(AF_INET, p, &m->underlay, b2, INET_ADDRSTRLEN), ++ rt_addr_n2a_r(AF_INET, p, &m->underlay, b2, INET_ADDRSTRLEN), + m->underlay_prefix); + } +} diff --git a/pkgs/os-specific/linux/iproute/default.nix b/pkgs/os-specific/linux/iproute/default.nix index 6813b5bcf1b4..9d3d76eb1f46 100644 --- a/pkgs/os-specific/linux/iproute/default.nix +++ b/pkgs/os-specific/linux/iproute/default.nix @@ -3,11 +3,12 @@ }: stdenv.mkDerivation rec { - name = "iproute2-4.5.0"; + name = "iproute2-${version}"; + version = "4.7.0"; src = fetchurl { url = "mirror://kernel/linux/utils/net/iproute2/${name}.tar.xz"; - sha256 = "0jj9phsi8m2sbnz7bbh9cf9vckm67hs62ab5srdwnrg4acpjj59z"; + sha256 = "14kvpdlxq8204f5ayfdfb6mc0423mbf3px9q0spdly9sng7xnq4g"; }; patches = lib.optionals enableFan [ @@ -28,6 +29,7 @@ stdenv.mkDerivation rec { "LIBDIR=$(out)/lib" "SBINDIR=$(out)/sbin" "MANDIR=$(out)/share/man" + "BASH_COMPDIR=$(out)/share/bash-completion/completions/iproute2" "DOCDIR=$(TMPDIR)/share/doc/${name}" # Don't install docs ]; -- cgit 1.4.1