{ stdenv, fetchFromGitHub, cmake, pkgconfig, libevent, openssl}: stdenv.mkDerivation rec { name = "libcouchbase-${version}"; version = "2.9.4"; src = fetchFromGitHub { owner = "couchbase"; repo = "libcouchbase"; rev = version; sha256 = "0d6lmnr5yfpkzr1yr6f2ilxprl6v9r4r7917k4iz0wc3jlcndwl3"; }; cmakeFlags = "-DLCB_NO_MOCK=ON"; nativeBuildInputs = [ cmake pkgconfig ]; buildInputs = [ libevent openssl ]; doCheck = !stdenv.isDarwin; checkPhase = "ctest"; meta = with stdenv.lib; { description = "C client library for Couchbase"; homepage = https://github.com/couchbase/libcouchbase; license = licenses.asl20; platforms = platforms.unix; }; }