nixpkgs/pkgs/by-name/li/libqb/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

37 lines
1.0 KiB
Nix

{ lib, stdenv, fetchFromGitHub, fetchpatch, autoreconfHook, pkg-config, libxml2 }:
stdenv.mkDerivation rec {
pname = "libqb";
version = "2.0.8";
src = fetchFromGitHub {
owner = "ClusterLabs";
repo = pname;
rev = "v${version}";
sha256 = "sha256-ZjxC7W4U8T68mZy/OvWj/e4W9pJIj2lVDoEjxXYr/G8=";
};
patches = [
# add a declaration of fdatasync, missing on darwin https://github.com/ClusterLabs/libqb/pull/496
(fetchpatch {
url = "https://github.com/ClusterLabs/libqb/commit/255ccb70ee19cc0c82dd13e4fd5838ca5427795f.patch";
hash = "sha256-6x4B3FM0XSRIeAly8JtMOGOdyunTcbaDzUeBZInXR4U=";
})
];
nativeBuildInputs = [ autoreconfHook pkg-config ];
buildInputs = [ libxml2 ];
postPatch = ''
sed -i '/# --enable-new-dtags:/,/--enable-new-dtags is required/ d' configure.ac
'';
meta = with lib; {
homepage = "https://github.com/clusterlabs/libqb";
description = "Library providing high performance logging, tracing, ipc, and poll";
license = licenses.lgpl21Plus;
platforms = platforms.unix;
};
}