sleepyhead: use qt5.makeDerivation and fix for Darwin (#88806)

gstqt5
Gregor Pogačnik 2020-05-25 01:35:40 +02:00 committed by GitHub
parent 08b229bde0
commit 4c1bab5057
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 15 additions and 7 deletions

View File

@ -1,9 +1,9 @@
{ stdenv, fetchgit, qt5, zlib, libGLU, libX11 }:
{ lib, stdenv, mkDerivation, fetchgit, zlib, libGLU, libX11, qtbase, qtwebkit, qtserialport, wrapQtAppsHook }:
let
name = "sleepyhead-${version}";
version = "1.0.0-beta-git";
in stdenv.mkDerivation {
in mkDerivation {
inherit name;
src = fetchgit {
@ -13,21 +13,30 @@ in stdenv.mkDerivation {
};
buildInputs = [
qt5.qtbase qt5.qtwebkit qt5.qtserialport
qtbase qtwebkit qtserialport
zlib
libGLU
libX11
];
nativeBuildInputs = [ wrapQtAppsHook ];
patchPhase = ''
patchShebangs configure
'';
installPhase = ''
installPhase = if stdenv.isDarwin then ''
mkdir -p $out/Applications
cp -r sleepyhead/SleepyHead.app $out/Applications
'' else ''
mkdir -p $out/bin
cp sleepyhead/SleepyHead $out/bin
'';
postFixup = stdenv.lib.optionalString stdenv.isDarwin ''
wrapQtApp "$out/Applications/SleepyHead.app/Contents/MacOS/SleepyHead"
'';
meta = with stdenv.lib; {
homepage = "https://sleepyhead.jedimark.net/";
description = "Review and explore data produced by CPAP and related machines";
@ -37,7 +46,6 @@ in stdenv.mkDerivation {
license = licenses.gpl3;
platforms = platforms.all;
maintainers = [ maintainers.krav ];
broken = true;
};
}

View File

@ -6660,7 +6660,7 @@ in
sleuthkit = callPackage ../tools/system/sleuthkit {};
sleepyhead = callPackage ../applications/misc/sleepyhead {};
sleepyhead = libsForQt5.callPackage ../applications/misc/sleepyhead {};
slirp4netns = callPackage ../tools/networking/slirp4netns/default.nix { };