nixpkgs/pkgs/os-specific/linux/libtracefs/default.nix
stuebinm ff1a94e523 treewide: add meta.mainProgram to packages with a single binary
The nixpkgs-unstable channel's programs.sqlite was used to identify
packages producing exactly one binary, and these automatically added
to their package definitions wherever possible.
2024-03-19 03:14:51 +01:00

64 lines
1.3 KiB
Nix

{ lib
, stdenv
, fetchzip
, pkg-config
, libtraceevent
, asciidoc
, xmlto
, docbook_xml_dtd_45
, docbook_xsl
, coreutils
, valgrind
, sourceHighlight
, meson
, flex
, bison
, ninja
, cunit
}:
stdenv.mkDerivation rec {
pname = "libtracefs";
version = "1.7.0";
src = fetchzip {
url = "https://git.kernel.org/pub/scm/libs/libtrace/libtracefs.git/snapshot/libtracefs-libtracefs-${version}.tar.gz";
hash = "sha256-64eXFFdnZHHf4C3vbADtPuIMsfJ85VZ6t8A1gIc1CW0=";
};
postPatch = ''
chmod +x samples/extract-example.sh
patchShebangs --build check-manpages.sh samples/extract-example.sh Documentation/install-docs.sh.in
'';
outputs = [ "out" "dev" "devman" "doc" ];
nativeBuildInputs = [
meson
ninja
pkg-config
asciidoc
xmlto
docbook_xml_dtd_45
docbook_xsl
valgrind
sourceHighlight
flex
bison
];
buildInputs = [ libtraceevent ];
ninjaFlags = [ "all" "docs" ];
doCheck = true;
checkInputs = [ cunit ];
meta = with lib; {
description = "Linux kernel trace file system library";
mainProgram = "sqlhist";
homepage = "https://git.kernel.org/pub/scm/libs/libtrace/libtracefs.git/";
license = licenses.lgpl21Only;
platforms = platforms.linux;
maintainers = with maintainers; [ wentasah ];
};
}