2017-11-26 16:32:18 +01:00
|
|
|
{ stdenv, lib, fetchFromGitHub, qtbase, qtquickcontrols, cmake, libqmatrixclient }:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "quaternion-${version}";
|
2018-04-30 11:22:20 +02:00
|
|
|
version = "0.0.9";
|
2017-11-26 16:32:18 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "QMatrixClient";
|
|
|
|
repo = "Quaternion";
|
|
|
|
rev = "v${version}";
|
2018-04-30 11:22:20 +02:00
|
|
|
sha256 = "0zdpll953a7biwnklhgmgg3k2vz7j58lc1nmfkmvsfcj1fmdf408";
|
2017-04-16 10:52:51 +02:00
|
|
|
};
|
|
|
|
|
2017-11-26 16:32:18 +01:00
|
|
|
buildInputs = [ qtbase qtquickcontrols libqmatrixclient ];
|
|
|
|
|
2017-05-17 21:26:11 +02:00
|
|
|
nativeBuildInputs = [ cmake ];
|
2017-04-16 10:52:51 +02:00
|
|
|
|
2018-04-30 11:22:20 +02:00
|
|
|
# libqmatrixclient is now compiled as a dynamic library but quarternion cannot use it yet
|
|
|
|
# https://github.com/QMatrixClient/Quaternion/issues/239
|
2017-11-26 16:32:18 +01:00
|
|
|
postPatch = ''
|
|
|
|
rm -rf lib
|
|
|
|
ln -s ${libqmatrixclient.src} lib
|
|
|
|
'';
|
2017-04-16 10:52:51 +02:00
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
substituteInPlace $out/share/applications/quaternion.desktop \
|
|
|
|
--replace 'Exec=quaternion' "Exec=$out/bin/quaternion"
|
|
|
|
'';
|
|
|
|
|
2017-05-17 21:26:11 +02:00
|
|
|
meta = with lib; {
|
2017-04-16 10:52:51 +02:00
|
|
|
description = "Cross-platform desktop IM client for the Matrix protocol";
|
2017-07-12 17:50:04 +02:00
|
|
|
homepage = https://matrix.org/docs/projects/client/quaternion.html;
|
|
|
|
license = licenses.gpl3;
|
2017-04-16 10:52:51 +02:00
|
|
|
maintainers = with maintainers; [ peterhoeg ];
|
|
|
|
inherit (qtbase.meta) platforms;
|
|
|
|
inherit version;
|
|
|
|
};
|
|
|
|
}
|