mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-07-05 15:55:39 +08:00
refactor: replace SPC_LIBC with SPC_TARGET and update related logic
This commit is contained in:
@@ -5,6 +5,7 @@ declare(strict_types=1);
|
||||
namespace SPC\builder\unix\library;
|
||||
|
||||
use SPC\util\executor\UnixCMakeExecutor;
|
||||
use SPC\util\SPCTarget;
|
||||
|
||||
trait mimalloc
|
||||
{
|
||||
@@ -15,7 +16,7 @@ trait mimalloc
|
||||
'-DMI_BUILD_SHARED=OFF',
|
||||
'-DMI_INSTALL_TOPLEVEL=ON'
|
||||
);
|
||||
if (getenv('SPC_LIBC') === 'musl') {
|
||||
if (SPCTarget::isTarget(SPCTarget::MUSL) || SPCTarget::isTarget(SPCTarget::MUSL_STATIC)) {
|
||||
$cmake->addConfigureArgs('-DMI_LIBC_MUSL=ON');
|
||||
}
|
||||
$cmake->build();
|
||||
|
||||
Reference in New Issue
Block a user