diff --git a/src/SPC/builder/unix/library/ldap.php b/src/SPC/builder/unix/library/ldap.php index fd6f7105..807abc2b 100644 --- a/src/SPC/builder/unix/library/ldap.php +++ b/src/SPC/builder/unix/library/ldap.php @@ -4,17 +4,25 @@ declare(strict_types=1); namespace SPC\builder\unix\library; +use SPC\store\FileSystem; + trait ldap { + public function patchBeforeBuild(): bool + { + FileSystem::replaceFileStr($this->source_dir . '/configure', '"-lssl -lcrypto', '"-lz -lssl -lcrypto'); + return true; + } + protected function build(): void { $alt = ''; // openssl support - $alt .= ($this->builder->getLib('openssl') && $this->builder->getExt('zlib')) ? '--with-tls=openssl ' : ''; + $alt .= $this->builder->getLib('openssl') ? '--with-tls=openssl ' : ''; // gmp support $alt .= $this->builder->getLib('gmp') ? '--with-mp=gmp ' : ''; // libsodium support - $alt .= $this->builder->getLib('libsodium') ? '--with-argon2=libsodium ' : ''; + $alt .= $this->builder->getLib('libsodium') ? '--with-argon2=libsodium ' : '--enable-argon2=no '; f_putenv('PKG_CONFIG=' . BUILD_ROOT_PATH . '/bin/pkg-config'); f_putenv('PKG_CONFIG_PATH=' . BUILD_LIB_PATH . '/pkgconfig'); shell()->cd($this->source_dir) @@ -24,7 +32,6 @@ trait ldap '--enable-static ' . '--disable-shared ' . '--disable-slapd ' . - '--disable-slurpd ' . '--without-systemd ' . '--without-cyrus-sasl ' . $alt .