From 9e71a98edaa874975e7286f752889a1f30998ab5 Mon Sep 17 00:00:00 2001 From: crazywhalecc Date: Fri, 2 Jun 2023 21:19:17 +0800 Subject: [PATCH] fix enable-zts option error on build:libs command --- src/SPC/builder/BuilderProvider.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/SPC/builder/BuilderProvider.php b/src/SPC/builder/BuilderProvider.php index 879153f8..a4e54032 100644 --- a/src/SPC/builder/BuilderProvider.php +++ b/src/SPC/builder/BuilderProvider.php @@ -31,13 +31,13 @@ class BuilderProvider cc: $input->getOption('cc'), cxx: $input->getOption('cxx'), arch: $input->getOption('arch'), - zts: $input->getOption('enable-zts'), + zts: $input->hasOption('enable-zts') ? $input->getOption('enable-zts') : false, ), 'Linux' => new LinuxBuilder( cc: $input->getOption('cc'), cxx: $input->getOption('cxx'), arch: $input->getOption('arch'), - zts: $input->getOption('enable-zts'), + zts: $input->hasOption('enable-zts') ? $input->getOption('enable-zts') : false, ), default => throw new WrongUsageException('Current OS "' . PHP_OS_FAMILY . '" is not supported yet'), };