1{
2 lib,
3 stdenv,
4 fetchurl,
5 updateAutotoolsGnuConfigScriptsHook,
6 # Note: -static hasn’t work on darwin
7 static ? with stdenv.hostPlatform; isStatic && !isDarwin,
8}:
9
10# Note: this package is used for bootstrapping fetchurl, and thus
11# cannot use fetchpatch! All mutable patches (generated by GitHub or
12# cgit) that are needed here should be included directly in Nixpkgs as
13# files.
14
15stdenv.mkDerivation rec {
16 pname = "libev";
17 version = "4.33";
18
19 src = fetchurl {
20 url = "http://dist.schmorp.de/libev/Attic/${pname}-${version}.tar.gz";
21 sha256 = "1sjs4324is7fp21an4aas2z4dwsvs6z4xwrmp72vwpq1s6wbfzjh";
22 };
23
24 nativeBuildInputs = [ updateAutotoolsGnuConfigScriptsHook ];
25
26 configureFlags = lib.optional (static) "LDFLAGS=-static";
27
28 meta = {
29 description = "High-performance event loop/event model with lots of features";
30 maintainers = [ lib.maintainers.raskin ];
31 platforms = lib.platforms.all;
32 license = lib.licenses.bsd2; # or GPL2+
33 };
34}