2019-01-13 00:43:24 +01:00
|
|
|
{ stdenv, fetchFromGitHub, postgresql }:
|
2018-04-02 14:15:07 +02:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 14:41:18 +02:00
|
|
|
pname = "pg_topn";
|
2019-11-01 10:20:00 +01:00
|
|
|
version = "2.3.0";
|
2018-04-02 14:15:07 +02:00
|
|
|
|
|
|
|
buildInputs = [ postgresql ];
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "citusdata";
|
|
|
|
repo = "postgresql-topn";
|
|
|
|
rev = "refs/tags/v${version}";
|
2019-11-01 10:20:00 +01:00
|
|
|
sha256 = "05mjzm7rz5j7byzag23526hhsqsg4dsyxxsg8q9ray1rwxjbr392";
|
2018-04-02 14:15:07 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
installPhase = ''
|
2019-08-15 00:36:59 +02:00
|
|
|
mkdir -p $out/{lib,share/postgresql/extension}
|
2018-04-02 14:15:07 +02:00
|
|
|
|
|
|
|
cp *.so $out/lib
|
2019-07-01 16:18:03 +02:00
|
|
|
cp *.sql $out/share/postgresql/extension
|
|
|
|
cp *.control $out/share/postgresql/extension
|
2018-04-02 14:15:07 +02:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Efficient querying of 'top values' for PostgreSQL";
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "https://github.com/citusdata/postgresql-topn";
|
2018-04-02 14:15:07 +02:00
|
|
|
maintainers = with maintainers; [ thoughtpolice ];
|
2019-05-06 13:00:00 +02:00
|
|
|
platforms = postgresql.meta.platforms;
|
2018-04-02 14:15:07 +02:00
|
|
|
license = licenses.agpl3;
|
|
|
|
};
|
|
|
|
}
|