1self: super:
2let
3 inherit (self) lib config;
4in
5(lib.packagesFromDirectoryRecursive {
6 inherit (super) callPackage;
7 directory = ./ext;
8})
9// {
10 timescaledb-apache = super.callPackage ./ext/timescaledb.nix { enableUnfree = false; };
11}
12// lib.optionalAttrs (!self.perlSupport) {
13 plperl = throw "PostgreSQL extension `plperl` is not available, because `postgresql` was built without Perl support. Override with `perlSupport = true` to enable the extension.";
14}
15// lib.optionalAttrs (!self.pythonSupport) {
16 plpython3 = throw "PostgreSQL extension `plpython3` is not available, because `postgresql` was built without Python support. Override with `pythonSupport = true` to enable the extension.";
17}
18// lib.optionalAttrs (!self.tclSupport) {
19 pltcl = throw "PostgreSQL extension `pltcl` is not available, because `postgresql` was built without Tcl support. Override with `tclSupport = true` to enable the extension.";
20}
21// lib.optionalAttrs config.allowAliases {
22 pg_embedding = throw "PostgreSQL extension `pg_embedding` has been removed since the project has been abandoned. Upstream's recommendation is to use pgvector instead (https://neon.tech/docs/extensions/pg_embedding#migrate-from-pg_embedding-to-pgvector)";
23}