mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-25 03:17:13 +00:00
e75f922e91
Updates to the latest version of the desktop client available. Tested the config migration from `nextcloud-client` 2.3.3 with a Nextcloud 14.0.3 instance (hosted using `services.nextcloud`). Additionally the derivation required the following changes: * Dropped `Qt5Sql` patch: this has been fixed upstream and isn't needed anymore (furthermore their CMake structure has changed and the patch wouldn't apply anymore on 2.5.0). * Moved to a new upstream repository (nextcloud/desktop), kept `fetchgit` to properly fetch submodules. * Added OpenSSL 1.1 integration: `libsync` (the syncing provided by this package) requires 1.1, furthermore the linking flags had to be fixed manually by passing `NIX_LDFLAGS` to the derivation. Furthermore I moved the support for a Gnome3 keyring into its own wrapper to avoid a full rebuild of the package whenever you alter `withGnomeKeyring` in an override expressions. It's still possible to enable keyring (now without recompile) like this: ``` nextcloud-client.override { withGnomeKeyring = true; } ``` To override the derivation itself you now have to use `nextcloud-client-unwrapped`: ``` nextcloud-client-unwrapped.overrideAttrs (old: { src = yoursrc; }) ```
46 lines
1.4 KiB
Nix
46 lines
1.4 KiB
Nix
{ stdenv, fetchgit, cmake, pkgconfig, qtbase, qtwebkit, qtkeychain, qttools, sqlite
|
|
, inotify-tools, makeWrapper, libgnome-keyring, openssl_1_1, pcre, qtwebengine
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
name = "nextcloud-client-${version}";
|
|
version = "2.5.0";
|
|
|
|
src = fetchgit {
|
|
url = "git://github.com/nextcloud/desktop.git";
|
|
rev = "refs/tags/v${version}";
|
|
sha256 = "1wz5bz4nmni0qxzcvgmpg9ywrfixzvdd7ixgqmdm4d8g6dm8pk9k";
|
|
fetchSubmodules = true;
|
|
};
|
|
|
|
nativeBuildInputs = [ pkgconfig cmake ];
|
|
|
|
buildInputs = [ qtbase qtwebkit qtkeychain qttools qtwebengine sqlite openssl_1_1.out pcre inotify-tools ];
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
NIX_LDFLAGS = "${openssl_1_1.out}/lib/libssl.so ${openssl_1_1.out}/lib/libcrypto.so";
|
|
|
|
cmakeFlags = [
|
|
"-UCMAKE_INSTALL_LIBDIR"
|
|
"-DCMAKE_BUILD_TYPE=Release"
|
|
"-DOPENSSL_LIBRARIES=${openssl_1_1.out}/lib"
|
|
"-DOPENSSL_INCLUDE_DIR=${openssl_1_1.dev}/include"
|
|
"-DINOTIFY_LIBRARY=${inotify-tools}/lib/libinotifytools.so"
|
|
"-DINOTIFY_INCLUDE_DIR=${inotify-tools}/include"
|
|
];
|
|
|
|
postInstall = ''
|
|
sed -i 's/\(Icon.*\)=nextcloud/\1=Nextcloud/g' \
|
|
$out/share/applications/nextcloud.desktop
|
|
'';
|
|
|
|
meta = with stdenv.lib; {
|
|
description = "Nextcloud themed desktop client";
|
|
homepage = https://nextcloud.com;
|
|
license = licenses.gpl2;
|
|
maintainers = with maintainers; [ caugner ma27 ];
|
|
platforms = platforms.linux;
|
|
};
|
|
}
|