mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-03-18 04:44:53 +08:00
fix: false postive with binutils-gold
This commit is contained in:
parent
8092f1e481
commit
96c3e6b935
@ -40,6 +40,10 @@ class LinuxToolCheckList
|
|||||||
'xz',
|
'xz',
|
||||||
];
|
];
|
||||||
|
|
||||||
|
private const PROVIDED_COMMAND = [
|
||||||
|
'binutils-gold' => 'ld.gold',
|
||||||
|
];
|
||||||
|
|
||||||
/** @noinspection PhpUnused */
|
/** @noinspection PhpUnused */
|
||||||
#[AsCheckItem('if necessary tools are installed', limit_os: 'Linux', level: 999)]
|
#[AsCheckItem('if necessary tools are installed', limit_os: 'Linux', level: 999)]
|
||||||
public function checkCliTools(): ?CheckResult
|
public function checkCliTools(): ?CheckResult
|
||||||
@ -52,9 +56,9 @@ class LinuxToolCheckList
|
|||||||
default => self::TOOLS_DEBIAN,
|
default => self::TOOLS_DEBIAN,
|
||||||
};
|
};
|
||||||
$missing = [];
|
$missing = [];
|
||||||
foreach ($required as $cmd) {
|
foreach ($required as $package) {
|
||||||
if ($this->findCommand($cmd) === null) {
|
if ($this->findCommand(self::PROVIDED_COMMAND[$package] ?? $package) === null) {
|
||||||
$missing[] = $cmd;
|
$missing[] = $package;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!empty($missing)) {
|
if (!empty($missing)) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user