diff options
Diffstat (limited to 'pkgs/tools/misc')
-rw-r--r-- | pkgs/tools/misc/broot/default.nix | 23 | ||||
-rw-r--r-- | pkgs/tools/misc/coreutils/coreutils-8.31-android-cross.patch | 51 | ||||
-rw-r--r-- | pkgs/tools/misc/coreutils/default.nix | 11 | ||||
-rw-r--r-- | pkgs/tools/misc/diffoscope/default.nix | 13 | ||||
-rw-r--r-- | pkgs/tools/misc/ethtool/default.nix | 6 | ||||
-rw-r--r-- | pkgs/tools/misc/hakuneko/default.nix | 94 | ||||
-rw-r--r-- | pkgs/tools/misc/snapper/default.nix | 4 |
7 files changed, 165 insertions, 37 deletions
diff --git a/pkgs/tools/misc/broot/default.nix b/pkgs/tools/misc/broot/default.nix index 63d5ff69e790..7980298eba16 100644 --- a/pkgs/tools/misc/broot/default.nix +++ b/pkgs/tools/misc/broot/default.nix @@ -1,17 +1,32 @@ -{ stdenv, rustPlatform, fetchFromGitHub }: +{ stdenv, rustPlatform, fetchFromGitHub, coreutils, installShellFiles }: rustPlatform.buildRustPackage rec { pname = "broot"; - version = "0.10.2"; + version = "0.11.8"; src = fetchFromGitHub { owner = "Canop"; repo = pname; rev = "v${version}"; - sha256 = "1wisqb4cqdgsnjvmpgxbzs9zcw6npqw1kqxxs8mn33sxlikhbf2l"; + sha256 = "1pbjlfwv4s50s731ryrcc54200g2i04acdxrxk4kpcvi6b19kbky"; }; - cargoSha256 = "09gnyj97akychin1axp9kcww3c04xx7x1qnplhs2yxfki62r4y2b"; + cargoSha256 = "07ncclp4yqqr2lncw4bbcmknm09qzmdcq8iwkhyyfiy3fpyw9hqc"; + + nativeBuildInputs = [ installShellFiles ]; + + postPatch = '' + substituteInPlace src/verb_store.rs --replace '"/bin/' '"${coreutils}/bin/' + ''; + + postInstall = '' + # install shell completion files + OUT_DIR=target/release/build/broot-*/out + + installShellCompletion --bash $OUT_DIR/{br,broot}.bash + installShellCompletion --fish $OUT_DIR/{br,broot}.fish + installShellCompletion --zsh $OUT_DIR/{_br,_broot} + ''; meta = with stdenv.lib; { description = "An interactive tree view, a fuzzy search, a balanced BFS descent and customizable commands"; diff --git a/pkgs/tools/misc/coreutils/coreutils-8.31-android-cross.patch b/pkgs/tools/misc/coreutils/coreutils-8.31-android-cross.patch new file mode 100644 index 000000000000..97d95d1c5b19 --- /dev/null +++ b/pkgs/tools/misc/coreutils/coreutils-8.31-android-cross.patch @@ -0,0 +1,51 @@ +From 3bd82a82cf4ba693d2c31c7b95aaec4e56dc92a4 Mon Sep 17 00:00:00 2001 +From: Paul Eggert <eggert@cs.ucla.edu> +Date: Mon, 11 Mar 2019 16:40:29 -0700 +Subject: [PATCH 1/1] strtod: fix clash with strtold + +Problem reported for RHEL 5 by Jesse Caldwell (Bug#34817). +* lib/strtod.c (compute_minus_zero, minus_zero): +Simplify by remving the macro / external variable, +and having just a function. User changed. This avoids +the need for an external variable that might clash. +--- + ChangeLog | 9 +++++++++ + lib/strtod.c | 11 +++++------ + 2 files changed, 14 insertions(+), 6 deletions(-) + +diff --git a/lib/strtod.c b/lib/strtod.c +index b9eaa51..69b1564 100644 +--- a/lib/strtod.c ++++ b/lib/strtod.c +@@ -294,16 +294,15 @@ parse_number (const char *nptr, + ICC 10.0 has a bug when optimizing the expression -zero. + The expression -MIN * MIN does not work when cross-compiling + to PowerPC on Mac OS X 10.5. */ +-#if defined __hpux || defined __sgi || defined __ICC + static DOUBLE +-compute_minus_zero (void) ++minus_zero (void) + { ++#if defined __hpux || defined __sgi || defined __ICC + return -MIN * MIN; +-} +-# define minus_zero compute_minus_zero () + #else +-DOUBLE minus_zero = -0.0; ++ return -0.0; + #endif ++} + + /* Convert NPTR to a DOUBLE. If ENDPTR is not NULL, a pointer to the + character after the last one used in the number is put in *ENDPTR. */ +@@ -479,6 +478,6 @@ STRTOD (const char *nptr, char **endptr) + /* Special case -0.0, since at least ICC miscompiles negation. We + can't use copysign(), as that drags in -lm on some platforms. */ + if (!num && negative) +- return minus_zero; ++ return minus_zero (); + return negative ? -num : num; + } +-- +1.9.1 + diff --git a/pkgs/tools/misc/coreutils/default.nix b/pkgs/tools/misc/coreutils/default.nix index cbe97dda9e5a..519a33c60d69 100644 --- a/pkgs/tools/misc/coreutils/default.nix +++ b/pkgs/tools/misc/coreutils/default.nix @@ -15,7 +15,7 @@ assert selinuxSupport -> libselinux != null && libsepol != null; with lib; -stdenv.mkDerivation rec { +stdenv.mkDerivation (rec { pname = "coreutils"; version = "8.31"; @@ -29,7 +29,9 @@ stdenv.mkDerivation rec { # To be removed in coreutils-8.32. ++ optional stdenv.hostPlatform.isMusl ./avoid-false-positive-in-date-debug-test.patch # Fix compilation in musl-cross environments. To be removed in coreutils-8.32. - ++ optional stdenv.hostPlatform.isMusl ./coreutils-8.31-musl-cross.patch; + ++ optional stdenv.hostPlatform.isMusl ./coreutils-8.31-musl-cross.patch + # Fix compilation in android-cross environments. To be removed in coreutils-8.32. + ++ [ ./coreutils-8.31-android-cross.patch ]; postPatch = '' # The test tends to fail on btrfs,f2fs and maybe other unusual filesystems. @@ -143,8 +145,9 @@ stdenv.mkDerivation rec { maintainers = [ maintainers.eelco ]; }; - } // optionalAttrs stdenv.hostPlatform.isMusl { # Work around a bogus warning in conjunction with musl. NIX_CFLAGS_COMPILE = "-Wno-error"; -} +} // stdenv.lib.optionalAttrs stdenv.hostPlatform.isAndroid { + NIX_CFLAGS_COMPILE = "-D__USE_FORTIFY_LEVEL=0"; +}) diff --git a/pkgs/tools/misc/diffoscope/default.nix b/pkgs/tools/misc/diffoscope/default.nix index b64c527a6b99..c9f61ee34592 100644 --- a/pkgs/tools/misc/diffoscope/default.nix +++ b/pkgs/tools/misc/diffoscope/default.nix @@ -35,11 +35,14 @@ python3Packages.buildPythonApplication rec { # # Still missing these tools: abootimg docx2txt dumpxsb enjarify js-beautify lipo oggDump otool procyon-decompiler Rscript wasm2wat zipnode # Also these libraries: python3-guestfs - pythonPath = with python3Packages; [ debian libarchive-c python_magic tlsh rpm pyxattr ] ++ [ - acl binutils-unwrapped bzip2 cdrkit colordiff coreutils cpio db diffutils + pythonPath = [ + binutils-unwrapped bzip2 colordiff coreutils cpio db diffutils dtc e2fsprogs file findutils fontforge-fonttools gettext gnutar gzip - libarchive libcaca lz4 pgpdump progressbar33 sng sqlite squashfsTools unzip xxd xz - ] ++ lib.optionals enableBloat [ + libarchive libcaca lz4 pgpdump sng sqlite squashfsTools unzip xxd xz + ] + ++ (with python3Packages; [ debian libarchive-c python_magic tlsh rpm progressbar33 ]) + ++ lib.optionals stdenv.isLinux [ python3Packages.pyxattr acl cdrkit ] + ++ lib.optionals enableBloat [ apktool cbfstool colord fpc ghc ghostscriptX giflib gnupg gnumeric imagemagick llvm jdk mono openssh pdftk poppler_utils tcpdump unoconv python3Packages.guestfs @@ -69,6 +72,6 @@ python3Packages.buildPythonApplication rec { homepage = https://wiki.debian.org/ReproducibleBuilds; license = licenses.gpl3Plus; maintainers = with maintainers; [ dezgeg ]; - platforms = platforms.linux; + platforms = platforms.unix; }; } diff --git a/pkgs/tools/misc/ethtool/default.nix b/pkgs/tools/misc/ethtool/default.nix index bffc8a01f920..ec1e2c48e640 100644 --- a/pkgs/tools/misc/ethtool/default.nix +++ b/pkgs/tools/misc/ethtool/default.nix @@ -2,11 +2,11 @@ stdenv.mkDerivation rec { pname = "ethtool"; - version = "5.3"; + version = "5.4"; src = fetchurl { - url = "mirror://kernel/software/network/ethtool/${pname}-${version}.tar.xz"; - sha256 = "1i14zrg4a84zjpwvqi8an0zx0hm06g614a79zc2syrkhrvdw1npk"; + url = "mirror://kernel/software/network/${pname}/${pname}-${version}.tar.xz"; + sha256 = "0srbqp4a3x9ryrbm5q854375y04ni8j0bmsrl89nmsyn4x4ixy12"; }; meta = with stdenv.lib; { diff --git a/pkgs/tools/misc/hakuneko/default.nix b/pkgs/tools/misc/hakuneko/default.nix index 8c2e7dc7451d..0a27397551d9 100644 --- a/pkgs/tools/misc/hakuneko/default.nix +++ b/pkgs/tools/misc/hakuneko/default.nix @@ -1,28 +1,84 @@ -{ stdenv, fetchurl, wxGTK30, openssl, curl }: - +{ atomEnv +, autoPatchelfHook +, dpkg +, fetchurl +, makeDesktopItem +, makeWrapper +, udev +, stdenv +, wrapGAppsHook +}: +let + desktopItem = makeDesktopItem { + desktopName = "HakuNeko Desktop"; + genericName = "Manga & Anime Downloader"; + categories = "Network;FileTransfer;"; + exec = "hakuneko"; + icon = "hakuneko-desktop"; + name = "hakuneko-desktop"; + type = "Application"; + }; +in stdenv.mkDerivation rec { pname = "hakuneko"; - version = "1.4.2"; + version = "5.0.8"; - src = fetchurl { - url = "mirror://sourceforge/hakuneko/hakuneko_${version}_src.tar.gz"; - sha256 = "76a63fa05e91b082cb5a70a8abacef005354e99978ff8b1369f7aa0af7615d52"; - }; + src = { + "x86_64-linux" = fetchurl { + url = "https://github.com/manga-download/hakuneko/releases/download/v${version}/hakuneko-desktop_${version}_linux_amd64.deb"; + sha256 = "924df1d7a0ab54b918529165317e4428b423c9045548d1e36bd634914f7957f0"; + }; + "i686-linux" = fetchurl { + url = "https://github.com/manga-download/hakuneko/releases/download/v${version}/hakuneko-desktop_${version}_linux_i386.deb"; + sha256 = "988d8b0e8447dcd0a8d85927f5877bca9efb8e4b09ed3c80a6788390e54a48d2"; + }; + }."${stdenv.hostPlatform.system}"; + + dontBuild = true; + dontConfigure = true; + dontPatchELF = true; + dontWrapGApps = true; + + nativeBuildInputs = [ + autoPatchelfHook + dpkg + makeWrapper + wrapGAppsHook + ]; + + buildInputs = atomEnv.packages; + + unpackPhase = '' + # The deb file contains a setuid binary, so 'dpkg -x' doesn't work here + dpkg --fsys-tarfile $src | tar --extract + ''; - preConfigure = '' - substituteInPlace ./configure \ - --replace /bin/bash $shell - ''; + installPhase = '' + cp -R usr "$out" + # Overwrite existing .desktop file. + cp "${desktopItem}/share/applications/hakuneko-desktop.desktop" \ + "$out/share/applications/hakuneko-desktop.desktop" + ''; - buildInputs = [ wxGTK30 openssl curl ]; + runtimeDependencies = [ + udev.lib + ]; - meta = { - description = "Manga downloader"; - homepage = https://sourceforge.net/projects/hakuneko/; - license = stdenv.lib.licenses.mit; - platforms = stdenv.lib.platforms.linux; + postFixup = '' + makeWrapper $out/lib/hakuneko-desktop/hakuneko $out/bin/hakuneko \ + "''${gappsWrapperArgs[@]}" + ''; - # This project was abandoned upstream. - broken = true; + meta = with stdenv.lib; { + description = "Manga & Anime Downloader"; + homepage = "https://sourceforge.net/projects/hakuneko/"; + license = licenses.unlicense; + maintainers = with maintainers; [ + nloomans + ]; + platforms = [ + "x86_64-linux" + "i686-linux" + ]; }; } diff --git a/pkgs/tools/misc/snapper/default.nix b/pkgs/tools/misc/snapper/default.nix index 466a5f3faf1c..283503f28788 100644 --- a/pkgs/tools/misc/snapper/default.nix +++ b/pkgs/tools/misc/snapper/default.nix @@ -5,13 +5,13 @@ stdenv.mkDerivation rec { pname = "snapper"; - version = "0.8.7"; + version = "0.8.8"; src = fetchFromGitHub { owner = "openSUSE"; repo = "snapper"; rev = "v${version}"; - sha256 = "0605j4f3plb6q8lwf82y2jhply6dwj49jgxk8j16wsbf5k7lqzfq"; + sha256 = "0wpf82xf61r9r20whhb83wk3408wac1if8awqm3bb36b9j7ni5jr"; }; nativeBuildInputs = [ |