nixpkgs/pkgs/tools/system/bfs/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

37 lines
1.2 KiB
Nix
Raw Normal View History

{ lib, stdenv, fetchFromGitHub, libcap, acl, oniguruma, liburing }:
2018-02-11 18:16:46 +03:00
stdenv.mkDerivation rec {
pname = "bfs";
version = "3.1.3";
2018-02-11 18:16:46 +03:00
src = fetchFromGitHub {
repo = "bfs";
owner = "tavianator";
rev = version;
hash = "sha256-/thPPueNrYzbxxZYAqlxZ2GEsceCzd+LkI84S8AS1mo=";
2018-02-11 18:16:46 +03:00
};
buildInputs = [ oniguruma ] ++ lib.optionals stdenv.isLinux [ libcap acl liburing ];
2018-02-11 18:16:46 +03:00
# Disable LTO on darwin. See https://github.com/NixOS/nixpkgs/issues/19098
2021-01-15 12:19:50 +03:00
preConfigure = lib.optionalString stdenv.isDarwin ''
2023-11-15 19:20:29 +03:00
substituteInPlace GNUMakefile --replace "-flto=auto" ""
'';
2018-02-11 18:16:46 +03:00
makeFlags = [ "PREFIX=$(out)" ];
buildFlags = [ "release" ]; # "release" enables compiler optimizations
meta = with lib; {
2018-02-11 18:16:46 +03:00
description = "A breadth-first version of the UNIX find command";
longDescription = ''
bfs is a variant of the UNIX find command that operates breadth-first rather than
depth-first. It is otherwise intended to be compatible with many versions of find.
'';
2020-02-26 00:19:16 +03:00
homepage = "https://github.com/tavianator/bfs";
2018-02-11 18:16:46 +03:00
license = licenses.bsd0;
2019-01-04 06:36:49 +03:00
platforms = platforms.unix;
maintainers = with maintainers; [ yesbox cafkafk ];
mainProgram = "bfs";
2018-02-11 18:16:46 +03:00
};
}