about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/libquotient/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/libquotient/default.nix')
-rw-r--r--nixpkgs/pkgs/development/libraries/libquotient/default.nix24
1 files changed, 16 insertions, 8 deletions
diff --git a/nixpkgs/pkgs/development/libraries/libquotient/default.nix b/nixpkgs/pkgs/development/libraries/libquotient/default.nix
index eea7eeb88fc7..c36bddc347f2 100644
--- a/nixpkgs/pkgs/development/libraries/libquotient/default.nix
+++ b/nixpkgs/pkgs/development/libraries/libquotient/default.nix
@@ -1,27 +1,35 @@
-{ mkDerivation, lib, fetchFromGitHub, cmake, qtmultimedia }:
+{ stdenv, lib, fetchFromGitHub, cmake, olm, openssl, qtbase, qtmultimedia, qtkeychain }:
 
-mkDerivation rec {
+stdenv.mkDerivation rec {
   pname = "libquotient";
-  version = "0.6.11";
+  version = "0.7.2";
 
   src = fetchFromGitHub {
     owner = "quotient-im";
     repo = "libQuotient";
     rev = version;
-    sha256 = "sha256-FPtxeZOfChIPi4e/h/eZkByH1QL3Fn0OJxe0dnMcTRw=";
+    hash = "sha256-Lq404O2VjZ8vlXOW+rhsvWDvZsNd3APNbv6AadQCjhk=";
   };
 
-  buildInputs = [ qtmultimedia ];
+  buildInputs = [ olm openssl qtbase qtmultimedia qtkeychain ];
 
   nativeBuildInputs = [ cmake ];
 
   cmakeFlags = [
-    # we need libqtolm for this
-    "-DQuotient_ENABLE_E2EE=OFF"
+    "-DQuotient_ENABLE_E2EE=ON"
   ];
 
+  # https://github.com/quotient-im/libQuotient/issues/551
+  postPatch = ''
+    substituteInPlace Quotient.pc.in \
+      --replace '$'{prefix}/@CMAKE_INSTALL_LIBDIR@ @CMAKE_INSTALL_FULL_LIBDIR@ \
+      --replace '$'{prefix}/@CMAKE_INSTALL_INCLUDEDIR@ @CMAKE_INSTALL_FULL_INCLUDEDIR@
+  '';
+
+  dontWrapQtApps = true;
+
   meta = with lib; {
-    description = "A Qt5 library to write cross-platform clients for Matrix";
+    description = "A Qt5/Qt6 library to write cross-platform clients for Matrix";
     homepage = "https://matrix.org/docs/projects/sdk/quotient";
     license = licenses.lgpl21;
     maintainers = with maintainers; [ colemickens ];