From d4c1e368e1ee945f75a2fb13e3166aa4d2f8c414 Mon Sep 17 00:00:00 2001 From: Anthony Roussel Date: Fri, 6 Jan 2023 04:24:12 +0100 Subject: [PATCH 1/2] iputils: 20211215 -> 20221126 --- .../from_md/release-notes/rl-2305.section.xml | 11 ++++++++ .../manual/release-notes/rl-2305.section.md | 5 ++++ pkgs/os-specific/linux/iputils/default.nix | 26 ++++++------------- 3 files changed, 24 insertions(+), 18 deletions(-) diff --git a/nixos/doc/manual/from_md/release-notes/rl-2305.section.xml b/nixos/doc/manual/from_md/release-notes/rl-2305.section.xml index d6dea111b97b..654683685fad 100644 --- a/nixos/doc/manual/from_md/release-notes/rl-2305.section.xml +++ b/nixos/doc/manual/from_md/release-notes/rl-2305.section.xml @@ -290,6 +290,17 @@ freetype and others. + + + The iputils package, which is installed by default, no longer + provides the ninfod, + rarpd and rdisc tools. + See + upstream’s + release notes for more details and available + replacements. + +
diff --git a/nixos/doc/manual/release-notes/rl-2305.section.md b/nixos/doc/manual/release-notes/rl-2305.section.md index beffe19c2ea7..134c8a81f0b2 100644 --- a/nixos/doc/manual/release-notes/rl-2305.section.md +++ b/nixos/doc/manual/release-notes/rl-2305.section.md @@ -75,6 +75,11 @@ In addition to numerous new and upgraded packages, this release has the followin - Deprecated `xlibsWrapper` transitional package has been removed in favour of direct use of its constitutents: `xorg.libX11`, `freetype` and others. +- The iputils package, which is installed by default, no longer provides the + `ninfod`, `rarpd` and `rdisc` tools. See + [upstream's release notes](https://github.com/iputils/iputils/releases/tag/20221126) + for more details and available replacements. + ## Other Notable Changes {#sec-release-23.05-notable-changes} diff --git a/pkgs/os-specific/linux/iputils/default.nix b/pkgs/os-specific/linux/iputils/default.nix index 0ca6d8aa187f..80500ceedac6 100644 --- a/pkgs/os-specific/linux/iputils/default.nix +++ b/pkgs/os-specific/linux/iputils/default.nix @@ -5,21 +5,15 @@ , apparmorRulesFromClosure }: -let - version = "20211215"; - sunAsIsLicense = { - fullName = "AS-IS, SUN MICROSYSTEMS license"; - url = "https://github.com/iputils/iputils/blob/s${version}/rdisc.c"; - }; -in stdenv.mkDerivation rec { +stdenv.mkDerivation rec { pname = "iputils"; - inherit version; + version = "20221126"; src = fetchFromGitHub { owner = pname; repo = pname; rev = version; - sha256 = "1vzdch1xi2x2j8mvnsr4wwwh7kdkgf926xafw5kkb74yy1wac5qv"; + hash = "sha256-XVoQhdjBmEK8TbCpaKLjebPw7ZT8iEvyLJDTCkzezeE="; }; outputs = ["out" "apparmor"]; @@ -29,7 +23,6 @@ in stdenv.mkDerivation rec { doCheck = false; mesonFlags = [ - "-DBUILD_RARPD=true" "-DNO_SETCAP_OR_SUID=true" "-Dsystemdunitdir=etc/systemd/system" "-DINSTALL_SYSTEMD_UNITS=true" @@ -68,20 +61,17 @@ in stdenv.mkDerivation rec { description = "A set of small useful utilities for Linux networking"; inherit (src.meta) homepage; changelog = "https://github.com/iputils/iputils/releases/tag/s${version}"; - license = with licenses; [ gpl2Plus bsd3 sunAsIsLicense ]; + license = with licenses; [ gpl2Plus bsd3 ]; platforms = platforms.linux; maintainers = with maintainers; [ primeos lheckemann ]; longDescription = '' A set of small useful utilities for Linux networking including: - arping - clockdiff - ninfod - ping - rarpd - rdisc - tracepath + - arping: send ARP REQUEST to a neighbour host + - clockdiff: measure clock difference between hosts + - ping: send ICMP ECHO_REQUEST to network hosts + - tracepath: traces path to a network host discovering MTU along this path ''; }; } From 4d32358bea2b91c5bd7b6962366c2a0d6b1c79e0 Mon Sep 17 00:00:00 2001 From: Anthony Roussel Date: Thu, 12 Jan 2023 13:14:55 +0100 Subject: [PATCH 2/2] iputils: format with nixpkgs-fmt --- pkgs/os-specific/linux/iputils/default.nix | 31 +++++++++++++--------- 1 file changed, 19 insertions(+), 12 deletions(-) diff --git a/pkgs/os-specific/linux/iputils/default.nix b/pkgs/os-specific/linux/iputils/default.nix index 80500ceedac6..cdaf9b9bbb40 100644 --- a/pkgs/os-specific/linux/iputils/default.nix +++ b/pkgs/os-specific/linux/iputils/default.nix @@ -1,6 +1,14 @@ -{ lib, stdenv, fetchFromGitHub -, meson, ninja, pkg-config, gettext, libxslt, docbook_xsl_ns -, libcap, libidn2 +{ lib +, stdenv +, fetchFromGitHub +, meson +, ninja +, pkg-config +, gettext +, libxslt +, docbook_xsl_ns +, libcap +, libidn2 , iproute2 , apparmorRulesFromClosure }: @@ -16,7 +24,7 @@ stdenv.mkDerivation rec { hash = "sha256-XVoQhdjBmEK8TbCpaKLjebPw7ZT8iEvyLJDTCkzezeE="; }; - outputs = ["out" "apparmor"]; + outputs = [ "out" "apparmor" ]; # We don't have the required permissions inside the build sandbox: # /build/source/build/ping/ping: socket: Operation not permitted @@ -28,8 +36,8 @@ stdenv.mkDerivation rec { "-DINSTALL_SYSTEMD_UNITS=true" "-DSKIP_TESTS=${lib.boolToString (!doCheck)}" ] - # Disable idn usage w/musl (https://github.com/iputils/iputils/pull/111): - ++ lib.optional stdenv.hostPlatform.isMusl "-DUSE_IDN=false"; + # Disable idn usage w/musl (https://github.com/iputils/iputils/pull/111): + ++ lib.optional stdenv.hostPlatform.isMusl "-DUSE_IDN=false"; nativeBuildInputs = [ meson ninja pkg-config gettext libxslt.bin docbook_xsl_ns ]; buildInputs = [ libcap ] @@ -58,13 +66,9 @@ stdenv.mkDerivation rec { ''; meta = with lib; { + homepage = "https://github.com/iputils/iputils"; + changelog = "https://github.com/iputils/iputils/releases/tag/${version}"; description = "A set of small useful utilities for Linux networking"; - inherit (src.meta) homepage; - changelog = "https://github.com/iputils/iputils/releases/tag/s${version}"; - license = with licenses; [ gpl2Plus bsd3 ]; - platforms = platforms.linux; - maintainers = with maintainers; [ primeos lheckemann ]; - longDescription = '' A set of small useful utilities for Linux networking including: @@ -73,5 +77,8 @@ stdenv.mkDerivation rec { - ping: send ICMP ECHO_REQUEST to network hosts - tracepath: traces path to a network host discovering MTU along this path ''; + license = with licenses; [ gpl2Plus bsd3 ]; + platforms = platforms.linux; + maintainers = with maintainers; [ primeos lheckemann ]; }; }