1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
{ lib, mkDerivation, fetchFromGitHub, installShellFiles,
qmake, qtbase, qtmultimedia,
poppler, mupdf, jbig2dec, openjpeg, gumbo,
renderer ? "mupdf" }:
let
renderers = {
mupdf.buildInputs = [ mupdf jbig2dec openjpeg gumbo ];
poppler.buildInputs = [ poppler ];
};
in mkDerivation rec {
pname = "beamerpresenter";
version = "0.2.0";
src = fetchFromGitHub {
owner = "stiglers-eponym";
repo = "BeamerPresenter";
rev = "v${version}";
sha256 = "10i5nc5b5syaqvsixam4lmfiz3b5cphbjfgfqavi5jilq769792a";
};
nativeBuildInputs = [ qmake installShellFiles ];
buildInputs = [ qtbase qtmultimedia ] ++ renderers.${renderer}.buildInputs;
qmakeFlags = [ "RENDERER=${renderer}" ];
postPatch = ''
shopt -s globstar
for f in **/*.{pro,conf,h,cpp}; do
substituteInPlace "$f" \
--replace "/usr/" "$out/" \
--replace "/etc/" "$out/etc/" \
--replace '$${GUI_CONFIG_PATH}' "$out/etc/xdg/beamerpresenter/gui.json"
done
'';
meta = with lib; {
description = "Modular multi screen pdf presentation software respecting your window manager";
homepage = "https://github.com/stiglers-eponym/BeamerPresenter";
license = licenses.agpl3Plus;
platforms = platforms.all;
maintainers = with maintainers; [ pacien ];
};
}
|