Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)

iputils: 20190515 -> 20190709

https://github.com/iputils/iputils/releases/tag/s20190709

See release notes for details,
but of particular note is that
this expression is now quite simpler
due to the following:

* ninfod now builds w/nettle!
* update includes patches we fetched from upstream
* cross should be handled now, during move to meson
* prelim testing confirms, meson makes it much easier
to get things right re:explanation given in comment
(not propagating host/target info)
* issue re:musl+idn2 appears resolved re:compilation,
but results in unclear runtime errors regarding
"invalid flags". Keep disabled as before as this
is clearer at the expression level and reports
failure to resolve instead which is a bit clearer.
(testing with systemd-less iputils)

This also means our iputils is openssl-free,
which if nothing else is a nice reduction in trans. size :).
(quick imperfect comparison shows:
39MB -> 35MB w/glibc
11.4 -> 7.9 w/musl
)

iputils: nvm no IDN w/musl

iputils: nvm keep idn disabled w/musl

authored by

Will Dietz and committed by
Frederik Rietdijk
d5dc9a21 3e867d16

+11 -41
-13
pkgs/os-specific/linux/iputils/build-ninfod-with-openssl.patch
··· 1 - diff --git a/ninfod/meson.build b/ninfod/meson.build 2 - index ea7ec1b..fada05b 100644 3 - --- a/ninfod/meson.build 4 - +++ b/ninfod/meson.build 5 - @@ -10,7 +10,7 @@ ninfod_sources = files(''' 6 - ninfod_name.c 7 - '''.split()) 8 - executable('ninfod', [ninfod_sources, git_version_h], 9 - - dependencies : [cap_dep, crypto_dep, rt_dep, threads], 10 - + dependencies : [cap_dep, dependency('openssl'), rt_dep, threads], 11 - link_with : [libcommon], 12 - include_directories : inc, 13 - install: true,
+11 -28
pkgs/os-specific/linux/iputils/default.nix
··· 1 1 { stdenv, fetchFromGitHub, fetchpatch 2 2 , meson, ninja, pkgconfig, gettext, libxslt, docbook_xsl_ns 3 - , libcap, nettle, libidn2, openssl, systemd 3 + , libcap, nettle, libidn2, systemd 4 4 }: 5 5 6 6 with stdenv.lib; 7 7 8 8 let 9 - time = "20190515"; 10 - # ninfod probably could build on cross, but the Makefile doesn't pass --host 11 - # etc to the sub configure... 12 - withNinfod = stdenv.hostPlatform == stdenv.buildPlatform; 9 + version = "20190709"; 13 10 sunAsIsLicense = { 14 11 fullName = "AS-IS, SUN MICROSYSTEMS license"; 15 - url = "https://github.com/iputils/iputils/blob/s${time}/rdisc.c"; 12 + url = "https://github.com/iputils/iputils/blob/s${version}/rdisc.c"; 16 13 }; 17 - in stdenv.mkDerivation { 18 - name = "iputils-${time}"; 14 + in stdenv.mkDerivation rec { 15 + pname = "iputils"; 16 + inherit version; 19 17 20 18 src = fetchFromGitHub { 21 - owner = "iputils"; 22 - repo = "iputils"; 23 - rev = "s${time}"; 24 - sha256 = "1k2wzgk0d47d1g9k8c1a5l24ml8h8xxz1vrs0vfbyxr7qghdhn4i"; 19 + owner = pname; 20 + repo = pname; 21 + rev = "s${version}"; 22 + sha256 = "04bp4af15adp79ipxmiakfp0ij6hx5qam266flzbr94pr8z8l693"; 25 23 }; 26 24 27 - # ninfod cannot be build with nettle yet: 28 - patches = 29 - [ ./build-ninfod-with-openssl.patch 30 - (fetchpatch { # build-sys/doc: Fix the dependency on xsltproc 31 - url = "https://github.com/iputils/iputils/commit/3b013f271931c3fe771e5a2c591f35d617de90f3.patch"; 32 - sha256 = "0ilhlgiqdflry7km3ik8i4h1yymm5f5zmwyl5r029q7x1p8kinfw"; 33 - }) 34 - (fetchpatch { # build-sys: Make setcap really optional 35 - url = "https://github.com/iputils/iputils/commit/473be6467f995865244e7e68b2fa587a4ee79551.patch"; 36 - sha256 = "0781147qaf0jwa177jbmh474r8hqs0jwgi5vgx9csb43jzdm8hqf"; 37 - }) 38 - ]; 39 - 40 25 mesonFlags = 41 26 [ "-DUSE_CRYPTO=nettle" 42 27 "-DBUILD_RARPD=true" ··· 44 29 "-DNO_SETCAP_OR_SUID=true" 45 30 "-Dsystemdunitdir=etc/systemd/system" 46 31 ] 47 - ++ optional (!withNinfod) "-DBUILD_NINFOD=false" 48 32 # Disable idn usage w/musl (https://github.com/iputils/iputils/pull/111): 49 33 ++ optional stdenv.hostPlatform.isMusl "-DUSE_IDN=false"; 50 34 51 35 nativeBuildInputs = [ meson ninja pkgconfig gettext libxslt.bin docbook_xsl_ns ]; 52 36 buildInputs = [ libcap nettle systemd ] 53 - ++ optional (!stdenv.hostPlatform.isMusl) libidn2 54 - ++ optional withNinfod openssl; # TODO: Build with nettle 37 + ++ optional (!stdenv.hostPlatform.isMusl) libidn2; 55 38 56 39 meta = { 57 40 homepage = https://github.com/iputils/iputils;