beamerpresenter: fix darwin build

This commit is contained in:
Dmitry Kalinkin 2021-05-10 08:27:30 +02:00
parent 76833b1206
commit a5fd5c36ce
2 changed files with 20 additions and 7 deletions

View file

@ -1,15 +1,17 @@
{ lib, mkDerivation, fetchFromGitHub, installShellFiles,
qmake, qtbase, qtmultimedia,
poppler, mupdf, jbig2dec, openjpeg, gumbo,
{ lib, stdenv, fetchFromGitHub, installShellFiles,
qmake, qtbase, qtmultimedia, wrapQtAppsHook,
poppler, mupdf, freetype, jbig2dec, openjpeg, gumbo,
renderer ? "mupdf" }:
let
renderers = {
mupdf.buildInputs = [ mupdf jbig2dec openjpeg gumbo ];
mupdf.buildInputs = [ mupdf freetype jbig2dec openjpeg gumbo ];
poppler.buildInputs = [ poppler ];
};
in mkDerivation rec {
in
stdenv.mkDerivation rec {
pname = "beamerpresenter";
version = "0.2.0";
@ -20,7 +22,7 @@ in mkDerivation rec {
sha256 = "10i5nc5b5syaqvsixam4lmfiz3b5cphbjfgfqavi5jilq769792a";
};
nativeBuildInputs = [ qmake installShellFiles ];
nativeBuildInputs = [ qmake installShellFiles wrapQtAppsHook ];
buildInputs = [ qtbase qtmultimedia ] ++ renderers.${renderer}.buildInputs;
qmakeFlags = [ "RENDERER=${renderer}" ];
@ -35,6 +37,10 @@ in mkDerivation rec {
done
'';
postInstall = lib.optionalString stdenv.isDarwin ''
wrapQtApp "$out"/bin/beamerpresenter.app/Contents/MacOS/beamerpresenter
'';
meta = with lib; {
description = "Modular multi screen pdf presentation software respecting your window manager";
homepage = "https://github.com/stiglers-eponym/BeamerPresenter";

View file

@ -3214,7 +3214,14 @@ in
bdsync = callPackage ../tools/backup/bdsync { };
beamerpresenter = libsForQt5.callPackage ../applications/office/beamerpresenter { };
beamerpresenter = libsForQt5.callPackage ../applications/office/beamerpresenter {
# developed for a compiler with C++20 support
stdenv =
if stdenv.isDarwin then
overrideCC stdenv clang_10
else
stdenv;
};
beanstalkd = callPackage ../servers/beanstalkd { };