patch before make for uv fix

This commit is contained in:
DubbleClick
2025-06-20 15:57:16 +07:00
parent be0b98c467
commit 3f92df0865
3 changed files with 5 additions and 6 deletions

View File

@@ -21,10 +21,10 @@ class uv extends Extension
public function patchBeforeSharedMake(): bool
{
if (PHP_OS_FAMILY !== 'Linux' || php_uname('m') !== 'aarch64' || SystemUtil::getLibcVersionIfExists() > '2.17') {
if (PHP_OS_FAMILY !== 'Linux' || GNU_ARCH !== 'aarch64') {
return false;
}
FileSystem::replaceFileRegex($this->source_dir . '/Makefile', '/^(LDFLAGS =.*)$/', '$1 -luv -ldl -lrt -pthread');
FileSystem::replaceFileRegex($this->source_dir . '/Makefile', '/^(LDFLAGS =.*)$/m', '$1 -luv -ldl -lrt -pthread');
return true;
}
}