postgresql16Packages.pg_similarity: fix build on darwin
Also fixes the build on linux with clang (JIT).
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
{ stdenv, lib, fetchFromGitHub, gcc, postgresql, unstableGitUpdater }:
|
||||
{ stdenv, lib, fetchFromGitHub, fetchpatch, postgresql, unstableGitUpdater }:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
pname = "pg_similarity";
|
||||
@@ -11,7 +11,17 @@ stdenv.mkDerivation {
|
||||
sha256 = "sha256-L04ANvyfzHgW7fINeJEY6T77Vojq3SI8P1TWiCRSPs0=";
|
||||
};
|
||||
|
||||
buildInputs = [ postgresql gcc ];
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
# https://github.com/eulerto/pg_similarity/pull/43
|
||||
# Also applied in debian as https://sources.debian.org/data/main/p/pg-similarity/1.0-8/debian/patches/pg16
|
||||
name = "pg16.patch";
|
||||
url = "https://github.com/eulerto/pg_similarity/commit/f7781ea5ace80f697a8249e03e3ce47d4b0f6b2f.patch";
|
||||
hash = "sha256-MPDvWfNzSg28lXL5u5/Un9pOCJjqJ4Fz9b8XCfalgts=";
|
||||
})
|
||||
];
|
||||
|
||||
buildInputs = [ postgresql ];
|
||||
|
||||
makeFlags = [ "USE_PGXS=1" ];
|
||||
|
||||
|
||||
Reference in New Issue
Block a user