2021-10-14 00:43:12 +00:00
|
|
|
{ stdenv
|
|
|
|
, lib
|
|
|
|
, fetchurl
|
2021-02-05 17:12:51 +00:00
|
|
|
, pkg-config
|
2020-04-24 23:36:52 +00:00
|
|
|
, meson
|
|
|
|
, ninja
|
|
|
|
, glib
|
2021-05-20 23:08:51 +00:00
|
|
|
, gnome
|
2020-04-24 23:36:52 +00:00
|
|
|
, gettext
|
|
|
|
, gobject-introspection
|
|
|
|
, vala
|
|
|
|
, sqlite
|
|
|
|
, dbus-glib
|
|
|
|
, dbus
|
|
|
|
, libgee
|
2022-10-21 18:38:19 +00:00
|
|
|
, evolution-data-server-gtk4
|
2020-04-24 23:36:52 +00:00
|
|
|
, python3
|
|
|
|
, readline
|
|
|
|
, gtk-doc
|
|
|
|
, docbook-xsl-nons
|
|
|
|
, docbook_xml_dtd_43
|
2020-11-12 09:05:59 +00:00
|
|
|
, telepathy-glib
|
|
|
|
, telepathySupport ? false
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
# TODO: enable more folks backends
|
|
|
|
|
2024-01-25 14:12:00 +00:00
|
|
|
stdenv.mkDerivation (finalAttrs: {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "folks";
|
2024-01-13 08:15:51 +00:00
|
|
|
version = "0.15.7";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
outputs = [ "out" "dev" "devdoc" ];
|
|
|
|
|
|
|
|
src = fetchurl {
|
2024-01-25 14:12:00 +00:00
|
|
|
url = "mirror://gnome/sources/folks/${lib.versions.majorMinor finalAttrs.version}/folks-${finalAttrs.version}.tar.xz";
|
2024-01-13 08:15:51 +00:00
|
|
|
sha256 = "Eg8hnvYyEsqpWuf2rrZOKZKLCxqLlFIFQwSgDQ80eHE=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
gettext
|
|
|
|
gobject-introspection
|
|
|
|
gtk-doc
|
|
|
|
docbook-xsl-nons
|
|
|
|
docbook_xml_dtd_43
|
|
|
|
meson
|
|
|
|
ninja
|
2021-02-05 17:12:51 +00:00
|
|
|
pkg-config
|
2020-04-24 23:36:52 +00:00
|
|
|
vala
|
2022-10-21 18:38:19 +00:00
|
|
|
] ++ lib.optionals telepathySupport [
|
|
|
|
python3
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
dbus-glib
|
2022-10-21 18:38:19 +00:00
|
|
|
evolution-data-server-gtk4 # UI part not needed, using gtk4 version to reduce system closure.
|
2020-04-24 23:36:52 +00:00
|
|
|
readline
|
2022-10-21 18:38:19 +00:00
|
|
|
] ++ lib.optionals telepathySupport [
|
|
|
|
telepathy-glib
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
glib
|
|
|
|
libgee
|
|
|
|
sqlite
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2020-04-24 23:36:52 +00:00
|
|
|
dbus
|
|
|
|
(python3.withPackages (pp: with pp; [
|
|
|
|
python-dbusmock
|
|
|
|
# The following possibly need to be propagated by dbusmock
|
|
|
|
# if they are not optional
|
|
|
|
dbus-python
|
|
|
|
pygobject3
|
|
|
|
]))
|
|
|
|
];
|
|
|
|
|
2021-05-20 23:08:51 +00:00
|
|
|
mesonFlags = [
|
|
|
|
"-Ddocs=true"
|
|
|
|
"-Dtelepathy_backend=${lib.boolToString telepathySupport}"
|
2024-01-25 14:12:00 +00:00
|
|
|
"-Dtests=${lib.boolToString (finalAttrs.doCheck && stdenv.isLinux)}"
|
2021-05-20 23:08:51 +00:00
|
|
|
];
|
|
|
|
|
2024-01-13 08:15:51 +00:00
|
|
|
# backends/eds/lib/libfolks-eds.so.26.0.0.p/edsf-persona-store.c:10697:4:
|
|
|
|
# error: call to undeclared function 'folks_persona_store_set_is_user_set_default';
|
|
|
|
# ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
|
|
|
|
env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.cc.isClang "-Wno-error=implicit-function-declaration";
|
|
|
|
|
2024-01-25 14:12:00 +00:00
|
|
|
# Checks last re-enabled in https://github.com/NixOS/nixpkgs/pull/279843, but timeouts in tests still
|
|
|
|
# occur inconsistently
|
|
|
|
doCheck = false;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-03-15 08:37:03 +00:00
|
|
|
# Prevents e-d-s add-contacts-stress-test from timing out
|
|
|
|
checkPhase = ''
|
|
|
|
runHook preCheck
|
|
|
|
meson test --timeout-multiplier 4
|
|
|
|
runHook postCheck
|
|
|
|
'';
|
|
|
|
|
2022-10-21 18:38:19 +00:00
|
|
|
postPatch = lib.optionalString telepathySupport ''
|
2020-04-24 23:36:52 +00:00
|
|
|
patchShebangs tests/tools/manager-file.py
|
|
|
|
'';
|
|
|
|
|
|
|
|
passthru = {
|
2021-05-20 23:08:51 +00:00
|
|
|
updateScript = gnome.updateScript {
|
2024-01-25 14:12:00 +00:00
|
|
|
packageName = "folks";
|
2020-04-24 23:36:52 +00:00
|
|
|
versionPolicy = "none";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "A library that aggregates people from multiple sources to create metacontacts";
|
|
|
|
homepage = "https://wiki.gnome.org/Projects/Folks";
|
2023-04-12 12:48:02 +00:00
|
|
|
license = licenses.lgpl21Plus;
|
2020-04-24 23:36:52 +00:00
|
|
|
maintainers = teams.gnome.members;
|
2022-12-28 21:21:41 +00:00
|
|
|
platforms = platforms.unix;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
2024-01-25 14:12:00 +00:00
|
|
|
})
|