nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 autoreconfHook,
3 fetchFromGitHub,
4 ghostscript,
5 lib,
6 pkg-config,
7 poppler,
8 stdenv,
9 texlive,
10}:
11
12stdenv.mkDerivation (finalAttrs: {
13 pname = "extractpdfmark";
14 version = "1.1.1";
15
16 src = fetchFromGitHub {
17 owner = "trueroad";
18 repo = "extractpdfmark";
19 rev = "v${finalAttrs.version}";
20 hash = "sha256-pNc/SWAtQWMbB2+lIQkJdBYSZ97iJXK71mS59qQa7Hs=";
21 };
22
23 patches = [
24 ./gettext-0.25.patch
25 ];
26
27 env = lib.optionalAttrs stdenv.hostPlatform.isDarwin {
28 NIX_LDFLAGS = "-liconv";
29 };
30
31 strictDeps = true;
32
33 nativeBuildInputs = [
34 autoreconfHook
35 pkg-config
36 ];
37
38 buildInputs = [
39 poppler
40 ];
41
42 doCheck = true;
43
44 nativeCheckInputs = [
45 ghostscript
46 texlive.combined.scheme-minimal
47 ];
48
49 meta = {
50 homepage = "https://github.com/trueroad/extractpdfmark";
51 description = "Extract page mode and named destinations as PDFmark from PDF";
52 license = lib.licenses.gpl3Plus;
53 maintainers = [ lib.maintainers.samueltardieu ];
54 platforms = lib.platforms.all;
55 mainProgram = "extractpdfmark";
56 };
57})