1 { stdenv, lib, fetchurl, libpcap, nixosTests }:
3 stdenv.mkDerivation rec {
8 url = "https://download.pureftpd.org/pub/ucarp/ucarp-${version}.tar.bz2";
9 sha256 = "0qidz5sr55nxlmnl8kcbjsrff2j97b44h9l1dmhvvjl46iji7q7j";
12 buildInputs = [ libpcap ];
14 # Workaround build failure on -fno-common toolchains like upstream
15 # gcc-10. Otherwise build fails as:
16 # ld: daemonize.o:/build/ucarp-1.5.2/src/ip_carp.h:73: multiple definition of
17 # `__packed'; ucarp.o:/build/ucarp-1.5.2/src/ip_carp.h:73: first defined here
18 env.NIX_CFLAGS_COMPILE = "-fcommon";
20 passthru.tests = { inherit (nixosTests) ucarp; };
23 description = "Userspace implementation of CARP";
25 UCARP allows a couple of hosts to share common virtual IP addresses in
26 order to provide automatic failover. It is a portable userland
27 implementation of the secure and patent-free Common Address Redundancy
28 Protocol (CARP, OpenBSD's alternative to the patents-bloated VRRP).
30 Warning: This package has not received any upstream updates for a long
31 time and can be considered as unmaintained.
33 license = with licenses; [ isc bsdOriginal bsd2 gpl2Plus ];
34 maintainers = with maintainers; [ oxzi ];
35 mainProgram = "ucarp";