Files

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

61 lines
1.0 KiB
Nix
Raw Permalink Normal View History

2025-10-09 14:15:47 +02:00
{
lib,
stdenv,
fetchFromGitHub,
cmake,
pkg-config,
openssl,
zlib,
zstd,
icu,
cyrus_sasl,
snappy,
}:
stdenv.mkDerivation rec {
pname = "mongoc";
version = "1.30.3";
src = fetchFromGitHub {
owner = "mongodb";
repo = "mongo-c-driver";
tag = version;
hash = "sha256-3mzqsrbXfrtAAC5igIna5dAgU8FH23lkMS2IacVlCmI=";
};
nativeBuildInputs = [
cmake
pkg-config
];
buildInputs = [
openssl
zlib
zstd
icu
cyrus_sasl
snappy
];
cmakeFlags = [
"-DBUILD_VERSION=${version}"
"-DENABLE_UNINSTALL=OFF"
"-DENABLE_AUTOMATIC_INIT_AND_CLEANUP=OFF"
"-DCMAKE_INSTALL_LIBDIR=lib"
];
# remove forbidden reference to $TMPDIR
preFixup = ''
rm -rf src/{libmongoc,libbson}
'';
meta = with lib; {
description = "Official C client library for MongoDB";
homepage = "http://mongoc.org";
license = licenses.asl20;
mainProgram = "mongoc-stat";
maintainers = with maintainers; [ archer-65 ];
platforms = platforms.all;
};
}