Add helper function for SPCConfigUtil

This commit is contained in:
crazywhalecc
2025-11-04 13:36:29 +08:00
parent 4d5641f6ec
commit 08362fb6e5
6 changed files with 100 additions and 48 deletions

View File

@@ -47,7 +47,7 @@ trait postgresql
{
$libs = array_map(fn ($x) => $x->getName(), $this->getDependencies(true));
$spc = new SPCConfigUtil($this->builder, ['no_php' => true, 'libs_only_deps' => true]);
$config = $spc->config(libraries: $libs, include_suggest_lib: $this->builder->getOption('with-suggested-libs'));
$config = $spc->config(libraries: $libs, include_suggest_lib: $this->builder->getOption('with-suggested-libs', false));
$env_vars = [
'CFLAGS' => $config['cflags'],