From 76d29412fd8827a1776d5fa25d5cd2aabf189ab6 Mon Sep 17 00:00:00 2001 From: Reno Dakota <170618376+paparodeo@users.noreply.github.com> Date: Thu, 24 Oct 2024 05:25:10 +0000 Subject: [PATCH] castxml: fix darwin build clang on darwin adds an `-isysroot` flag which breaks the regular expressions used in a couple tests --- pkgs/by-name/ca/castxml/package.nix | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/pkgs/by-name/ca/castxml/package.nix b/pkgs/by-name/ca/castxml/package.nix index fc8eccd1dcca..03a984741211 100644 --- a/pkgs/by-name/ca/castxml/package.nix +++ b/pkgs/by-name/ca/castxml/package.nix @@ -52,6 +52,14 @@ stdenv.mkDerivation (finalAttrs: { strictDeps = true; + # darwin clang adds `-isysroot` when $SDKROOT is set. this confuses the + # regular expressions for the disabled tests below. + checkPhase = '' + runHook preCheck + ctest -E 'cmd.cc-gnu-(src-cxx|c-src-c)-cmd' -j $NIX_BUILD_CORES + runHook postCheck + ''; + passthru.tests = testers.testVersion { package = finalAttrs.finalPackage; }; meta = {