mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-03-17 20:34:51 +08:00
don't fail build without ldap
This commit is contained in:
parent
c83e803c85
commit
8a1689b79d
@ -44,7 +44,7 @@ trait postgresql
|
||||
$error_exec_cnt = 0;
|
||||
|
||||
foreach ($optional_packages as $lib => $pkg) {
|
||||
if ($this->getBuilder()->getLib($lib)) {
|
||||
if ($this->builder->getLib($lib)) {
|
||||
$packages .= ' ' . $pkg;
|
||||
$output = shell()->execWithResult("pkg-config --static {$pkg}");
|
||||
$error_exec_cnt += $output[0] === 0 ? 0 : 1;
|
||||
@ -125,10 +125,12 @@ trait postgresql
|
||||
'--without-tcl '
|
||||
);
|
||||
|
||||
$libs = PkgConfigUtil::getLibsArray('ldap');
|
||||
$libs = clean_spaces(implode(' ', $libs));
|
||||
FileSystem::replaceFileStr($this->source_dir . '/build/config.status', '-lldap', $libs);
|
||||
FileSystem::replaceFileStr($this->source_dir . '/build/src/Makefile.global', '-lldap', $libs);
|
||||
if ($this->builder->getLib('ldap')) {
|
||||
$libs = PkgConfigUtil::getLibsArray('ldap');
|
||||
$libs = clean_spaces(implode(' ', $libs));
|
||||
FileSystem::replaceFileStr($this->source_dir . '/build/config.status', '-lldap', $libs);
|
||||
FileSystem::replaceFileStr($this->source_dir . '/build/src/Makefile.global', '-lldap', $libs);
|
||||
}
|
||||
|
||||
$shell
|
||||
->exec($envs . ' make -C src/bin/pg_config install')
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user