tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
lol
0
fork
atom
overview
issues
pulls
pipelines
corosync: 2.4.1 -> 2.4.2 + various improvements
montag451
9 years ago
f1cd1b40
e797cfae
+33
-22
1 changed file
expand all
collapse all
unified
split
pkgs
servers
corosync
default.nix
+33
-22
pkgs/servers/corosync/default.nix
···
1
1
{ stdenv, fetchurl, makeWrapper, pkgconfig, nss, nspr, libqb
2
2
-
, dbus ? null
3
3
-
, librdmacm ? null, libibverbs ? null
4
4
-
, libstatgrab ? null
5
5
-
, net_snmp ? null
2
2
+
, dbus, librdmacm, libibverbs, libstatgrab, net_snmp
3
3
+
, enableDbus ? false
4
4
+
, enableInfiniBandRdma ? false
5
5
+
, enableMonitoring ? false
6
6
+
, enableSnmp ? false
6
7
}:
7
8
8
9
with stdenv.lib;
10
10
+
9
11
stdenv.mkDerivation rec {
10
10
-
name = "corosync-2.4.1";
12
12
+
name = "corosync-2.4.2";
11
13
12
14
src = fetchurl {
13
15
url = "http://build.clusterlabs.org/corosync/releases/${name}.tar.gz";
14
14
-
sha256 = "0w8m97ih7a2g99pmjsckw4xwbgzv96xdgg62s2a4qbgnw4yl637y";
16
16
+
sha256 = "1aab380mv4ivy5icmwvk7941jbs6ikm21p5ijk7brr4z608k0vpj";
15
17
};
16
18
19
19
+
nativeBuildInputs = [ makeWrapper pkgconfig ];
20
20
+
17
21
buildInputs = [
18
18
-
makeWrapper pkgconfig nss nspr libqb
19
19
-
dbus librdmacm libibverbs libstatgrab net_snmp
20
20
-
];
21
21
-
22
22
-
# Remove when rdma libraries gain pkgconfig support
23
23
-
ibverbs_CFLAGS = optionalString (libibverbs != null)
24
24
-
"-I${libibverbs}/include/infiniband";
25
25
-
ibverbs_LIBS = optionalString (libibverbs != null) "-libverbs";
26
26
-
rdmacm_CFLAGS = optionalString (librdmacm != null)
27
27
-
"-I${librdmacm}/include/rdma";
28
28
-
rdmacm_LIBS = optionalString (librdmacm != null) "-lrdmacm";
22
22
+
nss nspr libqb
23
23
+
] ++ optional enableDbus dbus
24
24
+
++ optional enableInfiniBandRdma [ librdmacm libibverbs ]
25
25
+
++ optional enableMonitoring libstatgrab
26
26
+
++ optional enableSnmp net_snmp;
29
27
30
28
configureFlags = [
29
29
+
"--sysconfdir=/etc"
30
30
+
"--localstatedir=/var"
31
31
+
"--with-logdir=/var/log/corosync"
31
32
"--enable-watchdog"
32
33
"--enable-qdevices"
33
33
-
] ++ optional (dbus != null) "--enable-dbus"
34
34
-
++ optional (librdmacm != null && libibverbs != null) "--enable-rdma"
35
35
-
++ optional (libstatgrab != null) "--enable-monitoring"
36
36
-
++ optional (net_snmp != null) "--enable-snmp";
34
34
+
] ++ optional enableDbus "--enable-dbus"
35
35
+
++ optional enableInfiniBandRdma "--enable-rdma"
36
36
+
++ optional enableMonitoring "--enable-monitoring"
37
37
+
++ optional enableSnmp "--enable-snmp";
38
38
+
39
39
+
installFlags = [
40
40
+
"sysconfdir=$(out)/etc"
41
41
+
"localstatedir=$(out)/var"
42
42
+
"COROSYSCONFDIR=$(out)/etc/corosync"
43
43
+
"INITDDIR=$(out)/etc/init.d"
44
44
+
"LOGROTATEDIR=$(out)/etc/logrotate.d"
45
45
+
];
37
46
38
47
postInstall = ''
39
48
wrapProgram $out/bin/corosync-blackbox \
40
49
--prefix PATH ":" "$out/sbin:${libqb}/sbin"
41
50
'';
42
51
52
52
+
enableParallelBuilding = true;
53
53
+
43
54
meta = {
44
55
homepage = http://corosync.org/;
45
56
description = "A Group Communication System with features for implementing high availability within applications";
46
57
license = licenses.bsd3;
47
58
platforms = platforms.linux;
48
48
-
maintainers = with maintainers; [ wkennington ];
59
59
+
maintainers = with maintainers; [ wkennington montag451 ];
49
60
};
50
61
}