2021-01-11 07:54:33 +00:00
|
|
|
{ lib, stdenv, fetchurl }:
|
2009-02-03 16:32:56 +00:00
|
|
|
|
2015-03-26 05:42:36 +00:00
|
|
|
stdenv.mkDerivation rec {
|
2021-07-27 14:46:40 +00:00
|
|
|
pname = "which";
|
|
|
|
version = "2.21";
|
2016-02-22 18:32:53 +00:00
|
|
|
|
2003-12-23 20:51:58 +00:00
|
|
|
src = fetchurl {
|
2021-07-27 14:46:40 +00:00
|
|
|
url = "mirror://gnu/which/which-${version}.tar.gz";
|
2023-10-23 01:20:09 +00:00
|
|
|
hash = "sha256-9KJFuUEks3fYtJZGv0IfkVXTaqdhS26/g3BdP/x26q0=";
|
2003-12-23 20:51:58 +00:00
|
|
|
};
|
2008-01-20 18:23:55 +00:00
|
|
|
|
2022-05-21 16:58:22 +00:00
|
|
|
strictDeps = true;
|
2022-05-14 01:13:49 +00:00
|
|
|
enableParallelBuilding = true;
|
2022-05-21 16:58:22 +00:00
|
|
|
|
2023-09-05 08:24:28 +00:00
|
|
|
env.NIX_CFLAGS_COMPILE = toString (
|
|
|
|
# Enable 64-bit file API. Otherwise `which` fails to find tools
|
|
|
|
# on filesystems with 64-bit inodes (like `btrfs`) when running
|
|
|
|
# binaries from 32-bit systems (like `i686-linux`).
|
|
|
|
lib.optional stdenv.hostPlatform.is32bit "-D_FILE_OFFSET_BITS=64"
|
|
|
|
);
|
|
|
|
|
2023-10-23 01:18:38 +00:00
|
|
|
meta = {
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://www.gnu.org/software/which/";
|
2019-10-06 04:59:27 +00:00
|
|
|
description = "Shows the full path of (shell) commands";
|
2023-10-23 01:18:38 +00:00
|
|
|
license = lib.licenses.gpl3Plus;
|
|
|
|
mainProgram = "which";
|
|
|
|
platforms = lib.platforms.all;
|
2009-02-03 16:32:56 +00:00
|
|
|
};
|
|
|
|
}
|