diff options
Diffstat (limited to 'pkgs/tools/misc')
-rw-r--r-- | pkgs/tools/misc/coreutils/default.nix | 19 | ||||
-rw-r--r-- | pkgs/tools/misc/ethtool/default.nix | 4 |
2 files changed, 16 insertions, 7 deletions
diff --git a/pkgs/tools/misc/coreutils/default.nix b/pkgs/tools/misc/coreutils/default.nix index 6ffdd3b5d47d..3d1c7145698c 100644 --- a/pkgs/tools/misc/coreutils/default.nix +++ b/pkgs/tools/misc/coreutils/default.nix @@ -1,8 +1,11 @@ { stdenv, lib, buildPackages , autoreconfHook, texinfo, fetchurl, perl, xz, libiconv, gmp ? null -, aclSupport ? false, acl ? null -, attrSupport ? false, attr ? null +, aclSupport ? stdenv.isLinux, acl ? null +, attrSupport ? stdenv.isLinux, attr ? null , selinuxSupport? false, libselinux ? null, libsepol ? null +# No openssl in default version, so openssl-induced rebuilds aren't too big. +# It makes *sum functions significantly faster. +, minimal ? true, withOpenssl ? !minimal, openssl ? null , withPrefix ? false , singleBinary ? "symlinks" # you can also pass "shebangs" or false }: @@ -36,9 +39,10 @@ stdenv.mkDerivation rec { outputs = [ "out" "info" ]; nativeBuildInputs = [ perl xz.bin ]; - configureFlags = - optional (singleBinary != false) + configureFlags = [ "--with-packager=https://NixOS.org" ] + ++ optional (singleBinary != false) ("--enable-single-binary" + optionalString (isString singleBinary) "=${singleBinary}") + ++ optional withOpenssl "--with-openssl" ++ optional stdenv.hostPlatform.isSunOS "ac_cv_func_inotify_init=no" ++ optional withPrefix "--program-prefix=g" ++ optionals (stdenv.hostPlatform != stdenv.buildPlatform && stdenv.hostPlatform.libc == "glibc") [ @@ -51,6 +55,7 @@ stdenv.mkDerivation rec { buildInputs = [ gmp ] ++ optional aclSupport acl ++ optional attrSupport attr + ++ optional withOpenssl openssl ++ optionals stdenv.hostPlatform.isCygwin [ autoreconfHook texinfo ] # due to patch ++ optionals selinuxSupport [ libselinux libsepol ] # TODO(@Ericson2314): Investigate whether Darwin could benefit too @@ -81,9 +86,13 @@ stdenv.mkDerivation rec { sed -i Makefile -e 's|^INSTALL =.*|INSTALL = ${buildPackages.coreutils}/bin/install -c|' ''; - postInstall = optionalString (stdenv.hostPlatform != stdenv.buildPlatform) '' + postInstall = optionalString (stdenv.hostPlatform != stdenv.buildPlatform && !minimal) '' rm $out/share/man/man1/* cp ${buildPackages.coreutils}/share/man/man1/* $out/share/man/man1 + '' + # du: 8.7 M locale + 0.4 M man pages + + optionalString minimal '' + rm -r "$out/share" ''; meta = { diff --git a/pkgs/tools/misc/ethtool/default.nix b/pkgs/tools/misc/ethtool/default.nix index 0e0bc37ad537..105733e00333 100644 --- a/pkgs/tools/misc/ethtool/default.nix +++ b/pkgs/tools/misc/ethtool/default.nix @@ -2,11 +2,11 @@ stdenv.mkDerivation rec { name = "ethtool-${version}"; - version = "4.17"; + version = "4.18"; src = fetchurl { url = "mirror://kernel/software/network/ethtool/${name}.tar.xz"; - sha256 = "11f5503mgcwjn1q4dvhjiqwnw3zmp2gbhirjvgfr71y72ys1wsy4"; + sha256 = "0461nwqp1z9a89nmxf7kq0r4jfl9c7fg55c71lfmc5y0siaqb54h"; }; meta = with stdenv.lib; { |