Skip to content

Commit

Permalink
postgresqlPackages.postgis: fix build on clang 12+
Browse files Browse the repository at this point in the history
Work around #166205
  • Loading branch information
reckenrode committed Nov 23, 2023
1 parent f0b7a60 commit b6d4be1
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pkgs/servers/sql/postgresql/ext/postgis.nix
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,10 @@ stdenv.mkDerivation rec {
dontDisableStatic = true;

# postgis config directory assumes /include /lib from the same root for json-c library
NIX_LDFLAGS = "-L${lib.getLib json_c}/lib";
NIX_LDFLAGS = "-L${lib.getLib json_c}/lib"
# Work around https://github.com/NixOS/nixpkgs/issues/166205.
+ lib.optionalString (stdenv.cc.isClang && stdenv.cc.libcxx != null) " -l${stdenv.cc.libcxx.cxxabi.libName}";


preConfigure = ''
sed -i 's@/usr/bin/file@${file}/bin/file@' configure
Expand Down

0 comments on commit b6d4be1

Please sign in to comment.