nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 stdenv,
4 fetchFromGitHub,
5 cmake,
6 pkg-config,
7 pcre,
8}:
9
10stdenv.mkDerivation (finalAttrs: {
11 pname = "pplatex";
12 version = "1.0-unstable-2025-05-07";
13
14 src = fetchFromGitHub {
15 owner = "stefanhepp";
16 repo = "pplatex";
17 rev = "9f6cfb23c3b578f14ad2664cd754cb4a66dc790e";
18 sha256 = "sha256-vI7CujOn2J4qWiykTQj8wyRmfeTDvR0eiFKB2ElTNUk=";
19 };
20
21 nativeBuildInputs = [
22 cmake
23 pkg-config
24 ];
25 cmakeFlags = [
26 # https://github.com/NixOS/nixpkgs/issues/445447
27 (lib.cmakeFeature "CMAKE_POLICY_VERSION_MINIMUM" "3.5")
28 ];
29
30 buildInputs = [
31 pcre
32 ];
33
34 installPhase = ''
35 runHook preInstall
36 install -Dm555 src/pplatex "$out"/bin/pplatex
37 runHook postInstall
38 '';
39
40 meta = {
41 description = "Tool to reformat the output of latex and friends into readable messages";
42 mainProgram = "pplatex";
43 homepage = "https://github.com/stefanhepp/pplatex";
44 license = lib.licenses.gpl3Plus;
45 maintainers = [ lib.maintainers.doronbehar ];
46 platforms = lib.platforms.unix;
47 };
48})