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

99 lines
2.2 KiB
Nix
Raw Normal View History

{ lib, stdenv, fetchFromGitHub
, vala, cmake, ninja, wrapGAppsHook, pkgconfig, gettext
2019-05-22 12:03:39 +01:00
, gobject-introspection, gnome3, glib, gdk-pixbuf, gtk3, glib-networking
2017-04-20 13:56:04 +01:00
, xorg, libXdmcp, libxkbcommon
, libnotify, libsoup, libgee
, librsvg, libsignal-protocol-c
, fetchpatch
2017-04-20 13:56:04 +01:00
, libgcrypt
, epoxy
, at-spi2-core
2017-04-20 13:56:04 +01:00
, sqlite
, dbus
, gpgme
, pcre
2018-11-27 14:49:30 +00:00
, qrencode
2019-02-06 00:54:07 +00:00
, icu
2017-04-20 13:56:04 +01:00
}:
stdenv.mkDerivation rec {
pname = "dino";
version = "0.1.0";
2017-04-20 13:56:04 +01:00
src = fetchFromGitHub {
owner = "dino";
repo = "dino";
rev = "v${version}";
sha256 = "1k5cgj5n8s40i71wqdh6m1q0njl45ichfdbbywx9rga5hljz1c54";
2017-04-20 13:56:04 +01:00
};
patches = [
(fetchpatch {
# Allow newer versions of libsignal-protocol-c
url = "https://github.com/dino/dino/commit/fbd70ceaac5ebbddfa21a580c61165bf5b861303.patch";
sha256 = "0ydpwsmwrzfsry89fsffkfalhki4n1dw99ixjvpiingdrhjmwyl2";
excludes = [ "plugins/signal-protocol/libsignal-protocol-c" ];
})
];
2017-04-20 13:56:04 +01:00
nativeBuildInputs = [
vala
cmake
ninja
2017-04-20 13:56:04 +01:00
pkgconfig
wrapGAppsHook
2019-02-06 00:54:07 +00:00
gettext
2017-04-20 13:56:04 +01:00
];
buildInputs = [
2018-11-27 14:49:30 +00:00
qrencode
gobject-introspection
glib-networking
2017-04-20 13:56:04 +01:00
glib
2019-02-13 21:47:50 +00:00
libgee
gnome3.adwaita-icon-theme
2017-04-20 13:56:04 +01:00
sqlite
2019-05-22 12:03:39 +01:00
gdk-pixbuf
2017-04-20 13:56:04 +01:00
gtk3
libnotify
gpgme
libgcrypt
2017-09-20 12:01:13 +01:00
libsoup
2017-04-20 13:56:04 +01:00
pcre
epoxy
at-spi2-core
2017-04-20 13:56:04 +01:00
dbus
2019-02-06 00:54:07 +00:00
icu
libsignal-protocol-c
librsvg
] ++ lib.optionals (!stdenv.isDarwin) [
xorg.libxcb
xorg.libpthreadstubs
libXdmcp
libxkbcommon
2017-04-20 13:56:04 +01:00
];
# Dino looks for plugins with a .so filename extension, even on macOS where
# .dylib is appropriate, and despite the fact that it builds said plugins with
# that as their filename extension
#
# Therefore, on macOS rename all of the plugins to use correct names that Dino
# will load
#
# See https://github.com/dino/dino/wiki/macOS
postFixup = lib.optionalString (stdenv.isDarwin) ''
cd "$out/lib/dino/plugins/"
for f in *.dylib; do
mv "$f" "$(basename "$f" .dylib).so"
done
'';
2017-04-20 13:56:04 +01:00
meta = with stdenv.lib; {
description = "Modern Jabber/XMPP Client using GTK/Vala";
homepage = "https://github.com/dino/dino";
2017-04-20 13:56:04 +01:00
license = licenses.gpl3;
platforms = platforms.linux ++ platforms.darwin;
2020-01-30 00:29:11 +00:00
maintainers = with maintainers; [ mic92 qyliss ];
2017-04-20 13:56:04 +01:00
};
}