about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/libverto/default.nix
blob: d161f2b92b2b5cbf3e374cf6af1ef52ebce25990 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
{ lib
, stdenv
, fetchFromGitHub
, autoreconfHook
, glib
, libev
, libevent
, pkg-config
, glibSupport ? true
, libevSupport ? true
, libeventSupport ? true
}:

let
  inherit (lib) optional;
in
stdenv.mkDerivation (finalAttrs: {
  pname = "libverto";
  version = "0.3.2";

  src = fetchFromGitHub {
    owner = "latchset";
    repo = "libverto";
    rev = finalAttrs.version;
    hash = "sha256-csoJ0WdKyrza8kBSMKoaItKvcbijI6Wl8nWCbywPScQ=";
  };

  nativeBuildInputs = [
    autoreconfHook
    pkg-config
  ];

  buildInputs =
    optional glibSupport glib
    ++ optional libevSupport libev
    ++ optional libeventSupport libevent;

  meta = with lib; {
    homepage = "https://github.com/latchset/libverto";
    description = "Asynchronous event loop abstraction library";
    longDescription = ''
      Libverto exists to solve an important problem: many applications and
      libraries are unable to write asynchronous code because they are unable to
      pick an event loop. This is particularly true of libraries who want to be
      useful to many applications who use loops that do not integrate with one
      another or which use home-grown loops. libverto provides a loop-neutral
      async api which allows the library to expose asynchronous interfaces and
      offload the choice of the main loop to the application.
    '';
    license = licenses.mit;
    maintainers = with maintainers; [ AndersonTorres ];
    platforms = platforms.unix;
  };
})