File tree Expand file tree Collapse file tree 1 file changed +7
-5
lines changed
src/SPC/builder/unix/library Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ protected function build(): void
4444 $ error_exec_cnt = 0 ;
4545
4646 foreach ($ optional_packages as $ lib => $ pkg ) {
47- if ($ this ->getBuilder () ->getLib ($ lib )) {
47+ if ($ this ->builder ->getLib ($ lib )) {
4848 $ packages .= ' ' . $ pkg ;
4949 $ output = shell ()->execWithResult ("pkg-config --static {$ pkg }" );
5050 $ error_exec_cnt += $ output [0 ] === 0 ? 0 : 1 ;
@@ -125,10 +125,12 @@ protected function build(): void
125125 '--without-tcl '
126126 );
127127
128- $ libs = PkgConfigUtil::getLibsArray ('ldap ' );
129- $ libs = clean_spaces (implode (' ' , $ libs ));
130- FileSystem::replaceFileStr ($ this ->source_dir . '/build/config.status ' , '-lldap ' , $ libs );
131- FileSystem::replaceFileStr ($ this ->source_dir . '/build/src/Makefile.global ' , '-lldap ' , $ libs );
128+ if ($ this ->builder ->getLib ('ldap ' )) {
129+ $ libs = PkgConfigUtil::getLibsArray ('ldap ' );
130+ $ libs = clean_spaces (implode (' ' , $ libs ));
131+ FileSystem::replaceFileStr ($ this ->source_dir . '/build/config.status ' , '-lldap ' , $ libs );
132+ FileSystem::replaceFileStr ($ this ->source_dir . '/build/src/Makefile.global ' , '-lldap ' , $ libs );
133+ }
132134
133135 $ shell
134136 ->exec ($ envs . ' make -C src/bin/pg_config install ' )
You can’t perform that action at this time.
0 commit comments