Merge pull request #121071 from georgyo/psql-gssapi

postgresql: enable gssapi/kerberos support
This commit is contained in:
Mario Rodas 2021-05-01 22:31:37 -05:00 committed by GitHub
commit b0813d32de
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -8,6 +8,8 @@ let
# This is important to obtain a version of `libpq` that does not depend on systemd.
, enableSystemd ? (lib.versionAtLeast version "9.6" && !stdenv.isDarwin)
, gssSupport ? with stdenv.hostPlatform; !isWindows && !isStatic, libkrb5
# for postgreql.pkgs
, this, self, newScope, buildEnv
@ -38,6 +40,7 @@ let
[ zlib readline openssl libxml2 ]
++ lib.optionals icuEnabled [ icu ]
++ lib.optionals enableSystemd [ systemd ]
++ lib.optionals gssSupport [ libkrb5 ]
++ lib.optionals (!stdenv.isDarwin) [ libossp_uuid ];
nativeBuildInputs = [ makeWrapper ] ++ lib.optionals icuEnabled [ pkg-config ];
@ -62,7 +65,8 @@ let
"--enable-debug"
(lib.optionalString enableSystemd "--with-systemd")
(if stdenv.isDarwin then "--with-uuid=e2fs" else "--with-ossp-uuid")
] ++ lib.optionals icuEnabled [ "--with-icu" ];
] ++ lib.optionals icuEnabled [ "--with-icu" ]
++ lib.optionals gssSupport [ "--with-gssapi" ];
patches =
[ (if atLeast "9.4" then ./patches/disable-resolve_symlinks-94.patch else ./patches/disable-resolve_symlinks.patch)