dar: use llvmPackages_12 rather than gcc on Darwin

As pointed out by @wegank in
https://github.com/NixOS/nixpkgs/pull/202218#issuecomment-1322708760, a newer
clang also works.
This commit is contained in:
Atemu 2022-11-22 06:55:49 +01:00 committed by Rick van Schijndel
parent b26e38d254
commit 58710ad37d

View file

@ -1,4 +1,4 @@
{ lib, gccStdenv, fetchurl
args @ { lib, stdenv, llvmPackages_12, fetchurl
, which
, attr, e2fsprogs
, curl, libargon2, librsync, libthreadar
@ -10,9 +10,9 @@
with lib;
let
# Fails to build with clang on Darwin:
# Fails to build with clang-11 on Darwin:
# error: exception specification of overriding function is more lax than base version
stdenv = gccStdenv;
stdenv = if args.stdenv.isDarwin then llvmPackages_12.stdenv else args.stdenv;
in
stdenv.mkDerivation rec {