nixpkgs/pkgs/applications/networking/instant-messengers/quaternion/default.nix

48 lines
1.2 KiB
Nix
Raw Normal View History

{ mkDerivation, stdenv, lib, fetchFromGitHub, cmake
2020-04-02 23:31:37 +01:00
, qtbase, qtquickcontrols, qtquickcontrols2, qtkeychain, qtmultimedia, qttools
, libquotient, libsecret
}:
2017-11-26 15:32:18 +00:00
2020-04-02 23:31:37 +01:00
mkDerivation rec {
pname = "quaternion";
2020-12-29 22:17:49 +00:00
version = "0.0.9.5-beta2";
2017-04-16 09:52:51 +01:00
2020-04-02 23:31:37 +01:00
src = fetchFromGitHub {
owner = "QMatrixClient";
repo = "Quaternion";
rev = version;
2020-12-29 22:17:49 +00:00
sha256 = "sha256-K4SMB5kL0YO2OIeNUu4hWqU4E4n4vZDRRsJVYmCZqvM=";
2017-04-16 09:52:51 +01:00
};
2019-04-10 08:07:01 +01:00
2020-04-02 23:31:37 +01:00
buildInputs = [
qtbase
qtmultimedia
qtquickcontrols
qtquickcontrols2
qtkeychain
libquotient
libsecret
];
nativeBuildInputs = [ cmake qttools ];
postInstall = if stdenv.isDarwin then ''
mkdir -p $out/Applications
mv $out/bin/quaternion.app $out/Applications
rmdir $out/bin || :
'' else ''
substituteInPlace $out/share/applications/com.github.quaternion.desktop \
--replace 'Exec=quaternion' "Exec=$out/bin/quaternion"
'';
meta = with lib; {
description =
"Cross-platform desktop IM client for the Matrix protocol";
homepage = "https://matrix.org/docs/projects/client/quaternion.html";
license = licenses.gpl3;
maintainers = with maintainers; [ peterhoeg ];
inherit (qtbase.meta) platforms;
inherit version;
};
2017-04-16 09:52:51 +01:00
}