From 179e20b4922a156042f17442fb91054c1d610c6f Mon Sep 17 00:00:00 2001 From: AndersonTorres Date: Mon, 12 Dec 2022 10:39:42 -0300 Subject: [PATCH] libverto: init at 0.3.2 --- .../libraries/libverto/default.nix | 54 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 56 insertions(+) create mode 100644 pkgs/development/libraries/libverto/default.nix diff --git a/pkgs/development/libraries/libverto/default.nix b/pkgs/development/libraries/libverto/default.nix new file mode 100644 index 000000000000..d161f2b92b2b --- /dev/null +++ b/pkgs/development/libraries/libverto/default.nix @@ -0,0 +1,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; + }; +}) diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 7383aeceae9e..1a9d7fbcff63 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -21287,6 +21287,8 @@ with pkgs; libversion = callPackage ../development/libraries/libversion { }; + libverto = callPackage ../development/libraries/libverto { }; + libvgm = callPackage ../development/libraries/libvgm { inherit (darwin.apple_sdk.frameworks) CoreAudio AudioToolbox; };