1 { lib, stdenv, fetchFromGitHub
3 , vala, cmake, ninja, wrapGAppsHook4, pkg-config, gettext
4 , gobject-introspection, glib, gdk-pixbuf, gtk4, glib-networking
6 , libnotify, libsoup, libgee
23 , webrtc-audio-processing
26 stdenv.mkDerivation (finalAttrs: {
30 src = fetchFromGitHub {
33 rev = "v${finalAttrs.version}";
34 sha256 = "sha256-I0ASeEjdXyxhz52QisU0q8mIBTKMfjaspJbxRIyOhD4=";
38 # don't overwrite manually set version information
39 substituteInPlace CMakeLists.txt \
40 --replace "include(ComputeVersion)" ""
46 ninja # https://github.com/dino/dino/issues/230
56 glib-networking # required for TLS support
75 gst-plugins-good # contains rtpbin, required for VP9
76 gst-plugins-bad # required for H264, MSDK
77 gst-vaapi # required for VAAPI
78 webrtc-audio-processing
83 "-DRTP_ENABLE_H264=true"
84 "-DRTP_ENABLE_MSDK=true"
85 "-DRTP_ENABLE_VAAPI=true"
86 "-DRTP_ENABLE_VP9=true"
87 "-DVERSION_FOUND=true"
88 "-DVERSION_IS_RELEASE=true"
89 "-DVERSION_FULL=${finalAttrs.version}"
90 "-DXGETTEXT_EXECUTABLE=${lib.getBin buildPackages.gettext}/bin/xgettext"
91 "-DMSGFMT_EXECUTABLE=${lib.getBin buildPackages.gettext}/bin/msgfmt"
92 "-DGLIB_COMPILE_RESOURCES_EXECUTABLE=${lib.getDev buildPackages.glib}/bin/glib-compile-resources"
93 "-DSOUP_VERSION=${lib.versions.major libsoup.version}"
96 # Undefined symbols for architecture arm64: "_gpg_strerror"
97 NIX_LDFLAGS = lib.optionalString stdenv.hostPlatform.isDarwin "-lgpg-error";
103 ./signal-protocol-vala-test
107 # Dino looks for plugins with a .so filename extension, even on macOS where
108 # .dylib is appropriate, and despite the fact that it builds said plugins with
109 # that as their filename extension
111 # Therefore, on macOS rename all of the plugins to use correct names that Dino
114 # See https://github.com/dino/dino/wiki/macOS
115 postFixup = lib.optionalString (stdenv.hostPlatform.isDarwin) ''
116 cd "$out/lib/dino/plugins/"
118 mv "$f" "$(basename "$f" .dylib).so"
123 description = "Modern Jabber/XMPP Client using GTK/Vala";
124 mainProgram = "dino";
125 homepage = "https://github.com/dino/dino";
126 license = licenses.gpl3Plus;
127 platforms = platforms.linux ++ platforms.darwin;
128 maintainers = with maintainers; [ qyliss tomfitzhenry ];