Skip to content

Commit 4e4cf4b

Browse files
committed
fix weird macos thing?!
1 parent d532b57 commit 4e4cf4b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/SPC/util/SPCConfigUtil.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,10 @@ private function getIncludesString(array $libraries): string
143143
}
144144
$pc_cflags = implode(' ', $pc);
145145
if ($pc_cflags !== '' && ($pc_cflags = PkgConfigUtil::getCflags($pc_cflags)) !== '') {
146+
$arr = explode(' ', $pc_cflags);
147+
$arr = array_unique($arr);
148+
$arr = array_filter($arr, fn ($x) => !str_starts_with($x, 'SHELL:-Xarch_'));
149+
$pc_cflags = implode(' ', $arr);
146150
$includes[] = $pc_cflags;
147151
}
148152
}

0 commit comments

Comments
 (0)