nixpkgs-suyu/pkgs/tools/misc/odyssey/default.nix

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

38 lines
1.1 KiB
Nix
Raw Normal View History

{ lib, stdenv, fetchFromGitHub, cmake, openssl, postgresql, zstd, fetchpatch }:
2019-03-12 22:20:00 +01:00
stdenv.mkDerivation rec {
pname = "odyssey";
version = "1.3";
2019-03-12 22:20:00 +01:00
src = fetchFromGitHub {
owner = "yandex";
repo = pname;
2019-06-15 04:50:44 +02:00
rev = version;
sha256 = "sha256-1ALTKRjpKmmFcAuhmgpcbJBkNuUlTyau8xWDRHh7gf0=";
2019-03-12 22:20:00 +01:00
};
patches = [
# Fix compression build. Remove with the next release. https://github.com/yandex/odyssey/pull/441
(fetchpatch {
url = "https://github.com/yandex/odyssey/commit/01ca5b345c4483add7425785c9c33dfa2c135d63.patch";
sha256 = "sha256-8UPkZkiI08ZZL6GShhug/5/kOVrmdqYlsD1bcqfxg/w=";
})
];
2019-03-12 22:20:00 +01:00
nativeBuildInputs = [ cmake ];
buildInputs = [ openssl postgresql zstd ];
cmakeFlags = [ "-DPQ_LIBRARY=${postgresql.lib}/lib" "-DBUILD_COMPRESSION=ON" ];
2019-03-12 22:20:00 +01:00
installPhase = ''
install -Dm755 -t $out/bin sources/odyssey
'';
meta = with lib; {
2019-03-12 22:20:00 +01:00
description = "Scalable PostgreSQL connection pooler";
homepage = "https://github.com/yandex/odyssey";
2019-03-12 22:20:00 +01:00
license = licenses.bsd3;
maintainers = [ maintainers.marsam ];
platforms = [ "x86_64-linux" ];
};
}