mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-06 04:53:27 +00:00
571c71e6f7
We are migrating packages that meet below requirements: 1. using `callPackage` 2. called path is a directory 3. overriding set is empty (`{ }`) 4. not containing path expressions other than relative path (to makenixpkgs-vet happy) 5. not referenced by nix files outside of the directory, other than`pkgs/top-level/all-packages.nix` 6. not referencing nix files outside of the directory 7. not referencing `default.nix` (since it's changed to `package.nix`) 8. `outPath` doesn't change after migration The tool is here: https://github.com/Aleksanaa/by-name-migrate.
30 lines
834 B
Nix
30 lines
834 B
Nix
{ lib, stdenv, fetchurl }:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "which";
|
|
version = "2.21";
|
|
|
|
src = fetchurl {
|
|
url = "mirror://gnu/which/which-${version}.tar.gz";
|
|
hash = "sha256-9KJFuUEks3fYtJZGv0IfkVXTaqdhS26/g3BdP/x26q0=";
|
|
};
|
|
|
|
strictDeps = true;
|
|
enableParallelBuilding = true;
|
|
|
|
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"
|
|
);
|
|
|
|
meta = {
|
|
homepage = "https://www.gnu.org/software/which/";
|
|
description = "Shows the full path of (shell) commands";
|
|
license = lib.licenses.gpl3Plus;
|
|
mainProgram = "which";
|
|
platforms = lib.platforms.all;
|
|
};
|
|
}
|