mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-17 09:34:36 +00:00
beamerpresenter: 0.1.3 -> 0.2.0
This commit is contained in:
parent
44d6925c3f
commit
76833b1206
@ -1,39 +1,44 @@
|
||||
{ lib, mkDerivation, fetchFromGitHub, installShellFiles,
|
||||
qmake, qtbase, poppler, qtmultimedia }:
|
||||
qmake, qtbase, qtmultimedia,
|
||||
poppler, mupdf, jbig2dec, openjpeg, gumbo,
|
||||
renderer ? "mupdf" }:
|
||||
|
||||
mkDerivation rec {
|
||||
let
|
||||
renderers = {
|
||||
mupdf.buildInputs = [ mupdf jbig2dec openjpeg gumbo ];
|
||||
poppler.buildInputs = [ poppler ];
|
||||
};
|
||||
|
||||
in mkDerivation rec {
|
||||
pname = "beamerpresenter";
|
||||
version = "0.1.3";
|
||||
version = "0.2.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "stiglers-eponym";
|
||||
repo = "BeamerPresenter";
|
||||
rev = "v${version}";
|
||||
sha256 = "1nbcqrfdjcsc6czqk1v163whka4x1w883b1298aws8yi7vac4f1i";
|
||||
sha256 = "10i5nc5b5syaqvsixam4lmfiz3b5cphbjfgfqavi5jilq769792a";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ qmake installShellFiles ];
|
||||
buildInputs = [ qtbase qtmultimedia poppler ];
|
||||
buildInputs = [ qtbase qtmultimedia ] ++ renderers.${renderer}.buildInputs;
|
||||
|
||||
qmakeFlags = [ "RENDERER=${renderer}" ];
|
||||
|
||||
postPatch = ''
|
||||
# Fix location of poppler-*.h
|
||||
shopt -s globstar
|
||||
for f in **/*.{h,cpp}; do
|
||||
substituteInPlace $f --replace '#include <poppler-' '#include <poppler/qt5/poppler-'
|
||||
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
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
install -m755 beamerpresenter -Dt $out/bin/
|
||||
install -m644 src/icons/beamerpresenter.svg -Dt $out/share/icons/hicolor/scalable/apps/
|
||||
install -m644 share/applications/beamerpresenter.desktop -Dt $out/share/applications/
|
||||
installManPage man/*.{1,5}
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Simple dual screen pdf presentation software";
|
||||
description = "Modular multi screen pdf presentation software respecting your window manager";
|
||||
homepage = "https://github.com/stiglers-eponym/BeamerPresenter";
|
||||
license = licenses.gpl3Plus;
|
||||
license = licenses.agpl3Plus;
|
||||
platforms = platforms.all;
|
||||
maintainers = with maintainers; [ pacien ];
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user