Files
nixpkgs/pkgs/by-name/xm/xmltoman/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

56 lines
1.2 KiB
Nix

{
lib,
stdenvNoCC,
fetchFromGitHub,
perlPackages,
perl,
installShellFiles,
}:
stdenvNoCC.mkDerivation rec {
pname = "xmltoman";
version = "0.6";
src = fetchFromGitHub {
owner = "atsb";
repo = "xmltoman";
rev = version;
hash = "sha256-EmFdGIeBEcTY0Pqp7BJded9WB/DaXWcMNWh6aTsZlLg=";
};
nativeBuildInputs = [
perl
installShellFiles
];
buildInputs = [
perlPackages.XMLTokeParser
];
dontBuild = true;
# File installation and setup similar to Makefile commands below.
installPhase = ''
runHook preInstall
mkdir -p $out
perl xmltoman xml/xmltoman.1.xml > xmltoman.1
perl xmltoman xml/xmlmantohtml.1.xml > xmlmantohtml.1
install -d $out/bin $out/share/xmltoman
install -m 0755 xmltoman xmlmantohtml $out/bin
install -m 0644 xmltoman.dtd xmltoman.css xmltoman.xsl $out/share/xmltoman
installManPage *.1
runHook postInstall
'';
meta = with lib; {
description = "Two very simple scripts for converting xml to groff or html";
homepage = "https://github.com/atsb/xmltoman";
license = licenses.gpl2Only;
maintainers = with maintainers; [ tochiaha ];
mainProgram = "xmltoman";
platforms = platforms.all;
};
}