nixpkgs/pkgs/by-name/au/augeas/package.nix
aleksana 571c71e6f7 treewide: migrate packages to pkgs/by-name, take 1
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.
2024-11-09 20:04:51 +08:00

67 lines
1.3 KiB
Nix

{ lib
, stdenv
, fetchFromGitHub
, autoreconfHook
, bison
, flex
, perl # for pod2man
, pkg-config
, readline
, libxml2
}:
stdenv.mkDerivation rec {
pname = "augeas";
version = "1.14.1";
src = fetchFromGitHub {
owner = "hercules-team";
repo = "augeas";
rev = "release-${version}";
fetchSubmodules = true;
hash = "sha256-U5tm3LDUeI/idHtL2Zy33BigkyvHunXPjToDC59G9VE=";
};
patches = [
# already have the submodules so don't fail when .git doesn't exist.
./bootstrap.diff
];
postPatch = ''
./bootstrap --gnulib-srcdir=.gnulib
'';
nativeBuildInputs = [
autoreconfHook
bison
flex
perl
pkg-config
];
buildInputs = [ readline libxml2 ];
enableParallelBuilding = true;
doCheck = true;
checkPhase = ''
runHook preCheck
patchShebangs --build gnulib/tests tests
make -j $NIX_BUILD_CORES check
runHook postCheck
'';
outputs = [ "out" "dev" ];
meta = with lib; {
description = "Configuration editing tool";
license = licenses.lgpl21Only;
homepage = "https://augeas.net/";
changelog = "https://github.com/hercules-team/augeas/releases/tag/release-${version}";
mainProgram = "augtool";
maintainers = with maintainers; [ offline ];
platforms = platforms.unix;
};
}