circt: fix build failure on darwin platforms

This commit is contained in:
Shogo Takata
2024-11-02 16:33:59 +09:00
parent 28bd698b94
commit d24b911161
2 changed files with 7 additions and 1 deletions
+1 -1
View File
@@ -80,7 +80,7 @@ stdenv.mkDerivation {
#
# Inspired by fixDarwinDylibNames.
postFixup = lib.optionalString stdenv.hostPlatform.isDarwin ''
local flags=(-delete_rpath @loader_path/../lib)
local flags
for file in "$lib"/lib/*.dylib; do
flags+=(-change @rpath/"$(basename "$file")" "$file")
done
+6
View File
@@ -72,6 +72,12 @@ stdenv.mkDerivation rec {
doCheck = true;
checkTarget = "check-circt check-circt-integration";
preCheck = lib.optionalString stdenv.hostPlatform.isDarwin ''
echo moving libarc-jit-env.dylib to '$lib' before check because archilator links to the output path
mkdir -pv $lib/lib
cp -v ./lib/libarc-jit-env.dylib $lib/lib
'';
outputs = [
"out"
"lib"